Skip to content

chore(multichain): remove unused PermissionsHeader, useNewRPC and barrel files - #47674

Merged
georgewrmarshall merged 1 commit into
mainfrom
cursor/remove-dead-code-multichain-unused-files-20261105-7b9e
Nov 6, 2026
Merged

georgewrmarshall merged 1 commit into
mainfrom
cursor/remove-dead-code-multichain-unused-files-20261105-7b9e

Conversation

@georgewrmarshall

@georgewrmarshall georgewrmarshall commented Nov 5, 2026 •

Copy link
Copy Markdown
Contributor

Description

Removes five @MetaMask/core-extension-ux files that nothing in the repo imports: the PermissionsHeader component, the useNewRPC hook, and three barrel index.ts files whose components are imported directly from their own modules. Owner set: @MetaMask/core-extension-ux.

path removed why dead
ui/components/multichain/permissions-header/permissions-header.tsx file (PermissionsHeader) zero refs
ui/components/multichain/network-manager/hooks/useNewRPC.ts file (useNewRPC) zero refs
ui/components/multichain/global-menu/index.ts file unused barrel
ui/components/multichain/funding-method-modal/index.ts file unused barrel
ui/pages/settings/backup-and-sync-tab/index.ts file unused barrel

GlobalMenuList, FundingMethodModal, and the backup and sync settings tab are still live; callers import them from global-menu-list, funding-method-modal, and backup-and-sync-tab directly. The PermissionsHeader file uses no locale key that isn't used elsewhere.

No user-facing behavior change.

Checks: yarn lint:tsc, yarn test:unit --coverage=false on the touched directories (no snapshot updates). ESLint had no remaining changed JS/TS files to lint.

Docs/comments updated: none

Changelog

CHANGELOG entry: null

Related issues

Refs: proactive dead-code cleanup (extension counterpart of metamask-mobile#37948)

Manual testing steps

N/A — deletes unreachable code. There is no user-facing behavior to click through.

Screenshots/Recordings

N/A — no UI change

Before

N/A — no UI change

After

N/A — no UI change

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.

Note

Low Risk
Deletes unreachable code only; live features remain wired through direct imports with no functional changes.

Overview
Removes dead multichain UI code with no import references in the extension: the PermissionsHeader component, the useNewRPC network-form hook, and three unused index.ts barrel re-exports (funding-method-modal, global-menu, settings/backup-and-sync-tab).

FundingMethodModal, GlobalMenuList, and the backup-and-sync settings tab stay in place; existing callers already import them from their concrete module files rather than these barrels. No user-facing behavior change—cleanup only.

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

…rel files

Co-authored-by: George Marshall <georgewrmarshall@users.noreply.github.com>
@github-actions github-actions Bot added the size-M label Nov 5, 2026
@georgewrmarshall georgewrmarshall added team-design-system All issues relating to design system in Extension no-changelog no-changelog Indicates no external facing user changes, therefore no changelog documentation needed and removed size-M labels Nov 5, 2026 — with Cursor
@georgewrmarshall georgewrmarshall self-assigned this Nov 5, 2026
@metamask-ci

metamask-ci Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

✨ Files requiring CODEOWNER review ✨

👨‍🔧 @MetaMask/core-extension-ux (5 files, +0 -126)
  • 📁 ui/
    • 📁 components/
      • 📁 multichain/
        • 📁 funding-method-modal/
          • 📄 index.ts +0 -1
        • 📁 global-menu/
          • 📄 index.ts +0 -7
        • 📁 network-manager/
          • 📁 hooks/
            • 📄 useNewRPC.ts +0 -40
        • 📁 permissions-header/
          • 📄 permissions-header.tsx +0 -77
    • 📁 pages/
      • 📁 settings/
        • 📁 backup-and-sync-tab/
          • 📄 index.ts +0 -1

@metamask-ci

metamask-ci Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor
Builds ready [92634ed]
⚡ Performance Benchmarks (Total: 🟢 8 pass · 🟡 2 warn · 🔴 3 fail)

Baseline (latest main): f693520 | Date: 11/3/2026 | Pipeline: 42104596199 | Baseline logs

Metricschrome-webpackfirefox-webpack
loadNewAccount
[Sentry log · main/release]
🔴 load_new_account(p95) [CI log]🔴 load_new_account(p95) [CI log]
onboardingImportWallet
[Sentry log · main/release]
🟢 [CI log]🔴 [CI log]

Regressions (🔴 3 failures)

Interaction Benchmarks · Samples: 5 🔴 2
Benchmarkchrome-webpackfirefox-webpack
loadNewAccount
[Sentry log · main/release]
🔴 [CI log]
🔴 load_new_account
🔴 [CI log]
🔴 load_new_account
confirmTx
[Sentry log · main/release]
🟡 [CI log]🟢 [CI log]
bridgeUserActions
[Sentry log · main/release]
🟡 [CI log]🟢 [CI log]

📈 Results compared to the previous 5 runs on main

  • ↑ loadNewAccount/load_new_account: +183%
  • ↑ loadNewAccount/total: +183%
  • ↑ loadNewAccount/lcp: +974%
  • ↑ loadNewAccount/cls: +573%
  • ↑ confirmTx/longTaskCount: +67%
  • ↑ confirmTx/longTaskTotalDuration: +78%
  • ↑ confirmTx/longTaskMaxDuration: +64%
  • ↑ confirmTx/tbt: +91%
  • ↓ confirmTx/inp: -13%
  • ↑ confirmTx/lcp: +971%
  • ↑ bridgeUserActions/bridge_load_page: +137%
  • ↑ bridgeUserActions/bridge_load_asset_picker: +30%
  • ↑ bridgeUserActions/longTaskCount: +82%
  • ↑ bridgeUserActions/longTaskTotalDuration: +109%
  • ↑ bridgeUserActions/longTaskMaxDuration: +40%
  • ↑ bridgeUserActions/tbt: +183%
  • ↑ bridgeUserActions/total: +23%
  • ↑ bridgeUserActions/fcp: +11%
  • ↑ bridgeUserActions/lcp: +1000%
  • ↑ bridgeUserActions/cls: +611%
  • ↑ loadNewAccount/load_new_account: +184%
  • ↑ loadNewAccount/total: +184%
  • ↑ loadNewAccount/inp: +42%
  • ↓ loadNewAccount/fcp: -38%
  • ↑ loadNewAccount/lcp: +1321%
  • ↓ confirmTx/longTaskCount: -100%
  • ↓ confirmTx/longTaskTotalDuration: -100%
  • ↓ confirmTx/longTaskMaxDuration: -100%
  • ↓ confirmTx/tbt: -100%
  • ↓ confirmTx/fcp: -35%
  • ↑ confirmTx/lcp: +1300%
  • ↑ bridgeUserActions/bridge_load_page: +282%
  • ↑ bridgeUserActions/bridge_load_asset_picker: +109%
  • ↑ bridgeUserActions/bridge_search_token: +51%
  • ↓ bridgeUserActions/longTaskCount: -100%
  • ↓ bridgeUserActions/longTaskTotalDuration: -100%
  • ↓ bridgeUserActions/longTaskMaxDuration: -100%
  • ↓ bridgeUserActions/tbt: -100%
  • ↑ bridgeUserActions/total: +79%
  • ↑ bridgeUserActions/inp: +54%
  • ↓ bridgeUserActions/fcp: -34%
  • ↑ bridgeUserActions/lcp: +1272%

🌐 Core Web Vitals — 🟢 good · 🟡 needs improvement · 🔴 poor (web.dev thresholds)

  • 🟡 loadNewAccount/FCP: p75 1.9s
  • 🟡 confirmTx/FCP: p75 1.8s
  • 🟡 bridgeUserActions/FCP: p75 1.9s
  • 🟡 loadNewAccount/LCP: p75 2.5s
Startup Benchmarks · Samples: 100
Benchmarkchrome-webpackfirefox-webpack
startupStandardHome
[Sentry log · main/release]
🟢 [CI log]🟢 [CI log]

📈 Results compared to the previous 5 runs on main

  • ↑ startupStandardHome/uiStartup: +87%
  • ↑ startupStandardHome/load: +122%
  • ↑ startupStandardHome/domContentLoaded: +123%
  • ↑ startupStandardHome/domInteractive: +22%
  • ↓ startupStandardHome/firstPaint: -55%
  • ↓ startupStandardHome/firstReactRender: -98%
  • ↓ startupStandardHome/initialActions: -29%
  • ↑ startupStandardHome/loadScripts: +121%
  • ↑ startupStandardHome/setupStore: +108%
  • ↑ startupStandardHome/numNetworkReqs: +11%
  • ↑ startupStandardHome/longTaskCount: +79%
  • ↑ startupStandardHome/longTaskTotalDuration: +119%
  • ↑ startupStandardHome/longTaskMaxDuration: +132%
  • ↑ startupStandardHome/tbt: +142%
  • ↓ startupStandardHome/inp: -11%
  • ↓ startupStandardHome/fcp: -51%
  • ↑ startupStandardHome/lcp: +121%
  • ↓ startupStandardHome/cls: -72%
  • ↑ startupStandardHome/domInteractive: +36%
  • ↓ startupStandardHome/firstReactRender: -99%
  • ↓ startupStandardHome/initialActions: -50%
  • ↑ startupStandardHome/fcp: +43%
User Journey Benchmarks · Samples: 5 · mock API 🔴 1
Benchmarkchrome-webpackfirefox-webpack
onboardingImportWallet
[Sentry log · main/release]
🟢 [CI log]🔴 [CI log]
🔴 total
onboardingNewWallet
[Sentry log · main/release]
🟢 [CI log]🟢 [CI log]

📈 Results compared to the previous 5 runs on main

  • ↓ onboardingImportWallet/srpButtonToSrpForm: -24%
  • ↓ onboardingImportWallet/confirmSrpToPwForm: -14%
  • ↓ onboardingImportWallet/metricsToWalletReadyScreen: -34%
  • ↓ onboardingImportWallet/doneButtonToHomeScreen: -92%
  • ↓ onboardingImportWallet/openAccountMenuToAccountListLoaded: -74%
  • ↓ onboardingImportWallet/longTaskCount: -100%
  • ↓ onboardingImportWallet/longTaskTotalDuration: -100%
  • ↓ onboardingImportWallet/longTaskMaxDuration: -100%
  • ↓ onboardingImportWallet/tbt: -100%
  • ↓ onboardingImportWallet/total: -86%
  • ↓ onboardingNewWallet/createWalletToSocialScreen: -11%
  • ↑ onboardingNewWallet/createPwToRecoveryScreen: +11%
  • ↓ onboardingNewWallet/doneButtonToAssetList: -80%
  • ↓ onboardingNewWallet/longTaskCount: -100%
  • ↓ onboardingNewWallet/longTaskTotalDuration: -100%
  • ↓ onboardingNewWallet/longTaskMaxDuration: -100%
  • ↓ onboardingNewWallet/tbt: -100%
  • ↓ onboardingNewWallet/total: -75%
Dapp Page Load Benchmarks · Samples: 100
Benchmarkchrome-webpack
dappPageLoad
[Sentry log · main/release]
🟢 [CI log]

📈 Results compared to the previous 5 runs on main

  • ↓ dappPageLoad/pageLoadTime: -50%
  • ↓ dappPageLoad/firstPaint: -33%
  • ↓ dappPageLoad/firstContentfulPaint: -33%
Bundle Size Diffs [🚀 Bundle size reduced!]
Status Bundle Total Diff Change
✅ background 15.26 MiB +116 Bytes 0.00%
✅ ui 19.4 MiB -3.94 KiB -0.02%
✅ common 0 Bytes 0 Bytes 0.00%
✅ other 4.44 MiB -14 Bytes 0.00%
✅ content scripts 3.23 MiB -28 Bytes 0.00%
✅ unzipped 79.73 MiB -3.86 KiB 0.00%
✅ zip 23.85 MiB -1.25 KiB -0.01%

@sonarqubecloud

sonarqubecloud Bot commented Nov 5, 2026

Copy link
Copy Markdown

@georgewrmarshall
georgewrmarshall marked this pull request as ready for review November 5, 2026 23:15
@georgewrmarshall
georgewrmarshall requested a review from a team as a code owner November 5, 2026 23:15
@georgewrmarshall
georgewrmarshall added this pull request to the merge queue Nov 6, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Nov 6, 2026
@georgewrmarshall
georgewrmarshall added this pull request to the merge queue Nov 6, 2026
Merged via the queue into main with commit 48312a6 Nov 6, 2026
386 of 394 checks passed
@georgewrmarshall
georgewrmarshall deleted the cursor/remove-dead-code-multichain-unused-files-20261105-7b9e branch November 6, 2026 18:34
@github-actions github-actions Bot locked and limited conversation to collaborators Nov 6, 2026
@metamaskbot metamaskbot added the release-13.58.0 Issue or pull request that will be included in release 13.58.0 label Nov 16, 2026
@gauthierpetetin

Copy link
Copy Markdown
Contributor

No release label on PR. Adding release label release-13.58.0 on PR, as PR was added to branch 13.58.0 when release was cut.

This branch was previously deployed

1 inactive deployment
pr-comment — 92634edb Deployed Nov 5, 2026 by georgewrmarshall via identify-codeowners #88864
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

no-changelog no-changelog Indicates no external facing user changes, therefore no changelog documentation needed release-13.58.0 Issue or pull request that will be included in release 13.58.0 team-design-system All issues relating to design system in Extension

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants