mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
layout: Make non-normal
align-content
establish a block formatting context (#34984)
* Make non-normal align-content establish a block formatting context Signed-off-by: rayguo17 <rayguo17@gmail.com> * Adjust code comment Signed-off-by: Martin Robinson <mrobinson@igalia.com> --------- Signed-off-by: rayguo17 <rayguo17@gmail.com> Signed-off-by: Martin Robinson <mrobinson@igalia.com> Co-authored-by: Martin Robinson <mrobinson@igalia.com>
This commit is contained in:
parent
e81951a973
commit
cbea70d1a0
18 changed files with 24 additions and 271 deletions
|
@ -721,6 +721,15 @@ impl ComputedValuesExt for ComputedValues {
|
|||
return true;
|
||||
}
|
||||
|
||||
// Per <https://drafts.csswg.org/css-align/#distribution-block>:
|
||||
// Block containers with an `align-content` value that is not `normal` should
|
||||
// form an independent block formatting context. This should really only happen
|
||||
// for block containers, but we do not support subgrid containers yet which is the
|
||||
// only other case.
|
||||
if self.get_position().align_content.0.primary() != AlignFlags::NORMAL {
|
||||
return true;
|
||||
}
|
||||
|
||||
// TODO: We need to handle CSS Contain here.
|
||||
false
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue