From 992b61b02481697395f0f6af2240c594525ef04b Mon Sep 17 00:00:00 2001 From: Peter Dave Hello Date: Wed, 21 Jun 2023 00:37:50 +0800 Subject: [PATCH] refactor: update zhTW.ts, improve some translation (#4981) --- CHANGELOG.en-US.md | 4 ++++ CHANGELOG.zh-CN.md | 4 ++++ src/locales/common/zhTW.ts | 34 +++++++++++++++++----------------- 3 files changed, 25 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.en-US.md b/CHANGELOG.en-US.md index 7df7db4a393..77586ccfbb1 100644 --- a/CHANGELOG.en-US.md +++ b/CHANGELOG.en-US.md @@ -37,6 +37,10 @@ - `n-tree` adds `show-line` prop, closes [#3796](https://github.com/tusen-ai/naive-ui/issues/3796), [#4554](https://github.com/tusen-ai/naive-ui/pull/4554) - `n-tree` adds node information for `render-switcher-icon` props, closes [#4815](https://github.com/tusen-ai/naive-ui/issues/4815). +### i18n + +- Improve `zhTW` locale. + ## 2.34.4 ### Fixes diff --git a/CHANGELOG.zh-CN.md b/CHANGELOG.zh-CN.md index 108b9e1db28..23c4d3a23cf 100644 --- a/CHANGELOG.zh-CN.md +++ b/CHANGELOG.zh-CN.md @@ -37,6 +37,10 @@ - `n-tree` 新增 `show-line` 属性,关闭 [#3796](https://github.com/tusen-ai/naive-ui/issues/3796), [#4554](https://github.com/tusen-ai/naive-ui/issues/4554) - `n-tree` 为 `render-switcher-icon` 属性添加节点信息,关闭 [#4815](https://github.com/tusen-ai/naive-ui/issues/4815) +### i18n + +- 完善 zhTW locale + ## 2.34.4 ### Fixes diff --git a/src/locales/common/zhTW.ts b/src/locales/common/zhTW.ts index 2788bbb7049..0d57046cd97 100644 --- a/src/locales/common/zhTW.ts +++ b/src/locales/common/zhTW.ts @@ -3,27 +3,27 @@ import type { NLocale } from './enUS' const zhTW: NLocale = { name: 'zh-TW', global: { - undo: '撤銷', + undo: '復原', redo: '重做', - confirm: '確認', + confirm: '確定', clear: '清除' }, Popconfirm: { - positiveText: '確認', + positiveText: '確定', negativeText: '取消' }, Cascader: { placeholder: '請選擇', loading: '載入中', loadingRequiredMessage: (label: string): string => - `載入全部 ${label} 的子節點後才可選中` + `載入全部 ${label} 的子節點後才可選擇` }, Time: { dateFormat: 'yyyy-MM-dd', dateTimeFormat: 'yyyy-MM-dd HH:mm:ss' }, DatePicker: { - yearFormat: 'yyyy年', + yearFormat: 'yyyy 年', monthFormat: 'MMM', dayFormat: 'eeeeee', yearTypeFormat: 'yyyy', @@ -32,8 +32,8 @@ const zhTW: NLocale = { dateTimeFormat: 'yyyy-MM-dd HH:mm:ss', quarterFormat: 'yyyy-qqq', clear: '清除', - now: '此刻', - confirm: '確認', + now: '現在', + confirm: '確定', selectTime: '選擇時間', selectDate: '選擇日期', datePlaceholder: '選擇日期', @@ -54,17 +54,17 @@ const zhTW: NLocale = { DataTable: { checkTableAll: '選擇全部表格資料', uncheckTableAll: '取消選擇全部表格資料', - confirm: '確認', - clear: '重置' + confirm: '確定', + clear: '重設' }, LegacyTransfer: { - sourceTitle: '源項', - targetTitle: '目標項' + sourceTitle: '來源', + targetTitle: '目標' }, Transfer: { selectAll: '全選', unselectAll: '取消全選', - clearAll: '清除', + clearAll: '清除全部', total: (num: number): string => `共 ${num} 項`, selected: (num: number): string => `已選 ${num} 項` }, @@ -76,9 +76,9 @@ const zhTW: NLocale = { }, TimePicker: { placeholder: '請選擇時間', - positiveText: '確認', + positiveText: '確定', negativeText: '取消', - now: '此刻' + now: '現在' }, Pagination: { goto: '跳至', @@ -103,9 +103,9 @@ const zhTW: NLocale = { title: '主題編輯器', clearAllVars: '清除全部變數', clearSearch: '清除搜尋', - filterCompName: '過濾組件名', - filterVarName: '過濾變數名', - import: '導入', + filterCompName: '過濾組件名稱', + filterVarName: '過濾變數名稱', + import: '匯入', export: '匯出', restore: '恢復預設' },