Getting Started

Documentation

Modal

Display dialogs with bound state, component methods and optional header and footer content.

Bound state

Component methods

Header, footer and close options

Size and centering

The full example uses a viewport-height split layout, like UIkit's full modal example.

Stacked dialogs

Lifecycle events and cancellation

The default slot provides the body. The optional header slot replaces the title header; footer adds a footer.

Use title or label to give the dialog a meaningful accessible name.

Methods (via bind:this)

NameDescriptionType Default
show() Requests opening the dialog. Promise<boolean> -
hide() Requests closing the dialog. Promise<boolean> -
toggle() Switches the requested open state. Promise<boolean> -

Methods return UIkit's result. Use shown and hidden to observe completed animations.

Options & Events

Getting Started

Documentation