Skip to content

feat(dashboard): end onboarding with a compact plan step - #1096

Open
izadoesdev wants to merge 5 commits into
mainfrom
izadoesdev/onboarding-plan-step-release
Open

izadoesdev wants to merge 5 commits into
mainfrom
izadoesdev/onboarding-plan-step-release

Conversation

@izadoesdev

@izadoesdev izadoesdev commented Oct 8, 2026 •

Copy link
Copy Markdown
Member

Cherry-pick of staging 8c5517d.

Why

New owners finished onboarding without ever seeing what paid plans give them. A plan checkpoint added earlier sat between feature picks and setup and dropped the full Billing table into the flow, before the user had connected anything.

What changes

  • After the setup checklist, owners and admins on cloud get a final Pick a plan step. Self-hosted installs and members without billing rights skip it.
  • One card in the checklist's style: current plan, then a row per plan with its monthly allowances (events, investigations), price, and upgrade action. The footer opens the dashboard or Insights, so an upgrade made here unlocks "Open Insights" immediately.
  • Checkout returns to the same step (website and step=plan are kept in the URL).
  • The preview, confirm, and checkout logic is extracted from PricingCard into a shared PlanButton, so Billing and onboarding buy plans the same way.
  • Billing provider now reports real isError/isFetching; the plans error state has a retry.

Verification

  • Dashboard e2e (chromium, local): core onboarding (fresh account through the plan step, back to setup, reload on the plan step), plan-step billing recovery and checkout return, verified-onboarding regression, and billing-controls regression all pass.
  • Dashboard typecheck and Biome clean on this branch.
  • Not checked: mobile widths, and rendering with live Autumn plans (e2e uses a mocked plan list).

Summary by cubic

Adds a final Pick a plan step after the onboarding setup checklist so cloud owners and admins can upgrade before opening the dashboard.

  • The step is gated by the onboarding-plan-step flag and a live billing build; self-hosted installs, E2E, members without billing rights, and billing failures skip it.
  • One compact card lists each plan's monthly events and investigations allowance, price, and upgrade action, then opens the dashboard or Insights; checkout returns to the same step=plan URL, so a completed upgrade unlocks "Open Insights" right away.
  • Extracts preview, confirm, and checkout logic from PricingTable into a shared PlanButton, and billing reports isError/isFetching only when its data is missing, so a failed plan list or background refetch no longer turns Open Insights into Open dashboard.
  • Returning from checkout or a reload no longer repeats the onboarding-started and tracking-verified events; going back to setup re-records tracking verification, and the "Skip setup" button is removed from the interests step.
  • E2E coverage runs on a key-gated public fixture that checks plan rows, retry after the plan list fails, and checkout returning to the plan step.

Written for commit 4950c0c. Summary will update on new commits.

View guided diff Turn on auto-fix

Rollout

The step is gated by the onboarding-plan-step flag on the dashboard's flag website (OXmNQsViBT-FOS_wZCTHc). Until that flag exists and is on for a user, onboarding behaves as it does today. Create it as a rollout flag at 50%. E2E runs with flags disabled, so the gate treats E2E as on.

Review fixes (46f009b)

  • Billing isError/isFetching only report missing billing data, so a failed plan list or a background refetch no longer turns Open Insights into Open dashboard.
  • Returning to the plan step from checkout or a reload no longer repeats onboarding_started and the tracking-verified events.

@vercel

vercel Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

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

Project Deployment Actions Updated
dashboard Ready Ready Preview Oct 10, 2026 5:23pm UTC
databuddy-status Ready Ready Preview Oct 10, 2026 5:23pm UTC
documentation Ready Ready Preview Oct 10, 2026 5:23pm UTC

@unkey-deploy

unkey-deploy Bot commented Oct 8, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Unkey Deploy

Name Status Preview Inspect Updated (UTC)
links (preview) Ready Visit Preview Inspect Oct 10, 2026 5:22pm

@coderabbitai

coderabbitai Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration
  • Configuration used: Repository UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: 9aff033d-3114-4b89-8064-b6a437ecc30c

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@github-actions

github-actions Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Observability score · 31

poor · unchanged against main · no regression

1 instrumented · 0 partial · 8 dark

Fix first (3)

evlog map v0.8.0 · how the score works · what each check expects

@blacksmith-sh

This comment has been minimized.

@greptile-apps

greptile-apps Bot commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 4/5

[Medium risk] Adds plan selection step to onboarding flow.

The flow appears sound, but the explicit text styling, callback naming, and nested-expression requirements must be satisfied before merging.

Findings

  1. P2 Required text classes are missing ▶
  2. P2 Finish choices are nested ▶
  3. P2 Callback names lack required suffix ▶

Summary

Adds a final plan step after onboarding setup for cloud users who can upgrade.

  • Shares checkout and confirmation through PlanButton.
  • Keeps the onboarding URL when checkout returns.
  • Exposes billing errors and fetching state, with a retry for loading plans.
  • Three repository style requirements need to be satisfied before merging.

izadoesdev explicitly acknowledged that “e2e uses a mocked plan list”; this known choice is not reported.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
  A[Pick features] --> B[Setup checklist]
  B --> C{Cloud and allowed to upgrade?}
  C -->|Yes| D[Pick a plan]
  C -->|No| G[Dashboard or Insights]
  D -->|Back| B
  D --> E[Preview and confirm]
  E -->|Checkout| F[Return to saved plan step]
  F --> D
  E -->|Updated directly| D
  D -->|Finish| G
Loading

Reviews (1) · Last reviewed commit: "feat(dashboard): end onboarding with a c..." · Reviewed by Greptile

<div className="h-full overflow-y-auto">
<div className="mx-auto w-full max-w-3xl px-4 py-6 sm:px-6 lg:py-10">
<div className="mb-4 flex items-center justify-between gap-3">
<h1 className="font-semibold text-xl">Pick a plan</h1>

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.

P2 Required text classes are missing

The new heading lacks text-balance, and the allowance paragraph lacks text-pretty. The UI guide requires these classes for headings and paragraphs. Add both before merging.

Context Used: .cursor/rules/ui-guidelines.mdc (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Comment on lines 516 to 520
websiteId
? {
label: reviewPending
? "Checking Insights…"
: opensInsights
? "Open Insights"
: "Open dashboard",
onClick: finish,
loading: reviewPending || research.saving,
note: reviewFailed
? "Failed to check Insights."
: opensInsights
? "Your first review runs once there is enough history to compare."
: null,
onRetry: reviewFailed ? billing.refetch : undefined,
}
? offersPlans
? { label: "Continue", onClick: choosePlan }
: { ...leaveAction, onClick: finish }
: null

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.

P2 Finish choices are nested

The new finish expression nests one ternary inside another, which the repository guide forbids. Calculate the finish action separately with early returns or if statements so the three cases are easier to follow. This requirement must be satisfied before merging.

Context Used: Ultracite Rules - AI-Ready Formatter and Linter (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

successPath,
}: {
finish: NonNullable<SetupChecklistProps["finish"]>;
onBack: () => void;

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.

P2 Callback names lack required suffix

The new callback types use onBack and onPlanUpdated without the required Action suffix. The repository guide requires function properties in types to end with Action. Rename these properties and their callers before merging. The same rule applies to the new onPlanUpdated properties in PricingTable and PricingCard.

Context Used: Basic guidelines for the project so vibe coders don't fuck it up (source)

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

@FindMalek

Copy link
Copy Markdown
Contributor

found a small bug while reviewing this - offersPlans gates on billing.isLoading, so a reload while on step=plan (e.g. checkout return) briefly falls through to SetupChecklist until billing refetches, then flips to ChoosePlan. opened a stacked fix: #1111

After setup, owners and admins on cloud pick a plan from one card that
lists each plan's monthly allowances, price and upgrade action, then
open the dashboard or Insights. Checkout returns to the same step.

(cherry picked from commit 8c5517d)
The plan step now also needs the onboarding-plan-step flag, so it can
reach half of new owners first. Billing only reports an error or a
pending check when its data is missing, so a failed plan list or a
background refetch no longer turns Open Insights into Open dashboard.
Returning to the plan step from checkout or a reload no longer repeats
the onboarding started and tracking verified events.

(cherry picked from commit efbd272)
…step

Members without billing rights no longer see plans while billing loads or fails, the card no longer claims Free when billing failed, and going back to setup after checkout records tracking verification again.

(cherry picked from commit 6fa430d)
E2E and self-host builds skip the Autumn provider, so the plan step crashed there. It now needs a live billing build and the onboarding-plan-step flag, and the e2e specs return to main's flow. The pricing table drops props only onboarding used, and the plan step file is named after its component.
E2E builds skip the Autumn provider in the app layout, so the plan step is exercised on a key-gated public fixture. It checks plan rows and allowances, recovery after the plan list fails, and that checkout returns to the onboarding plan step.

This branch was successfully deployed

4 active deployments
Preview – dashboard — 4950c0cb Deployed Oct 10, 2026 by vercel[bot]
Preview – documentation — 4950c0cb Deployed Oct 10, 2026 by vercel[bot]
Preview – databuddy-status — 4950c0cb Deployed Oct 10, 2026 by vercel[bot]
links - preview — 4950c0cb Deployed Oct 10, 2026 by unkey-deploy[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants