Dropdown Menu

The main dropdown menu component that manages state and positioning.

Read more Read less

Options

  • :id - Required unique identifier for the dropdown menu.
  • :open - Whether the dropdown is initially open. Defaults to false.
  • :use-portal - Whether to render the dropdown in a portal. Defaults to false.
  • :portal-container - CSS selector for the portal container. Defaults to nil.
  • :on-open - Handler for dropdown menu open event.
  • :on-close - Handler for dropdown menu close event.
  • :class - Additional CSS classes.
Attribute Type Documentation Default Value
Required id * :string

Unique identifier for the dropdown menu

open :boolean

Whether the dropdown menu is initially open

false
use-portal :boolean

Whether to render the content in a portal

false
portal-container :string

CSS selector for the portal container

on-open :any

Handler for dropdown menu open event

on-close :any

Handler for dropdown menu close event

class :string
rest :global
Required inner_block * :slot