This package includes components relating to native form fields in the Garden Design System.
npm install @zendeskgarden/react-forms
# Peer Dependencies - Also Required
npm install react react-dom prop-types styled-components @zendeskgarden/react-theming
/**
* Include forms styling at the root of your application
*/
import '@zendeskgarden/react-forms/dist/styles.css';
import { ThemeProvider } from '@zendeskgarden/react-theming';
import { Field, Label, Hint, Input, Message } from '@zendeskgarden/react-forms';
/**
* Place a `ThemeProvider` at the root of your React application
*/
<ThemeProvider>
<form>
<Field>
<Label>Example Text Input</Label>
<Hint>Hint text</Hint>
<Input placeholder="Accepts all native input props" />
<Message>Default message styling</Message>
</Field>
</form>
</ThemeProvider>;