This also gets rid of the colored buttons in favor of `.btn-default`, prevents wrapping of the "Destroy" button of the first button group of the "Programmatic access" demos to a second line and consistently places buttons below the Select2 widgets they apply to.
Ref. http://getbootstrap.com/components/#btn-groups.
Adds
* version information
* links to the GitHub repository, issues and releases
* links to the examples and options
* a link to the 3.5.2 docs
to the footer as well as namespaced styles for the footer in general as well as all the above.
* adds styles for anchor.js (similar to the official Bootstrap docs)
* currently results some of the generated links to have a suffix (e. g. examples.html#templating-1) added due to sections having the same ID as the headline copy that we want to link to
Since Select2 methods should not be called on an element where
Select2 has not yet been initialized, this raises an error when it
happens. This does not silence the original error, but it does
provide the user with some more context about why they are seeing
a TypeError.
This closes https://github.com/select2/select2/issues/3173.
We now check that the `abort` method actually exists before aborting
the request, as JSONP does not include the `abort` method because
a JSONP request technically cannot be aborted.
This closes https://github.com/select2/select2/issues/3217.
This adds back keyboard support, so you can now clear a selected
item using either the backspace or delete key. This only work when
the container is closed, to prevent issues with the selection being
clear while a user is searching.
This was a regression in accessibility from 3.x.
This closes https://github.com/select2/select2/issues/3224.
Slight performance hit as we are no longer using `qurySelectorAll`,
but it handles the situation a bit more cleanly and prevent future
issues with special characters.
This closes https://github.com/select2/select2/issues/3157.
This fixes the results display so they prefer the `selected`
property on objects over checking if the `id` matches the value of
the underlying select.
We only ignore the `selected` property if it is null, at that point
we compare against the `id` property.
This closes https://github.com/select2/select2/issues/3163.
This also fixes an issue where we were using the `full_name` for
the value instead of the `id` in the example, which technically
wasn't correct.
This closes https://github.com/select2/select2/issues/3148.
In the past, `initSelection` was used for loading in data objects
for the pre-selected options. Now that Select2 is using a `<select>`
element, there is no need for doing this because the `<option>`
elements should provide the relevant information. So you can now
just pull this information from the remote data source
(or static array, in some cases) and build out the `<option>`
elements manually.
In most cases you don't need to go the full length with a custom
data adapter, but instead are just looking to pre-load elements on
the initial page load.
This improves https://github.com/select2/select2/issues/3116.