Skip to content

Commit

Permalink
fix: Float box pushed out of the page area
Browse files Browse the repository at this point in the history
- fix #1295
  • Loading branch information
MurakamiShinyu committed Mar 3, 2024
1 parent 54f3c5d commit 7e86951
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/core/src/vivliostyle/layout-helper.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,10 +44,11 @@ export function calculateEdge(

const element = node.nodeType === 1 ? (node as Element) : node.parentElement;
if (element && element.namespaceURI === Base.NS.XHTML) {
const style = (element as HTMLElement).style;
if (
/^([\d\.]|super|(text-)?top)/.test(
(element as HTMLElement).style.verticalAlign,
)
style &&
Display.isInlineLevel(style.display) &&
/^([\d\.]|super|(text-)?top)/.test(style.verticalAlign)
) {
// (Fix for issue #811)
return NaN;
Expand Down

0 comments on commit 7e86951

Please sign in to comment.