feat(web): replace empty dashboard zeros with a first-run screen - #1
Merged
Conversation
An account with no tunnels was rendering ops KPIs at 0, which looked like a broken product. Switch on a DashboardView union so first-run, relay-down, and operating cannot share chrome. Co-authored-by: Cursor <cursoragent@cursor.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Co-authored-by: Cursor <cursoragent@cursor.com>
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.
Why
An account with no tunnels rendered three KPI cards at 0 plus empty ops tables. That looked like a broken product. First-run users need CLI setup, not fake monitoring.
Scope
dashboardViewinweb/lib/dashboard-view.tsturns settled relay fetches intofirst-run,relay-down, oroperating.web/app/dashboard/page.tsxswitches onkind. First-run hides KPIs, routes, and logs, and shows a personalized host plus copyable install, login,bitrok myapp 3000, andcurl. Operating keeps the existing KPI, route, and log layout. Relay-down keeps the warning and does not claim the account is empty. Dead{!username && ...}banner afterredirectis gone.web/lib/dashboard-view.test.tscovers the three kinds.Tradeoffs
A separate first-run screen means a new user does not see where KPIs will live until they have a tunnel. That is the point. The progressive alternative kept the ops shell with em dashes and still looked empty.
Redis is unused. Traffic still comes from relay SQLite.
Blast Radius
Signed-in
/dashboardonly. Accounts with tunnels should look the same except logs-unavailable shows—instead of0. Username onboarding still redirects to settings.Verification
cd web && npm test: 16 passed, including fourdashboardViewcases.npx eslinton the touched files passed.npx tsc --noEmitpassed in the worktree. No browser MCP in this session, so first-run layout was not clicked through in a live session.Made with Cursor