Shards React
DocumentationForm groups allow you to easily add structure to your forms.
import React from "react";
import { Form, FormGroup, FormInput } from "shards-react";
export default function FormGroupExample() {
return (
<Form>
<FormGroup>
<label htmlFor="username">Username</label>
<FormInput id="username" />
</FormGroup>
</Form>
);
}
The following props are available for the Form Group
component.
Prop | Description | Type | Default | Required |
---|---|---|---|---|
children | The children nodes. | Node | - | No |
row | Whether it is a row, or not. | Bool | - | No |
check | Whether it is a form check, or not. | Bool | - | No |
inline | Whether it is displayed inline (form check) or not. | Bool | - | No |
disabled | Whether it is disabled, or not. | Bool | - | No |
tag | The components' tag type. | String | "div" | No |
className | The class name. | String | - | No |