Elemental.Dropdown (elemental v0.2.0)

An abstraction around DaisyUI's dropdown.

Think of it as a more advanced Elemental.Select with support for multi-select and searching out of the box.

This is implement in a manner that works drop-in in forms and uses only dead/stateless components with minimal JavaScript.

Usage

Make sure in your application to include the required JavaScript hooks required for the main behaviour, found in dropdown.js.

See the hooks section for more details.

Most basic usage is done by simply passing it options

<.dropdown options={["Foo", "Bar"]}/>

See dropdown/1 for details on the support properties and their behaviour.

JavaScript hooks

This implementation requires JavaScript hooks for it's main behaviour, utilizes 3 main hooks

  • ElementalDropdownSearch implementing filtering/search behaviour when enabled.
  • ElementalDropdownSingleItem implementing prompt changes when using single item mode.
  • ElementalDropdownMultiItem implementing prompt changes when using multi item mode.

##

Summary

Functions

The primary dropdown component.

Functions