status/src/components/Network/index.tsx

33 lines
717 B
TypeScript

import React from 'react'
import styles from './index.module.css'
import Data from './Data'
export interface NetworkProps {
name: string
project?: string
networkId: string
chainId?: string
type: string
rpcUrl?: string
explorerUrl?: string
}
export default function Network({ network }: { network: NetworkProps }) {
return (
<div className={styles.network}>
<header className={styles.networkHeader}>
<h2 className={styles.title}>
{network.name}
<code>{network.networkId}</code>
<span>{network.type}</span>
</h2>
<p>
<code>{network.rpcUrl}</code>
</p>
</header>
<Data network={network} />
</div>
)
}