From ccb1c7a1e80b42923672ab63005b138490d29559 Mon Sep 17 00:00:00 2001 From: smartcorestudio Date: Thu, 21 Feb 2013 13:21:49 +0400 Subject: [PATCH] Create select2_locale_ru.js Russian translation file for Select2 --- select2_locale_ru.js | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 select2_locale_ru.js diff --git a/select2_locale_ru.js b/select2_locale_ru.js new file mode 100644 index 00000000..f5df5f1f --- /dev/null +++ b/select2_locale_ru.js @@ -0,0 +1,15 @@ +/** + * Select2 Russian translation + */ +(function ($) { + "use strict"; + + $.extend($.fn.select2.defaults, { + formatNoMatches: function () { return "Совпадений не найдено"; }, + formatInputTooShort: function (input, min) { var n = min - input.length; return "Пожалуйста, введите еще " + n + " символ" + (n == 1 ? "" : ((n > 1)&&(n < 5) ? "а" : "ов")); }, + formatInputTooLong: function (input, max) { var n = input.length - max; return "Пожалуйста, введите на " + n + " символ" + (n == 1 ? "" : ((n > 1)&&(n < 5)? "а" : "ов")) + " меньше"; }, + formatSelectionTooBig: function (limit) { return "Вы можете выбрать не более " + limit + " элемент" + (limit == 1 ? "" : ((limit > 1)&&(limit < 5)? "а" : "ов")); }, + formatLoadMore: function (pageNumber) { return "Загрузка данных..."; }, + formatSearching: function () { return "Поиск..."; } + }); +})(jQuery);