From 24aa57417667a49037a413432c1a7bd22999f391 Mon Sep 17 00:00:00 2001 From: alger Date: Sun, 15 Mar 2026 15:57:17 +0800 Subject: [PATCH] =?UTF-8?q?fix(i18n):=20=E8=A1=A5=E5=85=A8=20MV/=E6=8E=92?= =?UTF-8?q?=E8=A1=8C=E6=A6=9C/=E6=AD=8C=E5=8D=95/=E6=90=9C=E7=B4=A2/?= =?UTF-8?q?=E4=B8=93=E8=BE=91=E9=A1=B5=E9=9D=A2=E7=BC=BA=E5=A4=B1=E7=9A=84?= =?UTF-8?q?=E5=9B=BD=E9=99=85=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - 新增 comp.pages 命名空间,包含页面描述、地区分类、加载状态等 i18n 键 - toplist: 标题和描述文本国际化 - mv: 描述、加载状态、6 个地区分类标签国际化 - list: 描述、加载/无更多状态国际化,提取每日推荐常量 - search: 描述文本国际化 - album: 5 个地区分类标签国际化 - 覆盖全部 5 种语言 (zh-CN/en-US/ja-JP/ko-KR/zh-Hant) --- src/i18n/lang/en-US/comp.ts | 36 +++++++++++++++++++++++++++- src/i18n/lang/ja-JP/comp.ts | 36 +++++++++++++++++++++++++++- src/i18n/lang/ko-KR/comp.ts | 36 +++++++++++++++++++++++++++- src/i18n/lang/zh-CN/comp.ts | 36 +++++++++++++++++++++++++++- src/i18n/lang/zh-Hant/comp.ts | 36 +++++++++++++++++++++++++++- src/renderer/views/album/index.vue | 17 ++++++------- src/renderer/views/list/index.vue | 21 +++++++++------- src/renderer/views/mv/index.vue | 26 ++++++++++---------- src/renderer/views/search/index.vue | 2 +- src/renderer/views/toplist/index.vue | 6 +++-- 10 files changed, 215 insertions(+), 37 deletions(-) diff --git a/src/i18n/lang/en-US/comp.ts b/src/i18n/lang/en-US/comp.ts index b04d139..3e2000b 100644 --- a/src/i18n/lang/en-US/comp.ts +++ b/src/i18n/lang/en-US/comp.ts @@ -280,5 +280,39 @@ export default { home: 'Home', search: 'Search', album: 'Album', - localMusic: 'Local Music' + localMusic: 'Local Music', + pages: { + toplist: { + desc: 'The most authoritative music charts, discover the hottest music' + }, + mv: { + desc: 'Explore amazing video content', + loadingMore: 'Loading more...', + noMore: '— All content loaded —', + area: { + all: 'All', + mainland: 'Mainland', + hktw: 'HK/TW', + western: 'Western', + japan: 'Japan', + korea: 'Korea' + } + }, + list: { + desc: 'Discover more great playlists', + dailyRecommend: 'Daily Picks' + }, + search: { + desc: 'Explore the hottest search trends' + }, + album: { + area: { + all: 'All', + chinese: 'Chinese', + western: 'Western', + korea: 'Korea', + japan: 'Japan' + } + } + } }; diff --git a/src/i18n/lang/ja-JP/comp.ts b/src/i18n/lang/ja-JP/comp.ts index 619593f..c130d94 100644 --- a/src/i18n/lang/ja-JP/comp.ts +++ b/src/i18n/lang/ja-JP/comp.ts @@ -280,5 +280,39 @@ export default { home: 'ホーム', search: '検索', album: 'アルバム', - localMusic: 'ローカル音楽' + localMusic: 'ローカル音楽', + pages: { + toplist: { + desc: '最も権威ある音楽チャート、今一番ホットな音楽を発見' + }, + mv: { + desc: '素晴らしい動画コンテンツを探索', + loadingMore: 'もっと読み込み中...', + noMore: '— すべて読み込みました —', + area: { + all: 'すべて', + mainland: '中国大陸', + hktw: '香港・台湾', + western: '欧米', + japan: '日本', + korea: '韓国' + } + }, + list: { + desc: 'もっと素敵なプレイリストを発見', + dailyRecommend: 'デイリーおすすめ' + }, + search: { + desc: '今最もホットな検索トレンドを探索' + }, + album: { + area: { + all: 'すべて', + chinese: '中華圏', + western: '欧米', + korea: '韓国', + japan: '日本' + } + } + } }; diff --git a/src/i18n/lang/ko-KR/comp.ts b/src/i18n/lang/ko-KR/comp.ts index 563ee3e..90cf3fe 100644 --- a/src/i18n/lang/ko-KR/comp.ts +++ b/src/i18n/lang/ko-KR/comp.ts @@ -279,5 +279,39 @@ export default { home: '홈', search: '검색', album: '앨범', - localMusic: '로컬 음악' + localMusic: '로컬 음악', + pages: { + toplist: { + desc: '가장 권위 있는 음악 차트, 지금 가장 핫한 음악을 발견하세요' + }, + mv: { + desc: '멋진 영상 콘텐츠 탐색', + loadingMore: '더 불러오는 중...', + noMore: '— 모든 콘텐츠 로드 완료 —', + area: { + all: '전체', + mainland: '중국 대륙', + hktw: '홍콩/대만', + western: '서양', + japan: '일본', + korea: '한국' + } + }, + list: { + desc: '더 많은 멋진 플레이리스트를 발견하세요', + dailyRecommend: '오늘의 추천' + }, + search: { + desc: '지금 가장 핫한 검색 트렌드를 탐색하세요' + }, + album: { + area: { + all: '전체', + chinese: '중화권', + western: '서양', + korea: '한국', + japan: '일본' + } + } + } }; diff --git a/src/i18n/lang/zh-CN/comp.ts b/src/i18n/lang/zh-CN/comp.ts index 80b61ca..800b7b5 100644 --- a/src/i18n/lang/zh-CN/comp.ts +++ b/src/i18n/lang/zh-CN/comp.ts @@ -272,5 +272,39 @@ export default { home: '首页', search: '搜索', album: '专辑', - localMusic: '本地音乐' + localMusic: '本地音乐', + pages: { + toplist: { + desc: '最具权威的音乐榜单,发现当下最热门的音乐' + }, + mv: { + desc: '探索精彩视频内容', + loadingMore: '加载更多中...', + noMore: '— 已加载全部内容 —', + area: { + all: '全部', + mainland: '内地', + hktw: '港台', + western: '欧美', + japan: '日本', + korea: '韩国' + } + }, + list: { + desc: '发现更多好听的歌单', + dailyRecommend: '每日推荐' + }, + search: { + desc: '探索当下最热门的搜索趋势' + }, + album: { + area: { + all: '全部', + chinese: '华语', + western: '欧美', + korea: '韩国', + japan: '日本' + } + } + } }; diff --git a/src/i18n/lang/zh-Hant/comp.ts b/src/i18n/lang/zh-Hant/comp.ts index 0b66453..ee6af30 100644 --- a/src/i18n/lang/zh-Hant/comp.ts +++ b/src/i18n/lang/zh-Hant/comp.ts @@ -272,5 +272,39 @@ export default { home: '首頁', search: '搜尋', album: '專輯', - localMusic: '本地音樂' + localMusic: '本地音樂', + pages: { + toplist: { + desc: '最具權威的音樂榜單,發現當下最熱門的音樂' + }, + mv: { + desc: '探索精彩影片內容', + loadingMore: '載入更多中...', + noMore: '— 已載入全部內容 —', + area: { + all: '全部', + mainland: '內地', + hktw: '港台', + western: '歐美', + japan: '日本', + korea: '韓國' + } + }, + list: { + desc: '發現更多好聽的播放清單', + dailyRecommend: '每日推薦' + }, + search: { + desc: '探索當下最熱門的搜尋趨勢' + }, + album: { + area: { + all: '全部', + chinese: '華語', + western: '歐美', + korea: '韓國', + japan: '日本' + } + } + } }; diff --git a/src/renderer/views/album/index.vue b/src/renderer/views/album/index.vue index 60a0021..2de70f7 100644 --- a/src/renderer/views/album/index.vue +++ b/src/renderer/views/album/index.vue @@ -133,13 +133,13 @@ const route = useRoute(); const TOTAL_ITEMS = 30; // 每页数量 -const areas = [ - { name: '全部', value: 'ALL' }, - { name: '华语', value: 'ZH' }, - { name: '欧美', value: 'EA' }, - { name: '韩国', value: 'KR' }, - { name: '日本', value: 'JP' } -]; +const areas = computed(() => [ + { name: t('comp.pages.album.area.all'), value: 'ALL' }, + { name: t('comp.pages.album.area.chinese'), value: 'ZH' }, + { name: t('comp.pages.album.area.western'), value: 'EA' }, + { name: t('comp.pages.album.area.korea'), value: 'KR' }, + { name: t('comp.pages.album.area.japan'), value: 'JP' } +]); const albumList = ref([]); const page = ref(0); @@ -149,7 +149,8 @@ const loading = ref(false); const currentArea = ref((route.query.area as string) || 'ALL'); const currentAreaName = computed( - () => areas.find((a) => a.value === currentArea.value)?.name || '全部' + () => + areas.value.find((a) => a.value === currentArea.value)?.name || t('comp.pages.album.area.all') ); const contentScrollbarRef = ref(); diff --git a/src/renderer/views/list/index.vue b/src/renderer/views/list/index.vue index 656207b..e6cdd1f 100644 --- a/src/renderer/views/list/index.vue +++ b/src/renderer/views/list/index.vue @@ -23,7 +23,7 @@

{{ listTitle }}

-

发现更多好听的歌单

+

{{ t('comp.pages.list.desc') }}

@@ -96,10 +96,10 @@
- 加载中... + {{ t('common.loading') }}
- 没有更多了 + {{ t('common.noMore') }}
@@ -108,6 +108,7 @@