Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions packages/bridge-controller/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,11 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added

- Add `MONAD` network support ([#6828](https://github.com/MetaMask/core/pull/6828))
- Add `MONAD` into constants `ALLOWED_BRIDGE_CHAIN_IDS`, `SWAPS_TOKEN_OBJECT` and `NETWORK_TO_NAME_MAP`

## [52.0.0]

### Changed
Expand Down
1 change: 1 addition & 0 deletions packages/bridge-controller/src/constants/bridge.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ export const ALLOWED_BRIDGE_CHAIN_IDS = [
CHAIN_IDS.LINEA_MAINNET,
CHAIN_IDS.BASE,
CHAIN_IDS.SEI,
CHAIN_IDS.MONAD,
SolScope.Mainnet,
BtcScope.Mainnet,
] as const;
Expand Down
3 changes: 3 additions & 0 deletions packages/bridge-controller/src/constants/chains.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,7 @@ export const CHAIN_IDS = {
INK: '0xdef1',
MODE_SEPOLIA: '0x397',
MODE: '0x868b',
MONAD: '0x8f',
} as const;

export const NETWORK_TYPES = {
Expand Down Expand Up @@ -124,6 +125,7 @@ export const SONEIUM_DISPLAY_NAME = 'Soneium Mainnet';
export const MODE_SEPOLIA_DISPLAY_NAME = 'Mode Sepolia';
export const MODE_DISPLAY_NAME = 'Mode Mainnet';
export const SEI_DISPLAY_NAME = 'Sei Network';
export const MONAD_DISPLAY_NAME = 'Monad';

export const NETWORK_TO_NAME_MAP = {
[NETWORK_TYPES.GOERLI]: GOERLI_DISPLAY_NAME,
Expand Down Expand Up @@ -156,4 +158,5 @@ export const NETWORK_TO_NAME_MAP = {
[CHAIN_IDS.LISK]: LISK_DISPLAY_NAME,
[CHAIN_IDS.LISK_SEPOLIA]: LISK_SEPOLIA_DISPLAY_NAME,
[CHAIN_IDS.SEI]: SEI_DISPLAY_NAME,
[CHAIN_IDS.MONAD]: MONAD_DISPLAY_NAME,
} as const;
11 changes: 11 additions & 0 deletions packages/bridge-controller/src/constants/tokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ const CURRENCY_SYMBOLS = {
SOL: 'SOL',
SEI: 'SEI',
BTC: 'BTC',
MON: 'MON',
} as const;

const ETH_SWAPS_TOKEN_OBJECT = {
Expand Down Expand Up @@ -156,6 +157,14 @@ const SEI_SWAPS_TOKEN_OBJECT = {
iconUrl: '',
} as const;

const MONAD_SWAPS_TOKEN_OBJECT = {
symbol: CURRENCY_SYMBOLS.MON,
name: 'Mon',
address: DEFAULT_TOKEN_ADDRESS,
decimals: 18,
iconUrl: '',
} as const;

const SWAPS_TESTNET_CHAIN_ID = '0x539';

export const SWAPS_CHAINID_DEFAULT_TOKEN_MAP = {
Expand All @@ -172,6 +181,7 @@ export const SWAPS_CHAINID_DEFAULT_TOKEN_MAP = {
[CHAIN_IDS.LINEA_MAINNET]: LINEA_SWAPS_TOKEN_OBJECT,
[CHAIN_IDS.BASE]: BASE_SWAPS_TOKEN_OBJECT,
[CHAIN_IDS.SEI]: SEI_SWAPS_TOKEN_OBJECT,
[CHAIN_IDS.MONAD]: MONAD_SWAPS_TOKEN_OBJECT,
[SolScope.Mainnet]: SOLANA_SWAPS_TOKEN_OBJECT,
[SolScope.Devnet]: SOLANA_SWAPS_TOKEN_OBJECT,
[BtcScope.Mainnet]: BTC_SWAPS_TOKEN_OBJECT,
Expand All @@ -198,4 +208,5 @@ export const SYMBOL_TO_SLIP44_MAP: Record<
AVAX: 'slip44:9000',
TESTETH: 'slip44:60',
SEI: 'slip44:19000118',
MON: 'slip44:268435779',
};
Loading