wallet-connect-web-examples/wallets/react-wallet-eip155/src/components/RequestDetalilsCard.tsx
0xAsimetriq 2379c795ce
eip155 example (#115)
* eip155 example

* temp fix for duplicate accs
2023-02-15 17:11:42 +02:00

39 lines
794 B
TypeScript

import { EIP155_CHAINS, TEIP155Chain } from '@/data/EIP155Data'
import { Col, Divider, Row, Text } from '@nextui-org/react'
import { Fragment } from 'react'
/**
* Types
*/
interface IProps {
chains: string[]
protocol: string
}
/**
* Component
*/
export default function RequesDetailsCard({ chains, protocol }: IProps) {
return (
<Fragment>
<Row>
<Col>
<Text h5>Blockchain(s)</Text>
<Text color="$gray400">
{chains.map(chain => EIP155_CHAINS[chain as TEIP155Chain]?.name ?? chain).join(', ')}
</Text>
</Col>
</Row>
<Divider y={2} />
<Row>
<Col>
<Text h5>Relay Protocol</Text>
<Text color="$gray400">{protocol}</Text>
</Col>
</Row>
</Fragment>
)
}