Skip to content

Commit

Permalink
fix: avoid making a placeholder for a placeholder
Browse files Browse the repository at this point in the history
  • Loading branch information
dhdaines committed Aug 17, 2024
1 parent a76fd88 commit 46cb1c2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion weasyprint/layout/flex.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,8 @@ def flex_layout(context, box, bottom_space, skip_stack, containing_block,
children = box.children
for index, child in enumerate(children):
# Absolute child layout: create placeholder.
if child.is_absolutely_positioned():
if (child.is_absolutely_positioned()
and not isinstance(child, AbsolutePlaceholder)):
child.position_x = box.content_box_x()
child.position_y = box.content_box_y()
new_child = placeholder = AbsolutePlaceholder(child)
Expand Down

0 comments on commit 46cb1c2

Please sign in to comment.