Skip to content

Add zero-amount send warning for EVM chains#6058

Open
j0ntz wants to merge 2 commits into
developfrom
jon/evm-zero-send-warning
Open

Add zero-amount send warning for EVM chains#6058
j0ntz wants to merge 2 commits into
developfrom
jon/evm-zero-send-warning

Conversation

@j0ntz

@j0ntz j0ntz commented Jun 25, 2026

Copy link
Copy Markdown
Contributor

CHANGELOG

Does this branch warrant an entry to the CHANGELOG?

  • Yes
  • No

Dependencies

none

Requirements

If you have made any visual changes to the GUI. Make sure you have:

  • Tested on iOS device
  • Tested on Android device
  • Tested on small-screen device (iPod Touch)
  • Tested on large-screen device (tablet)

Description

EVM chains (Ethereum and other allowZeroTx chains) let you broadcast a zero-amount transaction, which still spends gas. Users have accidentally sent zero-amount transactions and wasted gas (multiple Zendesk tickets).

This adds a confirmation warning when the user slides to confirm a send whose amount is zero on an EVM wallet or token. The warning explains gas is still charged and offers Continue / Cancel. Cancel resets the slider and aborts; Continue proceeds with the normal sign and broadcast. The ability to send a zero amount is preserved, the user is just asked to confirm.

Implementation:

  • SendScene2.tsx handleSliderComplete: before signing/broadcasting, if isEvmWallet(coreWallet) and every spend target amount is zero, show a ButtonsModal confirmation and bail on cancel.
  • Detection reuses the existing isEvmWallet helper (walletConnectV2ChainId.namespace === 'eip155'), so it covers EVM coin and token sends. Non-EVM chains already disable the slider for zero amounts and are unaffected.
  • Two new en_US.ts strings for the modal title and message.
  • Added a confirmSliderThumb testID to SafeSlider so the maestro confirm-slider selector resolves (separate commit).

Asana: https://app.asana.com/0/1215088146871429/1206403488324344

Tested on the iOS simulator: drove a zero-amount ETH send from a funded Arbitrum (EVM) wallet to a valid address, slid to confirm, and confirmed the "Send Zero Amount?" warning modal appears before any broadcast. Cancel dismissed the modal and reset the slider with no transaction sent. Screenshots below.


Note

Low Risk
Targeted send-flow UX change on EVM only; cancel path aborts before signing with no change to non-EVM behavior.

Overview
Adds a Send Zero Amount? confirmation when users slide to confirm an EVM send whose spend targets are all zero, because those txs still consume gas while non-EVM chains usually block zero amounts on the slider.

In SendScene2, handleSliderComplete now checks isEvmWallet and zero nativeAmount on every target, shows a ButtonsModal with new copy, resets the slider on cancel, and only then continues to sign/broadcast. SafeSlider gets testID="confirmSliderThumb" for Maestro; snapshots and en_US strings were updated.

Reviewed by Cursor Bugbot for commit 74c96e0. Bugbot is set up for automated code reviews on this repo. Configure here.

j0ntz added 2 commits June 24, 2026 16:55
Sending a zero amount on Ethereum and other EVM chains is allowed but
still spends gas, and users have accidentally done so. Confirm the
user's intent with a warning modal before broadcasting a zero-amount
send on any EVM coin or token. Other chains are unaffected since they
already disable the slider for zero amounts.
@j0ntz

j0ntz commented Jun 25, 2026

Copy link
Copy Markdown
Contributor Author

📸 Test evidence (iOS sim — zero-amount EVM send)

agent proof 1206403488324344 01 zero send ready

agent proof 1206403488324344 01 zero send ready

agent proof 1206403488324344 02 zero send warning modal

agent proof 1206403488324344 02 zero send warning modal

Captured by the agent's in-app test run (build-and-test).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant