adminlte_assets 0.0.33 → 0.0.36

Sign up to get free protection for your applications and to get access to all the features.
Files changed (54) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +34 -1
  3. data/lib/adminlte_assets/version.rb +1 -1
  4. data/vendor/assets/javascripts/adminlte/plugin_options.js +5 -0
  5. data/vendor/assets/javascripts/adminlte/plugins/daterangepicker/all.js +1 -0
  6. data/vendor/assets/javascripts/adminlte/plugins/select2/all.js +1 -1
  7. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/ar.js +3 -0
  8. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/az.js +1 -1
  9. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/bg.js +1 -1
  10. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/ca.js +1 -1
  11. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/cs.js +1 -1
  12. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/da.js +2 -2
  13. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/de.js +1 -1
  14. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/en.js +1 -1
  15. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/es.js +1 -1
  16. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/et.js +1 -1
  17. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/eu.js +1 -1
  18. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/fa.js +1 -1
  19. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/fi.js +1 -1
  20. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/fr.js +1 -1
  21. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/gl.js +2 -2
  22. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/he.js +2 -2
  23. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/hi.js +1 -1
  24. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/hr.js +2 -2
  25. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/hu.js +1 -1
  26. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/id.js +2 -2
  27. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/is.js +1 -1
  28. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/it.js +1 -1
  29. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/ja.js +3 -0
  30. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/ko.js +1 -1
  31. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/lt.js +1 -1
  32. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/lv.js +1 -1
  33. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/mk.js +1 -1
  34. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/ms.js +3 -0
  35. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/nb.js +1 -1
  36. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/nl.js +2 -2
  37. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/pl.js +2 -2
  38. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/pt-BR.js +1 -1
  39. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/pt.js +1 -1
  40. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/ro.js +1 -1
  41. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/ru.js +1 -1
  42. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/sk.js +1 -1
  43. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/sr-Cyrl.js +3 -0
  44. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/sr.js +2 -2
  45. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/sv.js +1 -1
  46. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/th.js +2 -2
  47. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/tr.js +1 -1
  48. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/uk.js +1 -1
  49. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/vi.js +1 -1
  50. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/zh-CN.js +1 -1
  51. data/vendor/assets/javascripts/adminlte/plugins/select2/i18n/zh-TW.js +1 -1
  52. data/vendor/assets/javascripts/adminlte/plugins/select2/select2.full.js +322 -155
  53. data/vendor/assets/stylesheets/adminlte/plugins/select2/select2.css +77 -26
  54. metadata +31 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 26af8a4662584389d61ce23562fd17584cb232a9
4
- data.tar.gz: c00af86298764fd57853274a4f344539e40a2488
3
+ metadata.gz: 743efcb7b1f314750f4c3a3ea078dbff63ab4018
4
+ data.tar.gz: e6d0b31574726ba7ffe5d851905a640bf372c5f0
5
5
  SHA512:
6
- metadata.gz: 90db2d50cd38d305fa729ac515af114bb9e0745997060ee362e8d10413f5e3305354c64a913c1485537616fe659178bf49aefbed5b921ea7517f914acf913840
7
- data.tar.gz: ddb1634a34689e48e53948974ed4613b3174f1860ee43d764dab648b3d8e01b95bbb21db0d89e3a8caa640ac856784f1d790e27f574b82a040c04736849d0a81
6
+ metadata.gz: 01258d4ec4387761f85b1f76761742de88a458e0537597079d8e49243e6739b0e96a3236c2114e1ea283286e6b33730ad7b1cd83b5030a6df2434857e96d9c1d
7
+ data.tar.gz: 61235ec506dc54f7b8a6d273c85c5b789d61b5ec5ce442986e5f7aec14087d2c9ab1bff3a0f4086601b12efde498bce82cde92e5985e103c4559592380b28384
data/README.md CHANGED
@@ -65,7 +65,7 @@ This template include some plugins by default such there are all plugins include
65
65
  ### Custom options for plugins
66
66
  This is a javascript to rewrite default options for other plugins.
67
67
  You can find this file in `javascripts/adminlte/plugin_options.js`
68
- For example:
68
+ For example (**Go to plugin_options file for show all available options**):
69
69
  ~~~
70
70
  $.PluginsOptions.daterangepicker = {
71
71
  multiple: {
@@ -74,6 +74,39 @@ $.PluginsOptions.daterangepicker = {
74
74
  }
75
75
  ~~~
76
76
 
77
+ ### Select2
78
+ Custom selector
79
+
80
+ #### Javscripts
81
+
82
+ Add the require for JS:
83
+ ~~~
84
+ //= require adminlte/plugins/select2/all
85
+ ~~~
86
+
87
+ Also `all.js` include by default these few lines of JavaScript:
88
+
89
+ ~~~
90
+ $('select[data-behaviour="select"]').select2($.PluginsOptions.select2);
91
+ ~~~
92
+
93
+ And this means that you can add `data-behaviour` attribute with `select`:
94
+
95
+ ~~~
96
+ <%= f.select :event_id, 'data-behaviour'=> 'select' %>
97
+ ~~~
98
+
99
+ #### Stylesheets
100
+
101
+ Add this few lines of code:
102
+
103
+ ~~~
104
+ /*
105
+ *= require adminlte/plugins/select2/select2
106
+ */
107
+ ~~~
108
+
109
+
77
110
 
78
111
  ### DateRangePicker
79
112
  This is a date picker this can be used as **range date picker** or **single date picker**.
@@ -1,3 +1,3 @@
1
1
  module AdminlteAssets
2
- VERSION = "0.0.33"
2
+ VERSION = "0.0.36"
3
3
  end
@@ -15,6 +15,11 @@ $.PluginsOptions = {};
15
15
  * --------------------
16
16
  * Rewrite after load this js for use your custom options
17
17
  */
18
+ $.PluginsOptions.datepicker = {
19
+ singleDatePicker: true,
20
+ showDropdowns: true,
21
+ format: 'YYYY-MM-DD',
22
+ }
18
23
  $.PluginsOptions.daterangepicker = {
19
24
  multiple: {
20
25
  showDropdowns: true,
@@ -7,6 +7,7 @@ documentReady = function(){
7
7
  // do all thins inside, this is for turbolinks
8
8
  $('input[data-behaviour="daterange"]').daterangepicker($.PluginsOptions.daterangepicker.multiple);
9
9
  $('input[data-behaviour="daterange-single"]').daterangepicker($.PluginsOptions.daterangepicker.single);
10
+ $('input[data-behaviour="datepicker"]').daterangepicker($.PluginsOptions.datepicker);
10
11
  };
11
12
 
12
13
  $(document).ready(documentReady);
@@ -1,4 +1,4 @@
1
- //= require ./select2
1
+ //= require ./select2.full
2
2
  //= require_self
3
3
 
4
4
  var documentReady;
@@ -0,0 +1,3 @@
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
+
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/ar",[],function(){return{errorLoading:function(){return"لا يمكن تحميل النتائج"},inputTooLong:function(e){var t=e.input.length-e.maximum,n="الرجاء حذف "+t+" عناصر";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="الرجاء إضافة "+t+" عناصر";return n},loadingMore:function(){return"جاري تحميل نتائج إضافية..."},maximumSelected:function(e){var t="تستطيع إختيار "+e.maximum+" بنود فقط";return t},noResults:function(){return"لم يتم العثور على أي نتائج"},searching:function(){return"جاري البحث…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/az",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum;return t+" simvol silin"},inputTooShort:function(e){var t=e.minimum-e.input.length;return t+" simvol daxil edin"},loadingMore:function(){return"Daha çox nəticə yüklənir…"},maximumSelected:function(e){return"Sadəcə "+e.maximum+" element seçə bilərsiniz"},noResults:function(){return"Nəticə tapılmadı"},searching:function(){return"Axtarılır…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/bg",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Моля въведете с "+t+" по-малко символ";return t>1&&(n+="a"),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Моля въведете още "+t+" символ";return t>1&&(n+="a"),n},loadingMore:function(){return"Зареждат се още…"},maximumSelected:function(e){var t="Можете да направите до "+e.maximum+" ";return e.maximum>1?t+="избора":t+="избор",t},noResults:function(){return"Няма намерени съвпадения"},searching:function(){return"Търсене…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/ca",[],function(){return{errorLoading:function(){return"La càrrega ha fallat"},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Si us plau, elimina "+t+" car";return t==1?n+="àcter":n+="àcters",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Si us plau, introdueix "+t+" car";return t==1?n+="àcter":n+="àcters",n},loadingMore:function(){return"Carregant més resultats…"},maximumSelected:function(e){var t="Només es pot seleccionar "+e.maximum+" element";return e.maximum!=1&&(t+="s"),t},noResults:function(){return"No s'han trobat resultats"},searching:function(){return"Cercant…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/cs",[],function(){function e(e,t){switch(e){case 2:return t?"dva":"dvě";case 3:return"tři";case 4:return"čtyři"}return""}return{errorLoading:function(){return"Výsledky nemohly být načteny."},inputTooLong:function(t){var n=t.input.length-t.maximum;return n==1?"Prosím zadejte o jeden znak méně":n<=4?"Prosím zadejte o "+e(n,!0)+" znaky méně":"Prosím zadejte o "+n+" znaků méně"},inputTooShort:function(t){var n=t.minimum-t.input.length;return n==1?"Prosím zadejte ještě jeden znak":n<=4?"Prosím zadejte ještě další "+e(n,!0)+" znaky":"Prosím zadejte ještě dalších "+n+" znaků"},loadingMore:function(){return"Načítají se další výsledky…"},maximumSelected:function(t){var n=t.maximum;return n==1?"Můžete zvolit jen jednu položku":n<=4?"Můžete zvolit maximálně "+e(n,!1)+" položky":"Můžete zvolit maximálně "+n+" položek"},noResults:function(){return"Nenalezeny žádné položky"},searching:function(){return"Vyhledávání…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/da",[],function(){return{errorLoading:function(){return"The results could not be loaded."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Angiv venligst "+t+" tegn mindre";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Angiv venligst "+t+" tegn mere";return n},loadingMore:function(){return"Indlæser flere resultater…"},maximumSelected:function(e){var t="Du kan kun vælge "+e.maximum+" emne";return e.maximum!=1&&(t+="r"),t},noResults:function(){return"Ingen resultater fundet"},searching:function(){return"Søger…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/da",[],function(){return{errorLoading:function(){return"Resultaterne kunne ikke indlæses."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Angiv venligst "+t+" tegn mindre";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Angiv venligst "+t+" tegn mere";return n},loadingMore:function(){return"Indlæser flere resultater…"},maximumSelected:function(e){var t="Du kan kun vælge "+e.maximum+" emne";return e.maximum!=1&&(t+="r"),t},noResults:function(){return"Ingen resultater fundet"},searching:function(){return"Søger…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/de",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum;return"Bitte "+t+" Zeichen weniger eingeben"},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Bitte "+t+" Zeichen mehr eingeben"},loadingMore:function(){return"Lade mehr Ergebnisse…"},maximumSelected:function(e){var t="Sie können nur "+e.maximum+" Eintr";return e.maximum===1?t+="ag":t+="äge",t+=" auswählen",t},noResults:function(){return"Keine Übereinstimmungen gefunden"},searching:function(){return"Suche…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/en",[],function(){return{errorLoading:function(){return"The results could not be loaded."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Please delete "+t+" character";return t!=1&&(n+="s"),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Please enter "+t+" or more characters";return n},loadingMore:function(){return"Loading more results…"},maximumSelected:function(e){var t="You can only select "+e.maximum+" item";return e.maximum!=1&&(t+="s"),t},noResults:function(){return"No results found"},searching:function(){return"Searching…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/es",[],function(){return{errorLoading:function(){return"La carga falló"},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Por favor, elimine "+t+" car";return t==1?n+="ácter":n+="acteres",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Por favor, introduzca "+t+" car";return t==1?n+="ácter":n+="acteres",n},loadingMore:function(){return"Cargando más resultados…"},maximumSelected:function(e){var t="Sólo puede seleccionar "+e.maximum+" elemento";return e.maximum!=1&&(t+="s"),t},noResults:function(){return"No se encontraron resultados"},searching:function(){return"Buscando…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/et",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Sisesta "+t+" täht";return t!=1&&(n+="e"),n+=" vähem",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Sisesta "+t+" täht";return t!=1&&(n+="e"),n+=" rohkem",n},loadingMore:function(){return"Laen tulemusi…"},maximumSelected:function(e){var t="Saad vaid "+e.maximum+" tulemus";return e.maximum==1?t+="e":t+="t",t+=" valida",t},noResults:function(){return"Tulemused puuduvad"},searching:function(){return"Otsin…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/eu",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Idatzi ";return t==1?n+="karaktere bat":n+=t+" karaktere",n+=" gutxiago",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Idatzi ";return t==1?n+="karaktere bat":n+=t+" karaktere",n+=" gehiago",n},loadingMore:function(){return"Emaitza gehiago kargatzen…"},maximumSelected:function(e){return e.maximum===1?"Elementu bakarra hauta dezakezu":e.maximum+" elementu hauta ditzakezu soilik"},noResults:function(){return"Ez da bat datorrenik aurkitu"},searching:function(){return"Bilatzen…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/fa",[],function(){return{errorLoading:function(){return"امکان بارگذاری نتایج وجود ندارد."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="لطفاً "+t+" کاراکتر را حذف نمایید";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="لطفاً تعداد "+t+" کاراکتر یا بیشتر وارد نمایید";return n},loadingMore:function(){return"در حال بارگذاری نتایج بیشتر..."},maximumSelected:function(e){var t="شما تنها می‌توانید "+e.maximum+" آیتم را انتخاب نمایید";return t},noResults:function(){return"هیچ نتیجه‌ای یافت نشد"},searching:function(){return"در حال جستجو..."}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/fi",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum;return"Ole hyvä ja anna "+t+" merkkiä vähemmän"},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Ole hyvä ja anna "+t+" merkkiä lisää"},loadingMore:function(){return"Ladataan lisää tuloksia…"},maximumSelected:function(e){return"Voit valita ainoastaan "+e.maximum+" kpl"},noResults:function(){return"Ei tuloksia"},searching:function(){}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/fr",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Supprimez "+t+" caractère";return t!==1&&(n+="s"),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Saisissez "+t+" caractère";return t!==1&&(n+="s"),n},loadingMore:function(){return"Chargement de résultats supplémentaires…"},maximumSelected:function(e){var t="Vous pouvez seulement sélectionner "+e.maximum+" élément";return e.maximum!==1&&(t+="s"),t},noResults:function(){return"Aucun résultat trouvé"},searching:function(){return"Recherche en cours…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/gl",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Engada ";return t===1?n+="un carácter":n+=t+" caracteres",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Elimine ";return t===1?n+="un carácter":n+=t+" caracteres",n},loadingMore:function(){return"Cargando máis resultados…"},maximumSelected:function(e){var t="Só pode ";return e.maximum===1?t+="un elemento":t+=e.maximum+" elementos",t},noResults:function(){return"Non se atoparon resultados"},searching:function(){return"Buscando…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/gl",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Elimine ";return t===1?n+="un carácter":n+=t+" caracteres",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Engada ";return t===1?n+="un carácter":n+=t+" caracteres",n},loadingMore:function(){return"Cargando máis resultados…"},maximumSelected:function(e){var t="Só pode ";return e.maximum===1?t+="un elemento":t+=e.maximum+" elementos",t},noResults:function(){return"Non se atoparon resultados"},searching:function(){return"Buscando…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/he",[],function(){return{errorLoading:function(){return"התוצאות לא נטענו בהלכה"},inputTooLong:function(e){var t=e.input.length-e.maximum,n="נא למחוק "+t+" תווים";return t!=1&&(n+="s"),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="נא להכניס "+t+" תווים או יותר";return n},loadingMore:function(){return"טען תוצאות נוספות…"},maximumSelected:function(e){var t="באפשרותך לבחור רק "+e.maximum+" פריטים";return e.maximum!=1&&(t+="s"),t},noResults:function(){return"לא נמצאו תוצאות"},searching:function(){return"מחפש…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/he",[],function(){return{errorLoading:function(){return"שגיאה בטעינת התוצאות"},inputTooLong:function(e){var t=e.input.length-e.maximum,n="נא למחוק ";return t===1?n+="תו אחד":n+=t+" תווים",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="נא להכניס ";return t===1?n+="תו אחד":n+=t+" תווים",n+=" או יותר",n},loadingMore:function(){return"טוען תוצאות נוספות…"},maximumSelected:function(e){var t="באפשרותך לבחור עד ";return e.maximum===1?t+="פריט אחד":t+=e.maximum+" פריטים",t},noResults:function(){return"לא נמצאו תוצאות"},searching:function(){return"מחפש…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/hi",[],function(){return{errorLoading:function(){return"परिणामों को लोड नहीं किया जा सका।"},inputTooLong:function(e){var t=e.input.length-e.maximum,n=t+" अक्षर को हटा दें";return t>1&&(n=t+" अक्षरों को हटा दें "),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="कृपया "+t+" या अधिक अक्षर दर्ज करें";return n},loadingMore:function(){return"अधिक परिणाम लोड हो रहे है..."},maximumSelected:function(e){var t="आप केवल "+e.maximum+" आइटम का चयन कर सकते हैं";return t},noResults:function(){return"कोई परिणाम नहीं मिला"},searching:function(){return"खोज रहा है..."}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/hr",[],function(){function e(e){var t=" "+e+" znak";return e%10<5&&e%10>0&&(e%100<5||e%100>19)?e%10>1&&(t+="a"):t+="ova",t}return{inputTooLong:function(t){var n=t.input.length-t.maximum;return"Unesite "+e(n)},inputTooShort:function(t){var n=t.minimum-t.input.length;return"Unesite još "+e(n)},loadingMore:function(){return"Učitavanje rezultata…"},maximumSelected:function(e){return"Maksimalan broj odabranih stavki je "+e.maximum},noResults:function(){return"Nema rezultata"},searching:function(){return"Pretraga…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/hr",[],function(){function e(e){var t=" "+e+" znak";return e%10<5&&e%10>0&&(e%100<5||e%100>19)?e%10>1&&(t+="a"):t+="ova",t}return{errorLoading:function(){return"Preuzimanje nije uspjelo."},inputTooLong:function(t){var n=t.input.length-t.maximum;return"Unesite "+e(n)},inputTooShort:function(t){var n=t.minimum-t.input.length;return"Unesite još "+e(n)},loadingMore:function(){return"Učitavanje rezultata…"},maximumSelected:function(e){return"Maksimalan broj odabranih stavki je "+e.maximum},noResults:function(){return"Nema rezultata"},searching:function(){return"Pretraga…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/hu",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum;return"Túl hosszú. "+t+" karakterrel több, mint kellene."},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Túl rövid. Még "+t+" karakter hiányzik."},loadingMore:function(){return"Töltés…"},maximumSelected:function(e){return"Csak "+e.maximum+" elemet lehet kiválasztani."},noResults:function(){return"Nincs találat."},searching:function(){return"Keresés…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/id",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum;return"Hapuskan "+t+" huruf"},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Masukkan "+t+" huruf lagi"},loadingMore:function(){return"Mengambil data…"},maximumSelected:function(e){return"Anda hanya dapat memilih "+e.maximum+" pilihan"},noResults:function(){return"Tidak ada data yang sesuai"},searching:function(){return"Mencari…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/id",[],function(){return{errorLoading:function(){return"Data tidak boleh diambil."},inputTooLong:function(e){var t=e.input.length-e.maximum;return"Hapuskan "+t+" huruf"},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Masukkan "+t+" huruf lagi"},loadingMore:function(){return"Mengambil data…"},maximumSelected:function(e){return"Anda hanya dapat memilih "+e.maximum+" pilihan"},noResults:function(){return"Tidak ada data yang sesuai"},searching:function(){return"Mencari…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/is",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Vinsamlegast styttið texta um "+t+" staf";return t<=1?n:n+"i"},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Vinsamlegast skrifið "+t+" staf";return t>1&&(n+="i"),n+=" í viðbót",n},loadingMore:function(){return"Sæki fleiri niðurstöður…"},maximumSelected:function(e){return"Þú getur aðeins valið "+e.maximum+" atriði"},noResults:function(){return"Ekkert fannst"},searching:function(){return"Leita…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/it",[],function(){return{errorLoading:function(){return"I risultati non possono essere caricati."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Per favore cancella "+t+" caratter";return t!==1?n+="i":n+="e",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Per favore inserisci "+t+" o più caratteri";return n},loadingMore:function(){return"Caricando più risultati…"},maximumSelected:function(e){var t="Puoi selezionare solo "+e.maximum+" element";return e.maximum!==1?t+="i":t+="o",t},noResults:function(){return"Nessun risultato trovato"},searching:function(){return"Sto cercando…"}}}),{define:e.define,require:e.require}})();
@@ -0,0 +1,3 @@
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
+
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/ja",[],function(){return{errorLoading:function(){return"結果が読み込まれませんでした"},inputTooLong:function(e){var t=e.input.length-e.maximum,n=t+" 文字を削除してください";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="少なくとも "+t+" 文字を入力してください";return n},loadingMore:function(){return"読み込み中…"},maximumSelected:function(e){var t=e.maximum+" 件しか選択できません";return t},noResults:function(){return"対象が見つかりません"},searching:function(){return"検索しています…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/ko",[],function(){return{errorLoading:function(){return"결과를 불러올 수 없습니다."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="너무 깁니다. "+t+" 글자 지워주세요.";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="너무 짧습니다. "+t+" 글자 더 입력해주세요.";return n},loadingMore:function(){return"불러오는 중…"},maximumSelected:function(e){var t="최대 "+e.maximum+"개까지만 선택 가능합니다.";return t},noResults:function(){return"결과가 없습니다."},searching:function(){return"검색 중…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/lt",[],function(){function e(e,t,n,r){return e%100>9&&e%100<21||e%10===0?e%10>1?n:r:t}return{inputTooLong:function(t){var n=t.input.length-t.maximum,r="Pašalinkite "+n+" simbol";return r+=e(n,"ių","ius","į"),r},inputTooShort:function(t){var n=t.minimum-t.input.length,r="Įrašykite dar "+n+" simbol";return r+=e(n,"ių","ius","į"),r},loadingMore:function(){return"Kraunama daugiau rezultatų…"},maximumSelected:function(t){var n="Jūs galite pasirinkti tik "+t.maximum+" element";return n+=e(t.maximum,"ų","us","ą"),n},noResults:function(){return"Atitikmenų nerasta"},searching:function(){return"Ieškoma…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/lv",[],function(){function e(e,t,n,r){return e===11?t:e%10===1?n:r}return{inputTooLong:function(t){var n=t.input.length-t.maximum,r="Lūdzu ievadiet par "+n;return r+=" simbol"+e(n,"iem","u","iem"),r+" mazāk"},inputTooShort:function(t){var n=t.minimum-t.input.length,r="Lūdzu ievadiet vēl "+n;return r+=" simbol"+e(n,"us","u","us"),r},loadingMore:function(){return"Datu ielāde…"},maximumSelected:function(t){var n="Jūs varat izvēlēties ne vairāk kā "+t.maximum;return n+=" element"+e(t.maximum,"us","u","us"),n},noResults:function(){return"Sakritību nav"},searching:function(){return"Meklēšana…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/mk",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Ве молиме внесете "+e.maximum+" помалку карактер";return e.maximum!==1&&(n+="и"),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Ве молиме внесете уште "+e.maximum+" карактер";return e.maximum!==1&&(n+="и"),n},loadingMore:function(){return"Вчитување резултати…"},maximumSelected:function(e){var t="Можете да изберете само "+e.maximum+" ставк";return e.maximum===1?t+="а":t+="и",t},noResults:function(){return"Нема пронајдено совпаѓања"},searching:function(){return"Пребарување…"}}}),{define:e.define,require:e.require}})();
@@ -0,0 +1,3 @@
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
+
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/ms",[],function(){return{errorLoading:function(){return"Keputusan tidak berjaya dimuatkan."},inputTooLong:function(e){var t=e.input.length-e.maximum;return"Sila hapuskan "+t+" aksara"},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Sila masukkan "+t+" atau lebih aksara"},loadingMore:function(){return"Sedang memuatkan keputusan…"},maximumSelected:function(e){return"Anda hanya boleh memilih "+e.maximum+" pilihan"},noResults:function(){return"Tiada padanan yang ditemui"},searching:function(){return"Mencari…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/nb",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum;return"Vennligst fjern "+t+" tegn"},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Vennligst skriv inn ";return t>1?n+=" flere tegn":n+=" tegn til",n},loadingMore:function(){return"Laster flere resultater…"},maximumSelected:function(e){return"Du kan velge maks "+e.maximum+" elementer"},noResults:function(){return"Ingen treff"},searching:function(){return"Søker…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/nl",[],function(){return{errorLoading:function(){return"De resultaten konden niet worden geladen."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Gelieve "+t+" karakters te verwijderen";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Gelieve "+t+" of meer karakters in te voeren";return n},loadingMore:function(){return"Meer resultaten laden…"},maximumSelected:function(e){var t="Er kunnen maar "+e.maximum+" item";return e.maximum!=1&&(t+="s"),t+=" worden geselecteerd",t},noResults:function(){return"Geen resultaten gevonden…"},searching:function(){return"Zoeken…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/nl",[],function(){return{errorLoading:function(){return"De resultaten konden niet worden geladen."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Gelieve "+t+" karakters te verwijderen";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Gelieve "+t+" of meer karakters in te voeren";return n},loadingMore:function(){return"Meer resultaten laden…"},maximumSelected:function(e){var t=e.maximum==1?"kan":"kunnen",n="Er "+t+" maar "+e.maximum+" item";return e.maximum!=1&&(n+="s"),n+=" worden geselecteerd",n},noResults:function(){return"Geen resultaten gevonden…"},searching:function(){return"Zoeken…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/pl",[],function(){var e=["znak","znaki","znaków"],t=["element","elementy","elementów"],n=function(t,n){if(t===1)return n[0];if(t>1&&t<=4)return n[1];if(t>=5)return n[2]};return{errorLoading:function(){return"Nie można załadować wyników."},inputTooLong:function(t){var r=t.input.length-t.maximum;return"Usuń "+r+" "+n(r,e)},inputTooShort:function(t){var r=t.minimum-t.input.length;return"Podaj przynajmniej "+r+" "+n(r,e)},loadingMore:function(){return"Trwa ładowanie…"},maximumSelected:function(e){return"Możesz zaznaczyć tylko "+e.maximum+" "+n(e.maxiumum,t)},noResults:function(){return"Brak wyników"},searching:function(){return"Trwa wyszukiwanie…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/pl",[],function(){var e=["znak","znaki","znaków"],t=["element","elementy","elementów"],n=function(t,n){if(t===1)return n[0];if(t>1&&t<=4)return n[1];if(t>=5)return n[2]};return{errorLoading:function(){return"Nie można załadować wyników."},inputTooLong:function(t){var r=t.input.length-t.maximum;return"Usuń "+r+" "+n(r,e)},inputTooShort:function(t){var r=t.minimum-t.input.length;return"Podaj przynajmniej "+r+" "+n(r,e)},loadingMore:function(){return"Trwa ładowanie…"},maximumSelected:function(e){return"Możesz zaznaczyć tylko "+e.maximum+" "+n(e.maximum,t)},noResults:function(){return"Brak wyników"},searching:function(){return"Trwa wyszukiwanie…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/pt-BR",[],function(){return{errorLoading:function(){return"Os resultados não puderam ser carregados."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Apague "+t+" caracter";return t!=1&&(n+="es"),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Digite "+t+" ou mais caracteres";return n},loadingMore:function(){return"Carregando mais resultados…"},maximumSelected:function(e){var t="Você só pode selecionar "+e.maximum+" ite";return e.maximum==1?t+="m":t+="ns",t},noResults:function(){return"Nenhum resultado encontrado"},searching:function(){return"Buscando…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/pt",[],function(){return{errorLoading:function(){return"Os resultados não puderam ser carregados."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Por favor apague "+t+" ";return n+=t!=1?"caracteres":"carácter",n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Introduza "+t+" ou mais caracteres";return n},loadingMore:function(){return"A carregar mais resultados…"},maximumSelected:function(e){var t="Apenas pode seleccionar "+e.maximum+" ";return t+=e.maximum!=1?"itens":"item",t},noResults:function(){return"Sem resultados"},searching:function(){return"A procurar…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/ro",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Vă rugăm să introduceți mai puțin de "+t;return n+=" caracter",n!==1&&(n+="e"),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Vă rugăm să introduceți incă "+t;return n+=" caracter",n!==1&&(n+="e"),n},loadingMore:function(){return"Se încarcă…"},maximumSelected:function(e){var t="Aveți voie să selectați cel mult "+e.maximum;return t+=" element",t!==1&&(t+="e"),t},noResults:function(){return"Nu a fost găsit nimic"},searching:function(){return"Căutare…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/ru",[],function(){function e(e,t,n,r){return e%10<5&&e%10>0&&e%100<5||e%100>20?e%10>1?n:t:r}return{errorLoading:function(){return"Невозможно загрузить результаты"},inputTooLong:function(t){var n=t.input.length-t.maximum,r="Пожалуйста, введите на "+n+" символ";return r+=e(n,"","a","ов"),r+=" меньше",r},inputTooShort:function(t){var n=t.minimum-t.input.length,r="Пожалуйста, введите еще хотя бы "+n+" символ";return r+=e(n,"","a","ов"),r},loadingMore:function(){return"Загрузка данных…"},maximumSelected:function(t){var n="Вы можете выбрать не более "+t.maximum+" элемент";return n+=e(t.maximum,"","a","ов"),n},noResults:function(){return"Совпадений не найдено"},searching:function(){return"Поиск…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/sk",[],function(){var e={2:function(e){return e?"dva":"dve"},3:function(){return"tri"},4:function(){return"štyri"}};return{inputTooLong:function(t){var n=t.input.length-t.maximum;return n==1?"Prosím, zadajte o jeden znak menej":n>=2&&n<=4?"Prosím, zadajte o "+e[n](!0)+" znaky menej":"Prosím, zadajte o "+n+" znakov menej"},inputTooShort:function(t){var n=t.minimum-t.input.length;return n==1?"Prosím, zadajte ešte jeden znak":n<=4?"Prosím, zadajte ešte ďalšie "+e[n](!0)+" znaky":"Prosím, zadajte ešte ďalších "+n+" znakov"},loadingMore:function(){return"Loading more results…"},maximumSelected:function(t){return t.maximum==1?"Môžete zvoliť len jednu položku":t.maximum>=2&&t.maximum<=4?"Môžete zvoliť najviac "+e[t.maximum](!1)+" položky":"Môžete zvoliť najviac "+t.maximum+" položiek"},noResults:function(){return"Nenašli sa žiadne položky"},searching:function(){return"Vyhľadávanie…"}}}),{define:e.define,require:e.require}})();
@@ -0,0 +1,3 @@
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
+
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/sr-Cyrl",[],function(){function e(e,t,n,r){return e%10==1&&e%100!=11?t:e%10>=2&&e%10<=4&&(e%100<12||e%100>14)?n:r}return{errorLoading:function(){return"Преузимање није успело."},inputTooLong:function(t){var n=t.input.length-t.maximum,r="Обришите "+n+" симбол";return r+=e(n,"","а","а"),r},inputTooShort:function(t){var n=t.minimum-t.input.length,r="Укуцајте бар још "+n+" симбол";return r+=e(n,"","а","а"),r},loadingMore:function(){return"Преузимање још резултата…"},maximumSelected:function(t){var n="Можете изабрати само "+t.maximum+" ставк";return n+=e(t.maximum,"у","е","и"),n},noResults:function(){return"Ништа није пронађено"},searching:function(){return"Претрага…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/sr",[],function(){function e(e,t,n,r){return e%10==1&&e%100!=11?t:e%10>=2&&e%10<=4&&(e%100<12||e%100>14)?n:r}return{inputTooLong:function(t){var n=t.input.length-t.maximum,r="Obrišite "+n+" simbol";return r+=e(n,"","a","a"),r},inputTooShort:function(t){var n=t.minimum-t.input.length,r="Ukucajte bar još "+n+" simbol";return r+=e(n,"","a","a"),r},loadingMore:function(){return"Preuzimanje još rezultata…"},maximumSelected:function(t){var n="Možete izabrati samo "+t.maximum+" stavk";return n+=e(t.maximum,"u","e","i"),n},noResults:function(){return"Ništa nije pronađeno"},searching:function(){return"Pretraga…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/sr",[],function(){function e(e,t,n,r){return e%10==1&&e%100!=11?t:e%10>=2&&e%10<=4&&(e%100<12||e%100>14)?n:r}return{errorLoading:function(){return"Preuzimanje nije uspelo."},inputTooLong:function(t){var n=t.input.length-t.maximum,r="Obrišite "+n+" simbol";return r+=e(n,"","a","a"),r},inputTooShort:function(t){var n=t.minimum-t.input.length,r="Ukucajte bar još "+n+" simbol";return r+=e(n,"","a","a"),r},loadingMore:function(){return"Preuzimanje još rezultata…"},maximumSelected:function(t){var n="Možete izabrati samo "+t.maximum+" stavk";return n+=e(t.maximum,"u","e","i"),n},noResults:function(){return"Ništa nije pronađeno"},searching:function(){return"Pretraga…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/sv",[],function(){return{errorLoading:function(){return"Resultat kunde inte laddas."},inputTooLong:function(e){var t=e.input.length-e.maximum,n="Vänligen sudda ut "+t+" tecken";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Vänligen skriv in "+t+" eller fler tecken";return n},loadingMore:function(){return"Laddar fler resultat…"},maximumSelected:function(e){var t="Du kan max välja "+e.maximum+" element";return t},noResults:function(){return"Inga träffar"},searching:function(){return"Söker…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
- (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/th",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="โปรดลบออก "+t+" ตัวอักษร";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="โปรดพิมพ์เพิ่มอีก "+t+" ตัวอักษร";return n},loadingMore:function(){return"กำลังค้นข้อมูลเพิ่ม…"},maximumSelected:function(e){var t="คุณสามารถเลือกได้ไม่เกิน "+e.maximum+" รายการ";return t},noResults:function(){return"ม่พบข้อมูล"},searching:function(){return"กำลังค้นข้อมูล…"}}}),{define:e.define,require:e.require}})();
3
+ (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/th",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="โปรดลบออก "+t+" ตัวอักษร";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="โปรดพิมพ์เพิ่มอีก "+t+" ตัวอักษร";return n},loadingMore:function(){return"กำลังค้นข้อมูลเพิ่ม…"},maximumSelected:function(e){var t="คุณสามารถเลือกได้ไม่เกิน "+e.maximum+" รายการ";return t},noResults:function(){return"ไม่พบข้อมูล"},searching:function(){return"กำลังค้นข้อมูล…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/tr",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n=t+" karakter daha girmelisiniz";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="En az "+t+" karakter daha girmelisiniz";return n},loadingMore:function(){return"Daha fazla…"},maximumSelected:function(e){var t="Sadece "+e.maximum+" seçim yapabilirsiniz";return t},noResults:function(){return"Sonuç bulunamadı"},searching:function(){return"Aranıyor…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/uk",[],function(){function e(e,t,n,r){return e%100>10&&e%100<15?r:e%10===1?t:e%10>1&&e%10<5?n:r}return{errorLoading:function(){return"Неможливо завантажити результати"},inputTooLong:function(t){var n=t.input.length-t.maximum;return"Будь ласка, видаліть "+n+" "+e(t.maximum,"літеру","літери","літер")},inputTooShort:function(e){var t=e.minimum-e.input.length;return"Будь ласка, введіть "+t+" або більше літер"},loadingMore:function(){return"Завантаження інших результатів…"},maximumSelected:function(t){return"Ви можете вибрати лише "+t.maximum+" "+e(t.maximum,"пункт","пункти","пунктів")},noResults:function(){return"Нічого не знайдено"},searching:function(){return"Пошук…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/vi",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="Vui lòng nhập ít hơn "+t+" ký tự";return t!=1&&(n+="s"),n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="Vui lòng nhập nhiều hơn "+t+' ký tự"';return n},loadingMore:function(){return"Đang lấy thêm kết quả…"},maximumSelected:function(e){var t="Chỉ có thể chọn được "+e.maximum+" lựa chọn";return t},noResults:function(){return"Không tìm thấy kết quả"},searching:function(){return"Đang tìm…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/zh-CN",[],function(){return{errorLoading:function(){return"无法载入结果。"},inputTooLong:function(e){var t=e.input.length-e.maximum,n="请删除"+t+"个字符";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="请再输入至少"+t+"个字符";return n},loadingMore:function(){return"载入更多结果…"},maximumSelected:function(e){var t="最多只能选择"+e.maximum+"个项目";return t},noResults:function(){return"未找到结果"},searching:function(){return"搜索中…"}}}),{define:e.define,require:e.require}})();
@@ -1,3 +1,3 @@
1
- /*! Select2 4.0.0 | https://github.com/select2/select2/blob/master/LICENSE.md */
1
+ /*! Select2 4.0.1 | https://github.com/select2/select2/blob/master/LICENSE.md */
2
2
 
3
3
  (function(){if(jQuery&&jQuery.fn&&jQuery.fn.select2&&jQuery.fn.select2.amd)var e=jQuery.fn.select2.amd;return e.define("select2/i18n/zh-TW",[],function(){return{inputTooLong:function(e){var t=e.input.length-e.maximum,n="請刪掉"+t+"個字元";return n},inputTooShort:function(e){var t=e.minimum-e.input.length,n="請再輸入"+t+"個字元";return n},loadingMore:function(){return"載入中…"},maximumSelected:function(e){var t="你只能選擇最多"+e.maximum+"項";return t},noResults:function(){return"沒有找到相符的項目"},searching:function(){return"搜尋中…"}}}),{define:e.define,require:e.require}})();
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * Select2 4.0.0
2
+ * Select2 4.0.1
3
3
  * https://select2.github.io
4
4
  *
5
5
  * Released under the MIT license
@@ -30,7 +30,7 @@
30
30
  var S2;(function () { if (!S2 || !S2.requirejs) {
31
31
  if (!S2) { S2 = {}; } else { require = S2; }
32
32
  /**
33
- * @license almond 0.2.9 Copyright (c) 2011-2014, The Dojo Foundation All Rights Reserved.
33
+ * @license almond 0.3.1 Copyright (c) 2011-2014, The Dojo Foundation All Rights Reserved.
34
34
  * Available via the MIT or new BSD license.
35
35
  * see: http://github.com/jrburke/almond for details
36
36
  */
@@ -75,12 +75,6 @@ var requirejs, require, define;
75
75
  //otherwise, assume it is a top-level require that will
76
76
  //be relative to baseUrl in the end.
77
77
  if (baseName) {
78
- //Convert baseName to array, and lop off the last part,
79
- //so that . matches that "directory" and not name of the baseName's
80
- //module. For instance, baseName of "one/two/three", maps to
81
- //"one/two/three.js", but we want the directory, "one/two" for
82
- //this normalization.
83
- baseParts = baseParts.slice(0, baseParts.length - 1);
84
78
  name = name.split('/');
85
79
  lastIndex = name.length - 1;
86
80
 
@@ -89,7 +83,11 @@ var requirejs, require, define;
89
83
  name[lastIndex] = name[lastIndex].replace(jsSuffixRegExp, '');
90
84
  }
91
85
 
92
- name = baseParts.concat(name);
86
+ //Lop off the last part of baseParts, so that . matches the
87
+ //"directory" and not name of the baseName's module. For instance,
88
+ //baseName of "one/two/three", maps to "one/two/three.js", but we
89
+ //want the directory, "one/two" for this normalization.
90
+ name = baseParts.slice(0, baseParts.length - 1).concat(name);
93
91
 
94
92
  //start trimDots
95
93
  for (i = 0; i < name.length; i += 1) {
@@ -181,7 +179,15 @@ var requirejs, require, define;
181
179
  //A version of a require function that passes a moduleName
182
180
  //value for items that may need to
183
181
  //look up paths relative to the moduleName
184
- return req.apply(undef, aps.call(arguments, 0).concat([relName, forceSync]));
182
+ var args = aps.call(arguments, 0);
183
+
184
+ //If first arg is not require('string'), and there is only
185
+ //one arg, it is the array form without a callback. Insert
186
+ //a null so that the following concat is correct.
187
+ if (typeof args[0] !== 'string' && args.length === 1) {
188
+ args.push(null);
189
+ }
190
+ return req.apply(undef, args.concat([relName, forceSync]));
185
191
  };
186
192
  }
187
193
 
@@ -431,6 +437,9 @@ var requirejs, require, define;
431
437
  requirejs._defined = defined;
432
438
 
433
439
  define = function (name, deps, callback) {
440
+ if (typeof name !== 'string') {
441
+ throw new Error('See almond README: incorrect module build, no module name');
442
+ }
434
443
 
435
444
  //This module may not have dependencies
436
445
  if (!deps.splice) {
@@ -773,7 +782,8 @@ S2.define('select2/results',[
773
782
  this.hideLoading();
774
783
 
775
784
  var $message = $(
776
- '<li role="treeitem" class="select2-results__option"></li>'
785
+ '<li role="treeitem" aria-live="assertive"' +
786
+ ' class="select2-results__option"></li>'
777
787
  );
778
788
 
779
789
  var message = this.options.get('translations').get(params.message);
@@ -784,9 +794,15 @@ S2.define('select2/results',[
784
794
  )
785
795
  );
786
796
 
797
+ $message[0].className += ' select2-results__message';
798
+
787
799
  this.$results.append($message);
788
800
  };
789
801
 
802
+ Results.prototype.hideMessages = function () {
803
+ this.$results.find('.select2-results__message').remove();
804
+ };
805
+
790
806
  Results.prototype.append = function (data) {
791
807
  this.hideLoading();
792
808
 
@@ -986,6 +1002,7 @@ S2.define('select2/results',[
986
1002
  });
987
1003
 
988
1004
  container.on('query', function (params) {
1005
+ self.hideMessages();
989
1006
  self.showLoading(params);
990
1007
  });
991
1008
 
@@ -1041,7 +1058,7 @@ S2.define('select2/results',[
1041
1058
  var data = $highlighted.data('data');
1042
1059
 
1043
1060
  if ($highlighted.attr('aria-selected') == 'true') {
1044
- self.trigger('close');
1061
+ self.trigger('close', {});
1045
1062
  } else {
1046
1063
  self.trigger('select', {
1047
1064
  data: data
@@ -1163,7 +1180,7 @@ S2.define('select2/results',[
1163
1180
  data: data
1164
1181
  });
1165
1182
  } else {
1166
- self.trigger('close');
1183
+ self.trigger('close', {});
1167
1184
  }
1168
1185
 
1169
1186
  return;
@@ -1229,7 +1246,7 @@ S2.define('select2/results',[
1229
1246
  var template = this.options.get('templateResult');
1230
1247
  var escapeMarkup = this.options.get('escapeMarkup');
1231
1248
 
1232
- var content = template(result);
1249
+ var content = template(result, container);
1233
1250
 
1234
1251
  if (content == null) {
1235
1252
  container.style.display = 'none';
@@ -1286,7 +1303,7 @@ S2.define('select2/selection/base',[
1286
1303
  BaseSelection.prototype.render = function () {
1287
1304
  var $selection = $(
1288
1305
  '<span class="select2-selection" role="combobox" ' +
1289
- 'aria-autocomplete="list" aria-haspopup="true" aria-expanded="false">' +
1306
+ ' aria-haspopup="true" aria-expanded="false">' +
1290
1307
  '</span>'
1291
1308
  );
1292
1309
 
@@ -1319,7 +1336,7 @@ S2.define('select2/selection/base',[
1319
1336
  });
1320
1337
 
1321
1338
  this.$selection.on('blur', function (evt) {
1322
- self.trigger('blur', evt);
1339
+ self._handleBlur(evt);
1323
1340
  });
1324
1341
 
1325
1342
  this.$selection.on('keydown', function (evt) {
@@ -1366,6 +1383,24 @@ S2.define('select2/selection/base',[
1366
1383
  });
1367
1384
  };
1368
1385
 
1386
+ BaseSelection.prototype._handleBlur = function (evt) {
1387
+ var self = this;
1388
+
1389
+ // This needs to be delayed as the active element is the body when the tab
1390
+ // key is pressed, possibly along with others.
1391
+ window.setTimeout(function () {
1392
+ // Don't trigger `blur` if the focus is still in the selection
1393
+ if (
1394
+ (document.activeElement == self.$selection[0]) ||
1395
+ ($.contains(self.$selection[0], document.activeElement))
1396
+ ) {
1397
+ return;
1398
+ }
1399
+
1400
+ self.trigger('blur', evt);
1401
+ }, 1);
1402
+ };
1403
+
1369
1404
  BaseSelection.prototype._attachCloseHandler = function (container) {
1370
1405
  var self = this;
1371
1406
 
@@ -1475,11 +1510,11 @@ S2.define('select2/selection/single',[
1475
1510
  this.$selection.find('.select2-selection__rendered').empty();
1476
1511
  };
1477
1512
 
1478
- SingleSelection.prototype.display = function (data) {
1513
+ SingleSelection.prototype.display = function (data, container) {
1479
1514
  var template = this.options.get('templateSelection');
1480
1515
  var escapeMarkup = this.options.get('escapeMarkup');
1481
1516
 
1482
- return escapeMarkup(template(data));
1517
+ return escapeMarkup(template(data, container));
1483
1518
  };
1484
1519
 
1485
1520
  SingleSelection.prototype.selectionContainer = function () {
@@ -1494,9 +1529,9 @@ S2.define('select2/selection/single',[
1494
1529
 
1495
1530
  var selection = data[0];
1496
1531
 
1497
- var formatted = this.display(selection);
1498
-
1499
1532
  var $rendered = this.$selection.find('.select2-selection__rendered');
1533
+ var formatted = this.display(selection, $rendered);
1534
+
1500
1535
  $rendered.empty().append(formatted);
1501
1536
  $rendered.prop('title', selection.title || selection.text);
1502
1537
  };
@@ -1538,29 +1573,37 @@ S2.define('select2/selection/multiple',[
1538
1573
  });
1539
1574
  });
1540
1575
 
1541
- this.$selection.on('click', '.select2-selection__choice__remove',
1576
+ this.$selection.on(
1577
+ 'click',
1578
+ '.select2-selection__choice__remove',
1542
1579
  function (evt) {
1543
- var $remove = $(this);
1544
- var $selection = $remove.parent();
1580
+ // Ignore the event if it is disabled
1581
+ if (self.options.get('disabled')) {
1582
+ return;
1583
+ }
1545
1584
 
1546
- var data = $selection.data('data');
1585
+ var $remove = $(this);
1586
+ var $selection = $remove.parent();
1547
1587
 
1548
- self.trigger('unselect', {
1549
- originalEvent: evt,
1550
- data: data
1551
- });
1552
- });
1588
+ var data = $selection.data('data');
1589
+
1590
+ self.trigger('unselect', {
1591
+ originalEvent: evt,
1592
+ data: data
1593
+ });
1594
+ }
1595
+ );
1553
1596
  };
1554
1597
 
1555
1598
  MultipleSelection.prototype.clear = function () {
1556
1599
  this.$selection.find('.select2-selection__rendered').empty();
1557
1600
  };
1558
1601
 
1559
- MultipleSelection.prototype.display = function (data) {
1602
+ MultipleSelection.prototype.display = function (data, container) {
1560
1603
  var template = this.options.get('templateSelection');
1561
1604
  var escapeMarkup = this.options.get('escapeMarkup');
1562
1605
 
1563
- return escapeMarkup(template(data));
1606
+ return escapeMarkup(template(data, container));
1564
1607
  };
1565
1608
 
1566
1609
  MultipleSelection.prototype.selectionContainer = function () {
@@ -1587,8 +1630,8 @@ S2.define('select2/selection/multiple',[
1587
1630
  for (var d = 0; d < data.length; d++) {
1588
1631
  var selection = data[d];
1589
1632
 
1590
- var formatted = this.display(selection);
1591
1633
  var $selection = this.selectionContainer();
1634
+ var formatted = this.display(selection, $selection);
1592
1635
 
1593
1636
  $selection.append(formatted);
1594
1637
  $selection.prop('title', selection.title || selection.text);
@@ -1720,7 +1763,7 @@ S2.define('select2/selection/allowClear',[
1720
1763
 
1721
1764
  this.$element.val(this.placeholder.id).trigger('change');
1722
1765
 
1723
- this.trigger('toggle');
1766
+ this.trigger('toggle', {});
1724
1767
  };
1725
1768
 
1726
1769
  AllowClear.prototype._handleKeyboardClear = function (_, evt, container) {
@@ -1768,7 +1811,7 @@ S2.define('select2/selection/search',[
1768
1811
  '<li class="select2-search select2-search--inline">' +
1769
1812
  '<input class="select2-search__field" type="search" tabindex="-1"' +
1770
1813
  ' autocomplete="off" autocorrect="off" autocapitalize="off"' +
1771
- ' spellcheck="false" role="textbox" />' +
1814
+ ' spellcheck="false" role="textbox" aria-autocomplete="list" />' +
1772
1815
  '</li>'
1773
1816
  );
1774
1817
 
@@ -1777,6 +1820,8 @@ S2.define('select2/selection/search',[
1777
1820
 
1778
1821
  var $rendered = decorated.call(this);
1779
1822
 
1823
+ this._transferTabIndex();
1824
+
1780
1825
  return $rendered;
1781
1826
  };
1782
1827
 
@@ -1786,32 +1831,39 @@ S2.define('select2/selection/search',[
1786
1831
  decorated.call(this, container, $container);
1787
1832
 
1788
1833
  container.on('open', function () {
1789
- self.$search.attr('tabindex', 0);
1790
-
1791
- self.$search.focus();
1834
+ self.$search.trigger('focus');
1792
1835
  });
1793
1836
 
1794
1837
  container.on('close', function () {
1795
- self.$search.attr('tabindex', -1);
1796
-
1797
1838
  self.$search.val('');
1798
- self.$search.focus();
1839
+ self.$search.removeAttr('aria-activedescendant');
1840
+ self.$search.trigger('focus');
1799
1841
  });
1800
1842
 
1801
1843
  container.on('enable', function () {
1802
1844
  self.$search.prop('disabled', false);
1845
+
1846
+ self._transferTabIndex();
1803
1847
  });
1804
1848
 
1805
1849
  container.on('disable', function () {
1806
1850
  self.$search.prop('disabled', true);
1807
1851
  });
1808
1852
 
1853
+ container.on('focus', function (evt) {
1854
+ self.$search.trigger('focus');
1855
+ });
1856
+
1857
+ container.on('results:focus', function (params) {
1858
+ self.$search.attr('aria-activedescendant', params.id);
1859
+ });
1860
+
1809
1861
  this.$selection.on('focusin', '.select2-search--inline', function (evt) {
1810
1862
  self.trigger('focus', evt);
1811
1863
  });
1812
1864
 
1813
1865
  this.$selection.on('focusout', '.select2-search--inline', function (evt) {
1814
- self.trigger('blur', evt);
1866
+ self._handleBlur(evt);
1815
1867
  });
1816
1868
 
1817
1869
  this.$selection.on('keydown', '.select2-search--inline', function (evt) {
@@ -1837,18 +1889,73 @@ S2.define('select2/selection/search',[
1837
1889
  }
1838
1890
  });
1839
1891
 
1892
+ // Try to detect the IE version should the `documentMode` property that
1893
+ // is stored on the document. This is only implemented in IE and is
1894
+ // slightly cleaner than doing a user agent check.
1895
+ // This property is not available in Edge, but Edge also doesn't have
1896
+ // this bug.
1897
+ var msie = document.documentMode;
1898
+ var disableInputEvents = msie && msie <= 11;
1899
+
1840
1900
  // Workaround for browsers which do not support the `input` event
1841
1901
  // This will prevent double-triggering of events for browsers which support
1842
1902
  // both the `keyup` and `input` events.
1843
- this.$selection.on('input', '.select2-search--inline', function (evt) {
1844
- // Unbind the duplicated `keyup` event
1845
- self.$selection.off('keyup.search');
1846
- });
1903
+ this.$selection.on(
1904
+ 'input.searchcheck',
1905
+ '.select2-search--inline',
1906
+ function (evt) {
1907
+ // IE will trigger the `input` event when a placeholder is used on a
1908
+ // search box. To get around this issue, we are forced to ignore all
1909
+ // `input` events in IE and keep using `keyup`.
1910
+ if (disableInputEvents) {
1911
+ self.$selection.off('input.search input.searchcheck');
1912
+ return;
1913
+ }
1847
1914
 
1848
- this.$selection.on('keyup.search input', '.select2-search--inline',
1849
- function (evt) {
1850
- self.handleSearch(evt);
1851
- });
1915
+ // Unbind the duplicated `keyup` event
1916
+ self.$selection.off('keyup.search');
1917
+ }
1918
+ );
1919
+
1920
+ this.$selection.on(
1921
+ 'keyup.search input.search',
1922
+ '.select2-search--inline',
1923
+ function (evt) {
1924
+ // IE will trigger the `input` event when a placeholder is used on a
1925
+ // search box. To get around this issue, we are forced to ignore all
1926
+ // `input` events in IE and keep using `keyup`.
1927
+ if (disableInputEvents && evt.type === 'input') {
1928
+ self.$selection.off('input.search input.searchcheck');
1929
+ return;
1930
+ }
1931
+
1932
+ var key = evt.which;
1933
+
1934
+ // We can freely ignore events from modifier keys
1935
+ if (key == KEYS.SHIFT || key == KEYS.CTRL || key == KEYS.ALT) {
1936
+ return;
1937
+ }
1938
+
1939
+ // Tabbing will be handled during the `keydown` phase
1940
+ if (key == KEYS.TAB) {
1941
+ return;
1942
+ }
1943
+
1944
+ self.handleSearch(evt);
1945
+ }
1946
+ );
1947
+ };
1948
+
1949
+ /**
1950
+ * This method will transfer the tabindex attribute from the rendered
1951
+ * selection to the search box. This allows for the search box to be used as
1952
+ * the primary focus instead of the selection container.
1953
+ *
1954
+ * @private
1955
+ */
1956
+ Search.prototype._transferTabIndex = function (decorated) {
1957
+ this.$search.attr('tabindex', this.$selection.attr('tabindex'));
1958
+ this.$selection.attr('tabindex', '-1');
1852
1959
  };
1853
1960
 
1854
1961
  Search.prototype.createPlaceholder = function (decorated, placeholder) {
@@ -1856,6 +1963,8 @@ S2.define('select2/selection/search',[
1856
1963
  };
1857
1964
 
1858
1965
  Search.prototype.update = function (decorated, data) {
1966
+ var searchHadFocus = this.$search[0] == document.activeElement;
1967
+
1859
1968
  this.$search.attr('placeholder', '');
1860
1969
 
1861
1970
  decorated.call(this, data);
@@ -1864,6 +1973,9 @@ S2.define('select2/selection/search',[
1864
1973
  .append(this.$searchContainer);
1865
1974
 
1866
1975
  this.resizeSearch();
1976
+ if (searchHadFocus) {
1977
+ this.$search.focus();
1978
+ }
1867
1979
  };
1868
1980
 
1869
1981
  Search.prototype.handleSearch = function () {
@@ -1885,9 +1997,8 @@ S2.define('select2/selection/search',[
1885
1997
  data: item
1886
1998
  });
1887
1999
 
1888
- this.trigger('open');
1889
-
1890
- this.$search.val(item.text + ' ');
2000
+ this.$search.val(item.text);
2001
+ this.handleSearch();
1891
2002
  };
1892
2003
 
1893
2004
  Search.prototype.resizeSearch = function () {
@@ -3223,7 +3334,7 @@ S2.define('select2/data/array',[
3223
3334
  var existingData = this.item($existingOption);
3224
3335
  var newData = $.extend(true, {}, existingData, item);
3225
3336
 
3226
- var $newOption = this.option(existingData);
3337
+ var $newOption = this.option(newData);
3227
3338
 
3228
3339
  $existingOption.replaceWith($newOption);
3229
3340
 
@@ -3259,7 +3370,7 @@ S2.define('select2/data/ajax',[
3259
3370
  this.processResults = this.ajaxOptions.processResults;
3260
3371
  }
3261
3372
 
3262
- ArrayAdapter.__super__.constructor.call(this, $element, options);
3373
+ AjaxAdapter.__super__.constructor.call(this, $element, options);
3263
3374
  }
3264
3375
 
3265
3376
  Utils.Extend(AjaxAdapter, ArrayAdapter);
@@ -3267,9 +3378,9 @@ S2.define('select2/data/ajax',[
3267
3378
  AjaxAdapter.prototype._applyDefaults = function (options) {
3268
3379
  var defaults = {
3269
3380
  data: function (params) {
3270
- return {
3381
+ return $.extend({}, params, {
3271
3382
  q: params.term
3272
- };
3383
+ });
3273
3384
  },
3274
3385
  transport: function (params, success, failure) {
3275
3386
  var $request = $.ajax(params);
@@ -3306,11 +3417,11 @@ S2.define('select2/data/ajax',[
3306
3417
  }, this.ajaxOptions);
3307
3418
 
3308
3419
  if (typeof options.url === 'function') {
3309
- options.url = options.url(params);
3420
+ options.url = options.url.call(this.$element, params);
3310
3421
  }
3311
3422
 
3312
3423
  if (typeof options.data === 'function') {
3313
- options.data = options.data(params);
3424
+ options.data = options.data.call(this.$element, params);
3314
3425
  }
3315
3426
 
3316
3427
  function request () {
@@ -3493,7 +3604,9 @@ S2.define('select2/data/tokenizer',[
3493
3604
  var self = this;
3494
3605
 
3495
3606
  function select (data) {
3496
- self.select(data);
3607
+ self.trigger('select', {
3608
+ data: data
3609
+ });
3497
3610
  }
3498
3611
 
3499
3612
  params.term = params.term || '';
@@ -3541,6 +3654,11 @@ S2.define('select2/data/tokenizer',[
3541
3654
 
3542
3655
  var data = createTag(partParams);
3543
3656
 
3657
+ if (data == null) {
3658
+ i++;
3659
+ continue;
3660
+ }
3661
+
3544
3662
  callback(data);
3545
3663
 
3546
3664
  // Reset the term to not include the tokenized portion
@@ -3678,6 +3796,10 @@ S2.define('select2/dropdown',[
3678
3796
  return $dropdown;
3679
3797
  };
3680
3798
 
3799
+ Dropdown.prototype.bind = function () {
3800
+ // Should be implemented in subclasses
3801
+ };
3802
+
3681
3803
  Dropdown.prototype.position = function ($dropdown, $container) {
3682
3804
  // Should be implmented in subclasses
3683
3805
  };
@@ -3904,7 +4026,9 @@ S2.define('select2/dropdown/infiniteScroll',[
3904
4026
 
3905
4027
  InfiniteScroll.prototype.createLoadingMore = function () {
3906
4028
  var $option = $(
3907
- '<li class="option load-more" role="treeitem"></li>'
4029
+ '<li ' +
4030
+ 'class="select2-results__option select2-results__option--load-more"' +
4031
+ 'role="treeitem" aria-disabled="true"></li>'
3908
4032
  );
3909
4033
 
3910
4034
  var message = this.options.get('translations').get('loadingMore');
@@ -3922,7 +4046,7 @@ S2.define('select2/dropdown/attachBody',[
3922
4046
  '../utils'
3923
4047
  ], function ($, Utils) {
3924
4048
  function AttachBody (decorated, $element, options) {
3925
- this.$dropdownParent = options.get('dropdownParent') || document.body;
4049
+ this.$dropdownParent = options.get('dropdownParent') || $(document.body);
3926
4050
 
3927
4051
  decorated.call(this, $element, options);
3928
4052
  }
@@ -3963,6 +4087,12 @@ S2.define('select2/dropdown/attachBody',[
3963
4087
  });
3964
4088
  };
3965
4089
 
4090
+ AttachBody.prototype.destroy = function (decorated) {
4091
+ decorated.call(this);
4092
+
4093
+ this.$dropdownContainer.remove();
4094
+ };
4095
+
3966
4096
  AttachBody.prototype.position = function (decorated, $dropdown, $container) {
3967
4097
  // Clone all of the container classes
3968
4098
  $dropdown.attr('class', $container.attr('class'));
@@ -3993,7 +4123,8 @@ S2.define('select2/dropdown/attachBody',[
3993
4123
  this.$dropdownContainer.detach();
3994
4124
  };
3995
4125
 
3996
- AttachBody.prototype._attachPositioningHandler = function (container) {
4126
+ AttachBody.prototype._attachPositioningHandler =
4127
+ function (decorated, container) {
3997
4128
  var self = this;
3998
4129
 
3999
4130
  var scrollEvent = 'scroll.select2.' + container.id;
@@ -4020,7 +4151,8 @@ S2.define('select2/dropdown/attachBody',[
4020
4151
  });
4021
4152
  };
4022
4153
 
4023
- AttachBody.prototype._detachPositioningHandler = function (container) {
4154
+ AttachBody.prototype._detachPositioningHandler =
4155
+ function (decorated, container) {
4024
4156
  var scrollEvent = 'scroll.select2.' + container.id;
4025
4157
  var resizeEvent = 'resize.select2.' + container.id;
4026
4158
  var orientationEvent = 'orientationchange.select2.' + container.id;
@@ -4068,6 +4200,14 @@ S2.define('select2/dropdown/attachBody',[
4068
4200
  top: container.bottom
4069
4201
  };
4070
4202
 
4203
+ // Fix positioning with static parents
4204
+ if (this.$dropdownParent[0].style.position !== 'static') {
4205
+ var parentOffset = this.$dropdownParent.offset();
4206
+
4207
+ css.top -= parentOffset.top;
4208
+ css.left -= parentOffset.left;
4209
+ }
4210
+
4071
4211
  if (!isCurrentlyAbove && !isCurrentlyBelow) {
4072
4212
  newDirection = 'below';
4073
4213
  }
@@ -4096,8 +4236,6 @@ S2.define('select2/dropdown/attachBody',[
4096
4236
  };
4097
4237
 
4098
4238
  AttachBody.prototype._resizeDropdown = function () {
4099
- this.$dropdownContainer.width();
4100
-
4101
4239
  var css = {
4102
4240
  width: this.$container.outerWidth(false) + 'px'
4103
4241
  };
@@ -4178,12 +4316,23 @@ S2.define('select2/dropdown/selectOnClose',[
4178
4316
  SelectOnClose.prototype._handleSelectOnClose = function () {
4179
4317
  var $highlightedResults = this.getHighlightedResults();
4180
4318
 
4319
+ // Only select highlighted results
4181
4320
  if ($highlightedResults.length < 1) {
4182
4321
  return;
4183
4322
  }
4184
4323
 
4324
+ var data = $highlightedResults.data('data');
4325
+
4326
+ // Don't re-select already selected resulte
4327
+ if (
4328
+ (data.element != null && data.element.selected) ||
4329
+ (data.element == null && data.selected)
4330
+ ) {
4331
+ return;
4332
+ }
4333
+
4185
4334
  this.trigger('select', {
4186
- data: $highlightedResults.data('data')
4335
+ data: data
4187
4336
  });
4188
4337
  };
4189
4338
 
@@ -4217,7 +4366,7 @@ S2.define('select2/dropdown/closeOnSelect',[
4217
4366
  return;
4218
4367
  }
4219
4368
 
4220
- this.trigger('close');
4369
+ this.trigger('close', {});
4221
4370
  };
4222
4371
 
4223
4372
  return CloseOnSelect;
@@ -4868,8 +5017,8 @@ S2.define('select2/core',[
4868
5017
 
4869
5018
  // Hide the original select
4870
5019
  $element.addClass('select2-hidden-accessible');
4871
- $element.attr('aria-hidden', 'true');
4872
-
5020
+ $element.attr('aria-hidden', 'true');
5021
+
4873
5022
  // Synchronize any monitored attributes
4874
5023
  this._syncAttributes();
4875
5024
 
@@ -5004,12 +5153,16 @@ S2.define('select2/core',[
5004
5153
 
5005
5154
  Select2.prototype._registerSelectionEvents = function () {
5006
5155
  var self = this;
5007
- var nonRelayEvents = ['toggle'];
5156
+ var nonRelayEvents = ['toggle', 'focus'];
5008
5157
 
5009
5158
  this.selection.on('toggle', function () {
5010
5159
  self.toggleDropdown();
5011
5160
  });
5012
5161
 
5162
+ this.selection.on('focus', function (params) {
5163
+ self.focus(params);
5164
+ });
5165
+
5013
5166
  this.selection.on('*', function (name, params) {
5014
5167
  if ($.inArray(name, nonRelayEvents) !== -1) {
5015
5168
  return;
@@ -5054,17 +5207,13 @@ S2.define('select2/core',[
5054
5207
  self.$container.addClass('select2-container--disabled');
5055
5208
  });
5056
5209
 
5057
- this.on('focus', function () {
5058
- self.$container.addClass('select2-container--focus');
5059
- });
5060
-
5061
5210
  this.on('blur', function () {
5062
5211
  self.$container.removeClass('select2-container--focus');
5063
5212
  });
5064
5213
 
5065
5214
  this.on('query', function (params) {
5066
5215
  if (!self.isOpen()) {
5067
- self.trigger('open');
5216
+ self.trigger('open', {});
5068
5217
  }
5069
5218
 
5070
5219
  this.dataAdapter.query(params, function (data) {
@@ -5088,30 +5237,31 @@ S2.define('select2/core',[
5088
5237
  var key = evt.which;
5089
5238
 
5090
5239
  if (self.isOpen()) {
5091
- if (key === KEYS.ENTER) {
5092
- self.trigger('results:select');
5240
+ if (key === KEYS.ESC || key === KEYS.TAB ||
5241
+ (key === KEYS.UP && evt.altKey)) {
5242
+ self.close();
5243
+
5244
+ evt.preventDefault();
5245
+ } else if (key === KEYS.ENTER) {
5246
+ self.trigger('results:select', {});
5093
5247
 
5094
5248
  evt.preventDefault();
5095
5249
  } else if ((key === KEYS.SPACE && evt.ctrlKey)) {
5096
- self.trigger('results:toggle');
5250
+ self.trigger('results:toggle', {});
5097
5251
 
5098
5252
  evt.preventDefault();
5099
5253
  } else if (key === KEYS.UP) {
5100
- self.trigger('results:previous');
5254
+ self.trigger('results:previous', {});
5101
5255
 
5102
5256
  evt.preventDefault();
5103
5257
  } else if (key === KEYS.DOWN) {
5104
- self.trigger('results:next');
5105
-
5106
- evt.preventDefault();
5107
- } else if (key === KEYS.ESC || key === KEYS.TAB) {
5108
- self.close();
5258
+ self.trigger('results:next', {});
5109
5259
 
5110
5260
  evt.preventDefault();
5111
5261
  }
5112
5262
  } else {
5113
5263
  if (key === KEYS.ENTER || key === KEYS.SPACE ||
5114
- ((key === KEYS.DOWN || key === KEYS.UP) && evt.altKey)) {
5264
+ (key === KEYS.DOWN && evt.altKey)) {
5115
5265
  self.open();
5116
5266
 
5117
5267
  evt.preventDefault();
@@ -5128,9 +5278,9 @@ S2.define('select2/core',[
5128
5278
  this.close();
5129
5279
  }
5130
5280
 
5131
- this.trigger('disable');
5281
+ this.trigger('disable', {});
5132
5282
  } else {
5133
- this.trigger('enable');
5283
+ this.trigger('enable', {});
5134
5284
  }
5135
5285
  };
5136
5286
 
@@ -5147,6 +5297,10 @@ S2.define('select2/core',[
5147
5297
  'unselect': 'unselecting'
5148
5298
  };
5149
5299
 
5300
+ if (args === undefined) {
5301
+ args = {};
5302
+ }
5303
+
5150
5304
  if (name in preTriggerMap) {
5151
5305
  var preTriggerName = preTriggerMap[name];
5152
5306
  var preTriggerArgs = {
@@ -5185,8 +5339,6 @@ S2.define('select2/core',[
5185
5339
  }
5186
5340
 
5187
5341
  this.trigger('query', {});
5188
-
5189
- this.trigger('open');
5190
5342
  };
5191
5343
 
5192
5344
  Select2.prototype.close = function () {
@@ -5194,13 +5346,27 @@ S2.define('select2/core',[
5194
5346
  return;
5195
5347
  }
5196
5348
 
5197
- this.trigger('close');
5349
+ this.trigger('close', {});
5198
5350
  };
5199
5351
 
5200
5352
  Select2.prototype.isOpen = function () {
5201
5353
  return this.$container.hasClass('select2-container--open');
5202
5354
  };
5203
5355
 
5356
+ Select2.prototype.hasFocus = function () {
5357
+ return this.$container.hasClass('select2-container--focus');
5358
+ };
5359
+
5360
+ Select2.prototype.focus = function (data) {
5361
+ // No need to re-trigger focus events if we are already focused
5362
+ if (this.hasFocus()) {
5363
+ return;
5364
+ }
5365
+
5366
+ this.$container.addClass('select2-container--focus');
5367
+ this.trigger('focus', {});
5368
+ };
5369
+
5204
5370
  Select2.prototype.enable = function (args) {
5205
5371
  if (this.options.get('debug') && window.console && console.warn) {
5206
5372
  console.warn(
@@ -5281,7 +5447,7 @@ S2.define('select2/core',[
5281
5447
  this.$element.attr('tabindex', this.$element.data('old-tabindex'));
5282
5448
 
5283
5449
  this.$element.removeClass('select2-hidden-accessible');
5284
- this.$element.attr('aria-hidden', 'false');
5450
+ this.$element.attr('aria-hidden', 'false');
5285
5451
  this.$element.removeData('select2');
5286
5452
 
5287
5453
  this.dataAdapter.destroy();
@@ -5385,7 +5551,7 @@ S2.define('select2/compat/containerCss',[
5385
5551
  containerCssAdapter = containerCssAdapter || _containerAdapter;
5386
5552
 
5387
5553
  if (containerCssClass.indexOf(':all:') !== -1) {
5388
- containerCssClass = containerCssClass.replace(':all', '');
5554
+ containerCssClass = containerCssClass.replace(':all:', '');
5389
5555
 
5390
5556
  var _cssAdapter = containerCssAdapter;
5391
5557
 
@@ -5442,7 +5608,7 @@ S2.define('select2/compat/dropdownCss',[
5442
5608
  dropdownCssAdapter = dropdownCssAdapter || _dropdownAdapter;
5443
5609
 
5444
5610
  if (dropdownCssClass.indexOf(':all:') !== -1) {
5445
- dropdownCssClass = dropdownCssClass.replace(':all', '');
5611
+ dropdownCssClass = dropdownCssClass.replace(':all:', '');
5446
5612
 
5447
5613
  var _cssAdapter = dropdownCssAdapter;
5448
5614
 
@@ -5813,76 +5979,18 @@ S2.define('select2/selection/stopPropagation',[
5813
5979
  return StopPropagation;
5814
5980
  });
5815
5981
 
5816
- S2.define('jquery.select2',[
5817
- 'jquery',
5818
- 'require',
5819
-
5820
- './select2/core',
5821
- './select2/defaults'
5822
- ], function ($, require, Select2, Defaults) {
5823
- // Force jQuery.mousewheel to be loaded if it hasn't already
5824
- require('jquery.mousewheel');
5825
-
5826
- if ($.fn.select2 == null) {
5827
- // All methods that should return the element
5828
- var thisMethods = ['open', 'close', 'destroy'];
5829
-
5830
- $.fn.select2 = function (options) {
5831
- options = options || {};
5832
-
5833
- if (typeof options === 'object') {
5834
- this.each(function () {
5835
- var instanceOptions = $.extend({}, options, true);
5836
-
5837
- var instance = new Select2($(this), instanceOptions);
5838
- });
5839
-
5840
- return this;
5841
- } else if (typeof options === 'string') {
5842
- var instance = this.data('select2');
5843
-
5844
- if (instance == null && window.console && console.error) {
5845
- console.error(
5846
- 'The select2(\'' + options + '\') method was called on an ' +
5847
- 'element that is not using Select2.'
5848
- );
5849
- }
5850
-
5851
- var args = Array.prototype.slice.call(arguments, 1);
5852
-
5853
- var ret = instance[options](args);
5854
-
5855
- // Check if we should be returning `this`
5856
- if ($.inArray(options, thisMethods) > -1) {
5857
- return this;
5858
- }
5859
-
5860
- return ret;
5861
- } else {
5862
- throw new Error('Invalid arguments for Select2: ' + options);
5863
- }
5864
- };
5865
- }
5866
-
5867
- if ($.fn.select2.defaults == null) {
5868
- $.fn.select2.defaults = Defaults;
5869
- }
5870
-
5871
- return Select2;
5872
- });
5873
-
5874
5982
  /*!
5875
- * jQuery Mousewheel 3.1.12
5983
+ * jQuery Mousewheel 3.1.13
5876
5984
  *
5877
- * Copyright 2014 jQuery Foundation and other contributors
5878
- * Released under the MIT license.
5985
+ * Copyright jQuery Foundation and other contributors
5986
+ * Released under the MIT license
5879
5987
  * http://jquery.org/license
5880
5988
  */
5881
5989
 
5882
5990
  (function (factory) {
5883
5991
  if ( typeof S2.define === 'function' && S2.define.amd ) {
5884
5992
  // AMD. Register as an anonymous module.
5885
- S2.define('jquery.mousewheel',['jquery'], factory);
5993
+ S2.define('jquery-mousewheel',['jquery'], factory);
5886
5994
  } else if (typeof exports === 'object') {
5887
5995
  // Node/CommonJS style for Browserify
5888
5996
  module.exports = factory;
@@ -6093,6 +6201,65 @@ S2.define('jquery.select2',[
6093
6201
 
6094
6202
  }));
6095
6203
 
6204
+ S2.define('jquery.select2',[
6205
+ 'jquery',
6206
+ 'jquery-mousewheel',
6207
+
6208
+ './select2/core',
6209
+ './select2/defaults'
6210
+ ], function ($, _, Select2, Defaults) {
6211
+ if ($.fn.select2 == null) {
6212
+ // All methods that should return the element
6213
+ var thisMethods = ['open', 'close', 'destroy'];
6214
+
6215
+ $.fn.select2 = function (options) {
6216
+ options = options || {};
6217
+
6218
+ if (typeof options === 'object') {
6219
+ this.each(function () {
6220
+ var instanceOptions = $.extend(true, {}, options);
6221
+
6222
+ var instance = new Select2($(this), instanceOptions);
6223
+ });
6224
+
6225
+ return this;
6226
+ } else if (typeof options === 'string') {
6227
+ var ret;
6228
+
6229
+ this.each(function () {
6230
+ var instance = $(this).data('select2');
6231
+
6232
+ if (instance == null && window.console && console.error) {
6233
+ console.error(
6234
+ 'The select2(\'' + options + '\') method was called on an ' +
6235
+ 'element that is not using Select2.'
6236
+ );
6237
+ }
6238
+
6239
+ var args = Array.prototype.slice.call(arguments, 1);
6240
+
6241
+ ret = instance[options].apply(instance, args);
6242
+ });
6243
+
6244
+ // Check if we should be returning `this`
6245
+ if ($.inArray(options, thisMethods) > -1) {
6246
+ return this;
6247
+ }
6248
+
6249
+ return ret;
6250
+ } else {
6251
+ throw new Error('Invalid arguments for Select2: ' + options);
6252
+ }
6253
+ };
6254
+ }
6255
+
6256
+ if ($.fn.select2.defaults == null) {
6257
+ $.fn.select2.defaults = Defaults;
6258
+ }
6259
+
6260
+ return Select2;
6261
+ });
6262
+
6096
6263
  // Return the AMD loader configuration so it can be used outside of this file
6097
6264
  return {
6098
6265
  define: S2.define,