Primitives
Input
A single-line text field, drawn on the ground rather than on a surface so it reads as a well cut into the panel it sits in.
It takes the control outline weight and no block: a block would make it look pressable, and the thing you press is the button next to it. The placeholder is the faint ink, so an empty field never reads as a filled one. An input is full-width by default - give the wrapper the measure you want rather than the field.
It is used at two scales, which is what --axi-input-pad and
--axi-input-size are for: the 14px default is a form control standing on a
page, and a filter in a section header or a row in a bar wants the smaller
one, because there it is furniture beside the reading rather than the thing
the page is for. .axi-palette__bar is the one place upstream needs it, and
it spends the knobs rather than redeclaring the properties.
A labelled field
<label class="axi-sr-only" for="input-demo">Squad name</label>
<input class="axi-input" id="input-demo" placeholder="Squad name…" style="max-width: 260px">
A multi-line field
Not a separate component - the same class, on a textarea. Resizing is vertical only, so a drag cannot break the form's column<textarea class="axi-input" style="--axi-textarea-h: 120px" placeholder="What happened on this pull?"></textarea>
Knobs
| Property | Sets | Fallback |
|---|---|---|
--axi-textarea-h | the minimum height of a <textarea class="axi-input"> | 90px |
--axi-input-pad | the padding inside an .axi-input, for a field that is furniture in a header rather than a control on a page | 11px 12px |
--axi-input-size | an .axi-input's text size, which travels with its padding | 14px |