mirror of
https://github.com/oceanprotocol/commons.git
synced 2023-03-15 18:03:00 +01:00
output version number in footer
This commit is contained in:
parent
c742426b1a
commit
2395c3ff21
@ -91,3 +91,9 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.version {
|
||||||
|
font-family: $font-family-monospace;
|
||||||
|
font-size: $font-size-mini;
|
||||||
|
margin-top: $spacer;
|
||||||
|
}
|
||||||
|
@ -5,6 +5,33 @@ import { ReactComponent as AiCommons } from '../../img/aicommons.svg'
|
|||||||
import styles from './Footer.module.scss'
|
import styles from './Footer.module.scss'
|
||||||
|
|
||||||
import meta from '../../data/meta.json'
|
import meta from '../../data/meta.json'
|
||||||
|
import { version } from '../../../package.json'
|
||||||
|
import { version as versionSquid } from '@oceanprotocol/squid/package.json'
|
||||||
|
|
||||||
|
const VersionNumber = () => {
|
||||||
|
const versionOutput =
|
||||||
|
process.env.NODE_ENV === 'production'
|
||||||
|
? `v${version}`
|
||||||
|
: `v${version}-dev`
|
||||||
|
|
||||||
|
return (
|
||||||
|
<p className={styles.version}>
|
||||||
|
<a
|
||||||
|
title="See commons release on GitHub"
|
||||||
|
href={`https://github.com/oceanprotocol/commons/releases/tag/v${version}`}
|
||||||
|
>
|
||||||
|
{versionOutput}
|
||||||
|
</a>{' '}
|
||||||
|
—{' '}
|
||||||
|
<a
|
||||||
|
title="See squid-js release on GitHub"
|
||||||
|
href={`https://github.com/oceanprotocol/squid-js/releases/tag/v${versionSquid}`}
|
||||||
|
>
|
||||||
|
squid-js v{versionSquid}
|
||||||
|
</a>
|
||||||
|
</p>
|
||||||
|
)
|
||||||
|
}
|
||||||
|
|
||||||
const Footer = () => (
|
const Footer = () => (
|
||||||
<footer className={styles.footer}>
|
<footer className={styles.footer}>
|
||||||
@ -30,6 +57,7 @@ const Footer = () => (
|
|||||||
<AiCommons />
|
<AiCommons />
|
||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
|
<VersionNumber />
|
||||||
</Content>
|
</Content>
|
||||||
</aside>
|
</aside>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user