Merge pull request #2982 from adrianpietka/select2-ng
Added polish translation
This commit is contained in:
commit
36cfc26cc1
45
src/js/select2/i18n/pl.js
vendored
Normal file
45
src/js/select2/i18n/pl.js
vendored
Normal file
@ -0,0 +1,45 @@
|
||||
define(function () {
|
||||
// Polish
|
||||
var charsWords = ['znak', 'znaki', 'znaków'];
|
||||
var itemsWords = ['element', 'elementy', 'elementów'];
|
||||
|
||||
var pluralWord = function pluralWord(numberOfChars, words) {
|
||||
if (numberOfChars === 1) {
|
||||
return words[0];
|
||||
} else if (numberOfChars > 1 && numberOfChars <= 4) {
|
||||
return words[1];
|
||||
} else if (numberOfChars >= 5) {
|
||||
return words[2];
|
||||
}
|
||||
};
|
||||
|
||||
return {
|
||||
errorLoading: function () {
|
||||
return 'Nie można załadować wyników.';
|
||||
},
|
||||
inputTooLong: function (args) {
|
||||
var overChars = args.input.length - args.maximum;
|
||||
|
||||
return 'Usuń ' + overChars + ' ' + pluralWord(overChars, charsWords);
|
||||
},
|
||||
inputTooShort: function (args) {
|
||||
var remainingChars = args.minimum - args.input.length;
|
||||
|
||||
return 'Podaj przynajmniej ' + remainingChars + ' ' +
|
||||
pluralWord(remainingChars, charsWords);
|
||||
},
|
||||
loadingMore: function () {
|
||||
return 'Trwa ładowanie…';
|
||||
},
|
||||
maximumSelected: function (args) {
|
||||
return 'Możesz zaznaczyć tylko ' + args.maximum + ' ' +
|
||||
pluralWord(args.maxiumum, itemsWords);
|
||||
},
|
||||
noResults: function () {
|
||||
return 'Brak wyników';
|
||||
},
|
||||
searching: function () {
|
||||
return 'Trwa wyszukiwanie…';
|
||||
}
|
||||
};
|
||||
});
|
Loading…
Reference in New Issue
Block a user