Skip to content

fix(frontend): money confirms state what is bought and how much - #781

Merged
cristim merged 5 commits into
mainfrom
fix/ux-money-confirms-v2
Oct 9, 2026
Merged

cristim merged 5 commits into
mainfrom
fix/ux-money-confirms-v2

Conversation

@cristim

@cristim cristim commented Oct 9, 2026

Copy link
Copy Markdown
Member

Supersedes #764

#764 was stacked on #763's branch (fix/ux-confirm-dialogs). #763 was squash-merged to main as 2360338, so #764's branch still carries #763's pre-squash commits and is BLOCKED. A force-push is not allowed, so this PR replays #764's own five commits onto current main (cherry-pick, no force-push). Intent and content are unchanged; nothing was added.

Commits (original messages, in order)

  • 17b39ed (was db11d3d) fix(frontend): money confirms state what is bought and how much
  • 919881d (was 0857a56) fix(frontend): keep the exact offering id in the RI exchange confirm
  • e783e1c (was fc4c1c2) fix(frontend): label approval-path amounts and flag unreported monthly fees
  • d015b93 (was 108fddb) test(frontend): e2e asserts instance type and offering id in the exchange confirm
  • 27d5801 (was 7d66c1a) fix(frontend): recognise the Azure upfront and monthly payment spellings

Conflict resolutions: none; all five cherry-picks applied cleanly.

Equivalence

git diff origin/fix/ux-confirm-dialogs origin/fix/ux-money-confirms (#764 vs its base) and git diff origin/main HEAD (this PR) are identical apart from index hash lines (632 lines each, no differing hunks).

What

Original description from #764: shared commitmentSummary.ts stat band and commitment lines; Execute now, Run now and RI exchange confirms state what is bought and how much (Total over term shows "Not reported" instead of a fake $0).

Refs #707, #709, #701, #711.

Verification (frontend/, on this head)

🤖 Generated with Claude Code

cristim and others added 5 commits October 9, 2026 15:02
Execute now, Run now and the RI exchange execute confirm now show a shared
stat band (charged today, monthly, total over term) plus the commitment
lines with account and region, focus Cancel first, and Run now ignores a
second click while its dialog or request is open. The RI exchange confirm
names source and target instance types instead of offering UUIDs and shows
the hourly price change from the quote.

Refs #707, #709, #701, #711

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The confirm shows the instance type first and the offering id next to it,
so the exact target stays verifiable.

Refs #709

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…y fees

The approval confirm shows "Upfront on approval" instead of "Charged today",
since nothing is charged until the approver acts. A line that is not all
upfront with no monthly figure says monthly fees apply. The exchange price
change names its currency.

Refs #707, #709

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
…ange confirm

Refs #709

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Refs #707

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
@cristim cristim added priority/p2 Backlog-worthy triaged Item has been triaged severity/high Significant harm urgency/this-quarter Within the quarter impact/few Limited audience impact/many Affects most users effort/s Hours effort/m Days type/bug Defect labels Oct 9, 2026
@coderabbitai

coderabbitai Bot commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

  • Run on-demand review

This review includes 10 billable files and costs up to $2.50.

  • Ask an admin to make reviews automatic

Open in CodeRabbit

Reviews can continue after your included limit without a manual trigger. An admin must approve usage-based billing.

Or wait 46 minutes for your next included review.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available. Your 86 included PR review attempts over the past 7 days set your current allowance at 1 review per hour.

Learn how review limits work.

Review configuration:

⚙️ Run configuration
  • Configuration used: Repository: LeanerCloud/cloud-commitments-platform/.coderabbit.yaml
  • Review profile: CHILL
  • Plan: Essentials
  • Run ID: de98d275-751f-4f8c-89ad-08b62109b547

📥 Commits

Reviewing files that changed from the base of the PR and between 6f5a618 and 27d5801.


📒 Files selected for processing (10)
  • frontend/src/__tests__/commitmentSummary.test.ts
  • frontend/src/__tests__/plans.test.ts
  • frontend/src/__tests__/purchase-modal-submit.test.ts
  • frontend/src/__tests__/riexchange.test.ts
  • frontend/src/app.ts
  • frontend/src/commitmentSummary.ts
  • frontend/src/plans.ts
  • frontend/src/riexchange.ts
  • frontend/src/styles/components.css
  • frontend/tests-e2e/ri-exchange-confirmation.spec.ts


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

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

@cristim

cristim commented Oct 9, 2026

Copy link
Copy Markdown
Member Author

Delta review (cloud-commitments-coordinator subagent): equivalence to #764 @7d66c1a9

APPROVE at 27d5801.

  1. Parent chain: merge-base with origin/main is 16aec29 (ancestor of origin/main, fix(server): wait for background DB init before returning from shutdown #691). fix(frontend): money confirms state what is bought and how much #781 adds exactly 5 commits; subjects match d7fb436..7d66c1a one-to-one (db11d3d, 0857a56, fc4c1c2, 108fddb, 7d66c1a).
  2. Patch equivalence: git diff d7fb436f 7d66c1a9 and git diff 16aec294 27d58012, index lines stripped, are both 622 lines and diff reports no difference (10 files).
  3. Main overlap (e5ac75d..16aec29 vs the 10 files): plans.ts, plans.test.ts, ri-exchange-confirmation.spec.ts. The spec and the confirmDialog part of plans.* are fix(frontend): confirm dialog focuses the safe action and is accessible #763's own squash (2360338, no diff vs d7fb436 for the spec). Real new overlap is fix(plans): say that cancelling a scheduled purchase also disables its plan #770 (225ad35), which edits the plans.ts "disable" case dialog copy and its test; fix(frontend): money confirms state what is bought and how much #764 edits the "run" case (new runPlannedPurchaseNow, import). Different hunks and behaviours, cherry-pick clean; fix(plans): point plan-step refusal messages at #631 #768 touches only plans.test.ts text. No semantic interaction.
  4. Approval: rv-ux-visual round 3 on fix(frontend): money confirms state what is bought and how much #764 is headed "PR fix(frontend): money confirms state what is bought and how much #764 at 7d66c1a", "Verdict: approved". It notes green CI was still open then, so CI on 27d5801 and the repo review gate (verdict, SHA, local verification recorded on fix(frontend): money confirms state what is bought and how much #781) still apply. I did not run jest/e2e here.

@cristim

cristim commented Oct 9, 2026

Copy link
Copy Markdown
Member Author

Independent review (rv-ux-visual): PR #781 at 27d5801273d220e0def606141c8f4c82dbc213a8

Verdict: approved. This is #764 replayed onto main, and I approved #764 at 7d66c1a after three rounds. CI status at this SHA is below.

CI at this SHA: 26/26 green, including Build frontend (jest) and Playwright Chromium.

Housekeeping: #764 can be closed as superseded by this PR once it merges (or now).

@cristim
cristim merged commit 6248db2 into main Oct 9, 2026
27 checks passed
@cristim

cristim commented Oct 9, 2026

Copy link
Copy Markdown
Member Author

Merged as 6248db2 (squash, match-head 27d5801). Gate: rv-ux-visual round-3 approval of #764 at 7d66c1a carried over; equivalence review at 27d5801 found diffs identical (comment 6081466742). CI 27/27 green, CLEAN/MERGEABLE. Local at 27d5801 (git archive): npm ci 0, tsc --noEmit 0, npm test --silent 0 (3168 passed, 1 skipped), npm run lint 0 (0 errors, 125 warnings).

IAmJSD added a commit that referenced this pull request Oct 24, 2026
…e approve and quote (#1363)

The Execute confirm already names instance types and the hourly price
change (#781), but two money surfaces still showed the opaque view: the
quote summary listed raw source and target hourly prices with no delta,
and the Approve confirm in exchange history led with the target offering
UUID as one run-on sentence. The quote summary now adds an Hourly Price
Change row, and the Approve confirm uses the same labeled lines as
Execute (Exchange: 2 x m5.large (ri ids), For: 1 x m5.xlarge (offering
id)), so the user can see what an irreversible exchange swaps before
committing.

The confirm body builders move to riexchange-confirm.ts so the Execute
and Approve dialogs share one formatter and riexchange.ts shrinks. The
two openExchangeModal describes now re-seed listTargetOfferings, since a
resetAllMocks elsewhere in the file broke them under --randomize.

Refs #709

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
IAmJSD added a commit that referenced this pull request Oct 24, 2026
The Execute now and Run now confirms already state what is bought and how
much (#781), but the bulk (fan-out) "Send N bulk purchases for approval?"
confirm still said only how many requests and emails would go out. It now
uses the same commitment summary as the single-purchase confirm: the
combined upfront on approval, monthly and total over term across every
bucket, one line per commitment with account and region, and a confirm
button that names the upfront amount. The rec-to-summary-line mapping is
shared by both paths.

Refs #707

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

effort/m Days effort/s Hours impact/few Limited audience impact/many Affects most users priority/p2 Backlog-worthy severity/high Significant harm triaged Item has been triaged type/bug Defect urgency/this-quarter Within the quarter

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant