General Configuration Options

Widgets are discrete blocks of content on a page or the header of an application. All widgets that are created using IBM® Watson Explorer Application Builder have some or all of the general configuration properties.

The following option is defined when you create a widget:
Type Description
Id The unique ID for this widget.
The following options can be defined when you create a widget, but may also be subsequently edited:
Type Description
Display name The title displayed in the header of the widget.

Default: the ID, displayed with an uppercase first letter for each word

Display conditions Ruby code that is evaluated to true or false to determine if the widget is displayed. The current entity can be accessed by using the variable subject, and the current user can be accessed by using the variable current_user. For example, the following checks to see if the position field of the current user entity is manager before the widget is displayed:
current_user.entity["position"].first == "manager"

Default: none (the widget is always displayed)

Asynchronously load content Allows the widget content to be loaded asynchronously to the loading of the application page using AJAX.

Default: off

Help text HTML help text displayed when the user clicks the help icon in the widget's header. For example:
<p>
This widget gives you information about the current <em>entity</em>.
</p>

Default: In most cases, no help text is shown by default.