Skip to content
Merged
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
6 changes: 6 additions & 0 deletions packages/preferences-controller/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added

- Add support for MONAD (chain ID `0x8f`) ([#6827](https://github.com/MetaMask/core/pull/6827))
- Add `MONAD` into constant `ETHERSCAN_SUPPORTED_CHAIN_IDS`
- Update default controller state so MONAD (Chain ID `0x8f`) is automatically enabled in `showIncomingTransactions`

## [20.0.2]

### Changed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -614,6 +614,7 @@ describe('PreferencesController', () => {
"0x61": true,
"0x64": true,
"0x89": true,
"0x8f": true,
"0xa": true,
"0xa869": true,
"0xa86a": true,
Expand Down Expand Up @@ -676,6 +677,7 @@ describe('PreferencesController', () => {
"0x61": true,
"0x64": true,
"0x89": true,
"0x8f": true,
"0xa": true,
"0xa869": true,
"0xa86a": true,
Expand Down Expand Up @@ -740,6 +742,7 @@ describe('PreferencesController', () => {
"0x61": true,
"0x64": true,
"0x89": true,
"0x8f": true,
"0xa": true,
"0xa869": true,
"0xa86a": true,
Expand Down Expand Up @@ -803,6 +806,7 @@ describe('PreferencesController', () => {
"0x61": true,
"0x64": true,
"0x89": true,
"0x8f": true,
"0xa": true,
"0xa869": true,
"0xa86a": true,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -358,6 +358,7 @@ export function getDefaultPreferencesState(): PreferencesState {
[ETHERSCAN_SUPPORTED_CHAIN_IDS.MOONRIVER]: true,
[ETHERSCAN_SUPPORTED_CHAIN_IDS.GNOSIS]: true,
[ETHERSCAN_SUPPORTED_CHAIN_IDS.SEI]: true,
[ETHERSCAN_SUPPORTED_CHAIN_IDS.MONAD]: true,
},
showTestNetworks: false,
useNftDetection: false,
Expand Down
1 change: 1 addition & 0 deletions packages/preferences-controller/src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,5 @@ export const ETHERSCAN_SUPPORTED_CHAIN_IDS = {
MOONRIVER: '0x505',
GNOSIS: '0x64',
SEI: '0x531',
MONAD: '0x8f',
} as const;
6 changes: 6 additions & 0 deletions packages/transaction-controller/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

### Added

- Add `MONAD` network support ([#6827](https://github.com/MetaMask/core/pull/6827))
- Add account address relationship API support
- Add incoming transactions API support

## [60.7.0]

### Added
Expand Down
1 change: 1 addition & 0 deletions packages/transaction-controller/src/api/accounts-api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -108,6 +108,7 @@ const SUPPORTED_CHAIN_IDS_FOR_RELATIONSHIP_API = [
59144, // Linea
534352, // Scroll
1329, // Sei
143, // Monad
];

const log = createModuleLogger(projectLogger, 'accounts-api');
Expand Down
1 change: 1 addition & 0 deletions packages/transaction-controller/src/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ export const CHAIN_IDS = {
MOONBEAM: '0x504',
MOONBEAM_TESTNET: '0x507',
MOONRIVER: '0x505',
MONAD: '0x8f',
GNOSIS: '0x64',
ARBITRUM: '0xa4b1',
ZKSYNC_ERA: '0x144',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ export const SUPPORTED_CHAIN_IDS: Hex[] = [
CHAIN_IDS.ARBITRUM,
CHAIN_IDS.SCROLL,
CHAIN_IDS.SEI,
CHAIN_IDS.MONAD,
];

const log = createModuleLogger(
Expand Down
7 changes: 7 additions & 0 deletions packages/transaction-controller/src/utils/swaps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,12 @@ const SEI_SWAPS_TOKEN_OBJECT: SwapsTokenObject = {
decimals: 18,
} as const;

const MONAD_SWAPS_TOKEN_OBJECT: SwapsTokenObject = {
name: 'Mon',
address: DEFAULT_TOKEN_ADDRESS,
decimals: 18,
} as const;

export const SWAPS_CHAINID_DEFAULT_TOKEN_MAP = {
[CHAIN_IDS.MAINNET]: ETH_SWAPS_TOKEN_OBJECT,
[SWAPS_TESTNET_CHAIN_ID]: TEST_ETH_SWAPS_TOKEN_OBJECT,
Expand All @@ -111,6 +117,7 @@ export const SWAPS_CHAINID_DEFAULT_TOKEN_MAP = {
[CHAIN_IDS.ARBITRUM]: ARBITRUM_SWAPS_TOKEN_OBJECT,
[CHAIN_IDS.ZKSYNC_ERA]: ZKSYNC_ERA_SWAPS_TOKEN_OBJECT,
[CHAIN_IDS.SEI]: SEI_SWAPS_TOKEN_OBJECT,
[CHAIN_IDS.MONAD]: MONAD_SWAPS_TOKEN_OBJECT,
} as const;

export const SWAP_TRANSACTION_TYPES = [
Expand Down
Loading