Etherscan link broken (#1255)
* Add default type * update deps * Rename variables * Update link * hardcode link type * remove optional type prop for etherscanlink Co-authored-by: Mikhail Mikheev <mmvsha73@gmail.com>
This commit is contained in:
parent
8a13d333d2
commit
50995c3f0c
|
@ -17,7 +17,7 @@ interface EtherscanLinkProps {
|
|||
className?: string
|
||||
cut?: number
|
||||
knownAddress?: boolean
|
||||
type?: 'tx' | 'address'
|
||||
type: 'tx' | 'address'
|
||||
value: string
|
||||
}
|
||||
|
||||
|
|
|
@ -59,7 +59,6 @@ const TxInfoDetails = ({ data }: { data: DataDecoded }): React.ReactElement => (
|
|||
<InlineText size="lg" strong>
|
||||
{param.name}({param.type}):
|
||||
</InlineText>
|
||||
|
||||
<Value method={data.method} type={param.type} value={param.value} />
|
||||
</TxDetailsMethodParam>
|
||||
))}
|
||||
|
|
|
@ -47,13 +47,13 @@ const EtherscanLink = ({ method, type, value }: RenderValueProps): React.ReactEl
|
|||
return (
|
||||
<NestedWrapper>
|
||||
{(value as string[]).map((value, index) => (
|
||||
<SafeEtherscanLink key={`${method}-value-${index}`} cut={cut} value={value} />
|
||||
<SafeEtherscanLink type="address" key={`${method}-value-${index}`} cut={cut} value={value} />
|
||||
))}
|
||||
</NestedWrapper>
|
||||
)
|
||||
}
|
||||
|
||||
return <SafeEtherscanLink className={classes.address} cut={cut} value={value as string} />
|
||||
return <SafeEtherscanLink type="address" className={classes.address} cut={cut} value={value as string} />
|
||||
}
|
||||
|
||||
const GenericValue = ({ method, type, value }: RenderValueProps): React.ReactElement => {
|
||||
|
|
Loading…
Reference in New Issue