Skip to content

Drawer

A panel that slides in from the right, left or bottom. Also a native <dialog>.

CSS + mian.js JSON Markdown Registry item

Edges

Filters

Menu

Share

Choose where to send this.

Installation

Everything ships in one stylesheet and one small script. There is nothing to import per component.

<link rel="stylesheet" href="https://mian.ro/dist/mian.css">
<script src="https://mian.ro/dist/mian.js" defer></script>

Prefer to own the files? /r/drawer.json is a registry item with this component's CSS and example markup, ready to copy into your project with any tool that reads the open registry-item format.

Class reference

Class / attributeDescription
dialog.mn-drawerRight side by default.
mn-drawer-left · mn-drawer-bottomOther edges.
mn-drawer-header · mn-drawer-body · mn-drawer-footerParts.

Accessibility

  • Same guarantees as Modal: focus trap, Escape, inert page, focus return.
Choose a noodle

Minimal

Flat

Pixel

Linear

Thin

Glass

Textured

Bold

Elegant

Rounded

On this page