Sorry, but you either have no stories or none are selected somehow.
If the problem persists, check the browser console, or the terminal you've run Storybook from.
The component failed to render properly, likely due to a configuration issue in Storybook. Here are some common causes and how you can address them:
Used for regular text input. For an array of data or tree-structured data, consider using Select
or Cascader
respectively.
To add more context to the input you can add either text or an icon before or after the input. You can use the prefix
and suffix
props for this. Try some examples in the Preview!
<Input prefix={<Icon name="search" />} />
Input
should be used with the Field
component to get labels and descriptions. It can also be used for validation by using the required
attribute. See the Field
component for more information.
<Field label="Important information" description="This information is very important, so you really need to fill it in"> <Input name="importantInput" required /> </Field>
Name | Description | Default |
---|---|---|
width | Sets the width to a multiple of 8px. Should only be used with inline forms. Setting width of the container is preferred in other cases. number | - |
prefix | Show an icon as a prefix in the input ReactNode | - |
invalid | Show an invalid state around the input boolean | - |
suffix | Show an icon as a suffix in the input ReactNode | - |
loading | Show a loading indicator as a suffix in the input boolean | - |
addonBefore | Add a component as an addon before the input ReactNode | - |
addonAfter | Add a component as an addon after the input ReactNode | - |