# toastStackStyle

> The peek stack a toast region draws: older toasts fold behind the newest, scaled to 0.95 and 0.9 and nudged out by `--ui-toast-peek`, then fan out into a list while the pointer or focus rests on the region.

```ts
import { toastStackStyle } from "@sdxc/ui/app";
```

Styles a toast region's children as a capped peek stack. The newest toast
is the last child; children past `max` from the end take no space, and
folded toasts match the front one's height through `--ui-toast-front-size`.

## Signature

```ts
toastStackStyle<Node extends Element = Element>(max: number): MixinDescriptor<Node, [styles: CSSStyles], ElementProps>
```

Returns: A mixin ready for the region element's `mix` prop.

## Parameters

| Parameter | Type | Description |
| --- | --- | --- |
| `max` | `number` | Most toasts shown at once. |

## Examples

```tsx
<div data-stack="peek" data-placement="bottom-end" mix={[toastStackStyle(3)]}>{toasts}</div>
```
