Skip to content
On this page

Drawer

Basic

ADrawer component uses ACard as its base. Bind ADrawer with v-model to hide and show drawer/card.

All props & slots available in ACard is available in ADrawer.

Anchor

You can change the position of the drawer by providing the values left,right,top or bottom to the anchor prop.

Width

Use width utility classes to provide custom width to drawer. e.g. !w-[400px].

Persistent

You can disable closing drawer on outside click via persistent prop.

API

Drawer

modelValue : boolean

Show/Hide menu base on v-model value

variant : LayerVariant

Layer variant

states : boolean

Interaction states like hover & active

anchor : ADrawerAnchor

Drawer anchor/position

loading : boolean | ALoaderProps

Set loading state

titleTag : string

Tag to use for title of the component

subtitleTag : string

Tag to use for subtitle of the component

textTag : string

Tag to use for text rendered via text prop

persistent : boolean

Persistence of drawer when clicked outside of reference element

text : ConfigurableValue

Typography text content

color : ColorProp

Layer color

title : ConfigurableValue

Typography title

subtitle : ConfigurableValue

Typography subtitle

img : string

Render image at the top of the card (above header)

imgAlt : string

alt attribute for image rendered via img prop

default : any

Default slot for rendering card content

title : any

Render custom content for title

subtitle : any

Render custom content for subtitle

header-right : any

Render custom content on right side of title & subtitle. Content inside this slot will be vertically centered to title & subtitle.

update:modelValue => [value: boolean]

Released under the MIT License.