diff --git a/src/config/web3/cosmos/mainnet/acrechain.ts b/src/config/web3/cosmos/mainnet/acrechain.ts index f2c281503..f4a7d63ca 100644 --- a/src/config/web3/cosmos/mainnet/acrechain.ts +++ b/src/config/web3/cosmos/mainnet/acrechain.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -14,14 +16,7 @@ export const acrechain: CosmosChain = { coinDecimals: 18, coinGeckoId: "arable-protocol", }, - bech32Config: { - bech32PrefixAccAddr: "acre", - bech32PrefixAccPub: "acrepub", - bech32PrefixValAddr: "acrevaloper", - bech32PrefixValPub: "acrevaloperpub", - bech32PrefixConsAddr: "acrevalcons", - bech32PrefixConsPub: "acrevalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("acre"), bip44: { coinType: 60 }, currencies: [ { diff --git a/src/config/web3/cosmos/mainnet/archway.ts b/src/config/web3/cosmos/mainnet/archway.ts index 62d38e44a..78411affb 100644 --- a/src/config/web3/cosmos/mainnet/archway.ts +++ b/src/config/web3/cosmos/mainnet/archway.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -5,14 +7,7 @@ import { CosmosChain } from "../interface"; export const archway: CosmosChain = { rest: "https://api.mainnet.archway.io", rpc: `${COSMOS_PROXY_RPC_MAINNET}/chain/archway`, - bech32Config: { - bech32PrefixAccAddr: "archway", - bech32PrefixAccPub: "archwaypub", - bech32PrefixConsAddr: "archwayvalcons", - bech32PrefixConsPub: "archwayvalconspub", - bech32PrefixValAddr: "archwayvaloper", - bech32PrefixValPub: "archwayvaloperpub", - }, + bech32Config: Bech32Address.defaultBech32Config("archway"), bip44: { coinType: 118, }, diff --git a/src/config/web3/cosmos/mainnet/assetmantle.ts b/src/config/web3/cosmos/mainnet/assetmantle.ts index c700a9421..b9dd69c04 100644 --- a/src/config/web3/cosmos/mainnet/assetmantle.ts +++ b/src/config/web3/cosmos/mainnet/assetmantle.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -13,14 +15,7 @@ export const assetmantle: CosmosChain = { coinDecimals: 6, coinGeckoId: "assetmantle", }, - bech32Config: { - bech32PrefixAccAddr: "mantle", - bech32PrefixAccPub: "mantlepub", - bech32PrefixValAddr: "mantlevaloper", - bech32PrefixValPub: "mantlevaloperpub", - bech32PrefixConsAddr: "mantlevalcons", - bech32PrefixConsPub: "mantlevalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("mantle"), bip44: { coinType: 118, }, diff --git a/src/config/web3/cosmos/mainnet/aura.ts b/src/config/web3/cosmos/mainnet/aura.ts index f62ce20bd..1108143c1 100644 --- a/src/config/web3/cosmos/mainnet/aura.ts +++ b/src/config/web3/cosmos/mainnet/aura.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -10,14 +12,7 @@ export const aura: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "aura", - bech32PrefixAccPub: "aura" + "pub", - bech32PrefixValAddr: "aura" + "valoper", - bech32PrefixValPub: "aura" + "valoperpub", - bech32PrefixConsAddr: "aura" + "valcons", - bech32PrefixConsPub: "aura" + "valconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("aura"), currencies: [ { coinDenom: "AURA", diff --git a/src/config/web3/cosmos/mainnet/carbon.ts b/src/config/web3/cosmos/mainnet/carbon.ts index c52030fc4..a58f70244 100644 --- a/src/config/web3/cosmos/mainnet/carbon.ts +++ b/src/config/web3/cosmos/mainnet/carbon.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -12,14 +14,7 @@ export const carbon: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "swth", - bech32PrefixAccPub: "swthpub", - bech32PrefixValAddr: "swthvaloper", - bech32PrefixValPub: "swthvaloperpub", - bech32PrefixConsAddr: "swthvalcons", - bech32PrefixConsPub: "swthvalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("swth"), currencies: [ { coinDenom: "SWTH", diff --git a/src/config/web3/cosmos/mainnet/crescent.ts b/src/config/web3/cosmos/mainnet/crescent.ts index 67759be27..0800283ed 100644 --- a/src/config/web3/cosmos/mainnet/crescent.ts +++ b/src/config/web3/cosmos/mainnet/crescent.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -12,14 +14,7 @@ export const crescent: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "cre", - bech32PrefixAccPub: "crepub", - bech32PrefixValAddr: "crevaloper", - bech32PrefixValPub: "crevaloperpub", - bech32PrefixConsAddr: "crevalcons", - bech32PrefixConsPub: "crevalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("cre"), currencies: [ { coinDenom: "CRE", diff --git a/src/config/web3/cosmos/mainnet/fetch.ts b/src/config/web3/cosmos/mainnet/fetch.ts index abd8d7498..83f893e58 100644 --- a/src/config/web3/cosmos/mainnet/fetch.ts +++ b/src/config/web3/cosmos/mainnet/fetch.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -13,14 +15,7 @@ export const fetch: CosmosChain = { coinDecimals: 18, coinGeckoId: "fetch-ai", }, - bech32Config: { - bech32PrefixAccAddr: "fetch", - bech32PrefixAccPub: "fetchpub", - bech32PrefixValAddr: "fetchvaloper", - bech32PrefixValPub: "fetchvaloperpub", - bech32PrefixConsAddr: "fetchvalcons", - bech32PrefixConsPub: "fetchvalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("fetch"), bip44: { coinType: 118, }, diff --git a/src/config/web3/cosmos/mainnet/ixo.ts b/src/config/web3/cosmos/mainnet/ixo.ts index 084545127..15092ce27 100644 --- a/src/config/web3/cosmos/mainnet/ixo.ts +++ b/src/config/web3/cosmos/mainnet/ixo.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -22,14 +24,7 @@ export const ixo: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "ixo", - bech32PrefixAccPub: "ixopub", - bech32PrefixValAddr: "ixovaloper", - bech32PrefixValPub: "ixovaloperpub", - bech32PrefixConsAddr: "ixovalcons", - bech32PrefixConsPub: "ixovalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("ixo"), currencies: [ { coinDenom: "IXO", diff --git a/src/config/web3/cosmos/mainnet/ki.ts b/src/config/web3/cosmos/mainnet/ki.ts index 9d7991233..09448f0a5 100644 --- a/src/config/web3/cosmos/mainnet/ki.ts +++ b/src/config/web3/cosmos/mainnet/ki.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -13,14 +15,7 @@ export const ki: CosmosChain = { coinDecimals: 6, coinGeckoId: "ki", }, - bech32Config: { - bech32PrefixAccAddr: "ki", - bech32PrefixAccPub: "kipub", - bech32PrefixValAddr: "kivaloper", - bech32PrefixValPub: "kivaloperpub", - bech32PrefixConsAddr: "kivalcons", - bech32PrefixConsPub: "kivalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("ki"), bip44: { coinType: 118, }, diff --git a/src/config/web3/cosmos/mainnet/kujira.ts b/src/config/web3/cosmos/mainnet/kujira.ts index 1bb339f54..56b401517 100644 --- a/src/config/web3/cosmos/mainnet/kujira.ts +++ b/src/config/web3/cosmos/mainnet/kujira.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -8,14 +10,7 @@ export const kujira: CosmosChain = { rpc: `${COSMOS_PROXY_RPC_MAINNET}/chain/kujira`, rest: "https://lcd.kaiyo.kujira.setten.io", bip44: { coinType: 118 }, - bech32Config: { - bech32PrefixAccAddr: "kujira", - bech32PrefixAccPub: "kujirapub", - bech32PrefixValAddr: "kujiravaloper", - bech32PrefixValPub: "kujiravaloperpub", - bech32PrefixConsAddr: "kujiravalcons", - bech32PrefixConsPub: "kujiravalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("kujira"), currencies: [ { coinDenom: "KUJI", diff --git a/src/config/web3/cosmos/mainnet/neutron.ts b/src/config/web3/cosmos/mainnet/neutron.ts index a5bb2089f..3bd735b4a 100644 --- a/src/config/web3/cosmos/mainnet/neutron.ts +++ b/src/config/web3/cosmos/mainnet/neutron.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -11,14 +13,7 @@ export const neutron: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "neutron", - bech32PrefixAccPub: "neutronpub", - bech32PrefixValAddr: "neutronvaloper", - bech32PrefixValPub: "neutronvaloperpub", - bech32PrefixConsAddr: "neutronvalcons", - bech32PrefixConsPub: "neutronvalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("neutron"), currencies: [ { coinDenom: "NTRN", diff --git a/src/config/web3/cosmos/mainnet/sei.ts b/src/config/web3/cosmos/mainnet/sei.ts index 7053a1c33..33c7ee4f3 100644 --- a/src/config/web3/cosmos/mainnet/sei.ts +++ b/src/config/web3/cosmos/mainnet/sei.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_MAINNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -9,14 +11,7 @@ export const sei: CosmosChain = { rpc: `${COSMOS_PROXY_RPC_MAINNET}/chain/sei`, rest: "https://sei-api.polkachu.com", bip44: { coinType: 118 }, - bech32Config: { - bech32PrefixAccAddr: "sei", - bech32PrefixAccPub: "seipub", - bech32PrefixValAddr: "seivaloper", - bech32PrefixValPub: "seivaloperpub", - bech32PrefixConsAddr: "seivalcons", - bech32PrefixConsPub: "seivalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("sei"), currencies: [{ coinDenom: "SEI", coinMinimalDenom: "usei", coinDecimals: 6 }], feeCurrencies: [ { coinDenom: "SEI", coinMinimalDenom: "usei", coinDecimals: 6 }, diff --git a/src/config/web3/cosmos/testnet/acrechain.ts b/src/config/web3/cosmos/testnet/acrechain.ts index 21afefbb0..ef01fcea4 100644 --- a/src/config/web3/cosmos/testnet/acrechain.ts +++ b/src/config/web3/cosmos/testnet/acrechain.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -14,14 +16,7 @@ export const acrechain: CosmosChain = { coinDecimals: 18, coinGeckoId: "unknown", }, - bech32Config: { - bech32PrefixAccAddr: "acre", - bech32PrefixAccPub: "acrepub", - bech32PrefixValAddr: "acrevaloper", - bech32PrefixValPub: "acrevaloperpub", - bech32PrefixConsAddr: "acrevalcons", - bech32PrefixConsPub: "acrevalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("acre"), bip44: { coinType: 60 }, currencies: [ { diff --git a/src/config/web3/cosmos/testnet/aura.ts b/src/config/web3/cosmos/testnet/aura.ts index 1204914e7..bf63ec543 100644 --- a/src/config/web3/cosmos/testnet/aura.ts +++ b/src/config/web3/cosmos/testnet/aura.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -10,14 +12,7 @@ export const aura: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "aura", - bech32PrefixAccPub: "aura" + "pub", - bech32PrefixValAddr: "aura" + "valoper", - bech32PrefixValPub: "aura" + "valoperpub", - bech32PrefixConsAddr: "aura" + "valcons", - bech32PrefixConsPub: "aura" + "valconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("aura"), currencies: [ { coinDenom: "EAURA", diff --git a/src/config/web3/cosmos/testnet/comdex.ts b/src/config/web3/cosmos/testnet/comdex.ts index 8d7dc29b8..cf4146581 100644 --- a/src/config/web3/cosmos/testnet/comdex.ts +++ b/src/config/web3/cosmos/testnet/comdex.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -14,14 +16,7 @@ export const comdex: CosmosChain = { coinDecimals: 6, coinGeckoId: "cmdx", }, - bech32Config: { - bech32PrefixAccAddr: "comdex", - bech32PrefixAccPub: "comdexpub", - bech32PrefixValAddr: "comdexvaloper", - bech32PrefixValPub: "comdexvaloperpub", - bech32PrefixConsAddr: "comdexvalcons", - bech32PrefixConsPub: "comdexvalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("comdex"), bip44: { coinType: 118, }, diff --git a/src/config/web3/cosmos/testnet/cosmoshub.ts b/src/config/web3/cosmos/testnet/cosmoshub.ts index 5405df0a5..7e29ba6a1 100644 --- a/src/config/web3/cosmos/testnet/cosmoshub.ts +++ b/src/config/web3/cosmos/testnet/cosmoshub.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -11,14 +13,7 @@ export const cosmoshub: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "cosmos", - bech32PrefixAccPub: "cosmospub", - bech32PrefixValAddr: "cosmosvaloper", - bech32PrefixValPub: "cosmosvaloperpub", - bech32PrefixConsAddr: "cosmosvalcons", - bech32PrefixConsPub: "cosmosvalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("cosmos"), currencies: [ { coinDenom: "ATOM", diff --git a/src/config/web3/cosmos/testnet/crescent.ts b/src/config/web3/cosmos/testnet/crescent.ts index f3af37576..f9fee085e 100644 --- a/src/config/web3/cosmos/testnet/crescent.ts +++ b/src/config/web3/cosmos/testnet/crescent.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -11,14 +13,7 @@ export const crescent: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "cre", - bech32PrefixAccPub: "crepub", - bech32PrefixValAddr: "crevaloper", - bech32PrefixValPub: "crevaloperpub", - bech32PrefixConsAddr: "crevalcons", - bech32PrefixConsPub: "crevalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("cre"), currencies: [ { coinDenom: "CRE", diff --git a/src/config/web3/cosmos/testnet/evmos.ts b/src/config/web3/cosmos/testnet/evmos.ts index 4ece4b926..2f76eba08 100644 --- a/src/config/web3/cosmos/testnet/evmos.ts +++ b/src/config/web3/cosmos/testnet/evmos.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -13,14 +15,7 @@ export const evmos: CosmosChain = { coinDecimals: 18, coinGeckoId: "evmos", }, - bech32Config: { - bech32PrefixAccAddr: "evmos", - bech32PrefixAccPub: "evmospub", - bech32PrefixValAddr: "evmosvaloper", - bech32PrefixValPub: "evmosvaloperpub", - bech32PrefixConsAddr: "evmosvalcons", - bech32PrefixConsPub: "evmosvalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("evmos"), bip44: { coinType: 118, }, diff --git a/src/config/web3/cosmos/testnet/kujira.ts b/src/config/web3/cosmos/testnet/kujira.ts index 61da9ccaa..4f222f7f3 100644 --- a/src/config/web3/cosmos/testnet/kujira.ts +++ b/src/config/web3/cosmos/testnet/kujira.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -9,14 +11,7 @@ export const kujira: CosmosChain = { rpc: `${COSMOS_PROXY_RPC_TESTNET}/chain/kujira`, rest: "https://lcd-harpoon.kujira.app", bip44: { coinType: 118 }, - bech32Config: { - bech32PrefixAccAddr: "kujira", - bech32PrefixAccPub: "kujirapub", - bech32PrefixValAddr: "kujiravaloper", - bech32PrefixValPub: "kujiravaloperpub", - bech32PrefixConsAddr: "kujiravalcons", - bech32PrefixConsPub: "kujiravalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("kujira"), currencies: [ { coinDenom: "KUJI", diff --git a/src/config/web3/cosmos/testnet/neutron.ts b/src/config/web3/cosmos/testnet/neutron.ts index c995d9503..373bc6932 100644 --- a/src/config/web3/cosmos/testnet/neutron.ts +++ b/src/config/web3/cosmos/testnet/neutron.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -11,14 +13,7 @@ export const neutron: CosmosChain = { bip44: { coinType: 118, }, - bech32Config: { - bech32PrefixAccAddr: "neutron", - bech32PrefixAccPub: "neutronpub", - bech32PrefixValAddr: "neutronvaloper", - bech32PrefixValPub: "neutronvaloperpub", - bech32PrefixConsAddr: "neutronvalcons", - bech32PrefixConsPub: "neutronvalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("neutron"), currencies: [ { coinDenom: "NTRN", diff --git a/src/config/web3/cosmos/testnet/sei.ts b/src/config/web3/cosmos/testnet/sei.ts index 9b7d01fb1..da3a1bd94 100644 --- a/src/config/web3/cosmos/testnet/sei.ts +++ b/src/config/web3/cosmos/testnet/sei.ts @@ -1,3 +1,5 @@ +import { Bech32Address } from "@keplr-wallet/cosmos"; + import { COSMOS_PROXY_RPC_TESTNET } from "~/config/constants"; import { CosmosChain } from "../interface"; @@ -9,14 +11,7 @@ export const sei: CosmosChain = { rpc: `${COSMOS_PROXY_RPC_TESTNET}/chain/sei`, rest: "https://sei-testnet-api.polkachu.com", bip44: { coinType: 118 }, - bech32Config: { - bech32PrefixAccAddr: "sei", - bech32PrefixAccPub: "seipub", - bech32PrefixValAddr: "seivaloper", - bech32PrefixValPub: "seivaloperpub", - bech32PrefixConsAddr: "seivalcons", - bech32PrefixConsPub: "seivalconspub", - }, + bech32Config: Bech32Address.defaultBech32Config("sei"), currencies: [{ coinDenom: "SEI", coinMinimalDenom: "usei", coinDecimals: 6 }], feeCurrencies: [ { coinDenom: "SEI", coinMinimalDenom: "usei", coinDecimals: 6 },