atom

gy-form-field

Labelled wrapper around a slotted form control that owns the label, description, error, and required indicator presentation.

Live

What you ship.

Markup

<gy-form-field label="Email" required>
  <input type="email" name="email" placeholder="you@example.com" />
</gy-form-field>

Prop space

Tier atom
Tag gy-form-field
PropTypeDefaultDescription
label *string no defaultThe visible label. Required — a control without one is a layout cell.
description string''Optional helper text rendered between the label and the control.
error string''Optional error message rendered below the control; collapses when empty.
required booleanfalseTrue to mark the field as required (surfaces a decorative `*` indicator).
inline booleanfalseTrue to render the label beside the control instead of above.

Slots: children.

Where this lives

import '@gyrum-labs/components/form-field/form-field.js';
Owner
gyrum-ui
Build state
registered-and-built