feat: solanatestnet -> eclipsetestnet warp route

dan/eclipsetestnet
Daniel Savu 9 months ago
parent 1b2ae917c5
commit c1a4631b9f
No known key found for this signature in database
GPG Key ID: 795E587829AF7E08
  1. 2
      src/components/nav/Footer.tsx
  2. 72
      src/consts/chains.ts
  3. 10
      src/consts/tokens.ts
  4. 2
      src/features/wallet/SolanaWalletContext.tsx

@ -18,7 +18,7 @@ export function Footer() {
</div>
<div className="hidden sm:flex flex-col ml-3">
<p className="leading-6">
Bridge with the Eclipse Devnet Bridge
Bridge with the Eclipse Testnet Bridge
<br />
Build with <Link href="https://www.hyperlane.xyz">Hyperlane</Link>
</p>

@ -1,6 +1,6 @@
import { ChainMap, ChainMetadata, ExplorerFamily, chainMetadata } from '@hyperlane-xyz/sdk';
import { ChainMap, ChainMetadata, ExplorerFamily } from '@hyperlane-xyz/sdk';
import { chainMetadata, etherToken, solToken } from '@hyperlane-xyz/sdk/dist/consts/chainMetadata';
import { ProtocolType } from '@hyperlane-xyz/utils';
// A map of chain names to ChainMetadata
export const chains: ChainMap<ChainMetadata & { mailbox?: Address }> = {
// ----------- Add your chains here -----------------
@ -40,40 +40,56 @@ export const chains: ChainMap<ChainMetadata & { mailbox?: Address }> = {
mailbox: 'Ge9atjAc3Ltu91VTbNpJDCjZ9CFxFyck4h3YBcTF9XPq',
},
solanatestnet: {
...chainMetadata.solanatestnet,
mailbox: 'TODO',
},
solanadevnet: {
...chainMetadata.solanadevnet,
mailbox: '4v25Dz9RccqUrTzmfHzJMsjd1iVoNrWzeJ4o6GYuJrVn',
},
eclipsedevnet: {
protocol: ProtocolType.Sealevel,
chainId: 3131313,
domainId: 3131313,
name: 'eclipsedevnet',
displayName: 'Eclipse Devnet',
nativeToken: {
"name": "Eclipse",
"symbol": "ECLIPSE",
"decimals": 9
},
rpcUrls: [{ http: 'https://staging-rpc.dev2.eclipsenetwork.xyz' }],
blockExplorers: [
// {
// name: 'Solana Explorer',
// url: 'https://explorer.solana.com',
// apiUrl: 'https://explorer.solana.com',
// family: ExplorerFamily.Other,
// },
{
apiUrl: 'https://explorer.solana.com',
family: ExplorerFamily.Other,
name: 'Solana Explorer',
url: 'https://explorer.solana.com',
},
],
blocks: {
confirmations: 1,
estimateBlockTime: 0.4,
reorgPeriod: 0,
},
chainId: 1399811150,
displayName: 'Solana Testnet',
displayNameShort: 'Sol Testnet',
domainId: 1399811150,
isTestnet: true,
name: 'solanatestnet',
nativeToken: solToken,
protocol: ProtocolType.Sealevel,
rpcUrls: [{ http: 'https://api.testnet.solana.com' }],
mailbox: '75HBBLae3ddeneJVrZeyrDfv6vb7SMC3aCpBucSXS5aR'
},
eclipsetestnet: {
blockExplorers: [
{
apiUrl: 'https://testnet.dev2.eclipsenetwork.xyz',
family: ExplorerFamily.Other,
name: 'Eclipse Testnet Explorer',
url: 'https://explorer.dev.eclipsenetwork.xyz/?cluster=testnet',
},
],
blocks: {
confirmations: 1,
estimateBlockTime: 0.4,
reorgPeriod: 0,
},
chainId: 239092742,
displayName: 'Eclipse Testnet',
domainId: 239092742,
isTestnet: true,
mailbox: 'AATtwuHptB6ruozdwc3XUFwGCuPfZL6jwPid955RoL6N',
name: 'eclipsetestnet',
nativeToken: {
...etherToken,
decimals: 9,
},
protocol: ProtocolType.Sealevel,
rpcUrls: [{ http: 'https://testnet.dev2.eclipsenetwork.xyz' }],
mailbox: '75HBBLae3ddeneJVrZeyrDfv6vb7SMC3aCpBucSXS5aR'
},
proteustestnet: {
chainId: 88002,

@ -24,14 +24,14 @@ export const tokenList: WarpTokenConfig = [
// logoURI: '/logos/zebec.png',
// },
// solanadevnet to eclipse
// solanatestnet to eclipsetestnet
{
type: 'native',
chainId: 1399811151,
chainId: 1399811150,
// address: 'wzbcJyhGhQDLTV1S99apZiiBdE4jmYfbw99saMMdP59',
hypNativeAddress: '62V5Sv2HeLZ4RqwxwYjaBQ7K9cqHbfert9pVtjfrxgYG',
name: 'Devnet SOL',
symbol: 'devSOL',
hypNativeAddress: 'DF99ZiHj8aN4ETbKmpMoMsRTSbm7gtL5j6sKKLC5mkTS',
name: 'Testnet SOL',
symbol: 'testSOL',
decimals: 9,
// isSpl2022: false,
logoURI: '/logos/solana.svg',

@ -16,7 +16,7 @@ import { logger } from '../../utils/logger';
export function SolanaWalletContext({ children }: PropsWithChildren<unknown>) {
// TODO support multiple networks
const network = WalletAdapterNetwork.Devnet;
const network = WalletAdapterNetwork.Testnet;
const endpoint = useMemo(() => clusterApiUrl(network), [network]);
const wallets = useMemo(
() => [

Loading…
Cancel
Save