New file |
0,0 → 1,98 |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" |
"http://www.w3.org/TR/html4/strict.dtd"> |
<html> |
<head> |
<title>TitlePane Test</title> |
|
<script type="text/javascript" src="../../dojo/dojo.js" |
djConfig="parseOnLoad: true, isDebug: true"></script> |
<script type="text/javascript" src="_testCommon.js"></script> |
|
<script language="JavaScript" type="text/javascript"> |
dojo.require("dijit.TitlePane"); |
dojo.require("dojo.parser"); // scan page for widgets and instantiate them |
|
// widgets used inside subpage loaded via href= |
dojo.require("dijit.form.Button"); |
dojo.require("dijit.form.ComboBox"); |
|
function randomMessageId(){ |
return Math.floor(Math.random() * 3) + 3; |
} |
</script> |
|
<style type="text/css"> |
@import "../../dojo/resources/dojo.css"; |
@import "css/dijitTests.css"; |
</style> |
</head> |
<body> |
<h1 class="testTitle">Dijit TitlePane Test</h1> |
|
<h1>Test #1: plain title pane, width=300px</h1> |
<div dojoType="dijit.TitlePane" title="Title Pane #1" style="width: 300px;"> |
Lorem Ipsum Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Quisque |
iaculis, nulla id semper faucibus, pede tellus nonummy magna, vitae adipiscing |
orci arcu ut augue. Nunc condimentum, magna a vestibulum convallis, libero purus |
pulvinar orci, sed vestibulum urna sem ut pede. More Ipsum... |
Sed sollicitudin suscipit risus. Nam ullamcorper. Sed nisl lectus, pellentesque |
nec, malesuada eget, ornare a, libero. Lorem ipsum dolor sit amet, |
consectetuer adipiscing elit. |
</div> |
|
<h1>Test #2: title pane with form, width=300px</h1> |
|
<div dojoType="dijit.TitlePane" title="Title Pane #2" id="pane_2" style="width: 300px;"> |
<form> |
Age: <input><br> |
Discount card <input type=checkbox><br> |
<button>Submit</button><br> |
</form> |
</div> |
<br> |
|
<h1>Test #3: initially closed pane</h1> |
<div dojoType="dijit.TitlePane" title="Initially closed pane" open="false" width="200"> |
<form> |
<title for="age">Age: </title><input id="age"><br> |
<title for="discount">Discount card </title><input type=checkbox id="discount"><br> |
<button>Submit</button><br> |
</form> |
</div> |
|
<h1>Test #4: title pane with href (initially closed)</h1> |
<p>The pane should open to "Loading..." message and then 2 seconds later it should slide open more to show loaded data.</p> |
<div dojoType="dijit.TitlePane" duration=1000 title="Pane from href" href="layout/getResponse.php?delay=3000&messId=3" open="false"> |
Loading... |
</div> |
|
<h1>Test #5: title pane with href (initially closed)</h1> |
<p>The pane should start to open to "Loading..." but halfway through href data will be loaded, and it should expand correctly.</p> |
<div dojoType="dijit.TitlePane" duration=1000 title="Pane from href" href="layout/getResponse.php?delay=500&messId=3" open="false"> |
Loading... |
</div> |
|
<h1>Test #6: nested title pane</h1> |
<div dojoType="dijit.TitlePane" title="Outer pane" width="300"> |
<p>This is a title pane, containing another title pane ... |
<p>Lorem ipsum dolor sit amet, consectetuer adipiscing elit. Quisque iaculis, nulla id semper faucibus, pede tellus nonummy magna, vitae adipiscing orci arcu ut augue. Nunc condimentum, magna a vestibulum convallis, libero purus pulvinar orci, sed vestibulum urna sem ut pede. |
More Ipsum... |
|
<div dojoType="dijit.TitlePane" title="Inner pane" width="250"> |
<p>And this is the inner title pane... |
<p>Sed sollicitudin suscipit risus. Nam ullamcorper. Sed nisl lectus, pellentesque nec, malesuada eget, ornare a, libero. Lorem ipsum dolor sit amet, consectetuer adipiscing elit. |
</div> |
|
<p>And this is the closing line for the outer title pane. |
</div> |
|
<table style="border: solid blue 2px; margin-top: 1em;"> |
<tr> |
<td> |
Here's some text below the title panes (to make sure that closing a title pane releases the space that the content was taking up) |
</td> |
</tr> |
</table> |
|
</body> |
</html> |