blob: b86824e698e5b3e1dda34271d977c4bb1cebefb6 [file] [log] [blame]
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../resources/js-test-pre.js"></script>
<script src="resources/paged-media-test-utils.js"></script>
</head>
<body>
<p id="description"></p>
<div id="console"></div>
<div id="sandbox"></div>
<script>
description("Test for page-break with 'display:none'");
function test()
{
createBlockWithRatioToPageHeight("page1-1", 0.1).style.breakBefore = "page";
// if 'display' is 'none', page break property should not have any effect.
var block = createBlockWithRatioToPageHeight("displaynone", 0.1);
block.style.breakBefore = "page";
block.style.display = "none";
createBlockWithRatioToPageHeight("page1-2", 0.1);
pageNumberForElementShouldBe("page1-1", 1);
pageNumberForElementShouldBe("displaynone", -1);
pageNumberForElementShouldBe("page1-2", 1);
document.body.removeChild(document.getElementById("sandbox"));
}
var successfullyParsed = true;
</script>
<script>runPrintingTest(test);</script>
<script src="../resources/js-test-post.js"></script>
</body>
</html>