momentjs-rails 2.9.0 → 2.20.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (133) hide show
  1. checksums.yaml +5 -5
  2. data/MIT-LICENSE +1 -1
  3. data/README.md +13 -11
  4. data/news.md +24 -7
  5. data/test/dummy/tmp/cache/assets/D1C/680/sprockets%2F16ed4d5afdb2919596e6f8790e2116c2 +0 -0
  6. data/test/dummy/tmp/cache/assets/D35/CA0/sprockets%2F493e64bce2d302801dc01cf7cd096a58 +0 -0
  7. data/test/dummy/tmp/cache/assets/D3F/5F0/sprockets%2F4a6c53eae7c6e41a69a191578bbb6417 +0 -0
  8. data/test/dummy/tmp/cache/assets/D58/BD0/sprockets%2F4de9ddc9b725c715a54c98697b2528fe +0 -0
  9. data/test/dummy/tmp/cache/assets/D75/510/sprockets%2Fe690787ac522f47a6be024bfcc1767ee +0 -0
  10. data/test/dummy/tmp/cache/assets/E10/250/sprockets%2Fe4badb9ddfda484eb9671bf88567be61 +0 -0
  11. data/test/integration/navigation_test.rb +1 -2
  12. data/vendor/assets/javascripts/moment/af.js +72 -69
  13. data/vendor/assets/javascripts/moment/ar-dz.js +60 -0
  14. data/vendor/assets/javascripts/moment/ar-kw.js +60 -0
  15. data/vendor/assets/javascripts/moment/ar-ly.js +127 -0
  16. data/vendor/assets/javascripts/moment/ar-ma.js +59 -55
  17. data/vendor/assets/javascripts/moment/ar-sa.js +103 -98
  18. data/vendor/assets/javascripts/moment/ar-tn.js +58 -53
  19. data/vendor/assets/javascripts/moment/ar.js +140 -131
  20. data/vendor/assets/javascripts/moment/az.js +100 -101
  21. data/vendor/assets/javascripts/moment/be.js +106 -125
  22. data/vendor/assets/javascripts/moment/bg.js +78 -75
  23. data/vendor/assets/javascripts/moment/bm.js +60 -0
  24. data/vendor/assets/javascripts/moment/bn.js +117 -108
  25. data/vendor/assets/javascripts/moment/bo.js +117 -105
  26. data/vendor/assets/javascripts/moment/br.js +92 -92
  27. data/vendor/assets/javascripts/moment/bs.js +81 -68
  28. data/vendor/assets/javascripts/moment/ca.js +83 -71
  29. data/vendor/assets/javascripts/moment/cs.js +102 -79
  30. data/vendor/assets/javascripts/moment/cv.js +62 -59
  31. data/vendor/assets/javascripts/moment/cy.js +78 -75
  32. data/vendor/assets/javascripts/moment/da.js +59 -56
  33. data/vendor/assets/javascripts/moment/de-at.js +77 -71
  34. data/vendor/assets/javascripts/moment/de-ch.js +79 -0
  35. data/vendor/assets/javascripts/moment/de.js +76 -70
  36. data/vendor/assets/javascripts/moment/dv.js +101 -0
  37. data/vendor/assets/javascripts/moment/el.js +96 -89
  38. data/vendor/assets/javascripts/moment/en-au.js +66 -62
  39. data/vendor/assets/javascripts/moment/en-ca.js +62 -59
  40. data/vendor/assets/javascripts/moment/en-gb.js +66 -63
  41. data/vendor/assets/javascripts/moment/en-ie.js +68 -0
  42. data/vendor/assets/javascripts/moment/en-nz.js +68 -0
  43. data/vendor/assets/javascripts/moment/eo.js +72 -69
  44. data/vendor/assets/javascripts/moment/es-do.js +92 -0
  45. data/vendor/assets/javascripts/moment/es-us.js +84 -0
  46. data/vendor/assets/javascripts/moment/es.js +87 -71
  47. data/vendor/assets/javascripts/moment/et.js +78 -74
  48. data/vendor/assets/javascripts/moment/eu.js +65 -60
  49. data/vendor/assets/javascripts/moment/fa.js +105 -100
  50. data/vendor/assets/javascripts/moment/fi.js +77 -74
  51. data/vendor/assets/javascripts/moment/fo.js +59 -56
  52. data/vendor/assets/javascripts/moment/fr-ca.js +73 -54
  53. data/vendor/assets/javascripts/moment/fr-ch.js +79 -0
  54. data/vendor/assets/javascripts/moment/fr.js +82 -58
  55. data/vendor/assets/javascripts/moment/fy.js +73 -66
  56. data/vendor/assets/javascripts/moment/gd.js +77 -0
  57. data/vendor/assets/javascripts/moment/gl.js +74 -69
  58. data/vendor/assets/javascripts/moment/gom-latn.js +124 -0
  59. data/vendor/assets/javascripts/moment/gu.js +125 -0
  60. data/vendor/assets/javascripts/moment/he.js +95 -75
  61. data/vendor/assets/javascripts/moment/hi.js +122 -118
  62. data/vendor/assets/javascripts/moment/hr.js +82 -68
  63. data/vendor/assets/javascripts/moment/hu.js +82 -82
  64. data/vendor/assets/javascripts/moment/hy-am.js +80 -102
  65. data/vendor/assets/javascripts/moment/id.js +82 -79
  66. data/vendor/assets/javascripts/moment/is.js +75 -68
  67. data/vendor/assets/javascripts/moment/it.js +68 -65
  68. data/vendor/assets/javascripts/moment/ja.js +79 -61
  69. data/vendor/assets/javascripts/moment/jv.js +84 -0
  70. data/vendor/assets/javascripts/moment/ka.js +82 -101
  71. data/vendor/assets/javascripts/moment/kk.js +88 -0
  72. data/vendor/assets/javascripts/moment/km.js +57 -54
  73. data/vendor/assets/javascripts/moment/kn.js +127 -0
  74. data/vendor/assets/javascripts/moment/ko.js +82 -64
  75. data/vendor/assets/javascripts/moment/ky.js +89 -0
  76. data/vendor/assets/javascripts/moment/lb.js +126 -127
  77. data/vendor/assets/javascripts/moment/lo.js +71 -0
  78. data/vendor/assets/javascripts/moment/lt.js +110 -111
  79. data/vendor/assets/javascripts/moment/lv.js +92 -72
  80. data/vendor/assets/javascripts/moment/me.js +113 -0
  81. data/vendor/assets/javascripts/moment/mi.js +65 -0
  82. data/vendor/assets/javascripts/moment/mk.js +80 -77
  83. data/vendor/assets/javascripts/moment/ml.js +80 -67
  84. data/vendor/assets/javascripts/moment/mr.js +158 -116
  85. data/vendor/assets/javascripts/moment/ms-my.js +82 -78
  86. data/vendor/assets/javascripts/moment/ms.js +83 -0
  87. data/vendor/assets/javascripts/moment/mt.js +61 -0
  88. data/vendor/assets/javascripts/moment/my.js +95 -87
  89. data/vendor/assets/javascripts/moment/nb.js +62 -57
  90. data/vendor/assets/javascripts/moment/ne.js +121 -118
  91. data/vendor/assets/javascripts/moment/nl-be.js +89 -0
  92. data/vendor/assets/javascripts/moment/nl.js +86 -66
  93. data/vendor/assets/javascripts/moment/nn.js +59 -56
  94. data/vendor/assets/javascripts/moment/pa-in.js +125 -0
  95. data/vendor/assets/javascripts/moment/pl.js +99 -72
  96. data/vendor/assets/javascripts/moment/pt-br.js +60 -56
  97. data/vendor/assets/javascripts/moment/pt.js +64 -60
  98. data/vendor/assets/javascripts/moment/ro.js +72 -68
  99. data/vendor/assets/javascripts/moment/ru.js +156 -147
  100. data/vendor/assets/javascripts/moment/sd.js +99 -0
  101. data/vendor/assets/javascripts/moment/se.js +62 -0
  102. data/vendor/assets/javascripts/moment/si.js +72 -0
  103. data/vendor/assets/javascripts/moment/sk.js +80 -80
  104. data/vendor/assets/javascripts/moment/sl.js +117 -89
  105. data/vendor/assets/javascripts/moment/sq.js +69 -65
  106. data/vendor/assets/javascripts/moment/sr-cyrl.js +96 -91
  107. data/vendor/assets/javascripts/moment/sr.js +96 -91
  108. data/vendor/assets/javascripts/moment/ss.js +90 -0
  109. data/vendor/assets/javascripts/moment/sv.js +68 -63
  110. data/vendor/assets/javascripts/moment/sw.js +60 -0
  111. data/vendor/assets/javascripts/moment/ta.js +126 -125
  112. data/vendor/assets/javascripts/moment/te.js +90 -0
  113. data/vendor/assets/javascripts/moment/tet.js +69 -0
  114. data/vendor/assets/javascripts/moment/th.js +66 -61
  115. data/vendor/assets/javascripts/moment/tl-ph.js +61 -58
  116. data/vendor/assets/javascripts/moment/tlh.js +123 -0
  117. data/vendor/assets/javascripts/moment/tr.js +85 -88
  118. data/vendor/assets/javascripts/moment/tzl.js +93 -0
  119. data/vendor/assets/javascripts/moment/tzm-latn.js +57 -54
  120. data/vendor/assets/javascripts/moment/tzm.js +57 -54
  121. data/vendor/assets/javascripts/moment/uk.js +123 -133
  122. data/vendor/assets/javascripts/moment/ur.js +100 -0
  123. data/vendor/assets/javascripts/moment/uz-latn.js +59 -0
  124. data/vendor/assets/javascripts/moment/uz.js +57 -54
  125. data/vendor/assets/javascripts/moment/vi.js +78 -62
  126. data/vendor/assets/javascripts/moment/x-pseudo.js +69 -0
  127. data/vendor/assets/javascripts/moment/yo.js +61 -0
  128. data/vendor/assets/javascripts/moment/zh-cn.js +99 -112
  129. data/vendor/assets/javascripts/moment/zh-hk.js +106 -0
  130. data/vendor/assets/javascripts/moment/zh-tw.js +92 -86
  131. data/vendor/assets/javascripts/moment.js +4128 -2636
  132. metadata +67 -16
  133. data/test/dummy/log/test.log +0 -61
@@ -1,121 +1,125 @@
1
- // moment.js locale configuration
2
- // locale : hindi (hi)
3
- // author : Mayank Singhal : https://github.com/mayanksinghal
1
+ //! moment.js locale configuration
2
+ //! locale : Hindi [hi]
3
+ //! author : Mayank Singhal : https://github.com/mayanksinghal
4
4
 
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((typeof global !== 'undefined' ? global : this).moment); // node or other global
12
- }
13
- }(function (moment) {
14
- var symbolMap = {
15
- '1': '',
16
- '2': '',
17
- '3': '',
18
- '4': '',
19
- '5': '',
20
- '6': '',
21
- '7': '',
22
- '8': '',
23
- '9': '',
24
- '0': '०'
25
- },
26
- numberMap = {
27
- '': '1',
28
- '': '2',
29
- '': '3',
30
- '': '4',
31
- '': '5',
32
- '': '6',
33
- '': '7',
34
- '': '8',
35
- '': '9',
36
- '०': '0'
37
- };
5
+ ;(function (global, factory) {
6
+ typeof exports === 'object' && typeof module !== 'undefined'
7
+ && typeof require === 'function' ? factory(require('../moment')) :
8
+ typeof define === 'function' && define.amd ? define(['../moment'], factory) :
9
+ factory(global.moment)
10
+ }(this, (function (moment) { 'use strict';
11
+
12
+
13
+ var symbolMap = {
14
+ '1': '१',
15
+ '2': '',
16
+ '3': '',
17
+ '4': '',
18
+ '5': '',
19
+ '6': '',
20
+ '7': '',
21
+ '8': '',
22
+ '9': '',
23
+ '0': ''
24
+ };
25
+ var numberMap = {
26
+ '१': '1',
27
+ '': '2',
28
+ '': '3',
29
+ '': '4',
30
+ '': '5',
31
+ '': '6',
32
+ '': '7',
33
+ '': '8',
34
+ '': '9',
35
+ '': '0'
36
+ };
38
37
 
39
- return moment.defineLocale('hi', {
40
- months : 'जनवरी_फ़रवरी_मार्च_अप्रैल_मई_जून_जुलाई_अगस्त_सितम्बर_अक्टूबर_नवम्बर_दिसम्बर'.split('_'),
41
- monthsShort : 'जन._फ़र._मार्च_अप्रै._मई_जून_जुल._अग._सित._अक्टू._नव._दिस.'.split('_'),
42
- weekdays : 'रविवार_सोमवार_मंगलवार_बुधवार_गुरूवार_शुक्रवार_शनिवार'.split('_'),
43
- weekdaysShort : 'रवि_सोम_मंगल_बुध_गुरू_शुक्र_शनि'.split('_'),
44
- weekdaysMin : '_सो_मं_बु_गु_शु_'.split('_'),
45
- longDateFormat : {
46
- LT : 'A h:mm बजे',
47
- LTS : 'A h:mm:ss बजे',
48
- L : 'DD/MM/YYYY',
49
- LL : 'D MMMM YYYY',
50
- LLL : 'D MMMM YYYY, LT',
51
- LLLL : 'dddd, D MMMM YYYY, LT'
52
- },
53
- calendar : {
54
- sameDay : '[आज] LT',
55
- nextDay : '[कल] LT',
56
- nextWeek : 'dddd, LT',
57
- lastDay : '[कल] LT',
58
- lastWeek : '[पिछले] dddd, LT',
59
- sameElse : 'L'
60
- },
61
- relativeTime : {
62
- future : '%s में',
63
- past : '%s पहले',
64
- s : 'कुछ ही क्षण',
65
- m : 'एक मिनट',
66
- mm : '%d मिनट',
67
- h : 'एक घंटा',
68
- hh : '%d घंटे',
69
- d : 'एक दिन',
70
- dd : '%d दिन',
71
- M : 'एक महीने',
72
- MM : '%d महीने',
73
- y : 'एक वर्ष',
74
- yy : '%d वर्ष'
75
- },
76
- preparse: function (string) {
77
- return string.replace(/[१२३४५६७८९०]/g, function (match) {
78
- return numberMap[match];
79
- });
80
- },
81
- postformat: function (string) {
82
- return string.replace(/\d/g, function (match) {
83
- return symbolMap[match];
84
- });
85
- },
86
- // Hindi notation for meridiems are quite fuzzy in practice. While there exists
87
- // a rigid notion of a 'Pahar' it is not used as rigidly in modern Hindi.
88
- meridiemParse: /रात|सुबह|दोपहर|शाम/,
89
- meridiemHour : function (hour, meridiem) {
90
- if (hour === 12) {
91
- hour = 0;
92
- }
93
- if (meridiem === 'रात') {
94
- return hour < 4 ? hour : hour + 12;
95
- } else if (meridiem === 'सुबह') {
96
- return hour;
97
- } else if (meridiem === 'दोपहर') {
98
- return hour >= 10 ? hour : hour + 12;
99
- } else if (meridiem === 'शाम') {
100
- return hour + 12;
101
- }
102
- },
103
- meridiem : function (hour, minute, isLower) {
104
- if (hour < 4) {
105
- return 'रात';
106
- } else if (hour < 10) {
107
- return 'सुबह';
108
- } else if (hour < 17) {
109
- return 'दोपहर';
110
- } else if (hour < 20) {
111
- return 'शाम';
112
- } else {
113
- return 'रात';
114
- }
115
- },
116
- week : {
117
- dow : 0, // Sunday is the first day of the week.
118
- doy : 6 // The week that contains Jan 1st is the first week of the year.
38
+ var hi = moment.defineLocale('hi', {
39
+ months : 'जनवरी_फ़रवरी_मार्च_अप्रैल_मई_जून_जुलाई_अगस्त_सितम्बर_अक्टूबर_नवम्बर_दिसम्बर'.split('_'),
40
+ monthsShort : 'जन._फ़र._मार्च_अप्रै._मई_जून_जुल._अग._सित._अक्टू._नव._दिस.'.split('_'),
41
+ monthsParseExact: true,
42
+ weekdays : 'रविवार_सोमवार_मंगलवार_बुधवार_गुरूवार_शुक्रवार_शनिवार'.split('_'),
43
+ weekdaysShort : 'रवि_सोम_मंगल_बुध_गुरू_शुक्र_शनि'.split('_'),
44
+ weekdaysMin : 'र_सो_मं_बु_गु_शु_श'.split('_'),
45
+ longDateFormat : {
46
+ LT : 'A h:mm बजे',
47
+ LTS : 'A h:mm:ss बजे',
48
+ L : 'DD/MM/YYYY',
49
+ LL : 'D MMMM YYYY',
50
+ LLL : 'D MMMM YYYY, A h:mm बजे',
51
+ LLLL : 'dddd, D MMMM YYYY, A h:mm बजे'
52
+ },
53
+ calendar : {
54
+ sameDay : '[आज] LT',
55
+ nextDay : '[कल] LT',
56
+ nextWeek : 'dddd, LT',
57
+ lastDay : '[कल] LT',
58
+ lastWeek : '[पिछले] dddd, LT',
59
+ sameElse : 'L'
60
+ },
61
+ relativeTime : {
62
+ future : '%s में',
63
+ past : '%s पहले',
64
+ s : 'कुछ ही क्षण',
65
+ ss : '%d सेकंड',
66
+ m : 'एक मिनट',
67
+ mm : '%d मिनट',
68
+ h : 'एक घंटा',
69
+ hh : '%d घंटे',
70
+ d : 'एक दिन',
71
+ dd : '%d दिन',
72
+ M : 'एक महीने',
73
+ MM : '%d महीने',
74
+ y : 'एक वर्ष',
75
+ yy : '%d वर्ष'
76
+ },
77
+ preparse: function (string) {
78
+ return string.replace(/[१२३४५६७८९०]/g, function (match) {
79
+ return numberMap[match];
80
+ });
81
+ },
82
+ postformat: function (string) {
83
+ return string.replace(/\d/g, function (match) {
84
+ return symbolMap[match];
85
+ });
86
+ },
87
+ // Hindi notation for meridiems are quite fuzzy in practice. While there exists
88
+ // a rigid notion of a 'Pahar' it is not used as rigidly in modern Hindi.
89
+ meridiemParse: /रात|सुबह|दोपहर|शाम/,
90
+ meridiemHour : function (hour, meridiem) {
91
+ if (hour === 12) {
92
+ hour = 0;
93
+ }
94
+ if (meridiem === 'रात') {
95
+ return hour < 4 ? hour : hour + 12;
96
+ } else if (meridiem === 'सुबह') {
97
+ return hour;
98
+ } else if (meridiem === 'दोपहर') {
99
+ return hour >= 10 ? hour : hour + 12;
100
+ } else if (meridiem === 'शाम') {
101
+ return hour + 12;
102
+ }
103
+ },
104
+ meridiem : function (hour, minute, isLower) {
105
+ if (hour < 4) {
106
+ return 'रात';
107
+ } else if (hour < 10) {
108
+ return 'सुबह';
109
+ } else if (hour < 17) {
110
+ return 'दोपहर';
111
+ } else if (hour < 20) {
112
+ return 'शाम';
113
+ } else {
114
+ return 'रात';
119
115
  }
120
- });
121
- }));
116
+ },
117
+ week : {
118
+ dow : 0, // Sunday is the first day of the week.
119
+ doy : 6 // The week that contains Jan 1st is the first week of the year.
120
+ }
121
+ });
122
+
123
+ return hi;
124
+
125
+ })));
@@ -1,21 +1,27 @@
1
- // moment.js locale configuration
2
- // locale : hrvatski (hr)
3
- // author : Bojan Marković : https://github.com/bmarkovic
1
+ //! moment.js locale configuration
2
+ //! locale : Croatian [hr]
3
+ //! author : Bojan Marković : https://github.com/bmarkovic
4
4
 
5
- // based on (sl) translation by Robert Sedovšek
5
+ ;(function (global, factory) {
6
+ typeof exports === 'object' && typeof module !== 'undefined'
7
+ && typeof require === 'function' ? factory(require('../moment')) :
8
+ typeof define === 'function' && define.amd ? define(['../moment'], factory) :
9
+ factory(global.moment)
10
+ }(this, (function (moment) { 'use strict';
6
11
 
7
- (function (factory) {
8
- if (typeof define === 'function' && define.amd) {
9
- define(['moment'], factory); // AMD
10
- } else if (typeof exports === 'object') {
11
- module.exports = factory(require('../moment')); // Node
12
- } else {
13
- factory((typeof global !== 'undefined' ? global : this).moment); // node or other global
14
- }
15
- }(function (moment) {
16
- function translate(number, withoutSuffix, key) {
17
- var result = number + ' ';
18
- switch (key) {
12
+
13
+ function translate(number, withoutSuffix, key) {
14
+ var result = number + ' ';
15
+ switch (key) {
16
+ case 'ss':
17
+ if (number === 1) {
18
+ result += 'sekunda';
19
+ } else if (number === 2 || number === 3 || number === 4) {
20
+ result += 'sekunde';
21
+ } else {
22
+ result += 'sekundi';
23
+ }
24
+ return result;
19
25
  case 'm':
20
26
  return withoutSuffix ? 'jedna minuta' : 'jedne minute';
21
27
  case 'mm':
@@ -63,29 +69,33 @@
63
69
  result += 'godina';
64
70
  }
65
71
  return result;
66
- }
67
72
  }
73
+ }
68
74
 
69
- return moment.defineLocale('hr', {
70
- months : 'sječanj_veljača_ožujak_travanj_svibanj_lipanj_srpanj_kolovoz_rujan_listopad_studeni_prosinac'.split('_'),
71
- monthsShort : 'sje._vel._ožu._tra._svi._lip._srp._kol._ruj._lis._stu._pro.'.split('_'),
72
- weekdays : 'nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota'.split('_'),
73
- weekdaysShort : 'ned._pon._uto._sri._čet._pet._sub.'.split('_'),
74
- weekdaysMin : 'ne_po_ut_sr_če_pe_su'.split('_'),
75
- longDateFormat : {
76
- LT : 'H:mm',
77
- LTS : 'LT:ss',
78
- L : 'DD. MM. YYYY',
79
- LL : 'D. MMMM YYYY',
80
- LLL : 'D. MMMM YYYY LT',
81
- LLLL : 'dddd, D. MMMM YYYY LT'
82
- },
83
- calendar : {
84
- sameDay : '[danas u] LT',
85
- nextDay : '[sutra u] LT',
86
-
87
- nextWeek : function () {
88
- switch (this.day()) {
75
+ var hr = moment.defineLocale('hr', {
76
+ months : {
77
+ format: 'siječnja_veljače_ožujka_travnja_svibnja_lipnja_srpnja_kolovoza_rujna_listopada_studenoga_prosinca'.split('_'),
78
+ standalone: 'siječanj_veljača_ožujak_travanj_svibanj_lipanj_srpanj_kolovoz_rujan_listopad_studeni_prosinac'.split('_')
79
+ },
80
+ monthsShort : 'sij._velj._ožu._tra._svi._lip._srp._kol._ruj._lis._stu._pro.'.split('_'),
81
+ monthsParseExact: true,
82
+ weekdays : 'nedjelja_ponedjeljak_utorak_srijeda_četvrtak_petak_subota'.split('_'),
83
+ weekdaysShort : 'ned._pon._uto._sri._čet._pet._sub.'.split('_'),
84
+ weekdaysMin : 'ne_po_ut_sr_če_pe_su'.split('_'),
85
+ weekdaysParseExact : true,
86
+ longDateFormat : {
87
+ LT : 'H:mm',
88
+ LTS : 'H:mm:ss',
89
+ L : 'DD.MM.YYYY',
90
+ LL : 'D. MMMM YYYY',
91
+ LLL : 'D. MMMM YYYY H:mm',
92
+ LLLL : 'dddd, D. MMMM YYYY H:mm'
93
+ },
94
+ calendar : {
95
+ sameDay : '[danas u] LT',
96
+ nextDay : '[sutra u] LT',
97
+ nextWeek : function () {
98
+ switch (this.day()) {
89
99
  case 0:
90
100
  return '[u] [nedjelju] [u] LT';
91
101
  case 3:
@@ -97,11 +107,11 @@
97
107
  case 4:
98
108
  case 5:
99
109
  return '[u] dddd [u] LT';
100
- }
101
- },
102
- lastDay : '[jučer u] LT',
103
- lastWeek : function () {
104
- switch (this.day()) {
110
+ }
111
+ },
112
+ lastDay : '[jučer u] LT',
113
+ lastWeek : function () {
114
+ switch (this.day()) {
105
115
  case 0:
106
116
  case 3:
107
117
  return '[prošlu] dddd [u] LT';
@@ -112,30 +122,34 @@
112
122
  case 4:
113
123
  case 5:
114
124
  return '[prošli] dddd [u] LT';
115
- }
116
- },
117
- sameElse : 'L'
118
- },
119
- relativeTime : {
120
- future : 'za %s',
121
- past : 'prije %s',
122
- s : 'par sekundi',
123
- m : translate,
124
- mm : translate,
125
- h : translate,
126
- hh : translate,
127
- d : 'dan',
128
- dd : translate,
129
- M : 'mjesec',
130
- MM : translate,
131
- y : 'godinu',
132
- yy : translate
125
+ }
133
126
  },
134
- ordinalParse: /\d{1,2}\./,
135
- ordinal : '%d.',
136
- week : {
137
- dow : 1, // Monday is the first day of the week.
138
- doy : 7 // The week that contains Jan 1st is the first week of the year.
139
- }
140
- });
141
- }));
127
+ sameElse : 'L'
128
+ },
129
+ relativeTime : {
130
+ future : 'za %s',
131
+ past : 'prije %s',
132
+ s : 'par sekundi',
133
+ ss : translate,
134
+ m : translate,
135
+ mm : translate,
136
+ h : translate,
137
+ hh : translate,
138
+ d : 'dan',
139
+ dd : translate,
140
+ M : 'mjesec',
141
+ MM : translate,
142
+ y : 'godinu',
143
+ yy : translate
144
+ },
145
+ dayOfMonthOrdinalParse: /\d{1,2}\./,
146
+ ordinal : '%d.',
147
+ week : {
148
+ dow : 1, // Monday is the first day of the week.
149
+ doy : 7 // The week that contains Jan 1st is the first week of the year.
150
+ }
151
+ });
152
+
153
+ return hr;
154
+
155
+ })));
@@ -1,25 +1,23 @@
1
- // moment.js locale configuration
2
- // locale : hungarian (hu)
3
- // author : Adam Brunner : https://github.com/adambrunner
1
+ //! moment.js locale configuration
2
+ //! locale : Hungarian [hu]
3
+ //! author : Adam Brunner : https://github.com/adambrunner
4
4
 
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((typeof global !== 'undefined' ? global : this).moment); // node or other global
12
- }
13
- }(function (moment) {
14
- var weekEndings = 'vasárnap hétfőn kedden szerdán csütörtökön pénteken szombaton'.split(' ');
5
+ ;(function (global, factory) {
6
+ typeof exports === 'object' && typeof module !== 'undefined'
7
+ && typeof require === 'function' ? factory(require('../moment')) :
8
+ typeof define === 'function' && define.amd ? define(['../moment'], factory) :
9
+ factory(global.moment)
10
+ }(this, (function (moment) { 'use strict';
15
11
 
16
- function translate(number, withoutSuffix, key, isFuture) {
17
- var num = number,
18
- suffix;
19
12
 
20
- switch (key) {
13
+ var weekEndings = 'vasárnap hétfőn kedden szerdán csütörtökön pénteken szombaton'.split(' ');
14
+ function translate(number, withoutSuffix, key, isFuture) {
15
+ var num = number;
16
+ switch (key) {
21
17
  case 's':
22
18
  return (isFuture || withoutSuffix) ? 'néhány másodperc' : 'néhány másodperce';
19
+ case 'ss':
20
+ return num + (isFuture || withoutSuffix) ? ' másodperc' : ' másodperce';
23
21
  case 'm':
24
22
  return 'egy' + (isFuture || withoutSuffix ? ' perc' : ' perce');
25
23
  case 'mm':
@@ -40,72 +38,74 @@
40
38
  return 'egy' + (isFuture || withoutSuffix ? ' év' : ' éve');
41
39
  case 'yy':
42
40
  return num + (isFuture || withoutSuffix ? ' év' : ' éve');
43
- }
44
-
45
- return '';
46
41
  }
42
+ return '';
43
+ }
44
+ function week(isFuture) {
45
+ return (isFuture ? '' : '[múlt] ') + '[' + weekEndings[this.day()] + '] LT[-kor]';
46
+ }
47
47
 
48
- function week(isFuture) {
49
- return (isFuture ? '' : '[múlt] ') + '[' + weekEndings[this.day()] + '] LT[-kor]';
50
- }
51
-
52
- return moment.defineLocale('hu', {
53
- months : 'január_február_március_április_május_június_július_augusztus_szeptember_október_november_december'.split('_'),
54
- monthsShort : 'jan_feb_márc_ápr_máj_jún_júl_aug_szept_okt_nov_dec'.split('_'),
55
- weekdays : 'vasárnap_hétfő_kedd_szerda_csütörtök_péntek_szombat'.split('_'),
56
- weekdaysShort : 'vas_hét_kedd_sze_csüt_pén_szo'.split('_'),
57
- weekdaysMin : 'v_h_k_sze_cs_p_szo'.split('_'),
58
- longDateFormat : {
59
- LT : 'H:mm',
60
- LTS : 'LT:ss',
61
- L : 'YYYY.MM.DD.',
62
- LL : 'YYYY. MMMM D.',
63
- LLL : 'YYYY. MMMM D., LT',
64
- LLLL : 'YYYY. MMMM D., dddd LT'
65
- },
66
- meridiemParse: /de|du/i,
67
- isPM: function (input) {
68
- return input.charAt(1).toLowerCase() === 'u';
69
- },
70
- meridiem : function (hours, minutes, isLower) {
71
- if (hours < 12) {
72
- return isLower === true ? 'de' : 'DE';
73
- } else {
74
- return isLower === true ? 'du' : 'DU';
75
- }
76
- },
77
- calendar : {
78
- sameDay : '[ma] LT[-kor]',
79
- nextDay : '[holnap] LT[-kor]',
80
- nextWeek : function () {
81
- return week.call(this, true);
82
- },
83
- lastDay : '[tegnap] LT[-kor]',
84
- lastWeek : function () {
85
- return week.call(this, false);
86
- },
87
- sameElse : 'L'
48
+ var hu = moment.defineLocale('hu', {
49
+ months : 'január_február_március_április_május_június_július_augusztus_szeptember_október_november_december'.split('_'),
50
+ monthsShort : 'jan_feb_márc_ápr_máj_jún_júl_aug_szept_okt_nov_dec'.split('_'),
51
+ weekdays : 'vasárnap_hétfő_kedd_szerda_csütörtök_péntek_szombat'.split('_'),
52
+ weekdaysShort : 'vas_hét_kedd_sze_csüt_pén_szo'.split('_'),
53
+ weekdaysMin : 'v_h_k_sze_cs_p_szo'.split('_'),
54
+ longDateFormat : {
55
+ LT : 'H:mm',
56
+ LTS : 'H:mm:ss',
57
+ L : 'YYYY.MM.DD.',
58
+ LL : 'YYYY. MMMM D.',
59
+ LLL : 'YYYY. MMMM D. H:mm',
60
+ LLLL : 'YYYY. MMMM D., dddd H:mm'
61
+ },
62
+ meridiemParse: /de|du/i,
63
+ isPM: function (input) {
64
+ return input.charAt(1).toLowerCase() === 'u';
65
+ },
66
+ meridiem : function (hours, minutes, isLower) {
67
+ if (hours < 12) {
68
+ return isLower === true ? 'de' : 'DE';
69
+ } else {
70
+ return isLower === true ? 'du' : 'DU';
71
+ }
72
+ },
73
+ calendar : {
74
+ sameDay : '[ma] LT[-kor]',
75
+ nextDay : '[holnap] LT[-kor]',
76
+ nextWeek : function () {
77
+ return week.call(this, true);
88
78
  },
89
- relativeTime : {
90
- future : '%s múlva',
91
- past : '%s',
92
- s : translate,
93
- m : translate,
94
- mm : translate,
95
- h : translate,
96
- hh : translate,
97
- d : translate,
98
- dd : translate,
99
- M : translate,
100
- MM : translate,
101
- y : translate,
102
- yy : translate
79
+ lastDay : '[tegnap] LT[-kor]',
80
+ lastWeek : function () {
81
+ return week.call(this, false);
103
82
  },
104
- ordinalParse: /\d{1,2}\./,
105
- ordinal : '%d.',
106
- week : {
107
- dow : 1, // Monday is the first day of the week.
108
- doy : 7 // The week that contains Jan 1st is the first week of the year.
109
- }
110
- });
111
- }));
83
+ sameElse : 'L'
84
+ },
85
+ relativeTime : {
86
+ future : '%s múlva',
87
+ past : '%s',
88
+ s : translate,
89
+ ss : translate,
90
+ m : translate,
91
+ mm : translate,
92
+ h : translate,
93
+ hh : translate,
94
+ d : translate,
95
+ dd : translate,
96
+ M : translate,
97
+ MM : translate,
98
+ y : translate,
99
+ yy : translate
100
+ },
101
+ dayOfMonthOrdinalParse: /\d{1,2}\./,
102
+ ordinal : '%d.',
103
+ week : {
104
+ dow : 1, // Monday is the first day of the week.
105
+ doy : 4 // The week that contains Jan 4th is the first week of the year.
106
+ }
107
+ });
108
+
109
+ return hu;
110
+
111
+ })));