field.setStyles()
The API for setting field styles
Styles can be dynamically set on a field in your form via the Context API. Note that field styles that are set this way will only last for the current user session.
The following are
Style Attribute | Type | Description |
---|---|---|
|
| Width of the field |
|
| The unit of the width value |
|
| Height of the field |
|
| The unit of the height value |
|
| Font color of field |
|
| Is field font italicized |
|
| Font weight of field |
|
| Font size of field |
|
| Font family of field |
|
| Is font strike-through |
|
| Is font underlined |
|
| The font line height |
|
| The font letter spacing |
|
| CSS visibility style |
|
| Horizontal field alignment |
|
| Vertical field alignment |
|
| Horizontal offset (in pixels) of the field shadow |
|
| Vertical offset (in pixels) of the field shadow |
|
| Blur radius (in pixels) of the field shadow |
|
| Field shadow color |
|
| Field background color |
|
| Field background color when hovered |
|
| Field background color when selected or active |
|
| Background color when field is disabled |
|
| Font color when hovered |
|
| Font color when selected or active |
|
| Font color when field is disabled |
|
| Bottom padding of the field |
|
| Top padding of the field |
|
| Left padding of the field |
|
| Right padding of the field |
|
| Top left border radius |
|
| Top right border radius |
|
| Bottom left border radius |
|
| Bottom right border radius |
|
| Top border color |
|
| Right border color |
|
| Bottom border color |
|
| Left border color |
|
| Top border width in pixels |
|
| Right border width in pixels |
|
| Bottom border width in pixels |
|
| Left border width in pixels |
|
| The CSS top border style |
|
| The CSS right border style |
|
| The CSS bottom border style |
|
| The CSS left border style |
Other border styles | For hover styles, prefix the style with |
Last updated