mirror of
https://github.com/discourse/discourse.git
synced 2024-12-19 06:05:57 +08:00
cdb7ddc258
We updated version of moment and moment-timezone as our current versions are outdated making Discourse Dates broken on places where timezone had updates, like here in Brazil. This also update highlightJS to the latest version and corrected a test that relied on a no longer supported locale in moment.
83 lines
2.7 KiB
JavaScript
83 lines
2.7 KiB
JavaScript
//! moment.js locale configuration
|
|
//! locale : Afrikaans [af]
|
|
//! author : Werner Mollentze : https://github.com/wernerm
|
|
|
|
;(function (global, factory) {
|
|
typeof exports === 'object' && typeof module !== 'undefined'
|
|
&& typeof require === 'function' ? factory(require('../moment')) :
|
|
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
|
factory(global.moment)
|
|
}(this, (function (moment) { 'use strict';
|
|
|
|
//! moment.js locale configuration
|
|
|
|
var af = moment.defineLocale('af', {
|
|
months: 'Januarie_Februarie_Maart_April_Mei_Junie_Julie_Augustus_September_Oktober_November_Desember'.split(
|
|
'_'
|
|
),
|
|
monthsShort: 'Jan_Feb_Mrt_Apr_Mei_Jun_Jul_Aug_Sep_Okt_Nov_Des'.split('_'),
|
|
weekdays: 'Sondag_Maandag_Dinsdag_Woensdag_Donderdag_Vrydag_Saterdag'.split(
|
|
'_'
|
|
),
|
|
weekdaysShort: 'Son_Maa_Din_Woe_Don_Vry_Sat'.split('_'),
|
|
weekdaysMin: 'So_Ma_Di_Wo_Do_Vr_Sa'.split('_'),
|
|
meridiemParse: /vm|nm/i,
|
|
isPM: function (input) {
|
|
return /^nm$/i.test(input);
|
|
},
|
|
meridiem: function (hours, minutes, isLower) {
|
|
if (hours < 12) {
|
|
return isLower ? 'vm' : 'VM';
|
|
} else {
|
|
return isLower ? 'nm' : 'NM';
|
|
}
|
|
},
|
|
longDateFormat: {
|
|
LT: 'HH:mm',
|
|
LTS: 'HH:mm:ss',
|
|
L: 'DD/MM/YYYY',
|
|
LL: 'D MMMM YYYY',
|
|
LLL: 'D MMMM YYYY HH:mm',
|
|
LLLL: 'dddd, D MMMM YYYY HH:mm',
|
|
},
|
|
calendar: {
|
|
sameDay: '[Vandag om] LT',
|
|
nextDay: '[Môre om] LT',
|
|
nextWeek: 'dddd [om] LT',
|
|
lastDay: '[Gister om] LT',
|
|
lastWeek: '[Laas] dddd [om] LT',
|
|
sameElse: 'L',
|
|
},
|
|
relativeTime: {
|
|
future: 'oor %s',
|
|
past: '%s gelede',
|
|
s: "'n paar sekondes",
|
|
ss: '%d sekondes',
|
|
m: "'n minuut",
|
|
mm: '%d minute',
|
|
h: "'n uur",
|
|
hh: '%d ure',
|
|
d: "'n dag",
|
|
dd: '%d dae',
|
|
M: "'n maand",
|
|
MM: '%d maande',
|
|
y: "'n jaar",
|
|
yy: '%d jaar',
|
|
},
|
|
dayOfMonthOrdinalParse: /\d{1,2}(ste|de)/,
|
|
ordinal: function (number) {
|
|
return (
|
|
number +
|
|
(number === 1 || number === 8 || number >= 20 ? 'ste' : 'de')
|
|
); // Thanks to Joris Röling : https://github.com/jjupiter
|
|
},
|
|
week: {
|
|
dow: 1, // Maandag is die eerste dag van die week.
|
|
doy: 4, // Die week wat die 4de Januarie bevat is die eerste week van die jaar.
|
|
},
|
|
});
|
|
|
|
return af;
|
|
|
|
})));
|