Class: OptionsSearch

Drupal.viewsUi. OptionsSearch

new Drupal.viewsUi.OptionsSearch($form)

Constructor for the viewsUi.OptionsSearch object.

The OptionsSearch object filters the available options on a form according to the user's search term. Typing in "taxonomy" will show only those options containing "taxonomy" in their label.

Name Type Description
$form jQuery

The form element.

Members

$formjQuery

options

Get a list of option labels and their corresponding divs and maintain it in memory, so we have as little overhead as possible at keyup time.

Methods

getOptions($allOptions){Array}

Assemble a list of all the filterable options on the form.

Name Type Description
$allOptions jQuery

A jQuery object representing the rows of filterable options to be shown and hidden depending on the user's search terms.

Returns:
Type Description
Array An array of all the filterable options.

Filter handler for the search box and type select that hides or shows the relevant options.

Name Type Description
event jQuery.Event

The formUpdated event.