aboutsummaryrefslogtreecommitdiffstats
path: root/apps/web/components/settings/sidebar/items.tsx
diff options
context:
space:
mode:
authorMohamed Bassem <me@mbassem.com>2024-11-17 00:33:28 +0000
committerGitHub <noreply@github.com>2024-11-17 00:33:28 +0000
commit4354ee7ba1c6ac9a9567944ae6169b1664e0ea8a (patch)
treee27c9070930514d77582bae00b3350274116179c /apps/web/components/settings/sidebar/items.tsx
parent9f2c7be23769bb0f4102736a683710b1a1939661 (diff)
downloadkarakeep-4354ee7ba1c6ac9a9567944ae6169b1664e0ea8a.tar.zst
feature: Add i18n support. Fixes #57 (#635)
* feature(web): Add basic scaffolding for i18n * refactor: Switch most of the app's strings to use i18n strings * fix: Remove unused i18next-resources-for-ts command * Add user setting * More translations * Drop the german translation for now
Diffstat (limited to 'apps/web/components/settings/sidebar/items.tsx')
-rw-r--r--apps/web/components/settings/sidebar/items.tsx19
1 files changed, 11 insertions, 8 deletions
diff --git a/apps/web/components/settings/sidebar/items.tsx b/apps/web/components/settings/sidebar/items.tsx
index 047ee233..43dfabdd 100644
--- a/apps/web/components/settings/sidebar/items.tsx
+++ b/apps/web/components/settings/sidebar/items.tsx
@@ -1,4 +1,5 @@
import React from "react";
+import { TFunction } from "i18next";
import {
ArrowLeft,
Download,
@@ -8,38 +9,40 @@ import {
User,
} from "lucide-react";
-export const settingsSidebarItems: {
+export const settingsSidebarItems = (
+ t: TFunction,
+): {
name: string;
icon: JSX.Element;
path: string;
-}[] = [
+}[] => [
{
- name: "Back To App",
+ name: t("settings.back_to_app"),
icon: <ArrowLeft size={18} />,
path: "/dashboard/bookmarks",
},
{
- name: "User Info",
+ name: t("settings.info.user_info"),
icon: <User size={18} />,
path: "/settings/info",
},
{
- name: "AI Settings",
+ name: t("settings.ai.ai_settings"),
icon: <Sparkles size={18} />,
path: "/settings/ai",
},
{
- name: "RSS Subscriptions",
+ name: t("settings.feeds.rss_subscriptions"),
icon: <Rss size={18} />,
path: "/settings/feeds",
},
{
- name: "Import / Export",
+ name: t("settings.import.import_export"),
icon: <Download size={18} />,
path: "/settings/import",
},
{
- name: "API Keys",
+ name: t("settings.api_keys.api_keys"),
icon: <KeyRound size={18} />,
path: "/settings/api-keys",
},