Page MenuHomePhabricator

[Cashtab] Show total send amount in modal for one-to-many send txs
ClosedPublic

Authored by bytesofman on Sep 13 2023, 18:38.

Details

Summary

T2801

Show total amount of XEC user is about to send in a one-to-many tx in modal

Test Plan

npm test

Send a one-to-many tx with "Send Confirmations" enabled in settings. Verify total and formatting.

Diff Detail

Repository
rABC Bitcoin ABC
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

cashtab/src/utils/cashMethods.js
558 ↗(On Diff #42179)

we can't use parseXecSendValue bc it is customized for tx creation and not rendering a string ... throws errors that crash the UI.

parseXecSendValue is also a dumb function that should be deprecated for other reasons, task open T3286

Improve function documentation

actually think it makes sense to deprecate parseXecSendValue in this diff as well

nm better to stack it

emack requested changes to this revision.Sep 14 2023, 02:30
emack added a subscriber: emack.

image.png (296×558 px, 36 KB)

  1. 17.7 XEC total is being rounded down to 17, should be displayed as is up to the 2 decimal points.
  2. Minor nit, can use a newline before displaying the addresses.
This revision now requires changes to proceed.Sep 14 2023, 02:30

fix bug with decimal calcs, formatting improvements

This revision is now accepted and ready to land.Sep 14 2023, 22:44