Skip to content

Input

import { Input } from 'yarcl';
<Input placeholder="Default" />
<Input size="lg" color="success" />
<Input disabled />
  • size sets the height, padding and font size. An input and a Button of the same size have the same height.
  • color sets the focus border and ring.
  • Inside a Field it’s labelled, described and marked invalid automatically.

Accepts every native <input> attribute except color and size, which are replaced by design tokens.

PropTypeDefaultDescription
colorColorconfigconfig.defaults.colorSemantic color, from the colors config.
radius'size' | Radiusconfigconfig.defaults.radiusBorder radius, from the radii config, or 'size' for the radius named like the control's size.
sizeSizeconfigconfig.defaults.sizeControl size, from the sizes config.