Description
Menu component based on Yahoo UI menu widget
API
component-family |
net.sf.yui4jsf.Menu |
renderer-type |
net.sf.yui4jsf.component.MenuRenderer
|
component-class |
net.sf.yui4jsf.component.menu.Menu
|
renderer-class |
net.sf.yui4jsf.component.menu.MenuRenderer
|
tag-class |
net.sf.yui4jsf.component.menu.MenuTag
|
Usage
<yui:menu tiered="{true|false}">
<yui:submenu title="Mail">
<yui:menuitem text="Gmail" url="http://mail.google.com"></yui:menuitem>
<yui:menuitem text="Yahoo Mail" url="http://mail.yahoo.com"></yui:menuitem>
<yui:menuitem text="Hotmail" url="http://www.hotmail.com" target="_blank"></yui:menuitem>
</yui:submenu>
<yui:submenu title="Sports">
<yui:menuitem text="FIFA" url="http://www.fifa.com"></yui:menuitem>
<yui:menuitem text="NBA" url="http://www.nba.com"></yui:menuitem>
</yui:submenu>
<yui:submenu title="Videos">
<yui:menuitem text="YouTube" url="http://www.youtube.com"></yui:menuitem>
<yui:menuitem text="Google Video" url="http://video.google.com"></yui:menuitem>
</yui:submenu>
</yui:menu>
Attributes
<yui:menu>
Standard Attributes - id, rendered, binding
visible - Sets the element's "display" style property to either "block"(true) or "none" (false)
constrainToViewport - Boolean value to keep the menu inside the confines of the size of viewport
monitorResize - Boolean value that configures whether or not to create a hidden off-screen element that can be used to monitor for text size
changes in the DOM
x - Sets the element's "left" style property
y - Sets the element's "top" style property
fixedCenter - Boolean value that specifies whether the component should be automatically centered in the viewport on window scroll and
resize
width - Width of the menu in pixels
height - Height of the menu in pixels
zIndex - zIndex property of the menu
iframe - Boolean value to place an iframe to prevent other elements with a higher z-index from poking through (true by default for IE 6
and below)
tiered - Boolean value to specify the display mode of the submenus, when it's false submenus
are displayed at the same tier, when true they're displayed at a new tier, default value is false
autoSubmenuDisplay - Boolean indicating if submenus are automatically made visible when the user mouses over the menu's items
showDelay - Number indicating the time (in milliseconds) that should expire before a submenu is made visible when the user mouses over the menu's items
hideDelay - Number indicating the time (in milliseconds) that should expire before the menu is hidden
submenuHideDelay - Number indicating the time (in milliseconds) that should expire before a submenu is hidden when the user mouses out of a menu item heading in the direction of a submenu.
The value must be greater than or equal to the value specified for the "showdelay" configuration property
maxheight - Defines the maximum height (in pixels) for a menu before the contents of the body are scrolled
rootClass - CSS class to be applied to the root element of the menu
subMenuTitleClass - CSS class to be applied to the submenu titles
subMenuClass - CSS class to be applied to the submenu contents
itemClass - CSS class to be applied to the li elements of menuitems
itemLabelClass - CSS class to be applied to the anchor elements of menuitem
enableLogging - Enable Logging or not
Instructions
see menu.jsp and multitieredMenu.jsp for examples
Upcoming Features
- Programmatic setup as an alternative to the current declarative setup
Additional Information
NONE