2019-08-27 12:43:30 +00:00
|
|
|
# FieldContainer
|
|
|
|
|
2019-11-20 13:32:10 +00:00
|
|
|
Responsive form field container
|
|
|
|
|
|
|
|
### Usage
|
2019-08-27 12:43:30 +00:00
|
|
|
|
|
|
|
```js
|
2019-10-10 12:08:39 +00:00
|
|
|
import { FieldContainer } from "asc-web-components";
|
2019-08-27 12:43:30 +00:00
|
|
|
```
|
|
|
|
|
2019-11-20 13:32:10 +00:00
|
|
|
```jsx
|
2019-08-27 12:43:30 +00:00
|
|
|
<FieldContainer labelText="Name:">
|
2019-10-10 12:08:39 +00:00
|
|
|
<TextInput value="" onChange={e => console.log(e.target.value)} />
|
2019-09-04 09:17:55 +00:00
|
|
|
</FieldContainer>
|
2019-08-27 12:43:30 +00:00
|
|
|
```
|
|
|
|
|
2019-11-20 13:32:10 +00:00
|
|
|
### Properties
|
2019-08-27 12:43:30 +00:00
|
|
|
|
2019-11-20 13:32:10 +00:00
|
|
|
| Props | Type | Required | Values | Default | Description |
|
|
|
|
| ------------------------- | :---------------: | :------: | :----: | :-----: | ------------------------------------------------ |
|
|
|
|
| `isVertical` | `bool` | - | - | `false` | Vertical or horizontal alignment |
|
|
|
|
| `isRequired` | `bool` | - | - | `false` | Indicates that the field is required to fill |
|
|
|
|
| `hasError` | `bool` | - | - | `false` | Indicates that the field is incorrect |
|
|
|
|
| `labelText` | `string` | - | - | - | Field label text |
|
2019-11-25 08:49:30 +00:00
|
|
|
| `tooltipContent` | `object`,`string` | - | - | - | Tooltip content |
|
2019-11-25 09:00:40 +00:00
|
|
|
| `helpButtonHeaderContent` | `string` | - | - | - | Tooltip header content (tooltip opened in aside) |
|
2019-11-22 12:03:25 +00:00
|
|
|
| `horLabelWidth` | `string` | - | - | `110px` | Label width in horizontal alignment |
|