mirror of
https://github.com/oceanprotocol/market.git
synced 2024-12-02 05:57:29 +01:00
* output total datatoken liquidity in footer stats * add build id to footer * write out repo metadata before build * build tweaks * add title * refactor
24 lines
680 B
TypeScript
24 lines
680 B
TypeScript
import React, { ReactElement } from 'react'
|
|
import repoMetadata from '../../../repo-metadata.json'
|
|
import styles from './BuildId.module.css'
|
|
|
|
export default function BuildId(): ReactElement {
|
|
const commitBranch = repoMetadata.branch
|
|
const commitId = repoMetadata.commit
|
|
const isMainBranch = commitBranch === 'main'
|
|
|
|
return (
|
|
<a
|
|
className={styles.buildId}
|
|
href={`https://github.com/oceanprotocol/market/tree/${
|
|
isMainBranch ? commitId : commitBranch
|
|
}`}
|
|
target="_blank"
|
|
rel="noreferrer"
|
|
title="Build ID referring to the linked commit hash."
|
|
>
|
|
{isMainBranch ? commitId.substring(0, 7) : commitBranch}
|
|
</a>
|
|
)
|
|
}
|