Button Widget
Enables the jQuery button functionality to an existing HTML element. By passing extra data attributes you can specify additional options for the widget.
jQueryUI Button API: http://api.jqueryui.com/button
Examples
The following example will initialize the button with the jQuery UI API option "disabled".
<button data-gx-widget="button" data-button-disabled="true">Disabled Button</button>
Equals to ...
$('button').button({ disabled: true });
The following example will initialize a button with custom jQuery UI icons by setting the "icons" option.
<button data-gx-widget="button"
data-button-icons='{ "primary": "ui-icon-triangle-1-s", "secondary": "ui-icon-triangle-1-s" }'>
jQuery UI
</button>
Note that if you ever need to pass a JSON object as an option the value must be a valid JSON string otherwise the module will not parse it correctly.
Requires
- module:jQueryUI-Library