Skip to content

Commit 3dc6752

Browse files
committed
Fix condition for page-break-inside: avoid
1 parent 918fc8d commit 3dc6752

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

Source/HtmlRenderer/Core/Dom/CssBox.cs

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -700,9 +700,7 @@ protected virtual async Task PerformLayoutImpAsync(RGraphics g)
700700
{
701701
this.BreakPage(true);
702702
}
703-
else if (this.PageBreakInside == CssConstants.Avoid
704-
&& ActualHeight + Location.Y > HtmlContainer.PageSize.Height
705-
&& prevSibling != null)
703+
else if (this.PageBreakInside == CssConstants.Avoid && prevSibling != null)
706704
{
707705
// handle page break avoiding.
708706
var pageLocationY = Location.Y % HtmlContainer.PageSize.Height;

0 commit comments

Comments
 (0)