View Source

h1. checkboxButton:

NOTE that rendering with class="ice-skin-sam" renders this component as a checkbutton (use label attr with labelPosition="on")
with class="ice-skin-rime" it is rendered as a checked box (use labelPosition="left")

 page should look like:

{code:xml}<html xmlns:ice="http://www.icefaces.org/icefaces/components"
..>
<!-- can use either ice-skin-sam or ice-skin-rime -->
<h:body class="ice-skin-rime">
<h:form >
<ice:checkbox />
<h:form>
<h:body>
<html>
{code}

{code:xml} <h:panelGroup id="overPanel" styleClass="ice-skin-sam">
<ice:checkboxButton id="chkbox" label="button1"
              labelPosition="on" value="#{button.checked}"
singleSubmit="false"/>
</h:panelGroup>
{code}
or
{code:xml} <h:panelGroup id="overPanel" styleClass="ice-skin-rime">
<ice:checkboxButton id="chkbox" label="apple"
labelPosition="left" value="#{button.checked}"
singleSubmit="true"/>
</h:panelGroup>
{code}
h2. Additional attributes(same as pushbutton except for):

*&nbsp;Defining the submission behaviour:*
&nbsp;When singleSubmit attribute is true, the checkbox only submits an event request a submit call with execute=@this and render=@all, if false then only the hidden field is updated on the client and some other component must submit the form for the server model side to be updated.

3. Keyboard short-cuts supported by pushbutton:

* space will toggle the checkbox/checkbutton

&nbsp;Aria role="button", aria-describedby and aria-disabled properties supported as well as aria-checked.

h4. Storyboard

|| Action || focus || hover || checked || disabled || onkeypress || aria ||
|| yui-class | yui-button-focus | yui-button-hover | yui-button-checked | yui-button-disabled | space or enter will submit | role, disabled, description, checked ||
|| Submit | | | submit button &update component | none | submit button/update component | ||
|| Single Submit | | | stay on client/update hidden field | none | update hidden field | ||
|| Screen Reader | description | description | role,description, checkedvalue | role | & checked value | ||