Input

Text inputs with four variants, plus Password, Search and TextArea built in.

Import#

import { Input, InputGroup } from "astralis-ui";
// Input.Password, Input.Search, Input.TextArea

Variants#

outline
filled
underline
unstyled

Password, Search and TextArea#

Input.Password manages its own visibility toggle; Input.Search fires onSearch on Enter (or its optional button); Input.TextArea adds a character counter via showCount + maxLength.

0/120

Prefix and suffix#

Wrap in InputGroup for decorative slots on either side — the input pads itself automatically.

.astralis.dev

Props#

Inputs accept all native attributes of their element, plus:

PropTypeDefaultDescription
variant"outline" | "filled" | "underline" | "unstyled""outline"Visual style.
size"sm" | "md" | "lg""md"Height and padding.
invalid / disabled / readOnlybooleanfalseState flags — inherited automatically inside a Field.
Sub-componentExtra props
Input.SearchonSearch(value), showSearchButton
Input.TextArearows, maxLength, showCount
InputGroupprefix, suffix (non-interactive slots)

Accessibility#

State flags map to aria-invalid / aria-readonly, and a wrapping Field wires the label and ids for you.