feat: show red warning on confirm-tx when recipient has zero transaction history #93

Closed
clawbot wants to merge 1 commits from issue-82-new-address-warning into main
Collaborator

Closes #82

When confirming a transaction, asynchronously checks the recipient address via Blockscout API. If the address has zero transactions and zero token transfers, displays a prominent red warning banner advising the user to double-check the address.

Also updates existing warning styling to use red borders/text for better visibility.

  • Uses Blockscout /addresses/{addr} endpoint to check transactions_count and token_transfers_count
  • Appends warning to existing warnings array and re-renders
  • Failure is silent (best-effort check)
Closes #82 When confirming a transaction, asynchronously checks the recipient address via Blockscout API. If the address has zero transactions and zero token transfers, displays a prominent red warning banner advising the user to double-check the address. Also updates existing warning styling to use red borders/text for better visibility. - Uses Blockscout `/addresses/{addr}` endpoint to check `transactions_count` and `token_transfers_count` - Appends warning to existing warnings array and re-renders - Failure is silent (best-effort check)
clawbot self-assigned this 2026-02-28 22:31:50 +01:00
clawbot added 1 commit 2026-02-28 22:31:51 +01:00
feat: show red warning on confirm-tx when recipient has zero transaction history
All checks were successful
check / check (push) Successful in 9s
e557def559
Closes #82

When confirming a transaction, asynchronously checks the recipient
address via Blockscout API. If the address has zero transactions and
zero token transfers, displays a prominent red warning banner advising
the user to double-check the address.

Also updates existing warning styling to use red borders/text for
better visibility.
clawbot added the
bot
needs-review
labels 2026-02-28 22:31:59 +01:00
Author
Collaborator

Implementation complete. Changes:

  • Added async checkRecipientHistory() that queries Blockscout /addresses/{addr} endpoint after the confirm-tx view loads
  • If transactions_count + token_transfers_count == 0, appends a red warning: "This address has ZERO transaction history. It may be incorrect. Double-check before sending."
  • Updated all warning styling to use red borders and text (border-red-500 text-red-500) for better visibility
  • Check is best-effort; failures are silently logged

docker build . passes (tests + lint + build).

Implementation complete. Changes: - Added async `checkRecipientHistory()` that queries Blockscout `/addresses/{addr}` endpoint after the confirm-tx view loads - If `transactions_count + token_transfers_count == 0`, appends a red warning: "This address has ZERO transaction history. It may be incorrect. Double-check before sending." - Updated all warning styling to use red borders and text (`border-red-500 text-red-500`) for better visibility - Check is best-effort; failures are silently logged `docker build .` passes (tests + lint + build).
clawbot removed their assignment 2026-02-28 22:32:11 +01:00
clawbot self-assigned this 2026-02-28 22:45:39 +01:00
clawbot added
merge-ready
and removed
needs-review
bot
labels 2026-02-28 22:46:23 +01:00
clawbot removed their assignment 2026-02-28 22:46:24 +01:00
sneak was assigned by clawbot 2026-02-28 22:46:24 +01:00
Author
Collaborator

Review: PASS

Code review of the diff looks clean:

  • Correctly queries Blockscout /addresses/{addr} endpoint for transactions_count + token_transfers_count
  • Shows red warning banner when both are zero — matches #82 requirements
  • Silent failure on API error (best-effort) — good
  • state.blockscoutUrl fallback to DEFAULT_BLOCKSCOUT_URL allows per-network override
  • Warning styling updated to red (border-red-500, text-red-500) with ⚠ emoji
  • No linter/config changes
  • docker build . passes

Marked merge-ready and assigned to @sneak for merge.

**Review: ✅ PASS** Code review of the diff looks clean: - Correctly queries Blockscout `/addresses/{addr}` endpoint for `transactions_count` + `token_transfers_count` - Shows red warning banner when both are zero — matches #82 requirements - Silent failure on API error (best-effort) — good - `state.blockscoutUrl` fallback to `DEFAULT_BLOCKSCOUT_URL` allows per-network override - Warning styling updated to red (`border-red-500`, `text-red-500`) with ⚠ emoji - No linter/config changes - `docker build .` passes Marked `merge-ready` and assigned to @sneak for merge.
Owner

dupe #98

dupe #98
sneak closed this pull request 2026-02-28 22:59:16 +01:00
sneak deleted branch issue-82-new-address-warning 2026-02-28 22:59:23 +01:00
All checks were successful
check / check (push) Successful in 9s
Required
Details

Pull request closed

Sign in to join this conversation.
No reviewers
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: sneak/AutistMask#93
No description provided.