2011-07-26 14:55:33 +00:00
<!doctype html>
< html >
< head >
2012-04-23 16:44:17 +00:00
< meta charset = "utf-8" >
2011-07-26 14:55:33 +00:00
< title > Menu Demo: Top-aligned Menu< / title >
2012-06-18 16:43:55 +00:00
< link rel = "stylesheet" href = "../demos.css" >
< link rel = "stylesheet" href = "../../themes/base/jquery.ui.all.css" >
2012-09-21 01:41:47 +00:00
< script src = "../../jquery-1.8.2.js" > < / script >
2012-04-23 16:29:18 +00:00
< script src = "../../ui/jquery.ui.core.js" > < / script >
< script src = "../../ui/jquery.ui.widget.js" > < / script >
< script src = "../../ui/jquery.ui.position.js" > < / script >
< script src = "../../ui/jquery.ui.menu.js" > < / script >
< script >
2011-07-26 14:55:33 +00:00
$(function() {
2012-06-18 16:43:55 +00:00
$( "#menu" ).menu({
2012-07-12 15:23:33 +00:00
position: { of: "ul:has(a.ui-state-focus):last" },
icons: {
submenu: "ui-icon-carat-1-e"
}
2011-07-26 14:55:33 +00:00
});
});
< / script >
< style >
2012-06-18 16:43:55 +00:00
.ui-menu { width: 200px; margin-bottom: 2em; }
2011-07-26 14:55:33 +00:00
< / style >
< / head >
< body >
2011-07-27 13:54:40 +00:00
2012-06-18 16:43:55 +00:00
< ul id = "menu" >
2011-07-26 14:55:33 +00:00
< li > < a href = "#" > Aberdeen< / a > < / li >
< li > < a href = "#" > Ada< / a > < / li >
< li > < a href = "#" > Adamsville< / a > < / li >
< li > < a href = "#" > Addyston< / a > < / li >
< li >
< a href = "#" > Delphi< / a >
< ul >
< li > < a href = "#" > Ada< / a > < / li >
< li > < a href = "#" > Saarland< / a > < / li >
< li > < a href = "#" > Salzburg< / a > < / li >
< / ul >
< / li >
< li > < a href = "#" > Saarland< / a > < / li >
< li >
< a href = "#" > Salzburg< / a >
< ul >
< li >
< a href = "#" > Delphi< / a >
< ul >
< li > < a href = "#" > Ada< / a > < / li >
< li > < a href = "#" > Saarland< / a > < / li >
< li > < a href = "#" > Salzburg< / a > < / li >
< / ul >
< / li >
< li >
< a href = "#" > Adamsville< / a >
< ul >
< li > < a href = "#" > Aberdeen< / a > < / li >
< li > < a href = "#" > Ada< / a > < / li >
< li > < a href = "#" > Adamsville< / a > < / li >
< li > < a href = "#" > Addyston< / a > < / li >
< li >
< a href = "#" > Delphi< / a >
< ul >
< li > < a href = "#" > Ada< / a > < / li >
< li > < a href = "#" > Saarland< / a > < / li >
< li > < a href = "#" > Salzburg< / a > < / li >
< / ul >
< / li >
< li > < a href = "#" > Saarland< / a > < / li >
< / ul >
< / li >
< li > < a href = "#" > Perch< / a >
< ul >
< li > < a href = "#" > Addyston< / a > < / li >
< li > < a href = "#" > Delphi< / a > < / li >
< li > < a href = "#" > Perch< / a > < / li >
< / ul >
< / li >
< / ul >
< / li >
< / ul >
2012-09-07 01:54:22 +00:00
< div class = "demo-description" >
2012-09-10 15:33:46 +00:00
< p > Menus can use custom positioning. There is a delay before activing an item on hover and a delay before closing a menu on mouse out to allow for moving to a submenu that is not touching its parent item.< / p >
2012-09-07 01:54:22 +00:00
< / div >
2011-07-26 14:55:33 +00:00
< / body >
< / html >