Info Text¶
A display-only option which shows a text in the app. It has no input to configure, it is only meant to provide information to the user.
Tag¶
"type": "info"
Values¶
The info type supports the following values:
text¶
The text which will be displayed. Newlines can be added with \n inside the string, they will be rendered as line breaks. The text may also contain HTML tags, which will be interpreted by the app.
variant¶
The style of the displayed text. Defaults to info, which renders the text as an info colored alert box. Any bootstrap-vue alert variant can be used, e.g. warning, danger or success. Use plain to render the text as a plain paragraph without any styling.
collapsible¶
A boolean which defaults to false. When set to true, the name of the option becomes a toggle with which the text can be collapsed and expanded. The text is expanded initially.
Note
This value requires the name tag of the option to be set.
collapsed¶
A boolean which defaults to false. When set to true, the text is collapsed initially. This implies collapsible.
Note
This value requires the name tag of the option to be set.
Argument Passed to the Device¶
This option does not pass any value to the device.
Note
This is a special type. It does not pass any value to device.execute. Thus you must not add a parameter there.
Example¶
This example shows how this type of option will look in the webapp.
Option configuration¶
{
"name": "Safety instructions",
"type": "info",
"id": "info-1",
"values": {
"text": "Make sure the motor is mounted before starting a test.\nWear ear protection when running speed tests above 1000 rpm.",
"variant": "warning",
"collapsible": true
}
}
Result¶
