id.js 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. // moment.js language configuration
  2. // language : Bahasa Indonesia (id)
  3. // author : Mohammad Satrio Utomo : https://github.com/tyok
  4. // reference: http://id.wikisource.org/wiki/Pedoman_Umum_Ejaan_Bahasa_Indonesia_yang_Disempurnakan
  5. (function (factory) {
  6. if (typeof define === 'function' && define.amd) {
  7. define(['moment'], factory); // AMD
  8. } else if (typeof exports === 'object') {
  9. module.exports = factory(require('../moment')); // Node
  10. } else {
  11. factory(window.moment); // Browser global
  12. }
  13. }(function (moment) {
  14. return moment.lang('id', {
  15. months : "Januari_Februari_Maret_April_Mei_Juni_Juli_Agustus_September_Oktober_November_Desember".split("_"),
  16. monthsShort : "Jan_Feb_Mar_Apr_Mei_Jun_Jul_Ags_Sep_Okt_Nov_Des".split("_"),
  17. weekdays : "Minggu_Senin_Selasa_Rabu_Kamis_Jumat_Sabtu".split("_"),
  18. weekdaysShort : "Min_Sen_Sel_Rab_Kam_Jum_Sab".split("_"),
  19. weekdaysMin : "Mg_Sn_Sl_Rb_Km_Jm_Sb".split("_"),
  20. longDateFormat : {
  21. LT : "HH.mm",
  22. L : "DD/MM/YYYY",
  23. LL : "D MMMM YYYY",
  24. LLL : "D MMMM YYYY [pukul] LT",
  25. LLLL : "dddd, D MMMM YYYY [pukul] LT"
  26. },
  27. meridiem : function (hours, minutes, isLower) {
  28. if (hours < 11) {
  29. return 'pagi';
  30. } else if (hours < 15) {
  31. return 'siang';
  32. } else if (hours < 19) {
  33. return 'sore';
  34. } else {
  35. return 'malam';
  36. }
  37. },
  38. calendar : {
  39. sameDay : '[Hari ini pukul] LT',
  40. nextDay : '[Besok pukul] LT',
  41. nextWeek : 'dddd [pukul] LT',
  42. lastDay : '[Kemarin pukul] LT',
  43. lastWeek : 'dddd [lalu pukul] LT',
  44. sameElse : 'L'
  45. },
  46. relativeTime : {
  47. future : "dalam %s",
  48. past : "%s yang lalu",
  49. s : "beberapa detik",
  50. m : "semenit",
  51. mm : "%d menit",
  52. h : "sejam",
  53. hh : "%d jam",
  54. d : "sehari",
  55. dd : "%d hari",
  56. M : "sebulan",
  57. MM : "%d bulan",
  58. y : "setahun",
  59. yy : "%d tahun"
  60. },
  61. week : {
  62. dow : 1, // Monday is the first day of the week.
  63. doy : 7 // The week that contains Jan 1st is the first week of the year.
  64. }
  65. });
  66. }));