Skip to content

Commit aa2abeb

Browse files
authored
Merge pull request #7931 from BitGo/feat/WIN-8346-megaeth-erc20-token-support
feat(statics): add MegaETH testnet ERC20 token support
2 parents fe0ba89 + 1a92ef0 commit aa2abeb

5 files changed

Lines changed: 32 additions & 7 deletions

File tree

modules/statics/src/allCoinsAndTokens.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3304,6 +3304,17 @@ export const allCoinsAndTokens = [
33043304
Networks.main.megaeth
33053305
),
33063306

3307+
// MegaEth testnet tokens
3308+
erc20Token(
3309+
'b8a7c96f-96af-4c2f-94eb-582aa21ac6bb',
3310+
'tmegaeth:tmt',
3311+
'Test Mintable Token',
3312+
6,
3313+
'0x9abf1ca968783ba2ad3a75b6b7b2beece80a4fc2',
3314+
UnderlyingAsset['tmegaeth:tmt'],
3315+
Networks.test.megaeth
3316+
),
3317+
33073318
// Plume testnet tokens
33083319
erc20Token(
33093320
'67a140e3-c73e-4984-af13-7b1555ee3ff3',

modules/statics/src/base.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3031,6 +3031,9 @@ export enum UnderlyingAsset {
30313031
'megaeth:mega' = 'megaeth:mega',
30323032
'megaeth:weth' = 'megaeth:weth',
30333033

3034+
// MegaEth testnet tokens
3035+
'tmegaeth:tmt' = 'tmegaeth:tmt',
3036+
30343037
// Plume testnet tokens
30353038
'tplume:usdc' = 'tplume:usdc',
30363039

modules/statics/src/coins/ofcErc20Coins.ts

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5212,6 +5212,17 @@ export const tOfcErc20Coins = [
52125212
18,
52135213
underlyingAssetForSymbol('megaeth:weth')
52145214
),
5215+
5216+
// MegaEth testnet tokens
5217+
tofcerc20(
5218+
'c4e8f2a1-9b3d-4e5f-8a6c-7d2e1f0b9c8a',
5219+
'ofctmegaeth:tmt',
5220+
'Test Mintable Token',
5221+
6,
5222+
underlyingAssetForSymbol('tmegaeth:tmt')
5223+
),
5224+
5225+
// Morph tokens
52155226
ofcerc20('4d5f4fb7-b2e2-4e63-bbda-7f315332da5b', 'ofcmorph:usdc', 'USD Coin', 6, UnderlyingAsset['morph:usdc']),
52165227
ofcerc20('37f51c58-9be5-4c56-adcb-2c7f3c2cfc1a', 'ofcmorph:usdt', 'Tether USD', 6, UnderlyingAsset['morph:usdt']),
52175228
ofcerc20('e499e7cc-22ae-4374-ae4b-27651565af15', 'ofcmorph:usd1', 'USD1', 18, UnderlyingAsset['morph:usd1']),

modules/statics/src/map.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ export class CoinMap {
154154
747: 'flow',
155155
98867: 'tplume',
156156
98866: 'plume',
157-
6342: 'tmegaeth',
157+
6343: 'tmegaeth',
158158
4326: 'megaeth',
159159
295: 'hbarevm',
160160
296: 'thbarevm',

modules/statics/src/networks.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2196,19 +2196,19 @@ class FlowTestnet extends Testnet implements EthereumNetwork {
21962196
class MegaETH extends Mainnet implements EthereumNetwork {
21972197
name = 'MegaETH';
21982198
family = CoinFamily.MEGAETH;
2199-
explorerUrl = 'https://www.megaexplorer.xyz/tx/';
2200-
accountExplorerUrl = 'https://www.megaexplorer.xyz/address/';
2199+
explorerUrl = 'https://megaeth.blockscout.com/tx/';
2200+
accountExplorerUrl = 'https://megaeth.blockscout.com/address/';
22012201
chainId = 4326;
22022202
nativeCoinOperationHashPrefix = '4326';
22032203
}
22042204

22052205
class MegaETHTestnet extends Testnet implements EthereumNetwork {
22062206
name = 'MegaETHTestnet';
22072207
family = CoinFamily.MEGAETH;
2208-
explorerUrl = 'https://megaeth.blockscout.com/tx/';
2209-
accountExplorerUrl = 'https://megaeth.blockscout.com/address/';
2210-
chainId = 6342;
2211-
nativeCoinOperationHashPrefix = '6342';
2208+
explorerUrl = 'https://www.megaexplorer.xyz/tx/';
2209+
accountExplorerUrl = 'https://www.megaexplorer.xyz/address/';
2210+
chainId = 6343;
2211+
nativeCoinOperationHashPrefix = '6343';
22122212
}
22132213

22142214
class Plume extends Mainnet implements EthereumNetwork {

0 commit comments

Comments
 (0)