Skip to content

fix(swap): default token output to native gas asset; collapse EVM summary#345

Merged
BitHighlander merged 1 commit into
developfrom
fix/swap-token-output-default
Jul 12, 2026
Merged

fix(swap): default token output to native gas asset; collapse EVM summary#345
BitHighlander merged 1 commit into
developfrom
fix/swap-token-output-default

Conversation

@BitHighlander

Copy link
Copy Markdown
Collaborator

Split out of #342 (was bundled under the clearsign branch).

Changes

  • Default output to native gas asset for a TOKEN input. Opening swap from a token page (e.g. USDT mainnet) no longer lands on a blank output — it defaults to the input chain's native asset (ETH). Native inputs keep their own DEFAULT_OUTPUT. Runs once assets load (the initialFromAsset fast-path sets fromAsset before assets arrive, so it can't be inline).
  • Collapse the EVM summary into a <details>/<summary> accordion — the payload status stays visible in the summary row; the detail body is opt-in.
  • Kill search autocorrect/autocomplete on the asset picker input (autoComplete/autoCorrect/autoCapitalize=off, spellCheck=false).

Test

  • Open swap from a token page → output pre-fills native gas asset
  • EVM summary expands/collapses; status text still shown collapsed

…mary; kill search autocorrect

- Token input now defaults the output to its chain's native gas asset
  (USDT mainnet -> ETH) instead of a blank output. Only fills an empty
  output, never overrides a user pick; covers both the token-page fast
  path and the CAIP-match path.
- EVM summary is now a collapsed-by-default <details> accordion (matches
  the other payload sections); 'payload ready' status stays in the header.
- Asset search input: autoComplete/autoCorrect/autoCapitalize=off +
  spellCheck=false so 'USDT' isn't re-corrected into a scam-token match.
@BitHighlander BitHighlander merged commit b0bff8e into develop Jul 12, 2026
1 check passed
@BitHighlander BitHighlander deleted the fix/swap-token-output-default branch July 12, 2026 02:15
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