PyBlade/ui
Menu⌄
DocsComponentsSheet

Sheet

A panel that slides in from an edge of the screen.

Alpine.jsdepends on button6 files

Installation

pyblade-ui add sheet

Usage

The tags <pb-ui.sheet> <pb-ui.sheet-header> <pb-ui.sheet-footer> <pb-ui.sheet-title> <pb-ui.sheet-description> <pb-ui.sheet-close> are available in all your templates.

<pb-ui.sheet side="right">
  <pb-slot:trigger><pb-ui.button variant="outline">Open</pb-ui.button></pb-slot:trigger>
  <pb-ui.sheet-header>
    <pb-ui.sheet-title>Edit profile</pb-ui.sheet-title>
    <pb-ui.sheet-description>Save when you are done.</pb-ui.sheet-description>
  </pb-ui.sheet-header>
  <pb-ui.sheet-footer>
    <pb-ui.sheet-close><pb-ui.button variant="outline">Close</pb-ui.button></pb-ui.sheet-close>
  </pb-ui.sheet-footer>
</pb-ui.sheet>
{# Or from anywhere: $dispatch('sheet-open', 'name') #}

Examples

Sides

Props

PropDefault
name''
trigger''
side'right'
openFalse

Any other attribute (class, id, x-on:click, hx-post…) is passed to the root element; your Tailwind classes win over the component's.