| 1 |
<!-- |
| 2 |
|
| 3 |
When changing this, make sure that style_quirks_test.html is kept in sync. |
| 4 |
|
| 5 |
--> |
| 6 |
<!-- |
| 7 |
Copyright 2017 The Closure Library Authors. All Rights Reserved. |
| 8 |
|
| 9 |
Use of this source code is governed by the Apache License, Version 2.0. |
| 10 |
See the COPYING file for details. |
| 11 |
--> |
| 12 |
<meta name="viewport" content="width=device-width, initial-scale=1.0, |
| 13 |
maximum-scale=1.0, minimum-scale=1.0, user-scalable=0"> |
| 14 |
<style> |
| 15 |
|
| 16 |
i { |
| 17 |
font-family: Times, sans-serif; |
| 18 |
font-size: 5em; |
| 19 |
} |
| 20 |
|
| 21 |
#testEl5 { |
| 22 |
display: none; |
| 23 |
} |
| 24 |
|
| 25 |
#styleTest1 { |
| 26 |
width: 120px; |
| 27 |
text-decoration: underline; |
| 28 |
} |
| 29 |
|
| 30 |
#bgcolorTest0 { |
| 31 |
background-color: #f00; |
| 32 |
} |
| 33 |
|
| 34 |
#bgcolorTest1 { |
| 35 |
background-color: #ff0000; |
| 36 |
} |
| 37 |
|
| 38 |
#bgcolorTest2 { |
| 39 |
background-color: rgb(255, 0, 0); |
| 40 |
} |
| 41 |
|
| 42 |
#bgcolorTest3 { |
| 43 |
background-color: rgb(100%, 0%, 0%); |
| 44 |
} |
| 45 |
|
| 46 |
#bgcolorTest5 { |
| 47 |
background-color: lightblue; |
| 48 |
} |
| 49 |
|
| 50 |
#bgcolorTest6 { |
| 51 |
background-color: inherit; |
| 52 |
} |
| 53 |
|
| 54 |
#bgcolorTest7 { |
| 55 |
background-color: transparent; |
| 56 |
} |
| 57 |
|
| 58 |
.rtl { |
| 59 |
direction: rtl; |
| 60 |
} |
| 61 |
|
| 62 |
.ltr { |
| 63 |
direction: ltr; |
| 64 |
} |
| 65 |
|
| 66 |
#pos-scroll-abs { |
| 67 |
position: absolute; |
| 68 |
top: 200px; |
| 69 |
left: 100px; |
| 70 |
} |
| 71 |
|
| 72 |
#pos-scroll-abs-1 { |
| 73 |
overflow: scroll; |
| 74 |
width: 100px; |
| 75 |
height: 100px; |
| 76 |
} |
| 77 |
|
| 78 |
#pos-scroll-abs-2 { |
| 79 |
position: absolute; |
| 80 |
top: 100px; |
| 81 |
left: 100px; |
| 82 |
width: 500px; |
| 83 |
background-color: pink; |
| 84 |
} |
| 85 |
|
| 86 |
#abs-upper-left { |
| 87 |
position: absolute; |
| 88 |
top: 0px; |
| 89 |
left: 0px; |
| 90 |
} |
| 91 |
|
| 92 |
#no-text-font-styles { |
| 93 |
font-family: "Helvetica", Times, serif; |
| 94 |
font-size: 30px; |
| 95 |
} |
| 96 |
|
| 97 |
.century { |
| 98 |
font-family: "Comic Sans MS", "Century Schoolbook L", serif; |
| 99 |
} |
| 100 |
|
| 101 |
#size-a, |
| 102 |
#size-e { |
| 103 |
width: 100px; |
| 104 |
height: 100px; |
| 105 |
background: red; |
| 106 |
padding: 0; |
| 107 |
border-style: solid; |
| 108 |
border-color: black; |
| 109 |
border-width: 0; |
| 110 |
} |
| 111 |
|
| 112 |
#size-b { |
| 113 |
width: 100px; |
| 114 |
height: 100px; |
| 115 |
background: red; |
| 116 |
border: 10px solid black; |
| 117 |
} |
| 118 |
|
| 119 |
#size-c { |
| 120 |
width: 100px; |
| 121 |
height: 100px; |
| 122 |
background: red; |
| 123 |
border: 10px solid black; |
| 124 |
padding: 10px; |
| 125 |
overflow: auto; |
| 126 |
} |
| 127 |
|
| 128 |
#size-d { |
| 129 |
width: 10em; |
| 130 |
height: 2cm; |
| 131 |
background: red; |
| 132 |
border: thick solid black; |
| 133 |
padding: 2mm; |
| 134 |
} |
| 135 |
|
| 136 |
#size-f { |
| 137 |
border-width: 0; |
| 138 |
margin: 0; |
| 139 |
padding: 0; |
| 140 |
} |
| 141 |
|
| 142 |
#css-position-absolute { |
| 143 |
position: absolute; |
| 144 |
} |
| 145 |
|
| 146 |
#css-overflow-hidden { |
| 147 |
overflow: hidden; |
| 148 |
} |
| 149 |
|
| 150 |
#css-z-index-200 { |
| 151 |
position:relative; |
| 152 |
z-index: 200; |
| 153 |
} |
| 154 |
|
| 155 |
#css-text-align-center { |
| 156 |
text-align: center; |
| 157 |
} |
| 158 |
|
| 159 |
#css-cursor-pointer { |
| 160 |
cursor: pointer; |
| 161 |
} |
| 162 |
|
| 163 |
#test-opacity { |
| 164 |
opacity: 0.5; |
| 165 |
-moz-opacity: 0.5; |
| 166 |
filter: alpha(opacity=50); |
| 167 |
} |
| 168 |
|
| 169 |
#test-frame-offset { |
| 170 |
display: block; |
| 171 |
position: absolute; |
| 172 |
top: 50px; |
| 173 |
left: 50px; |
| 174 |
width: 50px; |
| 175 |
height: 50px; |
| 176 |
} |
| 177 |
|
| 178 |
#test-visible { |
| 179 |
background: yellow; |
| 180 |
position: absolute; |
| 181 |
overflow: hidden; |
| 182 |
} |
| 183 |
|
| 184 |
#test-visible2 { |
| 185 |
background: #ebebeb; |
| 186 |
position: absolute; |
| 187 |
overflow: hidden; |
| 188 |
} |
| 189 |
|
| 190 |
.scrollable-container { |
| 191 |
border: 8px solid blue; |
| 192 |
padding: 16px; |
| 193 |
margin: 32px; |
| 194 |
width: 100px; |
| 195 |
height: 100px; |
| 196 |
overflow: auto; |
| 197 |
position: absolute; |
| 198 |
left: 400px; |
| 199 |
top: 0; |
| 200 |
} |
| 201 |
|
| 202 |
.scrollable-container-item { |
| 203 |
margin: 1px; |
| 204 |
border: 2px solid gray; |
| 205 |
padding: 4px; |
| 206 |
width: auto; |
| 207 |
height: 20px; |
| 208 |
} |
| 209 |
|
| 210 |
.svg-container { |
| 211 |
width: 150px; |
| 212 |
height: 150px; |
| 213 |
overflow-x: hidden; |
| 214 |
overflow-y: auto; |
| 215 |
} |
| 216 |
|
| 217 |
#translation { |
| 218 |
position: absolute; |
| 219 |
z-index: 10; |
| 220 |
left: 10px; |
| 221 |
top: 10px; |
| 222 |
width: 10px; |
| 223 |
height: 10px; |
| 224 |
background-color: blue; |
| 225 |
-webkit-transform: translate(20px, 30px); |
| 226 |
-ms-transform: translate(20px, 30px); |
| 227 |
-o-transform: translate(20px, 30px); |
| 228 |
-moz-transform: translate(20px, 30px); |
| 229 |
transform: translate(20px, 30px); |
| 230 |
} |
| 231 |
|
| 232 |
</style> |
| 233 |
</head> |
| 234 |
<body> |
| 235 |
<div id="testEl"> |
| 236 |
<span>Test Element</span> |
| 237 |
</div> |
| 238 |
|
| 239 |
<div id="testEl5"> |
| 240 |
<span>Test Element 5</span> |
| 241 |
</div> |
| 242 |
|
| 243 |
<table id="table1"> |
| 244 |
<tr> |
| 245 |
<td id="td1">td1</td> |
| 246 |
</tr> |
| 247 |
</table> |
| 248 |
|
| 249 |
<span id="span0">span0</span> |
| 250 |
|
| 251 |
<ul> |
| 252 |
<li id="li1">li1</li> |
| 253 |
</ul> |
| 254 |
|
| 255 |
<span id="span1" class="test1"></span> |
| 256 |
<span id="span2" class="test1"></span> |
| 257 |
<span id="span3" class="test2"></span> |
| 258 |
<span id="span4" class="test3"></span> |
| 259 |
<span id="span5" class="test1"></span> |
| 260 |
<span id="span6" class="test1"></span> |
| 261 |
|
| 262 |
<p id="p1"></p> |
| 263 |
|
| 264 |
<div id="styleTest1"></div> |
| 265 |
<div id="styleTest2" style="width:100px;text-decoration:underline"></div> |
| 266 |
<div id="styleTest3"></div> |
| 267 |
|
| 268 |
<!-- Paragraph to test element child and sibling --> |
| 269 |
<p id="p2"> |
| 270 |
<!-- Comment --> |
| 271 |
a |
| 272 |
<b id="b1">c</b> |
| 273 |
d |
| 274 |
<!-- Comment --> |
| 275 |
e |
| 276 |
<b id="b2">f</b> |
| 277 |
g |
| 278 |
<!-- Comment --> |
| 279 |
</p> |
| 280 |
|
| 281 |
<p style="background-color: #eee"> |
| 282 |
<span id="bgcolorTest0">1</span> |
| 283 |
<span id="bgcolorTest1">1</span> |
| 284 |
<span id="bgcolorTest2">2</span> |
| 285 |
<span id="bgcolorTest3">3</span> |
| 286 |
<span id="bgcolorTest4" style="background-color:#ff0000">4</span> |
| 287 |
<span id="bgcolorTest5">5</span> |
| 288 |
<span id="bgcolorTest6">6</span> |
| 289 |
<span id="bgcolorTest7">7</span> |
| 290 |
<span id="bgcolorDest">Dest</span> |
| 291 |
<span id="installTest0">Styled 0</span> |
| 292 |
<span id="installTest1">Styled 1</span> |
| 293 |
</p> |
| 294 |
|
| 295 |
<div class='rtl-test' dir='ltr' id='rtl1'> |
| 296 |
<div dir='rtl' id='rtl2'>right to left</div> |
| 297 |
<div dir='ltr' id='rtl3'>left to right</div> |
| 298 |
<div id='rtl4'>left to right (inherited)</div> |
| 299 |
<div id='rtl5' style="direction: rtl">right to left (style)</div> |
| 300 |
<div id='rtl6' style="direction: ltr">left to right (style)</div> |
| 301 |
<div id='rtl7' class=rtl>right to left (css)</div> |
| 302 |
<div id='rtl8' class=ltr>left to right (css)</div> |
| 303 |
<div class=rtl> |
| 304 |
<div id='rtl9'>right to left (css)</div> |
| 305 |
</div> |
| 306 |
<div class=ltr> |
| 307 |
<div id='rtl10'>left to right (css)</div> |
| 308 |
</div> |
| 309 |
</div> |
| 310 |
|
| 311 |
<div id="unselectable-gecko" style="-moz-user-select:none">no-select</div> |
| 312 |
<div id="unselectable-webkit" style="-webkit-user-select:none">no-select</div> |
| 313 |
<div id="unselectable-ie" unselectable="on">no-select</div> |
| 314 |
|
| 315 |
<div id="make-unselectable"> |
| 316 |
<p>Can't touch this <aside>(Oh-oh oh oh-oh)</aside></p> |
| 317 |
<div><em>Stop.</em> Hammer <math><mo>×</mo></math></div> |
| 318 |
</div> |
| 319 |
|
| 320 |
<div id="pos-scroll-abs"> |
| 321 |
|
| 322 |
<p>Some text some text some text some text some text some text some text |
| 323 |
some text some text some text. Some text some text some text some text some |
| 324 |
text some text some text some text some text some text. Some text some text |
| 325 |
some text some text some text some text some text some text some text some |
| 326 |
text. Some text some text some text some text some text some text some text |
| 327 |
some text some text some text. |
| 328 |
|
| 329 |
<p>Some text some text some text some text some text some text some text |
| 330 |
some text some text some text. Some text some text some text some text some |
| 331 |
text some text some text some text some text some text. Some text some text |
| 332 |
some text some text some text some text some text some text some text some |
| 333 |
text. Some text some text some text some text some text some text some text |
| 334 |
some text some text some text. |
| 335 |
|
| 336 |
<div id="pos-scroll-abs-1"> |
| 337 |
<p>Some text some text some text some text some text some text some text |
| 338 |
some text some text some text. Some text some text some text some text |
| 339 |
some text some text some text some text some text some text. Some text |
| 340 |
some text some text some text some text some text some text some text some |
| 341 |
text some text. Some text some text some text some text some text some |
| 342 |
text some text some text some text some text. |
| 343 |
|
| 344 |
<p>Some text some text some text some text some text some text some text |
| 345 |
some text some text some text. Some text some text some text some text |
| 346 |
some text some text some text some text some text some text. Some text |
| 347 |
some text some text some text some text some text some text some text some |
| 348 |
text some text. Some text some text some text some text some text some |
| 349 |
text some text some text some text some text. |
| 350 |
|
| 351 |
<div id="pos-scroll-abs-2"> |
| 352 |
|
| 353 |
<p>Some text some text some text some text some text some text some text |
| 354 |
some text some text some text. Some text some text some text some text |
| 355 |
some text some text some text some text some text some text. Some text |
| 356 |
some text some text some text some text some text some text some text |
| 357 |
some text some text. Some text some text some text some text some text |
| 358 |
some text some text some text some text some text. |
| 359 |
|
| 360 |
</div> |
| 361 |
|
| 362 |
</div> |
| 363 |
|
| 364 |
</div> |
| 365 |
|
| 366 |
<div id="abs-upper-left"> |
| 367 |
foo |
| 368 |
</div> |
| 369 |
|
| 370 |
<div id="no-text-font-styles"> |
| 371 |
<font size="+1" face="Times,serif" id="font-tag">Times</font> |
| 372 |
<pre id="pre-font">pre text</pre> |
| 373 |
<span style="font:inherit" id="inherit-font">inherited</span> |
| 374 |
<span style="font-family:Times,sans-serif; font-size:3in" |
| 375 |
id="times-font-family">Times</span> |
| 376 |
<b id="bold-font">Bolded</b> |
| 377 |
<i id="css-html-tag-redefinition">Times</i> |
| 378 |
<span id="small-text" class="century" style="font-size:small">eensy</span> |
| 379 |
<span id="x-small-text" style="font-size:x-small">weensy</span> |
| 380 |
<span style="font:50% badFont" id="font-style-badfont"> |
| 381 |
badFont |
| 382 |
<span style="font:inherit" id="inherit-50pct-font"> |
| 383 |
same size as badFont |
| 384 |
</span> |
| 385 |
</span> |
| 386 |
<span id="icon-font" style="font:icon">Icon Font</span> |
| 387 |
</div> |
| 388 |
<span id="no-font-style">plain</span> |
| 389 |
<span style="font-family:Arial" id="nested-font">Arial<span style="font-family:Times">Times nested inside Arial</span></span> |
| 390 |
<img id="img-font-test" src=""/> |
| 391 |
|
| 392 |
<span style="font-size:25px"> |
| 393 |
<span style="font-size:12.5px" id="font-size-12-point-5-px">12.5PX</span> |
| 394 |
<span style="font-size:0.5em" id="font-size-50-pct-of-25-px">12.5PX</span> |
| 395 |
</span> |
| 396 |
|
| 397 |
<div id="size-a"></div> |
| 398 |
|
| 399 |
<div id="size-b"></div> |
| 400 |
|
| 401 |
<div id="size-c">xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxxxxxxxxxx |
| 402 |
xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx |
| 403 |
xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx |
| 404 |
xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx |
| 405 |
xxxxxxxxxxxxxxxx</div> |
| 406 |
|
| 407 |
<div id="size-d">xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxxxxxxxxxx |
| 408 |
xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx xxxxxxxx |
| 409 |
xxxxxxxx x</div> |
| 410 |
|
| 411 |
<div id="size-e"></div> |
| 412 |
|
| 413 |
<div id="size-f">hello</div> |
| 414 |
|
| 415 |
<div style="font-size: 1px"> |
| 416 |
<div style="font-size: 2em"><span id="em-font-size"></span></div> |
| 417 |
</div> |
| 418 |
|
| 419 |
<div id="no-float"></div> |
| 420 |
|
| 421 |
<div id="float-none" style="float:none"></div> |
| 422 |
|
| 423 |
<div id="float-left" style="float:left"></div> |
| 424 |
|
| 425 |
<div id="float-test"></div> |
| 426 |
|
| 427 |
<div id="position-unset"></div> |
| 428 |
<div id="style-position-relative" style="position:relative"></div> |
| 429 |
<div id="style-position-fixed" style="position:fixed"></div> |
| 430 |
<div id="css-position-absolute"></div> |
| 431 |
|
| 432 |
<div id="box-sizing-unset"></div> |
| 433 |
<div id="box-sizing-border-box" style="box-sizing: border-box; -moz-box-sizing: border-box; -webkit-box-sizing: border-box;"></div> |
| 434 |
|
| 435 |
<div id="style-overflow-scroll" style="overflow:scroll"></div> |
| 436 |
<div id="css-overflow-hidden"></div> |
| 437 |
|
| 438 |
<!-- Getting the computed z-index of an unpositioned element is unspecified. --> |
| 439 |
<div id="style-z-index-200" style="position:relative;z-index:200"></div> |
| 440 |
<div id="css-z-index-200"></div> |
| 441 |
|
| 442 |
<div id="style-text-align-right" style="text-align:right"> |
| 443 |
<div id="style-text-align-right-inner">foo</div> |
| 444 |
</div> |
| 445 |
<div id="css-text-align-center"></div> |
| 446 |
|
| 447 |
<div id="style-cursor-move" style="cursor:move"> |
| 448 |
<span id="style-cursor-move-inner">foo</span> |
| 449 |
</div> |
| 450 |
<div id="css-cursor-pointer"></div> |
| 451 |
|
| 452 |
<div id="height-test" style="display:inline-block;position:relative"> |
| 453 |
<div id="height-test-inner" style="display:inline-block"> |
| 454 |
foo |
| 455 |
</div> |
| 456 |
</div> |
| 457 |
|
| 458 |
<div id="test-opacity"></div> |
| 459 |
|
| 460 |
<iframe id="test-frame-offset"></iframe> |
| 461 |
|
| 462 |
<iframe id="test-translate-frame-standard" src="style_test_standard.html" |
| 463 |
style="overflow:auto;position:absolute;left:100px;top:150px;width:200px;height:200px;border:0px;"> |
| 464 |
</iframe> |
| 465 |
<iframe id="test-translate-frame-quirk" src="style_test_quirk.html" |
| 466 |
style="overflow:auto;position:absolute;left:100px;top:350px;width:200px;height:200px;border:0px;margin:0px;"> |
| 467 |
</iframe> |
| 468 |
|
| 469 |
<iframe |
| 470 |
id="test-visible-frame" |
| 471 |
src="style_test_iframe_standard.html" |
| 472 |
style="width: 200px; height: 200px; border: 0px;"> |
| 473 |
</iframe> |
| 474 |
|
| 475 |
<div id="test-scrollbarwidth" style="background-color: orange; width: 100px; height: 100px; overflow: auto;"> |
| 476 |
<div style='width: 200px; height: 200px; background-color: red'>Test Scroll bar width with scroll</div> |
| 477 |
</div> |
| 478 |
|
| 479 |
<div id="scrollable-container" class="scrollable-container"> |
| 480 |
<!-- |
| 481 |
Workaround for overlapping top padding of the container and top margin of |
| 482 |
the first item in Internet Explorer 6 and 7. |
| 483 |
See http://www.quirksmode.org/bugreports/archives/2005/01/IE_nested_boxes_padding_topmargin_top.html#c11285 |
| 484 |
--> |
| 485 |
<div style="height: 0"><!-- --></div> |
| 486 |
<div id="item1" class="scrollable-container-item">1</div> |
| 487 |
<div id="item2" class="scrollable-container-item">2</div> |
| 488 |
<div id="item3" class="scrollable-container-item">3</div> |
| 489 |
<div id="item4" class="scrollable-container-item">4</div> |
| 490 |
<div id="item5" class="scrollable-container-item">5</div> |
| 491 |
<div id="item6" class="scrollable-container-item">6</div> |
| 492 |
<div id="item7" class="scrollable-container-item">7</div> |
| 493 |
<div id="item8" class="scrollable-container-item">8</div> |
| 494 |
</div> |
| 495 |
|
| 496 |
<div id="test-visible"> |
| 497 |
Test-visible |
| 498 |
<div id="test-visible-el" style="height:200px;">Test-visible</div> |
| 499 |
Test-visible |
| 500 |
</div> |
| 501 |
|
| 502 |
<div id="test-visible2"></div> |
| 503 |
|
| 504 |
<div id="msFilter" style="-ms-filter:'alpha(opacity=0)'"> |
| 505 |
A div</div> |
| 506 |
<div id="filter" style="filter:alpha(opacity=0)"> |
| 507 |
Another div</div> |
| 508 |
|
| 509 |
<div id="offset-parent" style="position:relative"> |
| 510 |
<div id="offset-child">child</div> |
| 511 |
</div> |
| 512 |
|
| 513 |
<div id="offset-parent-overflow" |
| 514 |
style="overflow: scroll; width: 50px; height: 50px;"> |
| 515 |
<a id="offset-child-overflow"> |
| 516 |
scrollscrollscrollscrollscrollscrollscrollscroll |
| 517 |
</a> |
| 518 |
</div> |
| 519 |
|
| 520 |
<div id="test-viewport"></div> |
| 521 |
<div id="translation"></div> |
| 522 |
|
| 523 |
<div id="rotated"></div> |
| 524 |
<div id="scaled"></div> |
| 525 |
|
| 526 |
<div id="svg-container" class="svg-container"> |
| 527 |
<svg xmlns="http://www.w3.org/2000/svg" version="1.1" baseProfile="full" |
| 528 |
width="100" height="400" viewBox="0 0 100 400"> |
| 529 |
<rect id="svg-item1" width="100" height="100" x="0" y="0" fill="red"/> |
| 530 |
<rect id="svg-item2" width="100" height="100" x="0" y="100" fill="blue"/> |
| 531 |
<rect id="svg-item3" width="100" height="100" x="0" y="200" fill="red"/> |
| 532 |
</svg> |
| 533 |
</div> |
| 534 |
|
| 535 |
<script> |
| 536 |
if (!goog.userAgent.IE || goog.userAgent.isDocumentModeOrHigher(9)) { |
| 537 |
document.write( |
| 538 |
'<iframe id="svg-frame" src="style_test_rect.svg"></' + 'iframe>'); |
| 539 |
} |
| 540 |
</script> |