Merge "objectcache: use INTERIM_KEY_TTL constant in WANObjectCache for readability"
[lhc/web/wiklou.git] / resources / lib / moment / locale / gu.js
1 //! moment.js locale configuration
2 //! locale : Gujarati [gu]
3 //! author : Kaushik Thanki : https://github.com/Kaushik1987
4
5 ;(function (global, factory) {
6 typeof exports === 'object' && typeof module !== 'undefined'
7 && typeof require === 'function' ? factory(require('../moment')) :
8 typeof define === 'function' && define.amd ? define(['../moment'], factory) :
9 factory(global.moment)
10 }(this, (function (moment) { 'use strict';
11
12
13 var symbolMap = {
14 '1': '૧',
15 '2': '૨',
16 '3': '૩',
17 '4': '૪',
18 '5': '૫',
19 '6': '૬',
20 '7': '૭',
21 '8': '૮',
22 '9': '૯',
23 '0': '૦'
24 };
25 var numberMap = {
26 '૧': '1',
27 '૨': '2',
28 '૩': '3',
29 '૪': '4',
30 '૫': '5',
31 '૬': '6',
32 '૭': '7',
33 '૮': '8',
34 '૯': '9',
35 '૦': '0'
36 };
37
38 var gu = moment.defineLocale('gu', {
39 months: 'જાન્યુઆરી_ફેબ્રુઆરી_માર્ચ_એપ્રિલ_મે_જૂન_જુલાઈ_ઑગસ્ટ_સપ્ટેમ્બર_ઑક્ટ્બર_નવેમ્બર_ડિસેમ્બર'.split('_'),
40 monthsShort: 'જાન્યુ._ફેબ્રુ._માર્ચ_એપ્રિ._મે_જૂન_જુલા._ઑગ._સપ્ટે._ઑક્ટ્._નવે._ડિસે.'.split('_'),
41 monthsParseExact: true,
42 weekdays: 'રવિવાર_સોમવાર_મંગળવાર_બુધ્વાર_ગુરુવાર_શુક્રવાર_શનિવાર'.split('_'),
43 weekdaysShort: 'રવિ_સોમ_મંગળ_બુધ્_ગુરુ_શુક્ર_શનિ'.split('_'),
44 weekdaysMin: 'ર_સો_મં_બુ_ગુ_શુ_શ'.split('_'),
45 longDateFormat: {
46 LT: 'A h:mm વાગ્યે',
47 LTS: 'A h:mm:ss વાગ્યે',
48 L: 'DD/MM/YYYY',
49 LL: 'D MMMM YYYY',
50 LLL: 'D MMMM YYYY, A h:mm વાગ્યે',
51 LLLL: 'dddd, D MMMM YYYY, A h:mm વાગ્યે'
52 },
53 calendar: {
54 sameDay: '[આજ] LT',
55 nextDay: '[કાલે] LT',
56 nextWeek: 'dddd, LT',
57 lastDay: '[ગઇકાલે] LT',
58 lastWeek: '[પાછલા] dddd, LT',
59 sameElse: 'L'
60 },
61 relativeTime: {
62 future: '%s મા',
63 past: '%s પેહલા',
64 s: 'અમુક પળો',
65 m: 'એક મિનિટ',
66 mm: '%d મિનિટ',
67 h: 'એક કલાક',
68 hh: '%d કલાક',
69 d: 'એક દિવસ',
70 dd: '%d દિવસ',
71 M: 'એક મહિનો',
72 MM: '%d મહિનો',
73 y: 'એક વર્ષ',
74 yy: '%d વર્ષ'
75 },
76 preparse: function (string) {
77 return string.replace(/[૧૨૩૪૫૬૭૮૯૦]/g, function (match) {
78 return numberMap[match];
79 });
80 },
81 postformat: function (string) {
82 return string.replace(/\d/g, function (match) {
83 return symbolMap[match];
84 });
85 },
86 // Gujarati notation for meridiems are quite fuzzy in practice. While there exists
87 // a rigid notion of a 'Pahar' it is not used as rigidly in modern Gujarati.
88 meridiemParse: /રાત|બપોર|સવાર|સાંજ/,
89 meridiemHour: function (hour, meridiem) {
90 if (hour === 12) {
91 hour = 0;
92 }
93 if (meridiem === 'રાત') {
94 return hour < 4 ? hour : hour + 12;
95 } else if (meridiem === 'સવાર') {
96 return hour;
97 } else if (meridiem === 'બપોર') {
98 return hour >= 10 ? hour : hour + 12;
99 } else if (meridiem === 'સાંજ') {
100 return hour + 12;
101 }
102 },
103 meridiem: function (hour, minute, isLower) {
104 if (hour < 4) {
105 return 'રાત';
106 } else if (hour < 10) {
107 return 'સવાર';
108 } else if (hour < 17) {
109 return 'બપોર';
110 } else if (hour < 20) {
111 return 'સાંજ';
112 } else {
113 return 'રાત';
114 }
115 },
116 week: {
117 dow: 0, // Sunday is the first day of the week.
118 doy: 6 // The week that contains Jan 1st is the first week of the year.
119 }
120 });
121
122 return gu;
123
124 })));