Skip to content

Commit

Permalink
Merge branch 'feature-1.8'
Browse files Browse the repository at this point in the history
  • Loading branch information
SummerOverture committed Jan 14, 2021
2 parents 576e2c7 + eb8c437 commit 13ec98f
Show file tree
Hide file tree
Showing 7 changed files with 262 additions and 5 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "ppfish",
"version": "1.8.1-alpha.2",
"version": "1.8.1-alpha.3",
"description": "fish design ui components",
"typings": "lib/components/index.d.ts",
"scripts": {
Expand Down
7 changes: 7 additions & 0 deletions site/docs/upgradeNotes/1.8/1.8.1.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,3 +25,10 @@
### 1.8.1-alpha.2
- 🐛修复Collapse state被写死导致表现不对的问题

### 1.8.1-alpha.3
- 🎊 国际化新增 繁体中文(中国台湾)(zh_TW)语言包
- DatePicker
- 🐛修复TimePicker中TimePanel的props未被正确传递的问题
- Select
- 🐛修复多选模式下 取消确定按钮未被国际化的问题

11 changes: 11 additions & 0 deletions site/docs/upgradeNotes/版本升级说明.md
Original file line number Diff line number Diff line change
Expand Up @@ -1144,3 +1144,14 @@

## 1.8.1-alpha.2
- 🐛修复Collapse state被写死导致表现不对的问题

---
`2021.1.14`

## 1.8.1-alpha.3

- 🎊 国际化新增 繁体中文(中国台湾)(zh_TW)语言包
- DatePicker
- 🐛修复TimePicker中TimePanel的props未被正确传递的问题
- Select
- 🐛修复多选模式下 取消确定按钮未被国际化的问题
3 changes: 2 additions & 1 deletion site/docs/zh-CN/i18n.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,5 +26,6 @@ return (

ppfish 目前支持的语言包如下:
- 简体中文(zh_CN)
- 英文 (en_US)
- 繁体中文(中国台湾)(zh_TW)
- 英文 (en_US)

4 changes: 3 additions & 1 deletion source/components/Locale/index.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import zh_CN from "./zh_CN";
import en_US from './en_US';
import zh_TW from './zh_TW';


type keyString = {
Expand Down Expand Up @@ -34,7 +35,8 @@ export interface LocaleProperties {

const Locale = {
zh_CN,
en_US
en_US,
zh_TW,
}

export default Locale
236 changes: 236 additions & 0 deletions source/components/Locale/zh_TW.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,236 @@
import { LocaleProperties } from '.';

const localeValues: LocaleProperties = {
locale: 'zh_TW',
AudioPlayer: {
notSupport: '您的瀏覽器不支持 audio 標籤。'
},
AutoComplete: {
notFoundContent: '無匹配結果'
},
Cascader: {
placeholder: '請選擇',
notFoundContent: '無匹配結果'
},
Table: {
filterTitle: '篩選',
filterConfirm: '確定',
filterReset: '重置',
filterEmptyText: '無篩選項',
emptyText: '暫無數據',
selectAll: '全選當頁',
selectInvert: '反選當頁',
selectionAll: '全選所有',
sortTitle: '排序',
expand: '展開行',
collapse: '關閉行',
triggerDesc: '點擊降序',
triggerAsc: '點擊升序',
cancelSort: '取消排序',
modalTitle: '選擇需要展示的數據項',
defaultOptionTitle: '默認展示數據項',
okText: '確定',
cancelText: '取消',
},
Modal: {
okText: '確定',
cancelText: '取消',
},
Pagination: {
items_per_page: '條/頁',
jump_to: '跳至',
jump_to_confirm: '確定',
page: '頁',

// Pagination.js
prev_page: '上一頁',
next_page: '下一頁',
prev_5: '向前 5 頁',
next_5: '向後 5 頁',
prev_3: '向前 3 頁',
next_3: '向後 3 頁',
},
RichEditor: {
// editor
insertImageTip: '支持jpg、jpeg、png、gif、bmp格式的圖片,最佳顯示高度不超過400px,寬度不超過270px。',
rule1: '1、單個視頻不超過10M,支持MP4、3GP格式視頻。',
rule2: '2、最佳顯示高度不超過400px',
PleaseEnterTheVideolinkURL: "請輸入視頻鏈接URL",
selectLocalVideo: '選擇本地視頻',
videoLink: '視頻鏈接',
localVideo: "本地視頻",
insertVideo: '插入視頻',
selectLocalImage: "選擇本地圖片",
insertAttachment: "插入附件",
selectLocalFile: "選擇本地文件",
HyperlinkAddress: '超鏈接地址',
insertPicture: '插入圖片',
noVideoLinkErrorTip: '請設置視頻源地址',
VideoCantPlayTip: '視頻無法播放',
file: '[文件]',
noFileInfoTip: '文件信息讀取失敗',
noPicSrcTip: '請設置圖片源地址',
noVideoUrlErrorTip: '視頻鏈接URL不得為空',
videoUrlFormattingError: '視頻鏈接URL格式錯誤',
videoLinkTooLongError: '視頻鏈接不得超過1000個字',
linkEmptyTip: '鏈接地址不得為空',
linkToolongError: '鏈接地址不得超過1000個字',
noSelectionText: '沒有選中文本',
insertLink: '插入超鏈接',
editLink: '編輯超鏈接',

//toolbar
backgroundColor: '背景色',
textDirection: '文字方向',
increaseIndent: '增加縮進',
decreaseIndent: '減少縮進',
subScript: '下腳標',
superSciprt: '上腳標',
codeBlock: '代碼塊',
blockquote: '塊引用',
strike: '刪除線',
brushFormat: '格式刷',
clearFormat: '清除格式',
fontSize: '文字大小',
insertEmoji: '插入表情',
defaultEmoji: '默認表情',
orderedList: '有序列表',
unOrderedList: '無序列表',
alignJustified: '兩端對齊',
alignCenter: '居中',
alignRight: '居右',
alignLeft: '居左',
fontColor: '文字顏色',
underline: '下劃線',
italic: '斜體',
bold: '粗體',
temporarilyNoData: '暫無數據',
enterKeyWordPlease: '請輸入關鍵字',
justOkText: '知道了'
},
Spin: {
loading: '加載中'
},
Select: {
errorMessage: '超過選項上限',
multipleSelectAllText: '所有選項',
notFoundContent: '無匹配結果',
placeholder: '請選擇',
searchPlaceholder: '請輸入關鍵字',
selectAllText: '選擇所有',
confirmText: '確定',
cancelText: '取消',
loading: '加載中…'
},
Transfer: {
notFoundContent: '無匹配結果',
sourceNotFoundContent: '暫無相關信息',
targetNotFonudContent: '請從左側選擇添加',
searchPlaceholder: '請輸入關鍵字',
},
TreeSelect: {
placeholder: '請選擇',
searchPlaceholder: '請輸入關鍵字',
treeNodeResetTitle: '不選擇任何分類',
notFoundContent: '無匹配結果',
okText: '確定',
cancelText: '取消',
},
Upload: {
uploading: '上傳中',
removeFile: '移除文件',
uploadError: '上傳錯誤',
previewFile: '預覽文件',
cancelText: '取消',
deleteText: '全部刪除',
uploadedTip: '已上傳 ${length} 項'
},
List: {
emptyText: '暫無數據',
},
Guide: {
prevBtnText: '上一步',
nextBtnText: '下一步',
doneBtnText: '知道了',
skipBtnText: '跳過',
},
LoadMore: {
defaultText: '查看更多',
loadingText: '加載中',
errorText: '加載失敗,請重試',
endText: '沒有更多了',
},
DatePicker: {
now: '現在',
today: '今天',
cancel: '取消',
clear: '清空',
confirm: '確定',
startPlaceholder: '開始日期',
endPlaceholder: '結束日期',
separator: '至',
selectDate: '下方選擇日期',
selectTime: '請選擇時間',
startDate: '開始日期',
startTime: '開始時間',
endDate: '結束日期',
endTime: '結束時間',
year: '年',
month1: '1 月',
month2: '2 月',
month3: '3 月',
month4: '4 月',
month5: '5 月',
month6: '6 月',
month7: '7 月',
month8: '8 月',
month9: '9 月',
month10: '10 月',
month11: '11 月',
month12: '12 月',
'1月': '1',
'2月': '2',
'3月': '3',
'4月': '4',
'5月': '5',
'6月': '6',
'7月': '7',
'8月': '8',
'9月': '9',
'10月': '10',
'11月': '11',
'12月': '12',
week: '週次',
weeks: {
sun: '日',
mon: '一',
tue: '二',
wed: '三',
thu: '四',
fri: '五',
sat: '六'
},
months: {
jan: '一月',
feb: '二月',
mar: '三月',
apr: '四月',
may: '五月',
jun: '六月',
jul: '七月',
aug: '八月',
sep: '九月',
oct: '十月',
nov: '十一月',
dec: '十二月'
}
},
VideoViewer: {
fullScreen: '全屏',
cancelFullScreen: '取消全屏',
download: '下載',
retry: '重試'
}
}

export default localeValues;
4 changes: 2 additions & 2 deletions source/components/Select/Select.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -874,15 +874,15 @@ class Select extends React.Component<SelectProps, SelectState> {
className={`${dropdownCls}-footer-btn`}
onClick={this.handleCancelSelect}
>
取消
{Locale.cancelText}
</Button>
<Button
className={`${dropdownCls}-footer-btn`}
onClick={this.handleConfirmSelect}
disabled={multipleConfirmDisabled}
type="primary"
>
确定
{Locale.confirmText}
</Button>
</div>
</div>
Expand Down

0 comments on commit 13ec98f

Please sign in to comment.