Skip to content

fix(templates): dashboard controls that did nothing show what they would do - #12040

Merged
josephfarina merged 1 commit into
mainfrom
josephfarina/dashboard-working-controls
Nov 16, 2026
Merged

josephfarina merged 1 commit into
mainfrom
josephfarina/dashboard-working-controls

Conversation

@josephfarina

Copy link
Copy Markdown
Contributor

User impact

Controls in six dashboard page templates did nothing when pressed. People and agents copying these templates got buttons that look interactive but do nothing, with no hint of what they are for. Each now responds with a short message that starts with "Demo:" and says what the button would do in a real app.

Problem and solution fit

  • Analytics dashboard: Reload ("the active-users data would reload here") and both View more buttons (the full demographics breakdown / engagement report "would open here").
  • Comparison, scorecard and funnel dashboards: Export ("… would export here"). A real export is a new feature, so these stay demo messages.
  • Program dashboard: Export status ("the program status would export here").
  • Portfolio dashboard: View more ("the full market overview would open here").

Each handler carries the comment "Demo only: replace this toast with the call that performs the action." so a copy shows where to connect the real call. No layout, style or behavior beyond the message changes.

Expected behavior and authority

Template controls either act or say honestly what they would do; a message never claims an action happened. The templates' existing confirmations are unchanged.

Smallest restoration

One onClick per dead control, the toast hook where the component did not have it, and a changeset.

Evidence

  • Before: pressing each listed control did nothing.
  • After (built into a Vite app with the neutral theme, Chromium at 1280 px): each listed control shows its "Demo:" message, and no page errors occur.
  • A replay of build on this change against main (cold, one run at a time) moves no start, alternative or block list.

Scope

Components: dashboard, dashboard-comparison, dashboard-scorecard, dashboard-cohort-funnel, dashboard-progress, dashboard-composition page templates

  • One defect is restored.
  • Separable contradictory or unsettled tagalongs were removed or split.
  • No new public API, visual representation, default, or interaction model is hidden under the bug-fix label.
  • Public text and artifacts contain no internal Meta context.

Testing

  • prettier, eslint and a strict typecheck on the changed pages: clean.
  • Real browser (Chromium, 1280×800): every listed control clicked, as under Evidence; the repository's 390 px phone check passes on these templates.

@vercel

vercel Bot commented Nov 16, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
astryx Ready Ready Preview Nov 16, 2026 8:47am UTC

Request Review

@meta-cla meta-cla Bot added the CLA Signed This label is managed by the Meta Open Source bot. label Nov 16, 2026
@astracat-bot

astracat-bot Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

AI review status for this pull request.

Review status Updated
🟢 Reviewed (for maintainers only) Nov 16, 2026, 9:22 AM UTC

@github-actions github-actions Bot added the needs:design-review Affects visuals — Design should review label Nov 16, 2026
@josephfarina

Copy link
Copy Markdown
Contributor Author

/approve-spec e7e5f98

@github-actions

github-actions Bot commented Nov 16, 2026 •

Copy link
Copy Markdown
Contributor

PR Analysis Report

🔎 Preview · e7e5f98

Storybook · Sandbox · built from this PR's head

Package size: @astryxdesign/cli 5.12 MB packed (+478 B); no new dependencies.

Not run on this PR: add ci:run-visual for Visual, ci:run-a11y for Accessibility, ci:run-rtl for RTL.


Generated by PR Enrichment workflow | View full report

@astracat-bot astracat-bot Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approved pending CI: CI has not run on this head yet. Its run stopped before any test because CI was full, so it needs a re-run.

The eight buttons that did nothing in the six dashboard templates now show their "Demo:" toast, and an engineering owner approved that demo-toast behavior for this head. Non-blocking, and not caused by this change: the Project Status and Data Dashboard templates keep template-rubric deductions from main (a raw <div> wrapper, custom CSS, and in Data Dashboard a fixed two-column grid), and Project Status is 1,148 lines, long for one page layout.

Claims and files checked

Review mode: full; reason: no-earlier-review

  • Claim: the listed controls in six dashboard templates did nothing when pressed. Verified: none of the eight buttons had a click handler on the base, and in Chromium a press showed nothing.
  • Claim: each now shows a short message that starts with "Demo:" and says what it would do. Verified at every handler and in Chromium for all eight.
  • Claim: Analytics Reload and both View more buttons show the active-users reload, demographics and engagement messages. Verified at dashboard/page.tsx:744, :783 and :806.
  • Claim: Export on the comparison, scorecard and funnel dashboards shows its export message. Verified at dashboard-comparison/page.tsx:824, dashboard-scorecard/page.tsx:805 and dashboard-cohort-funnel/page.tsx:840.
  • Claim: the program dashboard's Export status shows the program status message. Verified at dashboard-progress/page.tsx:619.
  • Claim: the portfolio dashboard's View more shows the market overview message. Verified at dashboard-composition/page.tsx:747.
  • Claim: each handler carries the "Demo only: replace this toast …" comment. Verified: eight comments, one per handler.
  • Claim: no layout, style or behavior beyond the message changes. Verified from the diff: imports, one hook call per component and the click handlers; two View more buttons only reflow onto several lines.
  • Claim: a message never claims an action happened. Verified: every message says what "would" happen.
  • Claim: the templates' existing confirmations are unchanged. Verified: the diff touches no other handler.
  • Claim: one click handler per dead control, the toast hook where the component lacked it, and a changeset. Verified.
  • Claim: in a browser at 1280 px each control shows its message with no page errors. Verified in Chromium at 1280 px: each message, no console errors.
  • Claim: the 390 px phone check passes. Not re-run here; the diff adds no markup.
  • Claim: the build-recommendation replay moves nothing. Not reproducible here; consistent with unchanged template docs.
  • Claim: prettier, eslint and a strict typecheck are clean on the changed pages. Verified for all three.
  • Claim: one defect is restored, with no hidden public API, default or interaction model, and no internal context in public text. Verified: no package surface changes, and the demo toast is owner-approved for this head.
  • Claim (changeset): a patch note naming the same controls in the six templates. Verified against the diff.
  • File .changeset/dashboard-working-controls.md: clear.
  • File packages/cli/assets/templates/pages/dashboard/page.tsx: clear.
  • File packages/cli/assets/templates/pages/dashboard-comparison/page.tsx: clear; it keeps existing template-rubric deductions (70), which this change does not cause.
  • File packages/cli/assets/templates/pages/dashboard-scorecard/page.tsx: clear.
  • File packages/cli/assets/templates/pages/dashboard-cohort-funnel/page.tsx: clear.
  • File packages/cli/assets/templates/pages/dashboard-progress/page.tsx: clear; it keeps existing template-rubric deductions (74) and is 1,148 lines, non-blocking notes.
  • File packages/cli/assets/templates/pages/dashboard-composition/page.tsx: clear.

Automated review (maintainer link)

@josephfarina
josephfarina merged commit 9eab143 into main Nov 16, 2026
359 of 395 checks passed
@github-actions
github-actions Bot deleted the josephfarina/dashboard-working-controls branch November 17, 2026 06:03

This branch was successfully deployed

1 active deployment
Preview — e7e5f98d Deployed Nov 16, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CLA Signed This label is managed by the Meta Open Source bot. needs:design-review Affects visuals — Design should review

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant