1 // moment.js locale configuration
2 // locale : Lithuanian (lt)
3 // author : Mindaugas Mozūras : https://github.com/mmozuras
6 // Comment out broken wrapper, see T145382
7 /*if (typeof define === 'function' && define.amd) {
8 define(['moment'], factory); // AMD
9 } else if (typeof exports === 'object') {
10 module.exports = factory(require('../moment')); // Node
12 factory((typeof global !== 'undefined' ? global : this).moment); // node or other global
17 'm' : 'minutė_minutės_minutę',
18 'mm': 'minutės_minučių_minutes',
19 'h' : 'valanda_valandos_valandą',
20 'hh': 'valandos_valandų_valandas',
21 'd' : 'diena_dienos_dieną',
22 'dd': 'dienos_dienų_dienas',
23 'M' : 'mėnuo_mėnesio_mėnesį',
24 'MM': 'mėnesiai_mėnesių_mėnesius',
25 'y' : 'metai_metų_metus',
26 'yy': 'metai_metų_metus'
28 weekDays = 'sekmadienis_pirmadienis_antradienis_trečiadienis_ketvirtadienis_penktadienis_šeštadienis'.split('_');
30 function translateSeconds(number, withoutSuffix, key, isFuture) {
32 return 'kelios sekundės';
34 return isFuture ? 'kelių sekundžių' : 'kelias sekundes';
38 function translateSingular(number, withoutSuffix, key, isFuture) {
39 return withoutSuffix ? forms(key)[0] : (isFuture ? forms(key)[1] : forms(key)[2]);
42 function special(number) {
43 return number % 10 === 0 || (number > 10 && number < 20);
47 return units[key].split('_');
50 function translate(number, withoutSuffix, key, isFuture) {
51 var result = number + ' ';
53 return result + translateSingular(number, withoutSuffix, key[0], isFuture);
54 } else if (withoutSuffix) {
55 return result + (special(number) ? forms(key)[1] : forms(key)[0]);
58 return result + forms(key)[1];
60 return result + (special(number) ? forms(key)[1] : forms(key)[2]);
65 function relativeWeekDay(moment, format) {
66 var nominative = format.indexOf('dddd HH:mm') === -1,
67 weekDay = weekDays[moment.day()];
69 return nominative ? weekDay : weekDay.substring(0, weekDay.length - 2) + 'į';
72 return moment.defineLocale('lt', {
73 months : 'sausio_vasario_kovo_balandžio_gegužės_birželio_liepos_rugpjūčio_rugsėjo_spalio_lapkričio_gruodžio'.split('_'),
74 monthsShort : 'sau_vas_kov_bal_geg_bir_lie_rgp_rgs_spa_lap_grd'.split('_'),
75 weekdays : relativeWeekDay,
76 weekdaysShort : 'Sek_Pir_Ant_Tre_Ket_Pen_Šeš'.split('_'),
77 weekdaysMin : 'S_P_A_T_K_Pn_Š'.split('_'),
82 LL : 'YYYY [m.] MMMM D [d.]',
83 LLL : 'YYYY [m.] MMMM D [d.], LT [val.]',
84 LLLL : 'YYYY [m.] MMMM D [d.], dddd, LT [val.]',
86 ll : 'YYYY [m.] MMMM D [d.]',
87 lll : 'YYYY [m.] MMMM D [d.], LT [val.]',
88 llll : 'YYYY [m.] MMMM D [d.], ddd, LT [val.]'
91 sameDay : '[Šiandien] LT',
92 nextDay : '[Rytoj] LT',
94 lastDay : '[Vakar] LT',
95 lastWeek : '[Praėjusį] dddd LT',
101 s : translateSeconds,
102 m : translateSingular,
104 h : translateSingular,
106 d : translateSingular,
108 M : translateSingular,
110 y : translateSingular,
113 ordinalParse: /\d{1,2}-oji/,
114 ordinal : function (number) {
115 return number + '-oji';
118 dow : 1, // Monday is the first day of the week.
119 doy : 4 // The week that contains Jan 4th is the first week of the year.