Interface: FormBuilderProps
Properties of the React Form builder component.
Extends
Omit<FormViewerProps,"view">
Properties
actions?
optionalactions:CustomActions
Custom actions for the form viewer.
Inherited from
Omit.actions
builderRef?
optionalbuilderRef:ForwardedRef<IFormBuilder>
The reference to IFormBuilder.
componentWrapper?
optionalcomponentWrapper:ComponentType<any>
The React component that wraps every component in a form. Internal use only.
Inherited from
Omit.componentWrapper
context?
optionalcontext:any
The arbitrary user context.
Inherited from
Omit.context
customization?
optionalcustomization:Partial<Record<string,Options>>
The map of customizations for the FormBuilder components.
disabled?
optionaldisabled:boolean
If true, the form is disabled.
Inherited from
Omit.disabled
errors?
optionalerrors:Record<string,unknown>
The form validation errors.
Inherited from
Omit.errors
errorWrapper?
optionalerrorWrapper:ComponentType<ErrorWrapperProps>
The default error wrapper used when errorType is not specified in the form.
Inherited from
Omit.errorWrapper
formName?
optionalformName:string
The form name. Updating the value triggers the FormViewerProps.getForm function.
Inherited from
Omit.formName
formOptions?
optionalformOptions:any
The form options. Used to transfer any options to the FormViewerProps.getForm function. Updating the value triggers the FormViewerProps.getForm function.
Inherited from
Omit.formOptions
formStorage?
optionalformStorage:IFormStorage
The external form storage.
formValidators?
optionalformValidators:FormValidators
The set of functions that validate the form data.
Inherited from
Omit.formValidators
generateJsonFormSchema()?
optionalgenerateJsonFormSchema: (options) =>string
The JSON schema generator for a form.
Parameters
options
the generator options.
Returns
string
the JSON schema in string format.
getForm()?
optionalgetForm: (name?,options?) =>string|Promise<string>
Loads the form.
Parameters
name?
string
the form name.
options?
any
the form options.
Returns
string | Promise<string>
the string or Promise with the form.
Inherited from
Omit.getForm
i18n?
optionali18n:FormBuilderI18n
The i18n data of the form builder.
initialData?
optionalinitialData:Record<string,unknown>
The initial data of the form.
Inherited from
Omit.initialData
jsonSchemaFilename?
optionaljsonSchemaFilename:string
The file name for the generated JSON schema.
language?
optionallanguage:`${string}-${string}`
The language of the form, e.g. 'en-US'.
Inherited from
Omit.language
licenseKey?
optionallicenseKey:string
The FormEngine license key.
localizationEngine?
optionallocalizationEngine:ILocalizationEngine
The localization engine used by the viewer.
Inherited from
Omit.localizationEngine
localize?
optionallocalize:ComponentLocalizer
The function to localize the properties of a component.
Inherited from
Omit.localize
localStoragePrefix?
optionallocalStoragePrefix:string
The prefix for localStorage keys.
onFormDataChange()?
optionalonFormDataChange: (data) =>void
The event is called whenever a form data changes.
Parameters
data
the IFormData with all the form data.
Returns
void
Inherited from
Omit.onFormDataChange
onFormSchemaChange()?
optionalonFormSchemaChange: (formSchema) =>void
The event is called whenever a form schema changes.
Parameters
formSchema
string
the current form schema serialized to JSON.
Returns
void
persistFormName?
optionalpersistFormName:boolean
If true, the form name will be saved to localStorage and restored when the Form builder is reopened. This functionality is enabled by default.
presetComponentOptions?
optionalpresetComponentOptions:IPresetComponentOptions
The preset component options.
propertyEditors?
optionalpropertyEditors:Record<string,ComponentType<AnnotationEditorProps>>
Custom component property editors. Attention! Unstable API.
readOnly?
optionalreadOnly:boolean
If true, the form is read-only.
Inherited from
Omit.readOnly
showAllValidationErrors?
optionalshowAllValidationErrors:boolean
If true, all validation errors will be displayed.
Inherited from
Omit.showAllValidationErrors
theme?
optionaltheme:FormBuilderTheme
Indicates the theme preference.
validators?
optionalvalidators:Partial<Record<keyofSchemaTypeMap,CustomValidationRules>>
The set of metadata of validation rules, grouped by the type of value being validated.
Inherited from
Omit.validators
view
view:
BuilderView
All the metadata of the components of the form builder.
viewerRef?
optionalviewerRef:ForwardedRef<IFormViewer>
The reference to IFormViewer.
Inherited from
Omit.viewerRef
viewMode?
optionalviewMode:ViewMode
Display resolution type.
Inherited from
Omit.viewMode