From 4eaf3508c1008cf7146c4c4364e372de465afaf4 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?=E5=90=B9=E9=9B=AA?= <2b@yorha.xyz>
Date: Thu, 11 Jun 2026 06:03:39 +0900
Subject: [PATCH] feat(ui): i18n for key info header and edit view
---
.../components/templates/KeyInfoHeader.tsx | 59 ++++---
.../components/templates/key_edit_view.tsx | 153 +++++++++---------
ui/litellm-dashboard/src/locales/en.json | 87 ++++++++++
ui/litellm-dashboard/src/locales/zh-CN.json | 87 ++++++++++
4 files changed, 295 insertions(+), 91 deletions(-)
diff --git a/ui/litellm-dashboard/src/components/templates/KeyInfoHeader.tsx b/ui/litellm-dashboard/src/components/templates/KeyInfoHeader.tsx
index c9c393352cc..5b40ce0c0c1 100644
--- a/ui/litellm-dashboard/src/components/templates/KeyInfoHeader.tsx
+++ b/ui/litellm-dashboard/src/components/templates/KeyInfoHeader.tsx
@@ -13,6 +13,7 @@ import {
TransactionOutlined,
FieldTimeOutlined,
} from "@ant-design/icons";
+import { useTranslation } from "react-i18next";
import LabeledField from "../common_components/LabeledField";
import DefaultProxyAdminTag from "../common_components/DefaultProxyAdminTag";
@@ -45,13 +46,14 @@ interface KeyInfoHeaderProps {
}
function UserField({ userAlias, userEmail, userId }: { userAlias?: string | null; userEmail: string; userId: string }) {
+ const { t } = useTranslation();
const labelEl = (