mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-26 17:40:27 +00:00
LibWeb: Add missing else's in absolutely positioned height computation
Rules 1, 2, and 3 use else if, so rules 4, 5, and 6 should too.
This commit is contained in:
parent
743f46030c
commit
ca0a0b7a93
Notes:
sideshowbarker
2024-07-17 08:35:21 +09:00
Author: https://github.com/SamuelBowman Commit: https://github.com/SerenityOS/serenity/commit/ca0a0b7a93 Pull-request: https://github.com/SerenityOS/serenity/pull/15548
1 changed files with 3 additions and 3 deletions
|
@ -858,19 +858,19 @@ void FormattingContext::compute_height_for_absolutely_positioned_non_replaced_el
|
||||||
}
|
}
|
||||||
|
|
||||||
// 4. If top is auto, height and bottom are not auto,
|
// 4. If top is auto, height and bottom are not auto,
|
||||||
if (top.is_auto() && !height.is_auto() && !bottom.is_auto()) {
|
else if (top.is_auto() && !height.is_auto() && !bottom.is_auto()) {
|
||||||
// then solve for top.
|
// then solve for top.
|
||||||
solve_for_top();
|
solve_for_top();
|
||||||
}
|
}
|
||||||
|
|
||||||
// 5. If height is auto, top and bottom are not auto,
|
// 5. If height is auto, top and bottom are not auto,
|
||||||
if (height.is_auto() && !top.is_auto() && !bottom.is_auto()) {
|
else if (height.is_auto() && !top.is_auto() && !bottom.is_auto()) {
|
||||||
// then solve for height.
|
// then solve for height.
|
||||||
solve_for_height();
|
solve_for_height();
|
||||||
}
|
}
|
||||||
|
|
||||||
// 6. If bottom is auto, top and height are not auto,
|
// 6. If bottom is auto, top and height are not auto,
|
||||||
if (bottom.is_auto() && !top.is_auto() && !height.is_auto()) {
|
else if (bottom.is_auto() && !top.is_auto() && !height.is_auto()) {
|
||||||
// then solve for bottom.
|
// then solve for bottom.
|
||||||
solve_for_bottom();
|
solve_for_bottom();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue