Skip to content

feat(billing): Redesign the Seer auto-reload modal - #130242

Merged
billyvg merged 2 commits into
masterfrom
billyvg/feat-seer-auto-reload-modal
Nov 6, 2026
Merged

billyvg merged 2 commits into
masterfrom
billyvg/feat-seer-auto-reload-modal

Conversation

@billyvg

@billyvg billyvg commented Nov 6, 2026 •

Copy link
Copy Markdown
Member

Why?

The Seer auto-reload modal didn't match the latest billing design. It asked for amounts in credits behind an on/off switch. The design asks for dollar amounts, shows what's due when auto-reload is turned on, and confirms before turning it off.

Follows:

How?

Rebuilds the modal to the design's three states: turning on, editing, and confirming the turn-off. It uses the same auto-reload API as before. Tax isn't known before checkout yet, so the due-now summary and the confirm button show the reload amount "+ tax" instead of a total.

Screenshots

Local dev server with mocked wallet responses. Before is master after #130241.

Before After
Turning on Turning on, before Turning on, after
Editing Editing, before Editing, after

Turning off is new, so it has no before shot:

Turn off auto-reload confirmation

Picking a preset and turning auto-reload on, which updates the card:

after-modal-turn-on-flow.webm

Generated with Claude Code

@billyvg
billyvg requested a review from a team as a code owner November 6, 2026 14:04
@github-actions github-actions Bot added the Scope: Frontend Automatically applied to PRs that change frontend components label Nov 6, 2026

@cursor cursor Bot left a comment

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.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit 58fe429. Configure here.

Base automatically changed from billyvg/feat-seer-card-design to master November 6, 2026 19:12
billyvg and others added 2 commits November 6, 2026 14:13
Rebuild the modal to the auto-reload design: dollar presets and inputs
that show their credit equivalents, a due-now summary when turning
auto-reload on, and a confirmation step before turning it off.

Tax isn't known before checkout yet, so the summary and the confirm
button say "+ tax" instead of a total.

Co-Authored-By: Claude <[email protected]>
The $150 preset is larger than the default $75 daily usage limit, and the
API rejects a daily limit that can't cover one reload, so turning
auto-reload on with that preset failed.

Co-Authored-By: Claude <[email protected]>
@sentry

sentry Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Sentry Snapshot Testing

Name Added Removed Changed Renamed Unchanged Skipped Status
sentry-frontend
sentry-frontend
- - - - - - ✅ 798 uploaded

Base commit 30598f5e9bc3000ed026fbd2db61624c71074d0d did not produce snapshots to compare against. Did its snapshot job fail? Try rebasing this branch on a commit with a successful snapshot job.

⚙️ sentry-frontend Snapshot Settings

@billyvg
billyvg merged commit 1897e88 into master Nov 6, 2026
79 of 80 checks passed
@billyvg
billyvg deleted the billyvg/feat-seer-auto-reload-modal branch November 6, 2026 19:33
billyvg added a commit that referenced this pull request Nov 10, 2026
)

### Why?

#130242 already brought the Seer auto-reload modal and card to the new
design, so this PR is now rebased down to what that one left out.

After a save, the modal refreshed the auto-reload settings but not the
wallet balance. After turning auto-reload on and paying for a reload,
the Seer card kept showing the old balance.

### How?

After a save, the modal now refreshes the wallet balance along with the
auto-reload settings. The card test checks that the new balance shows
once auto-reload is on.

The API doesn't buy a reload when auto-reload is turned on yet. A task
checks every five minutes and buys one only when the balance is below
the threshold. Once turning on buys a reload, the card will show it
right away.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude Opus 5.5 <[email protected]>
billyvg added a commit that referenced this pull request Nov 10, 2026
…CTA (#129552)

This changes the CTA "Configure auto-reload" button from redirecting to
billing to opening the auto top up modal.

## Slop

For billing members, "Turn on auto-reload" in the out-of-credits CTA
("Configure auto-reload" when it's already on) now opens the billing
page's Seer auto-reload modal in place instead of linking to the billing
page, so they can fix credits without leaving the chat they were in.
After a save it re-runs every Seer credit check and the CTA's
auto-reload state, so gated buttons come back and the copy updates
without a reload.

It opens the billing page's existing auto-reload modal (redesigned in
#130242) rather than forking it, so the billing page and the CTA stay in
sync. The modal now loads the Seer wallet itself, since the CTA has no
wallet card behind it, so the wallet card and the CTA both open it with
`openSeerAutoTopUpModal({organization})`; on the billing page it shows
straight from the card's cache. It shows a load error with retry if the
wallet fails to load. Credit pricing only comes back for billing roles,
so a missing price counts as a load error, as it does on the wallet
card.

**Not in this PR: a one-time "add credits" purchase.** The ticket asks
for "add credits or turn on auto top-up", but the UI has no purchase API
yet (the ticket says to check with billing), so this covers auto-reload
only. Saving auto-reload doesn't buy credits in that request either: the
endpoint only stores the settings, and billing charges the reload on its
next scheduled check, every 5 minutes. So an org at 0 credits stays
blocked for up to 5 minutes after turning it on, even though the modal
shows the reload as "Due now". The gate lifts on the first credit check
after the charge, on window focus or the next mount.

The new `Seer auto-reload modal` story opens the modal with your org's
real wallet. The CTA story's "For the signed-in viewer" section renders
the real getsentry CTA, whose button opens it.

| Location | Screenshot |
| --- | --- |
| Seer Agent › chat, out of credits | [![Seer Agent › chat, out of
credits](https://github.com/user-attachments/assets/aa3cb216-afd8-4c41-be94-7ae714588acf)](https://github.com/user-attachments/assets/aa3cb216-afd8-4c41-be94-7ae714588acf)
|
| Seer Agent › chat › Turn on auto-reload | [![Seer Agent › chat › Turn
on
auto-reload](https://github.com/user-attachments/assets/6a5a38fe-d5d5-46a2-9556-87e031156d6f)](https://github.com/user-attachments/assets/6a5a38fe-d5d5-46a2-9556-87e031156d6f)
|
| Seer Agent › chat, auto-reload already on › Configure auto-reload |
[![Seer Agent › chat, auto-reload already on › Configure
auto-reload](https://github.com/user-attachments/assets/664712fb-01ac-402d-8757-b4fcbf123d5a)](https://github.com/user-attachments/assets/664712fb-01ac-402d-8757-b4fcbf123d5a)
|
| Seer Agent › chat › Turn on auto-reload, wallet fails to load |
[![Seer Agent › chat › Turn on auto-reload, wallet fails to
load](https://github.com/user-attachments/assets/4f1c89cf-ddfd-4e22-b324-d8441b0947cd)](https://github.com/user-attachments/assets/4f1c89cf-ddfd-4e22-b324-d8441b0947cd)
|

Fixes CW-2353

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 5.5 <[email protected]>
billyvg added a commit that referenced this pull request Nov 11, 2026
…130706)

### Why?

The Seer auto-reload modal no longer matched the latest billing design.
The design renames it to auto-load, offers $15, $25, $50 and custom
amounts as cards with their credit counts, and says how many purchased
credits remain when turning it off.

Follows:
- #130242

### How?

Rebuilds the amount picker on radio `ToggleCard`s, with the dollar input
shown only for a custom amount, and widens the modal so its content is
as wide as the design's. The daily usage limit no longer rises to cover
the chosen amount, since the API stopped requiring that. As before, due
now and the pay button only show when the balance is below the auto-load
threshold, and tax still isn't known before checkout, so due now shows
the amount plus tax rather than a total.

### Screenshots

Local dev server with mocked wallet responses. The turning-on states
have a balance below the auto-load threshold, so a load is due. Before
is `master`.

| | Before | After |
|---|---|---|
| Turning on | ![Before: turning
on](https://github.com/user-attachments/assets/20dfb343-7f61-4e7b-b4be-e29d65ab2196)
| ![After: turning
on](https://github.com/user-attachments/assets/ab27eb58-181e-4c88-90df-a975d94a396b)
|
| Custom amount | ![Before: custom
amount](https://github.com/user-attachments/assets/9df7ab56-2189-4f3b-beb7-430a755880eb)
| ![After: custom
amount](https://github.com/user-attachments/assets/c6d34ae7-f1cf-4b91-a1da-4927e6a6ce1e)
|
| Editing | ![Before:
editing](https://github.com/user-attachments/assets/4d8135ae-9395-4d20-bb38-fcd55fe1fcfc)
| ![After:
editing](https://github.com/user-attachments/assets/50d433ad-7028-4141-8385-394fca0a84f6)
|
| Turning off | ![Before: turning
off](https://github.com/user-attachments/assets/50feefa2-2284-492f-857e-929cbf05ca78)
| ![After: turning
off](https://github.com/user-attachments/assets/81431349-5661-4c5d-b774-2efd774fa140)
|

<sub>Generated with Claude Code</sub>

Co-authored-by: Claude Opus 5.5 <[email protected]>

This branch was successfully deployed

1 active deployment
Preview — 0125a9a8 Deployed Nov 6, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Scope: Frontend Automatically applied to PRs that change frontend components

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants