website: fix broken links in NewsBar
Signed-off-by: Jens Langhammer <jens@goauthentik.io>
This commit is contained in:
parent
198e6b0d2e
commit
f38fdfff6e
|
@ -19,9 +19,10 @@ export function getReleases(): ItemLink[] {
|
||||||
);
|
);
|
||||||
const releaseVersion: ItemLink[] = releaseItems.map((relUrl: string) => {
|
const releaseVersion: ItemLink[] = releaseItems.map((relUrl: string) => {
|
||||||
const [_, year, version] = relUrl.split("/");
|
const [_, year, version] = relUrl.split("/");
|
||||||
|
const url = useBaseUrl(`docs/releases/${version.replace("v", "")}`);
|
||||||
return {
|
return {
|
||||||
label: `authentik ${version} released!`,
|
label: `authentik ${version} released!`,
|
||||||
link: relUrl,
|
link: url,
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
return releaseVersion;
|
return releaseVersion;
|
||||||
|
@ -34,7 +35,7 @@ export function NewsBar() {
|
||||||
<div className="items">
|
<div className="items">
|
||||||
{getReleases().map((version) => {
|
{getReleases().map((version) => {
|
||||||
return (
|
return (
|
||||||
<a key={version.link} href={useBaseUrl(version.link)}>
|
<a key={version.link} href={version.link}>
|
||||||
{version.label}
|
{version.label}
|
||||||
</a>
|
</a>
|
||||||
);
|
);
|
||||||
|
|
Reference in New Issue