import React, { useState } from "react";
import FieldContainer from ".";
import TextInput from "../text-input";
export default {
title: "Components/FieldContainer",
component: FieldContainer,
argTypes: {
errorColor: { control: "color" },
},
parameters: {
docs: {
description: {
component: `Responsive form field container
### Properties
| Props | Type | Required | Values | Default | Description |
| ------------------------- | :---------------: | :------: | :----: | :-------: | ------------------------------------------------ |
| className | string | - | - | - | Accepts class |
| errorColor | string | - | - | ![#C96C27](https://placehold.it/15/C96C27/000000?text=+) #C96C27 | Error text color |
| errorMessageWidth | string | - | - | 320px | Error text width |
| errorMessage | string | - | - | - | Error message text |
| hasError | bool | - | - | false | Indicates that the field is incorrect |
| helpButtonHeaderContent | string | - | - | - | Tooltip header content (tooltip opened in aside) |
| id | string | - | - | - | Accepts id |
| isRequired | bool | - | - | false | Indicates that the field is required to fill |
| isVertical | bool | - | - | false | Vertical or horizontal alignment |
| labelText | string | - | - | - | Field label text |
| labelVisible | bool | - | - | true | Sets visibility of field label section |
| maxLabelWidth | string | - | - | 110px | Max label width in horizontal alignment |
| style | obj, array | - | - | - | Accepts css style |
| tooltipContent | object, string | - | - | - | Tooltip content |
`,
},
source: {
code: `import FieldContainer from "@appserver/components/field-container";