feat: gas fee token option - #7123
Merged
Merged
Conversation
Member
Author
|
@metamaskbot publish-preview |
Contributor
|
Preview builds have been published. See these instructions for more information about preview builds. Expand for full list of packages and versions. |
matthewwalsh0
force-pushed
the
feat/relay-transactions
branch
2 times, most recently
from
November 12, 2025 12:32
1d4c565 to
bba0dee
Compare
matthewwalsh0
force-pushed
the
feat/gas-fee-token-option
branch
from
November 12, 2025 14:48
9733480 to
b7df144
Compare
matthewwalsh0
marked this pull request as ready for review
November 12, 2025 16:38
matthewwalsh0
enabled auto-merge (squash)
November 12, 2025 16:49
matthewwalsh0
force-pushed
the
feat/gas-fee-token-option
branch
from
November 12, 2025 16:49
2ffc7e8 to
27af205
Compare
vinistevam
approved these changes
Nov 13, 2025
matthewwalsh0
force-pushed
the
feat/gas-fee-token-option
branch
from
November 13, 2025 09:14
27af205 to
f44e910
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Explanation
Support providing
gasFeeTokenwhen adding a transaction or transaction batch.References
Related to #6173
Checklist
Note
Adds optional gas fee token to single/batch transactions, pre-publish validation that auto-toggles token use based on native balance, and supporting balance utilities.
addTransaction/addTransactionBatch: accept optionalgasFeeToken.TransactionMeta: addselectedGasFeeTokenandisGasFeeTokenIgnoredIfBalance; initialised from options.utils/batch.ts): plumbsgasFeeTokenthrough toaddTransaction.checkGasFeeTokenBeforePublishinutils/gas-fee-tokens.ts:selectedGasFeeTokenand disablesisExternalSign.TransactionController#approveTransaction.#getGasFeeTokenshelper inTransactionControllerand reused in simulation updates.utils/balance.ts:getNativeBalance,isNativeBalanceSufficientForGas(usesbignumber.js).utils/balance-changes.ts: now usesgetNativeBalanceinstead of raweth_getBalance.bignumber.js.Written by Cursor Bugbot for commit f44e910. This will update automatically on new commits. Configure here.