Skip to content

[PM-37804] feat: Confirm before leaving the app to Stripe checkout#6958

Merged
SaintPatrck merged 1 commit into
mainfrom
premium-upgrade/pm-37804-stripe-checkout-confirmation
May 20, 2026
Merged

[PM-37804] feat: Confirm before leaving the app to Stripe checkout#6958
SaintPatrck merged 1 commit into
mainfrom
premium-upgrade/pm-37804-stripe-checkout-confirmation

Conversation

@SaintPatrck
Copy link
Copy Markdown
Contributor

@SaintPatrck SaintPatrck commented May 20, 2026

🎟️ Tracking

https://bitwarden.atlassian.net/browse/PM-37804

📔 Objective

The Upgrade now CTA on the Free Premium plan view launched the Stripe checkout URL with no acknowledgement that the user was about to leave the app. Mirror the Manage Plan confirmation pattern: the button now opens a two-button dialog ("Continue to Stripe?" / "You'll go to Stripe's secure checkout to complete your purchase.") and only fetches the checkout URL when the user confirms, giving them a chance to back out without an unnecessary network call.

Also renames the existing stripe_checkout_footer string resource to mirror its value, matching the project convention for naming resources from their text.

📸 Screenshots

The Upgrade now CTA on the Free Premium plan view launched the Stripe checkout
URL with no acknowledgement that the user was about to leave the app. Mirror
the Manage Plan confirmation pattern: the button now opens a two-button dialog
("Continue to Stripe?" / "You'll go to Stripe's secure checkout to complete
your purchase.") and only fetches the checkout URL when the user confirms,
giving them a chance to back out without an unnecessary network call.

Also renames the existing stripe_checkout_footer string resource to mirror its
value, matching the project convention for naming resources from their text.
@SaintPatrck SaintPatrck added the ai-review-vnext Request a Claude code review using the vNext workflow label May 20, 2026
@github-actions github-actions Bot added app:password-manager Bitwarden Password Manager app context app:authenticator Bitwarden Authenticator app context t:feature Change Type - Feature Development labels May 20, 2026
@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 20, 2026

🤖 Bitwarden Claude Code Review

Overall Assessment: APPROVE

This PR adds a confirmation dialog before launching the Stripe checkout from the Free Premium plan view, mirroring the existing Manage Plan confirmation pattern in the same screen. The implementation reuses BitwardenTwoButtonDialog with rememberSaveable for state persistence, defers the network call until the user confirms, and renames stripe_checkout_footer to match the project's naming-from-content convention. Test coverage adds three new cases covering dialog display, confirm, and cancel paths — matching the structure of the existing ManagePlanButton tests.

Code Review Details

No findings. The dialog implementation is a direct mirror of the existing PremiumContent confirmation pattern (same file, lines 499 and 542-557), the new string follows the documented snake_case-from-content convention, and the localized stripe_checkout_footer entries will be cleaned up by Crowdin on its next sync — consistent with prior renames in this codebase (e.g., ask_to_add_loginask_to_add_item in #5758).

@codecov
Copy link
Copy Markdown

codecov Bot commented May 20, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 86.46%. Comparing base (31011b5) to head (16f68d0).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6958      +/-   ##
==========================================
+ Coverage   85.49%   86.46%   +0.96%     
==========================================
  Files        1023      870     -153     
  Lines       66231    63464    -2767     
  Branches     9308     9207     -101     
==========================================
- Hits        56623    54872    -1751     
+ Misses       6422     5432     -990     
+ Partials     3186     3160      -26     
Flag Coverage Δ
app-data 17.04% <0.00%> (+0.18%) ⬆️
app-ui-auth-tools 19.14% <0.00%> (-0.23%) ⬇️
app-ui-platform 16.43% <100.00%> (-0.51%) ⬇️
app-ui-vault 27.89% <0.00%> (-0.58%) ⬇️
authenticator 6.23% <0.00%> (-0.01%) ⬇️
lib-core-network-bridge 4.06% <0.00%> (-0.01%) ⬇️
lib-data-ui 1.15% <0.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@SaintPatrck SaintPatrck marked this pull request as ready for review May 20, 2026 22:03
@SaintPatrck SaintPatrck requested review from a team and david-livefront as code owners May 20, 2026 22:03
@SaintPatrck SaintPatrck enabled auto-merge May 20, 2026 22:10
@SaintPatrck SaintPatrck added this pull request to the merge queue May 20, 2026
Merged via the queue into main with commit 8f72c10 May 20, 2026
26 of 27 checks passed
@SaintPatrck SaintPatrck deleted the premium-upgrade/pm-37804-stripe-checkout-confirmation branch May 20, 2026 22:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai-review-vnext Request a Claude code review using the vNext workflow app:authenticator Bitwarden Authenticator app context app:password-manager Bitwarden Password Manager app context t:feature Change Type - Feature Development

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants