Quantcast
Channel: Issues for Drupal core
Viewing all articles
Browse latest Browse all 293211

Replace jQuery UI autocomplete with Select2

$
0
0

Problem/Motivation

Improve usability and accessibility of long select lists and autocomplete tagging widgets.

Proposed resolution

Use Select2 for tags and autocomplete stuff.

Patch is almost ready, it just needs a new Select2 tokenizer that supports our "tag with, comma" syntax.

FAPI is not going to be changed, but since the latest version of Select2 only works with <select>, we need to add javascript to convert our <input type="text"> used for free tagging, to a <select>. We probably also need a submit handler in javascript that changes it back to a normal text field so our PHP code keeps working. We cannot solve this on the PHP side, since it will not work without javascript.

Remaining tasks

User interface changes

Yes.

API changes

Is this still a relevant change: The return value expected by the autocomplete API changes from array('value' => $value, 'label' => $label) to array('id' => $value, 'text' => $label).

Beta phase evaluation

Reference: https://www.drupal.org/core/beta-changes
Issue categoryTask because it is a usability improvement of various UI pieces which are already in core
Issue priorityMajor because it greatly improves usability of long select lists (language selection in the installer, timezone selection, etc.) and Entity Reference's autocomplete widgets
Prioritized changesThe main goal of this issue is usability and accessibility improvements.
DisruptionSmall disruption for contributed and custom modules that implement Drupal's autocomplete API because it will require a BC break.

Viewing all articles
Browse latest Browse all 293211

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>