Sha256: 6d84da361d580aeb47fd12127e69ea7da5535bf2d92db6e066289cbaf834f025
Contents?: true
Size: 1.95 KB
Versions: 7
Compression:
Stored size: 1.95 KB
Contents
<!-- quirks mode --> <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"> <head> <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/> <title>Box Model (quirks)</title> <style type="text/css"> .box { width: 48px; padding: 25px; background-color: yellow; border: 1px solid black; } .dj_borderbox .box { background-color: orange; width: 100px; } .ruler { background: url('http://sam-i-am.com/work/sandbox/measuring/ruler.gif') no-repeat; height: 60px; } </style> <script type="text/javascript" src="../../../dojo/dojo.js" djConfig="isDebug:true"></script> <script type="text/javascript" src="../../_base/sniff.js"></script> <script type="text/javascript"> dojo.require("doh.runner"); dojo.addOnLoad(function() { var node = dojo.byId("box1"); var reportNode = dojo.byId("log") var inner = (reportNode.textContent) ? "textContent": "innerText"; reportNode.innerHTML = dojo.toJson({ boxModel: dojo.boxModel, isQuirks: dojo.isQuirks, width: dojo.style(node, "width"), marginBoxWidth: dojo.marginBox(node).w, htmlClassName: dojo.doc.documentElement.className }, 1); doh.register("dijit.tests._base.sniffQuirks", [ function test_boxModel(t) { // ensure the box-model correction in the stylesheet have been correctly applied // we measure the node - it should be 100px t.is(100, node.offsetWidth); } ]); doh.run(); }); </script> </head> <body> <h1>CSS Sniff test dj_boxmodel in quirks mode</h1> <div style="background-color: orange; float:left"> <div id="box1" class="box"> <div style="background-color: white; height: 20px"></div> </div> </div> <div style="clear:both"></div> <div class="ruler"></div> <div style="border: 1px solid #666; background-color: #dedede"><xmp id="log"></xmp></div> </body> </html>
Version data entries
7 entries across 7 versions & 1 rubygems