From 5288238694cfe944962ef2b9d3c292bbc86f84dc Mon Sep 17 00:00:00 2001 From: Jason Date: Tue, 7 Apr 2026 16:38:49 +0800 Subject: [PATCH] refactor: tighten OAuth Auth Center copy, layout, and icon - Trim Auth Center section descriptions to focus on user intent - Remove duplicate outer heading on the auth settings tab - Swap Sparkles glyph for CodexIcon on the ChatGPT card - Generalize codexOauth.authStatus to a neutral "Auth status" - Register settings.authCenter.* keys across zh/en/ja locales --- .../providers/forms/CodexOAuthSection.tsx | 2 +- src/components/settings/AuthCenterPanel.tsx | 13 ++++++------- src/components/settings/SettingsPage.tsx | 18 ------------------ src/i18n/locales/en.json | 9 ++++++++- src/i18n/locales/ja.json | 9 ++++++++- src/i18n/locales/zh.json | 9 ++++++++- 6 files changed, 31 insertions(+), 29 deletions(-) diff --git a/src/components/providers/forms/CodexOAuthSection.tsx b/src/components/providers/forms/CodexOAuthSection.tsx index a45bd2186..8f66b4dca 100644 --- a/src/components/providers/forms/CodexOAuthSection.tsx +++ b/src/components/providers/forms/CodexOAuthSection.tsx @@ -89,7 +89,7 @@ export const CodexOAuthSection: React.FC = ({
{/* 认证状态标题 */}
- + {t("settings.authCenter.description", { defaultValue: - "集中管理跨应用复用的 OAuth 账号。Provider 只绑定这些认证源,不再重复登录。", + "在 Claude Code 中使用您的其他订阅,请注意合规风险。", })}

@@ -42,8 +43,7 @@ export function AuthCenterPanel() {

GitHub Copilot

{t("settings.authCenter.copilotDescription", { - defaultValue: - "管理 GitHub Copilot 账号、默认账号以及供 Claude / Codex / Gemini 绑定的托管凭据。", + defaultValue: "管理 GitHub Copilot 账号", })}

@@ -55,14 +55,13 @@ export function AuthCenterPanel() {
- +

ChatGPT (Codex OAuth)

{t("settings.authCenter.codexOauthDescription", { - defaultValue: - "管理 ChatGPT Plus/Pro 账号,用于将 Claude Code 请求反代到 Codex 后端。仅限个人开发使用。", + defaultValue: "管理 ChatGPT 账号", })}

diff --git a/src/components/settings/SettingsPage.tsx b/src/components/settings/SettingsPage.tsx index 5acd350dd..d10e57f30 100644 --- a/src/components/settings/SettingsPage.tsx +++ b/src/components/settings/SettingsPage.tsx @@ -9,7 +9,6 @@ import { ScrollText, HardDriveDownload, FlaskConical, - KeyRound, } from "lucide-react"; import { toast } from "sonner"; import { @@ -272,23 +271,6 @@ export function SettingsPage({ transition={{ duration: 0.3 }} className="space-y-6" > -
- -
-

- {t("settings.authCenter.heading", { - defaultValue: "认证中心", - })} -

-

- {t("settings.authCenter.headingDescription", { - defaultValue: - "统一管理可跨应用复用的 OAuth 账号和默认认证来源。", - })} -

-
-
- diff --git a/src/i18n/locales/en.json b/src/i18n/locales/en.json index 6d9f1e5a9..f2475be26 100644 --- a/src/i18n/locales/en.json +++ b/src/i18n/locales/en.json @@ -225,6 +225,13 @@ "tabGeneral": "General", "tabAdvanced": "Advanced", "tabProxy": "Proxy", + "authCenter": { + "title": "OAuth Authentication Center", + "description": "Use your other subscriptions in Claude Code — please be mindful of compliance risks.", + "beta": "Beta", + "copilotDescription": "Manage GitHub Copilot accounts", + "codexOauthDescription": "Manage ChatGPT accounts" + }, "advanced": { "configDir": { "title": "Configuration Directory", @@ -846,7 +853,7 @@ "loadModelsFailed": "Failed to load Copilot models" }, "codexOauth": { - "authStatus": "ChatGPT Plus/Pro Auth", + "authStatus": "Auth status", "notAuthenticated": "Not authenticated", "loginWithChatGPT": "Sign in with ChatGPT", "loginRequired": "Please sign in to ChatGPT first", diff --git a/src/i18n/locales/ja.json b/src/i18n/locales/ja.json index 853b466d0..3aa2f7006 100644 --- a/src/i18n/locales/ja.json +++ b/src/i18n/locales/ja.json @@ -225,6 +225,13 @@ "tabGeneral": "一般", "tabAdvanced": "詳細", "tabProxy": "プロキシ", + "authCenter": { + "title": "OAuth 認証センター", + "description": "Claude Code で他のサブスクリプションをご利用いただけます。コンプライアンスリスクにご注意ください。", + "beta": "Beta", + "copilotDescription": "GitHub Copilot アカウントを管理します", + "codexOauthDescription": "ChatGPT アカウントを管理します" + }, "advanced": { "configDir": { "title": "設定ディレクトリ", @@ -846,7 +853,7 @@ "loadModelsFailed": "Copilot モデル一覧の読み込みに失敗しました" }, "codexOauth": { - "authStatus": "ChatGPT Plus/Pro 認証", + "authStatus": "認証状態", "notAuthenticated": "未認証", "loginWithChatGPT": "ChatGPT でログイン", "loginRequired": "先に ChatGPT にログインしてください", diff --git a/src/i18n/locales/zh.json b/src/i18n/locales/zh.json index 7e02c19d6..7148b5bde 100644 --- a/src/i18n/locales/zh.json +++ b/src/i18n/locales/zh.json @@ -225,6 +225,13 @@ "tabGeneral": "通用", "tabAdvanced": "高级", "tabProxy": "代理", + "authCenter": { + "title": "OAuth 认证中心", + "description": "在 Claude Code 中使用您的其他订阅,请注意合规风险。", + "beta": "Beta", + "copilotDescription": "管理 GitHub Copilot 账号", + "codexOauthDescription": "管理 ChatGPT 账号" + }, "advanced": { "configDir": { "title": "配置文件目录", @@ -846,7 +853,7 @@ "loadModelsFailed": "加载 Copilot 模型列表失败" }, "codexOauth": { - "authStatus": "ChatGPT Plus/Pro 认证", + "authStatus": "认证状态", "notAuthenticated": "未认证", "loginWithChatGPT": "使用 ChatGPT 登录", "loginRequired": "请先登录 ChatGPT 账号",