PageSourceSearch

https://mazury24.eu/js/dist/moment/locale/pl.js

js mazury24.eu collected 2026-10-02 08:10:04 UTC 3,968 bytes, 105 lines download raw bytes

1//! moment.js locale configuration
2//! locale : polish (pl)
3//! author : Rafal Hirsz : https://github.com/evoL
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 monthsNominative = 'styczeń_luty_marzec_kwiecień_maj_czerwiec_lipiec_sierpień_wrzesień_październik_listopad_grudzień'.split('_'),
14        monthsSubjective = 'stycznia_lutego_marca_kwietnia_maja_czerwca_lipca_sierpnia_września_października_listopada_grudnia'.split('_');
15    function plural(n) {
16        return (n % 10 < 5) && (n % 10 > 1) && ((~~(n / 10) % 10) !== 1);
17    }
18    function translate(number, withoutSuffix, key) {
19        var result = number + ' ';
20        switch (key) {
21        case 'm':
22            return withoutSuffix ? 'minuta' : 'minutę';
23        case 'mm':
24            return result + (plural(number) ? 'minuty' : 'minut');
25        case 'h':
26            return withoutSuffix  ? 'godzina'  : 'godzinę';
27        case 'hh':
28            return result + (plural(number) ? 'godziny' : 'godzin');
29        case 'MM':
30            return result + (plural(number) ? 'miesiące' : 'miesięcy');
31        case 'yy':
32            return result + (plural(number) ? 'lata' : 'lat');
33        }
34    }
35
36    var pl = moment.defineLocale('pl', {
37        months : function (momentToFormat, format) {
38            if (format === '') {
39                // Hack: if format empty we know this is used to generate
40                // RegExp by moment. Give then back both valid forms of months
41                // in RegExp ready format.
42                return '(' + monthsSubjective[momentToFormat.month()] + '|' + monthsNominative[momentToFormat.month()] + ')';
43            } else if (/D MMMM/.test(format)) {
44                return monthsSubjective[momentToFormat.month()];
45            } else {
46                return monthsNominative[momentToFormat.month()];
47            }
48        },
49        monthsShort : 'sty_lut_mar_kwi_maj_cze_lip_sie_wrz_paź_lis_gru'.split('_'),
50        weekdays : 'niedziela_poniedziałek_wtorek_środa_czwartek_piątek_sobota'.split('_'),
51        weekdaysShort : 'nie_pon_wt_śr_czw_pt_sb'.split('_'),
52        weekdaysMin : 'Nd_Pn_Wt_Śr_Cz_Pt_So'.split('_'),
53        longDateFormat : {
54            LT : 'HH:mm',
55            LTS : 'HH:mm:ss',
56            L : 'DD.MM.YYYY',
57            LL : 'D MMMM YYYY',
58            LLL : 'D MMMM YYYY HH:mm',
59            LLLL : 'dddd, D MMMM YYYY HH:mm'
60        },
61        calendar : {
62            sameDay: '[Dziś o] LT',
63            nextDay: '[Jutro o] LT',
64            nextWeek: '[W] dddd [o] LT',
65            lastDay: '[Wczoraj o] LT',
66            lastWeek: function () {
67                switch (this.day()) {
68                case 0:
69                    return '[W zeszłą niedzielę o] LT';
70                case 3:
71                    return '[W zeszłą środę o] LT';
72                case 6:
73                    return '[W zeszłą sobotę o] LT';
74                default:
75                    return '[W zeszły] dddd [o] LT';
76                }
77            },
78            sameElse: 'L'
79        },
80        relativeTime : {
81            future : 'za %s',
82            past : '%s temu',
83            s : 'kilka sekund',
84            m : translate,
85            mm : translate,
86            h : translate,
87            hh : translate,
88            d : '1 dzień',
89            dd : '%d dni',
90            M : 'miesiąc',
91            MM : translate,
92            y : 'rok',
93            yy : translate
94        },
95        ordinalParse: /\d{1,2}\./,
96        ordinal : '%d.',
97        week : {
98            dow : 1, // Monday is the first day of the week.
99            doy : 4  // The week that contains Jan 4th is the first week of the year.
100        }
101    });
102
103    return pl;
104
105}));

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.