# <drawer-right>

A drawer that slides in from the right edge, for filters or details; open it with #id.open.

Category: Structure.

```ham
<screen>
    <app-bar title="Results"/>
    <drawer-right id="filters">
        <column style="p-16 gap-8">
            <text style="font-bold">Filters</text>
            <checkbox label="Open now"
                      color="teal"
                      checked="true"/>
            <checkbox label="Under $20"/>
        </column>
    </drawer-right>
    <main action-created="#filters.open">
        <column style="w-full p-16 gap-8">
            <text style="font-bold">24 restaurants nearby</text>
            <button action="#filters.open">Filters</button>
        </column>
    </main>
</screen>
```

How Hype Apps draws it on a phone: [light](https://hypeapps.dev/img/tags/drawer-right-light.webp), [dark](https://hypeapps.dev/img/tags/drawer-right-dark.webp).

## Attributes

| Name | What it does | Default |
|---|---|---|
| `bg-color` | Background color (theme-aware default) |  |
| `mode` | Drawer mode: overlay (Material) or slide (pushes content aside). (overlay, slide) | `overlay` |

## Commands

| Name | What it does |
|---|---|
| `close` | Close it. |
| `open` | Open the drawer. |
| `toggle` | Open/close. |

Any tag also takes gestures: `@on.tap`, `@on.longpress`, `@on.doubletap` and `@on.swipeleft` (and right, up and down). `@click` runs on a tap too.

## Related tags

- [`<app-bar>`](https://hypeapps.dev/docs/reference/app-bar.md): The bar at the top of a screen: a title, a leading menu icon, and action icons on the right.
- [`<column>`](https://hypeapps.dev/docs/reference/column.md): Stacks its children top to bottom, with a gap between them and an alignment across.
- [`<text>`](https://hypeapps.dev/docs/reference/text.md): A run of text; with @text it shows an expression that updates as its variables change.
- [`<checkbox>`](https://hypeapps.dev/docs/reference/checkbox.md): A checkbox with a label; its state goes into a variable by name.
- [`<button>`](https://hypeapps.dev/docs/reference/button.md): A tappable button that runs an action: a fetch, a navigation or a statement.
- [`<drawer-header>`](https://hypeapps.dev/docs/reference/drawer-header.md): The header at the top of a side drawer, such as the signed-in person's photo and name.
- [`<drawer-left>`](https://hypeapps.dev/docs/reference/drawer-left.md): A drawer that slides in from the left edge, opened by the menu icon or #id.open.
- [`<list-tile>`](https://hypeapps.dev/docs/reference/list-tile.md): A Material list row with an icon, a title, a subtitle and an optional switch, checkbox or radio.

All tags: https://hypeapps.dev/docs/reference.md · The full reference: https://hypeapps.dev/llms.txt
