From 668ee219c67e6019bc3d4e3e9bc764fe55cbea58 Mon Sep 17 00:00:00 2001 From: Elian Doran Date: Tue, 9 Dec 2025 23:02:21 +0200 Subject: [PATCH] chore(layout): use translation for badges --- apps/client/src/translations/en/translation.json | 6 ++++++ apps/client/src/widgets/BreadcrumbBadges.tsx | 5 +++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/apps/client/src/translations/en/translation.json b/apps/client/src/translations/en/translation.json index 92dbc07cb..3dcd231bc 100644 --- a/apps/client/src/translations/en/translation.json +++ b/apps/client/src/translations/en/translation.json @@ -2129,5 +2129,11 @@ "tab_history_navigation_buttons": { "go-back": "Go back to previous note", "go-forward": "Go forward to next note" + }, + "breadcrumb_badges": { + "read_only_explicit": "Read-only", + "read_only_auto": "Auto read-only", + "shared_publicly": "Shared publicly", + "shared_locally": "Shared locally" } } diff --git a/apps/client/src/widgets/BreadcrumbBadges.tsx b/apps/client/src/widgets/BreadcrumbBadges.tsx index 9a89652bb..3bb3c06b6 100644 --- a/apps/client/src/widgets/BreadcrumbBadges.tsx +++ b/apps/client/src/widgets/BreadcrumbBadges.tsx @@ -5,6 +5,7 @@ import { useIsNoteReadOnly, useNoteContext } from "./react/hooks"; import Icon from "./react/Icon"; import { useShareInfo } from "./shared_info"; import clsx from "clsx"; +import { t } from "../services/i18n"; export default function BreadcrumbBadges() { return ( @@ -24,7 +25,7 @@ function ReadOnlyBadge() { enableEditing()}> - {isExplicitReadOnly ? "Read-only" : "Auto read-only"} + {isExplicitReadOnly ? t("breadcrumb_badges.read_only_explicit") : t("breadcrumb_badges.read_only_auto")} ); } @@ -37,7 +38,7 @@ function ShareBadge() { - {isSharedExternally ? "Shared publicly" : "Shared locally"} + {isSharedExternally ? t("breadcrumb_badges.shared_publicly") : t("breadcrumb_badges.shared_locally")} ); }