refactor(i18n): 移除 chrome.i18n 国际化,统一使用中文硬编码

移除 chromeI18n 工具、_locales 翻译文件和 manifest default_locale 配置,
将所有 UI 文案改为直接硬编码中文,并更新相关测试与文档。
This commit is contained in:
雨霖铃
2026-06-18 14:22:14 +00:00
parent 618f3c36f2
commit ec92afa294
68 changed files with 531 additions and 2148 deletions
@@ -1,5 +1,4 @@
import React from 'react';
import { useI18n } from '@/utils/chromeI18n';
import { cn } from '@/lib/utils';
import JsonTree from './JsonTree';
import type { DiffNode, DiffResult as DiffResultType, DiffType, ViewMode } from '../types';
@@ -17,8 +16,6 @@ export default function DiffResult({
className,
...props
}: DiffResultProps) {
const { t } = useI18n('jsonDiff');
if (viewMode === 'sideBySide') {
return (
<div
@@ -26,11 +23,11 @@ export default function DiffResult({
{...props}
>
<div className="flex-1 min-w-0">
<SectionLabel text={t('jsonDiff:leftLabel')} />
<SectionLabel text={'原始 JSON'} />
<JsonTree node={result.root} side="left" activePath={activePath} />
</div>
<div className="flex-1 min-w-0">
<SectionLabel text={t('jsonDiff:rightLabel')} />
<SectionLabel text={'目标 JSON'} />
<JsonTree node={result.root} side="right" activePath={activePath} />
</div>
</div>