1 //! moment.js locale configuration
2 //! locale : Polish [pl]
3 //! author : Rafal Hirsz : https://github.com/evoL
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
) :
10 }(this, (function (moment
) { 'use strict';
13 var monthsNominative
= 'styczeń_luty_marzec_kwiecień_maj_czerwiec_lipiec_sierpień_wrzesień_październik_listopad_grudzień'.split('_');
14 var monthsSubjective
= 'stycznia_lutego_marca_kwietnia_maja_czerwca_lipca_sierpnia_września_października_listopada_grudnia'.split('_');
16 return (n
% 10 < 5) && (n
% 10 > 1) && ((~~(n
/ 10) % 10) !== 1);
18 function translate(number
, withoutSuffix
, key
) {
19 var result
= number
+ ' ';
22 return withoutSuffix
? 'minuta' : 'minutę';
24 return result
+ (plural(number
) ? 'minuty' : 'minut');
26 return withoutSuffix
? 'godzina' : 'godzinę';
28 return result
+ (plural(number
) ? 'godziny' : 'godzin');
30 return result
+ (plural(number
) ? 'miesiące' : 'miesięcy');
32 return result
+ (plural(number
) ? 'lata' : 'lat');
36 var pl
= moment
.defineLocale('pl', {
37 months : function (momentToFormat
, format
) {
38 if (!momentToFormat
) {
39 return monthsNominative
;
40 } else if (format
=== '') {
41 // Hack: if format empty we know this is used to generate
42 // RegExp by moment. Give then back both valid forms of months
43 // in RegExp ready format.
44 return '(' + monthsSubjective
[momentToFormat
.month()] + '|' + monthsNominative
[momentToFormat
.month()] + ')';
45 } else if (/D MMMM/.test(format
)) {
46 return monthsSubjective
[momentToFormat
.month()];
48 return monthsNominative
[momentToFormat
.month()];
51 monthsShort
: 'sty_lut_mar_kwi_maj_cze_lip_sie_wrz_paź_lis_gru'.split('_'),
52 weekdays
: 'niedziela_poniedziałek_wtorek_środa_czwartek_piątek_sobota'.split('_'),
53 weekdaysShort
: 'ndz_pon_wt_śr_czw_pt_sob'.split('_'),
54 weekdaysMin
: 'Nd_Pn_Wt_Śr_Cz_Pt_So'.split('_'),
60 LLL
: 'D MMMM YYYY HH:mm',
61 LLLL
: 'dddd, D MMMM YYYY HH:mm'
64 sameDay
: '[Dziś o] LT',
65 nextDay
: '[Jutro o] LT',
66 nextWeek: function () {
69 return '[W niedzielę o] LT';
72 return '[We wtorek o] LT';
75 return '[W środę o] LT';
78 return '[W sobotę o] LT';
81 return '[W] dddd [o] LT';
84 lastDay
: '[Wczoraj o] LT',
85 lastWeek: function () {
88 return '[W zeszłą niedzielę o] LT';
90 return '[W zeszłą środę o] LT';
92 return '[W zeszłą sobotę o] LT';
94 return '[W zeszły] dddd [o] LT';
114 dayOfMonthOrdinalParse
: /\d{1,2}\./,
117 dow
: 1, // Monday is the first day of the week.
118 doy
: 4 // The week that contains Jan 4th is the first week of the year.