From ProtoScript
Contents |
YUI:Show Behavior
Changes the visibility of an element or elements on the page from hidden to shown (if already visible, nothing changes). Opposite of the Hide Behavior.
Example
$proto('img#avatar', {
Click: {
onClick: {
Show: {}
}
}
});
When the user clicks on the avatar (an image with ID='avatar'), changes it's visibility to 'visible' (causing it to be shown on the page if it was not visible before).
Attributes
| Name | Description | Default | Valid Values | Example |
|---|---|---|---|---|
| target | Selected element or elements to show. | String value denoting an interface element. See Selecting Elements | No value. If no value supplied, use the last targeted element. If value is supplied, use the element(s) selected by the target instead. See Element Scope | Show: {} |
Callbacks
| Name | Description |
|---|---|
| onShow | The callback corresponding to the Show behavior. Fired after the element has been shown. |
Demos
See Show Demo
