Every plain delegation shows the wrong confirmation:
Congrats! You've successfully migrated your stake to a new orchestrator.
TxConfirmedDialog/index.tsx:120 picks the copy from the recorded amount, which is correct in principle — a genuine "Move Delegated Stake" bonds zero:
Number(tx.inputData.amount) <= 0
? "...migrated your stake to a new orchestrator."
: "...delegated N LPT."
The amount it reads has already been cleared. onDelegate in components/DelegatingWidget/Delegate.tsx calls bondWrite(...) and then reset() → setAmount("") (components/DelegatingWidget/index.tsx:199) without waiting for the hash. useHandleTransaction's useEffect(..., [data]) later stores setLatestTransactionDetails(data, id, args) using the current args, by which point the amount is 0.
The hash can never arrive before reset() runs, so this is deterministic rather than a race.
Reproduction
Delegate any amount to an orchestrator and read the success dialog.
Fix
Capture the args when the transaction is submitted and hand those to useHandleTransaction, so the confirmation reflects what was sent.
Display only — the transaction itself is unaffected. unbond does not share the problem; Undelegate.tsx never calls reset().
Related
Every plain delegation shows the wrong confirmation:
TxConfirmedDialog/index.tsx:120picks the copy from the recorded amount, which is correct in principle — a genuine "Move Delegated Stake" bonds zero:The amount it reads has already been cleared.
onDelegateincomponents/DelegatingWidget/Delegate.tsxcallsbondWrite(...)and thenreset()→setAmount("")(components/DelegatingWidget/index.tsx:199) without waiting for the hash.useHandleTransaction'suseEffect(..., [data])later storessetLatestTransactionDetails(data, id, args)using the current args, by which point the amount is0.The hash can never arrive before
reset()runs, so this is deterministic rather than a race.Reproduction
Delegate any amount to an orchestrator and read the success dialog.
Fix
Capture the args when the transaction is submitted and hand those to
useHandleTransaction, so the confirmation reflects what was sent.Display only — the transaction itself is unaffected.
unbonddoes not share the problem;Undelegate.tsxnever callsreset().Related