mirror of
https://github.com/oceanprotocol/market.git
synced 2024-12-02 05:57:29 +01:00
* updated subgraph query * rework AccountList * fix missing 'a' elem in dom (<Link> is not rendering correct markup) * restore PublishersWithMostSales section * removed unnecessary params in AssetList * use Blockies for all profile.image * changed logic on getTopAssetsPublishers * added aggregations op to getTopAssetsPublishers method * fix build issues * improve logic & added correct total sales on profile * removed complex logic to unify query * typography & markup cleanup Co-authored-by: Matthias Kretschmann <m@kretschmann.io>
29 lines
573 B
TypeScript
29 lines
573 B
TypeScript
import { toDataUrl } from 'myetherwallet-blockies'
|
|
import React, { ReactElement } from 'react'
|
|
import styles from './index.module.css'
|
|
|
|
export interface BlockiesProps {
|
|
accountId: string
|
|
className?: string
|
|
image?: string
|
|
}
|
|
|
|
export default function Blockies({
|
|
accountId,
|
|
className,
|
|
image
|
|
}: BlockiesProps): ReactElement {
|
|
if (!accountId) return null
|
|
|
|
const blockies = toDataUrl(accountId)
|
|
|
|
return (
|
|
<img
|
|
className={`${className || ''} ${styles.blockies} `}
|
|
src={image || blockies}
|
|
alt="Blockies"
|
|
aria-hidden="true"
|
|
/>
|
|
)
|
|
}
|