<!DOCTYPE html>
<!--
@BLINK-ALLOW:focusable*
@EXECUTE-AND-WAIT-FOR:addOverflowAutoRule()
@EXECUTE-AND-WAIT-FOR:onlySmallContent()
@EXECUTE-AND-WAIT-FOR:onlyLargeContent()
@EXECUTE-AND-WAIT-FOR:useSmallFontInParagraph()
@EXECUTE-AND-WAIT-FOR:useLargeFontInParagraph()
@EXECUTE-AND-WAIT-FOR:removeOverflowAutoRule()
@EXECUTE-AND-WAIT-FOR:readdOverflowAutoRule()
-->
<style>
/* Make paragraphs large so that there is overflow with scrollbars */
p { font-size: 50px; }
/* Make blockquote tiny so that there is no overflow with scrollbars */
blockquote { font-size: 1px; }
</style>
<div id='div1' title='1234' style='overflow:scroll; width: 200px; height:50px'>
<p id='p1'>Example Paragraph 1</p>
<p id='p2'>Example Paragraph 2</p>
</div>
<script>
function addOverflowAutoRule() {
document.getElementById('div1').style.overflow = 'auto';
document.title = 'overflow-auto';
return 'overflow-auto';
}
function onlySmallContent() {
document.getElementById('div1').innerHTML = '<blockquote>small</blockquote>';
document.title = 'only-small-content';
return 'only-small-content';
}
function onlyLargeContent() {
document.getElementById('div1').insertAdjacentHTML('beforeend', '<p>large content</p>');
document.title = 'large-content'
return 'large-content';
}
function useSmallFontInParagraph() {
document.querySelector('p').style.fontSize = '1px';
document.title = 'p-font-small';
return 'p-font-small';
}
function useLargeFontInParagraph() {
document.querySelector('p').style.fontSize = '50px';
document.title = 'p-font-large';
return 'p-font-large';
}
function removeOverflowAutoRule() {
document.getElementById('div1').style.overflow = 'hidden';
document.title = 'overflow-hidden';
return 'overflow-hidden';
}
function readdOverflowAutoRule() {
document.getElementById('div1').style.overflow = 'auto';
document.title = 'finished';
return 'finished';
}
</script>