Static Text Api
API exposed in all event handlers that can be used to communicate with Static Text components in the view. These functions are available under the `convenienceApi.staticTextHelper` namespace.
Methods
- retrieveAll() ⇒
Array.<Promise.<Object>>
| null
- Returns an array of Static Text component view-models.
- getValue(staticTextId) ⇒
Promise.<(String|null)>
- Returns a value of a given Static Text component.
- getHtmlElement(staticTextId) ⇒
Promise.<(Object|null)>
- Returns the HTML associated with a Static Text component.
- setIsHidden(staticTextId, isHidden) ⇒
Promise.<(Boolean|null)>
- Sets the visible property of a Static Text component.
- setValue(staticTextId, value) ⇒
Promise.<(String|null)>
- Sets value to a Static Text component.
Properties Details
retrieveAll() ⇒ Array.<Promise.<Object>>
| null
Returns an array of Static Text component view-models.
Returns: Array.<Promise.<Object>>
| null
- Array of promises that resolve to Static Text component ID and value.
getValue(staticTextId) ⇒ Promise.<(String|null)>
Returns a value of a given Static Text component.
Returns: Promise.<(String|null)>
- A promise that resolves to the value. Resolves to null if component is not found.
Param |
Type |
Description |
staticTextId |
Number | String |
ID of the Static Text component. |
getHtmlElement(staticTextId) ⇒ Promise.<(Object|null)>
Returns the HTML associated with a Static Text component.
Returns: Promise.<(Object|null)>
- A promise that resolves to the HTML element. Resolves to null if component is not found.
Param |
Type |
Description |
staticTextId |
Number | String |
ID of the Static Text component. |
setIsHidden(staticTextId, isHidden) ⇒ Promise.<(Boolean|null)>
Sets the visible property of a Static Text component.
Returns: Promise.<(Boolean|null)>
- A value of a Static Text component.
Param |
Type |
Description |
staticTextId |
Number | String |
ID of the Static Text component. |
isHidden |
Boolean
|
True if component should be hidden, false otherwise. |
setValue(staticTextId, value) ⇒ Promise.<(String|null)>
Sets value to a Static Text component.
Returns: Promise.<(String|null)>
- A value of a Static Text component.
Param |
Type |
Description |
staticTextId |
Number | String |
ID of the Static Text component. |
value |
String
|
A value to set. |