| 1 |
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" |
| 2 |
"http://www.w3.org/TR/html4/strict.dtd"> |
| 3 |
<html> |
| 4 |
<head> |
| 5 |
<title>Dijit Theme Tester</title> |
| 6 |
|
| 7 |
|
| 8 |
<link id="themeStyles" rel="stylesheet" href="../../dijit/themes/claro/claro.css"/> |
| 9 |
|
| 10 |
<style type="text/css"> |
| 11 |
@import "../themes/claro/document.css"; |
| 12 |
@import "../tests/css/dijitTests.css"; |
| 13 |
|
| 14 |
html, body { height: 100%; width: 100%; padding: 0; border: 0; } |
| 15 |
#main { height: 100%; width: 100%; border: 0; } |
| 16 |
#header { margin: 0; } |
| 17 |
#leftAccordion { width: 25%; } |
| 18 |
#bottomTabs { height: 40%; } |
| 19 |
|
| 20 |
/* pre-loader specific stuff to prevent unsightly flash of unstyled content */ |
| 21 |
#loader { |
| 22 |
padding:0; |
| 23 |
margin:0; |
| 24 |
position:absolute; |
| 25 |
top:0; left:0; |
| 26 |
width:100%; height:100%; |
| 27 |
background:#ededed; |
| 28 |
z-index:999; |
| 29 |
vertical-align:middle; |
| 30 |
} |
| 31 |
#loaderInner { |
| 32 |
padding:5px; |
| 33 |
position:relative; |
| 34 |
left:0; |
| 35 |
top:0; |
| 36 |
width:175px; |
| 37 |
background:#3c3; |
| 38 |
color:#fff; |
| 39 |
} |
| 40 |
|
| 41 |
hr.spacer { border:0; background-color:#ededed; width:80%; height:1px; } |
| 42 |
|
| 43 |
/* rules used to test custom setting of TextBox padding */ |
| 44 |
.inputPadding0 .dijitInputField { padding: 0 !important; } |
| 45 |
.inputPadding1 .dijitInputField { padding: 1px !important; } |
| 46 |
.inputPadding2 .dijitInputField { padding: 2px !important; } |
| 47 |
.inputPadding3 .dijitInputField { padding: 3px !important; } |
| 48 |
.inputPadding4 .dijitInputField { padding: 4px !important; } |
| 49 |
.inputPadding5 .dijitInputField { padding: 5px !important; } |
| 50 |
</style> |
| 51 |
|
| 52 |
|
| 53 |
<script type="text/javascript"> |
| 54 |
window.__globalList = {dojo: true, dijit: true, dojox: true, djConfig: true}; |
| 55 |
for(var i in window){ |
| 56 |
window.__globalList[i] = true; |
| 57 |
} |
| 58 |
</script> |
| 59 |
|
| 60 |
|
| 61 |
<script type="text/javascript" src="../../dojo/dojo.js" |
| 62 |
djConfig="parseOnLoad: false, isDebug: true"></script> |
| 63 |
|
| 64 |
|
| 65 |
<script type="text/javascript" src="../tests/_testCommon.js"></script> |
| 66 |
|
| 67 |
|
| 68 |
|
| 69 |
|
| 70 |
<script type="text/javascript"> // dojo.requires() |
| 71 |
|
| 72 |
dojo.require("dijit.Menu"); |
| 73 |
dojo.require("dijit.MenuItem"); |
| 74 |
dojo.require("dijit.PopupMenuItem"); |
| 75 |
dojo.require("dijit.CheckedMenuItem"); |
| 76 |
dojo.require("dijit.MenuSeparator"); |
| 77 |
|
| 78 |
dojo.require("dijit.Calendar"); |
| 79 |
dojo.require("dijit.ColorPalette"); |
| 80 |
dojo.require("dijit.ProgressBar"); |
| 81 |
dojo.require("dijit.TitlePane"); |
| 82 |
dojo.require("dijit.Tooltip"); |
| 83 |
dojo.require("dijit.Tree"); |
| 84 |
|
| 85 |
dojo.require("dijit.MenuBar"); |
| 86 |
dojo.require("dijit.MenuBarItem"); |
| 87 |
dojo.require("dijit.PopupMenuBarItem"); |
| 88 |
|
| 89 |
dojo.require("dijit.InlineEditBox"); |
| 90 |
|
| 91 |
// editor: |
| 92 |
dojo.require("dijit.Editor"); |
| 93 |
dojo.require("dijit._editor.plugins.FontChoice"); |
| 94 |
dojo.require("dijit._editor.plugins.LinkDialog"); |
| 95 |
|
| 96 |
// dnd: |
| 97 |
dojo.require("dojo.dnd.Source"); |
| 98 |
|
| 99 |
// various Form elements |
| 100 |
dojo.require("dijit.form.CheckBox"); |
| 101 |
dojo.require("dijit.form.RadioButton"); |
| 102 |
|
| 103 |
dojo.require("dijit.form.Textarea"); |
| 104 |
dojo.require("dijit.form.SimpleTextarea"); |
| 105 |
dojo.require("dijit.form.FilteringSelect"); |
| 106 |
dojo.require("dijit.form.Select"); |
| 107 |
dojo.require("dijit.form.TextBox"); |
| 108 |
dojo.require("dijit.form.DateTextBox"); |
| 109 |
dojo.require("dijit.form.TimeTextBox"); |
| 110 |
dojo.require("dijit.form.CurrencyTextBox"); |
| 111 |
dojo.require("dijit.form.NumberSpinner"); |
| 112 |
|
| 113 |
dojo.require("dijit.form.Button"); |
| 114 |
dojo.require("dijit.form.DropDownButton"); |
| 115 |
dojo.require("dijit.form.ComboButton"); |
| 116 |
dojo.require("dijit.form.ToggleButton"); |
| 117 |
|
| 118 |
dojo.require("dijit.form.VerticalSlider"); |
| 119 |
dojo.require("dijit.form.VerticalRuleLabels"); |
| 120 |
dojo.require("dijit.form.VerticalRule"); |
| 121 |
dojo.require("dijit.form.HorizontalSlider"); |
| 122 |
dojo.require("dijit.form.HorizontalRuleLabels"); |
| 123 |
dojo.require("dijit.form.HorizontalRule"); |
| 124 |
|
| 125 |
// layouts used in page |
| 126 |
dojo.require("dijit.layout.AccordionContainer"); |
| 127 |
dojo.require("dijit.layout.ContentPane"); |
| 128 |
dojo.require("dijit.layout.TabContainer"); |
| 129 |
dojo.require("dijit.layout.BorderContainer"); |
| 130 |
dojo.require("dijit.layout.LinkPane"); |
| 131 |
dojo.require("dijit.Dialog"); |
| 132 |
|
| 133 |
// scan page for widgets and instantiate them |
| 134 |
dojo.require("dojo.parser"); |
| 135 |
|
| 136 |
// humm? |
| 137 |
dojo.require("dojo.date.locale"); |
| 138 |
|
| 139 |
// for the Tree |
| 140 |
dojo.require("dojo.data.ItemFileReadStore"); |
| 141 |
|
| 142 |
// for the colorpalette |
| 143 |
function setColor(color){ |
| 144 |
var theSpan = dojo.byId("outputSpan"); |
| 145 |
dojo.style(theSpan,"color",color); |
| 146 |
theSpan.innerHTML = color; |
| 147 |
} |
| 148 |
|
| 149 |
// for the calendar |
| 150 |
function myHandler(id,newValue){ |
| 151 |
console.debug("onChange for id = " + id + ", value: " + newValue); |
| 152 |
} |
| 153 |
|
| 154 |
// current setting (if there is one) to override theme default padding on TextBox based widgets |
| 155 |
currentInputPadding = ""; |
| 156 |
|
| 157 |
function setTextBoxPadding(){ |
| 158 |
// summary: |
| 159 |
// Handler for when a MenuItem is clicked to set non-default padding for |
| 160 |
// TextBox widgets |
| 161 |
|
| 162 |
// Effectively ignore clicks on the currently checked MenuItem |
| 163 |
if(!this.get("checked")){ |
| 164 |
this.set("checked", true); |
| 165 |
} |
| 166 |
|
| 167 |
// val will be "theme default", "0px", "1px", ..., "5px" |
| 168 |
var val = this.get("label"); |
| 169 |
|
| 170 |
// Set class on body to get requested padding, and remove any previously set class |
| 171 |
if(currentInputPadding){ |
| 172 |
dojo.removeClass(dojo.body(), currentInputPadding); |
| 173 |
currentInputPadding = ""; |
| 174 |
} |
| 175 |
if(val != "theme default"){ |
| 176 |
currentInputPadding = "inputPadding" + val.replace("px", ""); |
| 177 |
dojo.addClass(dojo.body(), currentInputPadding); |
| 178 |
} |
| 179 |
|
| 180 |
// Clear previously checked MenuItem (radio-button effect). |
| 181 |
dojo.forEach(this.getParent().getChildren(), function(mi){ |
| 182 |
if(mi != this){ |
| 183 |
mi.set("checked", false); |
| 184 |
} |
| 185 |
}, this); |
| 186 |
} |
| 187 |
|
| 188 |
dojo.addOnLoad(function(){ |
| 189 |
|
| 190 |
var start = new Date().getTime(); |
| 191 |
dojo.parser.parse(dojo.byId('container')); |
| 192 |
console.info("Total parse time: " + (new Date().getTime() - start) + "ms"); |
| 193 |
|
| 194 |
dojo.byId('loaderInner').innerHTML += " done."; |
| 195 |
setTimeout(function hideLoader(){ |
| 196 |
var loader = dojo.byId('loader'); |
| 197 |
dojo.fadeOut({ node: loader, duration:500, |
| 198 |
onEnd: function(){ |
| 199 |
loader.style.display = "none"; |
| 200 |
} |
| 201 |
}).play(); |
| 202 |
}, 250); |
| 203 |
|
| 204 |
logStrayGlobals(); |
| 205 |
|
| 206 |
// Fill in menu/links to get to other themes. |
| 207 |
// availableThemes[] is just a list of 'official' dijit themes, you can use ?theme=String |
| 208 |
// for 'un-supported' themes, too. (eg: yours) |
| 209 |
var availableThemes = [ |
| 210 |
{ theme:"claro", author:"Dojo", baseUri:"../themes/" }, |
| 211 |
{ theme:"tundra", author:"Dojo", baseUri:"../themes/" }, |
| 212 |
{ theme:"soria", author:"nikolai", baseUri:"../themes/" }, |
| 213 |
{ theme:"nihilo", author:"nikolai", baseUri:"../themes/" } |
| 214 |
]; |
| 215 |
|
| 216 |
var tmpString=''; |
| 217 |
dojo.forEach(availableThemes,function(theme){ |
| 218 |
tmpString += |
| 219 |
'<a href="?theme='+theme.theme+'">'+theme.theme+'</'+'a> (' + |
| 220 |
'<a href="?theme='+theme.theme+'&dir=rtl">RTL</'+'a> ' + |
| 221 |
'<a href="?theme='+theme.theme+'&a11y=true">high-contrast</'+'a> ' + |
| 222 |
'<a href="?theme='+theme.theme+'&dir=rtl&a11y=true">RTL+high-contrast</'+'a> )' + |
| 223 |
' - by: '+theme.author+' <br>'; |
| 224 |
dijit.byId('themeMenu').addChild(new dijit.MenuItem({ |
| 225 |
label: theme.theme, |
| 226 |
onClick: function(){ location.search = "?theme=" + theme.theme; } |
| 227 |
})) |
| 228 |
}); |
| 229 |
dojo.byId('themeData').innerHTML = tmpString; |
| 230 |
}); |
| 231 |
|
| 232 |
function logStrayGlobals(){ |
| 233 |
// summary: |
| 234 |
// Print all the global variables that we've created [by mistake] inside of dojo |
| 235 |
var strayGlobals = []; |
| 236 |
for(var i in window){ |
| 237 |
if(!window.__globalList[i]){ strayGlobals.push(i); } |
| 238 |
} |
| 239 |
if(strayGlobals.length){ |
| 240 |
console.warn("Stray globals: "+strayGlobals.join(", ")); |
| 241 |
} |
| 242 |
} |
| 243 |
|
| 244 |
function logWidgets(){ |
| 245 |
// summary: |
| 246 |
// Print all the widgets to console |
| 247 |
console.log("Widgets in registry:"); |
| 248 |
dijit.registry.forEach(function(w){ |
| 249 |
console.log(w); |
| 250 |
}); |
| 251 |
} |
| 252 |
|
| 253 |
function tearDown(){ |
| 254 |
// summary: |
| 255 |
// Destroy all widgets, top down, and then check for any orphaned widgets |
| 256 |
dijit._destroyAll(); |
| 257 |
logWidgets(); |
| 258 |
} |
| 259 |
|
| 260 |
dojo.addOnLoad(function(){ |
| 261 |
// It's the server's responsibility to localize the date displayed in the (non-edit) version of an InlineEditBox, |
| 262 |
// but since we don't have a server we'll hack it in the client |
| 263 |
dijit.byId("backgroundArea").set('value', dojo.date.locale.format(new Date(2005, 11, 30), { selector: 'date' })); |
| 264 |
|
| 265 |
var nineAm = new Date(0); |
| 266 |
nineAm.setHours(9); |
| 267 |
dijit.byId("timePicker").set('value', dojo.date.locale.format(nineAm, { selector: 'time' })); |
| 268 |
}); |
| 269 |
|
| 270 |
/*** |
| 271 |
dojo.addOnLoad(function(){ |
| 272 |
// use "before advice" to print log message each time resize is called on a layout widget |
| 273 |
var origResize = dijit.layout._LayoutWidget.prototype.resize; |
| 274 |
dijit.layout._LayoutWidget.prototype.resize = function(mb){ |
| 275 |
console.log(this + ": resize({w:"+ mb.w + ", h:" + mb.h + "})"); |
| 276 |
origResize.apply(this, arguments); |
| 277 |
}; |
| 278 |
|
| 279 |
// content pane has no children so just use dojo's builtin after advice |
| 280 |
dojo.connect(dijit.layout.ContentPane.prototype, "resize", function(mb){ |
| 281 |
console.log(this + ": resize({w:"+ mb.w + ", h:" + mb.h + "})"); |
| 282 |
}); |
| 283 |
}); |
| 284 |
***/ |
| 285 |
</script> |
| 286 |
</head> |
| 287 |
<body class="claro"> |
| 288 |
|
| 289 |
<div id="loader"><div id="loaderInner" style="direction:ltr;">Loading themeTester ... </div></div> |
| 290 |
|
| 291 |
|
| 292 |
<div dojoType="dojo.data.ItemFileReadStore" jsId="continentStore" |
| 293 |
url="../tests/_data/countries.json"></div> |
| 294 |
<div dojoType="dojo.data.ItemFileReadStore" jsId="stateStore" |
| 295 |
url="../tests/_data/states.json"></div> |
| 296 |
|
| 297 |
<div dojoType="dijit.Menu" id="submenu1" contextMenuForWindow="true" style="display: none;"> |
| 298 |
<div dojoType="dijit.MenuItem" onClick="alert('Hello world');">Enabled Item</div> |
| 299 |
<div dojoType="dijit.MenuItem" disabled="true">Disabled Item</div> |
| 300 |
<div dojoType="dijit.MenuSeparator"></div> |
| 301 |
<div dojoType="dijit.MenuItem" iconClass="dijitIconCut" |
| 302 |
onClick="alert('not actually cutting anything, just a test!')">Cut</div> |
| 303 |
<div dojoType="dijit.MenuItem" iconClass="dijitIconCopy" |
| 304 |
onClick="alert('not actually copying anything, just a test!')">Copy</div> |
| 305 |
<div dojoType="dijit.MenuItem" iconClass="dijitIconPaste" |
| 306 |
onClick="alert('not actually pasting anything, just a test!')">Paste</div> |
| 307 |
<div dojoType="dijit.MenuSeparator"></div> |
| 308 |
<div dojoType="dijit.PopupMenuItem"> |
| 309 |
<span>Enabled Submenu</span> |
| 310 |
<div dojoType="dijit.Menu" id="submenu2"> |
| 311 |
<div dojoType="dijit.MenuItem" onClick="alert('Submenu 1!')">Submenu Item One</div> |
| 312 |
<div dojoType="dijit.MenuItem" onClick="alert('Submenu 2!')">Submenu Item Two</div> |
| 313 |
<div dojoType="dijit.PopupMenuItem"> |
| 314 |
<span>Deeper Submenu</span> |
| 315 |
<div dojoType="dijit.Menu" id="submenu4"> |
| 316 |
<div dojoType="dijit.MenuItem" onClick="alert('Sub-submenu 1!')">Sub-sub-menu Item One</div> |
| 317 |
<div dojoType="dijit.MenuItem" onClick="alert('Sub-submenu 2!')">Sub-sub-menu Item Two</div> |
| 318 |
</div> |
| 319 |
</div> |
| 320 |
</div> |
| 321 |
</div> |
| 322 |
<div dojoType="dijit.PopupMenuItem" disabled="true"> |
| 323 |
<span>Disabled Submenu</span> |
| 324 |
<div dojoType="dijit.Menu" id="submenu3" style="display: none;"> |
| 325 |
<div dojoType="dijit.MenuItem" onClick="alert('Submenu 1!')">Submenu Item One</div> |
| 326 |
<div dojoType="dijit.MenuItem" onClick="alert('Submenu 2!')">Submenu Item Two</div> |
| 327 |
</div> |
| 328 |
</div> |
| 329 |
<div dojoType="dijit.PopupMenuItem"> |
| 330 |
<span>Different popup</span> |
| 331 |
<div dojoType="dijit.ColorPalette"></div> |
| 332 |
</div> |
| 333 |
<div dojoType="dijit.PopupMenuItem"> |
| 334 |
<span>Different popup</span> |
| 335 |
<div dojoType="dijit.Calendar"></div> |
| 336 |
</div> |
| 337 |
</div> |
| 338 |
|
| 339 |
|
| 340 |
<div id="main" dojoType="dijit.layout.BorderContainer" liveSplitters="false" design="sidebar"> |
| 341 |
|
| 342 |
<div id="header" dojoType="dijit.MenuBar" region="top"> |
| 343 |
<div dojoType="dijit.PopupMenuBarItem" id="file"> |
| 344 |
<span>File</span> |
| 345 |
<div dojoType="dijit.Menu" id="fileMenu"> |
| 346 |
<div dojoType="dijit.MenuItem" id="globals" onClick="logStrayGlobals();">Log globals</div> |
| 347 |
<div dojoType="dijit.MenuItem" id="widgets" onClick="logWidgets();">Log widgets</div> |
| 348 |
<div dojoType="dijit.MenuItem" id="destroy" iconClass="dijitIconDelete" onClick="tearDown();">Destroy All</div> |
| 349 |
</div> |
| 350 |
</div> |
| 351 |
<div dojoType="dijit.PopupMenuBarItem" id="edit"> |
| 352 |
<span>Edit</span> |
| 353 |
<div dojoType="dijit.Menu" id="editMenu"> |
| 354 |
<div dojoType="dijit.MenuItem" id="cut" iconClass="dijitIconCut" |
| 355 |
onClick="console.log('not actually cutting anything, just a test!')">Cut</div> |
| 356 |
<div dojoType="dijit.MenuItem" id="copy" iconClass="dijitIconCopy" |
| 357 |
onClick="console.log('not actually copying anything, just a test!')">Copy</div> |
| 358 |
<div dojoType="dijit.MenuItem" id="paste" iconClass="dijitIconPaste" |
| 359 |
onClick="console.log('not actually pasting anything, just a test!')">Paste</div> |
| 360 |
<div dojoType="dijit.MenuSeparator" id="separator"></div> |
| 361 |
<div dojoType="dijit.MenuItem" id="undo" iconClass="dijitIconUndo">Undo</div> |
| 362 |
</div> |
| 363 |
</div> |
| 364 |
<div dojoType="dijit.PopupMenuBarItem" id="view"> |
| 365 |
<span>View</span> |
| 366 |
<div dojoType="dijit.Menu" id="viewMenu"> |
| 367 |
<div dojoType="dijit.MenuItem">Normal</div> |
| 368 |
<div dojoType="dijit.MenuItem">Outline</div> |
| 369 |
<div dojoType="dijit.PopupMenuItem"> |
| 370 |
<span>Zoom</span> |
| 371 |
<div dojoType="dijit.Menu" id="zoomMenu"> |
| 372 |
<div dojoType="dijit.MenuItem">50%</div> |
| 373 |
<div dojoType="dijit.MenuItem">75%</div> |
| 374 |
<div dojoType="dijit.MenuItem">100%</div> |
| 375 |
<div dojoType="dijit.MenuItem">150%</div> |
| 376 |
<div dojoType="dijit.MenuItem">200%</div> |
| 377 |
</div> |
| 378 |
</div> |
| 379 |
</div> |
| 380 |
</div> |
| 381 |
<div dojoType="dijit.PopupMenuBarItem" id="themes"> |
| 382 |
<span>Themes</span> |
| 383 |
<div dojoType="dijit.Menu" id="themeMenu"> |
| 384 |
</div> |
| 385 |
</div> |
| 386 |
<div dojoType="dijit.PopupMenuBarItem" id="dialogs"> |
| 387 |
<span>Dialogs</span> |
| 388 |
<div dojoType="dijit.Menu" id="dialogMenu"> |
| 389 |
<div dojoType="dijit.MenuItem"> |
| 390 |
<script type="dojo/method" event="onClick"> |
| 391 |
var dlg = dijit.byId('dialog1'); |
| 392 |
dlg.show(); |
| 393 |
// avoid (trying to) restore focus to a closed menu, go to MenuBar instead |
| 394 |
dlg._savedFocus = dojo.byId("header"); |
| 395 |
</script> |
| 396 |
slow loading |
| 397 |
</div> |
| 398 |
<div dojoType="dijit.MenuItem"> |
| 399 |
<script type="dojo/method" event="onClick"> |
| 400 |
var dlg = dijit.byId('dialogAB'); |
| 401 |
dlg.show(); |
| 402 |
// avoid (trying to) restore focus to a closed menu, go to MenuBar instead |
| 403 |
dlg._savedFocus = dojo.byId("header"); |
| 404 |
</script> |
| 405 |
action bar |
| 406 |
</div> |
| 407 |
</div> |
| 408 |
</div> |
| 409 |
<div dojoType="dijit.PopupMenuBarItem" id="inputPadding"> |
| 410 |
<span>TextBox Padding</span> |
| 411 |
<div dojoType="dijit.Menu" id="inputPaddingMenu"> |
| 412 |
<div dojoType="dijit.CheckedMenuItem" onClick="setTextBoxPadding" checked>theme default</div> |
| 413 |
<div dojoType="dijit.CheckedMenuItem" onClick="setTextBoxPadding">0px</div> |
| 414 |
<div dojoType="dijit.CheckedMenuItem" onClick="setTextBoxPadding">1px</div> |
| 415 |
<div dojoType="dijit.CheckedMenuItem" onClick="setTextBoxPadding">2px</div> |
| 416 |
<div dojoType="dijit.CheckedMenuItem" onClick="setTextBoxPadding">3px</div> |
| 417 |
<div dojoType="dijit.CheckedMenuItem" onClick="setTextBoxPadding">4px</div> |
| 418 |
<div dojoType="dijit.CheckedMenuItem" onClick="setTextBoxPadding">5px</div> |
| 419 |
</div> |
| 420 |
</div> |
| 421 |
<div dojoType="dijit.PopupMenuBarItem" id="help"> |
| 422 |
<span>Help</span> |
| 423 |
<div dojoType="dijit.Menu" id="helpMenu"> |
| 424 |
<div dojoType="dijit.MenuItem">Help Topics</div> |
| 425 |
<div dojoType="dijit.MenuItem">About Dijit</div> |
| 426 |
</div> |
| 427 |
</div> |
| 428 |
<div dojoType="dijit.PopupMenuBarItem" disabled="true"> |
| 429 |
<span>Disabled</span> |
| 430 |
<div dojoType="dijit.Menu"> |
| 431 |
<div dojoType="dijit.MenuItem">You should not see this</div> |
| 432 |
</div> |
| 433 |
</div> |
| 434 |
<div dojoType="dijit.MenuBarItem" onclick="alert('no submenu, just a clickable MenuItem');"> |
| 435 |
Click me! |
| 436 |
</div> |
| 437 |
</div> |
| 438 |
|
| 439 |
<div dojoType="dijit.layout.AccordionContainer" |
| 440 |
minSize="20" style="width: 300px;" id="leftAccordion" region="leading" splitter="true"> |
| 441 |
|
| 442 |
<div dojoType="dijit.layout.ContentPane" title="Popups and Alerts"><div style="padding:8px"> |
| 443 |
<h2>Tooltips</h2> |
| 444 |
<ul> |
| 445 |
<li> |
| 446 |
<span id="ttRich"><b>rich</b> <i>text</i> tooltip</span> |
| 447 |
<span dojoType="dijit.Tooltip" connectId="ttRich" style="display:none;"> |
| 448 |
Embedded <b>bold</b> <i>RICH</i> text <span style="color:#309; font-size:x-large;">weirdness!</span> |
| 449 |
</span> |
| 450 |
</li> |
| 451 |
|
| 452 |
<li><a id="ttOne" href="#bogus">anchor tooltip</a> |
| 453 |
<span dojoType="dijit.Tooltip" connectId="ttOne" style="display:none;">tooltip on anchor</span> |
| 454 |
</li> |
| 455 |
</ul> |
| 456 |
|
| 457 |
<table style="width: 100%;"> |
| 458 |
<tr> |
| 459 |
<td></td> |
| 460 |
<td> |
| 461 |
<div id="ttBelow" href="#bogus">tooltip below</div> |
| 462 |
<div dojoType="dijit.Tooltip" connectId="ttBelow" style="display:none; width: 100px;" position="below" >I'm <i>below</i>!</div> |
| 463 |
</td> |
| 464 |
<td></td> |
| 465 |
</tr> |
| 466 |
<tr> |
| 467 |
<td> |
| 468 |
<div id="ttRight" href="#bogus">tooltip after</div> |
| 469 |
<div dojoType="dijit.Tooltip" connectId="ttRight" style="display:none;" position="after" >I'm on the <i>right</i>!<br>(or left on RTL systems)</div> |
| 470 |
</td> |
| 471 |
<td></td> |
| 472 |
<td> |
| 473 |
<div id="ttLeft" href="#bogus">tooltip before</div> |
| 474 |
<div dojoType="dijit.Tooltip" connectId="ttLeft" style="display:none;" position="before,after" >I'm on the <i>left</i>!<br>(or right on RTL systems)</div> |
| 475 |
</td> |
| 476 |
</tr> |
| 477 |
<tr> |
| 478 |
<td></td> |
| 479 |
<td> |
| 480 |
<div id="ttAbove" href="#bogus">tooltip above</div> |
| 481 |
<div dojoType="dijit.Tooltip" connectId="ttAbove" style="display:none;" position="above" >I'm <i>above</i>!</div> |
| 482 |
</td> |
| 483 |
<td></td> |
| 484 |
</tr> |
| 485 |
</table> |
| 486 |
|
| 487 |
<hr class="spacer"> |
| 488 |
|
| 489 |
<h2>Dialogs</h2> |
| 490 |
<ul> |
| 491 |
<li><a href="#" onclick="dijit.byId('dialog1').show()">slow loading modal dialog</a></li> |
| 492 |
<li><a href="#" onclick="dijit.byId('dialogAB').show()">modal dialog w/action bar</a></li> |
| 493 |
</ul> |
| 494 |
|
| 495 |
<div dojoType="dijit.form.DropDownButton"> |
| 496 |
<span>Show Tooltip Dialog</span> |
| 497 |
<div dojoType="dijit.TooltipDialog" id="tooltipDlg" title="Enter Login information" |
| 498 |
execute="alert('submitted w/args:\n' + dojo.toJson(arguments[0], true));"> |
| 499 |
<table> |
| 500 |
<tr> |
| 501 |
<td><label for="user">User:</label></td> |
| 502 |
<td><input dojoType=dijit.form.TextBox type="text" id="user" name="user" ></td> |
| 503 |
</tr> |
| 504 |
<tr> |
| 505 |
<td><label for="pwd">Password:</label></td> |
| 506 |
<td><input dojoType=dijit.form.TextBox type="password" id="pwd" name="pwd"></td> |
| 507 |
</tr> |
| 508 |
<tr> |
| 509 |
<td colspan="2" align="center"> |
| 510 |
<button dojoType=dijit.form.Button type="submit" name="submit">Login</button> |
| 511 |
</tr> |
| 512 |
</table> |
| 513 |
</div> |
| 514 |
</div> |
| 515 |
</div> |
| 516 |
</div> |
| 517 |
|
| 518 |
<div dojoType="dijit.layout.ContentPane" title="Dojo Tree from Store"> |
| 519 |
|
| 520 |
<div dojoType="dijit.Tree" store="continentStore" query="{type:'continent'}" |
| 521 |
label="Continents" openOnClick="true"> |
| 522 |
</div> |
| 523 |
</div> |
| 524 |
|
| 525 |
<div dojoType="dijit.layout.ContentPane" title="Calendar" selected="true"> |
| 526 |
|
| 527 |
<input id="calendar1" dojoType="dijit.Calendar" onChange="myHandler(this.id,arguments[0])"> |
| 528 |
</div> |
| 529 |
|
| 530 |
<div dojoType="dijit.layout.ContentPane" title="Color Picker"> |
| 531 |
<p> |
| 532 |
Selecting a color will change the background color of the page. |
| 533 |
Use this to test how tooltips and drop downs appear with different backgrounds. |
| 534 |
</p> |
| 535 |
<h2 class="testHeader">3x4</h2> |
| 536 |
<script> |
| 537 |
function setBackground(color){ |
| 538 |
dojo.query('.dijitAccordionBody').style('background', color); |
| 539 |
dojo.query('.dijitTabPaneWrapper').style('background', color); |
| 540 |
} |
| 541 |
</script> |
| 542 |
<div dojoType="dijit.ColorPalette" palette="3x4" onChange="setBackground(arguments[0]);"></div> |
| 543 |
<h2 class="testHeader">7x10</h2> |
| 544 |
<div dojoType="dijit.ColorPalette" onChange="setBackground(arguments[0]);"></div> |
| 545 |
</div> |
| 546 |
<div dojoType="dijit.layout.TabContainer" useMenu="false" title="Sliding TabContainer" |
| 547 |
id="slidingTab"> |
| 548 |
<div dojoType="dijit.layout.ContentPane" title="Information"> |
| 549 |
This tab container uses slide controls when the tabs are too wide to fit beside each other. |
| 550 |
If you make the left column narrow enough, the slide controls should appear. |
| 551 |
</div> |
| 552 |
<div dojoType="dijit.layout.ContentPane" title="Rootless Tree" closable="true"> |
| 553 |
<div |
| 554 |
dojoType="dijit.Tree" |
| 555 |
id="rootlessTree" |
| 556 |
store="continentStore" |
| 557 |
query="{type:'continent'}" |
| 558 |
openOnClick="true"> |
| 559 |
</div> |
| 560 |
|
| 561 |
</div> |
| 562 |
<div dojoType="dijit.layout.TabContainer" |
| 563 |
id="inlined" closable="true" |
| 564 |
title="Nested TabContainer" nested="true"> |
| 565 |
<a dojoType="dijit.layout.LinkPane" id="tab1href" href="../tests/layout/tab1.html" onLoad="console.log('load of SubTab 1');">SubTab 1</a> |
| 566 |
<a dojoType="dijit.layout.LinkPane" id="tab2href" href="../tests/layout/tab2.html" onLoad="console.log('load of SubTab 2');" selected="true">SubTab 2</a> |
| 567 |
<div dojoType="dijit.layout.ContentPane" id="subtab3" title="SubTab 3"> |
| 568 |
<h1>I am tab 3, inlined.</h1> |
| 569 |
</div> |
| 570 |
<div dojoType="dijit.layout.ContentPane" id="subtab4" title="SubTab 4"> |
| 571 |
<h1>I am tab 4, inlined.</h1> |
| 572 |
</div> |
| 573 |
</div> |
| 574 |
<div dojoType="dijit.layout.ContentPane" title="Menu Bar" closable="true"> |
| 575 |
<div id="menubar" dojoType="dijit.MenuBar"> |
| 576 |
<div dojoType="dijit.PopupMenuBarItem" > |
| 577 |
<span>File</span> |
| 578 |
<div dojoType="dijit.Menu"> |
| 579 |
<div dojoType="dijit.MenuItem" iconClass="dijitIconNewTask">New</div> |
| 580 |
<div dojoType="dijit.MenuItem">Open</div> |
| 581 |
<div dojoType="dijit.MenuSeparator"></div> |
| 582 |
<div dojoType="dijit.MenuItem" iconClass="dijitIconSave">Save</div> |
| 583 |
<div dojoType="dijit.MenuItem">Save As...</div> |
| 584 |
</div> |
| 585 |
</div> |
| 586 |
<div dojoType="dijit.PopupMenuBarItem"> |
| 587 |
<span>Edit</span> |
| 588 |
<div dojoType="dijit.Menu" > |
| 589 |
<div dojoType="dijit.MenuItem" iconClass="dijitIconCut" |
| 590 |
onClick="console.log('not actually cutting anything, just a test!')">Cut</div> |
| 591 |
<div dojoType="dijit.MenuItem" iconClass="dijitIconCopy" |
| 592 |
onClick="console.log('not actually copying anything, just a test!')">Copy</div> |
| 593 |
<div dojoType="dijit.MenuItem" iconClass="dijitIconPaste" |
| 594 |
onClick="console.log('not actually pasting anything, just a test!')">Paste</div> |
| 595 |
</div> |
| 596 |
</div> |
| 597 |
<div dojoType="dijit.PopupMenuBarItem"> |
| 598 |
<span>View</span> |
| 599 |
<div dojoType="dijit.Menu"> |
| 600 |
<div dojoType="dijit.MenuItem">Normal</div> |
| 601 |
<div dojoType="dijit.MenuItem">Outline</div> |
| 602 |
<div dojoType="dijit.PopupMenuItem"> |
| 603 |
<span>Zoom</span> |
| 604 |
<div dojoType="dijit.Menu"> |
| 605 |
<div dojoType="dijit.MenuItem">50%</div> |
| 606 |
<div dojoType="dijit.MenuItem">75%</div> |
| 607 |
<div dojoType="dijit.MenuItem">100%</div> |
| 608 |
<div dojoType="dijit.MenuItem">150%</div> |
| 609 |
<div dojoType="dijit.MenuItem">200%</div> |
| 610 |
</div> |
| 611 |
</div> |
| 612 |
</div> |
| 613 |
</div> |
| 614 |
<div dojoType="dijit.PopupMenuBarItem"> |
| 615 |
<span>Help</span> |
| 616 |
<div dojoType="dijit.Menu"> |
| 617 |
<div dojoType="dijit.MenuItem">Help Topics</div> |
| 618 |
<div dojoType="dijit.MenuItem">About Dijit</div> |
| 619 |
</div> |
| 620 |
</div> |
| 621 |
<div dojoType="dijit.PopupMenuBarItem" disabled="true"> |
| 622 |
<span>Disabled</span> |
| 623 |
<div dojoType="dijit.Menu"> |
| 624 |
<div dojoType="dijit.MenuItem">You should not see this</div> |
| 625 |
</div> |
| 626 |
</div> |
| 627 |
<div dojoType="dijit.MenuBarItem" onclick="alert('no submenu, just a clickable MenuItem');"> |
| 628 |
Click me! |
| 629 |
</div> |
| 630 |
</div> |
| 631 |
</div> |
| 632 |
</div> |
| 633 |
|
| 634 |
|
| 635 |
</div> |
| 636 |
|
| 637 |
|
| 638 |
<div dojoType="dijit.layout.TabContainer" region="center" id="topTabs" tabStrip="true"> |
| 639 |
|
| 640 |
<div id="basicFormTab" dojoType="dijit.layout.ContentPane" title="Basic Form Widgets" style="padding:10px;display:none;"> |
| 641 |
|
| 642 |
<h2>Buttons</h2> |
| 643 |
<p>Buttons can do an action, display a menu, or both:</p> |
| 644 |
|
| 645 |
Enabled: |
| 646 |
|
| 647 |
<button dojoType="dijit.form.Button" iconClass="dijitIconTask" onClick='console.debug("clicked simple")'> |
| 648 |
Simple |
| 649 |
</button> |
| 650 |
|
| 651 |
<button dojoType="dijit.form.DropDownButton" iconClass="dijitIconEdit"> |
| 652 |
<span>Drop Down</span> |
| 653 |
<div dojoType="dijit.Menu" id="editMenu1" style="display: none;"> |
| 654 |
<div dojoType="dijit.MenuItem" |
| 655 |
iconClass="dijitIconCut" |
| 656 |
onClick="console.debug('not actually cutting anything, just a test!')"> |
| 657 |
Cut |
| 658 |
</div> |
| 659 |
|
| 660 |
<div dojoType="dijit.MenuItem" |
| 661 |
iconClass="dijitIconCopy" |
| 662 |
onClick="console.debug('not actually copying anything, just a test!')"> |
| 663 |
Copy |
| 664 |
</div> |
| 665 |
|
| 666 |
<div dojoType="dijit.MenuItem" |
| 667 |
iconClass="dijitIconPaste" |
| 668 |
onClick="console.debug('not actually pasting anything, just a test!')"> |
| 669 |
Paste |
| 670 |
</div> |
| 671 |
</div> |
| 672 |
</button> |
| 673 |
|
| 674 |
<button dojoType="dijit.form.ComboButton" iconClass="dijitIconSave" |
| 675 |
optionsTitle='save options' |
| 676 |
onClick='console.debug("clicked combo save")'> |
| 677 |
<span>Combo</span> |
| 678 |
<div dojoType="dijit.Menu" id="saveMenu1" style="display: none;"> |
| 679 |
<div dojoType="dijit.MenuItem" |
| 680 |
iconClass="dijitIconSave" |
| 681 |
onClick="console.debug('not actually saving anything, just a test!')"> |
| 682 |
Save |
| 683 |
</div> |
| 684 |
<div dojoType="dijit.MenuItem" |
| 685 |
onClick="console.debug('not actually saving anything, just a test!')"> |
| 686 |
Save As |
| 687 |
</div> |
| 688 |
</div> |
| 689 |
</button> |
| 690 |
|
| 691 |
<button dojoType="dijit.form.ToggleButton" checked onChange="console.log('toggled button checked='+arguments[0]);" iconClass="dijitCheckBoxIcon"> |
| 692 |
Toggle |
| 693 |
</button> |
| 694 |
|
| 695 |
<hr class="spacer"> |
| 696 |
|
| 697 |
Disabled: |
| 698 |
|
| 699 |
<button dojoType="dijit.form.Button" iconClass="dijitIconTask" disabled> |
| 700 |
Simple |
| 701 |
</button> |
| 702 |
|
| 703 |
<button dojoType="dijit.form.DropDownButton" iconClass="dijitIconEdit" disabled> |
| 704 |
<span>Drop Down</span> |
| 705 |
<div dojoType="dijit.Menu" id="editMenu2" style="display: none;"> |
| 706 |
<div dojoType="dijit.MenuItem" |
| 707 |
iconClass="dijitIconCut" |
| 708 |
onClick="console.debug('not actually cutting anything, just a test!')"> |
| 709 |
Cut |
| 710 |
</div> |
| 711 |
|
| 712 |
<div dojoType="dijit.MenuItem" |
| 713 |
iconClass="dijitIconCopy" |
| 714 |
onClick="console.debug('not actually copying anything, just a test!')"> |
| 715 |
Copy |
| 716 |
</div> |
| 717 |
|
| 718 |
<div dojoType="dijit.MenuItem" |
| 719 |
iconClass="dijitIconPaste" |
| 720 |
onClick="console.debug('not actually pasting anything, just a test!')"> |
| 721 |
Paste |
| 722 |
</div> |
| 723 |
</div> |
| 724 |
</button> |
| 725 |
|
| 726 |
<button dojoType="dijit.form.ComboButton" iconClass="dijitIconSave" |
| 727 |
optionsTitle='save options' |
| 728 |
disabled> |
| 729 |
<span>Combo</span> |
| 730 |
<div dojoType="dijit.Menu" id="saveMenu2" style="display: none;"> |
| 731 |
<div dojoType="dijit.MenuItem" |
| 732 |
iconClass="dijitIconSave" |
| 733 |
onClick="console.debug('not actually saving anything, just a test!')"> |
| 734 |
Save |
| 735 |
</div> |
| 736 |
<div dojoType="dijit.MenuItem" |
| 737 |
onClick="console.debug('not actually saving anything, just a test!')"> |
| 738 |
Save As |
| 739 |
</div> |
| 740 |
</div> |
| 741 |
</button> |
| 742 |
|
| 743 |
<button dojoType="dijit.form.ToggleButton" checked disabled iconClass="dijitCheckBoxIcon"> |
| 744 |
Toggle |
| 745 |
</button> |
| 746 |
|
| 747 |
<hr class="spacer"> |
| 748 |
|
| 749 |
<h2>CheckBox</h2> |
| 750 |
<fieldset> |
| 751 |
<input id="check1" type="checkBox" dojoType="dijit.form.CheckBox"> |
| 752 |
<label for="check1">unchecked</label> |
| 753 |
|
| 754 |
<input id="check2" type="checkBox" dojoType="dijit.form.CheckBox" checked="checked"> |
| 755 |
<label for="check2">checked</label> |
| 756 |
|
| 757 |
<input id="check3" type="checkBox" dojoType="dijit.form.CheckBox" disabled> |
| 758 |
<label for="check3">disabled</label> |
| 759 |
|
| 760 |
<input id="check4" type="checkBox" dojoType="dijit.form.CheckBox" checked="checked" disabled> |
| 761 |
<label for="check4">disabled and checked</label> |
| 762 |
</fieldset> |
| 763 |
|
| 764 |
<h2>Radio Buttons</h2> |
| 765 |
<fieldset> |
| 766 |
<input type="radio" name="g1" id="g1rb1" value="news" dojoType="dijit.form.RadioButton"> |
| 767 |
<label for="g1rb1">news</label> |
| 768 |
<input type="radio" name="g1" id="g1rb2" value="talk" dojoType="dijit.form.RadioButton" checked> |
| 769 |
<label for="g1rb2">talk</label> |
| 770 |
<input type="radio" name="g1" id="g1rb3" value="weather" dojoType="dijit.form.RadioButton" disabled> |
| 771 |
<label for="g1rb3">weather (disabled)</label> |
| 772 |
</fieldset> |
| 773 |
</div> |
| 774 |
|
| 775 |
<div id="textboxTab" dojoType="dijit.layout.ContentPane" title="Text Input Widgets" style="padding:10px;display:none;"> |
| 776 |
|
| 777 |
<h2>dijit.form.DateTextBox</h2> |
| 778 |
<label for="date1">Enabled w/placeHolder:</label> |
| 779 |
<input id="date1" name="date1" type="text" dojoType="dijit.form.DateTextBox" placeHolder="Birthday"> |
| 780 |
<label for="date2">Disabled w/placeHolder:</label> |
| 781 |
<input id="date2" name="date2" type="text" dojoType="dijit.form.DateTextBox" placeHolder="Birthday" disabled="disabled"> |
| 782 |
<label for="date2">Disabled w/value:</label> |
| 783 |
<input id="date3" name="date3" type="text" dojoType="dijit.form.DateTextBox" value="2008-12-25" disabled="disabled"> |
| 784 |
|
| 785 |
<h2>dijit.form.TimeTextBox</h2> |
| 786 |
<label for="time1">Enabled:</label> |
| 787 |
<input id="time1" name="time1" type="text" dojoType="dijit.form.TimeTextBox" value="T17:45:00"> |
| 788 |
<label for="time2">Disabled:</label> |
| 789 |
<input id="time2" name="time2" type="text" dojoType="dijit.form.TimeTextBox" value="T17:45:00" disabled> |
| 790 |
|
| 791 |
<h2>dijit.form.CurrencyTextBox</h2> |
| 792 |
<label for="currency1">Enabled:</label> |
| 793 |
<input id="currency1" type="text" name="income1" value="54775.53" |
| 794 |
dojoType="dijit.form.CurrencyTextBox" |
| 795 |
required="true" |
| 796 |
constraints="{fractional:true}" |
| 797 |
currency="USD" |
| 798 |
invalidMessage="Invalid amount. Include dollar sign, commas, and cents. Cents are mandatory."> |
| 799 |
<label for="currency2">Disabled:</label> |
| 800 |
<input id="currency2" type="text" name="income1" value="54775.53" |
| 801 |
dojoType="dijit.form.CurrencyTextBox" |
| 802 |
required="true" |
| 803 |
constraints="{fractional:true}" |
| 804 |
currency="USD" |
| 805 |
invalidMessage="Invalid amount. Include dollar sign, commas, and cents. Cents are mandatory." disabled> |
| 806 |
|
| 807 |
<hr class="spacer"> |
| 808 |
|
| 809 |
<h2>dijit.form.NumberSpinner max=100</h2> |
| 810 |
<label for="spinner1">Enabled: </label> |
| 811 |
<input dojoType="dijit.form.NumberSpinner" constraints="{max:100,places:0}" id="spinner1" value="10"> |
| 812 |
<label for="spinner2">Disabled: </label> |
| 813 |
<input dojoType="dijit.form.NumberSpinner" constraints="{max:100,places:0}" id="spinner2" value="10" disabled> |
| 814 |
|
| 815 |
</div> |
| 816 |
|
| 817 |
<div id="selectTab" dojoType="dijit.layout.ContentPane" title="Select Widgets" style="padding:10px;display:none;"> |
| 818 |
|
| 819 |
<h2>dijit.form.Select</h2> |
| 820 |
<label for="selectEnabled">Enabled: </label> |
| 821 |
<div id="selectEnabled" value="AK" dojoType="dijit.form.Select"> |
| 822 |
<span value="AL"><b>Alabama</b></span> |
| 823 |
<span value="AK"><font color="red">A</font><font color="orange">l</font><font color="yellow">a</font><font color="green">s</font><font color="blue">k</font><font color="purple">a</font></span> |
| 824 |
<span value="AZ"><i>Arizona</i></span> |
| 825 |
<span value="AR"><span class="ark">Arkansas</span></span> |
| 826 |
<span value="CA"><span style="font-size:25%">C</span><span style="font-size:50%">a</span><span style="font-size:75%">l</span><span style="font-size:90%">i</span><span style="font-size:100%">f</span><span style="font-size:125%">o</span><span style="font-size:133%">r</span><span style="font-size:150%">n</span><span style="font-size:175%">i</span><span style="font-size:200%">a</span></span> |
| 827 |
<span value="NM" disabled="disabled">New<br> Mexico</span> |
| 828 |
</div> |
| 829 |
|
| 830 |
<label for="selectDisabled">Disabled: </label> |
| 831 |
<div id="selectDisabled" value="AK" dojoType="dijit.form.Select" disabled> |
| 832 |
<span value="AL"><b>Alabama</b></span> |
| 833 |
<span value="AK"><font color="red">A</font><font color="orange">l</font><font color="yellow">a</font><font color="green">s</font><font color="blue">k</font><font color="purple">a</font></span> |
| 834 |
<span value="AZ"><i>Arizona</i></span> |
| 835 |
<span value="AR"><span class="ark">Arkansas</span></span> |
| 836 |
<span value="CA"><span style="font-size:25%">C</span><span style="font-size:50%">a</span><span style="font-size:75%">l</span><span style="font-size:90%">i</span><span style="font-size:100%">f</span><span style="font-size:125%">o</span><span style="font-size:133%">r</span><span style="font-size:150%">n</span><span style="font-size:175%">i</span><span style="font-size:200%">a</span></span> |
| 837 |
<span value="NM" disabled="disabled">New<br> Mexico</span> |
| 838 |
</div> |
| 839 |
|
| 840 |
<hr class="spacer"> |
| 841 |
|
| 842 |
<h2>dijit.form.FilteringSelect</h2> |
| 843 |
<label for="filteringSelect">Enabled w/placeHolder: </label> |
| 844 |
<input dojoType="dijit.form.FilteringSelect" |
| 845 |
placeHolder="State" |
| 846 |
store="stateStore" |
| 847 |
searchAttr="name" |
| 848 |
name="state2" |
| 849 |
id="filteringSelect" |
| 850 |
> |
| 851 |
<label for="filteringSelect2">Disabled w/placeHolder: </label> |
| 852 |
<input dojoType="dijit.form.FilteringSelect" |
| 853 |
placeHolder="State" |
| 854 |
store="stateStore" |
| 855 |
searchAttr="name" |
| 856 |
name="state2" |
| 857 |
id="filteringSelect2" |
| 858 |
disabled |
| 859 |
> |
| 860 |
<label for="filteringSelect3">Disabled w/value: </label> |
| 861 |
<input dojoType="dijit.form.FilteringSelect" |
| 862 |
value="California" |
| 863 |
store="stateStore" |
| 864 |
searchAttr="name" |
| 865 |
name="state3" |
| 866 |
id="filteringSelect3" |
| 867 |
disabled |
| 868 |
> |
| 869 |
|
| 870 |
|
| 871 |
</div> |
| 872 |
|
| 873 |
<div id="textareaTab" dojoType="dijit.layout.ContentPane" title="Textarea" style="padding:10px;"> |
| 874 |
|
| 875 |
|
| 876 |
|
| 877 |
<h2>dijit.form.Textarea</h2> |
| 878 |
<p>Enabled:</p> |
| 879 |
<textarea dojoType="dijit.form.Textarea" name="areText">This text area will expand and contract as you type ‪text.‬ |
| 880 |
|
| 881 |
Lorem ipsum dolor sit ‪amet,‬ |
| 882 |
consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet |
| 883 |
dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci |
| 884 |
tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo ‪consequat.‬ |
| 885 |
</textarea> |
| 886 |
|
| 887 |
<br> |
| 888 |
<p>Disabled:</p> |
| 889 |
<textarea dojoType="dijit.form.Textarea" name="areText2" disabled>This text |
| 890 |
area is disabled and you shouldn't be able to type in ‪it.‬ |
| 891 |
</textarea> |
| 892 |
|
| 893 |
|
| 894 |
<h2>dijit.form.SimpleTextarea</h2> |
| 895 |
<p></p> |
| 896 |
<p>Enabled:</p> |
| 897 |
<textarea dojoType="dijit.form.SimpleTextarea" name="areText">This text area has a constant height and displays a scrollbar when ‪necessary.‬ |
| 898 |
|
| 899 |
Lorem ipsum dolor sit ‪amet,‬ |
| 900 |
consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet |
| 901 |
dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci |
| 902 |
tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis |
| 903 |
autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie ‪consequat,‬ |
| 904 |
vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio |
| 905 |
dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait |
| 906 |
nulla ‪facilisi.‬ |
| 907 |
</textarea> |
| 908 |
|
| 909 |
<p>Disabled:</p> |
| 910 |
<textarea dojoType="dijit.form.SimpleTextarea" name="areText2" disabled>Lorem ipsum dolor sit ‪amet,‬ |
| 911 |
consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet |
| 912 |
dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci |
| 913 |
tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis |
| 914 |
autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie ‪consequat,‬ |
| 915 |
vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio |
| 916 |
dignissim qui blandit praesent luptatum zzril delenit augue duis dolore te feugait |
| 917 |
nulla ‪facilisi.‬ |
| 918 |
</textarea> |
| 919 |
</div> |
| 920 |
|
| 921 |
<div id="editorTab" dojoType="dijit.layout.ContentPane" title="Editor" style="padding:10px;"> |
| 922 |
<p>Enabled:</p> |
| 923 |
|
| 924 |
|
| 925 |
|
| 926 |
|
| 927 |
|
| 928 |
|
| 929 |
<div height="175" dojoType="dijit.Editor" extraPlugins="['|', 'createLink', 'fontName']" styleSheets="../themes/claro/document.css"> |
| 930 |
<ul> |
| 931 |
<li>Lorem <a href="http://dojotoolkit.org">and a link</a>, what do you think?</li> |
| 932 |
<li>This is the Editor with a Toolbar attached.</li> |
| 933 |
</ul> |
| 934 |
</div> |
| 935 |
<p>Disabled:</p> |
| 936 |
<div height="175" dojoType="dijit.Editor" extraPlugins="['|', 'createLink', 'fontName']" styleSheets="../themes/claro/document.css" disabled="true"> |
| 937 |
<ul> |
| 938 |
<li>Lorem <a href="http://dojotoolkit.org">and a link</a>, what do you think?</li> |
| 939 |
<li>This is the Editor with a Toolbar attached.</li> |
| 940 |
</ul> |
| 941 |
</div> |
| 942 |
</div> |
| 943 |
|
| 944 |
|
| 945 |
<div dojoType="dijit.layout.ContentPane" title="Sliders" style="padding:10px;display:none;"> |
| 946 |
|
| 947 |
|
| 948 |
|
| 949 |
|
| 950 |
<h2>Enabled</h2> |
| 951 |
<div style="float:right;"> |
| 952 |
<div dojoType="dijit.form.VerticalSlider" |
| 953 |
onChange="dojo.byId('slider2input').value=arguments[0];" |
| 954 |
value="10" |
| 955 |
maximum="100" |
| 956 |
minimum="0" |
| 957 |
discreteValues="11" |
| 958 |
style="height:176px; clear:both;" |
| 959 |
id="slider2"> |
| 960 |
<ol dojoType="dijit.form.VerticalRuleLabels" container="leftDecoration"style="width:2em;" labelStyle="right:0px;"> |
| 961 |
<li>0 |
| 962 |
<li>100 |
| 963 |
</ol> |
| 964 |
|
| 965 |
<div dojoType="dijit.form.VerticalRule" container="leftDecoration" count=11 style="width:5px;"></div> |
| 966 |
<div dojoType="dijit.form.VerticalRule" container="rightDecoration" count=11 style="width:5px;"></div> |
| 967 |
<ol dojoType="dijit.form.VerticalRuleLabels" container="rightDecoration"style="width:2em;" maximum="100" count="6" numericMargin="1" constraints="{pattern:'#'}"></ol> |
| 968 |
</div> |
| 969 |
<br> Slider2 Value:<input disabled id="slider2input" size="3" value="10" autocomplete="off"> |
| 970 |
</div> |
| 971 |
|
| 972 |
<div dojoType="dijit.form.HorizontalSlider" |
| 973 |
onChange="dojo.byId('slider1input').value=dojo.number.format(arguments[0]/100,{places:1,pattern:'#%'});" |
| 974 |
value="10" |
| 975 |
maximum="100" |
| 976 |
minimum="0" |
| 977 |
showButtons="false" |
| 978 |
intermediateChanges="true" |
| 979 |
style="width:50%; height: 20px;" |
| 980 |
id="horizontal1"> |
| 981 |
<ol dojoType="dijit.form.HorizontalRuleLabels" container="topDecoration" style="height:1.2em;font-size:75%;" numericMargin="1" count="6"></ol> |
| 982 |
<div dojoType="dijit.form.HorizontalRule" container="topDecoration" count=11 style="height:5px;"></div> |
| 983 |
<div dojoType="dijit.form.HorizontalRule" container="bottomDecoration" count=5 style="height:5px;"></div> |
| 984 |
<ol dojoType="dijit.form.HorizontalRuleLabels" container="bottomDecoration" style="height:1em;font-size:75%;"> |
| 985 |
<li>lowest |
| 986 |
<li>normal |
| 987 |
<li>highest |
| 988 |
</ol> |
| 989 |
|
| 990 |
</div> |
| 991 |
<br>Value: <input disabled id="slider1input" size="5" value="10.0%" autocomplete="off"> |
| 992 |
|
| 993 |
<div dojoType="dijit.form.HorizontalSlider" |
| 994 |
minimum="1" |
| 995 |
value="2" |
| 996 |
maximum="3" |
| 997 |
discreteValues="3" |
| 998 |
showButtons="false" |
| 999 |
intermediateChanges="true" |
| 1000 |
style="width:300px; height: 40px;" |
| 1001 |
id="horizontal2"> |
| 1002 |
<div dojoType="dijit.form.HorizontalRule" container="bottomDecoration" count=3 style="height:5px;"></div> |
| 1003 |
<ol dojoType="dijit.form.HorizontalRuleLabels" container="bottomDecoration"style="height:1em;font-size:75%;"> |
| 1004 |
<li><img width=10 height=10 src="../tests/images/note.gif"><br><span style="font-size: small">small</span> |
| 1005 |
<li><img width=15 height=15 src="../tests/images/note.gif"><br><span style="font-size: medium">medium</span> |
| 1006 |
|
| 1007 |
<li><img width=20 height=20 src="../tests/images/note.gif"><br><span style="font-size: large">large</span> |
| 1008 |
</ol> |
| 1009 |
</div> |
| 1010 |
|
| 1011 |
<h2 style="clear:both">Disabled</h2> |
| 1012 |
<div style="float:right;"> |
| 1013 |
<div dojoType="dijit.form.VerticalSlider" |
| 1014 |
value="10" |
| 1015 |
maximum="100" |
| 1016 |
minimum="0" |
| 1017 |
discreteValues="11" |
| 1018 |
style="height:175px; clear:both" |
| 1019 |
disabled> |
| 1020 |
<ol dojoType="dijit.form.VerticalRuleLabels" container="leftDecoration"style="width:2em;" labelStyle="right:0px;"> |
| 1021 |
<li>0 |
| 1022 |
<li>100 |
| 1023 |
</ol> |
| 1024 |
|
| 1025 |
<div dojoType="dijit.form.VerticalRule" container="leftDecoration" count=11 style="width:5px;"></div> |
| 1026 |
<div dojoType="dijit.form.VerticalRule" container="rightDecoration" count=11 style="width:5px;"></div> |
| 1027 |
<ol dojoType="dijit.form.VerticalRuleLabels" container="rightDecoration"style="width:2em;" maximum="100" count="6" numericMargin="1" constraints="{pattern:'#'}"></ol> |
| 1028 |
</div> |
| 1029 |
</div> |
| 1030 |
<div dojoType="dijit.form.HorizontalSlider" |
| 1031 |
value="10" |
| 1032 |
maximum="100" |
| 1033 |
minimum="0" |
| 1034 |
showButtons="false" |
| 1035 |
intermediateChanges="true" |
| 1036 |
style="width:50%; height: 20px;" |
| 1037 |
disabled> |
| 1038 |
<ol dojoType="dijit.form.HorizontalRuleLabels" container="topDecoration" style="height:1.2em;font-size:75%;" numericMargin="1" count="6"></ol> |
| 1039 |
<div dojoType="dijit.form.HorizontalRule" container="topDecoration" count=11 style="height:5px;"></div> |
| 1040 |
<div dojoType="dijit.form.HorizontalRule" container="bottomDecoration" count=5 style="height:5px;"></div> |
| 1041 |
<ol dojoType="dijit.form.HorizontalRuleLabels" container="bottomDecoration" style="height:1em;font-size:75%;"> |
| 1042 |
<li>lowest |
| 1043 |
<li>normal |
| 1044 |
<li>highest |
| 1045 |
</ol> |
| 1046 |
|
| 1047 |
</div> |
| 1048 |
|
| 1049 |
<div dojoType="dijit.form.HorizontalSlider" |
| 1050 |
minimum="1" |
| 1051 |
value="2" |
| 1052 |
maximum="3" |
| 1053 |
discreteValues="3" |
| 1054 |
showButtons="false" |
| 1055 |
intermediateChanges="true" |
| 1056 |
style="width:300px; height: 40px;" |
| 1057 |
disabled> |
| 1058 |
<div dojoType="dijit.form.HorizontalRule" container="bottomDecoration" count=3 style="height:5px;"></div> |
| 1059 |
<ol dojoType="dijit.form.HorizontalRuleLabels" container="bottomDecoration"style="height:1em;font-size:75%;"> |
| 1060 |
<li><img width=10 height=10 src="../tests/images/note.gif"><br><span style="font-size: small">small</span> |
| 1061 |
<li><img width=15 height=15 src="../tests/images/note.gif"><br><span style="font-size: medium">medium</span> |
| 1062 |
<li><img width=20 height=20 src="../tests/images/note.gif"><br><span style="font-size: large">large</span> |
| 1063 |
</ol> |
| 1064 |
</div> |
| 1065 |
</div> |
| 1066 |
|
| 1067 |
<div id="variousTab" dojoType="dijit.layout.ContentPane" title="Various Dijits" |
| 1068 |
style="padding:10px; display:none;"> |
| 1069 |
|
| 1070 |
|
| 1071 |
<h2>TitlePane</h2> |
| 1072 |
<div dojoType="dijit.TitlePane" title="my pane" width="275"> |
| 1073 |
<p>This is a title pane. It can be expanded and collapsed.</p> |
| 1074 |
|
| 1075 |
<p>Sed sollicitudin suscipit risus. Nam |
| 1076 |
ullamcorper. Sed nisl lectus, pellentesque nec, |
| 1077 |
malesuada eget, ornare a, libero. Lorem ipsum dolor |
| 1078 |
sit amet, consectetuer adipiscing elit.</p> |
| 1079 |
|
| 1080 |
</div> |
| 1081 |
|
| 1082 |
<hr class="spacer"> |
| 1083 |
|
| 1084 |
<h2>ProgressBar</h2> |
| 1085 |
<div style="width:400px;" maximum="200" id="setTestBar" |
| 1086 |
progress="20" dojoType="dijit.ProgressBar"></div> |
| 1087 |
|
| 1088 |
Indeterminate: |
| 1089 |
<div style="width:400px;" indeterminate="true" dojoType="dijit.ProgressBar"></div> |
| 1090 |
|
| 1091 |
</div> |
| 1092 |
|
| 1093 |
<div id="InlineEditBoxTab" dojoType="dijit.layout.ContentPane" title="InlineEditBox" |
| 1094 |
style="padding:10px; display:none;"> |
| 1095 |
|
| 1096 |
<h2 class="testTitle">dijit.InlineEditBox + dijit.form.TextBox on <h3></h2> |
| 1097 |
|
| 1098 |
(HTML before) |
| 1099 |
<h3 id="editable" style="font-size:larger;" dojoType="dijit.InlineEditBox" onChange="myHandler(this.id,arguments[0])"> |
| 1100 |
Edit me - I trigger the onChange callback |
| 1101 |
</h3> |
| 1102 |
(HTML after) |
| 1103 |
|
| 1104 |
<hr class="spacer"> |
| 1105 |
|
| 1106 |
<h2>dijit.InlineEditBox + dijit.form.Textarea</h2> |
| 1107 |
|
| 1108 |
(HTML before) |
| 1109 |
<p id="areaEditable" dojoType="dijit.InlineEditBox" editor="dijit.form.Textarea" autoSave="false"> |
| 1110 |
I'm one big ‪paragraph.‬ Go ahead and edit ‪me.‬ I dare ‪you.‬ |
| 1111 |
The quick brown fox jumped over the lazy ‪dog.‬ Blah blah blah blah blah blah ‪blah ...‬ |
| 1112 |
</p> |
| 1113 |
(HTML after) |
| 1114 |
|
| 1115 |
<p> |
| 1116 |
These links will |
| 1117 |
<a href="#" onClick="dijit.byId('areaEditable').set('disabled', true)">disable</a> / |
| 1118 |
<a href="#" onClick="dijit.byId('areaEditable').set('disabled', false)">enable</a> |
| 1119 |
the text area above. |
| 1120 |
</p> |
| 1121 |
|
| 1122 |
<hr class="spacer"> |
| 1123 |
|
| 1124 |
<h2>dijit.form.DateTextBox</h2> |
| 1125 |
|
| 1126 |
(HTML inline before) |
| 1127 |
|
| 1128 |
<span id="backgroundArea" dojoType="dijit.InlineEditBox" editor="dijit.form.DateTextBox" width="170px"></span> |
| 1129 |
(HTML after) |
| 1130 |
<hr class="spacer"> |
| 1131 |
|
| 1132 |
<h2>dijit.form.TimeTextBox</h2> |
| 1133 |
|
| 1134 |
(HTML inline before) |
| 1135 |
|
| 1136 |
<span id="timePicker" dojoType="dijit.InlineEditBox" editor="dijit.form.TimeTextBox" width="150px"></span> |
| 1137 |
(HTML after) |
| 1138 |
|
| 1139 |
<hr class="spacer"> |
| 1140 |
|
| 1141 |
|
| 1142 |
<h2>dijit.form.FilteringSelect + Inline + remote data store</h2> |
| 1143 |
(HTML inline before) |
| 1144 |
<span id="backgroundArea2" dojoType="dijit.InlineEditBox" editor="dijit.form.FilteringSelect" |
| 1145 |
editorParams="{store: stateStore, autoComplete: true, promptMessage: 'Please enter a state'}" |
| 1146 |
width="300px"> |
| 1147 |
Indiana |
| 1148 |
</span> |
| 1149 |
(HTML after) |
| 1150 |
|
| 1151 |
</div> |
| 1152 |
|
| 1153 |
<div id="dndTab" dojoType="dijit.layout.ContentPane" title="DnD" |
| 1154 |
style="padding:10px; display:none;"> |
| 1155 |
<div style="float:left; margin:5px;"> |
| 1156 |
<h3>Source 1</h3> |
| 1157 |
<div dojoType="dojo.dnd.Source" style="border:3px solid #ccc; padding: 1em 3em; "> |
| 1158 |
<div class="dojoDndItem">Item <strong>X</strong></div> |
| 1159 |
<div class="dojoDndItem">Item <strong>Y</strong></div> |
| 1160 |
<div class="dojoDndItem">Item <strong>Z</strong></div> |
| 1161 |
</div> |
| 1162 |
</div> |
| 1163 |
<div style="float:left; margin:5px; "> |
| 1164 |
<h3>Source 2</h3> |
| 1165 |
<div dojoType="dojo.dnd.Source" style="border:3px solid #ccc; padding: 1em 3em; "> |
| 1166 |
<div class="dojoDndItem">Item <strong>1</strong></div> |
| 1167 |
<div class="dojoDndItem">Item <strong>2</strong></div> |
| 1168 |
<div class="dojoDndItem">Item <strong>3</strong></div> |
| 1169 |
</div> |
| 1170 |
</div> |
| 1171 |
</div> |
| 1172 |
|
| 1173 |
<div id="closableTab" dojoType="dijit.layout.ContentPane" title="Closable" |
| 1174 |
style="display:none; padding:10px; " closable="true"> |
| 1175 |
This pane is closable, just for the icon ... |
| 1176 |
</div> |
| 1177 |
</div> |
| 1178 |
|
| 1179 |
|
| 1180 |
<div dojoType="dijit.layout.TabContainer" id="bottomTabs" |
| 1181 |
tabPosition="bottom" selectedChild="btab1" region="bottom" splitter="true" tabStrip="true"> |
| 1182 |
|
| 1183 |
|
| 1184 |
<div id="btab1" dojoType="dijit.layout.ContentPane" title="Info" style=" padding:10px; "> |
| 1185 |
<p>You can explore this single page after applying a Theme |
| 1186 |
for use in creation of your own theme.</p> |
| 1187 |
|
| 1188 |
<p>I am whole slew of Widgets on a page. Jump to <a href="../tests/">dijit tests</a> to |
| 1189 |
test individual components.</p> |
| 1190 |
|
| 1191 |
<p>There is a right-click [context] pop-up menu here, as well.</p> |
| 1192 |
</div> |
| 1193 |
|
| 1194 |
<div id="btab2" dojoType="dijit.layout.ContentPane" title="Alternate Themes" style="padding:20px;"> |
| 1195 |
<span id="themeData"></span> |
| 1196 |
</div> |
| 1197 |
|
| 1198 |
<div id="btab3" dojoType="dijit.layout.ContentPane" title="Bottom 3" closable="true"> |
| 1199 |
<p>I am the last Tab</p> |
| 1200 |
<div id="dialog2" dojoType="dijit.Dialog" title="Encased Dialog" style="display:none;"> |
| 1201 |
I am the second dialog. I am |
| 1202 |
parented by the Low Tab Pane #3 |
| 1203 |
</div> |
| 1204 |
</div> |
| 1205 |
|
| 1206 |
</div> |
| 1207 |
|
| 1208 |
</div> |
| 1209 |
|
| 1210 |
|
| 1211 |
<div id="dialog1" dojoType="dijit.Dialog" |
| 1212 |
title="Floating Modal Dialog from href" style="display:none; width: 400px;" |
| 1213 |
href="../tests/layout/getResponse.php?delay=3000&messId=3" refreshOnShow="true"></div> |
| 1214 |
<div id="dialogAB" dojoType="dijit.Dialog" |
| 1215 |
title="Floating Modal Dialog" style="display:none;"> |
| 1216 |
<div class="dijitDialogPaneContentArea"> |
| 1217 |
<table> |
| 1218 |
<tr> |
| 1219 |
<td><label for="name">Name: </label></td> |
| 1220 |
<td><input dojoType=dijit.form.TextBox type="text" name="name" id="name"></td> |
| 1221 |
</tr> |
| 1222 |
<tr> |
| 1223 |
<td><label for="loc">Location: </label></td> |
| 1224 |
<td><input dojoType=dijit.form.TextBox type="text" name="loc" id="loc"></td> |
| 1225 |
</tr> |
| 1226 |
<tr> |
| 1227 |
<td><label for="date">Date: </label></td> |
| 1228 |
<td><input dojoType=dijit.form.DateTextBox type="text" name="date" id="date"></td> |
| 1229 |
</tr> |
| 1230 |
</table> |
| 1231 |
</div> |
| 1232 |
|
| 1233 |
|
| 1234 |
<div class="dijitDialogPaneActionBar"> |
| 1235 |
<button dojoType="dijit.form.Button" type="submit" id="ABdialog1button1">OK</button> |
| 1236 |
<button dojoType="dijit.form.Button" type="button" onClick="dijit.byId('dialogAB').onCancel();" |
| 1237 |
id="ABdialog1button2">Cancel</button> |
| 1238 |
</div> |
| 1239 |
</div> |
| 1240 |
|
| 1241 |
</body> |
| 1242 |
</html> |