2022-08-28 20:12:09 +02:00
|
|
|
import Link from 'next/link';
|
|
|
|
import styled from 'styled-components';
|
|
|
|
import { Text13 } from './Typography';
|
|
|
|
|
|
|
|
export interface CurrentVersionProps {
|
|
|
|
version: string;
|
|
|
|
}
|
2023-03-19 21:23:43 +01:00
|
|
|
export function CurrentVersion({ version }: CurrentVersionProps) {
|
2022-08-28 20:12:09 +02:00
|
|
|
return (
|
2023-01-11 19:08:14 +01:00
|
|
|
<Link href={'/docs/changelog'} passHref legacyBehavior>
|
2023-09-25 00:31:45 +02:00
|
|
|
<Container as={'a'}>{version}</Container>
|
2022-08-28 20:12:09 +02:00
|
|
|
</Link>
|
|
|
|
);
|
|
|
|
}
|
|
|
|
|
|
|
|
const Container = styled(Text13)`
|
2023-09-25 04:43:10 +02:00
|
|
|
&&& {
|
|
|
|
color: var(--g1);
|
|
|
|
font-weight: 700;
|
|
|
|
background: var(--g5);
|
|
|
|
line-height: 1;
|
|
|
|
padding: 7px 16px;
|
|
|
|
border-radius: 200px;
|
|
|
|
display: block;
|
|
|
|
text-decoration: none;
|
|
|
|
transition:
|
|
|
|
color 0.1s linear,
|
|
|
|
background 0.1s linear;
|
|
|
|
&:hover {
|
|
|
|
background: var(--black);
|
|
|
|
color: var(--white);
|
|
|
|
}
|
2022-11-10 01:48:15 +01:00
|
|
|
}
|
2022-08-28 20:12:09 +02:00
|
|
|
`;
|