Conversation
…nd network configuration
…ferencedCurrency hook
…tamask-extension into vs/speedup-cancel-ui
…tamask-extension into vs/speedup-cancel-ui
…tamask-extension into vs/speedup-cancel-ui
…context - Introduced `useCancelSpeedupGasState` to manage effective transaction state and actions for cancel/speedup. - Added `useCancelSpeedupInitialGas` to handle initial gas estimation logic when the cancel/speedup modal is opened. - Refactored gas fee modal context to support transaction meta and edit gas modes. - Updated `GasFeesSection` to utilize new hooks for fee calculations. - Improved modal components to handle gas fee editing more effectively. - Added optional Dapp swap context for better integration in various flows. - Enhanced tests for new hooks and components to ensure proper functionality.
|
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
✨ Files requiring CODEOWNER review ✨✅ @MetaMask/confirmations (21 files, +703 -225)
👨🔧 @MetaMask/core-extension-ux (1 files, +1 -13)
📜 @MetaMask/policy-reviewers (4 files, +308 -4)
Tip Follow the policy review process outlined in the LavaMoat Policy Review Process doc before expecting an approval from Policy Reviewers. 🧪 @MetaMask/qa (1 files, +87 -0)
|
Builds ready [59d206a]
⚡ Performance Benchmarks (1366 ± 110 ms)
🌐 Dapp Page Load BenchmarksCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
…ansaction components
Builds ready [edc0067]
⚡ Performance Benchmarks
🌐 Dapp Page Load BenchmarksCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
edc0067 to
449a9a5
Compare
Builds ready [449a9a5]
⚡ Performance Benchmarks
🌐 Dapp Page Load BenchmarksCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [48a3e5b]
⚡ Performance Benchmarks
🌐 Dapp Page Load BenchmarksCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
Builds ready [95e802a]
⚡ Performance Benchmarks
🌐 Dapp Page Load BenchmarksCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
|
@metamaskbot update-policies |
|
Policies updated. 🧠 Learn how: https://lavamoat.github.io/guides/policy-diff/#what-to-look-for-when-reviewing-a-policy-diff ✅ lavamoat/browserify/beta/policy.json changes match main/policy.json policy changes |
Builds ready [a612768]
⚡ Performance Benchmarks
🌐 Dapp Page Load BenchmarksCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|
|
Builds ready [7eaeb1c]
⚡ Performance Benchmarks
🌐 Dapp Page Load BenchmarksCurrent Commit: 📄 Localhost MetaMask Test DappSamples: 100 Summary
📈 Detailed Results
Bundle size diffs [🚨 Warning! Bundle size has increased!]
|



Description
This PR modernizes the cancel/speed-up transaction UI to use the same GasFeeModal context and gas-details patterns as the main confirmation flow, and fixes the "useConfirmContext must be used within ConfirmContextProvider" error when opening the gas modal from cancel-speedup.
What was done
transactionMetaandeditGasMode.GasFeeModalWrapperwraps modal content inConfirmContextProviderwithcurrentConfirmationOverride={transactionMeta}when opened from cancel-speedup so gas modals can useuseConfirmContext().GasFeeModalContextProvider(transactionMeta, editGasMode),useCancelSpeedupGasState, anduseCancelSpeedupInitialGas. Renders shared gas UI (e.g. GasFeesSection) and opens the gas modal via context.AdvancedEIP1559Modal,AdvancedGasPriceModal, anduseGasFeeEstimateLevelOptionsuseuseConfirmContext()again; nouseTransactionForGasModalin the modal flow.ConfirmContextProvidersupports optionalcurrentConfirmationOverride; when set, route sync and navigate-on-dismiss are skipped so the gas modal can be used outside the confirm route.useCancelSpeedupGasStateprovides effective transaction and actions;useCancelSpeedupInitialGasruns the initial gas rule (medium vs tenPercentIncreased) when the cancel-speedup modal is open.Changelog
CHANGELOG entry: Fixed gas edit opening from cancel/speed-up transaction flow and aligned cancel-speedup gas UI with the main confirmation flow.
Related issues
Fixes: https://github.com/MetaMask/MetaMask-planning/issues/7051
Manual testing steps
Screenshots/Recordings
cancel_new_ex.webm
Before
After
Pre-merge author checklist
Pre-merge reviewer checklist