effective_bootstrap 0.4.8 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +4 -0
- data/app/assets/javascripts/effective_date/input.js +1 -1
- data/app/assets/javascripts/effective_datetime/input.js +1 -1
- data/app/assets/javascripts/effective_time/input.js +1 -1
- data/app/assets/javascripts/moment/locale/af.js +72 -0
- data/app/assets/javascripts/moment/locale/ar-dz.js +58 -0
- data/app/assets/javascripts/moment/locale/ar-kw.js +58 -0
- data/app/assets/javascripts/moment/locale/ar-ly.js +121 -0
- data/app/assets/javascripts/moment/locale/ar-ma.js +58 -0
- data/app/assets/javascripts/moment/locale/ar-sa.js +103 -0
- data/app/assets/javascripts/moment/locale/ar-tn.js +58 -0
- data/app/assets/javascripts/moment/locale/ar.js +134 -0
- data/app/assets/javascripts/moment/locale/az.js +104 -0
- data/app/assets/javascripts/moment/locale/be.js +131 -0
- data/app/assets/javascripts/moment/locale/bg.js +89 -0
- data/app/assets/javascripts/moment/locale/bm.js +57 -0
- data/app/assets/javascripts/moment/locale/bn.js +118 -0
- data/app/assets/javascripts/moment/locale/bo.js +118 -0
- data/app/assets/javascripts/moment/locale/br.js +107 -0
- data/app/assets/javascripts/moment/locale/bs.js +150 -0
- data/app/assets/javascripts/moment/locale/ca.js +87 -0
- data/app/assets/javascripts/moment/locale/cs.js +171 -0
- data/app/assets/javascripts/moment/locale/cv.js +62 -0
- data/app/assets/javascripts/moment/locale/cy.js +79 -0
- data/app/assets/javascripts/moment/locale/da.js +59 -0
- data/app/assets/javascripts/moment/locale/de-at.js +75 -0
- data/app/assets/javascripts/moment/locale/de-ch.js +75 -0
- data/app/assets/javascripts/moment/locale/de.js +75 -0
- data/app/assets/javascripts/moment/locale/dv.js +98 -0
- data/app/assets/javascripts/moment/locale/el.js +99 -0
- data/app/assets/javascripts/moment/locale/en-SG.js +66 -0
- data/app/assets/javascripts/moment/locale/en-au.js +66 -0
- data/app/assets/javascripts/moment/locale/en-ca.js +62 -0
- data/app/assets/javascripts/moment/locale/en-gb.js +66 -0
- data/app/assets/javascripts/moment/locale/en-ie.js +66 -0
- data/app/assets/javascripts/moment/locale/en-il.js +61 -0
- data/app/assets/javascripts/moment/locale/en-nz.js +66 -0
- data/app/assets/javascripts/moment/locale/eo.js +70 -0
- data/app/assets/javascripts/moment/locale/es-do.js +91 -0
- data/app/assets/javascripts/moment/locale/es-us.js +91 -0
- data/app/assets/javascripts/moment/locale/es.js +91 -0
- data/app/assets/javascripts/moment/locale/et.js +79 -0
- data/app/assets/javascripts/moment/locale/eu.js +65 -0
- data/app/assets/javascripts/moment/locale/fa.js +105 -0
- data/app/assets/javascripts/moment/locale/fi.js +108 -0
- data/app/assets/javascripts/moment/locale/fo.js +59 -0
- data/app/assets/javascripts/moment/locale/fr-ca.js +73 -0
- data/app/assets/javascripts/moment/locale/fr-ch.js +77 -0
- data/app/assets/javascripts/moment/locale/fr.js +82 -0
- data/app/assets/javascripts/moment/locale/fy.js +74 -0
- data/app/assets/javascripts/moment/locale/ga.js +76 -0
- data/app/assets/javascripts/moment/locale/gd.js +75 -0
- data/app/assets/javascripts/moment/locale/gl.js +76 -0
- data/app/assets/javascripts/moment/locale/gom-latn.js +122 -0
- data/app/assets/javascripts/moment/locale/gu.js +123 -0
- data/app/assets/javascripts/moment/locale/he.js +96 -0
- data/app/assets/javascripts/moment/locale/hi.js +123 -0
- data/app/assets/javascripts/moment/locale/hr.js +153 -0
- data/app/assets/javascripts/moment/locale/hu.js +109 -0
- data/app/assets/javascripts/moment/locale/hy-am.js +94 -0
- data/app/assets/javascripts/moment/locale/id.js +81 -0
- data/app/assets/javascripts/moment/locale/is.js +131 -0
- data/app/assets/javascripts/moment/locale/it-ch.js +68 -0
- data/app/assets/javascripts/moment/locale/it.js +68 -0
- data/app/assets/javascripts/moment/locale/ja.js +91 -0
- data/app/assets/javascripts/moment/locale/jv.js +81 -0
- data/app/assets/javascripts/moment/locale/ka.js +88 -0
- data/app/assets/javascripts/moment/locale/kk.js +86 -0
- data/app/assets/javascripts/moment/locale/km.js +109 -0
- data/app/assets/javascripts/moment/locale/kn.js +125 -0
- data/app/assets/javascripts/moment/locale/ko.js +80 -0
- data/app/assets/javascripts/moment/locale/ku.js +118 -0
- data/app/assets/javascripts/moment/locale/ky.js +86 -0
- data/app/assets/javascripts/moment/locale/lb.js +135 -0
- data/app/assets/javascripts/moment/locale/lo.js +69 -0
- data/app/assets/javascripts/moment/locale/lt.js +117 -0
- data/app/assets/javascripts/moment/locale/lv.js +96 -0
- data/app/assets/javascripts/moment/locale/me.js +111 -0
- data/app/assets/javascripts/moment/locale/mi.js +63 -0
- data/app/assets/javascripts/moment/locale/mk.js +89 -0
- data/app/assets/javascripts/moment/locale/ml.js +80 -0
- data/app/assets/javascripts/moment/locale/mn.js +103 -0
- data/app/assets/javascripts/moment/locale/mr.js +159 -0
- data/app/assets/javascripts/moment/locale/ms-my.js +81 -0
- data/app/assets/javascripts/moment/locale/ms.js +81 -0
- data/app/assets/javascripts/moment/locale/mt.js +59 -0
- data/app/assets/javascripts/moment/locale/my.js +92 -0
- data/app/assets/javascripts/moment/locale/nb.js +61 -0
- data/app/assets/javascripts/moment/locale/ne.js +122 -0
- data/app/assets/javascripts/moment/locale/nl-be.js +86 -0
- data/app/assets/javascripts/moment/locale/nl.js +86 -0
- data/app/assets/javascripts/moment/locale/nn.js +59 -0
- data/app/assets/javascripts/moment/locale/pa-in.js +123 -0
- data/app/assets/javascripts/moment/locale/pl.js +125 -0
- data/app/assets/javascripts/moment/locale/pt-br.js +60 -0
- data/app/assets/javascripts/moment/locale/pt.js +64 -0
- data/app/assets/javascripts/moment/locale/ro.js +74 -0
- data/app/assets/javascripts/moment/locale/ru.js +181 -0
- data/app/assets/javascripts/moment/locale/sd.js +97 -0
- data/app/assets/javascripts/moment/locale/se.js +59 -0
- data/app/assets/javascripts/moment/locale/si.js +70 -0
- data/app/assets/javascripts/moment/locale/sk.js +155 -0
- data/app/assets/javascripts/moment/locale/sl.js +172 -0
- data/app/assets/javascripts/moment/locale/sq.js +67 -0
- data/app/assets/javascripts/moment/locale/sr-cyrl.js +110 -0
- data/app/assets/javascripts/moment/locale/sr.js +110 -0
- data/app/assets/javascripts/moment/locale/ss.js +87 -0
- data/app/assets/javascripts/moment/locale/sv.js +68 -0
- data/app/assets/javascripts/moment/locale/sw.js +58 -0
- data/app/assets/javascripts/moment/locale/ta.js +128 -0
- data/app/assets/javascripts/moment/locale/te.js +88 -0
- data/app/assets/javascripts/moment/locale/tet.js +66 -0
- data/app/assets/javascripts/moment/locale/tg.js +115 -0
- data/app/assets/javascripts/moment/locale/th.js +66 -0
- data/app/assets/javascripts/moment/locale/tl-ph.js +61 -0
- data/app/assets/javascripts/moment/locale/tlh.js +121 -0
- data/app/assets/javascripts/moment/locale/tr.js +93 -0
- data/app/assets/javascripts/moment/locale/tzl.js +90 -0
- data/app/assets/javascripts/moment/locale/tzm-latn.js +57 -0
- data/app/assets/javascripts/moment/locale/tzm.js +57 -0
- data/app/assets/javascripts/moment/locale/ug-cn.js +118 -0
- data/app/assets/javascripts/moment/locale/uk.js +153 -0
- data/app/assets/javascripts/moment/locale/ur.js +97 -0
- data/app/assets/javascripts/moment/locale/uz-latn.js +57 -0
- data/app/assets/javascripts/moment/locale/uz.js +57 -0
- data/app/assets/javascripts/moment/locale/vi.js +78 -0
- data/app/assets/javascripts/moment/locale/x-pseudo.js +67 -0
- data/app/assets/javascripts/moment/locale/yo.js +59 -0
- data/app/assets/javascripts/moment/locale/zh-cn.js +109 -0
- data/app/assets/javascripts/moment/locale/zh-hk.js +102 -0
- data/app/assets/javascripts/moment/locale/zh-tw.js +102 -0
- data/app/assets/javascripts/moment/moment.js +4603 -0
- data/lib/effective_bootstrap/version.rb +1 -1
- metadata +129 -2
- data/app/assets/javascripts/effective_datetime/moment.js +0 -4535
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
//! moment.js locale configuration
|
|
2
|
+
|
|
3
|
+
;(function (global, factory) {
|
|
4
|
+
typeof exports === 'object' && typeof module !== 'undefined'
|
|
5
|
+
&& typeof require === 'function' ? factory(require('../moment')) :
|
|
6
|
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
|
7
|
+
factory(global.moment)
|
|
8
|
+
}(this, (function (moment) { 'use strict';
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
function processRelativeTime(number, withoutSuffix, key, isFuture) {
|
|
12
|
+
var result = number + ' ';
|
|
13
|
+
switch (key) {
|
|
14
|
+
case 's':
|
|
15
|
+
return withoutSuffix || isFuture ? 'nekaj sekund' : 'nekaj sekundami';
|
|
16
|
+
case 'ss':
|
|
17
|
+
if (number === 1) {
|
|
18
|
+
result += withoutSuffix ? 'sekundo' : 'sekundi';
|
|
19
|
+
} else if (number === 2) {
|
|
20
|
+
result += withoutSuffix || isFuture ? 'sekundi' : 'sekundah';
|
|
21
|
+
} else if (number < 5) {
|
|
22
|
+
result += withoutSuffix || isFuture ? 'sekunde' : 'sekundah';
|
|
23
|
+
} else {
|
|
24
|
+
result += 'sekund';
|
|
25
|
+
}
|
|
26
|
+
return result;
|
|
27
|
+
case 'm':
|
|
28
|
+
return withoutSuffix ? 'ena minuta' : 'eno minuto';
|
|
29
|
+
case 'mm':
|
|
30
|
+
if (number === 1) {
|
|
31
|
+
result += withoutSuffix ? 'minuta' : 'minuto';
|
|
32
|
+
} else if (number === 2) {
|
|
33
|
+
result += withoutSuffix || isFuture ? 'minuti' : 'minutama';
|
|
34
|
+
} else if (number < 5) {
|
|
35
|
+
result += withoutSuffix || isFuture ? 'minute' : 'minutami';
|
|
36
|
+
} else {
|
|
37
|
+
result += withoutSuffix || isFuture ? 'minut' : 'minutami';
|
|
38
|
+
}
|
|
39
|
+
return result;
|
|
40
|
+
case 'h':
|
|
41
|
+
return withoutSuffix ? 'ena ura' : 'eno uro';
|
|
42
|
+
case 'hh':
|
|
43
|
+
if (number === 1) {
|
|
44
|
+
result += withoutSuffix ? 'ura' : 'uro';
|
|
45
|
+
} else if (number === 2) {
|
|
46
|
+
result += withoutSuffix || isFuture ? 'uri' : 'urama';
|
|
47
|
+
} else if (number < 5) {
|
|
48
|
+
result += withoutSuffix || isFuture ? 'ure' : 'urami';
|
|
49
|
+
} else {
|
|
50
|
+
result += withoutSuffix || isFuture ? 'ur' : 'urami';
|
|
51
|
+
}
|
|
52
|
+
return result;
|
|
53
|
+
case 'd':
|
|
54
|
+
return withoutSuffix || isFuture ? 'en dan' : 'enim dnem';
|
|
55
|
+
case 'dd':
|
|
56
|
+
if (number === 1) {
|
|
57
|
+
result += withoutSuffix || isFuture ? 'dan' : 'dnem';
|
|
58
|
+
} else if (number === 2) {
|
|
59
|
+
result += withoutSuffix || isFuture ? 'dni' : 'dnevoma';
|
|
60
|
+
} else {
|
|
61
|
+
result += withoutSuffix || isFuture ? 'dni' : 'dnevi';
|
|
62
|
+
}
|
|
63
|
+
return result;
|
|
64
|
+
case 'M':
|
|
65
|
+
return withoutSuffix || isFuture ? 'en mesec' : 'enim mesecem';
|
|
66
|
+
case 'MM':
|
|
67
|
+
if (number === 1) {
|
|
68
|
+
result += withoutSuffix || isFuture ? 'mesec' : 'mesecem';
|
|
69
|
+
} else if (number === 2) {
|
|
70
|
+
result += withoutSuffix || isFuture ? 'meseca' : 'mesecema';
|
|
71
|
+
} else if (number < 5) {
|
|
72
|
+
result += withoutSuffix || isFuture ? 'mesece' : 'meseci';
|
|
73
|
+
} else {
|
|
74
|
+
result += withoutSuffix || isFuture ? 'mesecev' : 'meseci';
|
|
75
|
+
}
|
|
76
|
+
return result;
|
|
77
|
+
case 'y':
|
|
78
|
+
return withoutSuffix || isFuture ? 'eno leto' : 'enim letom';
|
|
79
|
+
case 'yy':
|
|
80
|
+
if (number === 1) {
|
|
81
|
+
result += withoutSuffix || isFuture ? 'leto' : 'letom';
|
|
82
|
+
} else if (number === 2) {
|
|
83
|
+
result += withoutSuffix || isFuture ? 'leti' : 'letoma';
|
|
84
|
+
} else if (number < 5) {
|
|
85
|
+
result += withoutSuffix || isFuture ? 'leta' : 'leti';
|
|
86
|
+
} else {
|
|
87
|
+
result += withoutSuffix || isFuture ? 'let' : 'leti';
|
|
88
|
+
}
|
|
89
|
+
return result;
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
var sl = moment.defineLocale('sl', {
|
|
94
|
+
months : 'januar_februar_marec_april_maj_junij_julij_avgust_september_oktober_november_december'.split('_'),
|
|
95
|
+
monthsShort : 'jan._feb._mar._apr._maj._jun._jul._avg._sep._okt._nov._dec.'.split('_'),
|
|
96
|
+
monthsParseExact: true,
|
|
97
|
+
weekdays : 'nedelja_ponedeljek_torek_sreda_četrtek_petek_sobota'.split('_'),
|
|
98
|
+
weekdaysShort : 'ned._pon._tor._sre._čet._pet._sob.'.split('_'),
|
|
99
|
+
weekdaysMin : 'ne_po_to_sr_če_pe_so'.split('_'),
|
|
100
|
+
weekdaysParseExact : true,
|
|
101
|
+
longDateFormat : {
|
|
102
|
+
LT : 'H:mm',
|
|
103
|
+
LTS : 'H:mm:ss',
|
|
104
|
+
L : 'DD.MM.YYYY',
|
|
105
|
+
LL : 'D. MMMM YYYY',
|
|
106
|
+
LLL : 'D. MMMM YYYY H:mm',
|
|
107
|
+
LLLL : 'dddd, D. MMMM YYYY H:mm'
|
|
108
|
+
},
|
|
109
|
+
calendar : {
|
|
110
|
+
sameDay : '[danes ob] LT',
|
|
111
|
+
nextDay : '[jutri ob] LT',
|
|
112
|
+
|
|
113
|
+
nextWeek : function () {
|
|
114
|
+
switch (this.day()) {
|
|
115
|
+
case 0:
|
|
116
|
+
return '[v] [nedeljo] [ob] LT';
|
|
117
|
+
case 3:
|
|
118
|
+
return '[v] [sredo] [ob] LT';
|
|
119
|
+
case 6:
|
|
120
|
+
return '[v] [soboto] [ob] LT';
|
|
121
|
+
case 1:
|
|
122
|
+
case 2:
|
|
123
|
+
case 4:
|
|
124
|
+
case 5:
|
|
125
|
+
return '[v] dddd [ob] LT';
|
|
126
|
+
}
|
|
127
|
+
},
|
|
128
|
+
lastDay : '[včeraj ob] LT',
|
|
129
|
+
lastWeek : function () {
|
|
130
|
+
switch (this.day()) {
|
|
131
|
+
case 0:
|
|
132
|
+
return '[prejšnjo] [nedeljo] [ob] LT';
|
|
133
|
+
case 3:
|
|
134
|
+
return '[prejšnjo] [sredo] [ob] LT';
|
|
135
|
+
case 6:
|
|
136
|
+
return '[prejšnjo] [soboto] [ob] LT';
|
|
137
|
+
case 1:
|
|
138
|
+
case 2:
|
|
139
|
+
case 4:
|
|
140
|
+
case 5:
|
|
141
|
+
return '[prejšnji] dddd [ob] LT';
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
sameElse : 'L'
|
|
145
|
+
},
|
|
146
|
+
relativeTime : {
|
|
147
|
+
future : 'čez %s',
|
|
148
|
+
past : 'pred %s',
|
|
149
|
+
s : processRelativeTime,
|
|
150
|
+
ss : processRelativeTime,
|
|
151
|
+
m : processRelativeTime,
|
|
152
|
+
mm : processRelativeTime,
|
|
153
|
+
h : processRelativeTime,
|
|
154
|
+
hh : processRelativeTime,
|
|
155
|
+
d : processRelativeTime,
|
|
156
|
+
dd : processRelativeTime,
|
|
157
|
+
M : processRelativeTime,
|
|
158
|
+
MM : processRelativeTime,
|
|
159
|
+
y : processRelativeTime,
|
|
160
|
+
yy : processRelativeTime
|
|
161
|
+
},
|
|
162
|
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
|
163
|
+
ordinal : '%d.',
|
|
164
|
+
week : {
|
|
165
|
+
dow : 1, // Monday is the first day of the week.
|
|
166
|
+
doy : 7 // The week that contains Jan 7th is the first week of the year.
|
|
167
|
+
}
|
|
168
|
+
});
|
|
169
|
+
|
|
170
|
+
return sl;
|
|
171
|
+
|
|
172
|
+
})));
|
|
@@ -0,0 +1,67 @@
|
|
|
1
|
+
//! moment.js locale configuration
|
|
2
|
+
|
|
3
|
+
;(function (global, factory) {
|
|
4
|
+
typeof exports === 'object' && typeof module !== 'undefined'
|
|
5
|
+
&& typeof require === 'function' ? factory(require('../moment')) :
|
|
6
|
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
|
7
|
+
factory(global.moment)
|
|
8
|
+
}(this, (function (moment) { 'use strict';
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
var sq = moment.defineLocale('sq', {
|
|
12
|
+
months : 'Janar_Shkurt_Mars_Prill_Maj_Qershor_Korrik_Gusht_Shtator_Tetor_Nëntor_Dhjetor'.split('_'),
|
|
13
|
+
monthsShort : 'Jan_Shk_Mar_Pri_Maj_Qer_Kor_Gus_Sht_Tet_Nën_Dhj'.split('_'),
|
|
14
|
+
weekdays : 'E Diel_E Hënë_E Martë_E Mërkurë_E Enjte_E Premte_E Shtunë'.split('_'),
|
|
15
|
+
weekdaysShort : 'Die_Hën_Mar_Mër_Enj_Pre_Sht'.split('_'),
|
|
16
|
+
weekdaysMin : 'D_H_Ma_Më_E_P_Sh'.split('_'),
|
|
17
|
+
weekdaysParseExact : true,
|
|
18
|
+
meridiemParse: /PD|MD/,
|
|
19
|
+
isPM: function (input) {
|
|
20
|
+
return input.charAt(0) === 'M';
|
|
21
|
+
},
|
|
22
|
+
meridiem : function (hours, minutes, isLower) {
|
|
23
|
+
return hours < 12 ? 'PD' : 'MD';
|
|
24
|
+
},
|
|
25
|
+
longDateFormat : {
|
|
26
|
+
LT : 'HH:mm',
|
|
27
|
+
LTS : 'HH:mm:ss',
|
|
28
|
+
L : 'DD/MM/YYYY',
|
|
29
|
+
LL : 'D MMMM YYYY',
|
|
30
|
+
LLL : 'D MMMM YYYY HH:mm',
|
|
31
|
+
LLLL : 'dddd, D MMMM YYYY HH:mm'
|
|
32
|
+
},
|
|
33
|
+
calendar : {
|
|
34
|
+
sameDay : '[Sot në] LT',
|
|
35
|
+
nextDay : '[Nesër në] LT',
|
|
36
|
+
nextWeek : 'dddd [në] LT',
|
|
37
|
+
lastDay : '[Dje në] LT',
|
|
38
|
+
lastWeek : 'dddd [e kaluar në] LT',
|
|
39
|
+
sameElse : 'L'
|
|
40
|
+
},
|
|
41
|
+
relativeTime : {
|
|
42
|
+
future : 'në %s',
|
|
43
|
+
past : '%s më parë',
|
|
44
|
+
s : 'disa sekonda',
|
|
45
|
+
ss : '%d sekonda',
|
|
46
|
+
m : 'një minutë',
|
|
47
|
+
mm : '%d minuta',
|
|
48
|
+
h : 'një orë',
|
|
49
|
+
hh : '%d orë',
|
|
50
|
+
d : 'një ditë',
|
|
51
|
+
dd : '%d ditë',
|
|
52
|
+
M : 'një muaj',
|
|
53
|
+
MM : '%d muaj',
|
|
54
|
+
y : 'një vit',
|
|
55
|
+
yy : '%d vite'
|
|
56
|
+
},
|
|
57
|
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
|
58
|
+
ordinal : '%d.',
|
|
59
|
+
week : {
|
|
60
|
+
dow : 1, // Monday is the first day of the week.
|
|
61
|
+
doy : 4 // The week that contains Jan 4th is the first week of the year.
|
|
62
|
+
}
|
|
63
|
+
});
|
|
64
|
+
|
|
65
|
+
return sq;
|
|
66
|
+
|
|
67
|
+
})));
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
//! moment.js locale configuration
|
|
2
|
+
|
|
3
|
+
;(function (global, factory) {
|
|
4
|
+
typeof exports === 'object' && typeof module !== 'undefined'
|
|
5
|
+
&& typeof require === 'function' ? factory(require('../moment')) :
|
|
6
|
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
|
7
|
+
factory(global.moment)
|
|
8
|
+
}(this, (function (moment) { 'use strict';
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
var translator = {
|
|
12
|
+
words: { //Different grammatical cases
|
|
13
|
+
ss: ['секунда', 'секунде', 'секунди'],
|
|
14
|
+
m: ['један минут', 'једне минуте'],
|
|
15
|
+
mm: ['минут', 'минуте', 'минута'],
|
|
16
|
+
h: ['један сат', 'једног сата'],
|
|
17
|
+
hh: ['сат', 'сата', 'сати'],
|
|
18
|
+
dd: ['дан', 'дана', 'дана'],
|
|
19
|
+
MM: ['месец', 'месеца', 'месеци'],
|
|
20
|
+
yy: ['година', 'године', 'година']
|
|
21
|
+
},
|
|
22
|
+
correctGrammaticalCase: function (number, wordKey) {
|
|
23
|
+
return number === 1 ? wordKey[0] : (number >= 2 && number <= 4 ? wordKey[1] : wordKey[2]);
|
|
24
|
+
},
|
|
25
|
+
translate: function (number, withoutSuffix, key) {
|
|
26
|
+
var wordKey = translator.words[key];
|
|
27
|
+
if (key.length === 1) {
|
|
28
|
+
return withoutSuffix ? wordKey[0] : wordKey[1];
|
|
29
|
+
} else {
|
|
30
|
+
return number + ' ' + translator.correctGrammaticalCase(number, wordKey);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
var srCyrl = moment.defineLocale('sr-cyrl', {
|
|
36
|
+
months: 'јануар_фебруар_март_април_мај_јун_јул_август_септембар_октобар_новембар_децембар'.split('_'),
|
|
37
|
+
monthsShort: 'јан._феб._мар._апр._мај_јун_јул_авг._сеп._окт._нов._дец.'.split('_'),
|
|
38
|
+
monthsParseExact: true,
|
|
39
|
+
weekdays: 'недеља_понедељак_уторак_среда_четвртак_петак_субота'.split('_'),
|
|
40
|
+
weekdaysShort: 'нед._пон._уто._сре._чет._пет._суб.'.split('_'),
|
|
41
|
+
weekdaysMin: 'не_по_ут_ср_че_пе_су'.split('_'),
|
|
42
|
+
weekdaysParseExact : true,
|
|
43
|
+
longDateFormat: {
|
|
44
|
+
LT: 'H:mm',
|
|
45
|
+
LTS : 'H:mm:ss',
|
|
46
|
+
L: 'DD.MM.YYYY',
|
|
47
|
+
LL: 'D. MMMM YYYY',
|
|
48
|
+
LLL: 'D. MMMM YYYY H:mm',
|
|
49
|
+
LLLL: 'dddd, D. MMMM YYYY H:mm'
|
|
50
|
+
},
|
|
51
|
+
calendar: {
|
|
52
|
+
sameDay: '[данас у] LT',
|
|
53
|
+
nextDay: '[сутра у] LT',
|
|
54
|
+
nextWeek: function () {
|
|
55
|
+
switch (this.day()) {
|
|
56
|
+
case 0:
|
|
57
|
+
return '[у] [недељу] [у] LT';
|
|
58
|
+
case 3:
|
|
59
|
+
return '[у] [среду] [у] LT';
|
|
60
|
+
case 6:
|
|
61
|
+
return '[у] [суботу] [у] LT';
|
|
62
|
+
case 1:
|
|
63
|
+
case 2:
|
|
64
|
+
case 4:
|
|
65
|
+
case 5:
|
|
66
|
+
return '[у] dddd [у] LT';
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
lastDay : '[јуче у] LT',
|
|
70
|
+
lastWeek : function () {
|
|
71
|
+
var lastWeekDays = [
|
|
72
|
+
'[прошле] [недеље] [у] LT',
|
|
73
|
+
'[прошлог] [понедељка] [у] LT',
|
|
74
|
+
'[прошлог] [уторка] [у] LT',
|
|
75
|
+
'[прошле] [среде] [у] LT',
|
|
76
|
+
'[прошлог] [четвртка] [у] LT',
|
|
77
|
+
'[прошлог] [петка] [у] LT',
|
|
78
|
+
'[прошле] [суботе] [у] LT'
|
|
79
|
+
];
|
|
80
|
+
return lastWeekDays[this.day()];
|
|
81
|
+
},
|
|
82
|
+
sameElse : 'L'
|
|
83
|
+
},
|
|
84
|
+
relativeTime : {
|
|
85
|
+
future : 'за %s',
|
|
86
|
+
past : 'пре %s',
|
|
87
|
+
s : 'неколико секунди',
|
|
88
|
+
ss : translator.translate,
|
|
89
|
+
m : translator.translate,
|
|
90
|
+
mm : translator.translate,
|
|
91
|
+
h : translator.translate,
|
|
92
|
+
hh : translator.translate,
|
|
93
|
+
d : 'дан',
|
|
94
|
+
dd : translator.translate,
|
|
95
|
+
M : 'месец',
|
|
96
|
+
MM : translator.translate,
|
|
97
|
+
y : 'годину',
|
|
98
|
+
yy : translator.translate
|
|
99
|
+
},
|
|
100
|
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
|
101
|
+
ordinal : '%d.',
|
|
102
|
+
week : {
|
|
103
|
+
dow : 1, // Monday is the first day of the week.
|
|
104
|
+
doy : 7 // The week that contains Jan 7th is the first week of the year.
|
|
105
|
+
}
|
|
106
|
+
});
|
|
107
|
+
|
|
108
|
+
return srCyrl;
|
|
109
|
+
|
|
110
|
+
})));
|
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
//! moment.js locale configuration
|
|
2
|
+
|
|
3
|
+
;(function (global, factory) {
|
|
4
|
+
typeof exports === 'object' && typeof module !== 'undefined'
|
|
5
|
+
&& typeof require === 'function' ? factory(require('../moment')) :
|
|
6
|
+
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
|
7
|
+
factory(global.moment)
|
|
8
|
+
}(this, (function (moment) { 'use strict';
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
var translator = {
|
|
12
|
+
words: { //Different grammatical cases
|
|
13
|
+
ss: ['sekunda', 'sekunde', 'sekundi'],
|
|
14
|
+
m: ['jedan minut', 'jedne minute'],
|
|
15
|
+
mm: ['minut', 'minute', 'minuta'],
|
|
16
|
+
h: ['jedan sat', 'jednog sata'],
|
|
17
|
+
hh: ['sat', 'sata', 'sati'],
|
|
18
|
+
dd: ['dan', 'dana', 'dana'],
|
|
19
|
+
MM: ['mesec', 'meseca', 'meseci'],
|
|
20
|
+
yy: ['godina', 'godine', 'godina']
|
|
21
|
+
},
|
|
22
|
+
correctGrammaticalCase: function (number, wordKey) {
|
|
23
|
+
return number === 1 ? wordKey[0] : (number >= 2 && number <= 4 ? wordKey[1] : wordKey[2]);
|
|
24
|
+
},
|
|
25
|
+
translate: function (number, withoutSuffix, key) {
|
|
26
|
+
var wordKey = translator.words[key];
|
|
27
|
+
if (key.length === 1) {
|
|
28
|
+
return withoutSuffix ? wordKey[0] : wordKey[1];
|
|
29
|
+
} else {
|
|
30
|
+
return number + ' ' + translator.correctGrammaticalCase(number, wordKey);
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
};
|
|
34
|
+
|
|
35
|
+
var sr = moment.defineLocale('sr', {
|
|
36
|
+
months: 'januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar'.split('_'),
|
|
37
|
+
monthsShort: 'jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.'.split('_'),
|
|
38
|
+
monthsParseExact: true,
|
|
39
|
+
weekdays: 'nedelja_ponedeljak_utorak_sreda_četvrtak_petak_subota'.split('_'),
|
|
40
|
+
weekdaysShort: 'ned._pon._uto._sre._čet._pet._sub.'.split('_'),
|
|
41
|
+
weekdaysMin: 'ne_po_ut_sr_če_pe_su'.split('_'),
|
|
42
|
+
weekdaysParseExact : true,
|
|
43
|
+
longDateFormat: {
|
|
44
|
+
LT: 'H:mm',
|
|
45
|
+
LTS : 'H:mm:ss',
|
|
46
|
+
L: 'DD.MM.YYYY',
|
|
47
|
+
LL: 'D. MMMM YYYY',
|
|
48
|
+
LLL: 'D. MMMM YYYY H:mm',
|
|
49
|
+
LLLL: 'dddd, D. MMMM YYYY H:mm'
|
|
50
|
+
},
|
|
51
|
+
calendar: {
|
|
52
|
+
sameDay: '[danas u] LT',
|
|
53
|
+
nextDay: '[sutra u] LT',
|
|
54
|
+
nextWeek: function () {
|
|
55
|
+
switch (this.day()) {
|
|
56
|
+
case 0:
|
|
57
|
+
return '[u] [nedelju] [u] LT';
|
|
58
|
+
case 3:
|
|
59
|
+
return '[u] [sredu] [u] LT';
|
|
60
|
+
case 6:
|
|
61
|
+
return '[u] [subotu] [u] LT';
|
|
62
|
+
case 1:
|
|
63
|
+
case 2:
|
|
64
|
+
case 4:
|
|
65
|
+
case 5:
|
|
66
|
+
return '[u] dddd [u] LT';
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
lastDay : '[juče u] LT',
|
|
70
|
+
lastWeek : function () {
|
|
71
|
+
var lastWeekDays = [
|
|
72
|
+
'[prošle] [nedelje] [u] LT',
|
|
73
|
+
'[prošlog] [ponedeljka] [u] LT',
|
|
74
|
+
'[prošlog] [utorka] [u] LT',
|
|
75
|
+
'[prošle] [srede] [u] LT',
|
|
76
|
+
'[prošlog] [četvrtka] [u] LT',
|
|
77
|
+
'[prošlog] [petka] [u] LT',
|
|
78
|
+
'[prošle] [subote] [u] LT'
|
|
79
|
+
];
|
|
80
|
+
return lastWeekDays[this.day()];
|
|
81
|
+
},
|
|
82
|
+
sameElse : 'L'
|
|
83
|
+
},
|
|
84
|
+
relativeTime : {
|
|
85
|
+
future : 'za %s',
|
|
86
|
+
past : 'pre %s',
|
|
87
|
+
s : 'nekoliko sekundi',
|
|
88
|
+
ss : translator.translate,
|
|
89
|
+
m : translator.translate,
|
|
90
|
+
mm : translator.translate,
|
|
91
|
+
h : translator.translate,
|
|
92
|
+
hh : translator.translate,
|
|
93
|
+
d : 'dan',
|
|
94
|
+
dd : translator.translate,
|
|
95
|
+
M : 'mesec',
|
|
96
|
+
MM : translator.translate,
|
|
97
|
+
y : 'godinu',
|
|
98
|
+
yy : translator.translate
|
|
99
|
+
},
|
|
100
|
+
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
|
101
|
+
ordinal : '%d.',
|
|
102
|
+
week : {
|
|
103
|
+
dow : 1, // Monday is the first day of the week.
|
|
104
|
+
doy : 7 // The week that contains Jan 7th is the first week of the year.
|
|
105
|
+
}
|
|
106
|
+
});
|
|
107
|
+
|
|
108
|
+
return sr;
|
|
109
|
+
|
|
110
|
+
})));
|