feat: Add Xone Mainnet network support #38373
Open
+46
−0
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.
Description
This PR adds support for Xone Mainnet network in MetaMask, enabling users to connect to and interact with the Xone blockchain.
What is the reason for the change?
Xone Mainnet is a new EVM-compatible blockchain that users want to access through MetaMask. Currently, users cannot easily add or switch to Xone Mainnet network without manual configuration.
What is the improvement/solution?
This PR integrates Xone Mainnet as a featured network in MetaMask, making it easily accessible to users through the network selector. The implementation includes:
0xe89(3721 in decimal) ✅ Verified from RPC endpointhttps://rpc.xone.orgXOC(Xone Coin)https://xonescan.comxone.svgandxone-native.svgfor network brandingThe network is added to
FEATURED_RPCS, which means it will appear in the popular networks list, making it easy for users to discover and add.Files Changed:
shared/constants/network.ts- Added Xone network constants, chain ID (0xe89= 3721), RPC URL, currency symbol, display name, and image URLsshared/constants/network.test.ts- Added unit tests to verify Xone network configurationapp/images/xone.svg- Network logo imageapp/images/xone-native.svg- Native token logo imageChangelog
CHANGELOG entry: Added Xone Mainnet as a featured network option in the network selector
Related issues
Fixes:
Manual testing steps
yarn startoryarn dist0xe89(3721 in decimal) ✅ Verified from RPChttps://rpc.xone.orghttps://xonescan.comScreenshots/Recordings
Before
Xone Mainnet was not available in the network selector.
After
Xone Mainnet appears in the popular networks list and can be easily added by users.
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
shared/constants/network.test.tsto verify:0xe89)https://rpc.xone.orgI'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.