Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[LayoutNG] Auto top/bottom margins may resolve to negative values.
The spec doesn't say that auto margin-top or margin-bottom need to resolve to something non-negative, so just allow negative values as well. They don't cause over-constrainedness. Also, when distributing the space to margin-top and margin-bottom, make sure that everything gets distributed. Set margin-top to the half, and set margin-bottom to total space MINUS margin-top. Just dividing both by two might cause us to lose a tiny fraction of the total, due to rounding. Bug: 888270 Cq-Include-Trybots: luci.chromium.try:linux_layout_tests_layout_ng Change-Id: Ia10577851e60707a0e2d67857a1c43a12e28b9d2 Reviewed-on: https://chromium-review.googlesource.com/c/1269855 Commit-Queue: Morten Stenshorne <[email protected]> Reviewed-by: Emil A Eklund <[email protected]> Reviewed-by: Christian Biesinger <[email protected]> Reviewed-by: Aleks Totic <[email protected]> Cr-Commit-Position: refs/heads/master@{#598052}
- Loading branch information