# `<alta-values-form>`

> The values a run needs (a name, a time zone, a key), checked as they are typed.

The values a run needs (a name, a time zone, a key), checked as they are typed.

[All components](https://docs.altasystem.ai/ui/components/)

## States

The closed list `data-state` takes on the element.

- <span id="state-pristine"></span>`pristine`
- <span id="state-editing"></span>`editing`
- <span id="state-invalid"></span>`invalid`
- <span id="state-valid"></span>`valid`
- <span id="state-submitting"></span>`submitting`
- <span id="state-submitted"></span>`submitted`

## Other attributes

On the element, or on a part (`part: attribute`). A list of values is closed.

| Attribute | On | Values |
|---|---|---|
| `data-kind` | `field` | `text`, `choice`, `email`, `path`, `number`, `boolean`, `secret` |
| `data-state` | `field` | `empty`, `filled`, `invalid`, `prefilled` |
| `data-required` | `field` | present or absent |

## Events

Dispatched on the element, bubbling. Listen with `addEventListener`.

- <span id="event-alta-values-change"></span>`alta-values-change`
- <span id="event-alta-values-valid"></span>`alta-values-valid`
- <span id="event-alta-values-submit"></span>`alta-values-submit`

## Parts

Every node you can style, as `[data-part="…"]`.

`form` · `field` · `label` · `control` · `hint` · `error` · `optional` · `prefilled-note` · `submit`

## Slots

Children with `slot="…"` replace or add to these places.

`field:<id>`

## Draws inside itself

[`<alta-choice-group>`](https://docs.altasystem.ai/ui/components/choice-group) · [`<alta-secret-field>`](https://docs.altasystem.ai/ui/components/secret-field)

## Style it

```css
[data-aui="values-form"][data-state="submitted"] [data-part="form"] { /* … */ }
```

## Words it reads

Keys of the string tables (override them on `<alta-provider>`).

`values.` · `ui.optional`

## Files

`packages/ui/src/elements/values-form.ts` · `packages/ui/styles/components/forms.css`
