Skip to content

feat(frontend): improve plans page UX for credits-only orgs#1629

Merged
riderx merged 2 commits into
mainfrom
feat/credits-only-plans-ux
Feb 14, 2026
Merged

feat(frontend): improve plans page UX for credits-only orgs#1629
riderx merged 2 commits into
mainfrom
feat/credits-only-plans-ux

Conversation

@WcaleNieWolny
Copy link
Copy Markdown
Contributor

@WcaleNieWolny WcaleNieWolny commented Feb 13, 2026

Summary (AI generated)

  • Replace misleading "Don't want to upgrade?" CTA with an informational banner for credits-only orgs on the Plans settings page
  • Remove the blue border highlight on the Solo plan card for credits-only orgs (they're not actually on Solo — it's a fallback)
  • Use the information icon (heroicons/information-circle) instead of the currency dollar icon for the new banner
  • Add 3 new translation keys (credits-only-info-title, credits-only-info-description, credits-only-info-link) in all 15 languages via DeepL API (Hindi translated manually)

Motivation (AI generated)

Credits-only organizations (orgs that purchased credits but have no active Stripe subscription) were seeing a confusing Plans page:

  1. The "Don't want to upgrade?" CTA implied they should consider credits — but they're already using credits
  2. The Solo plan card was highlighted with a blue border as if it were their current plan — but they have no plan at all

This created a misleading UX that contradicted the user's actual state. The fix replaces the upsell CTA with a clear informational banner and removes the false plan highlight.

Business Impact (AI generated)

  • User clarity: Credits-only customers now see an accurate representation of their account state
  • Reduced confusion: No more misleading "current plan" highlight or irrelevant upgrade prompt
  • Credit adoption: The "Manage your credit usage" link provides a direct path to the credits page, reinforcing the pay-as-you-go model
  • Follows PR fix(frontend): don't show paywall for credits-only orgs #1628: Complements the paywall fix by also fixing the Plans page UX for the same user segment

Test Plan (AI generated)

  • Spoof credits-only user on local dev server with production backend
  • Verify info banner shows "Using credits instead of a plan" with information icon
  • Verify "You are not currently subscribed to any plan." description text
  • Verify "Manage your credit usage" link navigates to /settings/organization/credits
  • Verify Solo plan card does NOT have blue border highlight
  • Verify all plan cards have uniform gray border styling
  • Verify non-credits-only orgs still see the original "Don't want to upgrade?" CTA
  • ESLint passes with no errors

Screenshots

(Will be added as a comment — GitHub CLI does not support inline image upload in PR body)

Generated with AI

Summary by CodeRabbit

  • New Features
    • Adds an informational banner for users with available credits but no active subscription — includes title, description, and link to manage credits.
    • Adds localized copy for this credits-only banner across 16 languages.

- Replace misleading 'Don't want to upgrade?' CTA with info banner for
  orgs using credits without a subscription plan
- Remove blue border highlight on Solo plan for credits-only orgs
- Use information icon instead of currency icon for credits-only banner
- Add new translation keys in all 15 languages via DeepL
@WcaleNieWolny
Copy link
Copy Markdown
Contributor Author

WcaleNieWolny commented Feb 13, 2026

Screenshots

Before (production — credits-only org on Plans page)

before-redacted

After (feature branch — credits-only org on Plans page)

after-redacted

Key changes visible

  • Before: Solo plan has blue border highlight + "Don't want to upgrade?" CTA at top
  • After: No blue border on Solo + informational banner "Using credits instead of a plan" with ℹ️ icon and "Manage your credit usage" link

Sensitive information (org names, user names, emails) has been redacted in both screenshots.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Feb 13, 2026

📝 Walkthrough

Walkthrough

Adds localized strings for a "credits-only" UI state across multiple languages, introduces a creditsOnly prop on CreditsCta.vue, and passes an isCreditsOnly computed flag from Plans.vue to conditionally render a credits-info banner.

Changes

Cohort / File(s) Summary
Localization Updates
messages/de.json, messages/en.json, messages/es.json, messages/fr.json, messages/hi.json, messages/id.json, messages/it.json, messages/ja.json, messages/ko.json, messages/pl.json, messages/pt-br.json, messages/ru.json, messages/tr.json, messages/vi.json, messages/zh-cn.json
Added three translation keys in each file: credits-only-info-description, credits-only-info-link, and credits-only-info-title to support credits-only UI copy.
CreditsCta Component
src/components/CreditsCta.vue
Added creditsOnly?: boolean prop (default false); conditional rendering: show a credits-only information banner with icon, title, description, and link when creditsOnly is true; otherwise render existing CTA.
Plans Page
src/pages/settings/organization/Plans.vue
Added isCreditsOnly computed to detect orgs with no active plan but available credits; passes this flag to CreditsCta via a new credits-only prop and adjusts plan highlight logic to exclude credits-only orgs.

Sequence Diagram(s)

sequenceDiagram
    participant Plans as Plans.vue
    participant CreditsCta as CreditsCta.vue
    participant Router as Router/goToCredits
    participant User as User

    Plans->>CreditsCta: pass prop credits-only = isCreditsOnly
    CreditsCta-->>Plans: render banner if credits-only true
    User->>CreditsCta: clicks banner link
    CreditsCta->>Router: goToCredits()
    Router-->>User: navigate to Credits page
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Possibly related PRs

Suggested labels

enhancement

Suggested reviewers

  • riderx

Poem

🐰 A little hop for credits small,
A banner bright to welcome all,
No plan in sight, but options near,
Manage your credits, cheer to cheer!

🚥 Pre-merge checks | ✅ 4
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title 'feat(frontend): improve plans page UX for credits-only orgs' accurately and concisely describes the main change: improving user experience for credits-only organizations on the plans page.
Description check ✅ Passed The description covers all required template sections with comprehensive detail: Summary explains the key changes, Motivation provides business context, Test Plan is marked complete with specific verification steps, and Screenshots are referenced as provided in comments.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Merge Conflict Detection ✅ Passed ✅ No merge conflicts detected when merging into main

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch feat/credits-only-plans-ux

No actionable comments were generated in the recent review. 🎉

🧹 Recent nitpick comments
src/components/CreditsCta.vue (2)

54-57: Link text hidden on mobile — only the chevron arrow is visible.

On small screens, the "Manage your credit usage" text is hidden (hidden sm:inline), leaving only the chevron icon. Since the entire button is the click target and the title/description provide context, this works, but consider whether the link text should be visible on mobile for clarity — especially since this is the primary CTA for credits-only users.


34-34: Consider aligning with the project's azure color palette for consistency.

The coding guidelines ask to "mirror the color palette from src/styles/style.css when introducing new UI" (using the project's --color-secondary: #119eff`` azure). CreditsCta uses Tailwind's default blue-* utilities instead. While blue is semantically appropriate for an information banner and the codebase has inconsistent color palette usage elsewhere (e.g., DeploymentBanner also uses `blue-*`), standardizing to the project's defined secondary color would improve consistency with the design system guidelines.


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 and usage tips.

Copy link
Copy Markdown
Contributor

@coderabbitai coderabbitai Bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 4

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
src/components/CreditsCta.vue (1)

29-88: ⚠️ Potential issue | 🟠 Major

Make the banner a real interactive element (DaisyUI + keyboard support).

The clickable <div> isn’t keyboard-accessible and doesn’t use DaisyUI components. Consider switching to a <button> (or <router-link>) styled as a d-card so it’s semantic, accessible, and guideline-compliant.

♿ Suggested adjustment
-  <div
+  <button
     v-if="props.creditsOnly"
-    class="flex items-center w-full p-4 transition-all duration-200 border cursor-pointer bg-blue-50 dark:bg-blue-900/20 border-blue-200 dark:border-blue-800 hover:border-blue-300 dark:hover:border-blue-700 rounded-xl group"
+    type="button"
+    class="d-card flex items-center w-full p-4 transition-all duration-200 border cursor-pointer bg-blue-50 dark:bg-blue-900/20 border-blue-200 dark:border-blue-800 hover:border-blue-300 dark:hover:border-blue-700 rounded-xl group"
     `@click`="goToCredits"
   >
@@
-  </div>
+  </button>
@@
-  <div
+  <button
     v-else
-    class="flex items-center w-full p-4 transition-all duration-200 border cursor-pointer bg-gray-50 dark:bg-gray-900 border-gray-200 dark:border-gray-700 hover:border-blue-300 dark:hover:border-blue-700 rounded-xl group"
+    type="button"
+    class="d-card flex items-center w-full p-4 transition-all duration-200 border cursor-pointer bg-gray-50 dark:bg-gray-900 border-gray-200 dark:border-gray-700 hover:border-blue-300 dark:hover:border-blue-700 rounded-xl group"
     `@click`="goToCredits"
   >
@@
-  </div>
+  </button>

As per coding guidelines, "Use DaisyUI components (d-btn, d-input, d-card) for interactive elements in Vue components".

🤖 Fix all issues with AI agents
In `@messages/id.json`:
- Around line 496-498: The link label for the key "credits-only-info-link" uses
"pulsa" which is inconsistent with the file's "kredit" terminology; update the
string value for "credits-only-info-link" to replace "pulsa" with "kredit" so it
reads "Kelola penggunaan kredit Anda" to match the other keys
("credits-only-info-title", "credits-only-info-description").

In `@messages/it.json`:
- Around line 496-498: Update the three i18n keys to use informal singular and
an imperative CTA: change "credits-only-info-description" to a singular informal
phrase (e.g., "Non sei abbonato a nessun piano."), change
"credits-only-info-title" to a more natural singular-tone title (e.g., "Uso dei
crediti invece di un piano"), and change "credits-only-info-link" to an
imperative CTA (e.g., "Gestisci il credito") so the tone matches the rest of the
file; apply these replacements to the values of the keys
"credits-only-info-description", "credits-only-info-title", and
"credits-only-info-link".

In `@messages/ru.json`:
- Around line 496-498: The link string "credits-only-info-link" currently uses
singular "кредита"; update its value to use the plural form "кредитов" to match
other keys (e.g., "credits-only-info-description" and "credits-only-info-title")
— find the "credits-only-info-link" entry and replace "Управляйте использованием
кредита" with "Управляйте использованием кредитов".

In `@messages/zh-cn.json`:
- Around line 496-498: The link text for the "credits-only-info-link" key uses
“信贷” while other keys like "credits-only-info-description" and
"credits-only-info-title" use “积分”; update the value of "credits-only-info-link"
to use “积分” (e.g., change "管理您的信贷使用情况" to "管理您的积分使用情况") so terminology is
consistent across the file.
🧹 Nitpick comments (1)
messages/pl.json (1)

496-498: New Polish translation keys look good.

The three new credits-only-info-* keys are properly placed and the translations are accurate Polish. Minor stylistic note: credits-only-info-link uses the noun form "Zarządzanie wykorzystaniem kredytu" whereas other CTA links in this file (e.g., credits-flexibility-cta-link: "Dowiedz się więcej...") use imperative mood. Consider "Zarządzaj wykorzystaniem kredytu" for consistency, but this is not blocking.

Comment thread messages/id.json
Comment thread messages/it.json Outdated
Comment thread messages/ru.json
Comment thread messages/zh-cn.json
- Fix Indonesian: use 'kredit' instead of 'pulsa' for terminology consistency
- Fix Italian: use informal singular and imperative CTA form
- Fix Russian: use plural 'кредитов' for consistency
- Fix Chinese: use '积分' instead of '信贷' for consistency
- Fix Polish: use imperative mood for CTA link
- Improve accessibility: use <button> instead of <div> for clickable banners
@riderx riderx merged commit a337d51 into main Feb 14, 2026
12 of 14 checks passed
@riderx riderx deleted the feat/credits-only-plans-ux branch February 14, 2026 11:08
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