Skip to content

feat: update banners for credit based trial plan#9404

Merged
AdityaHegde merged 8 commits into
mainfrom
feat/credit-based-trial-plan
May 12, 2026
Merged

feat: update banners for credit based trial plan#9404
AdityaHegde merged 8 commits into
mainfrom
feat/credit-based-trial-plan

Conversation

@AdityaHegde
Copy link
Copy Markdown
Collaborator

@AdityaHegde AdityaHegde commented May 6, 2026

Updates the banners to support the new credit based trial plan. Follows: https://www.notion.so/rilldata/Cloud-First-Burn-Down-Plan-343ba33c8f57813fb3abdc4e4bcaf042?source=copy_link#34aba33c8f578023b0fffeb698b52304

Checklist:

  • Covered by tests
  • Ran it and it works as intended
  • Reviewed the diff before requesting a review
  • Checked for unhandled edge cases
  • Linked the issues it closes
  • Checked if the docs need to be updated. If so, create a separate Linear DOCS issue
  • Intend to cherry-pick into the release branch
  • I'm proud of this work!

@AdityaHegde AdityaHegde changed the title feat: UI support for credit based trial plan feat: update banners for credit based trial plan May 12, 2026
@AdityaHegde AdityaHegde marked this pull request as ready for review May 12, 2026 06:25
@AdityaHegde AdityaHegde requested a review from a team as a code owner May 12, 2026 06:25
Copy link
Copy Markdown
Member

@djbarnwal djbarnwal left a comment

Choose a reason for hiding this comment

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

Developed the below feedback with Codex:

  • [P1] Dismissing the welcome banner hides later low-credit warnings forever.
    web-admin/src/features/billing/issues/getMessageForTrialPlan.ts:105 and :110 both use buildDismissableForIssue, which stores id: issue.type at :150. Since welcome and low-credit are both BILLING_ISSUE_TYPE_ON_CREDIT_TRIAL, a forever dismissal from the welcome state makes isBannerDismissed return true later at web-common/src/components/banner/banner-dismiss.ts:16-17. Admins who dismiss “Welcome to Rill” will never see the 80% warning.

  • [P1] The 50% and 90% credit flows are not implemented.
    getMessageForCreditsTrial only branches on onCreditTrial.lowCredit at web-admin/src/features/billing/issues/getMessageForTrialPlan.ts:101. The API shape only exposes creditAllocation and lowCredit (web-admin/src/client/gen/index.schemas.ts:187-191), so the UI cannot show the 50% blue weekly banner or the 90% red “almost out” banner with 4-hour/session dismissal.

Feel free to ignore them if they are not relevant to this PR.

@AdityaHegde
Copy link
Copy Markdown
Collaborator Author

Thanks @djbarnwal . Fixed the issue with low credits, good catch. We are not doing 50% & 90% right now, just 80%. Updated the doc to clarify.

@AdityaHegde AdityaHegde force-pushed the feat/credit-based-trial-plan branch from 6cbf798 to 067dd7e Compare May 12, 2026 13:17
@AdityaHegde
Copy link
Copy Markdown
Collaborator Author

Merging since the test is unrelated and on main.

@AdityaHegde AdityaHegde merged commit 57fdabc into main May 12, 2026
18 of 22 checks passed
@AdityaHegde AdityaHegde deleted the feat/credit-based-trial-plan branch May 12, 2026 14:51
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