Expand description
Labelled form fields, inputs, input groups, choice cards, and the error summary, from field.css and form-variants.css.
Re-exports§
pub use Field_completions::Component::Field;pub use Input_completions::Component::Input;pub use Textarea_completions::Component::Textarea;pub use NativeSelect_completions::Component::NativeSelect;pub use InputGroup_completions::Component::InputGroup;pub use InputAddon_completions::Component::InputAddon;pub use ErrorSummary_completions::Component::ErrorSummary;pub use Choice_completions::Component::Choice;
Structs§
- Choice
Props - Properties for the
Choicecomponent. - Error
Summary Props - Properties for the
ErrorSummarycomponent. - Field
Error - One problem listed in an
ErrorSummary. - Field
Props - Properties for the
Fieldcomponent. - Input
Addon Props - Properties for the
InputAddoncomponent. - Input
Group Props - Properties for the
InputGroupcomponent. - Input
Props - Properties for the
Inputcomponent. - Native
Select Props - Properties for the
NativeSelectcomponent. - Textarea
Props - Properties for the
Textareacomponent.
Enums§
- Input
Size - Input sizes.
- Input
Type - The HTML input types this library styles. Text is the default and is not written, as in upstream’s markup.
- Input
Variant - Input surface treatments.
- Necessity
- Whether a field is marked as required or optional.
Functions§
- Choice
- A radio drawn as a card with a title and description, inside a
CheckGroupgivenradios. - Error
Summary - The list of problems after a submit, linking to each field. It takes focus whenever it appears with errors, so keyboard and screen reader users land on it.
- Field
- A visible label, an optional hint and error, and one control, wired together.
- Input
- A single-line text input. Inside a
Fieldit is labelled automatically; anywhere else, give it anaria_label. - Input
Addon - Fixed text beside an input, such as a unit or a URL scheme.
- Input
Group - One box holding an
InputwithInputAddons before or after it. - Native
Select - A native
<select>styled as an input, for short fixed lists. Children areoptions. - Textarea
- A multi-line text input;
autosizegrows it with its content where supported.