mirror of
https://github.com/oceanprotocol/market.git
synced 2024-11-14 17:24:51 +01:00
boomarks title fix
This commit is contained in:
parent
31eb89f40f
commit
8eb1023447
@ -3,11 +3,18 @@ import { Link } from 'gatsby'
|
||||
import React, { ReactElement } from 'react'
|
||||
import styles from './AssetTitle.module.css'
|
||||
|
||||
export default function AssetTitle({ did }: { did: string }): ReactElement {
|
||||
const { title } = useMetadata(did)
|
||||
export default function AssetTitle({
|
||||
did,
|
||||
title
|
||||
}: {
|
||||
did?: string
|
||||
title?: string
|
||||
}): ReactElement {
|
||||
const metadata = useMetadata(did)
|
||||
|
||||
return (
|
||||
<h3 className={styles.title}>
|
||||
<Link to={`/asset/${did}`}>{title || did}</Link>
|
||||
<Link to={`/asset/${did}`}>{title || metadata.title || did}</Link>
|
||||
</h3>
|
||||
)
|
||||
}
|
||||
|
@ -27,7 +27,8 @@ const columns = [
|
||||
{
|
||||
name: 'Data Set',
|
||||
selector: function getAssetRow(row: DDO) {
|
||||
return <AssetTitle did={row.id} />
|
||||
const { attributes } = row.findServiceByType('metadata')
|
||||
return <AssetTitle title={attributes.main.name} />
|
||||
},
|
||||
grow: 2
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user