Skip to main content

Introducing Workflow Engine, try for FREE workflowengine.io.

Class: PropertyAnnotation

Metadata for the component property for the form builder.

Extends

Constructors

new PropertyAnnotation()

new PropertyAnnotation(key, name): PropertyAnnotation

Creates metadata for a React component property.

Parameters

key: string

the property name.

name: string

the human-readable property name.

Returns

PropertyAnnotation

Inherited from

Annotation.constructor

Properties

bindingType?

readonly optional bindingType: ComponentPropertyBindType

The component property binding type.

Inherited from

Annotation.bindingType


calculable

readonly calculable: boolean = true

True if the property value can be a calculated property, false otherwise.

Inherited from

Annotation.calculable


data

data: LabeledValue[]

Possible values for the property.


default?

readonly optional default: any

The default property value.

Inherited from

Annotation.default


editor

readonly editor: string

The name of the component's property editor.

Inherited from

Annotation.editor


editorProps?

readonly optional editorProps: any

Additional properties for the component property editor.

Inherited from

Annotation.editorProps


errorMap?

readonly optional errorMap: ErrorMap

Message and/or error code for the validation function.

Inherited from

Annotation.errorMap


hint?

readonly optional hint: ReactNode

The hint for the component property.

Inherited from

Annotation.hint


key

readonly key: string

The component property key.

Inherited from

Annotation.key


localizable

readonly localizable: boolean = false

True if the property value can be localized, false otherwise.

Inherited from

Annotation.localizable


name

readonly name: string

The component property name.

Inherited from

Annotation.name


readOnly

readonly readOnly: boolean = false

True if the property value controls a read-only flag, false otherwise.

Inherited from

Annotation.readOnly


required

readonly required: boolean = false

True if the component property is required, false otherwise.

Inherited from

Annotation.required


slotConditionBuilder()?

readonly optional slotConditionBuilder: (props) => string

A function that returns a string containing the source code of the function to bind child components.

Parameters

props: any

the properties of the component, which are available only inside Form Builder Designer.

Returns

string

Inherited from

Annotation.slotConditionBuilder


type?

readonly optional type: keyof SchemaTypeMap

The data type for the value of the property.

Inherited from

Annotation.type


validator?

readonly optional validator: RuleValidator

The function for validating the property value.

Inherited from

Annotation.validator


valued

readonly valued: boolean = false

True if the property value is bound to form data, false otherwise.

Inherited from

Annotation.valued

Methods

clone()

clone(): any

Returns

any

the metadata clone.

Inherited from

Annotation.clone