chore(website/i18n): missing translations in header

This commit is contained in:
Elian Doran 2025-10-25 20:10:11 +03:00
parent 2697f9a25d
commit eb93762ecc
No known key found for this signature in database
3 changed files with 18 additions and 6 deletions

View File

@ -106,6 +106,11 @@
"linux_small": "for Linux",
"more_platforms": "More platforms & server setup"
},
"header": {
"get-started": "Get started",
"documentation": "Documentation",
"support-us": "Support us"
},
"footer": {
"copyright_and_the": " and the ",
"copyright_community": "community"

View File

@ -106,6 +106,11 @@
"linux_small": "pentru Linux",
"more_platforms": "Mai multe platforme și instalarea server-ului"
},
"header": {
"get-started": "Primii pași",
"documentation": "Documentație",
"support-us": "Sprijină-ne"
},
"footer": {
"copyright_and_the": " și ",
"copyright_community": "comunitatea"

View File

@ -9,6 +9,7 @@ import Icon from "./Icon.js";
import logoPath from "../assets/icon-color.svg";
import menuIcon from "../assets/boxicons/bx-menu.svg?raw";
import { LocaleContext } from "..";
import { useTranslation } from "react-i18next";
interface HeaderLink {
url: string;
@ -16,17 +17,18 @@ interface HeaderLink {
external?: boolean;
}
const HEADER_LINKS: HeaderLink[] = [
{ url: "/get-started/", text: "Get started" },
{ url: "https://docs.triliumnotes.org/", text: "Documentation", external: true },
{ url: "/support-us/", text: "Support us" }
]
export function Header(props: {repoStargazersCount: number}) {
const { url } = useLocation();
const { t } = useTranslation();
const locale = useContext(LocaleContext);
const [ mobileMenuShown, setMobileMenuShown ] = useState(false);
const HEADER_LINKS = useMemo<HeaderLink[]>(() => [
{ url: "/get-started/", text: t("header.get-started") },
{ url: "https://docs.triliumnotes.org/", text: t("header.documentation"), external: true },
{ url: "/support-us/", text: t("header.support-us") }
], [ locale ]);
return (
<header>
<div class="content-wrapper">