Skip to content

feat: select transaction pay token#17309

Merged
matthewwalsh0 merged 14 commits into
mainfrom
feat/pay-with-token-selection
Jul 23, 2025
Merged

feat: select transaction pay token#17309
matthewwalsh0 merged 14 commits into
mainfrom
feat/pay-with-token-selection

Conversation

@matthewwalsh0

@matthewwalsh0 matthewwalsh0 commented Jul 16, 2025

Copy link
Copy Markdown
Member

Description

Support selection of an ERC-20 payment token in the transaction confirmation.

New:

  • Add PayWithModal component as confirmations specific multi-chain token picker.
  • Add PayWithNetworkModal component as confirmations specific network picker.
  • Add TokenPill component to display selected token including chain badge.
  • Add useTransactionPayToken hook to abstract reading and setting selected token via Redux slice.
  • Add temporary PayWithRow to display selected token and trigger picker.
    • Requires MM_CONFIRMATION_INTENTS environment variable.

Updated:

  • Add transactionPayTokenById to confirmationMetrics slice to store selected token.
    • Slice will be renamed in separate PR to confirmation.
  • Add title prop to BridgeTokenSelectorBase component.
  • Add onPress prop to BridgeSourceNetworksBar component.
  • Add onApply prop to BridgeSourceNetworkSelector component.

Changelog

CHANGELOG entry: null

Related issues

Fixes: #5413

Manual testing steps

Screenshots/Recordings

Before

After

Token.Selection.mov
Token Modal Network Modal Token Modal

Pre-merge author checklist

Pre-merge reviewer checklist

  • I've manually tested the PR (e.g. pull and build branch, run the app, test code being changed).
  • I confirm that this PR addresses all acceptance criteria described in the ticket it closes and includes the necessary testing evidence such as recordings and or screenshots.

@matthewwalsh0 matthewwalsh0 force-pushed the feat/pay-with-token-selection branch from 38472f5 to e85016e Compare July 17, 2025 23:24
@matthewwalsh0 matthewwalsh0 added team-confirmations Push issues to confirmations team Run Smoke E2E labels Jul 18, 2025
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

Attention: Patch coverage is 86.07595% with 11 lines in your changes missing coverage. Please review.

Project coverage is 73.58%. Comparing base (9456964) to head (cf87f5e).
Report is 22 commits behind head on main.

Files with missing lines Patch % Lines
...ions/components/rows/pay-with-row/pay-with-row.tsx 0.00% 5 Missing ⚠️
...omponents/modals/pay-with-modal/pay-with-modal.tsx 86.20% 1 Missing and 3 partials ⚠️
...onfirmations/components/info/transfer/transfer.tsx 0.00% 0 Missing and 1 partial ⚠️
...ws/confirmations/hooks/transactions/usePayAsset.ts 88.88% 0 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #17309      +/-   ##
==========================================
+ Coverage   73.53%   73.58%   +0.05%     
==========================================
  Files        2824     2851      +27     
  Lines       62359    63415    +1056     
  Branches    10017    10338     +321     
==========================================
+ Hits        45858    46667     +809     
- Misses      13605    13745     +140     
- Partials     2896     3003     +107     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions

github-actions Bot commented Jul 18, 2025

Copy link
Copy Markdown
Contributor

https://bitrise.io/ Bitrise

❌❌❌ pr_smoke_e2e_pipeline failed on Bitrise! ❌❌❌

Commit hash: cf87f5eb516d54dc891110c8b2059a59039e453b
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/be565d76-cc39-48ee-b541-d6914572a41b

Note

  • You can rerun any failed steps by opening the Bitrise build, tapping Rebuild on the upper right then Rebuild unsuccessful Workflows
  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

Tip

  • Check the documentation if you have any doubts on how to understand the failure on bitrise

@matthewwalsh0 matthewwalsh0 marked this pull request as ready for review July 21, 2025 12:16
@matthewwalsh0 matthewwalsh0 requested review from a team as code owners July 21, 2025 12:16
@matthewwalsh0 matthewwalsh0 changed the title feat: select transaction pay asset feat: select transaction pay token Jul 21, 2025
cursor[bot]

This comment was marked as outdated.

@matthewwalsh0 matthewwalsh0 force-pushed the feat/pay-with-token-selection branch from 7c0792e to d233abe Compare July 23, 2025 09:30
cursor[bot]

This comment was marked as resolved.

@github-actions

github-actions Bot commented Jul 23, 2025

Copy link
Copy Markdown
Contributor

https://bitrise.io/ Bitrise

✅✅✅ pr_smoke_e2e_pipeline passed on Bitrise! ✅✅✅

Commit hash: d233abe
Build link: https://app.bitrise.io/app/be69d4368ee7e86d/pipelines/2287cb6c-880a-4765-bb2b-bc83f34fb225

Note

  • You can kick off another pr_smoke_e2e_pipeline on Bitrise by removing and re-applying the Run Smoke E2E label on the pull request

@sonarqubecloud

Copy link
Copy Markdown

@matthewwalsh0 matthewwalsh0 added the QA Passed QA testing has been completed and passed label Jul 23, 2025
Comment thread app/core/redux/slices/confirmationMetrics/index.ts
@matthewwalsh0 matthewwalsh0 enabled auto-merge July 23, 2025 12:08
@matthewwalsh0 matthewwalsh0 added this pull request to the merge queue Jul 23, 2025
Merged via the queue into main with commit c6d2c10 Jul 23, 2025
54 of 59 checks passed
@matthewwalsh0 matthewwalsh0 deleted the feat/pay-with-token-selection branch July 23, 2025 13:09
@github-actions github-actions Bot locked and limited conversation to collaborators Jul 23, 2025
@metamaskbot metamaskbot added the release-7.53.0 Issue or pull request that will be included in release 7.53.0 label Jul 23, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

QA Passed QA testing has been completed and passed release-7.53.0 Issue or pull request that will be included in release 7.53.0 team-confirmations Push issues to confirmations team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants