Node-Red configuration
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

ms.js 2.2KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475
  1. //! moment.js locale configuration
  2. //! locale : Malay [ms]
  3. //! author : Weldan Jamili : https://github.com/weldan
  4. import moment from '../moment';
  5. export default moment.defineLocale('ms', {
  6. months: 'Januari_Februari_Mac_April_Mei_Jun_Julai_Ogos_September_Oktober_November_Disember'.split(
  7. '_'
  8. ),
  9. monthsShort: 'Jan_Feb_Mac_Apr_Mei_Jun_Jul_Ogs_Sep_Okt_Nov_Dis'.split('_'),
  10. weekdays: 'Ahad_Isnin_Selasa_Rabu_Khamis_Jumaat_Sabtu'.split('_'),
  11. weekdaysShort: 'Ahd_Isn_Sel_Rab_Kha_Jum_Sab'.split('_'),
  12. weekdaysMin: 'Ah_Is_Sl_Rb_Km_Jm_Sb'.split('_'),
  13. longDateFormat: {
  14. LT: 'HH.mm',
  15. LTS: 'HH.mm.ss',
  16. L: 'DD/MM/YYYY',
  17. LL: 'D MMMM YYYY',
  18. LLL: 'D MMMM YYYY [pukul] HH.mm',
  19. LLLL: 'dddd, D MMMM YYYY [pukul] HH.mm',
  20. },
  21. meridiemParse: /pagi|tengahari|petang|malam/,
  22. meridiemHour: function (hour, meridiem) {
  23. if (hour === 12) {
  24. hour = 0;
  25. }
  26. if (meridiem === 'pagi') {
  27. return hour;
  28. } else if (meridiem === 'tengahari') {
  29. return hour >= 11 ? hour : hour + 12;
  30. } else if (meridiem === 'petang' || meridiem === 'malam') {
  31. return hour + 12;
  32. }
  33. },
  34. meridiem: function (hours, minutes, isLower) {
  35. if (hours < 11) {
  36. return 'pagi';
  37. } else if (hours < 15) {
  38. return 'tengahari';
  39. } else if (hours < 19) {
  40. return 'petang';
  41. } else {
  42. return 'malam';
  43. }
  44. },
  45. calendar: {
  46. sameDay: '[Hari ini pukul] LT',
  47. nextDay: '[Esok pukul] LT',
  48. nextWeek: 'dddd [pukul] LT',
  49. lastDay: '[Kelmarin pukul] LT',
  50. lastWeek: 'dddd [lepas pukul] LT',
  51. sameElse: 'L',
  52. },
  53. relativeTime: {
  54. future: 'dalam %s',
  55. past: '%s yang lepas',
  56. s: 'beberapa saat',
  57. ss: '%d saat',
  58. m: 'seminit',
  59. mm: '%d minit',
  60. h: 'sejam',
  61. hh: '%d jam',
  62. d: 'sehari',
  63. dd: '%d hari',
  64. M: 'sebulan',
  65. MM: '%d bulan',
  66. y: 'setahun',
  67. yy: '%d tahun',
  68. },
  69. week: {
  70. dow: 1, // Monday is the first day of the week.
  71. doy: 7, // The week that contains Jan 7th is the first week of the year.
  72. },
  73. });