gl.js 2.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. //! moment.js locale configuration
  2. //! locale : Galician [gl]
  3. //! author : Juan G. Hurtado : https://github.com/juanghurtado
  4. ;(function (global, factory) {
  5. typeof exports === 'object' && typeof module !== 'undefined'
  6. && typeof require === 'function' ? factory(require('../moment')) :
  7. typeof define === 'function' && define.amd ? define(['../moment'], factory) :
  8. factory(global.moment)
  9. }(this, (function (moment) { 'use strict';
  10. //! moment.js locale configuration
  11. var gl = moment.defineLocale('gl', {
  12. months: 'xaneiro_febreiro_marzo_abril_maio_xuño_xullo_agosto_setembro_outubro_novembro_decembro'.split(
  13. '_'
  14. ),
  15. monthsShort: 'xan._feb._mar._abr._mai._xuñ._xul._ago._set._out._nov._dec.'.split(
  16. '_'
  17. ),
  18. monthsParseExact: true,
  19. weekdays: 'domingo_luns_martes_mércores_xoves_venres_sábado'.split('_'),
  20. weekdaysShort: 'dom._lun._mar._mér._xov._ven._sáb.'.split('_'),
  21. weekdaysMin: 'do_lu_ma_mé_xo_ve_sá'.split('_'),
  22. weekdaysParseExact: true,
  23. longDateFormat: {
  24. LT: 'H:mm',
  25. LTS: 'H:mm:ss',
  26. L: 'DD/MM/YYYY',
  27. LL: 'D [de] MMMM [de] YYYY',
  28. LLL: 'D [de] MMMM [de] YYYY H:mm',
  29. LLLL: 'dddd, D [de] MMMM [de] YYYY H:mm',
  30. },
  31. calendar: {
  32. sameDay: function () {
  33. return '[hoxe ' + (this.hours() !== 1 ? 'ás' : 'á') + '] LT';
  34. },
  35. nextDay: function () {
  36. return '[mañá ' + (this.hours() !== 1 ? 'ás' : 'á') + '] LT';
  37. },
  38. nextWeek: function () {
  39. return 'dddd [' + (this.hours() !== 1 ? 'ás' : 'a') + '] LT';
  40. },
  41. lastDay: function () {
  42. return '[onte ' + (this.hours() !== 1 ? 'á' : 'a') + '] LT';
  43. },
  44. lastWeek: function () {
  45. return (
  46. '[o] dddd [pasado ' + (this.hours() !== 1 ? 'ás' : 'a') + '] LT'
  47. );
  48. },
  49. sameElse: 'L',
  50. },
  51. relativeTime: {
  52. future: function (str) {
  53. if (str.indexOf('un') === 0) {
  54. return 'n' + str;
  55. }
  56. return 'en ' + str;
  57. },
  58. past: 'hai %s',
  59. s: 'uns segundos',
  60. ss: '%d segundos',
  61. m: 'un minuto',
  62. mm: '%d minutos',
  63. h: 'unha hora',
  64. hh: '%d horas',
  65. d: 'un día',
  66. dd: '%d días',
  67. M: 'un mes',
  68. MM: '%d meses',
  69. y: 'un ano',
  70. yy: '%d anos',
  71. },
  72. dayOfMonthOrdinalParse: /\d{1,2}º/,
  73. ordinal: '%dº',
  74. week: {
  75. dow: 1, // Monday is the first day of the week.
  76. doy: 4, // The week that contains Jan 4th is the first week of the year.
  77. },
  78. });
  79. return gl;
  80. })));