Style individual form controls and utilize common layouts.
<fieldset>s, WebKit validation bubbles, and most textual <input>s.<input>s are styled automatically, but .form-control is available should you need it.type on your <button>s.Form controls in Primer currently have no basic layout specified (this is by design). You’ll need to use <fieldset>s, <div>s, or other elements and styles to rearrange them.
</code>
Textual form controls have a white background by default. You can change this to a light gray with .input-contrast.
</code>
Make inputs smaller, larger, or full-width with an additional class.
</code>
</code>
</code>
Primer adds light height and vertical-align styles to <select>s for all browsers to render them consistently with textual inputs.
</code>
Use the .select-sm class to resize both default and custom <select>s to match the size of our small buttons.
</code>
</code>
Convey errors and warnings for form groups. Add the appropriate class—either .errored or .warn—to the <dl class="form-group"> to start. Then, house your error messaging in an additional <dd> with either .error or .warning.
</code>
Utilities to spice up the alignment and styling of checkbox and radio controls.
</code>
You may also add emphasis to the label:
</code>
Attached an input and button to one another.
</code>
Align buttons to the right—via float: right on the buttons—in forms with .form-actions. The floats are automatically cleared for you.
</code>