feat: show red warning on confirm-tx for addresses with zero tx history #101
No reviewers
Labels
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: sneak/AutistMask#101
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "issue-82-new-address-warning"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Closes #82
Adds a Blockscout-backed check on the confirm-tx screen that warns users when the destination address has zero transaction history (no transactions and no token transfers). The warning is displayed in red with dashed border, consistent with the existing scam-address warning style.
Changes:
src/shared/transactions.js: AddedhasZeroTxHistory()— queries Blockscout/addresses/{addr}/countersendpoint, returns true if bothtransactions_countandtoken_transfers_countare zero. Fail-open on errors.src/popup/views/confirmTx.js: Added asynccheckNewAddress()called fromshow(). Appends a red warning to the warnings container if the address has no history.docker build .passes (tests + lint + build).Closing as duplicate of #98 which already addresses issue #82.
Implementation complete. Changes:
src/shared/transactions.js: AddedhasZeroTxHistory(address, blockscoutUrl)— queries Blockscout/addresses/{addr}/countersendpoint, returnstrueif bothtransactions_countandtoken_transfers_countare zero. Fail-open on errors.src/popup/views/confirmTx.js: Added asynccheckNewAddress()called fromshow(). Appends a red warning (red text, red dashed border) to the warnings container if the destination has no history. Includes staleness guard (pendingTx !== txInfo).docker build .passes (tests, lint, build).Pull request closed