mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-11 18:50:50 +00:00
LibWeb: Change inline float clearance to not reset margin collapsing
When a block container has `clear` set and some clearance is applied, that clearance prevents margins from adjoining and therefore resets the margin state. But when a floating box has `clear` set, that clearance only goes between floating boxes so should not reset margin state. BlockFormattingContexts already do that correctly, and this PR changes InlineFormattingContext to do the same. Fixes #1462; adds reduced input from that issue as test.
This commit is contained in:
parent
c77d9a2732
commit
9075f64cac
Notes:
github-actions[bot]
2024-09-20 23:56:34 +00:00
Author: https://github.com/pavpanchekha 🔰
Commit: 9075f64cac
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/1464
3 changed files with 39 additions and 3 deletions
|
@ -0,0 +1,8 @@
|
|||
<!DOCTYPE html>
|
||||
<style> div { height: 1rem; } </style>
|
||||
<body style="font-size: 24px; width: 80rex; padding: 0; border: 1px solid black;">
|
||||
|
||||
<div id=A style="margin-bottom: 1rem; background: green;"></div>
|
||||
<div id=B style="float: right; width: 3rem; background: orange;"></div>
|
||||
<div id=C style="float: right; clear: right; width: 3rem; background: red;"></div>
|
||||
<div id=D style="background: blue;"></div>
|
Loading…
Add table
Add a link
Reference in a new issue