Merge pull request #17546 from austin-krave/feature

Added ms_MY locale support
This commit is contained in:
偏右 2019-07-15 16:58:28 +08:00 committed by GitHub
commit 7d9af06289
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 5378 additions and 40 deletions

View File

@ -0,0 +1,2 @@
import ms_MY from '../../date-picker/locale/ms_MY';
export default ms_MY;

View File

@ -0,0 +1,19 @@
import CalendarLocale from 'rc-calendar/lib/locale/ms_MY';
import TimePickerLocale from '../../time-picker/locale/ms_MY';
// Merge into a locale object
const locale = {
lang: {
placeholder: 'Pilih tarikh',
rangePlaceholder: ['Tarikh mula', 'Tarikh akhir'],
...CalendarLocale,
},
timePickerLocale: {
...TimePickerLocale,
},
};
// All settings at:
// https://github.com/ant-design/ant-design/blob/master/components/date-picker/locale/example.json
export default locale;

View File

@ -41,6 +41,7 @@ import knIN from '../kn_IN';
import koKR from '../ko_KR';
import kuIQ from '../ku_IQ';
import mnMN from '../mn_MN';
import msMY from '../ms_MY';
import nbNO from '../nb_NO';
import neNP from '../ne-NP';
import nlBE from '../nl_BE';
@ -87,6 +88,7 @@ const locales = [
knIN,
koKR,
kuIQ,
msMY,
mnMN,
nbNO,
neNP,

View File

@ -0,0 +1,62 @@
import Pagination from 'rc-pagination/lib/locale/ms_MY';
import DatePicker from '../date-picker/locale/ms_MY';
import TimePicker from '../time-picker/locale/ms_MY';
import Calendar from '../calendar/locale/ms_MY';
export default {
locale: 'ms-my',
Pagination,
DatePicker,
TimePicker,
Calendar,
global: {
placeholder: 'Sila pilih',
},
PageHeader: {
back: 'Kembali',
},
Text: {
edit: 'Sunting',
copy: 'Salin',
copied: 'Berjaya menyalin',
expand: 'Kembang',
},
Empty: {
description: 'Tiada data',
},
Table: {
filterTitle: 'Cari dengan tajuk',
filterConfirm: 'Ok',
filterReset: 'Menetapkan semula',
emptyText: 'Tiada data',
selectAll: 'Pilih semua',
selectInvert: 'Terbalikkan',
},
Modal: {
okText: 'OK',
cancelText: 'Batal',
justOkText: 'OK',
},
Popconfirm: {
okText: 'OK',
cancelText: 'Batal',
},
Transfer: {
notFoundContent: 'Tidak dijumpai',
searchPlaceholder: 'Carian di sini',
itemUnit: 'item',
itemsUnit: 'item',
},
Icon: {
icon: 'ikon',
},
Select: {
notFoundContent: 'Tidak Dijumpai',
},
Upload: {
uploading: 'Sedang memuat naik...',
removeFile: 'Buang fail',
uploadError: 'Masalah muat naik',
previewFile: 'Tengok fail',
},
};

View File

@ -0,0 +1,5 @@
const locale = {
placeholder: 'Sila pilih masa',
};
export default locale;