Merge "content: Recognise .json as JsonContent in User and MediaWiki namespace"
[lhc/web/wiklou.git] / resources / lib / moment / locale / ka.js
1 // moment.js locale configuration
2 // locale : Georgian (ka)
3 // author : Irakli Janiashvili : https://github.com/irakli-janiashvili
4
5 (function (factory) {
6 if (typeof define === 'function' && define.amd) {
7 define(['moment'], factory); // AMD
8 } else if (typeof exports === 'object') {
9 module.exports = factory(require('../moment')); // Node
10 } else {
11 factory((typeof global !== 'undefined' ? global : this).moment); // node or other global
12 }
13 }(function (moment) {
14 function monthsCaseReplace(m, format) {
15 var months = {
16 'nominative': 'იანვარი_თებერვალი_მარტი_აპრილი_მაისი_ივნისი_ივლისი_აგვისტო_სექტემბერი_ოქტომბერი_ნოემბერი_დეკემბერი'.split('_'),
17 'accusative': 'იანვარს_თებერვალს_მარტს_აპრილის_მაისს_ივნისს_ივლისს_აგვისტს_სექტემბერს_ოქტომბერს_ნოემბერს_დეკემბერს'.split('_')
18 },
19
20 nounCase = (/D[oD] *MMMM?/).test(format) ?
21 'accusative' :
22 'nominative';
23
24 return months[nounCase][m.month()];
25 }
26
27 function weekdaysCaseReplace(m, format) {
28 var weekdays = {
29 'nominative': 'კვირა_ორშაბათი_სამშაბათი_ოთხშაბათი_ხუთშაბათი_პარასკევი_შაბათი'.split('_'),
30 'accusative': 'კვირას_ორშაბათს_სამშაბათს_ოთხშაბათს_ხუთშაბათს_პარასკევს_შაბათს'.split('_')
31 },
32
33 nounCase = (/(წინა|შემდეგ)/).test(format) ?
34 'accusative' :
35 'nominative';
36
37 return weekdays[nounCase][m.day()];
38 }
39
40 return moment.defineLocale('ka', {
41 months : monthsCaseReplace,
42 monthsShort : 'იან_თებ_მარ_აპრ_მაი_ივნ_ივლ_აგვ_სექ_ოქტ_ნოე_დეკ'.split('_'),
43 weekdays : weekdaysCaseReplace,
44 weekdaysShort : 'კვი_ორშ_სამ_ოთხ_ხუთ_პარ_შაბ'.split('_'),
45 weekdaysMin : 'კვ_ორ_სა_ოთ_ხუ_პა_შა'.split('_'),
46 longDateFormat : {
47 LT : 'h:mm A',
48 LTS : 'h:mm:ss A',
49 L : 'DD/MM/YYYY',
50 LL : 'D MMMM YYYY',
51 LLL : 'D MMMM YYYY LT',
52 LLLL : 'dddd, D MMMM YYYY LT'
53 },
54 calendar : {
55 sameDay : '[დღეს] LT[-ზე]',
56 nextDay : '[ხვალ] LT[-ზე]',
57 lastDay : '[გუშინ] LT[-ზე]',
58 nextWeek : '[შემდეგ] dddd LT[-ზე]',
59 lastWeek : '[წინა] dddd LT-ზე',
60 sameElse : 'L'
61 },
62 relativeTime : {
63 future : function (s) {
64 return (/(წამი|წუთი|საათი|წელი)/).test(s) ?
65 s.replace(/ი$/, 'ში') :
66 s + 'ში';
67 },
68 past : function (s) {
69 if ((/(წამი|წუთი|საათი|დღე|თვე)/).test(s)) {
70 return s.replace(/(ი|ე)$/, 'ის წინ');
71 }
72 if ((/წელი/).test(s)) {
73 return s.replace(/წელი$/, 'წლის წინ');
74 }
75 },
76 s : 'რამდენიმე წამი',
77 m : 'წუთი',
78 mm : '%d წუთი',
79 h : 'საათი',
80 hh : '%d საათი',
81 d : 'დღე',
82 dd : '%d დღე',
83 M : 'თვე',
84 MM : '%d თვე',
85 y : 'წელი',
86 yy : '%d წელი'
87 },
88 ordinalParse: /0|1-ლი|მე-\d{1,2}|\d{1,2}-ე/,
89 ordinal : function (number) {
90 if (number === 0) {
91 return number;
92 }
93
94 if (number === 1) {
95 return number + '-ლი';
96 }
97
98 if ((number < 20) || (number <= 100 && (number % 20 === 0)) || (number % 100 === 0)) {
99 return 'მე-' + number;
100 }
101
102 return number + '-ე';
103 },
104 week : {
105 dow : 1,
106 doy : 7
107 }
108 });
109 }));