NuclearDispersionSystem/ant-design-vue-jeecg/node_modules/moment/locale/mr.js

214 lines
7.5 KiB
Java
Raw Normal View History

2023-09-14 14:47:11 +08:00
//! moment.js locale configuration
//! locale : Marathi [mr]
//! author : Harshad Kale : https://github.com/kalehv
//! author : Vivek Athalye : https://github.com/vnathalye
;(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 symbolMap = {
'1': '१',
'2': '२',
'3': '३',
'4': '४',
'5': '५',
'6': '६',
'7': '७',
'8': '८',
'9': '९',
'0': '',
},
numberMap = {
'१': '1',
'२': '2',
'३': '3',
'४': '4',
'५': '5',
'६': '6',
'७': '7',
'८': '8',
'९': '9',
'': '0',
};
function relativeTimeMr(number, withoutSuffix, string, isFuture) {
var output = '';
if (withoutSuffix) {
switch (string) {
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;
}
} else {
switch (string) {
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;
}
}
return output.replace(/%d/i, number);
}
var mr = moment.defineLocale('mr', {
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 जत',
},
calendar: {
sameDay: '[आज] LT',
nextDay: '[उद्य] LT',
nextWeek: 'dddd, LT',
lastDay: '[] LT',
lastWeek: '[] dddd, LT',
sameElse: 'L',
},
relativeTime: {
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,
yy: relativeTimeMr,
},
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];
});
},
meridiemParse: /पहटे|सक|दुप|यंक|त्र/,
meridiemHour: function (hour, meridiem) {
if (hour === 12) {
hour = 0;
}
if (meridiem === 'पहटे' || meridiem === 'सक') {
return hour;
} else if (
meridiem === 'दुप' ||
meridiem === 'यंक' ||
meridiem === 'त्र'
) {
return hour >= 12 ? hour : hour + 12;
}
},
meridiem: function (hour, minute, isLower) {
if (hour >= 0 && hour < 6) {
return 'पहटे';
} else if (hour < 12) {
return 'सक';
} else if (hour < 17) {
return 'दुप';
} else if (hour < 20) {
return 'यंक';
} else {
return 'त्र';
}
},
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.
},
});
return mr;
})));