fix: fixed ENS Resolution for selected chain in contacts
This PR is to ensure if ENS is supported on that network, it should resolve to their corresponding address in that network
Changelog
CHANGELOG entry:null
Related issues
Fixes: #34994
Manual testing steps
- Click Contacts
- Select Mainnet
- Add seaona.eth see address
- Select Sepolia
- Add seaona.eth see address is different
Screenshots/Recordings
Before
NA
After
https://github.com/user-attachments/assets/15d851b1-7617-4208-9672-2ce73aa9ac93
Pre-merge author checklist
- [ ] I've followed MetaMask Contributor Docs and MetaMask Extension Coding Standards.
- [ ] I've completed the PR template to the best of my ability
- [ ] I’ve included tests if applicable
- [ ] I’ve documented my code using JSDoc format if applicable
- [ ] I’ve applied the right labels on the PR (see labeling guidelines). Not required for external contributors.
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] Re-resolves ENS/domain names on network change in Add Contact by tracking the entered domain and invoking
lookupDomainNamewith the selected chain, with container wiring and minor fixes.
- Contacts UI (
ui/pages/settings/contact-list-tab/add-contact/add-contact.component.js):
- Add re-resolution logic on network change:
- Track original domain via
enteredDomainNameand previous chain viauseRef.- On
selectedChainIdchange, reset resolutions and calllookupDomainName(domain, selectedChainId).- Update domain resolution selection:
- On selecting a resolution, set
enteredDomainNameand clear existing resolutions.- Reset flow: clear
enteredDomainNameon input reset.- Network picker: normalize
onSelectparam tochainId.- Props: add
lookupDomainNametoPropTypes.- Container (
add-contact.container.js):
- Wire
lookupDomainName(domainName, chainId)fromducks/domainsinto component props.Written by Cursor Bugbot for commit c44b0b4531ba5957648cce2646d7d75d392af7b9. This will update automatically on new commits. Configure here.
Builds ready [a81e87f]
- builds: chrome, firefox
- builds (beta): chrome, firefox
- builds (flask): chrome, firefox
- builds (test): chrome, firefox
- builds (test-flask): chrome, firefox
- bundle size: Bundle Size Stats
- user-actions-benchmark: User Actions Stats
- storybook: Storybook
- typescript migration: Dashboard
- all artifacts
UI Startup Metrics (1242 ± 81 ms)
| Platform | BuildType | Page | Metric | Mean (ms) | Min (ms) | Max (ms) | Std Dev (ms) | P 75 (ms) | P 95 (ms) |
|---|---|---|---|---|---|---|---|---|---|
| Chrome | Browserify | Standard Home | uiStartup | 1242 | 1069 | 1450 | 81 | 1314 | 1366 |
| load | 1021 | 864 | 1196 | 64 | 1062 | 1119 | |||
| domContentLoaded | 1016 | 861 | 1183 | 64 | 1056 | 1111 | |||
| domInteractive | 21 | 15 | 61 | 7 | 21 | 36 | |||
| firstPaint | 444 | 82 | 1201 | 376 | 965 | 1105 | |||
| backgroundConnect | 213 | 198 | 268 | 12 | 216 | 237 | |||
| firstReactRender | 48 | 32 | 83 | 13 | 55 | 74 | |||
| getState | 39 | 15 | 124 | 21 | 46 | 90 | |||
| initialActions | 1 | 0 | 4 | 1 | 1 | 2 | |||
| loadScripts | 809 | 662 | 974 | 63 | 849 | 906 | |||
| setupStore | 12 | 7 | 32 | 4 | 14 | 21 | |||
| numNetworkReqs | 8 | 6 | 33 | 7 | 6 | 30 | |||
| Browserify | Power User Home | uiStartup | 1932 | 1648 | 2820 | 151 | 2020 | 2125 | |
| load | 1104 | 934 | 1270 | 88 | 1175 | 1259 | |||
| domContentLoaded | 1093 | 929 | 1263 | 88 | 1165 | 1244 | |||
| domInteractive | 28 | 17 | 84 | 11 | 29 | 53 | |||
| firstPaint | 537 | 94 | 1269 | 425 | 1081 | 1236 | |||
| backgroundConnect | 263 | 207 | 667 | 105 | 246 | 612 | |||
| firstReactRender | 50 | 41 | 71 | 6 | 52 | 62 | |||
| getState | 201 | 147 | 351 | 38 | 221 | 272 | |||
| initialActions | 1 | 0 | 2 | 1 | 1 | 1 | |||
| loadScripts | 873 | 718 | 1047 | 86 | 939 | 1021 | |||
| setupStore | 16 | 11 | 42 | 6 | 15 | 32 | |||
| numNetworkReqs | 67 | 58 | 107 | 11 | 66 | 101 | |||
| Webpack | Standard Home | uiStartup | 847 | 716 | 1129 | 73 | 878 | 995 | |
| load | 658 | 570 | 945 | 71 | 695 | 812 | |||
| domContentLoaded | 653 | 563 | 941 | 71 | 690 | 807 | |||
| domInteractive | 22 | 15 | 50 | 7 | 22 | 38 | |||
| firstPaint | 223 | 76 | 729 | 170 | 195 | 670 | |||
| backgroundConnect | 13 | 6 | 42 | 8 | 13 | 31 | |||
| firstReactRender | 56 | 34 | 209 | 37 | 54 | 147 | |||
| getState | 24 | 15 | 69 | 9 | 31 | 42 | |||
| initialActions | 1 | 0 | 3 | 1 | 1 | 2 | |||
| loadScripts | 649 | 560 | 935 | 71 | 688 | 804 | |||
| setupStore | 10 | 6 | 27 | 4 | 11 | 19 | |||
| numNetworkReqs | 8 | 6 | 30 | 6 | 6 | 29 | |||
| Webpack | Power User Home | uiStartup | 1485 | 1197 | 2362 | 180 | 1625 | 1757 | |
| load | 735 | 607 | 938 | 91 | 819 | 901 | |||
| domContentLoaded | 728 | 601 | 931 | 90 | 809 | 892 | |||
| domInteractive | 26 | 16 | 82 | 11 | 27 | 54 | |||
| firstPaint | 264 | 89 | 917 | 183 | 244 | 711 | |||
| backgroundConnect | 57 | 7 | 553 | 127 | 32 | 523 | |||
| firstReactRender | 50 | 39 | 85 | 6 | 52 | 62 | |||
| getState | 197 | 138 | 422 | 50 | 229 | 309 | |||
| initialActions | 1 | 0 | 3 | 0 | 1 | 1 | |||
| loadScripts | 724 | 599 | 928 | 90 | 805 | 889 | |||
| setupStore | 15 | 9 | 39 | 7 | 14 | 35 | |||
| numNetworkReqs | 66 | 58 | 101 | 10 | 66 | 97 | |||
| Firefox | Browserify | Standard Home | uiStartup | 1283 | 1113 | 1770 | 135 | 1357 | 1599 |
| load | 1053 | 939 | 1482 | 107 | 1096 | 1337 | |||
| domContentLoaded | 1053 | 939 | 1482 | 107 | 1093 | 1337 | |||
| domInteractive | 58 | 32 | 175 | 30 | 83 | 131 | |||
| firstPaint | - | - | - | - | - | - | |||
| backgroundConnect | 42 | 20 | 292 | 36 | 43 | 90 | |||
| firstReactRender | 37 | 30 | 104 | 10 | 37 | 59 | |||
| getState | 9 | 6 | 21 | 2 | 10 | 12 | |||
| initialActions | 1 | 0 | 2 | 1 | 2 | 2 | |||
| loadScripts | 1025 | 917 | 1459 | 98 | 1049 | 1273 | |||
| setupStore | 9 | 6 | 79 | 7 | 10 | 13 | |||
| numNetworkReqs | 8 | 6 | 25 | 5 | 7 | 24 | |||
| Browserify | Power User Home | uiStartup | 2605 | 1611 | 3959 | 570 | 3066 | 3344 | |
| load | 1567 | 998 | 2489 | 530 | 2123 | 2322 | |||
| domContentLoaded | 1567 | 994 | 2489 | 530 | 2122 | 2321 | |||
| domInteractive | 152 | 31 | 1206 | 294 | 77 | 1009 | |||
| firstPaint | - | - | - | - | - | - | |||
| backgroundConnect | 148 | 26 | 1093 | 175 | 171 | 270 | |||
| firstReactRender | 56 | 35 | 101 | 14 | 60 | 91 | |||
| getState | 140 | 76 | 335 | 50 | 171 | 252 | |||
| initialActions | 2 | 0 | 6 | 1 | 2 | 3 | |||
| loadScripts | 1513 | 955 | 2440 | 502 | 2026 | 2285 | |||
| setupStore | 50 | 4 | 1086 | 129 | 30 | 287 | |||
| numNetworkReqs | 68 | 54 | 132 | 15 | 67 | 114 | |||
| Webpack | Standard Home | uiStartup | 1517 | 1296 | 1862 | 109 | 1572 | 1752 | |
| load | 1241 | 1094 | 1504 | 76 | 1297 | 1380 | |||
| domContentLoaded | 1241 | 1094 | 1504 | 76 | 1297 | 1380 | |||
| domInteractive | 65 | 30 | 197 | 38 | 85 | 140 | |||
| firstPaint | - | - | - | - | - | - | |||
| backgroundConnect | 44 | 19 | 175 | 23 | 48 | 101 | |||
| firstReactRender | 42 | 33 | 84 | 9 | 45 | 60 | |||
| getState | 16 | 7 | 203 | 25 | 14 | 25 | |||
| initialActions | 1 | 0 | 3 | 1 | 2 | 2 | |||
| loadScripts | 1218 | 1079 | 1424 | 72 | 1277 | 1353 | |||
| setupStore | 11 | 6 | 27 | 4 | 12 | 19 | |||
| numNetworkReqs | 8 | 6 | 26 | 5 | 7 | 23 | |||
| Webpack | Power User Home | uiStartup | 2802 | 1759 | 4623 | 640 | 3316 | 3574 | |
| load | 1877 | 1116 | 3635 | 582 | 2397 | 2615 | |||
| domContentLoaded | 1876 | 1116 | 3635 | 582 | 2396 | 2614 | |||
| domInteractive | 251 | 28 | 1810 | 425 | 102 | 1107 | |||
| firstPaint | - | - | - | - | - | - | |||
| backgroundConnect | 178 | 25 | 1186 | 256 | 188 | 1046 | |||
| firstReactRender | 56 | 35 | 141 | 17 | 59 | 104 | |||
| getState | 138 | 80 | 276 | 47 | 172 | 241 | |||
| initialActions | 3 | 0 | 69 | 8 | 2 | 3 | |||
| loadScripts | 1782 | 1100 | 3366 | 536 | 2243 | 2579 | |||
| setupStore | 43 | 4 | 355 | 71 | 33 | 258 | |||
| numNetworkReqs | 70 | 53 | 136 | 18 | 68 | 120 |
📊 Page Load Benchmark Results
Current Commit: a81e87f | Date: 12/9/2025
📄 Localhost MetaMask Test Dapp
Samples: 100
Summary
- pageLoadTime-> current mean value: 1.03s (±42ms) 🟡 | historical mean value: 1.06s ⬇️ (historical data)
- domContentLoaded-> current mean value: 713ms (±39ms) 🟢 | historical mean value: 738ms ⬇️ (historical data)
- firstContentfulPaint-> current mean value: 74ms (±11ms) 🟢 | historical mean value: 79ms ⬇️ (historical data)
📈 Detailed Results
| Metric | Mean | Std Dev | Min | Max | P95 | P99 |
|---|---|---|---|---|---|---|
| pageLoadTime | 1.03s | 42ms | 1.00s | 1.32s | 1.05s | 1.32s |
| domContentLoaded | 713ms | 39ms | 693ms | 982ms | 726ms | 982ms |
| firstPaint | 74ms | 11ms | 60ms | 168ms | 84ms | 168ms |
| firstContentfulPaint | 74ms | 11ms | 60ms | 168ms | 84ms | 168ms |
| largestContentfulPaint | 0ms | 0ms | 0ms | 0ms | 0ms | 0ms |
Bundle size diffs [🚨 Warning! Bundle size has increased!]
- background: 58 Bytes (0%)
- ui: 468 Bytes (0.01%)
- common: 20 Bytes (0%)
Builds ready [c44b0b4]
- builds: chrome, firefox
- builds (beta): chrome, firefox
- builds (flask): chrome, firefox
- builds (test): chrome, firefox
- builds (test-flask): chrome, firefox
- bundle size: Bundle Size Stats
- user-actions-benchmark: User Actions Stats
- storybook: Storybook
- typescript migration: Dashboard
- all artifacts
UI Startup Metrics (1265 ± 78 ms)
| Platform | BuildType | Page | Metric | Mean (ms) | Min (ms) | Max (ms) | Std Dev (ms) | P 75 (ms) | P 95 (ms) |
|---|---|---|---|---|---|---|---|---|---|
| Chrome | Browserify | Standard Home | uiStartup | 1265 | 1049 | 1474 | 78 | 1321 | 1396 |
| load | 1037 | 875 | 1250 | 69 | 1080 | 1138 | |||
| domContentLoaded | 1031 | 869 | 1244 | 68 | 1072 | 1134 | |||
| domInteractive | 23 | 16 | 57 | 8 | 24 | 40 | |||
| firstPaint | 587 | 80 | 1177 | 414 | 1052 | 1107 | |||
| backgroundConnect | 219 | 196 | 248 | 10 | 226 | 239 | |||
| firstReactRender | 46 | 33 | 94 | 11 | 49 | 69 | |||
| getState | 34 | 16 | 122 | 17 | 40 | 74 | |||
| initialActions | 1 | 0 | 3 | 1 | 1 | 1 | |||
| loadScripts | 819 | 666 | 1042 | 67 | 860 | 918 | |||
| setupStore | 11 | 8 | 26 | 3 | 12 | 21 | |||
| numNetworkReqs | 8 | 6 | 30 | 7 | 6 | 29 | |||
| Browserify | Power User Home | uiStartup | 1972 | 1654 | 2528 | 184 | 2064 | 2406 | |
| load | 1116 | 951 | 1332 | 101 | 1204 | 1282 | |||
| domContentLoaded | 1105 | 942 | 1327 | 101 | 1198 | 1272 | |||
| domInteractive | 28 | 18 | 56 | 8 | 29 | 46 | |||
| firstPaint | 581 | 128 | 1308 | 423 | 1080 | 1254 | |||
| backgroundConnect | 275 | 211 | 883 | 122 | 258 | 630 | |||
| firstReactRender | 52 | 41 | 94 | 7 | 55 | 62 | |||
| getState | 200 | 150 | 282 | 28 | 218 | 256 | |||
| initialActions | 1 | 0 | 2 | 1 | 1 | 2 | |||
| loadScripts | 876 | 705 | 1106 | 98 | 959 | 1044 | |||
| setupStore | 16 | 11 | 66 | 7 | 16 | 31 | |||
| numNetworkReqs | 71 | 59 | 206 | 25 | 67 | 110 | |||
| Webpack | Standard Home | uiStartup | 840 | 717 | 1024 | 64 | 878 | 956 | |
| load | 654 | 572 | 846 | 63 | 693 | 792 | |||
| domContentLoaded | 649 | 568 | 840 | 63 | 687 | 786 | |||
| domInteractive | 22 | 15 | 51 | 7 | 22 | 38 | |||
| firstPaint | 224 | 72 | 785 | 162 | 204 | 646 | |||
| backgroundConnect | 11 | 5 | 33 | 7 | 13 | 27 | |||
| firstReactRender | 56 | 32 | 204 | 41 | 47 | 163 | |||
| getState | 24 | 13 | 55 | 9 | 31 | 41 | |||
| initialActions | 1 | 0 | 3 | 1 | 1 | 1 | |||
| loadScripts | 645 | 565 | 837 | 63 | 685 | 783 | |||
| setupStore | 10 | 6 | 28 | 4 | 12 | 17 | |||
| numNetworkReqs | 8 | 6 | 33 | 7 | 6 | 29 | |||
| Webpack | Power User Home | uiStartup | 1539 | 1213 | 2628 | 200 | 1650 | 1877 | |
| load | 764 | 624 | 1183 | 99 | 852 | 908 | |||
| domContentLoaded | 756 | 618 | 1176 | 98 | 846 | 902 | |||
| domInteractive | 27 | 16 | 101 | 12 | 26 | 48 | |||
| firstPaint | 298 | 89 | 902 | 228 | 263 | 822 | |||
| backgroundConnect | 43 | 7 | 626 | 110 | 21 | 324 | |||
| firstReactRender | 51 | 42 | 73 | 6 | 55 | 67 | |||
| getState | 211 | 149 | 337 | 46 | 245 | 312 | |||
| initialActions | 1 | 0 | 3 | 1 | 1 | 2 | |||
| loadScripts | 753 | 615 | 1166 | 98 | 843 | 899 | |||
| setupStore | 15 | 7 | 42 | 7 | 14 | 36 | |||
| numNetworkReqs | 68 | 58 | 204 | 16 | 67 | 94 | |||
| Firefox | Browserify | Standard Home | uiStartup | 1348 | 1140 | 1810 | 128 | 1437 | 1559 |
| load | 1106 | 955 | 1567 | 102 | 1155 | 1333 | |||
| domContentLoaded | 1105 | 954 | 1567 | 102 | 1154 | 1333 | |||
| domInteractive | 69 | 33 | 247 | 38 | 88 | 144 | |||
| firstPaint | - | - | - | - | - | - | |||
| backgroundConnect | 40 | 23 | 132 | 20 | 46 | 86 | |||
| firstReactRender | 39 | 31 | 149 | 13 | 40 | 53 | |||
| getState | 10 | 6 | 36 | 5 | 10 | 24 | |||
| initialActions | 1 | 0 | 2 | 1 | 2 | 2 | |||
| loadScripts | 1080 | 935 | 1501 | 96 | 1119 | 1298 | |||
| setupStore | 12 | 6 | 162 | 16 | 11 | 22 | |||
| numNetworkReqs | 8 | 6 | 28 | 6 | 7 | 25 | |||
| Browserify | Power User Home | uiStartup | 2638 | 1604 | 3575 | 604 | 3139 | 3430 | |
| load | 1653 | 973 | 2603 | 552 | 2137 | 2437 | |||
| domContentLoaded | 1653 | 973 | 2602 | 552 | 2136 | 2436 | |||
| domInteractive | 98 | 31 | 1086 | 193 | 75 | 150 | |||
| firstPaint | - | - | - | - | - | - | |||
| backgroundConnect | 186 | 23 | 1460 | 240 | 215 | 1021 | |||
| firstReactRender | 55 | 38 | 110 | 12 | 59 | 72 | |||
| getState | 152 | 73 | 423 | 59 | 169 | 246 | |||
| initialActions | 2 | 1 | 9 | 1 | 2 | 3 | |||
| loadScripts | 1560 | 955 | 2382 | 506 | 2049 | 2299 | |||
| setupStore | 68 | 5 | 1113 | 163 | 39 | 357 | |||
| numNetworkReqs | 70 | 56 | 126 | 14 | 72 | 109 | |||
| Webpack | Standard Home | uiStartup | 1511 | 1293 | 1861 | 119 | 1575 | 1766 | |
| load | 1222 | 1120 | 1525 | 69 | 1278 | 1346 | |||
| domContentLoaded | 1222 | 1119 | 1525 | 69 | 1278 | 1346 | |||
| domInteractive | 51 | 27 | 249 | 35 | 76 | 110 | |||
| firstPaint | - | - | - | - | - | - | |||
| backgroundConnect | 48 | 19 | 164 | 29 | 48 | 119 | |||
| firstReactRender | 43 | 32 | 91 | 10 | 45 | 58 | |||
| getState | 17 | 7 | 197 | 28 | 14 | 34 | |||
| initialActions | 1 | 0 | 3 | 1 | 2 | 2 | |||
| loadScripts | 1200 | 1101 | 1498 | 68 | 1255 | 1323 | |||
| setupStore | 13 | 4 | 107 | 14 | 12 | 28 | |||
| numNetworkReqs | 8 | 6 | 27 | 5 | 7 | 24 | |||
| Webpack | Power User Home | uiStartup | 2737 | 1834 | 3588 | 558 | 3189 | 3446 | |
| load | 1845 | 1118 | 2671 | 495 | 2273 | 2448 | |||
| domContentLoaded | 1845 | 1118 | 2670 | 495 | 2273 | 2448 | |||
| domInteractive | 186 | 28 | 1133 | 334 | 78 | 1017 | |||
| firstPaint | - | - | - | - | - | - | |||
| backgroundConnect | 162 | 25 | 1190 | 221 | 173 | 958 | |||
| firstReactRender | 58 | 39 | 109 | 17 | 58 | 102 | |||
| getState | 129 | 72 | 337 | 50 | 154 | 235 | |||
| initialActions | 2 | 0 | 7 | 1 | 2 | 3 | |||
| loadScripts | 1768 | 1103 | 2494 | 474 | 2207 | 2415 | |||
| setupStore | 19 | 4 | 368 | 38 | 19 | 53 | |||
| numNetworkReqs | 71 | 58 | 114 | 12 | 70 | 100 |
📊 Page Load Benchmark Results
Current Commit: c44b0b4 | Date: 12/9/2025
📄 Localhost MetaMask Test Dapp
Samples: 100
Summary
- pageLoadTime-> current mean value: 1.10s (±117ms) 🟡 | historical mean value: 1.06s ⬆️ (historical data)
- domContentLoaded-> current mean value: 787ms (±114ms) 🟢 | historical mean value: 741ms ⬆️ (historical data)
- firstContentfulPaint-> current mean value: 78ms (±10ms) 🟢 | historical mean value: 80ms ⬇️ (historical data)
📈 Detailed Results
| Metric | Mean | Std Dev | Min | Max | P95 | P99 |
|---|---|---|---|---|---|---|
| pageLoadTime | 1.10s | 117ms | 1.02s | 1.34s | 1.32s | 1.34s |
| domContentLoaded | 787ms | 114ms | 703ms | 1.02s | 998ms | 1.02s |
| firstPaint | 78ms | 10ms | 60ms | 164ms | 88ms | 164ms |
| firstContentfulPaint | 78ms | 10ms | 60ms | 164ms | 88ms | 164ms |
| largestContentfulPaint | 0ms | 0ms | 0ms | 0ms | 0ms | 0ms |
Bundle size diffs [🚨 Warning! Bundle size has increased!]
- background: 58 Bytes (0%)
- ui: 504 Bytes (0.01%)
- common: 20 Bytes (0%)