Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@aria-ui/listbox

Package Overview
Dependencies
Maintainers
0
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aria-ui/listbox

## Listbox

  • 0.0.15
  • npm
  • Socket score

Version published
Weekly downloads
2.1K
decreased by-6.47%
Maintainers
0
Weekly downloads
 
Created
Source

@aria-ui/listbox

Listbox

ListboxElement

A custom Listbox element.

new ListboxElement(): ListboxElement
PropertyTypeDescription
autoFocusboolean

Whether the listbox should automatically set the focus to the first item when the listbox is mounted or when the query changes.

Default

false
filternull | ItemFilter

The filter function to determine if an item should be shown in the listbox. By default, a simple case-insensitive substring match is used. You can provide a custom filter function to match against a more complex pattern. You can also pass null to disable filtering and allow all items to be shown.

Default

defaultItemFilter
onKeydownHandlerAddnull | (handler: (event: KeyboardEvent) => void) => VoidFunction

By default, the Listbox element will listen for keydown events. However, you can pass onKeydownHandlerAdd to override the default behavior. onKeydownHandlerAdd receives a keydown handler when the Listbox element is mounted, and returns a function that will be called when the Listbox element is unmounted.

Default

null
onValueChangenull | (value: string) => void

Event handler called when the value changes.

Default

null
querystring

The query string to filter the listbox items.

Default

""
selectionMode"multiple" | "single"

Listbox selection mode

(Currently only single selection mode is implemented)

Default

"single"
valuestring

The selected value.

Default

""

ListboxEmpty

ListboxEmptyElement

A custom ListboxEmpty element.

new ListboxEmptyElement(): ListboxEmptyElement

ListboxItem

ListboxItemElement

A custom ListboxItem element.

new ListboxItemElement(): ListboxItemElement
PropertyTypeDescription
onSelectnull | VoidFunction

The function to call when the item is selected.

Default

null
valuestring

The value of the item. Every item must have a unique value in the parent list.

Default

""

ListboxItemProps

PropertyTypeDescription
onSelectnull | VoidFunction

The function to call when the item is selected.

Default

null
valuestring

The value of the item. Every item must have a unique value in the parent list.

Default

""

FAQs

Package last updated on 21 Jun 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc