vendor: 5,946 bytes, lines 1-157
1// moment.js locale configuration 2// locale : ukrainian (uk) 3// author : zemlanin : https://github.com/zemlanin 4// Author : Menelion Elensúle : https://github.com/Oire 5 6(function (factory) { 7 if (typeof define === 'function' && define.amd) { 8 define(['moment'], factory); // AMD 9 } else if (typeof exports === 'object') { 10 module.exports = factory(require('../moment')); // Node 11 } else { 12 factory(window.moment); // Browser global 13 } 14}(function (moment) { 15 function plural(word, num) { 16 var forms = word.split('_'); 17 return num % 10 === 1 && num % 100 !== 11 ? forms[0] : (num % 10 >= 2 && num % 10 <= 4 && (num % 100 < 10 || num % 100 >= 20) ? forms[1] : forms[2]); 18 } 19 20 function relativeTimeWithPlural(number, withoutSuffix, key) { 21 var format = { 22 'mm': 'Ñ Ð²Ð¸Ð»Ð¸Ð½Ð°_Ñ Ð²Ð¸Ð»Ð¸Ð½Ð¸_Ñ Ð²Ð¸Ð»Ð¸Ð½', 23 'hh': 'година_години_годин', 24 'dd': 'денÑ_днÑ_днÑв', 25 'MM': 'мÑÑÑÑÑ_мÑÑÑÑÑ_мÑÑÑÑÑв', 26 'yy': 'ÑÑк_Ñоки_ÑокÑв' 27 }; 28 if (key === 'm') { 29 return withoutSuffix ? 'Ñ Ð²Ð¸Ð»Ð¸Ð½Ð°' : 'Ñ Ð²Ð¸Ð»Ð¸Ð½Ñ'; 30 } 31 else if (key === 'h') { 32 return withoutSuffix ? 'година' : 'годинÑ'; 33 } 34 else { 35 return number + ' ' + plural(format[key], +number); 36 } 37 } 38 39 function monthsCaseReplace(m, format) { 40 var months = { 41 'nominative': 'ÑÑÑенÑ_лÑÑий_беÑезенÑ_квÑÑенÑ_ÑÑавенÑ_ÑеÑвенÑ_липенÑ_ÑеÑпенÑ_веÑеÑенÑ_жовÑенÑ_лиÑÑопад_гÑÑденÑ'.split('_'), 42 'accusative': 'ÑÑÑнÑ_лÑÑого_беÑезнÑ_квÑÑнÑ_ÑÑавнÑ_ÑеÑвнÑ_липнÑ_ÑеÑпнÑ_веÑеÑнÑ_жовÑнÑ_лиÑÑопада_гÑÑднÑ'.split('_') 43 }, 44 45 nounCase = (/D[oD]? *MMMM?/).test(format) ? 46 'accusative' : 47 'nominative'; 48 49 return months[nounCase][m.month()]; 50 } 51 52 function weekdaysCaseReplace(m, format) { 53 var weekdays = { 54 'nominative': 'недÑлÑ_понедÑлок_вÑвÑоÑок_ÑеÑеда_ÑеÑвеÑ_пâÑÑниÑÑ_ÑÑбоÑа'.split('_'), 55 'accusative': 'недÑлÑ_понедÑлок_вÑвÑоÑок_ÑеÑедÑ_ÑеÑвеÑ_пâÑÑниÑÑ_ÑÑбоÑÑ'.split('_'), 56 'genitive': 'недÑлÑ_понедÑлка_вÑвÑоÑка_ÑеÑеди_ÑеÑвеÑга_пâÑÑниÑÑ_ÑÑбоÑи'.split('_') 57 }, 58 59 nounCase = (/(\[[ÐвУÑ]\]) ?dddd/).test(format) ? 60 'accusative' : 61 ((/\[?(?:минÑлоÑ|наÑÑÑпноÑ)? ?\] ?dddd/).test(format) ? 62 'genitive' : 63 'nominative'); 64 65 return weekdays[nounCase][m.day()]; 66 } 67 68 function processHoursFunction(str) { 69 return function () { 70 return str + 'о' + (this.hours() === 11 ? 'б' : '') + '] LT'; 71 }; 72 } 73 74 return moment.defineLocale('uk', { 75 months : monthsCaseReplace, 76 monthsShort : 'ÑÑÑ_лÑÑ_беÑ_квÑÑ_ÑÑав_ÑеÑв_лип_ÑеÑп_веÑ_жовÑ_лиÑÑ_гÑÑд'.split('_'), 77 weekdays : weekdaysCaseReplace, 78 weekdaysShort : 'нд_пн_вÑ_ÑÑ_ÑÑ_пÑ_Ñб'.split('_'), 79 weekdaysMin : 'нд_пн_вÑ_ÑÑ_ÑÑ_пÑ_Ñб'.split('_'), 80 longDateFormat : { 81 LT : 'HH:mm', 82 L : 'DD.MM.YYYY', 83 LL : 'D MMMM YYYY Ñ.', 84 LLL : 'D MMMM YYYY Ñ., LT', 85 LLLL : 'dddd, D MMMM YYYY Ñ., LT' 86 }, 87 calendar : { 88 sameDay: processHoursFunction('[СÑÐ¾Ð³Ð¾Ð´Ð½Ñ '), 89 nextDay: processHoursFunction('[ÐавÑÑа '), 90 lastDay: processHoursFunction('[ÐÑоÑа '), 91 nextWeek: processHoursFunction('[У] dddd ['), 92 lastWeek: function () { 93 switch (this.day()) { 94 case 0: 95 case 3: 96 case 5: 97 case 6: 98 return processHoursFunction('[ÐинÑлоÑ] dddd [').call(this); 99 case 1: 100 case 2: 101 case 4: 102 return processHoursFunction('[ÐинÑлого] dddd [').call(this); 103 } 104 }, 105 sameElse: 'L' 106 }, 107 relativeTime : { 108 future : 'за %s', 109 past : '%s ÑомÑ', 110 s : 'декÑлÑка ÑекÑнд', 111 m : relativeTimeWithPlural, 112 mm : relativeTimeWithPlural, 113 h : 'годинÑ', 114 hh : relativeTimeWithPlural, 115 d : 'денÑ', 116 dd : relativeTimeWithPlural, 117 M : 'мÑÑÑÑÑ', 118 MM : relativeTimeWithPlural, 119 y : 'ÑÑк', 120 yy : relativeTimeWithPlural 121 }, 122 123 // M. E.: those two are virtually unused but a user might want to implement them for his/her website for some reason 124 125 meridiem : function (hour, minute, isLower) { 126 if (hour < 4) { 127 return 'ноÑÑ'; 128 } else if (hour < 12) { 129 return 'ÑанкÑ'; 130 } else if (hour < 17) { 131 return 'днÑ'; 132 } else { 133 return 'веÑоÑа'; 134 } 135 }, 136 137 ordinal: function (number, period) { 138 switch (period) { 139 case 'M': 140 case 'd': 141 case 'DDD': 142 case 'w': 143 case 'W': 144 return number + '-й'; 145 case 'D': 146 return number + '-го'; 147 default: 148 return number; 149 } 150 }, 151 152 week : { 153 dow : 1, // Monday is the first day of the week. 154 doy : 7 // The week that contains Jan 1st is the first week of the year. 155 } 156 }); 157}));
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.