# Typing Indicator (/docs/agent-ui/components/typing-indicator)

Use a typing indicator where the agent's next message will appear, until its first words arrive. The bubble shows no text, so its label is only for screen readers.

<Example caption="The dots flow while the assistant types. With reduced motion on, they hold still.">
<g />

```tsx
import { TypingIndicator } from "@/components/ui/typing-indicator";

export default function TypingIndicatorExample() {
  return <TypingIndicator label="Assistant is typing" />;
}
```
</Example>

## Installation [#installation]

```bash tab="React"
npx shadcn@latest add @kind-ui/typing-indicator
```

```bash tab="Web Components"
npx shadcn@latest add @kind-ui/typing-indicator-web
```

## Usage [#usage]

### Label [#label]

Pass `label` to say who's typing. It names the indicator, "Typing" by default, and stays hidden on screen. The indicator is a polite status, so screen readers read a new label when it changes. The dots are hidden from them.

### Motion [#motion]

The dots flow one after another. Under `prefers-reduced-motion`, or with `motion="reduced"` or `"none"`, they hold still. The indicator takes no focus and has no keys.

## API Reference [#api-reference]

### IndicatorOptions

| Prop      | Type                            | Description                                                                                                                                                       |
| --------- | ------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `label?`  | `string \| undefined`           | Names the status, and screen readers read it again when it changes. Loader and Thinking Indicator also show it; it defaults to "Loading", "Thinking" or "Typing". |
| `motion?` | `"auto" \| "none" \| "reduced"` | Whether the dots move: `"auto"` follows `prefers-reduced-motion`, and `"reduced"` or `"none"` hold them still. Default: `"auto"`                                  |

### Agent [#agent]

An agent connected with `createAgent` sees the typing indicator as a status named by its label. It has no actions of its own.

<Caption>
Runs in React and Web Components. On `<kind-typing-indicator>`, `label` and `motion` are attributes of the same name, and the element fills in its label and dots when it has no children.
</Caption>