The UI section of the Fields framework, it consists on a FieldBuilder which receives the data from the backend and iterates through the elements in the object. Each field has the elements described in the FieldData Interface and the possible types are enumerated bellow.
FieldData Interface
Property | Type | Description |
---|
type | FieldTypes | Type of the field (Enum). |
field | string | Field name. |
label | string | Label for the field. |
display | any | [any] |
css_style | any | CSS style information. |
css_class | string | CSS class information. |
use_ellipses | boolean | Flag to indicate whether to use ellipses. |
sort | boolean | string |
only_on_highlight | boolean | Flag to show only when highlighted. |
show_blank | boolean | Flag to show when blank. |
[x: string] | any | Additional properties allowed. |
FieldTypes Enum
Name | Value |
---|
TEXT | 'text' |
URL | 'url' |
DATE | 'date' |
DATEAGE | 'date_age' |
NUMBER | 'number' |
SIZE | 'size' |
MIME_TYPE | 'mime_type' |
IMAGE | 'image' |
THUMBNAILS | 'thumbnails' |
BOOL | 'bool' |
NESTED | 'nested' |
KEYVALUE | 'key_value' |
KEYVALUETABLE | 'key_value_table' |
TAGS | 'tags' |
CHIP | 'chip' |
Each type has its own Functional Component defined at src/framework/fields/field-components which is where you may modify the way they're displayed at the screen.