# <background>

The layer a swiped dismissible row reveals behind it, such as a red delete strip.

Category: Layout.

```ham
<dismissible direction="left">
    <background style="bg-red flex-row justify-end items-center px-16">
        <icon name="delete white"/>
    </background>
    <row style="p-16 bg-white dark:bg-gray-900 gap-12 items-center">
        <icon name="mail"/>
        <text>Swipe left to delete this message</text>
    </row>
</dismissible>
```

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

## Attributes

| Name | What it does | Default |
|---|---|---|
| `autoscroll-delay` | Autoscroll delay in seconds | `0.0` |
| `autoscroll-loop` | Whether autoscroll loops | `false` |
| `autoscroll-restart` | Autoscroll restart delay in seconds, or 'false' to disable |  |
| `autoscroll-speed` | Autoscroll speed in pixels per second |  |
| `autoscroll-target` | page: scroll the screen; self: scroll inside this box (give it a height). parent is accepted as self. (page, self) | `page` |
| `side` | Edge this layer belongs to: left/start shows while swiping right, right/end while swiping left. Default both. (left, start, right, end) |  |
| `swipe` | The same, named by the swipe that reveals it: swipe="left" = side="right". (left, right) |  |

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.

## Guides and recipes that use it

- [Data and databases](https://hypeapps.dev/docs/guides/data.md)

## Related tags

- [`<dismissible>`](https://hypeapps.dev/docs/reference/dismissible.md): A list row you swipe away, as in a mail app, revealing a layer behind it as it moves.
- [`<icon>`](https://hypeapps.dev/docs/reference/icon.md): A Material Symbols icon, with its style, weight, size and color set in its name.
- [`<row>`](https://hypeapps.dev/docs/reference/row.md): Lays children side by side in one line; flex= shares the free space and align/cross position them.
- [`<text>`](https://hypeapps.dev/docs/reference/text.md): A run of text; with @text it shows an expression that updates as its variables change.
- [`<address>`](https://hypeapps.dev/docs/reference/address.md): Contact details as a block, in italic by default, as HTML's address element.
- [`<aside>`](https://hypeapps.dev/docs/reference/aside.md): A side note set apart from the main text, as HTML's aside element; it works like a block.
- [`<block>`](https://hypeapps.dev/docs/reference/block.md): The general-purpose container: groups children and gives them padding, color, corners and a border.
- [`<card>`](https://hypeapps.dev/docs/reference/card.md): A surface for grouped content, with padding, rounded corners and a soft shadow.

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