NuclearDispersionSystem/ant-design-vue-jeecg/node_modules/moment/locale/gu.js
2023-09-14 14:47:11 +08:00

133 lines
4.8 KiB
Java
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

//! moment.js locale configuration
//! locale : Gujarati [gu]
//! author : Kaushik Thanki : https://github.com/Kaushik1987
;(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',
};
var gu = moment.defineLocale('gu', {
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: 'અમુક પળ',
ss: '%d સેકંડ',
m: 'એક િિ',
mm: '%d િિ',
h: 'એક કલ',
hh: '%d કલ',
d: 'એક િવસ',
dd: '%d િવસ',
M: 'એક મહિ',
MM: '%d મહિ',
y: 'એક વર્ષ',
yy: '%d વર્ષ',
},
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];
});
},
// Gujarati notation for meridiems are quite fuzzy in practice. While there exists
// a rigid notion of a 'Pahar' it is not used as rigidly in modern Gujarati.
meridiemParse: /|બપ|સવ|ંજ/,
meridiemHour: function (hour, meridiem) {
if (hour === 12) {
hour = 0;
}
if (meridiem === '') {
return hour < 4 ? hour : hour + 12;
} else if (meridiem === 'સવ') {
return hour;
} else if (meridiem === 'બપ') {
return hour >= 10 ? hour : hour + 12;
} else if (meridiem === 'ંજ') {
return hour + 12;
}
},
meridiem: function (hour, minute, isLower) {
if (hour < 4) {
return '';
} else if (hour < 10) {
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 gu;
})));