2020-08-07 11:27:12 +02:00
|
|
|
import React from 'react';
|
2020-10-03 19:53:06 +02:00
|
|
|
import classNames from 'classnames';
|
2021-05-15 10:29:39 +02:00
|
|
|
import { FormattedMessage } from 'react-intl';
|
2020-09-16 05:34:30 +02:00
|
|
|
import Link from 'components/common/Link';
|
2020-08-07 11:27:12 +02:00
|
|
|
import styles from './Footer.module.css';
|
2022-06-24 10:54:55 +02:00
|
|
|
import useStore from 'store/version';
|
2022-07-16 08:53:31 +02:00
|
|
|
import { HOMEPAGE_URL, REPO_URL } from 'lib/constants';
|
2020-08-07 11:27:12 +02:00
|
|
|
|
|
|
|
export default function Footer() {
|
2022-06-24 10:54:55 +02:00
|
|
|
const { current } = useStore();
|
2021-05-13 08:15:37 +02:00
|
|
|
|
2020-08-07 11:27:12 +02:00
|
|
|
return (
|
2022-03-01 03:39:37 +01:00
|
|
|
<footer className={classNames(styles.footer, 'row')}>
|
|
|
|
<div className="col-12 col-md-4" />
|
|
|
|
<div className="col-12 col-md-4">
|
|
|
|
<FormattedMessage
|
|
|
|
id="message.powered-by"
|
|
|
|
defaultMessage="Powered by {name}"
|
|
|
|
values={{
|
|
|
|
name: (
|
|
|
|
<Link href={HOMEPAGE_URL}>
|
|
|
|
<b>umami</b>
|
|
|
|
</Link>
|
|
|
|
),
|
|
|
|
}}
|
|
|
|
/>
|
|
|
|
</div>
|
|
|
|
<div className={classNames(styles.version, 'col-12 col-md-4')}>
|
2022-07-16 08:53:31 +02:00
|
|
|
<Link href={REPO_URL}>{`v${current}`}</Link>
|
2020-08-15 10:17:15 +02:00
|
|
|
</div>
|
2022-07-16 08:53:31 +02:00
|
|
|
{!process.env.telemetryDisabled && (
|
|
|
|
<img src={`https://i.umami.is/a.png?v=${current}`} alt="" />
|
|
|
|
)}
|
2020-08-07 11:27:12 +02:00
|
|
|
</footer>
|
|
|
|
);
|
|
|
|
}
|