Skip to content
  • P
    Projects
  • G
    Groups
  • S
    Snippets
  • Help

abalsh / Garlix

  • This project
    • Loading...
  • Sign in
Go to a project
  • Project
  • Repository
  • Issues 0
  • Merge Requests 0
  • Pipelines
  • Wiki
  • Snippets
  • Members
  • Activity
  • Graph
  • Charts
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Files
  • Commits
  • Branches
  • Tags
  • Contributors
  • Graph
  • Compare
  • Charts
Switch branch/tag
  • Garlix
  • ..
  • Lang
  • uk.php
Find file
BlameHistoryPermalink
  • Florian Shllaku's avatar
    Laravel has been added and the porting has been configured · 20bcaf2c
    Florian Shllaku committed 6 years ago
    20bcaf2c
uk.php 6.97 KB
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172
<?php

/**
 * This file is part of the Carbon package.
 *
 * (c) Brian Nesbitt <brian@nesbot.com>
 *
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 */
$processHoursFunction = function (\Carbon\CarbonInterface $date, string $format) {
    return $format.'о'.($date->hour === 11 ? 'б' : '').'] LT';
};

/*
 * Authors:
 * - Kunal Marwaha
 * - Josh Soref
 * - François B
 * - Tim Fish
 * - Serhan Apaydın
 * - Max Mykhailenko
 * - JD Isaacks
 * - Max Kovpak
 * - AucT
 * - Philippe Vaucher
 * - Ilya Shaplyko
 * - Vadym Ievsieiev
 * - Denys Kurets
 * - Igor Kasyanchuk
 * - Tsutomu Kuroda
 * - tjku
 * - Max Melentiev
 * - Oleh
 * - epaminond
 * - Juanito Fatas
 * - Vitalii Khustochka
 * - Akira Matsuda
 * - Christopher Dell
 * - Enrique Vidal
 * - Simone Carletti
 * - Aaron Patterson
 * - Andriy Tyurnikov
 * - Nicolás Hock Isaza
 * - Iwakura Taro
 * - Andrii Ponomarov
 * - alecrabbit
 * - vystepanenko
 * - AlexWalkerson
 */
return [
    'year' => ':count рік|:count роки|:count років',
    'y' => ':count рік|:count роки|:count років',
    'a_year' => '{1}рік|:count рік|:count роки|:count років',
    'month' => ':count місяць|:count місяці|:count місяців',
    'm' => ':count місяць|:count місяці|:count місяців',
    'a_month' => '{1}місяць|:count місяць|:count місяці|:count місяців',
    'week' => ':count тиждень|:count тижні|:count тижнів',
    'w' => ':count тиждень|:count тижні|:count тижнів',
    'a_week' => '{1}тиждень|:count тиждень|:count тижні|:count тижнів',
    'day' => ':count день|:count дні|:count днів',
    'd' => ':count день|:count дні|:count днів',
    'a_day' => '{1}день|:count день|:count дні|:count днів',
    'hour' => ':count година|:count години|:count годин',
    'h' => ':count година|:count години|:count годин',
    'a_hour' => '{1}годину|:count година|:count години|:count годин',
    'minute' => ':count хвилина|:count хвилини|:count хвилин',
    'min' => ':count хвилина|:count хвилини|:count хвилин',
    'a_minute' => '{1}хвилина|:count хвилину|:count хвилини|:count хвилин',
    'second' => ':count секунда|:count секунди|:count секунд',
    's' => ':count секунда|:count секунди|:count секунд',
    'a_second' => '{1}кілька секунд|:count секунду|:count секунди|:count секунд',
    'ago' => ':time тому',
    'from_now' => 'за :time',
    'after' => ':time після',
    'before' => ':time до',
    'diff_now' => 'щойно',
    'diff_yesterday' => 'вчора',
    'diff_tomorrow' => 'завтра',
    'diff_before_yesterday' => 'позавчора',
    'diff_after_tomorrow' => 'післязавтра',
    'period_recurrences' => 'один раз|:count рази|:count разів',
    'period_interval' => 'кожні :interval',
    'period_start_date' => 'з :date',
    'period_end_date' => 'до :date',
    'formats' => [
        'LT' => 'HH:mm',
        'LTS' => 'HH:mm:ss',
        'L' => 'DD.MM.YYYY',
        'LL' => 'D MMMM YYYY',
        'LLL' => 'D MMMM YYYY, HH:mm',
        'LLLL' => 'dddd, D MMMM YYYY, HH:mm',
    ],
    'calendar' => [
        'sameDay' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) {
            return $processHoursFunction($date, '[Сьогодні ');
        },
        'nextDay' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) {
            return $processHoursFunction($date, '[Завтра ');
        },
        'nextWeek' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) {
            return $processHoursFunction($date, '[У] dddd [');
        },
        'lastDay' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) {
            return $processHoursFunction($date, '[Вчора ');
        },
        'lastWeek' => function (\Carbon\CarbonInterface $date) use ($processHoursFunction) {
            switch ($date->dayOfWeek) {
                case 0:
                case 3:
                case 5:
                case 6:
                    return $processHoursFunction($date, '[Минулої] dddd [');
                default:
                    return $processHoursFunction($date, '[Минулого] dddd [');
            }
        },
        'sameElse' => 'L',
    ],
    'ordinal' => function ($number, $period) {
        switch ($period) {
            case 'M':
            case 'd':
            case 'DDD':
            case 'w':
            case 'W':
                return $number.'-й';
            case 'D':
                return $number.'-го';
            default:
                return $number;
        }
    },
    'meridiem' => function ($hour) {
        if ($hour < 4) {
            return 'ночі';
        }
        if ($hour < 12) {
            return 'ранку';
        }
        if ($hour < 17) {
            return 'дня';
        }

        return 'вечора';
    },
    'months' => ['січня', 'лютого', 'березня', 'квітня', 'травня', 'червня', 'липня', 'серпня', 'вересня', 'жовтня', 'листопада', 'грудня'],
    'months_standalone' => ['січень', 'лютий', 'березень', 'квітень', 'травень', 'червень', 'липень', 'серпень', 'вересень', 'жовтень', 'листопад', 'грудень'],
    'months_short' => ['січ', 'лют', 'бер', 'кві', 'тра', 'чер', 'лип', 'сер', 'вер', 'жов', 'лис', 'гру'],
    'months_regexp' => '/D[oD]?(\[[^\[\]]*\]|\s)+MMMM?/',
    'weekdays' => function (\Carbon\CarbonInterface $date, $format, $index) {
        static $words = [
            'nominative' => ['неділя', 'понеділок', 'вівторок', 'середа', 'четвер', 'п’ятниця', 'субота'],
            'accusative' => ['неділю', 'понеділок', 'вівторок', 'середу', 'четвер', 'п’ятницю', 'суботу'],
            'genitive' => ['неділі', 'понеділка', 'вівторка', 'середи', 'четверга', 'п’ятниці', 'суботи'],
        ];

        $nounCase = preg_match('/(\[(В|в|У|у)\])\s+dddd/', $format) ?
            'accusative' :
            (preg_match('/\[?(?:минулої|наступної)?\s*\]\s+dddd/', $format) ?
                'genitive' :
                'nominative'
            );

        return $words[$nounCase][$index] ?? null;
    },
    'weekdays_short' => ['нд', 'пн', 'вт', 'ср', 'чт', 'пт', 'сб'],
    'weekdays_min' => ['нд', 'пн', 'вт', 'ср', 'чт', 'пт', 'сб'],
    'first_day_of_week' => 1,
    'day_of_first_week_of_year' => 1,
    'list' => [', ', ' i '],
];