# text.status

The state something is in, as a word in an outlined pill: Flying, Charging, On time. data-tone="success", "info", "pending", "warning", "danger" or "muted" colours it

Component: [`<Text>`](https://www.prongs.dev/docs/components/text.md) · Renders: `<span>` · Profile: [UI](https://www.prongs.dev/docs/intents/ui.md)

## Example

```tsx
<Text intent="text.status">Pack my box with five dozen liquor jugs.</Text>
```

## Choosing between neighbours

Find the row that describes your element, and use the intent on the right.

| If it is for… | Use |
|---|---|
| The state something is in, as a word in an outlined pill: Flying, Charging, On time. data-tone="success", "info", "pending", "warning", "danger" or "muted" colours it | `text.status` (this page) |
| A topic or category | [`text.topic`](https://www.prongs.dev/docs/intents/text/topic.md) |
| A status shown as a dot alone | [`text.indicator`](https://www.prongs.dev/docs/intents/text/indicator.md) |

## Connections

Declared in the registry, both directions. Where an intent is used in your own code is something check and the gallery see; this site has no app code.

- Built from: [`typography.label`](https://www.prongs.dev/docs/intents/ui.md#typography-label)

## For registry authors

**Starter intents.** These are the intents `prongs add` puts in your registry, shown in this site’s theme. Yours are your own `registry.ts`: rename, restyle and add to them, and see them with `prongs add gallery`.

What this intent is built from and its entry in `components/prongs/registry.ts`. You only need this to change how it looks or to add an intent like it.

How text.status resolves, and its definition

Each layer adds to the one before it; a later class wins over an earlier one that sets the same thing.

- [`typography.label`](https://www.prongs.dev/docs/intents/ui.md#typography-label) — Small, slightly heavy type for names of things

  ```
  text-sm
  ```

- `text.status` (this page) — The state something is in, as a word in an outlined pill: Flying, Charging, On time. data-tone="success", "info", "pending", "warning", "danger" or "muted" colours it

  ```
  inline-flex w-fit items-center whitespace-nowrap rounded-full
  border border-surface-border px-2.5 py-0.5 text-xs
  text-surface-muted data-[tone=muted]:border-surface-muted/35
  data-[tone=success]:border-success/25
  data-[tone=success]:text-success/75
  data-[tone=info]:border-info/25 data-[tone=info]:text-info/75
  data-[tone=warning]:border-warning/25
  data-[tone=warning]:text-warning/75
  data-[tone=pending]:border-pending/25
  data-[tone=pending]:text-pending/75
  data-[tone=danger]:border-destructive/25
  data-[tone=danger]:text-destructive/75
  ```

Final classes

```
inline-flex w-fit items-center whitespace-nowrap rounded-full
border border-surface-border px-2.5 py-0.5 text-xs
text-surface-muted data-[tone=muted]:border-surface-muted/35
data-[tone=success]:border-success/25
data-[tone=success]:text-success/75
data-[tone=info]:border-info/25 data-[tone=info]:text-info/75
data-[tone=warning]:border-warning/25
data-[tone=warning]:text-warning/75
data-[tone=pending]:border-pending/25
data-[tone=pending]:text-pending/75
data-[tone=danger]:border-destructive/25
data-[tone=danger]:text-destructive/75
```

Definition

```ts
'text.status': {
  kind: 'semantic',
  description: 'The state something is in, as a word in an outlined pill: Flying, Charging, On time. data-tone="success", "info", "pending", "warning", "danger" or "muted" colours it',
  refs: ['typography.label'],
  binding: {
    element: 'span',
    classes: 'inline-flex w-fit items-center whitespace-nowrap rounded-full border border-surface-border px-2.5 py-0.5 text-xs text-surface-muted data-[tone=muted]:border-surface-muted/35 data-[tone=success]:border-success/25 data-[tone=success]:text-success/75 data-[tone=info]:border-info/25 data-[tone=info]:text-info/75 data-[tone=warning]:border-warning/25 data-[tone=warning]:text-warning/75 data-[tone=pending]:border-pending/25 data-[tone=pending]:text-pending/75 data-[tone=danger]:border-destructive/25 data-[tone=danger]:text-destructive/75',
  },
  notFor: [
    { context: 'a topic or category', instead: 'text.topic' },
    { context: 'a status shown as a dot alone', instead: 'text.indicator' },
  ],
},
```
