Update dependency select2 to v4 - autoclosed #1220
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
3.5.1
->4.0.8
By merging this PR, the below issues will be automatically resolved and closed:
Release Notes
select2/select2
v4.0.8
Compare Source
New features / improvements
<option>
(#5560)computedstyle
option for calculating the width (#5559)Bug fixes
Translations
Miscellaneous
.select2-selection__placeholder
CSS definitions for multiple selects (#5508)v4.0.7
Compare Source
New features/improvements
Bug fixes
Miscellaneous
v4.0.6
Compare Source
New features/improvements
clear
andclearing
events (#5058)scrollAfterSelect
option (#5150)Bug fixes
;
before beginning of factory wrapper (#5089)select2-selection__rendered
when selection is cleared (#4640, #4746)Defaults.set()
(#4364)Utils.__cache
instead of using$.data
(#4346, #5486)selection:update
(#4306)Accessibility
.select2-hidden-accessible
(#4908)Translations
tk
) (#5125)sq
) (#5199)ka
) (#5179)ne
) (#5295)bn
) (#5248)removeAllItems
translation for clear "x" title (#5291)Miscellaneous
v4.0.5
Compare Source
Bug fixes
autocapitalize=off
withautocapitalize=none
(#4994)Translations
ps
) (#4960)dsb
andhsb
) (#4949)inputTooShort
message (#4817, 4896)af
) (#4850)bs
) (#4504)v4.0.4
Compare Source
New features / Improvements
0
option values [select2/select2@16b4840, select2/select2@0358ee528765157234643d289bce6b8ca5889c72]Bug fixes
Documentation
<select>
serialization example [https://github.com/select2/select2/pull/4538]Translations
errorLoading
Hungarian translation [select2/select2@7d1d13352321e21670ff1c6cba7413aa264fd57a]errorLoading
German translation [select2/select2@4df965219ea4c39147fde9335bc260840465933a]errorLoading
Galician translation [select2/select2@8fcc6202c37f4e06d951342bf142a3b906b6b8e3]errorLoading
Thai translation [select2/select2@625fc78ee616baedf64aa37357403b4b72c7363c]searching
anderrorLoading
Finnish translations [https://github.com/select2/select2/pull/4730]errorLoading
Turkish translation [select2/select2@fd4a082, select2/select2@751b36767f9f28b9de9428d5e8035c9a404915d9]v4.0.3
Compare Source
This is the third bugfix release of Select2 4.0.0. It builds upon the second bugfix release and fixes many common issues.
New features / Improvements
dropdownAutoWidth
option now properly works [select2/select2@fe26b083eb830836061de1458e483782cefef424]focus
event on the original<select>
is now handled [select2/select2@31e7a1d4c52ed7477769fcad5d15166ae3c9b4d0]Bug fixes
select2('option')
no longer mutate the arguments when working on multiple elements [select2/select2@c2c1aeef31c95c6df5545c900a4e1782d712497c]selectOnClose
now works properly withcloseOnSelect
[select2/select2@481c43883e23874e9c35879d173eb8cc5b994b12]ajax.delay
to empty search terms as well [select2/select2@4b9e02f02211248be25ac4c16d4635cf38237bb9]Documentation
<label>
[select2/select2@3bc7f4ac78b58eff8cd17b3273596638c3c9c5c1]ajax.url
[select2/select2@5a831afb9a7d46e8f20aec21164cfbfd182024de]Translations
errorLoading
[https://github.com/select2/select2/pull/4259]errorLoading
[select2/select2@b1ea28bb7d8c02b3b352f558031ccfc8041122eb]v4.0.2
Compare Source
This is the second bugfix release of Select2 4.0.0. It builds upon the first release candidate of Select2 4.0.2 with some minor improvements.
New features / Improvements
insertTag
option to control the placement of thetags
option [https://github.com/select2/select2/pull/4008]Bug fixes
Documentation
id
andtext
[https://github.com/select2/select2/issues/4086]change
just for Select2 [https://github.com/select2/select2/issues/3620]Translations
v4.0.1
Compare Source
New features / improvements
input
event beforechange
events (#4649)selection:update
once on DOM change events (#5734)Bug fixes
Documentation
Miscellaneous
v4.0.0
Compare Source
This builds upon the second release candidate, so review all previous release notes before upgrading from previous versions of Select2.
Supported environments
New features
jQuery.noConflict
.<select>
is the recommended element and can be used for all options. There is limited backwards-compatible support for the<input>
element in full builds.data-*
attributesen-US
) and Select2 will be able to determine what translation files to load.Breaking changes
bower.json
/component.json
files.<select>
has replaced<input type="hidden" />
for all options (including remote data)matcher
has been revamped to include full context, a compatibility module (select2/compat/matcher
) has been createdselectionAdapter
with theClickMask
(select2/selection/clickMask
) decorator.StopPropagation
modules available in the full builds to prevent this. [select2/select2@8f8140e3b00c5d5bb232455137c4c633d7da4275]Options
width
option has been changed fromstyle
toresolve
.copy
value for thewidth
option has been renamed tostyle
.Renamed
formatSelection
->templateSelection
formatResult
->templateResult
sortResults
->sorter
createSearchChoice
->createTag
selectOnBlur
->selectOnClose
ajax.jsonpCallback
->ajax.jsonp
ajax.results
->ajax.processResults
tags: [array,of,data]
->data: [array,of,data], tags: true
placeholderOption
has been replaced byplaceholder.id
(placeholder
->placeholder.text
)Internationalization
formatNoMatches
->language.noMatches
formatSearching
->language.searching
formatInputTooShort
->language.inputTooShort
formatInputTooLong
->language.inputTooLong
formatAjaxError
->language.errorLoading
formatLoading
->language.loadingMore
formatSelectionTooBig
->language.maximumSelected
Deprecated/Removed
initSelection
- This is no longer needed with<select>
tags. Limited backwards compatibility in the full build.id
- Data objects should now always haveid
andtext
attributes that are strings, use$.map
when migratingquery
- Use a custom data adapter instead. Limited backwards compatibility in the full build.ajax.params
- All parameters passed toajax
will be passed to the AJAX data transport functionMethods
Renamed
.select2("val", [value])
->.val([value])
.select2("enable", !disabled)
->.prop("disabled", disabled)
Removed
.select2("onSortStart")
and.select2("onSortEnd")
- A custom selection adapter should be created instead.select2("data", data)
- Create the<option>
tags for the objects that you would like to set, and set the.val
to select them.select2("readonly")
- There is no way to make a<select>
element read-only, disable it insteadEvents
New
select2:closing
is triggered before the dropdown is closedselect2:select
is triggered when an option is selectedRenamed
select2-close
is nowselect2:close
select2-open
is nowselect2:open
select2-opening
is nowselect2:opening
select2-selecting
is nowselect2:selecting
select2-removed
is nowselect2:unselect
select2-removing
is nowselect2:unselecting
Removed
select2-clearing
has been removed in favor ofselect2:unselecting
select2-highlight
select2-loaded
select2-focus
- Use the nativefocus
event insteadselect2-blur
- Use the nativeblur
event insteadchange
event were removedval
can be retrieved with$element.val()
insteadadded
can be retrieved by listening toselect2:select
removed
can be retrieved by listening toselect2:unselect