diff options
author | Scott González <scott.gonzalez@gmail.com> | 2011-01-14 14:35:37 -0500 |
---|---|---|
committer | Scott González <scott.gonzalez@gmail.com> | 2011-01-14 14:35:37 -0500 |
commit | 66606407edf9faa33c566f0cc6a2bb1dd4d3e808 (patch) | |
tree | d404ba5808418cb55435d914008cd88ced3851ed /demos | |
parent | 1b2f6ce0955f2a08a2e52c688f23335423179cf1 (diff) | |
download | jquery-ui-66606407edf9faa33c566f0cc6a2bb1dd4d3e808.tar.gz jquery-ui-66606407edf9faa33c566f0cc6a2bb1dd4d3e808.zip |
Accordion: Force the width of the accordion panel during animation when animating from a fully collapsed state. Fixes #5540 - Accordion: Jumpy animation when opening a panel after closing all.
The animation code should be refactored.
Diffstat (limited to 'demos')
-rw-r--r-- | demos/accordion/default.html | 93 |
1 files changed, 27 insertions, 66 deletions
diff --git a/demos/accordion/default.html b/demos/accordion/default.html index 974dc0569..c2774c549 100644 --- a/demos/accordion/default.html +++ b/demos/accordion/default.html @@ -4,82 +4,43 @@ <meta charset="utf-8"> <title>jQuery UI Accordion - Default functionality</title> <link rel="stylesheet" href="../../themes/base/jquery.ui.all.css"> - <script src="../../jquery-1.4.4.js"></script> + <script src="http://code.jquery.com/jquery-git.js"></script> <script src="../../ui/jquery.ui.core.js"></script> <script src="../../ui/jquery.ui.widget.js"></script> <script src="../../ui/jquery.ui.accordion.js"></script> <link rel="stylesheet" href="../demos.css"> + <style type="text/css"> +#accordion { + width: 600px; +} +</style> <script> - $(function() { - $( "#accordion" ).accordion(); + $(function(){ + + $("#accordion").accordion({ + autoHeight: false, + active: false, + collapsible: true + }); + }); </script> </head> <body> -<div class="demo"> - -<div id="accordion"> - <h3><a href="#">Section 1</a></h3> - <div> - <p> - Mauris mauris ante, blandit et, ultrices a, suscipit eget, quam. Integer - ut neque. Vivamus nisi metus, molestie vel, gravida in, condimentum sit - amet, nunc. Nam a nibh. Donec suscipit eros. Nam mi. Proin viverra leo ut - odio. Curabitur malesuada. Vestibulum a velit eu ante scelerisque vulputate. - </p> - </div> - <h3><a href="#">Section 2</a></h3> - <div> - <p> - Sed non urna. Donec et ante. Phasellus eu ligula. Vestibulum sit amet - purus. Vivamus hendrerit, dolor at aliquet laoreet, mauris turpis porttitor - velit, faucibus interdum tellus libero ac justo. Vivamus non quam. In - suscipit faucibus urna. - </p> - </div> - <h3><a href="#">Section 3</a></h3> - <div> - <p> - Nam enim risus, molestie et, porta ac, aliquam ac, risus. Quisque lobortis. - Phasellus pellentesque purus in massa. Aenean in pede. Phasellus ac libero - ac tellus pellentesque semper. Sed ac felis. Sed commodo, magna quis - lacinia ornare, quam ante aliquam nisi, eu iaculis leo purus venenatis dui. - </p> - <ul> - <li>List item one</li> - <li>List item two</li> - <li>List item three</li> - </ul> + <div id="accordion"> + <h3><a href="#section1">Header</a></h3> + <div> + <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec dapibus eleifend odio. Suspendisse porta pretium urna, vitae euismod turpis pharetra elementum. Donec malesuada laoreet est vel bibendum. Donec tempus, urna sit amet consequat molestie, sapien tellus pellentesque lectus, consectetur volutpat urna dolor eget elit. Donec tempus feugiat nulla in egestas. Duis eleifend sollicitudin lobortis. Vivamus ornare, ipsum et laoreet blandit, tortor nulla congue justo, ac eleifend massa neque ac eros. Nullam condimentum, nibh sed rutrum faucibus, velit metus malesuada est, lacinia vulputate ante nibh ut massa. Quisque et elementum nulla. Mauris a sem in odio cursus varius in nec ante. Vestibulum accumsan massa et dolor tincidunt ac laoreet massa imperdiet. Mauris eleifend turpis non sapien accumsan egestas. Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p> + </div> + <h3><a href="#section1">Header</a></h3> + <div> + <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec dapibus eleifend odio. Suspendisse porta pretium urna, vitae euismod turpis pharetra elementum. Donec malesuada laoreet est vel bibendum. Donec tempus, urna sit amet consequat molestie, sapien tellus pellentesque lectus, consectetur volutpat urna dolor eget elit. Donec tempus feugiat nulla in egestas. Duis eleifend sollicitudin lobortis. Vivamus ornare, ipsum et laoreet blandit, tortor nulla congue justo, ac eleifend massa neque ac eros. Nullam condimentum, nibh sed rutrum faucibus, velit metus malesuada est, lacinia vulputate ante nibh ut massa. Quisque et elementum nulla. Mauris a sem in odio cursus varius in nec ante. Vestibulum accumsan massa et dolor tincidunt ac laoreet massa imperdiet. Mauris eleifend turpis non sapien accumsan egestas. Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p> + </div> + <h3><a href="#section1">Header</a></h3> + <div> + <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Donec dapibus eleifend odio. Suspendisse porta pretium urna, vitae euismod turpis pharetra elementum. Donec malesuada laoreet est vel bibendum. Donec tempus, urna sit amet consequat molestie, sapien tellus pellentesque lectus, consectetur volutpat urna dolor eget elit. Donec tempus feugiat nulla in egestas. Duis eleifend sollicitudin lobortis. Vivamus ornare, ipsum et laoreet blandit, tortor nulla congue justo, ac eleifend massa neque ac eros. Nullam condimentum, nibh sed rutrum faucibus, velit metus malesuada est, lacinia vulputate ante nibh ut massa. Quisque et elementum nulla. Mauris a sem in odio cursus varius in nec ante. Vestibulum accumsan massa et dolor tincidunt ac laoreet massa imperdiet. Mauris eleifend turpis non sapien accumsan egestas. Lorem ipsum dolor sit amet, consectetur adipiscing elit.</p> + </div> </div> - <h3><a href="#">Section 4</a></h3> - <div> - <p> - Cras dictum. Pellentesque habitant morbi tristique senectus et netus - et malesuada fames ac turpis egestas. Vestibulum ante ipsum primis in - faucibus orci luctus et ultrices posuere cubilia Curae; Aenean lacinia - mauris vel est. - </p> - <p> - Suspendisse eu nisl. Nullam ut libero. Integer dignissim consequat lectus. - Class aptent taciti sociosqu ad litora torquent per conubia nostra, per - inceptos himenaeos. - </p> - </div> -</div> - -</div><!-- End demo --> - -<div class="demo-description"> -<p> -Click headers to expand/collapse content that is broken into logical sections, much like tabs. -Optionally, toggle sections open/closed on mouseover. -</p> -<p> -The underlying HTML markup is a series of headers (H3 tags) and content divs so the content is -usable without JavaScript. -</p> -</div><!-- End demo-description --> - </body> </html> |