2016-02-06 04:42:48 +08:00
|
|
|
|
//! moment.js locale configuration
|
2020-11-11 09:34:26 +08:00
|
|
|
|
//! locale : Marathi [mr]
|
|
|
|
|
//! author : Harshad Kale : https://github.com/kalehv
|
|
|
|
|
//! author : Vivek Athalye : https://github.com/vnathalye
|
2016-02-06 04:42:48 +08:00
|
|
|
|
|
|
|
|
|
;(function (global, factory) {
|
|
|
|
|
typeof exports === 'object' && typeof module !== 'undefined'
|
|
|
|
|
&& typeof require === 'function' ? factory(require('../moment')) :
|
2017-04-20 12:24:20 +08:00
|
|
|
|
typeof define === 'function' && define.amd ? define(['../moment'], factory) :
|
2016-02-06 04:42:48 +08:00
|
|
|
|
factory(global.moment)
|
2017-04-20 12:24:20 +08:00
|
|
|
|
}(this, (function (moment) { 'use strict';
|
2016-02-06 04:42:48 +08:00
|
|
|
|
|
2020-11-11 09:34:26 +08:00
|
|
|
|
//! moment.js locale configuration
|
2014-08-21 02:41:50 +08:00
|
|
|
|
|
2018-04-26 15:15:53 +08:00
|
|
|
|
var symbolMap = {
|
2020-11-11 09:34:26 +08:00
|
|
|
|
1: '१',
|
|
|
|
|
2: '२',
|
|
|
|
|
3: '३',
|
|
|
|
|
4: '४',
|
|
|
|
|
5: '५',
|
|
|
|
|
6: '६',
|
|
|
|
|
7: '७',
|
|
|
|
|
8: '८',
|
|
|
|
|
9: '९',
|
|
|
|
|
0: '०',
|
|
|
|
|
},
|
|
|
|
|
numberMap = {
|
|
|
|
|
'१': '1',
|
|
|
|
|
'२': '2',
|
|
|
|
|
'३': '3',
|
|
|
|
|
'४': '4',
|
|
|
|
|
'५': '5',
|
|
|
|
|
'६': '6',
|
|
|
|
|
'७': '7',
|
|
|
|
|
'८': '8',
|
|
|
|
|
'९': '9',
|
|
|
|
|
'०': '0',
|
|
|
|
|
};
|
2014-08-21 02:41:50 +08:00
|
|
|
|
|
2020-11-11 09:34:26 +08:00
|
|
|
|
function relativeTimeMr(number, withoutSuffix, string, isFuture) {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
var output = '';
|
|
|
|
|
if (withoutSuffix) {
|
|
|
|
|
switch (string) {
|
2020-11-11 09:34:26 +08:00
|
|
|
|
case 's':
|
|
|
|
|
output = 'काही सेकंद';
|
|
|
|
|
break;
|
|
|
|
|
case 'ss':
|
|
|
|
|
output = '%d सेकंद';
|
|
|
|
|
break;
|
|
|
|
|
case 'm':
|
|
|
|
|
output = 'एक मिनिट';
|
|
|
|
|
break;
|
|
|
|
|
case 'mm':
|
|
|
|
|
output = '%d मिनिटे';
|
|
|
|
|
break;
|
|
|
|
|
case 'h':
|
|
|
|
|
output = 'एक तास';
|
|
|
|
|
break;
|
|
|
|
|
case 'hh':
|
|
|
|
|
output = '%d तास';
|
|
|
|
|
break;
|
|
|
|
|
case 'd':
|
|
|
|
|
output = 'एक दिवस';
|
|
|
|
|
break;
|
|
|
|
|
case 'dd':
|
|
|
|
|
output = '%d दिवस';
|
|
|
|
|
break;
|
|
|
|
|
case 'M':
|
|
|
|
|
output = 'एक महिना';
|
|
|
|
|
break;
|
|
|
|
|
case 'MM':
|
|
|
|
|
output = '%d महिने';
|
|
|
|
|
break;
|
|
|
|
|
case 'y':
|
|
|
|
|
output = 'एक वर्ष';
|
|
|
|
|
break;
|
|
|
|
|
case 'yy':
|
|
|
|
|
output = '%d वर्षे';
|
|
|
|
|
break;
|
2018-04-26 15:15:53 +08:00
|
|
|
|
}
|
2020-11-11 09:34:26 +08:00
|
|
|
|
} else {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
switch (string) {
|
2020-11-11 09:34:26 +08:00
|
|
|
|
case 's':
|
|
|
|
|
output = 'काही सेकंदां';
|
|
|
|
|
break;
|
|
|
|
|
case 'ss':
|
|
|
|
|
output = '%d सेकंदां';
|
|
|
|
|
break;
|
|
|
|
|
case 'm':
|
|
|
|
|
output = 'एका मिनिटा';
|
|
|
|
|
break;
|
|
|
|
|
case 'mm':
|
|
|
|
|
output = '%d मिनिटां';
|
|
|
|
|
break;
|
|
|
|
|
case 'h':
|
|
|
|
|
output = 'एका तासा';
|
|
|
|
|
break;
|
|
|
|
|
case 'hh':
|
|
|
|
|
output = '%d तासां';
|
|
|
|
|
break;
|
|
|
|
|
case 'd':
|
|
|
|
|
output = 'एका दिवसा';
|
|
|
|
|
break;
|
|
|
|
|
case 'dd':
|
|
|
|
|
output = '%d दिवसां';
|
|
|
|
|
break;
|
|
|
|
|
case 'M':
|
|
|
|
|
output = 'एका महिन्या';
|
|
|
|
|
break;
|
|
|
|
|
case 'MM':
|
|
|
|
|
output = '%d महिन्यां';
|
|
|
|
|
break;
|
|
|
|
|
case 'y':
|
|
|
|
|
output = 'एका वर्षा';
|
|
|
|
|
break;
|
|
|
|
|
case 'yy':
|
|
|
|
|
output = '%d वर्षां';
|
|
|
|
|
break;
|
2018-04-26 15:15:53 +08:00
|
|
|
|
}
|
2016-02-06 04:42:48 +08:00
|
|
|
|
}
|
2018-04-26 15:15:53 +08:00
|
|
|
|
return output.replace(/%d/i, number);
|
2016-02-06 04:42:48 +08:00
|
|
|
|
}
|
|
|
|
|
|
2018-04-26 15:15:53 +08:00
|
|
|
|
var mr = moment.defineLocale('mr', {
|
2020-11-11 09:34:26 +08:00
|
|
|
|
months: 'जानेवारी_फेब्रुवारी_मार्च_एप्रिल_मे_जून_जुलै_ऑगस्ट_सप्टेंबर_ऑक्टोबर_नोव्हेंबर_डिसेंबर'.split(
|
|
|
|
|
'_'
|
|
|
|
|
),
|
|
|
|
|
monthsShort: 'जाने._फेब्रु._मार्च._एप्रि._मे._जून._जुलै._ऑग._सप्टें._ऑक्टो._नोव्हें._डिसें.'.split(
|
|
|
|
|
'_'
|
|
|
|
|
),
|
|
|
|
|
monthsParseExact: true,
|
|
|
|
|
weekdays: 'रविवार_सोमवार_मंगळवार_बुधवार_गुरूवार_शुक्रवार_शनिवार'.split('_'),
|
|
|
|
|
weekdaysShort: 'रवि_सोम_मंगळ_बुध_गुरू_शुक्र_शनि'.split('_'),
|
|
|
|
|
weekdaysMin: 'र_सो_मं_बु_गु_शु_श'.split('_'),
|
|
|
|
|
longDateFormat: {
|
|
|
|
|
LT: 'A h:mm वाजता',
|
|
|
|
|
LTS: 'A h:mm:ss वाजता',
|
|
|
|
|
L: 'DD/MM/YYYY',
|
|
|
|
|
LL: 'D MMMM YYYY',
|
|
|
|
|
LLL: 'D MMMM YYYY, A h:mm वाजता',
|
|
|
|
|
LLLL: 'dddd, D MMMM YYYY, A h:mm वाजता',
|
2018-04-26 15:15:53 +08:00
|
|
|
|
},
|
2020-11-11 09:34:26 +08:00
|
|
|
|
calendar: {
|
|
|
|
|
sameDay: '[आज] LT',
|
|
|
|
|
nextDay: '[उद्या] LT',
|
|
|
|
|
nextWeek: 'dddd, LT',
|
|
|
|
|
lastDay: '[काल] LT',
|
2018-04-26 15:15:53 +08:00
|
|
|
|
lastWeek: '[मागील] dddd, LT',
|
2020-11-11 09:34:26 +08:00
|
|
|
|
sameElse: 'L',
|
2018-04-26 15:15:53 +08:00
|
|
|
|
},
|
2020-11-11 09:34:26 +08:00
|
|
|
|
relativeTime: {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
future: '%sमध्ये',
|
|
|
|
|
past: '%sपूर्वी',
|
|
|
|
|
s: relativeTimeMr,
|
|
|
|
|
ss: relativeTimeMr,
|
|
|
|
|
m: relativeTimeMr,
|
|
|
|
|
mm: relativeTimeMr,
|
|
|
|
|
h: relativeTimeMr,
|
|
|
|
|
hh: relativeTimeMr,
|
|
|
|
|
d: relativeTimeMr,
|
|
|
|
|
dd: relativeTimeMr,
|
|
|
|
|
M: relativeTimeMr,
|
|
|
|
|
MM: relativeTimeMr,
|
|
|
|
|
y: relativeTimeMr,
|
2020-11-11 09:34:26 +08:00
|
|
|
|
yy: relativeTimeMr,
|
2018-04-26 15:15:53 +08:00
|
|
|
|
},
|
|
|
|
|
preparse: function (string) {
|
|
|
|
|
return string.replace(/[१२३४५६७८९०]/g, function (match) {
|
|
|
|
|
return numberMap[match];
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
postformat: function (string) {
|
|
|
|
|
return string.replace(/\d/g, function (match) {
|
|
|
|
|
return symbolMap[match];
|
|
|
|
|
});
|
|
|
|
|
},
|
2020-11-11 09:34:26 +08:00
|
|
|
|
meridiemParse: /पहाटे|सकाळी|दुपारी|सायंकाळी|रात्री/,
|
|
|
|
|
meridiemHour: function (hour, meridiem) {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
if (hour === 12) {
|
|
|
|
|
hour = 0;
|
|
|
|
|
}
|
2020-11-11 09:34:26 +08:00
|
|
|
|
if (meridiem === 'पहाटे' || meridiem === 'सकाळी') {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
return hour;
|
2020-11-11 09:34:26 +08:00
|
|
|
|
} else if (
|
|
|
|
|
meridiem === 'दुपारी' ||
|
|
|
|
|
meridiem === 'सायंकाळी' ||
|
|
|
|
|
meridiem === 'रात्री'
|
|
|
|
|
) {
|
|
|
|
|
return hour >= 12 ? hour : hour + 12;
|
2018-04-26 15:15:53 +08:00
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
meridiem: function (hour, minute, isLower) {
|
2020-11-11 09:34:26 +08:00
|
|
|
|
if (hour >= 0 && hour < 6) {
|
|
|
|
|
return 'पहाटे';
|
|
|
|
|
} else if (hour < 12) {
|
2018-04-26 15:15:53 +08:00
|
|
|
|
return 'सकाळी';
|
|
|
|
|
} else if (hour < 17) {
|
|
|
|
|
return 'दुपारी';
|
|
|
|
|
} else if (hour < 20) {
|
|
|
|
|
return 'सायंकाळी';
|
|
|
|
|
} else {
|
|
|
|
|
return 'रात्री';
|
|
|
|
|
}
|
|
|
|
|
},
|
2020-11-11 09:34:26 +08:00
|
|
|
|
week: {
|
|
|
|
|
dow: 0, // Sunday is the first day of the week.
|
|
|
|
|
doy: 6, // The week that contains Jan 6th is the first week of the year.
|
|
|
|
|
},
|
2018-04-26 15:15:53 +08:00
|
|
|
|
});
|
2016-02-06 04:42:48 +08:00
|
|
|
|
|
2018-04-26 15:15:53 +08:00
|
|
|
|
return mr;
|
2016-02-06 04:42:48 +08:00
|
|
|
|
|
2017-04-20 12:24:20 +08:00
|
|
|
|
})));
|