Wallet pending savings withdrawals: Cancel on one row opens every row's dialog and cancels the last withdrawal
Problem
apps/wallet/feature/transfers-page/pending-savings-withdrawals.tsx: one openCancelTransfer boolean drives every row's cancel <Dialog>. With two or more pending savings withdrawals, clicking Cancel on row 1 opens every row's dialog. The topmost is the last row's, so confirming broadcasts cancel_transfer_from_savings for the last withdrawal's request_id, not the clicked one. The dialog shows that last row's text, so an attentive user might notice, but the action doesn't match the click. This predates #1391 (closed)/#1397 (closed) and was found in the #1397 (closed) review.
Expected
- Each row's Cancel opens a prompt for that row only, e.g. keep the selected
request_id(or row) in state, or render a single dialog bound to the selected withdrawal. - Confirming cancels exactly that withdrawal.
- Keep #1397 (closed)'s behaviour: the open state resets when
canCancelturns false, so the prompt stays closed when Cancel comes back.
Acceptance
A wallet fixture spec with two pending withdrawals (different request_ids): click Cancel on the first, confirm, and assert the broadcast cancel_transfer_from_savings carries the first withdrawal's request_id, and that only one dialog is open. It must fail on the current code.