Form

Form UI Component

Installation

npm i @synerise/ds-form
or
yarn add @synerise/ds-form

Usage

import Form from '@synerise/ds-form'
<Form />

Deprecated Features

The Form and EditableList components have been deprecated and replaced by EditableItemsList component. Please refer to the EditableItemsList documentation for more information on how to transition to the new component.

Demo

API

Form.FieldSet

PropertyDescriptionTypeDefault
headingHeading textstring-
classNameClass name applied to the elementstring-
descriptionDescription textstring-
withLineWhether divider should be displayedbooleanfalse

EditableList

PropertyDescriptionTypeDefault
firstInputProps*Enable overwriting first input propsAutocompleteProps / undefined-
secondInputProps*Enable overwriting second input propsInputProps / undefined-
validationEnable validation on first and second columnRecord<'validateLeftColumn' / 'validateLeftColumn', (val: string) => string / ReactNode / null-
addButtonConfigDefine props for buttonAddButtonConfigProps / undefined-
  • in order to overwrite f.e. styles in first two columns, it is possible to use spread operator used in component implementation, to overwrite style of third column it is required to import styled component wrapper and overwrite it