mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
layout: grid template getComputedStyle resolved value (#34885)
* Store taffy detailed info into fragment Signed-off-by: stevennovaryo <steven.novaryo@gmail.com> * Fix info propagation and resolved grid track query Signed-off-by: stevennovaryo <steven.novaryo@gmail.com> * Fix import Signed-off-by: stevennovaryo <steven.novaryo@gmail.com> * Fix tracklist matching logic and type optimization Signed-off-by: stevennovaryo <steven.novaryo@gmail.com> * Run fmt Signed-off-by: stevennovaryo <steven.novaryo@gmail.com> * Update wpt expectations Signed-off-by: stevennovaryo <steven.novaryo@gmail.com> * Optimizing info propagation and minor qol Signed-off-by: stevennovaryo <steven.novaryo@gmail.com> * Run fmt Signed-off-by: stevennovaryo <steven.novaryo@gmail.com> --------- Signed-off-by: stevennovaryo <steven.novaryo@gmail.com>
This commit is contained in:
parent
040e29415b
commit
76fa456a9a
25 changed files with 297 additions and 778 deletions
|
@ -23,7 +23,8 @@ use crate::formatting_contexts::{
|
|||
IndependentFormattingContext, IndependentFormattingContextContents,
|
||||
};
|
||||
use crate::fragment_tree::{
|
||||
BoxFragment, CollapsedBlockMargins, Fragment, FragmentFlags, HoistedSharedFragment,
|
||||
BoxFragment, CollapsedBlockMargins, DetailedLayoutInfo, Fragment, FragmentFlags,
|
||||
HoistedSharedFragment,
|
||||
};
|
||||
use crate::geom::{
|
||||
AuOrAuto, LengthPercentageOrAuto, LogicalRect, LogicalSides, LogicalVec2, PhysicalPoint,
|
||||
|
@ -561,6 +562,7 @@ impl HoistedAbsolutelyPositionedBox {
|
|||
let mut new_fragment = {
|
||||
let content_size: LogicalVec2<Au>;
|
||||
let fragments;
|
||||
let mut detailed_layout_info: Option<DetailedLayoutInfo> = None;
|
||||
match &context.contents {
|
||||
IndependentFormattingContextContents::Replaced(replaced) => {
|
||||
// https://drafts.csswg.org/css2/visudet.html#abs-replaced-width
|
||||
|
@ -629,6 +631,7 @@ impl HoistedAbsolutelyPositionedBox {
|
|||
block: block_size,
|
||||
};
|
||||
fragments = independent_layout.fragments;
|
||||
detailed_layout_info = independent_layout.detailed_layout_info;
|
||||
},
|
||||
};
|
||||
|
||||
|
@ -676,6 +679,7 @@ impl HoistedAbsolutelyPositionedBox {
|
|||
// elements are not inflow.
|
||||
CollapsedBlockMargins::zero(),
|
||||
)
|
||||
.with_detailed_layout_info(detailed_layout_info)
|
||||
};
|
||||
positioning_context.layout_collected_children(layout_context, &mut new_fragment);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue