Extended features
Example using the Form.Handler collecting data with onSubmit
:
import { Form, Field, Value } from '@dnb/eufemia/extensions/forms'render(<Form.Handler data={existingData} onSubmit={submitHandler}><Field.Email path="/dataPath" /><Value.Date value="2023-01-16" /><Form.SubmitButton /></Form.Handler>,)
Example using the StepsLayout for handling stepped layouts:
import { StepsLayout } from '@dnb/eufemia/extensions/forms'render(<StepsLayout><StepsLayout.Step title="Name"><Form.MainHeading>Profile</Form.MainHeading></StepsLayout.Step></StepsLayout>,)
Components
Form
Form
provides the main forms-helpers including data provider and event handling.
Iterate
Iterate
is components and functionality for traversing values and parts of data sets such as arrays, which contain a varying number of elements where the number of components on the screen depends on how many elements the data consists of.
StepsLayout
StepsLayout
is a wrapper component for showing forms with a StepIndicator for navigation between several steps. It also includes components for navigating between steps.
Visibility
Visibility
makes it possible to hide components and elements on the screen based on the dynamic state of data.