Playground GitHub npm

Dialog Panel

Headless dialog card (no Scrim/mount) for your own overlay root.

ui overlay

Preview

Installation

npx slintcn@latest add dialog-panel

Usage

import { DialogPanel } from "slintcn/components/dialog-panel.slint";

// Headless: mount in your own overlay root, control visibility + centering.
DialogPanel {
    title: "Confirm your action";
    description: "This cannot be undone.";
    closed => { /* hide me */ }
}

Properties

title in string

Heading at the top of the panel.

description in string

Body text under the title.

close-label in string

Tooltip / accessible label for the X-close button.

trap-focus in bool

Tab-cycle focus inside the panel; set false to disable the trap.

closed callback ()

Fired when the X-close button is pressed.

API

Accessibility
focusableyes
keyboardTabEscape
focus trapyes
Escapedismisses

Dependencies

buttonseparatoriconlucide-paths

Installed automatically as transitive dependencies of slintcn add dialog-panel.