momentjs-rails 1.5.0 → 1.6.2
Sign up to get free protection for your applications and to get access to all the features.
- data/README.md +5 -1
- data/changelog.md +4 -0
- data/vendor/assets/javascripts/moment.js +406 -223
- data/vendor/assets/javascripts/moment/ca.js +60 -0
- data/vendor/assets/javascripts/moment/da.js +50 -0
- data/vendor/assets/javascripts/moment/de.js +50 -0
- data/vendor/assets/javascripts/moment/en-gb.js +54 -0
- data/vendor/assets/javascripts/moment/es.js +60 -0
- data/vendor/assets/javascripts/moment/eu.js +50 -0
- data/vendor/assets/javascripts/moment/fi.js +94 -0
- data/vendor/assets/javascripts/moment/fr.js +50 -0
- data/vendor/assets/javascripts/moment/gl.js +60 -0
- data/vendor/assets/javascripts/moment/is.js +128 -0
- data/vendor/assets/javascripts/moment/it.js +50 -0
- data/vendor/assets/javascripts/moment/jp.js +57 -0
- data/vendor/assets/javascripts/moment/kr.js +54 -0
- data/vendor/assets/javascripts/moment/nb.js +50 -0
- data/vendor/assets/javascripts/moment/nl.js +50 -0
- data/vendor/assets/javascripts/moment/pl.js +72 -0
- data/vendor/assets/javascripts/moment/pt.js +54 -0
- data/vendor/assets/javascripts/moment/ru.js +103 -0
- data/vendor/assets/javascripts/moment/sv.js +54 -0
- data/vendor/assets/javascripts/moment/tr.js +54 -0
- data/vendor/assets/javascripts/moment/zh-cn.js +63 -0
- data/vendor/assets/javascripts/moment/zh-tw.js +63 -0
- metadata +74 -29
@@ -0,0 +1,60 @@
|
|
1
|
+
(function () {
|
2
|
+
var lang = {
|
3
|
+
months : "Xaneiro_Febreiro_Marzo_Abril_Maio_Xuño_Xullo_Agosto_Setembro_Octubro_Novembro_Decembro".split("_"),
|
4
|
+
monthsShort : "Xan._Feb._Mar._Abr._Mai._Xuñ._Xul._Ago._Set._Out._Nov._Dec.".split("_"),
|
5
|
+
weekdays : "Domingo_Luns_Martes_Mércores_Xoves_Venres_Sábado".split("_"),
|
6
|
+
weekdaysShort : "Dom._Lun._Mar._Mér._Xov._Ven._Sáb.".split("_"),
|
7
|
+
longDateFormat : {
|
8
|
+
LT : "H:mm",
|
9
|
+
L : "DD/MM/YYYY",
|
10
|
+
LL : "D MMMM YYYY",
|
11
|
+
LLL : "D MMMM YYYY LT",
|
12
|
+
LLLL : "dddd D MMMM YYYY LT"
|
13
|
+
},
|
14
|
+
calendar : {
|
15
|
+
sameDay : function () {
|
16
|
+
return '[hoxe ' + ((this.hours() !== 1) ? 'ás' : 'a') + '] LT';
|
17
|
+
},
|
18
|
+
nextDay : function () {
|
19
|
+
return '[mañá ' + ((this.hours() !== 1) ? 'ás' : 'a') + '] LT';
|
20
|
+
},
|
21
|
+
nextWeek : function () {
|
22
|
+
return 'dddd [' + ((this.hours() !== 1) ? 'ás' : 'a') + '] LT';
|
23
|
+
},
|
24
|
+
lastDay : function () {
|
25
|
+
return '[onte ' + ((this.hours() !== 1) ? 'á' : 'a') + '] LT';
|
26
|
+
},
|
27
|
+
lastWeek : function () {
|
28
|
+
return '[o] dddd [pasado ' + ((this.hours() !== 1) ? 'ás' : 'a') + '] LT';
|
29
|
+
},
|
30
|
+
sameElse : 'L'
|
31
|
+
},
|
32
|
+
relativeTime : {
|
33
|
+
future : "en %s",
|
34
|
+
past : "fai %s",
|
35
|
+
s : "uns segundo",
|
36
|
+
m : "un minuto",
|
37
|
+
mm : "%d minutos",
|
38
|
+
h : "unha hora",
|
39
|
+
hh : "%d horas",
|
40
|
+
d : "un día",
|
41
|
+
dd : "%d días",
|
42
|
+
M : "un mes",
|
43
|
+
MM : "%d meses",
|
44
|
+
y : "un ano",
|
45
|
+
yy : "%d anos"
|
46
|
+
},
|
47
|
+
ordinal : function (number) {
|
48
|
+
return 'º';
|
49
|
+
}
|
50
|
+
};
|
51
|
+
|
52
|
+
// Node
|
53
|
+
if (typeof module !== 'undefined') {
|
54
|
+
module.exports = lang;
|
55
|
+
}
|
56
|
+
// Browser
|
57
|
+
if (typeof window !== 'undefined' && this.moment && this.moment.lang) {
|
58
|
+
this.moment.lang('gl', lang);
|
59
|
+
}
|
60
|
+
}());
|
@@ -0,0 +1,128 @@
|
|
1
|
+
(function () {
|
2
|
+
var plural = function (n) {
|
3
|
+
if (n % 100 == 11) {
|
4
|
+
return true;
|
5
|
+
} else if (n % 10 == 1) {
|
6
|
+
return false;
|
7
|
+
} else {
|
8
|
+
return true;
|
9
|
+
}
|
10
|
+
},
|
11
|
+
|
12
|
+
translate = function (number, withoutSuffix, key, isFuture) {
|
13
|
+
var result = number + " ";
|
14
|
+
switch (key) {
|
15
|
+
case 's':
|
16
|
+
return withoutSuffix || isFuture ? 'nokkrar sekúndur' : 'nokkrum sekúndum';
|
17
|
+
case 'm':
|
18
|
+
return withoutSuffix ? 'mínúta' : 'mínútu';
|
19
|
+
case 'mm':
|
20
|
+
if (plural(number)) {
|
21
|
+
return result + (withoutSuffix || isFuture ? 'mínútur' : 'mínútum');
|
22
|
+
} else if (withoutSuffix) {
|
23
|
+
return result + 'mínúta';
|
24
|
+
} else {
|
25
|
+
return result + 'mínútu';
|
26
|
+
}
|
27
|
+
case 'hh':
|
28
|
+
if (plural(number)) {
|
29
|
+
return result + (withoutSuffix || isFuture ? 'klukkustundir' : 'klukkustundum');
|
30
|
+
} else {
|
31
|
+
return result + 'klukkustund';
|
32
|
+
}
|
33
|
+
case 'd':
|
34
|
+
if (withoutSuffix) {
|
35
|
+
return 'dagur'
|
36
|
+
} else {
|
37
|
+
return isFuture ? 'dag' : 'degi';
|
38
|
+
}
|
39
|
+
case 'dd':
|
40
|
+
if (plural(number)) {
|
41
|
+
if (withoutSuffix) {
|
42
|
+
return result + 'dagar'
|
43
|
+
} else {
|
44
|
+
return result + (isFuture ? 'daga' : 'dögum');
|
45
|
+
}
|
46
|
+
} else if (withoutSuffix) {
|
47
|
+
return result + 'dagur'
|
48
|
+
} else {
|
49
|
+
return result + (isFuture ? 'dag' : 'degi');
|
50
|
+
}
|
51
|
+
case 'M':
|
52
|
+
if (withoutSuffix) {
|
53
|
+
return 'mánuður'
|
54
|
+
} else {
|
55
|
+
return isFuture ? 'mánuð' : 'mánuði';
|
56
|
+
}
|
57
|
+
case 'MM':
|
58
|
+
if (plural(number)) {
|
59
|
+
if (withoutSuffix) {
|
60
|
+
return result + 'mánuðir'
|
61
|
+
} else {
|
62
|
+
return result + (isFuture ? 'mánuði' : 'mánuðum');
|
63
|
+
}
|
64
|
+
} else if (withoutSuffix) {
|
65
|
+
return result + 'mánuður';
|
66
|
+
} else {
|
67
|
+
return result + (isFuture ? 'mánuð' : 'mánuði');
|
68
|
+
}
|
69
|
+
case 'y':
|
70
|
+
return withoutSuffix || isFuture ? 'ár' : 'ári';
|
71
|
+
case 'yy':
|
72
|
+
if (plural(number)) {
|
73
|
+
return result + (withoutSuffix || isFuture ? 'ár' : 'árum');
|
74
|
+
} else {
|
75
|
+
return result + (withoutSuffix || isFuture ? 'ár' : 'ári');
|
76
|
+
}
|
77
|
+
}
|
78
|
+
},
|
79
|
+
|
80
|
+
lang = {
|
81
|
+
months : "janúar_febrúar_mars_apríl_maí_júní_júlí_ágúst_september_október_nóvember_desember".split("_"),
|
82
|
+
monthsShort : "jan_feb_mar_apr_maí_jún_júl_ágú_sep_okt_nóv_des".split("_"),
|
83
|
+
weekdays : "sunnudagur_mánudagur_þriðjudagur_miðvikudagur_fimmtudagur_föstudagur_laugardagur".split("_"),
|
84
|
+
weekdaysShort : "sun_mán_þri_mið_fim_fös_lau".split("_"),
|
85
|
+
longDateFormat : {
|
86
|
+
LT : "H:mm",
|
87
|
+
L : "DD/MM/YYYY",
|
88
|
+
LL : "D. MMMM YYYY",
|
89
|
+
LLL : "D. MMMM YYYY kl. LT",
|
90
|
+
LLLL : "dddd, D. MMMM YYYY kl. LT"
|
91
|
+
},
|
92
|
+
calendar : {
|
93
|
+
sameDay : '[í dag kl.] LT',
|
94
|
+
nextDay : '[á morgun kl.] LT',
|
95
|
+
nextWeek : 'dddd [kl.] LT',
|
96
|
+
lastDay : '[í gær kl.] LT',
|
97
|
+
lastWeek : '[síðasta] dddd [kl.] LT',
|
98
|
+
sameElse : 'L'
|
99
|
+
},
|
100
|
+
relativeTime : {
|
101
|
+
future : "eftir %s",
|
102
|
+
past : "fyrir %s síðan",
|
103
|
+
s : translate,
|
104
|
+
m : translate,
|
105
|
+
mm : translate,
|
106
|
+
h : "klukkustund",
|
107
|
+
hh : translate,
|
108
|
+
d : translate,
|
109
|
+
dd : translate,
|
110
|
+
M : translate,
|
111
|
+
MM : translate,
|
112
|
+
y : translate,
|
113
|
+
yy : translate,
|
114
|
+
},
|
115
|
+
ordinal : function (number) {
|
116
|
+
return '.';
|
117
|
+
}
|
118
|
+
};
|
119
|
+
|
120
|
+
// Node
|
121
|
+
if (typeof module !== 'undefined') {
|
122
|
+
module.exports = lang;
|
123
|
+
}
|
124
|
+
// Browser
|
125
|
+
if (typeof window !== 'undefined' && this.moment && this.moment.lang) {
|
126
|
+
this.moment.lang('is', lang);
|
127
|
+
}
|
128
|
+
}());
|
@@ -0,0 +1,50 @@
|
|
1
|
+
(function () {
|
2
|
+
var lang = {
|
3
|
+
months : "Gennaio_Febbraio_Marzo_Aprile_Maggio_Giugno_Luglio_Agosto_Settebre_Ottobre_Novembre_Dicembre".split("_"),
|
4
|
+
monthsShort : "Gen_Feb_Mar_Apr_Mag_Giu_Lug_Ago_Set_Ott_Nov_Dic".split("_"),
|
5
|
+
weekdays : "Domenica_Lunedi_Martedi_Mercoledi_Giovedi_Venerdi_Sabato".split("_"),
|
6
|
+
weekdaysShort : "Dom_Lun_Mar_Mer_Gio_Ven_Sab".split("_"),
|
7
|
+
longDateFormat : {
|
8
|
+
LT : "HH:mm",
|
9
|
+
L : "DD/MM/YYYY",
|
10
|
+
LL : "D MMMM YYYY",
|
11
|
+
LLL : "D MMMM YYYY LT",
|
12
|
+
LLLL : "dddd, D MMMM YYYY LT"
|
13
|
+
},
|
14
|
+
calendar : {
|
15
|
+
sameDay: '[Oggi alle] LT',
|
16
|
+
nextDay: '[Domani alle] LT',
|
17
|
+
nextWeek: 'dddd [alle] LT',
|
18
|
+
lastDay: '[Ieri alle] LT',
|
19
|
+
lastWeek: '[lo scorso] dddd [alle] LT',
|
20
|
+
sameElse: 'L'
|
21
|
+
},
|
22
|
+
relativeTime : {
|
23
|
+
future : "in %s",
|
24
|
+
past : "%s fa",
|
25
|
+
s : "secondi",
|
26
|
+
m : "un minuto",
|
27
|
+
mm : "%d minuti",
|
28
|
+
h : "un ora",
|
29
|
+
hh : "%d ore",
|
30
|
+
d : "un giorno",
|
31
|
+
dd : "%d giorni",
|
32
|
+
M : "un mese",
|
33
|
+
MM : "%d mesi",
|
34
|
+
y : "un anno",
|
35
|
+
yy : "%d anni"
|
36
|
+
},
|
37
|
+
ordinal: function () {
|
38
|
+
return 'º';
|
39
|
+
}
|
40
|
+
};
|
41
|
+
|
42
|
+
// Node
|
43
|
+
if (typeof module !== 'undefined') {
|
44
|
+
module.exports = lang;
|
45
|
+
}
|
46
|
+
// Browser
|
47
|
+
if (typeof window !== 'undefined' && this.moment && this.moment.lang) {
|
48
|
+
this.moment.lang('it', lang);
|
49
|
+
}
|
50
|
+
}());
|
@@ -0,0 +1,57 @@
|
|
1
|
+
(function () {
|
2
|
+
var lang = {
|
3
|
+
months : "1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),
|
4
|
+
monthsShort : "1月_2月_3月_4月_5月_6月_7月_8月_9月_10月_11月_12月".split("_"),
|
5
|
+
weekdays : "日曜日_月曜日_火曜日_水曜日_木曜日_金曜日_土曜日".split("_"),
|
6
|
+
weekdaysShort : "日_月_火_水_木_金_土".split("_"),
|
7
|
+
longDateFormat : {
|
8
|
+
LT : "Ah:mm",
|
9
|
+
L : "YYYY/MM/DD",
|
10
|
+
LL : "YYYY年M月D日",
|
11
|
+
LLL : "YYYY年M月D日 LT",
|
12
|
+
LLLL : "YYYY年M月D日 dddd LT"
|
13
|
+
},
|
14
|
+
meridiem : function (hour, minute, isLower) {
|
15
|
+
if (hour < 12) {
|
16
|
+
return "午前";
|
17
|
+
} else {
|
18
|
+
return "午後";
|
19
|
+
}
|
20
|
+
},
|
21
|
+
calendar : {
|
22
|
+
sameDay : '[今日] LT',
|
23
|
+
nextDay : '[明日] LT',
|
24
|
+
nextWeek : '[来週]dddd LT',
|
25
|
+
lastDay : '[昨日] LT',
|
26
|
+
lastWeek : '[前週]dddd LT',
|
27
|
+
sameElse : 'L'
|
28
|
+
},
|
29
|
+
relativeTime : {
|
30
|
+
future : "%s後",
|
31
|
+
past : "%s前",
|
32
|
+
s : "数秒",
|
33
|
+
m : "1分",
|
34
|
+
mm : "%d分",
|
35
|
+
h : "1時間",
|
36
|
+
hh : "%d時間",
|
37
|
+
d : "1日",
|
38
|
+
dd : "%d日",
|
39
|
+
M : "1ヶ月",
|
40
|
+
MM : "%dヶ月",
|
41
|
+
y : "1年",
|
42
|
+
yy : "%d年"
|
43
|
+
},
|
44
|
+
ordinal : function (number) {
|
45
|
+
return '';
|
46
|
+
}
|
47
|
+
};
|
48
|
+
|
49
|
+
// Node
|
50
|
+
if (typeof module !== 'undefined') {
|
51
|
+
module.exports = lang;
|
52
|
+
}
|
53
|
+
// Browser
|
54
|
+
if (typeof window !== 'undefined' && this.moment && this.moment.lang) {
|
55
|
+
this.moment.lang('jp', lang);
|
56
|
+
}
|
57
|
+
}());
|
@@ -0,0 +1,54 @@
|
|
1
|
+
(function () {
|
2
|
+
var lang = {
|
3
|
+
months : "1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),
|
4
|
+
monthsShort : "1월_2월_3월_4월_5월_6월_7월_8월_9월_10월_11월_12월".split("_"),
|
5
|
+
weekdays : "일요일_월요일_화요일_수요일_목요일_금요일_토요일".split("_"),
|
6
|
+
weekdaysShort : "일_월_화_수_목_금_토".split("_"),
|
7
|
+
longDateFormat : {
|
8
|
+
LT : "A h시 mm분",
|
9
|
+
L : "YYYY.MM.DD",
|
10
|
+
LL : "YYYY년 MMMM D일",
|
11
|
+
LLL : "YYYY년 MMMM D일 LT",
|
12
|
+
LLLL : "YYYY년 MMMM D일 dddd LT"
|
13
|
+
},
|
14
|
+
meridiem : function(hour, minute, isUpper) {
|
15
|
+
return hour < 12 ? '오전' : '오후';
|
16
|
+
},
|
17
|
+
calendar : {
|
18
|
+
sameDay : '오늘 LT',
|
19
|
+
nextDay : '내일 LT',
|
20
|
+
nextWeek : 'dddd LT',
|
21
|
+
lastDay : '어제 LT',
|
22
|
+
lastWeek : '지난주 dddd LT',
|
23
|
+
sameElse : 'L'
|
24
|
+
},
|
25
|
+
relativeTime : {
|
26
|
+
future : "%s 후",
|
27
|
+
past : "%s 전",
|
28
|
+
s : "몇초",
|
29
|
+
ss : "%d초",
|
30
|
+
m : "일분",
|
31
|
+
mm : "%d분",
|
32
|
+
h : "한시간",
|
33
|
+
hh : "%d시간",
|
34
|
+
d : "하루",
|
35
|
+
dd : "%d일",
|
36
|
+
M : "한달",
|
37
|
+
MM : "%d달",
|
38
|
+
y : "일년",
|
39
|
+
yy : "%d년"
|
40
|
+
},
|
41
|
+
ordinal : function (number) {
|
42
|
+
return '일';
|
43
|
+
}
|
44
|
+
};
|
45
|
+
|
46
|
+
// Node
|
47
|
+
if (typeof module !== 'undefined') {
|
48
|
+
module.exports = lang;
|
49
|
+
}
|
50
|
+
// Browser
|
51
|
+
if (typeof window !== 'undefined' && this.moment && this.moment.lang) {
|
52
|
+
this.moment.lang('kr', lang);
|
53
|
+
}
|
54
|
+
}());
|
@@ -0,0 +1,50 @@
|
|
1
|
+
(function () {
|
2
|
+
var lang = {
|
3
|
+
months : "januar_februar_mars_april_mai_juni_juli_august_september_oktober_november_desember".split("_"),
|
4
|
+
monthsShort : "jan_feb_mar_apr_mai_jun_jul_aug_sep_okt_nov_des".split("_"),
|
5
|
+
weekdays : "søndag_mandag_tirsdag_onsdag_torsdag_fredag_lørdag".split("_"),
|
6
|
+
weekdaysShort : "søn_man_tir_ons_tor_fre_lør".split("_"),
|
7
|
+
longDateFormat : {
|
8
|
+
LT : "HH:mm",
|
9
|
+
L : "YYYY-MM-DD",
|
10
|
+
LL : "D MMMM YYYY",
|
11
|
+
LLL : "D MMMM YYYY LT",
|
12
|
+
LLLL : "dddd D MMMM YYYY LT"
|
13
|
+
},
|
14
|
+
calendar : {
|
15
|
+
sameDay: '[I dag klokken] LT',
|
16
|
+
nextDay: '[I morgen klokken] LT',
|
17
|
+
nextWeek: 'dddd [klokken] LT',
|
18
|
+
lastDay: '[I går klokken] LT',
|
19
|
+
lastWeek: '[Forrige] dddd [klokken] LT',
|
20
|
+
sameElse: 'L'
|
21
|
+
},
|
22
|
+
relativeTime : {
|
23
|
+
future : "om %s",
|
24
|
+
past : "for %s siden",
|
25
|
+
s : "noen sekunder",
|
26
|
+
m : "ett minutt",
|
27
|
+
mm : "%d minutter",
|
28
|
+
h : "en time",
|
29
|
+
hh : "%d timer",
|
30
|
+
d : "en dag",
|
31
|
+
dd : "%d dager",
|
32
|
+
M : "en måned",
|
33
|
+
MM : "%d måneder",
|
34
|
+
y : "ett år",
|
35
|
+
yy : "%d år"
|
36
|
+
},
|
37
|
+
ordinal : function (number) {
|
38
|
+
return '.';
|
39
|
+
}
|
40
|
+
};
|
41
|
+
|
42
|
+
// Node
|
43
|
+
if (typeof module !== 'undefined') {
|
44
|
+
module.exports = lang;
|
45
|
+
}
|
46
|
+
// Browser
|
47
|
+
if (typeof window !== 'undefined' && this.moment && this.moment.lang) {
|
48
|
+
this.moment.lang('nb', lang);
|
49
|
+
}
|
50
|
+
}());
|
@@ -0,0 +1,50 @@
|
|
1
|
+
(function () {
|
2
|
+
var lang = {
|
3
|
+
months : "januari_februari_maart_april_mei_juni_juli_augustus_september_oktober_november_december".split("_"),
|
4
|
+
monthsShort : "jan._feb._mar._apr._mei._jun._jul._aug._sep._okt._nov._dec.".split("_"),
|
5
|
+
weekdays : "zondag_maandag_dinsdag_woensdag_donderdag_vrijdag_zaterdag".split("_"),
|
6
|
+
weekdaysShort : "zo._ma._di._wo._do._vr._za.".split("_"),
|
7
|
+
longDateFormat : {
|
8
|
+
LT : "HH:mm",
|
9
|
+
L : "DD-MM-YYYY",
|
10
|
+
LL : "D MMMM YYYY",
|
11
|
+
LLL : "D MMMM YYYY LT",
|
12
|
+
LLLL : "dddd D MMMM YYYY LT"
|
13
|
+
},
|
14
|
+
calendar : {
|
15
|
+
sameDay: '[Vandaag om] LT',
|
16
|
+
nextDay: '[Morgen om] LT',
|
17
|
+
nextWeek: 'dddd [om] LT',
|
18
|
+
lastDay: '[Gisteren om] LT',
|
19
|
+
lastWeek: '[afgelopen] dddd [om] LT',
|
20
|
+
sameElse: 'L'
|
21
|
+
},
|
22
|
+
relativeTime : {
|
23
|
+
future : "over %s",
|
24
|
+
past : "%s geleden",
|
25
|
+
s : "een paar seconden",
|
26
|
+
m : "één minuut",
|
27
|
+
mm : "%d minuten",
|
28
|
+
h : "één uur",
|
29
|
+
hh : "%d uur",
|
30
|
+
d : "één dag",
|
31
|
+
dd : "%d dagen",
|
32
|
+
M : "één maand",
|
33
|
+
MM : "%d maanden",
|
34
|
+
y : "één jaar",
|
35
|
+
yy : "%d jaar"
|
36
|
+
},
|
37
|
+
ordinal : function (number) {
|
38
|
+
return (number === 1 || number === 8 || number >= 20) ? 'ste' : 'de';
|
39
|
+
}
|
40
|
+
};
|
41
|
+
|
42
|
+
// Node
|
43
|
+
if (typeof module !== 'undefined') {
|
44
|
+
module.exports = lang;
|
45
|
+
}
|
46
|
+
// Browser
|
47
|
+
if (typeof window !== 'undefined' && this.moment && this.moment.lang) {
|
48
|
+
this.moment.lang('nl', lang);
|
49
|
+
}
|
50
|
+
}());
|