# Skeleton

Placeholders that hold space while real content loads.

- **Use it for**: Holding the space of content while it loads, to avoid layout jumps.
- **Not for**: Background work unrelated to visible content. Try [LoadingIndicator](https://unseenui.com/components/loading-indicator/).

## Installation

```bash
npm install @stackunseen/ui
```

## Usage

```tsx
import { Skeleton } from '@stackunseen/ui';
import '@stackunseen/ui/styles.css';

<Skeleton variant="shimmer" label="Loading answer" lines={3} />
```

## All props

| Prop | Type | Description |
| --- | --- | --- |
| `label` | `string` |  |
| `lines` | `number` |  |
| `shape` | `"text" \| "card" \| "avatar"` |  |
| `variant` | `"shimmer" \| "pulse" \| "static"` |  |

## Keyboard

Tab reaches controls; Enter or Space activates buttons. Accordions use arrow keys, Home and End. Select menus support arrows and typeahead; Escape closes menus and dialogs and restores focus.

## Works with

[Alert](https://unseenui.com/components/alert/), [EmptyState](https://unseenui.com/components/empty-state/), [Progress](https://unseenui.com/components/progress/), [Toast](https://unseenui.com/components/toast/), [LoadingIndicator](https://unseenui.com/components/loading-indicator/), [StatusBadge](https://unseenui.com/components/status-badge/)

Page: https://unseenui.com/components/skeleton/
