From cb208b0df9113c3f091ff61ffafcd342a993a33b Mon Sep 17 00:00:00 2001 From: Pete Arif Date: Mon, 11 Feb 2019 11:24:09 +0800 Subject: [PATCH] fix: Add Bahasa Melayu (Malaysia) locale (#485) --- src/locale/ms.js | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 src/locale/ms.js diff --git a/src/locale/ms.js b/src/locale/ms.js new file mode 100644 index 000000000..740b95b32 --- /dev/null +++ b/src/locale/ms.js @@ -0,0 +1,36 @@ +import dayjs from 'dayjs' + +const locale = { + name: 'ms', + weekdays: 'Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu'.split('_'), + months: 'Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember'.split('_'), + weekStart: 1, + formats: { + LT: 'HH.mm', + LTS: 'HH.mm.ss', + L: 'DD/MM/YYYY', + LL: 'D MMMM YYYY', + LLL: 'D MMMM YYYY HH.mm', + LLLL: 'dddd, D MMMM YYYY HH.mm' + }, + relativeTime: { + future: 'dalam %s', + past: '%s yang lepas', + s: 'beberapa saat', + m: 'seminit', + mm: '%d minit', + h: 'sejam', + hh: '%d jam', + d: 'sehari', + dd: '%d hari', + M: 'sebulan', + MM: '%d bulan', + y: 'setahun', + yy: '%d tahun' + }, + ordinal: n => `${n}.` +} + +dayjs.locale(locale, null, true) + +export default locale