Bumped AdminLTE and its libraries from 3.0.4 to 3.1 This broke Calendar support will fix
This commit is contained in:
+57
-38
@@ -1,4 +1,7 @@
|
||||
//! moment.js locale configuration
|
||||
//! locale : Serbian [sr]
|
||||
//! author : Milan Janačković<milanjanackovic@gmail.com> : https://github.com/milan-j
|
||||
//! author : Stefan Crnjaković <stefan@hotmail.rs> : https://github.com/crnjakovic
|
||||
|
||||
;(function (global, factory) {
|
||||
typeof exports === 'object' && typeof module !== 'undefined'
|
||||
@@ -7,9 +10,11 @@
|
||||
factory(global.moment)
|
||||
}(this, (function (moment) { 'use strict';
|
||||
|
||||
//! moment.js locale configuration
|
||||
|
||||
var translator = {
|
||||
words: { //Different grammatical cases
|
||||
words: {
|
||||
//Different grammatical cases
|
||||
ss: ['sekunda', 'sekunde', 'sekundi'],
|
||||
m: ['jedan minut', 'jedne minute'],
|
||||
mm: ['minut', 'minute', 'minuta'],
|
||||
@@ -17,36 +22,50 @@
|
||||
hh: ['sat', 'sata', 'sati'],
|
||||
dd: ['dan', 'dana', 'dana'],
|
||||
MM: ['mesec', 'meseca', 'meseci'],
|
||||
yy: ['godina', 'godine', 'godina']
|
||||
yy: ['godina', 'godine', 'godina'],
|
||||
},
|
||||
correctGrammaticalCase: function (number, wordKey) {
|
||||
return number === 1 ? wordKey[0] : (number >= 2 && number <= 4 ? wordKey[1] : wordKey[2]);
|
||||
return number === 1
|
||||
? wordKey[0]
|
||||
: number >= 2 && number <= 4
|
||||
? wordKey[1]
|
||||
: wordKey[2];
|
||||
},
|
||||
translate: function (number, withoutSuffix, key) {
|
||||
var wordKey = translator.words[key];
|
||||
if (key.length === 1) {
|
||||
return withoutSuffix ? wordKey[0] : wordKey[1];
|
||||
} else {
|
||||
return number + ' ' + translator.correctGrammaticalCase(number, wordKey);
|
||||
return (
|
||||
number +
|
||||
' ' +
|
||||
translator.correctGrammaticalCase(number, wordKey)
|
||||
);
|
||||
}
|
||||
}
|
||||
},
|
||||
};
|
||||
|
||||
var sr = moment.defineLocale('sr', {
|
||||
months: 'januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar'.split('_'),
|
||||
monthsShort: 'jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.'.split('_'),
|
||||
months: 'januar_februar_mart_april_maj_jun_jul_avgust_septembar_oktobar_novembar_decembar'.split(
|
||||
'_'
|
||||
),
|
||||
monthsShort: 'jan._feb._mar._apr._maj_jun_jul_avg._sep._okt._nov._dec.'.split(
|
||||
'_'
|
||||
),
|
||||
monthsParseExact: true,
|
||||
weekdays: 'nedelja_ponedeljak_utorak_sreda_četvrtak_petak_subota'.split('_'),
|
||||
weekdays: 'nedelja_ponedeljak_utorak_sreda_četvrtak_petak_subota'.split(
|
||||
'_'
|
||||
),
|
||||
weekdaysShort: 'ned._pon._uto._sre._čet._pet._sub.'.split('_'),
|
||||
weekdaysMin: 'ne_po_ut_sr_če_pe_su'.split('_'),
|
||||
weekdaysParseExact : true,
|
||||
weekdaysParseExact: true,
|
||||
longDateFormat: {
|
||||
LT: 'H:mm',
|
||||
LTS : 'H:mm:ss',
|
||||
L: 'DD.MM.YYYY',
|
||||
LL: 'D. MMMM YYYY',
|
||||
LLL: 'D. MMMM YYYY H:mm',
|
||||
LLLL: 'dddd, D. MMMM YYYY H:mm'
|
||||
LTS: 'H:mm:ss',
|
||||
L: 'D. M. YYYY.',
|
||||
LL: 'D. MMMM YYYY.',
|
||||
LLL: 'D. MMMM YYYY. H:mm',
|
||||
LLLL: 'dddd, D. MMMM YYYY. H:mm',
|
||||
},
|
||||
calendar: {
|
||||
sameDay: '[danas u] LT',
|
||||
@@ -66,8 +85,8 @@
|
||||
return '[u] dddd [u] LT';
|
||||
}
|
||||
},
|
||||
lastDay : '[juče u] LT',
|
||||
lastWeek : function () {
|
||||
lastDay: '[juče u] LT',
|
||||
lastWeek: function () {
|
||||
var lastWeekDays = [
|
||||
'[prošle] [nedelje] [u] LT',
|
||||
'[prošlog] [ponedeljka] [u] LT',
|
||||
@@ -75,34 +94,34 @@
|
||||
'[prošle] [srede] [u] LT',
|
||||
'[prošlog] [četvrtka] [u] LT',
|
||||
'[prošlog] [petka] [u] LT',
|
||||
'[prošle] [subote] [u] LT'
|
||||
'[prošle] [subote] [u] LT',
|
||||
];
|
||||
return lastWeekDays[this.day()];
|
||||
},
|
||||
sameElse : 'L'
|
||||
sameElse: 'L',
|
||||
},
|
||||
relativeTime : {
|
||||
future : 'za %s',
|
||||
past : 'pre %s',
|
||||
s : 'nekoliko sekundi',
|
||||
ss : translator.translate,
|
||||
m : translator.translate,
|
||||
mm : translator.translate,
|
||||
h : translator.translate,
|
||||
hh : translator.translate,
|
||||
d : 'dan',
|
||||
dd : translator.translate,
|
||||
M : 'mesec',
|
||||
MM : translator.translate,
|
||||
y : 'godinu',
|
||||
yy : translator.translate
|
||||
relativeTime: {
|
||||
future: 'za %s',
|
||||
past: 'pre %s',
|
||||
s: 'nekoliko sekundi',
|
||||
ss: translator.translate,
|
||||
m: translator.translate,
|
||||
mm: translator.translate,
|
||||
h: translator.translate,
|
||||
hh: translator.translate,
|
||||
d: 'dan',
|
||||
dd: translator.translate,
|
||||
M: 'mesec',
|
||||
MM: translator.translate,
|
||||
y: 'godinu',
|
||||
yy: translator.translate,
|
||||
},
|
||||
dayOfMonthOrdinalParse: /\d{1,2}\./,
|
||||
ordinal : '%d.',
|
||||
week : {
|
||||
dow : 1, // Monday is the first day of the week.
|
||||
doy : 7 // The week that contains Jan 7th is the first week of the year.
|
||||
}
|
||||
ordinal: '%d.',
|
||||
week: {
|
||||
dow: 1, // Monday is the first day of the week.
|
||||
doy: 7, // The week that contains Jan 7th is the first week of the year.
|
||||
},
|
||||
});
|
||||
|
||||
return sr;
|
||||
|
||||
Reference in New Issue
Block a user