Truly independent web browser
LibWeb: Support the stretch sizing keyword
Andreas Kling371fecff587c
diff --git a/Libraries/LibWeb/CSS/Keywords.json b/Libraries/LibWeb/CSS/Keywords.jsonindex d3b79b44ac2..ea7cbf19c08 100644--- a/Libraries/LibWeb/CSS/Keywords.json+++ b/Libraries/LibWeb/CSS/Keywords.json@@ -8,6 +8,7 @@"-libweb-left","-libweb-right","-webkit-box",+ "-webkit-fill-available","-webkit-flex","-webkit-inline-box","-webkit-inline-flex",diff --git a/Libraries/LibWeb/CSS/Properties.json b/Libraries/LibWeb/CSS/Properties.jsonindex 9b951fe215f..e45bb2747f4 100644--- a/Libraries/LibWeb/CSS/Properties.json+++ b/Libraries/LibWeb/CSS/Properties.json@@ -2293,10 +2293,12 @@"percentage [0,∞]"],"valid-identifiers": [+ "-webkit-fill-available","auto","content","max-content",- "min-content"+ "min-content",+ "stretch"],"percentages-resolve-to": "length"},@@ -2875,9 +2877,11 @@"percentage [0,∞]"],"valid-identifiers": [+ "-webkit-fill-available","auto","max-content",- "min-content"+ "min-content",+ "stretch"],"percentages-resolve-to": "length","quirks": [@@ -3512,9 +3516,11 @@"percentage [0,∞]"],"valid-identifiers": [+ "-webkit-fill-available","max-content","min-content",- "none"+ "none",+ "stretch"],"percentages-resolve-to": "length","quirks": [@@ -3554,9 +3560,11 @@"percentage [0,∞]"],"valid-identifiers": [+ "-webkit-fill-available","max-content","min-content",- "none"+ "none",+ "stretch"],"percentages-resolve-to": "length","quirks": [@@ -3582,9 +3590,11 @@"percentage [0,∞]"],"valid-identifiers": [+ "-webkit-fill-available","auto","max-content",- "min-content"+ "min-content",+ "stretch"],"percentages-resolve-to": "length","quirks": [@@ -3610,9 +3620,11 @@"percentage [0,∞]"],"valid-identifiers": [+ "-webkit-fill-available","auto","max-content",- "min-content"+ "min-content",+ "stretch"],"percentages-resolve-to": "length","quirks": [@@ -5528,9 +5540,11 @@"percentage [0,∞]"],"valid-identifiers": [+ "-webkit-fill-available","auto","max-content",- "min-content"+ "min-content",+ "stretch"],"percentages-resolve-to": "length","quirks": [diff --git a/Libraries/LibWeb/Rust/src/css/animation.rs b/Libraries/LibWeb/Rust/src/css/animation.rsindex 9bfa6005a95..b228c548d5b 100644--- a/Libraries/LibWeb/Rust/src/css/animation.rs+++ b/Libraries/LibWeb/Rust/src/css/animation.rs@@ -1187,7 +1187,12 @@ fn interpolate_calc_size(let kind = |value: &StyleValueData| match value {StyleValueData::Keyword {keyword:- keyword::AUTO | keyword::MIN_CONTENT | keyword::MAX_CONTENT | keyword::FIT_CONTENT | keyword::CONTENT,+ keyword::AUTO+ | keyword::MIN_CONTENT+ | keyword::MAX_CONTENT+ | keyword::FIT_CONTENT+ | keyword::STRETCH+ | keyword::CONTENT,} => Some(Kind::Keyword),value if crate::css::calc_size::calc_size_arguments(value).is_some() => Some(Kind::CalcSize),StyleValueData::Length { .. } | StyleValueData::Percentage { .. } | StyleValueData::Calculated { .. } => {diff --git a/Libraries/LibWeb/Rust/src/css/calc_size.rs b/Libraries/LibWeb/Rust/src/css/calc_size.rsindex f86338644b1..e2e37c1c30e 100644--- a/Libraries/LibWeb/Rust/src/css/calc_size.rs+++ b/Libraries/LibWeb/Rust/src/css/calc_size.rs@@ -63,7 +63,7 @@ fn parse_basis(context: &ParseContext, property: u16, values: &[ComponentValue])// <size-keyword> represents any sizing keywords allowed in the context where the function is used.let is_size_keyword = match keyword {keyword::ANY => true,- keyword::AUTO | keyword::CONTENT | keyword::MIN_CONTENT | keyword::MAX_CONTENT => {+ keyword::AUTO | keyword::CONTENT | keyword::MIN_CONTENT | keyword::MAX_CONTENT | keyword::STRETCH => {property_accepted_keywords(property).contains(&keyword)}keyword::FIT_CONTENT => property_accepted_value_types(property).contains(&VALUE_TYPE_FIT_CONTENT),@@ -119,7 +119,7 @@ pub(crate) fn calc_size_arguments(value: &StyleValueData) -> Option<(&StyleValue}/// The sizing keyword a calc-size() acts as, after following nested calc-size() bases: auto, min-content,-/// max-content or fit-content, or none when its basis is any or a calculation.+/// max-content, fit-content or stretch, or none when its basis is any or a calculation.pub(crate) fn calc_size_basis_keyword(value: &StyleValueData) -> Option<u16> {let (basis, _) = calc_size_arguments(value)?;match basis {diff --git a/Libraries/LibWeb/Rust/src/css/computed_value_types.rs b/Libraries/LibWeb/Rust/src/css/computed_value_types.rsindex eabd4e420a1..cb85f4c31ee 100644--- a/Libraries/LibWeb/Rust/src/css/computed_value_types.rs+++ b/Libraries/LibWeb/Rust/src/css/computed_value_types.rs@@ -15,6 +15,7 @@ pub enum ComputedSizeKind {MinContent,MaxContent,FitContent,+ Stretch,None,}diff --git a/Libraries/LibWeb/Rust/src/css/computed_value_views.rs b/Libraries/LibWeb/Rust/src/css/computed_value_views.rsindex 0e55707581f..c590c415a81 100644--- a/Libraries/LibWeb/Rust/src/css/computed_value_views.rs+++ b/Libraries/LibWeb/Rust/src/css/computed_value_views.rs@@ -180,6 +180,10 @@ impl ComputedSize {self.kind == ComputedSizeKind::FitContent}+ pub(crate) fn is_stretch(&self) -> bool {+ self.kind == ComputedSizeKind::Stretch+ }+pub(crate) fn is_none(&self) -> bool {self.kind == ComputedSizeKind::None}@@ -229,6 +233,7 @@ impl ComputedSize {ComputedSizeKind::Auto| ComputedSizeKind::MinContent| ComputedSizeKind::MaxContent+ | ComputedSizeKind::Stretch| ComputedSizeKind::None => CssPixels::default(),ComputedSizeKind::Calculated | ComputedSizeKind::Length | ComputedSizeKind::Percentage => {self.length_percentage().to_px(reference)@@ -245,6 +250,10 @@ impl ComputedSize {| ComputedSizeKind::MinContent| ComputedSizeKind::MaxContent| ComputedSizeKind::None => false,+ // NB: A stretch size depends on the size of the containing block, and behaves as auto, zero or none+ // wherever a percentage of it would not resolve.+ // https://drafts.csswg.org/css-sizing-3/#stretch-fit-sizing+ ComputedSizeKind::Stretch => true,ComputedSizeKind::Calculated | ComputedSizeKind::Length | ComputedSizeKind::Percentage => {self.length_percentage().contains_percentage()}diff --git a/Libraries/LibWeb/Rust/src/css/computed_values.rs b/Libraries/LibWeb/Rust/src/css/computed_values.rsindex eeac18cd1d8..7d35f9d7482 100644--- a/Libraries/LibWeb/Rust/src/css/computed_values.rs+++ b/Libraries/LibWeb/Rust/src/css/computed_values.rs@@ -2722,6 +2722,13 @@ impl ComputedSize {Some(StyleValueData::Keyword { keyword: value }) if *value == keyword::MAX_CONTENT => {Self::keyword(ComputedSizeKind::MaxContent)}+ Some(StyleValueData::Keyword { keyword: value }) if *value == keyword::STRETCH => {+ Self::keyword(ComputedSizeKind::Stretch)+ }+ // NB: -webkit-fill-available behaves as stretch, and keeps its own keyword for serialization.+ Some(StyleValueData::Keyword { keyword: value }) if *value == keyword::_WEBKIT_FILL_AVAILABLE => {+ Self::retained(ComputedSizeKind::Stretch, data)+ }Some(StyleValueData::Keyword { keyword: value }) if *value == keyword::NONE => {Self::keyword(ComputedSizeKind::None)}@@ -2734,6 +2741,7 @@ impl ComputedSize {Some(keyword::MIN_CONTENT) => ComputedSizeKind::MinContent,Some(keyword::MAX_CONTENT) => ComputedSizeKind::MaxContent,Some(keyword::FIT_CONTENT) => ComputedSizeKind::FitContent,+ Some(keyword::STRETCH) => ComputedSizeKind::Stretch,_ => ComputedSizeKind::Calculated,};Self::retained(kind, data)diff --git a/Libraries/LibWeb/Rust/src/css/serialize.rs b/Libraries/LibWeb/Rust/src/css/serialize.rsindex d6171d611c0..b2d9a8977f5 100644--- a/Libraries/LibWeb/Rust/src/css/serialize.rs+++ b/Libraries/LibWeb/Rust/src/css/serialize.rs@@ -233,6 +233,15 @@ pub(crate) fn serialize_computed_size(size: &crate::css::computed_value_types::C}ComputedSizeKind::MinContent => sink.push_ascii("min-content"),ComputedSizeKind::MaxContent => sink.push_ascii("max-content"),+ ComputedSizeKind::Stretch => {+ if size.value.pointer.is_null() {+ sink.push_ascii("stretch");+ } else {+ // SAFETY: A stretch size that retains a value retains its live -webkit-fill-available keyword.+ let value = unsafe { &*size.value.pointer.cast::<StyleValueData>() };+ serialize_style_value(&mut sink, value, SerializationMode::Normal);+ }+ }ComputedSizeKind::FitContent => {if size.value.pointer.is_null() {sink.push_ascii("fit-content");diff --git a/Libraries/LibWeb/Rust/src/layout/abspos_engine.rs b/Libraries/LibWeb/Rust/src/layout/abspos_engine.rsindex f42f297198b..f1fad7e291c 100644--- a/Libraries/LibWeb/Rust/src/layout/abspos_engine.rs+++ b/Libraries/LibWeb/Rust/src/layout/abspos_engine.rs@@ -1147,6 +1147,70 @@ impl AbsposEngine<'_> {)}+ /// The inner size that a size property gives the box in `axis`. A stretch size fills the inset-modified+ /// containing block, where an auto inset is the static position at the start, or the containing block edge.+ /// https://drafts.csswg.org/css-sizing-3/#stretch-fit-sizing+ #[expect(clippy::too_many_arguments)]+ fn calculate_inner_size(+ &self,+ node: Node,+ axis: SizingAxis,+ size: &ComputedSize,+ available_space: AvailableSpace,+ constraints: ContainingBlockConstraints,+ static_position_rect: abspos_inputs::StaticPositionRect,+ resolved_anchor_insets: Option<&formatting_context::ResolvedAnchorInsets>,+ ) -> CssPixels {+ let sizing = self.sizing();+ if !size.is_stretch() {+ return match axis {+ SizingAxis::Inline => {+ sizing.calculate_inner_inline_size(node, available_space.inline_size, size, constraints)+ }+ SizingAxis::Block => sizing.calculate_inner_block_size(node, available_space, size, constraints),+ };+ }+ let style = self.style(node).with_resolved_insets(resolved_anchor_insets);+ let containing_block_inline_size = available_space.inline_size.to_px_or_zero();+ let (start, end, containing_block_size, percentage_basis) = match axis {+ SizingAxis::Inline => (+ style.inset_left(),+ style.inset_right(),+ containing_block_inline_size,+ constraints.percentage_basis_inline_size,+ ),+ SizingAxis::Block => (+ style.inset_top(),+ style.inset_bottom(),+ available_space.block_size.to_px_or_zero(),+ constraints.percentage_basis_block_size,+ ),+ };+ let start_offset = if !start.is_auto() {+ start.to_px(containing_block_size)+ } else if end.is_auto() {+ let static_offset = self.static_offset(node, static_position_rect);+ match axis {+ SizingAxis::Inline => static_offset.inline_offset,+ SizingAxis::Block => static_offset.block_offset,+ }+ } else {+ CssPixels::default()+ };+ let end_offset = if end.is_auto() {+ CssPixels::default()+ } else {+ end.to_px(containing_block_size)+ };+ let stretch_fit_size = sizing.stretch_fit_inner_size(+ node,+ axis,+ containing_block_size - start_offset - end_offset,+ constraints,+ );+ sizing.resolve_calc_size(node, axis, size, stretch_fit_size, percentage_basis)+ }+#[expect(clippy::too_many_arguments)]fn solve_non_replaced_inline_once(&self,@@ -1307,7 +1371,15 @@ impl AbsposEngine<'_> {} else if style.width().is_auto() {None} else {- Some(sizing.calculate_inner_inline_size(node, available_space.inline_size, style.width(), constraints))+ Some(self.calculate_inner_size(+ node,+ SizingAxis::Inline,+ style.width(),+ available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ ))};let (mut used_inline_size, mut left, mut right, mut margin_left, mut margin_right) = self.solve_non_replaced_inline_once(@@ -1341,8 +1413,15 @@ impl AbsposEngine<'_> {}if !sizing.should_treat_max_inline_size_as_none(node, available_space.inline_size, constraints) {- let max_inline_size =- sizing.calculate_inner_inline_size(node, available_space.inline_size, style.max_width(), constraints);+ let max_inline_size = self.calculate_inner_size(+ node,+ SizingAxis::Inline,+ style.max_width(),+ available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ );if auto_px_value(used_inline_size) > max_inline_size {(used_inline_size, left, right, margin_left, margin_right) = self.solve_non_replaced_inline_once(node,@@ -1371,8 +1450,15 @@ impl AbsposEngine<'_> {}}if !crate::layout::sizing_context::is_plain_auto(style.min_width()) {- let min_inline_size =- sizing.calculate_inner_inline_size(node, available_space.inline_size, style.min_width(), constraints);+ let min_inline_size = self.calculate_inner_size(+ node,+ SizingAxis::Inline,+ style.min_width(),+ available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ );if auto_px_value(used_inline_size) < min_inline_size {(used_inline_size, left, right, margin_left, margin_right) = self.solve_non_replaced_inline_once(node,@@ -1403,7 +1489,21 @@ impl AbsposEngine<'_> {resolved_anchor_insets: Option<&formatting_context::ResolvedAnchorInsets>,) {let sizing = self.sizing();- let inline_size = sizing.compute_inline_size_for_replaced_element(node, available_space, constraints);+ // NB: A stretch inline size fills the inset-modified containing block, which replaced element sizing does not+ // know about.+ let inline_size = if self.style(node).width().is_stretch() {+ self.calculate_inner_size(+ node,+ SizingAxis::Inline,+ self.style(node).width(),+ available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ )+ } else {+ sizing.compute_inline_size_for_replaced_element(node, available_space, constraints)+ };let containing_block_inline_size = available_space.inline_size.to_px_or_zero();let style = self.style(node).with_resolved_insets(resolved_anchor_insets);let used = self.used(node);@@ -1479,19 +1579,31 @@ impl AbsposEngine<'_> {node: Node,available_space: AvailableSpace,constraints: ContainingBlockConstraints,+ static_position_rect: abspos_inputs::StaticPositionRect,+ resolved_anchor_insets: Option<&formatting_context::ResolvedAnchorInsets>,unconstrained: AutoPx,) -> AutoPx {let style = self.style(node);- let sizing = self.sizing();let mut constrained = unconstrained;+ let calculate_inner_size = |size: &ComputedSize| {+ self.calculate_inner_size(+ node,+ SizingAxis::Block,+ size,+ available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ )+ };if !style.max_height().is_none() {- let maximum = sizing.calculate_inner_block_size(node, available_space, style.max_height(), constraints);+ let maximum = calculate_inner_size(style.max_height());if maximum < auto_px_value(constrained) {constrained = Some(maximum);}}if !crate::layout::sizing_context::is_plain_auto(style.min_height()) {- let minimum = sizing.calculate_inner_block_size(node, available_space, style.min_height(), constraints);+ let minimum = calculate_inner_size(style.min_height());if minimum > auto_px_value(constrained) {constrained = Some(minimum);}@@ -1574,8 +1686,14 @@ impl AbsposEngine<'_> {return solution;};solution.block_size = Some(automatic);- let constrained =- self.apply_min_max_block_size_constraints(node, available_space, constraints, solution.block_size);+ let constrained = self.apply_min_max_block_size_constraints(+ node,+ available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ solution.block_size,+ );self.used(node).set_content_block_size(auto_px_value(constrained));solution.top = Some(self.static_offset(node, static_position_rect).block_offset);solution.bottom = Some(solve_for(solution.bottom, false, solution));@@ -1644,10 +1762,15 @@ impl AbsposEngine<'_> {{None} else {- Some(- self.sizing()- .calculate_inner_block_size(node, intrinsic_available_space, style.height(), constraints),- )+ Some(self.calculate_inner_size(+ node,+ SizingAxis::Block,+ style.height(),+ intrinsic_available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ ))};let mut solution = self.solve_non_replaced_block_once(node,@@ -1660,11 +1783,14 @@ impl AbsposEngine<'_> {);if solution.block_size.is_some() && !style.max_height().is_none() {- let max_block_size = self.sizing().calculate_inner_block_size(+ let max_block_size = self.calculate_inner_size(node,- intrinsic_available_space,+ SizingAxis::Block,style.max_height(),+ intrinsic_available_space,constraints,+ static_position_rect,+ resolved_anchor_insets,);if auto_px_value(solution.block_size) > max_block_size {solution = self.solve_non_replaced_block_once(@@ -1679,11 +1805,14 @@ impl AbsposEngine<'_> {}}if solution.block_size.is_some() && !crate::layout::sizing_context::is_plain_auto(style.min_height()) {- let min_block_size = self.sizing().calculate_inner_block_size(+ let min_block_size = self.calculate_inner_size(node,- intrinsic_available_space,+ SizingAxis::Block,style.min_height(),+ intrinsic_available_space,constraints,+ static_position_rect,+ resolved_anchor_insets,);if auto_px_value(solution.block_size) < min_block_size {solution = self.solve_non_replaced_block_once(@@ -1698,8 +1827,14 @@ impl AbsposEngine<'_> {}}if solution.block_size.is_none() {- solution.block_size =- self.apply_min_max_block_size_constraints(node, available_space, constraints, solution.block_size);+ solution.block_size = self.apply_min_max_block_size_constraints(+ node,+ available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ solution.block_size,+ );}let used = self.used(node);@@ -1727,9 +1862,21 @@ impl AbsposEngine<'_> {pass: BlockSizePass,resolved_anchor_insets: Option<&formatting_context::ResolvedAnchorInsets>,) {- let mut block_size = self- .sizing()- .compute_block_size_for_replaced_element(node, available_space, constraints);+ // NB: As for the inline axis, a stretch block size fills the inset-modified containing block.+ let mut block_size = if self.style(node).height().is_stretch() {+ self.calculate_inner_size(+ node,+ SizingAxis::Block,+ self.style(node).height(),+ available_space,+ constraints,+ static_position_rect,+ resolved_anchor_insets,+ )+ } else {+ self.sizing()+ .compute_block_size_for_replaced_element(node, available_space, constraints)+ };if let BlockSizePass::AfterInsideLayout {automatic_content_block_size_of_inside_layout,} = passdiff --git a/Libraries/LibWeb/Rust/src/layout/block_formatting_context.rs b/Libraries/LibWeb/Rust/src/layout/block_formatting_context.rsindex 87e6865b004..12e0d01bb9e 100644--- a/Libraries/LibWeb/Rust/src/layout/block_formatting_context.rs+++ b/Libraries/LibWeb/Rust/src/layout/block_formatting_context.rs@@ -566,6 +566,25 @@ impl<'pass> BlockFormattingContext<'pass> {let sizing = self.sizing();let available_inline_size = available_space.inline_size.to_px_or_zero();+ let calculate_inner_inline_size = |size: &ComputedSize| {+ if size.is_stretch()+ && let Some(remaining_inline_size) = float_avoidance_inline_size+ {+ // https://drafts.csswg.org/css-sizing-3/#stretch-fit-sizing+ // For in-flow block-level boxes that form an independent formatting context, use the space available+ // to line boxes (i.e. excluding floats) in place of the containing block's inline size.+ let stretch_fit_size =+ sizing.stretch_fit_inner_size(node, SizingAxis::Inline, remaining_inline_size, constraints);+ return sizing.resolve_calc_size(+ node,+ SizingAxis::Inline,+ size,+ stretch_fit_size,+ constraints.percentage_basis_inline_size,+ );+ }+ sizing.calculate_inner_inline_size(node, available_space.inline_size, size, constraints)+ };let sized_as_replaced = sizing.box_is_sized_as_replaced_element(node, available_space, constraints);let replaced_inline_size = sized_as_replaced.then(|| {// 10.3.4 Block-level, replaced elements in normal flow:@@ -577,6 +596,10 @@ impl<'pass> BlockFormattingContext<'pass> {let used = self.used(node);used.resolve_horizontal_box_model(&style, available_inline_size);}+ // NB: Replaced element sizing does not know about the floats a stretch inline size avoids.+ if style.width().is_stretch() && float_avoidance_inline_size.is_some() {+ return calculate_inner_inline_size(style.width());+ }sizing.compute_inline_size_for_replaced_element(node, available_space, constraints)});if sized_as_replaced && facts.is_floating() {@@ -750,7 +773,7 @@ impl<'pass> BlockFormattingContext<'pass> {} else if sizing.should_treat_inline_size_as_auto(node, available_space) {None} else {- Some(sizing.calculate_inner_inline_size(node, available_space.inline_size, style.width(), constraints))+ Some(calculate_inner_inline_size(style.width()))};// 1. The tentative used width is calculated (without 'min-width' and 'max-width')@@ -786,8 +809,7 @@ impl<'pass> BlockFormattingContext<'pass> {// 2. The tentative used width is greater than 'max-width', the rules above are applied again,// but this time using the computed value of 'max-width' as the computed value for 'width'.if !sizing.should_treat_max_inline_size_as_none(node, available_space.inline_size, constraints) {- let max_inline_size =- sizing.calculate_inner_inline_size(node, available_space.inline_size, style.max_width(), constraints);+ let max_inline_size = calculate_inner_inline_size(style.max_width());if used_inline_size.unwrap_or_default() > max_inline_size {used_inline_size = compute(Some(max_inline_size),@@ -821,8 +843,7 @@ impl<'pass> BlockFormattingContext<'pass> {if !min_width.is_auto()&& let Some(value) = used_inline_size{- let min_inline_size =- sizing.calculate_inner_inline_size(node, available_space.inline_size, min_width, constraints);+ let min_inline_size = calculate_inner_inline_size(min_width);if value < min_inline_size {used_inline_size = compute(Some(min_inline_size),diff --git a/Libraries/LibWeb/Rust/src/layout/flex_formatting_context.rs b/Libraries/LibWeb/Rust/src/layout/flex_formatting_context.rsindex 046b29a3646..49b22716789 100644--- a/Libraries/LibWeb/Rust/src/layout/flex_formatting_context.rs+++ b/Libraries/LibWeb/Rust/src/layout/flex_formatting_context.rs@@ -836,8 +836,10 @@ impl<'pass> FlexFormattingContext<'pass> {// (i.e. its flex container); and if that containing block’s size is indefinite,// the used value for flex-basis is content.// NB: A main size property that contains a percentage of an indefinite size behaves as auto, as in block layout.- let percentage_is_unresolvable =- value.is_percentage() || (property != SizingProperty::FlexBasis && value.contains_percentage());+ // NB: So does a stretch flex basis, which resolves against the same size.+ let percentage_is_unresolvable = value.is_percentage()+ || value.is_stretch()+ || (property != SizingProperty::FlexBasis && value.contains_percentage());if percentage_is_unresolvable && !self.has_definite_main_size_used(self.container_used()) {return UsedFlexBasis::Content;}@@ -1062,7 +1064,7 @@ impl<'pass> FlexFormattingContext<'pass> {} else if value.kind == ComputedSizeKind::Calculated {!value.contains_percentage() || self.has_definite_main_size_used(self.container_used())} else {- debug_assert!(value.is_percentage());+ debug_assert!(value.is_percentage() || value.is_stretch());self.has_definite_main_size_used(self.container_used())}}@@ -1160,8 +1162,11 @@ impl<'pass> FlexFormattingContext<'pass> {let percentage_basis = self.has_definite_main_size_used(self.container_used()).then(|| self.inner_main_size_used(self.container_used()));- let has_keyword_basis =- |size: &ComputedSize| size.calc_size().is_some() && size.kind != ComputedSizeKind::Calculated;+ // NB: A stretch basis resolves its calc-size() along with its stretch-fit size.+ let has_keyword_basis = |size: &ComputedSize| {+ size.calc_size().is_some()+ && !matches!(size.kind, ComputedSizeKind::Calculated | ComputedSizeKind::Stretch)+ };let flex_basis = style.flex_basis();let basis_retrieves_main_size = !style.flex_basis_is_content() && flex_basis.is_auto();let (main_size, _) = self.computed_main_size(node);@@ -1696,6 +1701,33 @@ impl<'pass> FlexFormattingContext<'pass> {}}+ // The size that a stretch cross size resolves against, or None where it behaves as auto because percentages of+ // the cross size would not resolve.+ // https://drafts.csswg.org/css-sizing-3/#stretch-fit-sizing+ fn cross_axis_stretch_basis(&self) -> Option<CssPixels> {+ let constraints = self.item_containing_block_constraints();+ self.select_cross(+ constraints.percentage_basis_inline_size,+ constraints.percentage_basis_block_size,+ )+ }++ // The inner cross size of an item with a stretch cross size, filling `basis` with its margin box.+ fn stretch_fit_inner_cross_size(&self, index: usize, basis: CssPixels) -> CssPixels {+ let node = self.flex_items[index].box_;+ let axis = self.cross_sizing_axis();+ let constraints = self.item_containing_block_constraints();+ let sizing = self.sizing();+ let stretch_fit_size = sizing.stretch_fit_inner_size(node, axis, basis, constraints);+ sizing.resolve_calc_size(+ node,+ axis,+ self.computed_cross_size(node).0,+ stretch_fit_size,+ self.cross_axis_stretch_basis(),+ )+ }+// https://drafts.csswg.org/css-flexbox-1/#stretchedfn flex_item_is_stretched(&self, index: usize) -> bool {let alignment = self.alignment_for_item(self.flex_items[index].box_);@@ -1712,7 +1744,10 @@ impl<'pass> FlexFormattingContext<'pass> {} else {node};- self.computed_cross_size(sizing_box).0.is_auto()+ let cross_size = self.computed_cross_size(sizing_box).0;+ let behaves_as_auto =+ cross_size.is_auto() || (cross_size.is_stretch() && self.cross_axis_stretch_basis().is_none());+ behaves_as_auto&& !self.flex_items[index].margins.cross_before_is_auto&& !self.flex_items[index].margins.cross_after_is_auto}@@ -1805,6 +1840,15 @@ impl<'pass> FlexFormattingContext<'pass> {}let computed = self.computed_cross_size(node).0;+ // NB: In a multi-line flex container, the stretch-fit size resolves against the containing block directly, and+ // contributes that size to the cross size of the line.+ if computed.is_stretch()+ && let Some(basis) = self.cross_axis_stretch_basis()+ {+ self.flex_items[index].hypothetical_cross_size =+ css_clamp(self.stretch_fit_inner_cross_size(index, basis), clamp_min, clamp_max);+ return;+ }if computed.is_min_content() {self.flex_items[index].hypothetical_cross_size =css_clamp(self.calculate_min_content_cross_size(index), clamp_min, clamp_max);@@ -1976,6 +2020,31 @@ impl<'pass> FlexFormattingContext<'pass> {// size as its definite cross size so that percentage-sized children can be resolved.self.set_cross_size(index, cross_size);self.set_has_definite_cross_size(index);+ } else if self.computed_cross_size(self.flex_items[index].box_).0.is_stretch()+ && self.cross_axis_stretch_basis().is_some()+ {+ // NB: A stretch cross size finally resolves against the cross size of the flex line.+ let node = self.flex_items[index].box_;+ let min = self.computed_cross_min_size(node).0;+ let cross_min = if min.is_auto() {+ CssPixels::default()+ } else {+ self.specified_cross_min_size(index)+ };+ let cross_max = if self.should_treat_max_size_as_none(node, true) {+ CssPixels::from_raw(i32::MAX)+ } else {+ self.specified_cross_max_size(index)+ };+ let line_cross_size = self.flex_lines[line_index].cross_size;+ let cross_size = css_clamp(+ self.stretch_fit_inner_cross_size(index, line_cross_size),+ cross_min,+ cross_max,+ );+ self.flex_items[index].cross_size = Some(cross_size);+ self.set_cross_size(index, cross_size);+ self.set_has_definite_cross_size(index);} else {// Otherwise, the used cross size is the item’s hypothetical cross size.let size = self.flex_items[index].hypothetical_cross_size;diff --git a/Libraries/LibWeb/Rust/src/layout/grid_formatting_context.rs b/Libraries/LibWeb/Rust/src/layout/grid_formatting_context.rsindex 9194eb43579..72faa3bdc9b 100644--- a/Libraries/LibWeb/Rust/src/layout/grid_formatting_context.rs+++ b/Libraries/LibWeb/Rust/src/layout/grid_formatting_context.rs@@ -260,7 +260,9 @@ fn grid_track_breadth_view(breadth: &ComputedGridTrackBreadth) -> GridTrackBreadComputedSizeKind::MinContent => GridTrackBreadth::MinContent,ComputedSizeKind::MaxContent => GridTrackBreadth::MaxContent,ComputedSizeKind::FitContent => GridTrackBreadth::FitContent(&breadth.size),- ComputedSizeKind::None => unreachable!("grid track sizes cannot be none"),+ ComputedSizeKind::Stretch | ComputedSizeKind::None => {+ unreachable!("grid track sizes cannot be stretch or none")+ }}}diff --git a/Libraries/LibWeb/Rust/src/layout/sizing_context.rs b/Libraries/LibWeb/Rust/src/layout/sizing_context.rsindex bef2ed8fdd4..888ba17ab66 100644--- a/Libraries/LibWeb/Rust/src/layout/sizing_context.rs+++ b/Libraries/LibWeb/Rust/src/layout/sizing_context.rs@@ -73,6 +73,47 @@ pub(crate) fn is_plain_auto(size: &ComputedSize) -> bool {size.is_auto() && size.calc_size().is_none()}+/// The block axis margins that stretch-fit sizing subtracts from the containing block size, with percentages of+/// `margin_basis`.+/// https://drafts.csswg.org/css-sizing-3/#stretch-fit-sizing+pub(crate) fn stretch_fit_block_margins(+ callbacks: &LayoutPass<'_>,+ node: Node,+ margin_basis: CssPixels,+) -> (CssPixels, CssPixels) {+ let style = StyleValues::for_node(callbacks, node);+ let mut margin_top = style.margin_top().to_px(margin_basis);+ let mut margin_bottom = style.margin_bottom().to_px(margin_basis);+ // For in-flow block-level boxes when resolving the block axis size: if the ancestor element percentages resolve+ // against does not have a block-start border or padding and is not an independent formatting context, treat the+ // element's block-start margin as zero for the purpose of calculating this size. Do the same for the block-end+ // margin, analogously.+ let facts = NodeFacts::new(callbacks, node);+ if !(facts.is_in_flow() && !facts.is_inline() && facts.parent_is_unfloated_flow_container()) {+ return (margin_top, margin_bottom);+ }+ let containing_block = callbacks.in_flow_containing_block(node);+ if containing_block.is_invalid()+ || formatting_context::formatting_context_type_created_by_box(NodeFacts::new(callbacks, containing_block))+ .is_some()+ {+ return (margin_top, margin_bottom);+ }+ // NB: The containing block's used values belong to another run, so its padding is resolved from its style.+ let containing_block_style = StyleValues::for_node(callbacks, containing_block);+ if containing_block_style.border_top_width() == CssPixels::default()+ && containing_block_style.padding_top().to_px(margin_basis) == CssPixels::default()+ {+ margin_top = CssPixels::default();+ }+ if containing_block_style.border_bottom_width() == CssPixels::default()+ && containing_block_style.padding_bottom().to_px(margin_basis) == CssPixels::default()+ {+ margin_bottom = CssPixels::default();+ }+ (margin_top, margin_bottom)+}+impl<'pass> SizingContext<'pass> {pub(crate) fn new(purpose: formatting_context::LayoutPurpose,@@ -3344,6 +3385,42 @@ impl<'pass> SizingContext<'pass> {(CssPixels::nearest_value_for(resolved) - edges).max(CssPixels::default())}+ /// The inner size that stretch-fit sizing gives a box whose containing block has the size `basis` in `axis`.+ /// https://drafts.csswg.org/css-sizing-3/#stretch-fit-sizing+ pub(crate) fn stretch_fit_inner_size(+ &self,+ node: Node,+ axis: SizingAxis,+ basis: CssPixels,+ constraints: ContainingBlockConstraints,+ ) -> CssPixels {+ let style = self.style(node);+ let used = self.used(node);+ let margin_basis = constraints.inline_basis();+ // Sizes the margin box to fill the containing block exactly, treating auto margins as zero.+ // (If this would make the inner size negative, it instead sizes the margin box so that the inner size is zero.)+ let (margins, edges) = match axis {+ SizingAxis::Inline => (+ style.margin_left().to_px(margin_basis) + style.margin_right().to_px(margin_basis),+ style.border_left_width()+ + used.padding_left.get()+ + used.padding_right.get()+ + style.border_right_width(),+ ),+ SizingAxis::Block => {+ let (margin_top, margin_bottom) = stretch_fit_block_margins(&self.callbacks, node, margin_basis);+ (+ margin_top + margin_bottom,+ style.border_top_width()+ + used.padding_top.get()+ + used.padding_bottom.get()+ + style.border_bottom_width(),+ )+ }+ };+ (basis - margins - edges).max(CssPixels::default())+ }+pub(crate) fn calculate_inner_inline_size(&self,node: Node,@@ -3372,6 +3449,16 @@ impl<'pass> SizingContext<'pass> {} else {available.to_px_or_zero()};+ if preferred_size.is_stretch() {+ let stretch_fit_size = self.stretch_fit_inner_size(node, SizingAxis::Inline, basis, constraints);+ return self.resolve_calc_size(+ node,+ SizingAxis::Inline,+ preferred_size,+ stretch_fit_size,+ constraints.percentage_basis_inline_size,+ );+ }let keyword_size = if preferred_size.is_fit_content() {Some(self.calculate_fit_content_size(node,@@ -3503,6 +3590,16 @@ impl<'pass> SizingContext<'pass> {basis = constraints.block_basis();}}+ if preferred_size.is_stretch() {+ let stretch_fit_size = self.stretch_fit_inner_size(node, SizingAxis::Block, basis, constraints);+ return self.resolve_calc_size(+ node,+ SizingAxis::Block,+ preferred_size,+ stretch_fit_size,+ constraints.percentage_basis_block_size,+ );+ }let value = preferred_size.to_px(basis);let style = self.style(node);if style.box_sizing() == box_sizing::BORDER_BOX {diff --git a/Libraries/LibWeb/Rust/src/layout/table_formatting_context.rs b/Libraries/LibWeb/Rust/src/layout/table_formatting_context.rsindex b97cc5f4024..62945d46c46 100644--- a/Libraries/LibWeb/Rust/src/layout/table_formatting_context.rs+++ b/Libraries/LibWeb/Rust/src/layout/table_formatting_context.rs@@ -1445,10 +1445,12 @@ impl<'pass> TableFormattingContext<'pass> {let width = style.width();// NB: A calc-size() width counts as well, whatever its basis.// https://drafts.csswg.org/css-values-5/#calc-size+ // NB: So does a stretch width, as resolved in https://github.com/w3c/csswg-drafts/issues/10937.style.table_layout() == TABLE_LAYOUT_FIXED&& (width.is_length_percentage()|| width.is_min_content()|| width.is_fit_content()+ || width.is_stretch()|| width.calc_size().is_some())}@@ -2154,6 +2156,15 @@ impl<'pass> TableFormattingContext<'pass> {};return resolve_calc_size_of_keyword(constraint, grid_max.min(grid_min.max(limit)), basis);}+ // https://drafts.csswg.org/css-sizing-3/#stretch-fit-sizing+ // NB: The table wrapper box carries the margins, so a stretch size fills the basis with the table's border box.+ if constraint.is_stretch() {+ let used = self.used_values(self.run.box_);+ let collapsed = used.uses_collapsing_borders_model.get();+ let stretch_fit_size =+ (basis - used.border_box_left(collapsed) - used.border_box_right(collapsed)).max(CssPixels::default());+ return resolve_calc_size_of_keyword(constraint, stretch_fit_size, basis);+ }// CSS Sizing says box-sizing:border-box applies length/percentage width/min-width/max-width constraints to// the border box. The table inline-size algorithm compares content inline sizes, so convert them before comparing.let mut resolved = constraint.to_px(basis);diff --git a/Libraries/LibWeb/Rust/src/layout/used_values.rs b/Libraries/LibWeb/Rust/src/layout/used_values.rsindex 232ca5037c4..fd6020860dd 100644--- a/Libraries/LibWeb/Rust/src/layout/used_values.rs+++ b/Libraries/LibWeb/Rust/src/layout/used_values.rs@@ -971,6 +971,39 @@ pub(crate) fn create_used_values(return None;}+ // https://drafts.csswg.org/css-sizing-3/#stretch-fit-sizing+ // NB: A stretch size is definite where percentages resolve to a definite value, and sizes the margin box to+ // fill the containing block exactly, treating auto margins as zero.+ if size.is_stretch() && size.calc_size().is_none() {+ if !containing_block_has_definite_size(axis) {+ return None;+ }+ let inline_basis = percentage_basis_inline_size.unwrap_or_default();+ let margins_borders_and_padding = match axis {+ Axis::Inline => {+ style.margin_left().to_px(inline_basis)+ + style.border_left_width()+ + style.padding_left().to_px(inline_basis)+ + style.padding_right().to_px(inline_basis)+ + style.border_right_width()+ + style.margin_right().to_px(inline_basis)+ }+ Axis::Block => {+ let (margin_top, margin_bottom) =+ crate::layout::sizing_context::stretch_fit_block_margins(callbacks, node, inline_basis);+ margin_top+ + style.border_top_width()+ + style.padding_top().to_px(inline_basis)+ + style.padding_bottom().to_px(inline_basis)+ + style.border_bottom_width()+ + margin_bottom+ }+ };+ return Some(clamp_to_max_dimension_value(+ (containing_block_size_for_axis(axis) - margins_borders_and_padding)+ .max(crate::layout::CssPixels::default()),+ ));+ }if !size.is_length_percentage() {return None;}diff --git a/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/block-height-003-ref.html b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/block-height-003-ref.htmlnew file mode 100644index 00000000000..76e2bc35cb7--- /dev/null+++ b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/block-height-003-ref.html@@ -0,0 +1,16 @@+<!DOCTYPE html>++<style>+ .surrounding-block {+ width: 100px;+ height: 100px;+ border: solid;+ }+</style>++<div class="surrounding-block"></div>+<div style="height: 75px;"></div>+<div+ style="width: 200px; height: 200px; outline: 1px solid; border: 2px dashed blue; box-sizing: border-box;">+</div>+<div class="surrounding-block"></div>diff --git a/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-anonymous-block-001-ref.html b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-anonymous-block-001-ref.htmlnew file mode 100644index 00000000000..14423d71465--- /dev/null+++ b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-anonymous-block-001-ref.html@@ -0,0 +1,22 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>CSS Reference Case</title>+<style>+ .container {+ height: 200px;+ }+ iframe {+ box-sizing: border-box;+ height: 200px;+ width: 40px;+ border: 5px solid blue;+ margin: 0;+ background: cyan;+ }+</style>+<body>+ <div class="container">+ <div style="height: 0"></div>+ <iframe></iframe>+ </div>+</body>diff --git a/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-float-ref.html b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-float-ref.htmlnew file mode 100644index 00000000000..46395645292--- /dev/null+++ b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-float-ref.html@@ -0,0 +1,9 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>Reference: two green rectangles of equal width</title>+<p>Test passes if there are two filled green rectangles of equal width and <strong>no red</strong>.</p>+<div style="width: 200px">+ <div style="width: 200px; height: 20px; background: green"></div>+ <div></div>+ <div style="width: 200px; height: 20px; background: green"></div>+</div>diff --git a/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-float-with-sibling-ref.html b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-float-with-sibling-ref.htmlnew file mode 100644index 00000000000..b60e649909b--- /dev/null+++ b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-float-with-sibling-ref.html@@ -0,0 +1,9 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>Reference: two green rectangles separated by a gap</title>+<p>Test passes if there are two filled green rectangles of equal width.</p>+<div style="width: 200px">+ <div style="width: 200px; height: 20px; background: green; float: left"></div>+ <div style="height: 100px"></div>+ <div style="width: 200px; height: 20px; background: green; float: left"></div>+</div>diff --git a/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-quirk-001-ref.html b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-quirk-001-ref.htmlnew file mode 100644index 00000000000..1fad6927f6c--- /dev/null+++ b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-quirk-001-ref.html@@ -0,0 +1,28 @@+<!-- no doctype, to trigger quirks mode -->+<meta charset="utf-8">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<title>CSS Reference Case</title>+<style>+ body {+ margin: 0;+ }+ body > * {+ box-sizing: border-box;+ height: 100vh;++ /* The rest of these styles are just for cosmetics & consistency: */+ width: 40px;+ border: 5px solid blue;+ vertical-align: top;+ margin: 0 10px 0 0;+ background: cyan;+ }+</style>+<body>+ <div style="display: inline-block">IB</div>+ <canvas></canvas>+ <iframe></iframe>+ <button>B</button>+ <input value="i">+ <textarea></textarea>+</body>diff --git a/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-quirk-002-ref.html b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-quirk-002-ref.htmlnew file mode 100644index 00000000000..c05ce9379fd--- /dev/null+++ b/Tests/LibWeb/Ref/expected/wpt-import/css/css-sizing/stretch/stretch-quirk-002-ref.html@@ -0,0 +1,20 @@+<!-- no doctype, to trigger quirks mode -->+<meta charset="utf-8">+<title>CSS Reference Case</title>+<style>+ body {+ margin: 0;+ }+ iframe {+ box-sizing: border-box;+ height: 100vh;+ width: 40px;+ border: 5px solid blue;+ margin: 0;+ background: cyan;+ }+</style>+<body>+ <div style="height: 0"></div>+ <iframe></iframe>+</body>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/abspos-1.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/abspos-1.htmlnew file mode 100644index 00000000000..87a3f57647d--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/abspos-1.html@@ -0,0 +1,21 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/4028">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div id="reference-overlapped-red"></div>++<div style="width: 100px; height: 100px; position: relative;">+ <div style="position: absolute; width: stretch; height: 100px; background: green;">+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/abspos-2.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/abspos-2.htmlnew file mode 100644index 00000000000..6cb8d5c319c--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/abspos-2.html@@ -0,0 +1,22 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/4028">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div id="reference-overlapped-red"></div>++<div style="width: 100px; height: 200px; position: relative;">+ <div+ style="width: 100%; height: stretch; position: absolute; bottom: 100px; background: green;">+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/bfc-next-to-float-1.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/bfc-next-to-float-1.htmlnew file mode 100644index 00000000000..d73979b5056--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/bfc-next-to-float-1.html@@ -0,0 +1,23 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/4028">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div id="reference-overlapped-red"></div>++<div style="width:200px; margin-left: -100px;">+ <div style="float: left; width: 100px; height: 100px;"></div>+ <div+ style="display: flow-root; width: stretch; height: 100px; background: green;">+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/bfc-next-to-float-2.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/bfc-next-to-float-2.htmlnew file mode 100644index 00000000000..5c6d3757a0b--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/bfc-next-to-float-2.html@@ -0,0 +1,41 @@+<!DOCTYPE html>+<link rel="author" title="Oriol Brufau" href="[email protected]">+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/4028">+<link rel="help" href="https://drafts.csswg.org/css2/#floats">+<meta name="assert" content="The border box of a block-level element that+ establishes an independent formatting context can't overlap the margin box+ of any float in the same block formatting context.+ The stretch size needs to respect that.+">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+ .stretch {+ display: flow-root;+ height: 25px;+ background: green;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div id="reference-overlapped-red"></div>++<div style="width:200px; margin-left: -100px;">+ <div style="float: left; width: 100px; height: 75px;"></div>+ <div class="stretch" style="width: 0; min-width: stretch"></div>+ <div class="stretch" style="width: 1000px; max-width: stretch"></div>+ <div class="stretch" style="width: stretch; padding: 0 10px; border: solid green; border-width: 0 10px; margin-left: 10px"></div>+</div>+<div style="width:250px; margin-left: -150px;">+ <div style="float: left; clear: left; width: 100px; height: 1px;"></div>+ <div style="float: left; clear: left; width: 150px; height: 1px;"></div>+ <div style="float: left; clear: left; width: 125px; height: 1px;"></div>+ <div class="stretch" style="width: stretch"></div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-003.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-003.htmlnew file mode 100644index 00000000000..bbdf07fc7fa--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-003.html@@ -0,0 +1,28 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<meta name="assert"+ content="Both margins are ignored for sizing, but top margin still collapses. Bottom margin doesn't collapse because parent has a definite height.">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/block-height-003-ref.html">++<style>+ .surrounding-block {+ width: 100px;+ height: 100px;+ border: solid;+ }+</style>++<!--+<p>These tests assert the behavior described at+ https://github.com/w3c/csswg-drafts/issues/11044#issuecomment-2599101601+</p>+-->++<div class="surrounding-block"></div>+<div style="width: 200px; height: 200px; outline: 1px solid;">+ <div+ style="height: stretch; margin: 75px 0px 25px 0px; border: 2px dashed blue;">+ </div>+</div>+<div class="surrounding-block"></div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-006.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-006.htmlnew file mode 100644index 00000000000..0d954f20461--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-006.html@@ -0,0 +1,29 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11044">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<meta name="assert"+ content="Bottom margin is treated as 0 for stretch sizing even if there is a proceeding float">++<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.+</p>+<div id="reference-overlapped-red"></div>++<div style="height: 100px;">+ <div+ style="display: flow-root; width: 100px; height: stretch; margin-bottom: 50px; background: green;">+ </div>+ <div style="float: left; width: 50px; height: 50px;">+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-009.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-009.htmlnew file mode 100644index 00000000000..4a2eb94d482--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-009.html@@ -0,0 +1,26 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11044">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<meta name="assert" content="margin ignoring works with min-height:stretch">++<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.+</p>+<div id="reference-overlapped-red"></div>++<div style="height: 100px;">+ <div+ style="width: 100px; min-height: stretch; margin-bottom: 50px; background: green;">+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-010.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-010.htmlnew file mode 100644index 00000000000..0c072f9ecd5--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/block-height-010.html@@ -0,0 +1,26 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11044">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<meta name="assert" content="margin ignoring works with max-height:stretch">++<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.+</p>+<div id="reference-overlapped-red"></div>++<div style="height: 100px;">+ <div+ style="width: 100px; height: 500px; max-height: stretch; margin-bottom: 50px; background: green;">+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/cache-miss-001.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/cache-miss-001.htmlnew file mode 100644index 00000000000..7332bf87648--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/cache-miss-001.html@@ -0,0 +1,36 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://crbug.com/386052671">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<meta name="assert" content="Dynamic height change affects stretched grandchild.">++<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+ #target {+ /* Use a sans-serif font to reduce likelihood that the 'hi' text draws any+ flourishes that happen to generate antialiasing fringe outside the+ container: */+ font-family: sans-serif;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.+</p>+<div id="reference-overlapped-red"></div>++<div id="target" style="width: 100px;">+ <div style="height: 100%;">+ <div style="height: -webkit-fill-available; background: green; color: green">hi</div>+ </div>+</div>+<script>+ document.body.offsetTop;+ target.style.height = '100px';+</script>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/cache-miss-002.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/cache-miss-002.htmlnew file mode 100644index 00000000000..c2b53da7bce--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/cache-miss-002.html@@ -0,0 +1,32 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://crbug.com/386052671">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<meta name="assert" content="Height change caused by 2-pass flex layout affects stretched-height descendant.">++<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.+</p>+<div id="reference-overlapped-red"></div>++ <div style="width: 100px; height: 100px; display: flex; flex-direction: column;">+ <main style="flex-basis: 0px; flex-grow: 1; width: -webkit-fill-available;">+ <div style="height: 100%; position: relative;">+ <div style="position: absolute; inset: 0px;">+ <div style="height: -webkit-fill-available; background: green; color: green; overflow-y: auto;">+ <div>Content</div>+ </div>+ </div>+ </div>+ </main>+ </div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/fixed-table-1.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/fixed-table-1.htmlnew file mode 100644index 00000000000..7a98e72f508--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/fixed-table-1.html@@ -0,0 +1,20 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/10937">+<link rel="match"+ href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square-only.html">+<meta name="assert"+ content="stretch width allows fixed-layout table mode to take effect">+++<p>Test passes if there is a filled green square.</p>++<div style="width: 100px;">+ <div+ style="display: table; table-layout: fixed; width: stretch; background: green;">+ <div style="display: table-cell; width: 100px;">+ <div style="width: 200px; height: 100px;"></div>+ </div>+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-auto-minimum-001.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-auto-minimum-001.htmlnew file mode 100644index 00000000000..4e9f7d44cbe--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-auto-minimum-001.html@@ -0,0 +1,30 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>Automatic minimum size of flex item with stretch cross size</title>+<link rel="author" title="Oriol Brufau" href="mailto:[email protected]">+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://drafts.csswg.org/css-flexbox-1/#min-size-auto">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-200px-square.html">+<meta assert="A definite `stretch` cross size can be transferred through the+ aspect ratio when computing the automatic minimum size of a flex item.">++<style>+div {+ display: flex;+ flex-direction: column;+ height: 200px;+ width: 200px;+ background: red;+}+canvas {+ width: stretch;+ align-self: start;+ flex-basis: 0;+ background: green;+}+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div class="flex">+ <canvas width="100" height="100"></canvas>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-flex-base-size-001.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-flex-base-size-001.htmlnew file mode 100644index 00000000000..b20509bc128--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-flex-base-size-001.html@@ -0,0 +1,30 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>Flex base size of flex item with stretch cross size</title>+<link rel="author" title="Oriol Brufau" href="mailto:[email protected]">+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://drafts.csswg.org/css-flexbox-1/#flex-base-size">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-200px-square.html">+<meta assert="A definite `stretch` cross size can be transferred through the+ aspect ratio when computing the flex base size of a flex item.">++<style>+div {+ display: flex;+ flex-direction: column;+ height: 200px;+ width: 200px;+ background: red;+}+canvas {+ width: stretch;+ align-self: start;+ min-height: 0;+ background: green;+}+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div class="flex">+ <canvas width="100" height="100"></canvas>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-flex-base-size-002.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-flex-base-size-002.htmlnew file mode 100644index 00000000000..e8d1424f34b--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-flex-base-size-002.html@@ -0,0 +1,30 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>Flex base size of flex item with stretch cross size</title>+<link rel="author" title="Oriol Brufau" href="mailto:[email protected]">+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://drafts.csswg.org/css-flexbox-1/#flex-base-size">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-200px-square.html">+<meta assert="A definite `stretch` cross size can be transferred through the+ aspect ratio when computing the flex base size of a flex item.">++<style>+div {+ display: flex;+ flex-direction: row;+ height: 200px;+ width: 200px;+ background: red;+}+canvas {+ height: stretch;+ align-self: start;+ min-width: 0;+ background: green;+}+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div class="flex">+ <canvas width="100" height="100"></canvas>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-stretch-minimum-001.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-stretch-minimum-001.htmlnew file mode 100644index 00000000000..2ad0605b0ba--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-stretch-minimum-001.html@@ -0,0 +1,36 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>Non-negative content-box size of stretched flex item with `stretch` min cross size</title>+<link rel="author" title="Oriol Brufau" href="mailto:[email protected]">+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://drafts.csswg.org/css-flexbox-1/#stretched">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11076">+<link rel="help" href="https://github.com/servo/servo/issues/38517">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-200px-square.html">+<meta assert="Stretching the cross size of a flex item to the flex line should never result+ in a negative content-box size.">++<style>+#red {+ position: absolute;+ z-index: -1;+ width: 200px;+ height: 200px;+ background: red;+}+#flex-container {+ display: flex;+ flex-direction: row;+ height: 0;+}+#flex-item {+ min-height: stretch;+ border: 100px solid green;+}+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div id="red"></div>+<div id="flex-container">+ <div id="flex-item"></div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-stretch-minimum-002.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-stretch-minimum-002.htmlnew file mode 100644index 00000000000..43da29b99a3--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/flexbox-stretch-minimum-002.html@@ -0,0 +1,36 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>Non-negative content-box size of stretched flex item with `stretch` min cross size</title>+<link rel="author" title="Oriol Brufau" href="mailto:[email protected]">+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://drafts.csswg.org/css-flexbox-1/#stretched">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11076">+<link rel="help" href="https://github.com/servo/servo/issues/38517">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-200px-square.html">+<meta assert="Stretching the cross size of a flex item to the flex line should never result+ in a negative content-box size.">++<style>+#red {+ position: absolute;+ z-index: -1;+ width: 200px;+ height: 200px;+ background: red;+}+#flex-container {+ display: flex;+ flex-direction: column;+ width: 0;+}+#flex-item {+ min-width: stretch;+ border: 100px solid green;+}+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div id="red"></div>+<div id="flex-container">+ <div id="flex-item"></div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/min-width-1.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/min-width-1.htmlnew file mode 100644index 00000000000..eda35d40267--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/min-width-1.html@@ -0,0 +1,7 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-3/#propdef-width">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square-only.html">+<p>Test passes if there is a filled green square.</p>+<div style="width: 100px;">+ <div style="width: 50px; min-width: stretch; height: 100px; background: green;"></div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-non-replaced-1.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-non-replaced-1.htmlnew file mode 100644index 00000000000..8399f954c2c--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-non-replaced-1.html@@ -0,0 +1,20 @@+<!DOCTYPE html>+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square-only.html">+<link rel="help" href="https://github.com/webcompat/web-bugs/issues/103641#issuecomment-1122414992">+<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=1324259">+<p>Test passes if there is a filled green square.</p>+<style>+#target {+ position: absolute;+ background: green;+ min-width: 50px;+ min-height: 25px;+ width: stretch;+ height: stretch;+}+</style>+<div style="display: flow-root; position: relative; width: 150px; height: 150px; margin-top: -50px; margin-left: -50px;">+ <div style="margin-left: 50px; margin-top: 50px;">+ <div id="target"></div>+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-1.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-1.htmlnew file mode 100644index 00000000000..a8dae2c1a99--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-1.html@@ -0,0 +1,18 @@+<!DOCTYPE html>+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square-only.html">+<link rel="help" href="https://github.com/webcompat/web-bugs/issues/103641#issuecomment-1122414992">+<link rel="help" href="https://bugs.chromium.org/p/chromium/issues/detail?id=1324259">+<p>Test passes if there is a filled green square.</p>+<style>+canvas {+ position: absolute;+ background: green;+ width: stretch;+ height: stretch;+}+</style>+<div style="display: flow-root; position: relative; width: 150px; height: 150px; margin-top: -50px; margin-left: -50px;">+ <div style="margin-left: 50px; margin-top: 50px;">+ <canvas width="50" height="25"></canvas>+ </div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-2.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-2.htmlnew file mode 100644index 00000000000..5e06fc2176f--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-2.html@@ -0,0 +1,18 @@+<!DOCTYPE html>+<link rel="author" title="Oriol Brufau" href="mailto:[email protected]">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square-only.html">+<link rel="help" href="https://github.com/servo/servo/pull/34430">+<p>Test passes if there is a filled green square.</p>+<style>+canvas {+ position: absolute;+ background: green;+ width: stretch;+ height: stretch;+ top: 50px;+ left: 50px;+}+</style>+<div style="display: flow-root; position: relative; width: 150px; height: 150px; margin-top: -50px; margin-left: -50px;">+ <canvas width="50" height="25"></canvas>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-3.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-3.htmlnew file mode 100644index 00000000000..6fbdad29887--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/positioned-replaced-3.html@@ -0,0 +1,17 @@+<!DOCTYPE html>+<link rel="author" title="Oriol Brufau" href="mailto:[email protected]">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square-only.html">+<link rel="help" href="https://github.com/servo/servo/pull/34430">+<p>Test passes if there is a filled green square.</p>+<style>+canvas {+ position: absolute;+ background: green;+ width: stretch;+ height: stretch;+ inset: 50px;+}+</style>+<div style="display: flow-root; position: relative; width: 200px; height: 200px; margin-top: -50px; margin-left: -50px;">+ <canvas width="50" height="25"></canvas>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/replaced-next-to-float-1.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/replaced-next-to-float-1.htmlnew file mode 100644index 00000000000..832898a3ed7--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/replaced-next-to-float-1.html@@ -0,0 +1,23 @@+<!DOCTYPE html>+<link rel="author" title="Oriol Brufau" href="[email protected]">+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/4028">+<link rel="help" href="https://github.com/servo/servo/issues/37861">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/../../reference/ref-filled-green-100px-square.xht">+<style>+ #reference-overlapped-red {+ position: absolute;+ background-color: red;+ width: 100px;+ height: 100px;+ z-index: -1;+ }+</style>++<p>Test passes if there is a filled green square and <strong>no red</strong>.</p>+<div id="reference-overlapped-red"></div>++<div style="width:200px; margin-left: -100px;">+ <div style="float: left; width: 100px; height: 100px;"></div>+ <canvas width="1" height="1" style="display: block; width: stretch; background: green"></canvas>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-anonymous-block-001.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-anonymous-block-001.htmlnew file mode 100644index 00000000000..4775280cfff--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-anonymous-block-001.html@@ -0,0 +1,28 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>CSS Test: 'stretch' heights resolve through an anonymous block wrapper</title>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/stretch-anonymous-block-001-ref.html">+<meta name="assert"+ content="When a block container has mixed block-level and inline-level children, the inline children are wrapped in an anonymous block box. height:stretch on those inline children should still resolve against the (non-anonymous) containing block, not be treated as indefinite due to the anonymous block wrapper sitting between.">+<style>+ .container {+ height: 200px;+ }+ iframe {+ box-sizing: border-box;+ height: stretch;+ width: 40px;+ border: 5px solid blue;+ margin: 0;+ background: cyan;+ }+</style>+<body>+ <div class="container">+ <!-- The block-level <div> forces .container's children to be non-inline,+ wrapping the following inline iframe in an anonymous block box. -->+ <div style="height: 0"></div>+ <iframe></iframe>+ </div>+</body>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-float-with-sibling.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-float-with-sibling.htmlnew file mode 100644index 00000000000..99995f2bbd3--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-float-with-sibling.html@@ -0,0 +1,24 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>CSS Sizing: stretch on float with tall sibling between floats</title>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/stretch-float-with-sibling-ref.html">+<meta name="assert" content="+ A float with width:stretch should resolve to the containing block width+ even when a tall non-float block separates it from a previous float.+">+<style>+.stretch {+ width: -webkit-fill-available;+ width: stretch;+ float: left;+ height: 20px;+ background: green;+}+</style>+<p>Test passes if there are two filled green rectangles of equal width.</p>+<div style="width: 200px">+ <div class="stretch"></div>+ <div style="height: 100px"></div>+ <div class="stretch"></div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-float.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-float.htmlnew file mode 100644index 00000000000..6414d5fba5e--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-float.html@@ -0,0 +1,25 @@+<!DOCTYPE html>+<meta charset="utf-8">+<title>CSS Sizing: stretch on float resolves against containing block</title>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/stretch-float-ref.html">+<meta name="assert" content="+ A float with width:stretch should resolve to the containing block width,+ not shrink to avoid sibling floats. Per CSS Sizing 4 section 6.1, stretch+ fills the containing block.+">+<style>+.stretch {+ width: -webkit-fill-available;+ width: stretch;+ float: left;+ height: 20px;+ background: green;+}+</style>+<p>Test passes if there are two filled green rectangles of equal width and <strong>no red</strong>.</p>+<div style="width: 200px; background: red">+ <div class="stretch"></div>+ <div></div>+ <div class="stretch"></div>+</div>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-quirk-001.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-quirk-001.htmlnew file mode 100644index 00000000000..b77690f2ed4--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-quirk-001.html@@ -0,0 +1,38 @@+<!-- no doctype, to trigger quirks mode -->+<meta charset="utf-8">+<title>+ CSS Test: 'stretch' heights can resolve against body height, with+ quirks-mode body-fills-html-which-fills-viewport behavior+</title>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="help" href="https://quirks.spec.whatwg.org/#the-html-element-fills-the-viewport-quirk">+<link rel="help" href="https://quirks.spec.whatwg.org/#the-body-element-fills-the-html-element-quirk">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/stretch-quirk-001-ref.html">+<meta name="assert"+ content="In quirks mode, the body's automatic height should be considered definite for the purposes of 'stretch' resolution on its children">+<style>+ body {+ margin: 0;+ }+ body > * {+ box-sizing: border-box;+ height: -webkit-fill-available;+ height: stretch;++ /* The rest of these styles are just for cosmetics & consistency: */+ width: 40px;+ border: 5px solid blue;+ vertical-align: top;+ margin: 0 10px 0 0;+ background: cyan;+ }+</style>+<body>+ <div style="display: inline-block">IB</div>+ <canvas></canvas>+ <iframe></iframe>+ <button>B</button>+ <input value="i">+ <textarea></textarea>+</body>diff --git a/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-quirk-002.html b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-quirk-002.htmlnew file mode 100644index 00000000000..79017c77283--- /dev/null+++ b/Tests/LibWeb/Ref/input/wpt-import/css/css-sizing/stretch/stretch-quirk-002.html@@ -0,0 +1,27 @@+<!-- no doctype, to trigger quirks mode -->+<meta charset="utf-8">+<title>CSS Test: 'stretch' heights resolve through an anonymous block wrapper</title>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="help" href="https://quirks.spec.whatwg.org/#the-body-element-fills-the-html-element-quirk">+<link rel="match" href="../../../../../expected/wpt-import/css/css-sizing/stretch/stretch-quirk-002-ref.html">+<meta name="assert"+ content="When body has mixed block-level and inline-level children, the inline children are wrapped in an anonymous block box. height:stretch on those inline children should still resolve against the body, not be treated as indefinite due to the anonymous block wrapper sitting between.">+<style>+ body {+ margin: 0;+ }+ iframe {+ box-sizing: border-box;+ height: stretch;+ width: 40px;+ border: 5px solid blue;+ margin: 0;+ background: cyan;+ }+</style>+<body>+ <!-- The block-level <div> forces body's children to be non-inline,+ wrapping the following inline iframe in an anonymous block box. -->+ <div style="height: 0"></div>+ <iframe></iframe>+</body>diff --git a/Tests/LibWeb/Text/expected/css/calc-size-stretch-basis-on-flex-items.txt b/Tests/LibWeb/Text/expected/css/calc-size-stretch-basis-on-flex-items.txtnew file mode 100644index 00000000000..7ec132069b7--- /dev/null+++ b/Tests/LibWeb/Text/expected/css/calc-size-stretch-basis-on-flex-items.txt@@ -0,0 +1,2 @@+calc-size() flex-basis with a stretch basis: 150+calc-size() width with a stretch basis: 150diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/animation/width-interpolation.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/animation/width-interpolation.txtindex 89430c5ed14..4fd89c40574 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/animation/width-interpolation.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/animation/width-interpolation.txt@@ -2,8 +2,7 @@ Harness status: OKFound 456 tests-414 Pass-42 Fail+456 PassPass CSS Transitions: property <width> from neutral to [40px] at (-0.3) should be [1px]Pass CSS Transitions: property <width> from neutral to [40px] at (0) should be [10px]Pass CSS Transitions: property <width> from neutral to [40px] at (0.3) should be [19px]@@ -292,48 +291,48 @@ Pass Web Animations: property <width> from [auto] to [fit-content] at (0.5) shouPass Web Animations: property <width> from [auto] to [fit-content] at (0.6) should be [fit-content]Pass Web Animations: property <width> from [auto] to [fit-content] at (1) should be [fit-content]Pass Web Animations: property <width> from [auto] to [fit-content] at (1.5) should be [fit-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (-0.3) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (0) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (0.3) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (-0.3) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.3) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail CSS Animations: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [auto] at (0) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [auto] at (0.3) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Animations: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Animations: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Animations: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail Web Animations: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [auto] at (0) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [auto] at (0.3) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail Web Animations: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail Web Animations: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail Web Animations: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (-0.3) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (0) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (0.3) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (-0.3) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.3) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Animations: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [auto] at (0) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [auto] at (0.3) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Animations: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Animations: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Animations: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass Web Animations: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [auto] at (0) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [auto] at (0.3) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass Web Animations: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass Web Animations: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass Web Animations: property <width> from [stretch] to [auto] at (1.5) should be [auto]Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [30px] to [fit-content] at (-0.3) should be [30px]Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [30px] to [fit-content] at (0) should be [30px]Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [30px] to [fit-content] at (0.3) should be [30px]diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/keyword-sizes-on-abspos.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/keyword-sizes-on-abspos.txtindex 0fc499b2c62..49843cc5d9d 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/keyword-sizes-on-abspos.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/keyword-sizes-on-abspos.txt@@ -2,8 +2,8 @@ Harness status: OKFound 60 tests-43 Pass-17 Fail+51 Pass+9 FailPass .test 1Pass .test 2Fail .test 3@@ -13,12 +13,12 @@ Pass .test 6Pass .test 7Fail .test 8Pass .test 9-Fail .test 10+Pass .test 10Pass .test 11Pass .test 12Fail .test 13Pass .test 14-Fail .test 15+Pass .test 15Pass .test 16Pass .test 17Pass .test 18@@ -28,12 +28,12 @@ Pass .test 21Pass .test 22Pass .test 23Pass .test 24-Fail .test 25+Pass .test 25Pass .test 26Pass .test 27Pass .test 28Pass .test 29-Fail .test 30+Pass .test 30Pass .test 31Pass .test 32Pass .test 33@@ -43,12 +43,12 @@ Pass .test 36Pass .test 37Pass .test 38Pass .test 39-Fail .test 40+Pass .test 40Pass .test 41Pass .test 42Pass .test 43Pass .test 44-Fail .test 45+Pass .test 45Pass .test 46Pass .test 47Pass .test 48@@ -58,9 +58,9 @@ Pass .test 51Fail .test 52Fail .test 53Fail .test 54-Fail .test 55+Pass .test 55Pass .test 56Fail .test 57Fail .test 58Fail .test 59-Fail .test 60\ No newline at end of file+Pass .test 60\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/aspect-ratio-1.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/aspect-ratio-1.txtnew file mode 100644index 00000000000..53c1f79b905--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/aspect-ratio-1.txt@@ -0,0 +1,9 @@+Harness status: OK++Found 4 tests++4 Pass+Pass p + div > div 1+Pass p + div > div 2+Pass p + div > div 3+Pass p + div > div 4\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/aspect-ratio-2.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/aspect-ratio-2.txtnew file mode 100644index 00000000000..f71188ab497--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/aspect-ratio-2.txt@@ -0,0 +1,23 @@+Harness status: OK++Found 18 tests++18 Pass+Pass canvas 1+Pass canvas 2+Pass canvas 3+Pass canvas 4+Pass canvas 5+Pass canvas 6+Pass canvas 7+Pass canvas 8+Pass canvas 9+Pass canvas 10+Pass canvas 11+Pass canvas 12+Pass canvas 13+Pass canvas 14+Pass canvas 15+Pass canvas 16+Pass canvas 17+Pass canvas 18\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/auto-margins-1.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/auto-margins-1.txtnew file mode 100644index 00000000000..780b529b6c0--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/auto-margins-1.txt@@ -0,0 +1,7 @@+Harness status: OK++Found 2 tests++2 Pass+Pass [data-expected-width] 1+Pass [data-expected-width] 2\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/auto-margins-2.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/auto-margins-2.txtnew file mode 100644index 00000000000..0755b452b56--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/auto-margins-2.txt@@ -0,0 +1,11 @@+Harness status: OK++Found 6 tests++6 Pass+Pass .outer>div 1+Pass .outer>div 2+Pass .outer>div 3+Pass .outer>div 4+Pass .outer>div 5+Pass .outer>div 6\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-001.txtnew file mode 100644index 00000000000..ea80a136dbb--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-001.txt@@ -0,0 +1,23 @@+Harness status: OK++Found 18 tests++18 Pass+Pass [data-expected-height] 1+Pass [data-expected-height] 2+Pass [data-expected-height] 3+Pass [data-expected-height] 4+Pass [data-expected-height] 5+Pass [data-expected-height] 6+Pass [data-expected-height] 7+Pass [data-expected-height] 8+Pass [data-expected-height] 9+Pass [data-expected-height] 10+Pass [data-expected-height] 11+Pass [data-expected-height] 12+Pass [data-expected-height] 13+Pass [data-expected-height] 14+Pass [data-expected-height] 15+Pass [data-expected-height] 16+Pass [data-expected-height] 17+Pass [data-expected-height] 18\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-002.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-002.txtnew file mode 100644index 00000000000..88a32373e03--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-002.txt@@ -0,0 +1,9 @@+Harness status: OK++Found 4 tests++4 Pass+Pass main > div > div 1+Pass main > div > div 2+Pass main > div > div 3+Pass main > div > div 4\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-004.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-004.txtnew file mode 100644index 00000000000..d2f21bb4865--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-004.txt@@ -0,0 +1,13 @@+Harness status: OK++Found 8 tests++8 Pass+Pass .inner 1+Pass .inner 2+Pass .inner 3+Pass .inner 4+Pass .inner 5+Pass .inner 6+Pass .inner 7+Pass .inner 8\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-005.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-005.txtnew file mode 100644index 00000000000..ec93dec1868--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-005.txt@@ -0,0 +1,9 @@+Harness status: OK++Found 4 tests++4 Pass+Pass .float + div 1+Pass .float + div 2+Pass .float + div 3+Pass .float + div 4\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-007.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-007.txtnew file mode 100644index 00000000000..3a79cabd123--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-007.txt@@ -0,0 +1,25 @@+Harness status: OK++Found 20 tests++20 Pass+Pass .child 1+Pass .child 2+Pass .child 3+Pass .child 4+Pass .child 5+Pass .child 6+Pass .child 7+Pass .child 8+Pass .child 9+Pass .child 10+Pass .child 11+Pass .child 12+Pass .child 13+Pass .child 14+Pass .child 15+Pass .child 16+Pass .child 17+Pass .child 18+Pass .child 19+Pass .child 20\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-008.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-008.txtnew file mode 100644index 00000000000..6db0f8c3e11--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-008.txt@@ -0,0 +1,165 @@+Harness status: OK++Found 160 tests++160 Fail+Fail .child 1+Fail .child 2+Fail .child 3+Fail .child 4+Fail .child 5+Fail .child 6+Fail .child 7+Fail .child 8+Fail .child 9+Fail .child 10+Fail .child 11+Fail .child 12+Fail .child 13+Fail .child 14+Fail .child 15+Fail .child 16+Fail .child 17+Fail .child 18+Fail .child 19+Fail .child 20+Fail .child 21+Fail .child 22+Fail .child 23+Fail .child 24+Fail .child 25+Fail .child 26+Fail .child 27+Fail .child 28+Fail .child 29+Fail .child 30+Fail .child 31+Fail .child 32+Fail .child 33+Fail .child 34+Fail .child 35+Fail .child 36+Fail .child 37+Fail .child 38+Fail .child 39+Fail .child 40+Fail .child 41+Fail .child 42+Fail .child 43+Fail .child 44+Fail .child 45+Fail .child 46+Fail .child 47+Fail .child 48+Fail .child 49+Fail .child 50+Fail .child 51+Fail .child 52+Fail .child 53+Fail .child 54+Fail .child 55+Fail .child 56+Fail .child 57+Fail .child 58+Fail .child 59+Fail .child 60+Fail .child 61+Fail .child 62+Fail .child 63+Fail .child 64+Fail .child 65+Fail .child 66+Fail .child 67+Fail .child 68+Fail .child 69+Fail .child 70+Fail .child 71+Fail .child 72+Fail .child 73+Fail .child 74+Fail .child 75+Fail .child 76+Fail .child 77+Fail .child 78+Fail .child 79+Fail .child 80+Fail .child 81+Fail .child 82+Fail .child 83+Fail .child 84+Fail .child 85+Fail .child 86+Fail .child 87+Fail .child 88+Fail .child 89+Fail .child 90+Fail .child 91+Fail .child 92+Fail .child 93+Fail .child 94+Fail .child 95+Fail .child 96+Fail .child 97+Fail .child 98+Fail .child 99+Fail .child 100+Fail .child 101+Fail .child 102+Fail .child 103+Fail .child 104+Fail .child 105+Fail .child 106+Fail .child 107+Fail .child 108+Fail .child 109+Fail .child 110+Fail .child 111+Fail .child 112+Fail .child 113+Fail .child 114+Fail .child 115+Fail .child 116+Fail .child 117+Fail .child 118+Fail .child 119+Fail .child 120+Fail .child 121+Fail .child 122+Fail .child 123+Fail .child 124+Fail .child 125+Fail .child 126+Fail .child 127+Fail .child 128+Fail .child 129+Fail .child 130+Fail .child 131+Fail .child 132+Fail .child 133+Fail .child 134+Fail .child 135+Fail .child 136+Fail .child 137+Fail .child 138+Fail .child 139+Fail .child 140+Fail .child 141+Fail .child 142+Fail .child 143+Fail .child 144+Fail .child 145+Fail .child 146+Fail .child 147+Fail .child 148+Fail .child 149+Fail .child 150+Fail .child 151+Fail .child 152+Fail .child 153+Fail .child 154+Fail .child 155+Fail .child 156+Fail .child 157+Fail .child 158+Fail .child 159+Fail .child 160\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-011.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-011.txtnew file mode 100644index 00000000000..fab5efde25c--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/block-height-011.txt@@ -0,0 +1,14 @@+Harness status: OK++Found 8 tests++7 Pass+1 Fail+Pass .test 1+Pass .test 2+Fail .test 3+Pass .test 4+Pass .test 5+Pass .test 6+Pass .test 7+Pass .test 8\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/content-contribution-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/content-contribution-001.txtnew file mode 100644index 00000000000..7923a8a3731--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/content-contribution-001.txt@@ -0,0 +1,10 @@+Harness status: OK++Found 5 tests++5 Pass+Pass .test 1+Pass .test 2+Pass .test 3+Pass .test 4+Pass .test 5\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-basis-1.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-basis-1.txtnew file mode 100644index 00000000000..243aff5ef3a--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-basis-1.txt@@ -0,0 +1,10 @@+Harness status: OK++Found 5 tests++5 Pass+Pass .item 1+Pass .item 2+Pass .item 3+Pass .item 4+Pass .item 5\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-001.txtnew file mode 100644index 00000000000..8564efd22b7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-001.txt@@ -0,0 +1,7 @@+Harness status: OK++Found 2 tests++2 Pass+Pass [data-expected-client-height] 1+Pass [data-expected-client-height] 2\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-002.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-002.txtnew file mode 100644index 00000000000..15f4c18256a--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-002.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Pass+Pass [data-expected-client-width] 1\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-003.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-003.txtnew file mode 100644index 00000000000..ddc90001f39--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-item-height-003.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Pass+Pass [data-expected-client-height] 1\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-001.txtnew file mode 100644index 00000000000..37eee8323c7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-001.txt@@ -0,0 +1,9 @@+Harness status: OK++Found 4 tests++4 Pass+Pass .stretch 1+Pass .stretch 2+Pass .stretch 3+Pass .stretch 4\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-002.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-002.txtnew file mode 100644index 00000000000..37eee8323c7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-002.txt@@ -0,0 +1,9 @@+Harness status: OK++Found 4 tests++4 Pass+Pass .stretch 1+Pass .stretch 2+Pass .stretch 3+Pass .stretch 4\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-003.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-003.txtnew file mode 100644index 00000000000..37eee8323c7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-003.txt@@ -0,0 +1,9 @@+Harness status: OK++Found 4 tests++4 Pass+Pass .stretch 1+Pass .stretch 2+Pass .stretch 3+Pass .stretch 4\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-004.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-004.txtnew file mode 100644index 00000000000..37eee8323c7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-004.txt@@ -0,0 +1,9 @@+Harness status: OK++Found 4 tests++4 Pass+Pass .stretch 1+Pass .stretch 2+Pass .stretch 3+Pass .stretch 4\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-005.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-005.txtnew file mode 100644index 00000000000..35f3ff9524d--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-line-005.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Pass+Pass .stretch 1\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-stretch-min-max-cross-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-stretch-min-max-cross-001.txtnew file mode 100644index 00000000000..d268bd347dc--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/flex-stretch-min-max-cross-001.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Pass+Pass [data-expected-height] 1\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/grid-item-height-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/grid-item-height-001.txtnew file mode 100644index 00000000000..2c893bbb021--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/grid-item-height-001.txt@@ -0,0 +1,7 @@+Harness status: OK++Found 2 tests++2 Pass+Pass [data-expected-height] 1+Pass [data-expected-height] 2\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-1.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-1.txtnew file mode 100644index 00000000000..8564efd22b7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-1.txt@@ -0,0 +1,7 @@+Harness status: OK++Found 2 tests++2 Pass+Pass [data-expected-client-height] 1+Pass [data-expected-client-height] 2\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-2.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-2.txtnew file mode 100644index 00000000000..ddc90001f39--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-2.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Pass+Pass [data-expected-client-height] 1\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-3.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-3.txtnew file mode 100644index 00000000000..ddc90001f39--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-3.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Pass+Pass [data-expected-client-height] 1\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-4.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-4.txtnew file mode 100644index 00000000000..a21fa747457--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-4.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Fail+Fail [data-expected-client-height] 1\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-5.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-5.txtnew file mode 100644index 00000000000..8564efd22b7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-5.txt@@ -0,0 +1,7 @@+Harness status: OK++Found 2 tests++2 Pass+Pass [data-expected-client-height] 1+Pass [data-expected-client-height] 2\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-6.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-6.txtnew file mode 100644index 00000000000..8564efd22b7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/indefinite-6.txt@@ -0,0 +1,7 @@+Harness status: OK++Found 2 tests++2 Pass+Pass [data-expected-client-height] 1+Pass [data-expected-client-height] 2\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/parsing.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/parsing.txtnew file mode 100644index 00000000000..53b8d7b4e9d--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/parsing.txt@@ -0,0 +1,22 @@+Harness status: OK++Found 17 tests++17 Pass+Pass e.style['width'] = "stretch" should set the property value+Pass e.style['height'] = "stretch" should set the property value+Pass e.style['max-width'] = "stretch" should set the property value+Pass e.style['min-width'] = "stretch" should set the property value+Pass e.style['max-height'] = "stretch" should set the property value+Pass e.style['min-height'] = "stretch" should set the property value+Pass e.style['inline-size'] = "stretch" should set the property value+Pass e.style['block-size'] = "stretch" should set the property value+Pass e.style['max-inline-size'] = "stretch" should set the property value+Pass e.style['min-inline-size'] = "stretch" should set the property value+Pass e.style['max-block-size'] = "stretch" should set the property value+Pass e.style['min-block-size'] = "stretch" should set the property value+Pass e.style['flex-basis'] = "stretch" should set the property value+Pass e.style['flex'] = "1 0 stretch" should set flex-basis+Pass e.style['flex'] = "1 0 stretch" should set flex-grow+Pass e.style['flex'] = "1 0 stretch" should set flex-shrink+Pass e.style['flex'] = "1 0 stretch" should not set unrelated longhands\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/replaced-stretch-height-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/replaced-stretch-height-001.txtnew file mode 100644index 00000000000..b9669b605d7--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/replaced-stretch-height-001.txt@@ -0,0 +1,6 @@+Harness status: OK++Found 1 tests++1 Pass+Pass [data-expected-height], [data-expected-width] 1\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-block-size-001.tentative.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-block-size-001.tentative.txtnew file mode 100644index 00000000000..6a8fef5250d--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-block-size-001.tentative.txt@@ -0,0 +1,51 @@+Harness status: OK++Found 46 tests++46 Pass+Pass [data-expected-height] 1+Pass [data-expected-height] 2+Pass [data-expected-height] 3+Pass [data-expected-height] 4+Pass [data-expected-height] 5+Pass [data-expected-height] 6+Pass [data-expected-height] 7+Pass [data-expected-height] 8+Pass [data-expected-height] 9+Pass [data-expected-height] 10+Pass [data-expected-height] 11+Pass [data-expected-height] 12+Pass [data-expected-height] 13+Pass [data-expected-height] 14+Pass [data-expected-height] 15+Pass [data-expected-height] 16+Pass [data-expected-height] 17+Pass [data-expected-height] 18+Pass [data-expected-height] 19+Pass [data-expected-height] 20+Pass [data-expected-height] 21+Pass [data-expected-height] 22+Pass [data-expected-height] 23+Pass [data-expected-height] 24+Pass [data-expected-height] 25+Pass [data-expected-height] 26+Pass [data-expected-height] 27+Pass [data-expected-height] 28+Pass [data-expected-height] 29+Pass [data-expected-height] 30+Pass [data-expected-height] 31+Pass [data-expected-height] 32+Pass [data-expected-height] 33+Pass [data-expected-height] 34+Pass [data-expected-height] 35+Pass [data-expected-height] 36+Pass [data-expected-height] 37+Pass [data-expected-height] 38+Pass [data-expected-height] 39+Pass [data-expected-height] 40+Pass [data-expected-height] 41+Pass [data-expected-height] 42+Pass [data-expected-height] 43+Pass [data-expected-height] 44+Pass [data-expected-height] 45+Pass [data-expected-height] 46\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-inline-size-001.tentative.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-inline-size-001.tentative.txtnew file mode 100644index 00000000000..cdae237076c--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-inline-size-001.tentative.txt@@ -0,0 +1,51 @@+Harness status: OK++Found 46 tests++46 Pass+Pass [data-expected-width] 1+Pass [data-expected-width] 2+Pass [data-expected-width] 3+Pass [data-expected-width] 4+Pass [data-expected-width] 5+Pass [data-expected-width] 6+Pass [data-expected-width] 7+Pass [data-expected-width] 8+Pass [data-expected-width] 9+Pass [data-expected-width] 10+Pass [data-expected-width] 11+Pass [data-expected-width] 12+Pass [data-expected-width] 13+Pass [data-expected-width] 14+Pass [data-expected-width] 15+Pass [data-expected-width] 16+Pass [data-expected-width] 17+Pass [data-expected-width] 18+Pass [data-expected-width] 19+Pass [data-expected-width] 20+Pass [data-expected-width] 21+Pass [data-expected-width] 22+Pass [data-expected-width] 23+Pass [data-expected-width] 24+Pass [data-expected-width] 25+Pass [data-expected-width] 26+Pass [data-expected-width] 27+Pass [data-expected-width] 28+Pass [data-expected-width] 29+Pass [data-expected-width] 30+Pass [data-expected-width] 31+Pass [data-expected-width] 32+Pass [data-expected-width] 33+Pass [data-expected-width] 34+Pass [data-expected-width] 35+Pass [data-expected-width] 36+Pass [data-expected-width] 37+Pass [data-expected-width] 38+Pass [data-expected-width] 39+Pass [data-expected-width] 40+Pass [data-expected-width] 41+Pass [data-expected-width] 42+Pass [data-expected-width] 43+Pass [data-expected-width] 44+Pass [data-expected-width] 45+Pass [data-expected-width] 46\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-max-block-size-001.tentative.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-max-block-size-001.tentative.txtnew file mode 100644index 00000000000..0d26eb065dc--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-max-block-size-001.tentative.txt@@ -0,0 +1,51 @@+Harness status: OK++Found 45 tests++43 Pass+2 Fail+Pass [data-expected-height] 1+Pass [data-expected-height] 2+Pass [data-expected-height] 3+Pass [data-expected-height] 4+Pass [data-expected-height] 5+Pass [data-expected-height] 6+Pass [data-expected-height] 7+Pass [data-expected-height] 8+Pass [data-expected-height] 9+Pass [data-expected-height] 10+Pass [data-expected-height] 11+Pass [data-expected-height] 12+Pass [data-expected-height] 13+Pass [data-expected-height] 14+Pass [data-expected-height] 15+Pass [data-expected-height] 16+Pass [data-expected-height] 17+Pass [data-expected-height] 18+Pass [data-expected-height] 19+Pass [data-expected-height] 20+Fail [data-expected-height] 21+Pass [data-expected-height] 22+Pass [data-expected-height] 23+Pass [data-expected-height]:not([skip-second-pass]) 24+Pass [data-expected-height]:not([skip-second-pass]) 25+Pass [data-expected-height]:not([skip-second-pass]) 26+Pass [data-expected-height]:not([skip-second-pass]) 27+Pass [data-expected-height]:not([skip-second-pass]) 28+Pass [data-expected-height]:not([skip-second-pass]) 29+Pass [data-expected-height]:not([skip-second-pass]) 30+Pass [data-expected-height]:not([skip-second-pass]) 31+Pass [data-expected-height]:not([skip-second-pass]) 32+Pass [data-expected-height]:not([skip-second-pass]) 33+Pass [data-expected-height]:not([skip-second-pass]) 34+Pass [data-expected-height]:not([skip-second-pass]) 35+Pass [data-expected-height]:not([skip-second-pass]) 36+Pass [data-expected-height]:not([skip-second-pass]) 37+Pass [data-expected-height]:not([skip-second-pass]) 38+Pass [data-expected-height]:not([skip-second-pass]) 39+Pass [data-expected-height]:not([skip-second-pass]) 40+Pass [data-expected-height]:not([skip-second-pass]) 41+Pass [data-expected-height]:not([skip-second-pass]) 42+Pass [data-expected-height]:not([skip-second-pass]) 43+Fail [data-expected-height]:not([skip-second-pass]) 44+Pass [data-expected-height]:not([skip-second-pass]) 45\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-max-inline-size-001.tentative.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-max-inline-size-001.tentative.txtnew file mode 100644index 00000000000..f510459b137--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-max-inline-size-001.tentative.txt@@ -0,0 +1,51 @@+Harness status: OK++Found 45 tests++43 Pass+2 Fail+Pass [data-expected-width] 1+Pass [data-expected-width] 2+Pass [data-expected-width] 3+Pass [data-expected-width] 4+Pass [data-expected-width] 5+Pass [data-expected-width] 6+Pass [data-expected-width] 7+Pass [data-expected-width] 8+Pass [data-expected-width] 9+Pass [data-expected-width] 10+Pass [data-expected-width] 11+Pass [data-expected-width] 12+Pass [data-expected-width] 13+Pass [data-expected-width] 14+Pass [data-expected-width] 15+Pass [data-expected-width] 16+Pass [data-expected-width] 17+Pass [data-expected-width] 18+Pass [data-expected-width] 19+Pass [data-expected-width] 20+Fail [data-expected-width] 21+Pass [data-expected-width] 22+Pass [data-expected-width] 23+Pass [data-expected-width]:not([skip-second-pass]) 24+Pass [data-expected-width]:not([skip-second-pass]) 25+Pass [data-expected-width]:not([skip-second-pass]) 26+Pass [data-expected-width]:not([skip-second-pass]) 27+Pass [data-expected-width]:not([skip-second-pass]) 28+Pass [data-expected-width]:not([skip-second-pass]) 29+Pass [data-expected-width]:not([skip-second-pass]) 30+Pass [data-expected-width]:not([skip-second-pass]) 31+Pass [data-expected-width]:not([skip-second-pass]) 32+Pass [data-expected-width]:not([skip-second-pass]) 33+Pass [data-expected-width]:not([skip-second-pass]) 34+Pass [data-expected-width]:not([skip-second-pass]) 35+Pass [data-expected-width]:not([skip-second-pass]) 36+Pass [data-expected-width]:not([skip-second-pass]) 37+Pass [data-expected-width]:not([skip-second-pass]) 38+Pass [data-expected-width]:not([skip-second-pass]) 39+Pass [data-expected-width]:not([skip-second-pass]) 40+Pass [data-expected-width]:not([skip-second-pass]) 41+Pass [data-expected-width]:not([skip-second-pass]) 42+Pass [data-expected-width]:not([skip-second-pass]) 43+Fail [data-expected-width]:not([skip-second-pass]) 44+Pass [data-expected-width]:not([skip-second-pass]) 45\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-min-block-size-001.tentative.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-min-block-size-001.tentative.txtnew file mode 100644index 00000000000..d8dd665198a--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-min-block-size-001.tentative.txt@@ -0,0 +1,52 @@+Harness status: OK++Found 46 tests++44 Pass+2 Fail+Pass [data-expected-height] 1+Pass [data-expected-height] 2+Pass [data-expected-height] 3+Pass [data-expected-height] 4+Pass [data-expected-height] 5+Pass [data-expected-height] 6+Pass [data-expected-height] 7+Pass [data-expected-height] 8+Pass [data-expected-height] 9+Pass [data-expected-height] 10+Pass [data-expected-height] 11+Pass [data-expected-height] 12+Pass [data-expected-height] 13+Pass [data-expected-height] 14+Pass [data-expected-height] 15+Pass [data-expected-height] 16+Pass [data-expected-height] 17+Pass [data-expected-height] 18+Pass [data-expected-height] 19+Pass [data-expected-height] 20+Fail [data-expected-height] 21+Pass [data-expected-height] 22+Pass [data-expected-height] 23+Pass [data-expected-height] 24+Pass [data-expected-height] 25+Pass [data-expected-height] 26+Pass [data-expected-height] 27+Pass [data-expected-height] 28+Pass [data-expected-height] 29+Pass [data-expected-height] 30+Pass [data-expected-height] 31+Pass [data-expected-height] 32+Pass [data-expected-height] 33+Pass [data-expected-height] 34+Pass [data-expected-height] 35+Pass [data-expected-height] 36+Pass [data-expected-height] 37+Pass [data-expected-height] 38+Pass [data-expected-height] 39+Pass [data-expected-height] 40+Pass [data-expected-height] 41+Pass [data-expected-height] 42+Pass [data-expected-height] 43+Fail [data-expected-height] 44+Pass [data-expected-height] 45+Pass [data-expected-height] 46\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-min-inline-size-001.tentative.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-min-inline-size-001.tentative.txtnew file mode 100644index 00000000000..a853e83ba68--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-alias-min-inline-size-001.tentative.txt@@ -0,0 +1,52 @@+Harness status: OK++Found 46 tests++44 Pass+2 Fail+Pass [data-expected-width] 1+Pass [data-expected-width] 2+Pass [data-expected-width] 3+Pass [data-expected-width] 4+Pass [data-expected-width] 5+Pass [data-expected-width] 6+Pass [data-expected-width] 7+Pass [data-expected-width] 8+Pass [data-expected-width] 9+Pass [data-expected-width] 10+Pass [data-expected-width] 11+Pass [data-expected-width] 12+Pass [data-expected-width] 13+Pass [data-expected-width] 14+Pass [data-expected-width] 15+Pass [data-expected-width] 16+Pass [data-expected-width] 17+Pass [data-expected-width] 18+Pass [data-expected-width] 19+Pass [data-expected-width] 20+Fail [data-expected-width] 21+Pass [data-expected-width] 22+Pass [data-expected-width] 23+Pass [data-expected-width] 24+Pass [data-expected-width] 25+Pass [data-expected-width] 26+Pass [data-expected-width] 27+Pass [data-expected-width] 28+Pass [data-expected-width] 29+Pass [data-expected-width] 30+Pass [data-expected-width] 31+Pass [data-expected-width] 32+Pass [data-expected-width] 33+Pass [data-expected-width] 34+Pass [data-expected-width] 35+Pass [data-expected-width] 36+Pass [data-expected-width] 37+Pass [data-expected-width] 38+Pass [data-expected-width] 39+Pass [data-expected-width] 40+Pass [data-expected-width] 41+Pass [data-expected-width] 42+Pass [data-expected-width] 43+Fail [data-expected-width] 44+Pass [data-expected-width] 45+Pass [data-expected-width] 46\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-001.txtnew file mode 100644index 00000000000..6a8fef5250d--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-001.txt@@ -0,0 +1,51 @@+Harness status: OK++Found 46 tests++46 Pass+Pass [data-expected-height] 1+Pass [data-expected-height] 2+Pass [data-expected-height] 3+Pass [data-expected-height] 4+Pass [data-expected-height] 5+Pass [data-expected-height] 6+Pass [data-expected-height] 7+Pass [data-expected-height] 8+Pass [data-expected-height] 9+Pass [data-expected-height] 10+Pass [data-expected-height] 11+Pass [data-expected-height] 12+Pass [data-expected-height] 13+Pass [data-expected-height] 14+Pass [data-expected-height] 15+Pass [data-expected-height] 16+Pass [data-expected-height] 17+Pass [data-expected-height] 18+Pass [data-expected-height] 19+Pass [data-expected-height] 20+Pass [data-expected-height] 21+Pass [data-expected-height] 22+Pass [data-expected-height] 23+Pass [data-expected-height] 24+Pass [data-expected-height] 25+Pass [data-expected-height] 26+Pass [data-expected-height] 27+Pass [data-expected-height] 28+Pass [data-expected-height] 29+Pass [data-expected-height] 30+Pass [data-expected-height] 31+Pass [data-expected-height] 32+Pass [data-expected-height] 33+Pass [data-expected-height] 34+Pass [data-expected-height] 35+Pass [data-expected-height] 36+Pass [data-expected-height] 37+Pass [data-expected-height] 38+Pass [data-expected-height] 39+Pass [data-expected-height] 40+Pass [data-expected-height] 41+Pass [data-expected-height] 42+Pass [data-expected-height] 43+Pass [data-expected-height] 44+Pass [data-expected-height] 45+Pass [data-expected-height] 46\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-002.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-002.txtnew file mode 100644index 00000000000..98900660286--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-002.txt@@ -0,0 +1,41 @@+Harness status: OK++Found 36 tests++36 Pass+Pass .test 1+Pass .test 2+Pass .test 3+Pass .test 4+Pass .test 5+Pass .test 6+Pass .test 7+Pass .test 8+Pass .test 9+Pass .test 10+Pass .test 11+Pass .test 12+Pass .test 13+Pass .test 14+Pass .test 15+Pass .test 16+Pass .test 17+Pass .test 18+Pass .test 19+Pass .test 20+Pass .test 21+Pass .test 22+Pass .test 23+Pass .test 24+Pass .test 25+Pass .test 26+Pass .test 27+Pass .test 28+Pass .test 29+Pass .test 30+Pass .test 31+Pass .test 32+Pass .test 33+Pass .test 34+Pass .test 35+Pass .test 36\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-003.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-003.txtnew file mode 100644index 00000000000..98900660286--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-block-size-003.txt@@ -0,0 +1,41 @@+Harness status: OK++Found 36 tests++36 Pass+Pass .test 1+Pass .test 2+Pass .test 3+Pass .test 4+Pass .test 5+Pass .test 6+Pass .test 7+Pass .test 8+Pass .test 9+Pass .test 10+Pass .test 11+Pass .test 12+Pass .test 13+Pass .test 14+Pass .test 15+Pass .test 16+Pass .test 17+Pass .test 18+Pass .test 19+Pass .test 20+Pass .test 21+Pass .test 22+Pass .test 23+Pass .test 24+Pass .test 25+Pass .test 26+Pass .test 27+Pass .test 28+Pass .test 29+Pass .test 30+Pass .test 31+Pass .test 32+Pass .test 33+Pass .test 34+Pass .test 35+Pass .test 36\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-001.txtnew file mode 100644index 00000000000..cdae237076c--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-001.txt@@ -0,0 +1,51 @@+Harness status: OK++Found 46 tests++46 Pass+Pass [data-expected-width] 1+Pass [data-expected-width] 2+Pass [data-expected-width] 3+Pass [data-expected-width] 4+Pass [data-expected-width] 5+Pass [data-expected-width] 6+Pass [data-expected-width] 7+Pass [data-expected-width] 8+Pass [data-expected-width] 9+Pass [data-expected-width] 10+Pass [data-expected-width] 11+Pass [data-expected-width] 12+Pass [data-expected-width] 13+Pass [data-expected-width] 14+Pass [data-expected-width] 15+Pass [data-expected-width] 16+Pass [data-expected-width] 17+Pass [data-expected-width] 18+Pass [data-expected-width] 19+Pass [data-expected-width] 20+Pass [data-expected-width] 21+Pass [data-expected-width] 22+Pass [data-expected-width] 23+Pass [data-expected-width] 24+Pass [data-expected-width] 25+Pass [data-expected-width] 26+Pass [data-expected-width] 27+Pass [data-expected-width] 28+Pass [data-expected-width] 29+Pass [data-expected-width] 30+Pass [data-expected-width] 31+Pass [data-expected-width] 32+Pass [data-expected-width] 33+Pass [data-expected-width] 34+Pass [data-expected-width] 35+Pass [data-expected-width] 36+Pass [data-expected-width] 37+Pass [data-expected-width] 38+Pass [data-expected-width] 39+Pass [data-expected-width] 40+Pass [data-expected-width] 41+Pass [data-expected-width] 42+Pass [data-expected-width] 43+Pass [data-expected-width] 44+Pass [data-expected-width] 45+Pass [data-expected-width] 46\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-002.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-002.txtnew file mode 100644index 00000000000..98900660286--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-002.txt@@ -0,0 +1,41 @@+Harness status: OK++Found 36 tests++36 Pass+Pass .test 1+Pass .test 2+Pass .test 3+Pass .test 4+Pass .test 5+Pass .test 6+Pass .test 7+Pass .test 8+Pass .test 9+Pass .test 10+Pass .test 11+Pass .test 12+Pass .test 13+Pass .test 14+Pass .test 15+Pass .test 16+Pass .test 17+Pass .test 18+Pass .test 19+Pass .test 20+Pass .test 21+Pass .test 22+Pass .test 23+Pass .test 24+Pass .test 25+Pass .test 26+Pass .test 27+Pass .test 28+Pass .test 29+Pass .test 30+Pass .test 31+Pass .test 32+Pass .test 33+Pass .test 34+Pass .test 35+Pass .test 36\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-003.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-003.txtnew file mode 100644index 00000000000..98900660286--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-inline-size-003.txt@@ -0,0 +1,41 @@+Harness status: OK++Found 36 tests++36 Pass+Pass .test 1+Pass .test 2+Pass .test 3+Pass .test 4+Pass .test 5+Pass .test 6+Pass .test 7+Pass .test 8+Pass .test 9+Pass .test 10+Pass .test 11+Pass .test 12+Pass .test 13+Pass .test 14+Pass .test 15+Pass .test 16+Pass .test 17+Pass .test 18+Pass .test 19+Pass .test 20+Pass .test 21+Pass .test 22+Pass .test 23+Pass .test 24+Pass .test 25+Pass .test 26+Pass .test 27+Pass .test 28+Pass .test 29+Pass .test 30+Pass .test 31+Pass .test 32+Pass .test 33+Pass .test 34+Pass .test 35+Pass .test 36\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-max-block-size-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-max-block-size-001.txtnew file mode 100644index 00000000000..0d26eb065dc--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-max-block-size-001.txt@@ -0,0 +1,51 @@+Harness status: OK++Found 45 tests++43 Pass+2 Fail+Pass [data-expected-height] 1+Pass [data-expected-height] 2+Pass [data-expected-height] 3+Pass [data-expected-height] 4+Pass [data-expected-height] 5+Pass [data-expected-height] 6+Pass [data-expected-height] 7+Pass [data-expected-height] 8+Pass [data-expected-height] 9+Pass [data-expected-height] 10+Pass [data-expected-height] 11+Pass [data-expected-height] 12+Pass [data-expected-height] 13+Pass [data-expected-height] 14+Pass [data-expected-height] 15+Pass [data-expected-height] 16+Pass [data-expected-height] 17+Pass [data-expected-height] 18+Pass [data-expected-height] 19+Pass [data-expected-height] 20+Fail [data-expected-height] 21+Pass [data-expected-height] 22+Pass [data-expected-height] 23+Pass [data-expected-height]:not([skip-second-pass]) 24+Pass [data-expected-height]:not([skip-second-pass]) 25+Pass [data-expected-height]:not([skip-second-pass]) 26+Pass [data-expected-height]:not([skip-second-pass]) 27+Pass [data-expected-height]:not([skip-second-pass]) 28+Pass [data-expected-height]:not([skip-second-pass]) 29+Pass [data-expected-height]:not([skip-second-pass]) 30+Pass [data-expected-height]:not([skip-second-pass]) 31+Pass [data-expected-height]:not([skip-second-pass]) 32+Pass [data-expected-height]:not([skip-second-pass]) 33+Pass [data-expected-height]:not([skip-second-pass]) 34+Pass [data-expected-height]:not([skip-second-pass]) 35+Pass [data-expected-height]:not([skip-second-pass]) 36+Pass [data-expected-height]:not([skip-second-pass]) 37+Pass [data-expected-height]:not([skip-second-pass]) 38+Pass [data-expected-height]:not([skip-second-pass]) 39+Pass [data-expected-height]:not([skip-second-pass]) 40+Pass [data-expected-height]:not([skip-second-pass]) 41+Pass [data-expected-height]:not([skip-second-pass]) 42+Pass [data-expected-height]:not([skip-second-pass]) 43+Fail [data-expected-height]:not([skip-second-pass]) 44+Pass [data-expected-height]:not([skip-second-pass]) 45\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-max-inline-size-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-max-inline-size-001.txtnew file mode 100644index 00000000000..f510459b137--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-max-inline-size-001.txt@@ -0,0 +1,51 @@+Harness status: OK++Found 45 tests++43 Pass+2 Fail+Pass [data-expected-width] 1+Pass [data-expected-width] 2+Pass [data-expected-width] 3+Pass [data-expected-width] 4+Pass [data-expected-width] 5+Pass [data-expected-width] 6+Pass [data-expected-width] 7+Pass [data-expected-width] 8+Pass [data-expected-width] 9+Pass [data-expected-width] 10+Pass [data-expected-width] 11+Pass [data-expected-width] 12+Pass [data-expected-width] 13+Pass [data-expected-width] 14+Pass [data-expected-width] 15+Pass [data-expected-width] 16+Pass [data-expected-width] 17+Pass [data-expected-width] 18+Pass [data-expected-width] 19+Pass [data-expected-width] 20+Fail [data-expected-width] 21+Pass [data-expected-width] 22+Pass [data-expected-width] 23+Pass [data-expected-width]:not([skip-second-pass]) 24+Pass [data-expected-width]:not([skip-second-pass]) 25+Pass [data-expected-width]:not([skip-second-pass]) 26+Pass [data-expected-width]:not([skip-second-pass]) 27+Pass [data-expected-width]:not([skip-second-pass]) 28+Pass [data-expected-width]:not([skip-second-pass]) 29+Pass [data-expected-width]:not([skip-second-pass]) 30+Pass [data-expected-width]:not([skip-second-pass]) 31+Pass [data-expected-width]:not([skip-second-pass]) 32+Pass [data-expected-width]:not([skip-second-pass]) 33+Pass [data-expected-width]:not([skip-second-pass]) 34+Pass [data-expected-width]:not([skip-second-pass]) 35+Pass [data-expected-width]:not([skip-second-pass]) 36+Pass [data-expected-width]:not([skip-second-pass]) 37+Pass [data-expected-width]:not([skip-second-pass]) 38+Pass [data-expected-width]:not([skip-second-pass]) 39+Pass [data-expected-width]:not([skip-second-pass]) 40+Pass [data-expected-width]:not([skip-second-pass]) 41+Pass [data-expected-width]:not([skip-second-pass]) 42+Pass [data-expected-width]:not([skip-second-pass]) 43+Fail [data-expected-width]:not([skip-second-pass]) 44+Pass [data-expected-width]:not([skip-second-pass]) 45\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-min-block-size-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-min-block-size-001.txtnew file mode 100644index 00000000000..d8dd665198a--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-min-block-size-001.txt@@ -0,0 +1,52 @@+Harness status: OK++Found 46 tests++44 Pass+2 Fail+Pass [data-expected-height] 1+Pass [data-expected-height] 2+Pass [data-expected-height] 3+Pass [data-expected-height] 4+Pass [data-expected-height] 5+Pass [data-expected-height] 6+Pass [data-expected-height] 7+Pass [data-expected-height] 8+Pass [data-expected-height] 9+Pass [data-expected-height] 10+Pass [data-expected-height] 11+Pass [data-expected-height] 12+Pass [data-expected-height] 13+Pass [data-expected-height] 14+Pass [data-expected-height] 15+Pass [data-expected-height] 16+Pass [data-expected-height] 17+Pass [data-expected-height] 18+Pass [data-expected-height] 19+Pass [data-expected-height] 20+Fail [data-expected-height] 21+Pass [data-expected-height] 22+Pass [data-expected-height] 23+Pass [data-expected-height] 24+Pass [data-expected-height] 25+Pass [data-expected-height] 26+Pass [data-expected-height] 27+Pass [data-expected-height] 28+Pass [data-expected-height] 29+Pass [data-expected-height] 30+Pass [data-expected-height] 31+Pass [data-expected-height] 32+Pass [data-expected-height] 33+Pass [data-expected-height] 34+Pass [data-expected-height] 35+Pass [data-expected-height] 36+Pass [data-expected-height] 37+Pass [data-expected-height] 38+Pass [data-expected-height] 39+Pass [data-expected-height] 40+Pass [data-expected-height] 41+Pass [data-expected-height] 42+Pass [data-expected-height] 43+Fail [data-expected-height] 44+Pass [data-expected-height] 45+Pass [data-expected-height] 46\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-min-inline-size-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-min-inline-size-001.txtnew file mode 100644index 00000000000..a853e83ba68--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-min-inline-size-001.txt@@ -0,0 +1,52 @@+Harness status: OK++Found 46 tests++44 Pass+2 Fail+Pass [data-expected-width] 1+Pass [data-expected-width] 2+Pass [data-expected-width] 3+Pass [data-expected-width] 4+Pass [data-expected-width] 5+Pass [data-expected-width] 6+Pass [data-expected-width] 7+Pass [data-expected-width] 8+Pass [data-expected-width] 9+Pass [data-expected-width] 10+Pass [data-expected-width] 11+Pass [data-expected-width] 12+Pass [data-expected-width] 13+Pass [data-expected-width] 14+Pass [data-expected-width] 15+Pass [data-expected-width] 16+Pass [data-expected-width] 17+Pass [data-expected-width] 18+Pass [data-expected-width] 19+Pass [data-expected-width] 20+Fail [data-expected-width] 21+Pass [data-expected-width] 22+Pass [data-expected-width] 23+Pass [data-expected-width] 24+Pass [data-expected-width] 25+Pass [data-expected-width] 26+Pass [data-expected-width] 27+Pass [data-expected-width] 28+Pass [data-expected-width] 29+Pass [data-expected-width] 30+Pass [data-expected-width] 31+Pass [data-expected-width] 32+Pass [data-expected-width] 33+Pass [data-expected-width] 34+Pass [data-expected-width] 35+Pass [data-expected-width] 36+Pass [data-expected-width] 37+Pass [data-expected-width] 38+Pass [data-expected-width] 39+Pass [data-expected-width] 40+Pass [data-expected-width] 41+Pass [data-expected-width] 42+Pass [data-expected-width] 43+Fail [data-expected-width] 44+Pass [data-expected-width] 45+Pass [data-expected-width] 46\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-table-001.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-table-001.txtnew file mode 100644index 00000000000..848d5d4faaf--- /dev/null+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-sizing/stretch/stretch-table-001.txt@@ -0,0 +1,13 @@+Harness status: OK++Found 7 tests++6 Pass+1 Fail+Pass .stretch 1+Fail .stretch 2+Pass .stretch 3+Pass .stretch 4+Pass .stretch 5+Pass .stretch 6+Pass .stretch 7\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-tables/fixed-layout-2.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-tables/fixed-layout-2.txtindex 2855ebc47fd..2589ec8dc4b 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-tables/fixed-layout-2.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-tables/fixed-layout-2.txt@@ -1,8 +1,8 @@Harness status: OK-Found 17 tests+Found 20 tests-17 Pass+20 PassPass 10pxPass calc-size(10px, size)Pass 100%@@ -19,4 +19,7 @@ Pass fit-contentPass calc-size(fit-content, size)Pass calc-size(any, 10px + 100%)Pass calc-size(calc-size(any, 10px + 100%), size)-Pass fit-content(0)\ No newline at end of file+Pass fit-content(0)+Pass stretch+Pass calc-size(stretch, size)+Pass -webkit-fill-available\ No newline at end of filediff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/calc-size-height-interpolation.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/calc-size-height-interpolation.txtindex 9ad681739a2..1d2917d8437 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/calc-size-height-interpolation.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/calc-size-height-interpolation.txt@@ -2,8 +2,7 @@ Harness status: OKFound 1156 tests-992 Pass-164 Fail+1156 PassPass CSS Transitions: property <height> from [calc-size(auto, size)] to [calc-size(auto, size * 2)] at (-0.25) should be [75px]Pass CSS Transitions: property <height> from [calc-size(auto, size)] to [calc-size(auto, size * 2)] at (0) should be [100px]Pass CSS Transitions: property <height> from [calc-size(auto, size)] to [calc-size(auto, size * 2)] at (0.25) should be [125px]@@ -464,86 +463,86 @@ Pass Web Animations: property <height> from [max-content] to [calc-size(50px, siPass Web Animations: property <height> from [max-content] to [calc-size(50px, size)] at (0.75) should be [62.5px]Pass Web Animations: property <height> from [max-content] to [calc-size(50px, size)] at (1) should be [50px]Pass Web Animations: property <height> from [max-content] to [calc-size(50px, size)] at (1.1) should be [45.00000000000001px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [225px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [300px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [525px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [600px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [675px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [225px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [300px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [525px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [600px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [675px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [225px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [300px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [525px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [600px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [675px]-Fail Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [225px]-Fail Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [300px]-Fail Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [525px]-Fail Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [600px]-Fail Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [675px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [362.5px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (0) should be [300px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [112.5px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (1.1) should be [25.000000000000007px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [362.5px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (0) should be [300px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [112.5px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (1.1) should be [25.000000000000007px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [362.5px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (0) should be [300px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [112.5px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (1.1) should be [25.000000000000007px]-Fail Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [362.5px]-Fail Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (0) should be [300px]-Fail Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [112.5px]-Fail Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]-Fail Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (1.1) should be [25.000000000000007px]-Fail CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.05) should be [22.5px]-Fail CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]-Fail CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [462.5px]-Fail CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [600px]-Fail CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [737.5px]-Fail CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.05) should be [22.5px]-Fail CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]-Fail CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [462.5px]-Fail CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [600px]-Fail CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [737.5px]-Fail CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.05) should be [22.5px]-Fail CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]-Fail CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [462.5px]-Fail CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [600px]-Fail CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [737.5px]-Fail Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.05) should be [22.5px]-Fail Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]-Fail Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [462.5px]-Fail Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [600px]-Fail Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [737.5px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [362.5px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (0) should be [300px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (0.75) should be [112.5px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (1.1) should be [25.000000000000007px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [362.5px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (0) should be [300px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (0.75) should be [112.5px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (1.1) should be [25.000000000000007px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [362.5px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (0) should be [300px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (0.75) should be [112.5px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]-Fail CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (1.1) should be [25.000000000000007px]-Fail Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [362.5px]-Fail Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (0) should be [300px]-Fail Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (0.75) should be [112.5px]-Fail Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]-Fail Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (1.1) should be [25.000000000000007px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [225px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [300px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [525px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [600px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [675px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [225px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [300px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [525px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [600px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [675px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [225px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [300px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [525px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [600px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [675px]+Pass Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [225px]+Pass Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [300px]+Pass Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [525px]+Pass Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [600px]+Pass Web Animations: property <height> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [675px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [362.5px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (0) should be [300px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [112.5px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(any, 50px)] at (1.1) should be [25.000000000000007px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [362.5px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (0) should be [300px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [112.5px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(any, 50px)] at (1.1) should be [25.000000000000007px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [362.5px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (0) should be [300px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [112.5px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (1.1) should be [25.000000000000007px]+Pass Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [362.5px]+Pass Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (0) should be [300px]+Pass Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [112.5px]+Pass Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]+Pass Web Animations: property <height> from [stretch] to [calc-size(any, 50px)] at (1.1) should be [25.000000000000007px]+Pass CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.05) should be [22.5px]+Pass CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]+Pass CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [462.5px]+Pass CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [600px]+Pass CSS Transitions: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [737.5px]+Pass CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.05) should be [22.5px]+Pass CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]+Pass CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [462.5px]+Pass CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [600px]+Pass CSS Transitions with transition: all: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [737.5px]+Pass CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.05) should be [22.5px]+Pass CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]+Pass CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [462.5px]+Pass CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [600px]+Pass CSS Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [737.5px]+Pass Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.05) should be [22.5px]+Pass Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]+Pass Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [462.5px]+Pass Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [600px]+Pass Web Animations: property <height> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [737.5px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [362.5px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (0) should be [300px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (0.75) should be [112.5px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(50px, size)] at (1.1) should be [25.000000000000007px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [362.5px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (0) should be [300px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (0.75) should be [112.5px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(50px, size)] at (1.1) should be [25.000000000000007px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [362.5px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (0) should be [300px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (0.75) should be [112.5px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]+Pass CSS Animations: property <height> from [stretch] to [calc-size(50px, size)] at (1.1) should be [25.000000000000007px]+Pass Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [362.5px]+Pass Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (0) should be [300px]+Pass Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (0.75) should be [112.5px]+Pass Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]+Pass Web Animations: property <height> from [stretch] to [calc-size(50px, size)] at (1.1) should be [25.000000000000007px]Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [auto] to [calc-size(fit-content, size)] at (-0.3) should be [auto]Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [auto] to [calc-size(fit-content, size)] at (0) should be [auto]Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [auto] to [calc-size(fit-content, size)] at (0.3) should be [auto]@@ -628,90 +627,90 @@ Pass Web Animations: property <height> from [fit-content] to [calc-size(min-contPass Web Animations: property <height> from [fit-content] to [calc-size(min-content, size)] at (0.6) should be [calc-size(min-content, size)]Pass Web Animations: property <height> from [fit-content] to [calc-size(min-content, size)] at (1) should be [calc-size(min-content, size)]Pass Web Animations: property <height> from [fit-content] to [calc-size(min-content, size)] at (1.5) should be [calc-size(min-content, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [calc-size(auto, size)]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [calc-size(auto, size)]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [calc-size(auto, size)]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]-Fail CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]-Fail CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]-Fail CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]-Fail Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]-Fail Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]-Fail Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]-Fail CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]-Fail CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]-Fail CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]-Fail Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]-Fail Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]-Fail Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [calc-size(auto, size)]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [calc-size(auto, size)]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [calc-size(auto, size)]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Transitions: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]+Pass CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]+Pass CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]+Pass CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Animations: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]+Pass Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]+Pass Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]+Pass Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass Web Animations: property <height> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]+Pass CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]+Pass CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]+Pass CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]+Pass Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]+Pass Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]+Pass Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass Web Animations: property <height> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]Pass CSS Transitions: property <height> from [calc-size(20px, size)] to [calc-size(60px, size)] at (-0.25) should be [10px]Pass CSS Transitions: property <height> from [calc-size(20px, size)] to [calc-size(60px, size)] at (0) should be [20px]Pass CSS Transitions: property <height> from [calc-size(20px, size)] to [calc-size(60px, size)] at (0.75) should be [50px]diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/calc-size-width-interpolation.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/calc-size-width-interpolation.txtindex 9f70aa8ed7b..6d976e72fab 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/calc-size-width-interpolation.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/calc-size-width-interpolation.txt@@ -2,8 +2,7 @@ Harness status: OKFound 732 tests-568 Pass-164 Fail+732 PassPass CSS Transitions: property <width> from [calc-size(auto, size)] to [calc-size(auto, size * 2)] at (-0.25) should be [150px]Pass CSS Transitions: property <width> from [calc-size(auto, size)] to [calc-size(auto, size * 2)] at (0) should be [200px]Pass CSS Transitions: property <width> from [calc-size(auto, size)] to [calc-size(auto, size * 2)] at (0.25) should be [250px]@@ -408,86 +407,86 @@ Pass Web Animations: property <width> from [max-content] to [calc-size(50px, sizPass Web Animations: property <width> from [max-content] to [calc-size(50px, size)] at (0.75) should be [62.5px]Pass Web Animations: property <width> from [max-content] to [calc-size(50px, size)] at (1) should be [50px]Pass Web Animations: property <width> from [max-content] to [calc-size(50px, size)] at (1.25) should be [37.5px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [150px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [200px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [350px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [400px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [450px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [150px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [200px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [350px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [400px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [450px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [150px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [200px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [350px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [400px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [450px]-Fail Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [150px]-Fail Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [200px]-Fail Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [350px]-Fail Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [400px]-Fail Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [450px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [237.5px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (0) should be [200px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [87.5px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (1.25) should be [12.5px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [237.5px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (0) should be [200px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [87.5px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (1.25) should be [12.5px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [237.5px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (0) should be [200px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [87.5px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (1.25) should be [12.5px]-Fail Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [237.5px]-Fail Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (0) should be [200px]-Fail Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [87.5px]-Fail Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]-Fail Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (1.25) should be [12.5px]-Fail CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.1) should be [15.000000000000007px]-Fail CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]-Fail CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [312.5px]-Fail CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [400px]-Fail CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [487.5px]-Fail CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.1) should be [15.000000000000007px]-Fail CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]-Fail CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [312.5px]-Fail CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [400px]-Fail CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [487.5px]-Fail CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.1) should be [15.000000000000007px]-Fail CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]-Fail CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [312.5px]-Fail CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [400px]-Fail CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [487.5px]-Fail Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.1) should be [15.000000000000007px]-Fail Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]-Fail Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [312.5px]-Fail Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [400px]-Fail Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [487.5px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [237.5px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (0) should be [200px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (0.75) should be [87.5px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (1.25) should be [12.5px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [237.5px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (0) should be [200px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (0.75) should be [87.5px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (1.25) should be [12.5px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [237.5px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (0) should be [200px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (0.75) should be [87.5px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]-Fail CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (1.25) should be [12.5px]-Fail Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [237.5px]-Fail Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (0) should be [200px]-Fail Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (0.75) should be [87.5px]-Fail Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]-Fail Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (1.25) should be [12.5px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [150px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [200px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [350px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [400px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [450px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [150px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [200px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [350px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [400px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [450px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [150px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [200px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [350px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [400px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [450px]+Pass Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (-0.25) should be [150px]+Pass Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0) should be [200px]+Pass Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (0.75) should be [350px]+Pass Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1) should be [400px]+Pass Web Animations: property <width> from [stretch] to [calc-size(stretch, size * 2)] at (1.25) should be [450px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [237.5px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (0) should be [200px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [87.5px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(any, 50px)] at (1.25) should be [12.5px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [237.5px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (0) should be [200px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [87.5px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(any, 50px)] at (1.25) should be [12.5px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [237.5px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (0) should be [200px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [87.5px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (1.25) should be [12.5px]+Pass Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (-0.25) should be [237.5px]+Pass Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (0) should be [200px]+Pass Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (0.75) should be [87.5px]+Pass Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (1) should be [50px]+Pass Web Animations: property <width> from [stretch] to [calc-size(any, 50px)] at (1.25) should be [12.5px]+Pass CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.1) should be [15.000000000000007px]+Pass CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]+Pass CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [312.5px]+Pass CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [400px]+Pass CSS Transitions: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [487.5px]+Pass CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.1) should be [15.000000000000007px]+Pass CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]+Pass CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [312.5px]+Pass CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [400px]+Pass CSS Transitions with transition: all: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [487.5px]+Pass CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.1) should be [15.000000000000007px]+Pass CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]+Pass CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [312.5px]+Pass CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [400px]+Pass CSS Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [487.5px]+Pass Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (-0.1) should be [15.000000000000007px]+Pass Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0) should be [50px]+Pass Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (0.75) should be [312.5px]+Pass Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1) should be [400px]+Pass Web Animations: property <width> from [calc-size(any, 50px)] to [calc-size(stretch, size * 2)] at (1.25) should be [487.5px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [237.5px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (0) should be [200px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (0.75) should be [87.5px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(50px, size)] at (1.25) should be [12.5px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [237.5px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (0) should be [200px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (0.75) should be [87.5px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(50px, size)] at (1.25) should be [12.5px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [237.5px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (0) should be [200px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (0.75) should be [87.5px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]+Pass CSS Animations: property <width> from [stretch] to [calc-size(50px, size)] at (1.25) should be [12.5px]+Pass Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (-0.25) should be [237.5px]+Pass Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (0) should be [200px]+Pass Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (0.75) should be [87.5px]+Pass Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (1) should be [50px]+Pass Web Animations: property <width> from [stretch] to [calc-size(50px, size)] at (1.25) should be [12.5px]Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [auto] to [calc-size(fit-content, size)] at (-0.3) should be [auto]Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [auto] to [calc-size(fit-content, size)] at (0) should be [auto]Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [auto] to [calc-size(fit-content, size)] at (0.3) should be [auto]@@ -572,90 +571,90 @@ Pass Web Animations: property <width> from [fit-content] to [calc-size(min-contePass Web Animations: property <width> from [fit-content] to [calc-size(min-content, size)] at (0.6) should be [calc-size(min-content, size)]Pass Web Animations: property <width> from [fit-content] to [calc-size(min-content, size)] at (1) should be [calc-size(min-content, size)]Pass Web Animations: property <width> from [fit-content] to [calc-size(min-content, size)] at (1.5) should be [calc-size(min-content, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [calc-size(auto, size)]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [calc-size(auto, size)]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [calc-size(auto, size)]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]-Fail Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]-Fail Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]-Fail Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]-Fail CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]-Fail CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]-Fail CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]-Fail Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]-Fail Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]-Fail Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]-Fail Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]-Fail Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]-Fail Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]-Fail Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [calc-size(auto, size)]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [calc-size(auto, size)]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [calc-size(auto, size)]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Transitions: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass CSS Animations: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (-0.3) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.3) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.5) should be [calc-size(auto, size)]+Pass Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (0.6) should be [calc-size(auto, size)]+Pass Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (1) should be [calc-size(auto, size)]+Pass Web Animations: property <width> from [stretch] to [calc-size(auto, size)] at (1.5) should be [calc-size(auto, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Transitions: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Transitions with transition: all: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]+Pass CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]+Pass CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]+Pass CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass CSS Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]+Pass Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (-0.3) should be [max-content]+Pass Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0) should be [max-content]+Pass Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.3) should be [max-content]+Pass Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.5) should be [calc-size(stretch, size)]+Pass Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (0.6) should be [calc-size(stretch, size)]+Pass Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (1) should be [calc-size(stretch, size)]+Pass Web Animations: property <width> from [max-content] to [calc-size(stretch, size)] at (1.5) should be [calc-size(stretch, size)]Pass CSS Transitions: property <width> from [calc-size(20px, size)] to [calc-size(60px, size)] at (-0.25) should be [10px]Pass CSS Transitions: property <width> from [calc-size(20px, size)] to [calc-size(60px, size)] at (0) should be [20px]Pass CSS Transitions: property <width> from [calc-size(20px, size)] to [calc-size(60px, size)] at (0.75) should be [50px]diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-height-interpolation.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-height-interpolation.txtindex 7f2b41c46fd..2af574e643f 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-height-interpolation.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-height-interpolation.txt@@ -2,8 +2,7 @@ Harness status: OKFound 318 tests-276 Pass-42 Fail+318 PassPass CSS Transitions: property <height> from [initial] to [90px] at (-0.3) should be [38px]Pass CSS Transitions: property <height> from [initial] to [90px] at (0) should be [50px]Pass CSS Transitions: property <height> from [initial] to [90px] at (0.3) should be [62px]@@ -232,48 +231,48 @@ Pass Web Animations: property <height> from [max-content] to [fit-content] at (0Pass Web Animations: property <height> from [max-content] to [fit-content] at (0.6) should be [fit-content]Pass Web Animations: property <height> from [max-content] to [fit-content] at (1) should be [fit-content]Pass Web Animations: property <height> from [max-content] to [fit-content] at (1.5) should be [fit-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (-0.3) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (0) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (0.3) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (-0.3) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (0) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (0.3) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail CSS Transitions: property <height> from [max-content] to [stretch] at (-0.3) should be [stretch]-Fail CSS Transitions: property <height> from [max-content] to [stretch] at (0) should be [stretch]-Fail CSS Transitions: property <height> from [max-content] to [stretch] at (0.3) should be [stretch]-Fail CSS Transitions: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Transitions: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Transitions: property <height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Transitions: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (-0.3) should be [stretch]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (0) should be [stretch]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (0.3) should be [stretch]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail CSS Animations: property <height> from [max-content] to [stretch] at (-0.3) should be [max-content]-Fail CSS Animations: property <height> from [max-content] to [stretch] at (0) should be [max-content]-Fail CSS Animations: property <height> from [max-content] to [stretch] at (0.3) should be [max-content]-Fail CSS Animations: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Animations: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Animations: property <height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Animations: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail Web Animations: property <height> from [max-content] to [stretch] at (-0.3) should be [max-content]-Fail Web Animations: property <height> from [max-content] to [stretch] at (0) should be [max-content]-Fail Web Animations: property <height> from [max-content] to [stretch] at (0.3) should be [max-content]-Fail Web Animations: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail Web Animations: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail Web Animations: property <height> from [max-content] to [stretch] at (1) should be [stretch]-Fail Web Animations: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (-0.3) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (0) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (0.3) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (-0.3) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (0) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (0.3) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Transitions: property <height> from [max-content] to [stretch] at (-0.3) should be [stretch]+Pass CSS Transitions: property <height> from [max-content] to [stretch] at (0) should be [stretch]+Pass CSS Transitions: property <height> from [max-content] to [stretch] at (0.3) should be [stretch]+Pass CSS Transitions: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Transitions: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Transitions: property <height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Transitions: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (-0.3) should be [stretch]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (0) should be [stretch]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (0.3) should be [stretch]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Transitions with transition: all: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Animations: property <height> from [max-content] to [stretch] at (-0.3) should be [max-content]+Pass CSS Animations: property <height> from [max-content] to [stretch] at (0) should be [max-content]+Pass CSS Animations: property <height> from [max-content] to [stretch] at (0.3) should be [max-content]+Pass CSS Animations: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Animations: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Animations: property <height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Animations: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass Web Animations: property <height> from [max-content] to [stretch] at (-0.3) should be [max-content]+Pass Web Animations: property <height> from [max-content] to [stretch] at (0) should be [max-content]+Pass Web Animations: property <height> from [max-content] to [stretch] at (0.3) should be [max-content]+Pass Web Animations: property <height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass Web Animations: property <height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass Web Animations: property <height> from [max-content] to [stretch] at (1) should be [stretch]+Pass Web Animations: property <height> from [max-content] to [stretch] at (1.5) should be [stretch]Pass CSS Transitions: property <height> from [max-content] to neutral at (-0.3) should be [20px]Pass CSS Transitions: property <height> from [max-content] to neutral at (0) should be [50px]Pass CSS Transitions: property <height> from [max-content] to neutral at (0.3) should be [80px]diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-max-width-interpolation.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-max-width-interpolation.txtindex 6050d1d18e9..d2d6209574f 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-max-width-interpolation.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-max-width-interpolation.txt@@ -2,8 +2,7 @@ Harness status: OKFound 282 tests-240 Pass-42 Fail+282 PassPass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [initial] to [20px] at (-0.3) should be [initial]Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [initial] to [20px] at (0) should be [initial]Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [initial] to [20px] at (0.3) should be [initial]@@ -130,48 +129,48 @@ Pass Web Animations: property <max-width> from [none] to [20px] at (0.5) shouldPass Web Animations: property <max-width> from [none] to [20px] at (0.6) should be [20px]Pass Web Animations: property <max-width> from [none] to [20px] at (1) should be [20px]Pass Web Animations: property <max-width> from [none] to [20px] at (1.5) should be [20px]-Fail CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (0) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (0.5) should be [none]-Fail CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (0.6) should be [none]-Fail CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (1) should be [none]-Fail CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (1.5) should be [none]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (0) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (0.5) should be [none]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (0.6) should be [none]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (1) should be [none]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (1.5) should be [none]-Fail CSS Transitions: property <max-width> from [stretch] to [none] at (-0.3) should be [none]-Fail CSS Transitions: property <max-width> from [stretch] to [none] at (0) should be [none]-Fail CSS Transitions: property <max-width> from [stretch] to [none] at (0.3) should be [none]-Fail CSS Transitions: property <max-width> from [stretch] to [none] at (0.5) should be [none]-Fail CSS Transitions: property <max-width> from [stretch] to [none] at (0.6) should be [none]-Fail CSS Transitions: property <max-width> from [stretch] to [none] at (1) should be [none]-Fail CSS Transitions: property <max-width> from [stretch] to [none] at (1.5) should be [none]-Fail CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (-0.3) should be [none]-Fail CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (0) should be [none]-Fail CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (0.3) should be [none]-Fail CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (0.5) should be [none]-Fail CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (0.6) should be [none]-Fail CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (1) should be [none]-Fail CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (1.5) should be [none]-Fail CSS Animations: property <max-width> from [stretch] to [none] at (-0.3) should be [stretch]-Fail CSS Animations: property <max-width> from [stretch] to [none] at (0) should be [stretch]-Fail CSS Animations: property <max-width> from [stretch] to [none] at (0.3) should be [stretch]-Fail CSS Animations: property <max-width> from [stretch] to [none] at (0.5) should be [none]-Fail CSS Animations: property <max-width> from [stretch] to [none] at (0.6) should be [none]-Fail CSS Animations: property <max-width> from [stretch] to [none] at (1) should be [none]-Fail CSS Animations: property <max-width> from [stretch] to [none] at (1.5) should be [none]-Fail Web Animations: property <max-width> from [stretch] to [none] at (-0.3) should be [stretch]-Fail Web Animations: property <max-width> from [stretch] to [none] at (0) should be [stretch]-Fail Web Animations: property <max-width> from [stretch] to [none] at (0.3) should be [stretch]-Fail Web Animations: property <max-width> from [stretch] to [none] at (0.5) should be [none]-Fail Web Animations: property <max-width> from [stretch] to [none] at (0.6) should be [none]-Fail Web Animations: property <max-width> from [stretch] to [none] at (1) should be [none]-Fail Web Animations: property <max-width> from [stretch] to [none] at (1.5) should be [none]+Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (0) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (0.5) should be [none]+Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (0.6) should be [none]+Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (1) should be [none]+Pass CSS Transitions with transition-behavior:allow-discrete: property <max-width> from [stretch] to [none] at (1.5) should be [none]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (0) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (0.5) should be [none]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (0.6) should be [none]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (1) should be [none]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <max-width> from [stretch] to [none] at (1.5) should be [none]+Pass CSS Transitions: property <max-width> from [stretch] to [none] at (-0.3) should be [none]+Pass CSS Transitions: property <max-width> from [stretch] to [none] at (0) should be [none]+Pass CSS Transitions: property <max-width> from [stretch] to [none] at (0.3) should be [none]+Pass CSS Transitions: property <max-width> from [stretch] to [none] at (0.5) should be [none]+Pass CSS Transitions: property <max-width> from [stretch] to [none] at (0.6) should be [none]+Pass CSS Transitions: property <max-width> from [stretch] to [none] at (1) should be [none]+Pass CSS Transitions: property <max-width> from [stretch] to [none] at (1.5) should be [none]+Pass CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (-0.3) should be [none]+Pass CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (0) should be [none]+Pass CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (0.3) should be [none]+Pass CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (0.5) should be [none]+Pass CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (0.6) should be [none]+Pass CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (1) should be [none]+Pass CSS Transitions with transition: all: property <max-width> from [stretch] to [none] at (1.5) should be [none]+Pass CSS Animations: property <max-width> from [stretch] to [none] at (-0.3) should be [stretch]+Pass CSS Animations: property <max-width> from [stretch] to [none] at (0) should be [stretch]+Pass CSS Animations: property <max-width> from [stretch] to [none] at (0.3) should be [stretch]+Pass CSS Animations: property <max-width> from [stretch] to [none] at (0.5) should be [none]+Pass CSS Animations: property <max-width> from [stretch] to [none] at (0.6) should be [none]+Pass CSS Animations: property <max-width> from [stretch] to [none] at (1) should be [none]+Pass CSS Animations: property <max-width> from [stretch] to [none] at (1.5) should be [none]+Pass Web Animations: property <max-width> from [stretch] to [none] at (-0.3) should be [stretch]+Pass Web Animations: property <max-width> from [stretch] to [none] at (0) should be [stretch]+Pass Web Animations: property <max-width> from [stretch] to [none] at (0.3) should be [stretch]+Pass Web Animations: property <max-width> from [stretch] to [none] at (0.5) should be [none]+Pass Web Animations: property <max-width> from [stretch] to [none] at (0.6) should be [none]+Pass Web Animations: property <max-width> from [stretch] to [none] at (1) should be [none]+Pass Web Animations: property <max-width> from [stretch] to [none] at (1.5) should be [none]Pass CSS Transitions: property <max-width> from [fit-content] to [50px] at (-0.3) should be [calc-size(fit-content, -15px + size * 1.3)]Pass CSS Transitions: property <max-width> from [fit-content] to [50px] at (0) should be [calc-size(fit-content, 0px + size * 1)]Pass CSS Transitions: property <max-width> from [fit-content] to [50px] at (0.3) should be [calc-size(fit-content, 15px + size * 0.7)]diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-min-height-interpolation.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-min-height-interpolation.txtindex dd37b3f4095..90b7fd1f0a5 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-min-height-interpolation.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-min-height-interpolation.txt@@ -2,8 +2,7 @@ Harness status: OKFound 228 tests-186 Pass-42 Fail+228 PassPass CSS Transitions: property <min-height> from [initial] to [20px] at (-0.3) should be [calc-size(auto, -6px + size * 1.3)]Pass CSS Transitions: property <min-height> from [initial] to [20px] at (0) should be [calc-size(auto, 0px + size * 1)]Pass CSS Transitions: property <min-height> from [initial] to [20px] at (0.3) should be [calc-size(auto, 6px + size * 0.7)]@@ -142,48 +141,48 @@ Pass Web Animations: property <min-height> from [fit-content] to [min-content] aPass Web Animations: property <min-height> from [fit-content] to [min-content] at (0.6) should be [min-content]Pass Web Animations: property <min-height> from [fit-content] to [min-content] at (1) should be [min-content]Pass Web Animations: property <min-height> from [fit-content] to [min-content] at (1.5) should be [min-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (-0.3) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (0) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.3) should be [max-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (-0.3) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (0) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.3) should be [max-content]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail CSS Transitions: property <min-height> from [max-content] to [stretch] at (-0.3) should be [stretch]-Fail CSS Transitions: property <min-height> from [max-content] to [stretch] at (0) should be [stretch]-Fail CSS Transitions: property <min-height> from [max-content] to [stretch] at (0.3) should be [stretch]-Fail CSS Transitions: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Transitions: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Transitions: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Transitions: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (-0.3) should be [stretch]-Fail CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (0) should be [stretch]-Fail CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (0.3) should be [stretch]-Fail CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail CSS Animations: property <min-height> from [max-content] to [stretch] at (-0.3) should be [max-content]-Fail CSS Animations: property <min-height> from [max-content] to [stretch] at (0) should be [max-content]-Fail CSS Animations: property <min-height> from [max-content] to [stretch] at (0.3) should be [max-content]-Fail CSS Animations: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail CSS Animations: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail CSS Animations: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]-Fail CSS Animations: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]-Fail Web Animations: property <min-height> from [max-content] to [stretch] at (-0.3) should be [max-content]-Fail Web Animations: property <min-height> from [max-content] to [stretch] at (0) should be [max-content]-Fail Web Animations: property <min-height> from [max-content] to [stretch] at (0.3) should be [max-content]-Fail Web Animations: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]-Fail Web Animations: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]-Fail Web Animations: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]-Fail Web Animations: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (-0.3) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (0) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.3) should be [max-content]+Pass CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (-0.3) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (0) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.3) should be [max-content]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Transitions: property <min-height> from [max-content] to [stretch] at (-0.3) should be [stretch]+Pass CSS Transitions: property <min-height> from [max-content] to [stretch] at (0) should be [stretch]+Pass CSS Transitions: property <min-height> from [max-content] to [stretch] at (0.3) should be [stretch]+Pass CSS Transitions: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Transitions: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Transitions: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Transitions: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (-0.3) should be [stretch]+Pass CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (0) should be [stretch]+Pass CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (0.3) should be [stretch]+Pass CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Transitions with transition: all: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass CSS Animations: property <min-height> from [max-content] to [stretch] at (-0.3) should be [max-content]+Pass CSS Animations: property <min-height> from [max-content] to [stretch] at (0) should be [max-content]+Pass CSS Animations: property <min-height> from [max-content] to [stretch] at (0.3) should be [max-content]+Pass CSS Animations: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass CSS Animations: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass CSS Animations: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]+Pass CSS Animations: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]+Pass Web Animations: property <min-height> from [max-content] to [stretch] at (-0.3) should be [max-content]+Pass Web Animations: property <min-height> from [max-content] to [stretch] at (0) should be [max-content]+Pass Web Animations: property <min-height> from [max-content] to [stretch] at (0.3) should be [max-content]+Pass Web Animations: property <min-height> from [max-content] to [stretch] at (0.5) should be [stretch]+Pass Web Animations: property <min-height> from [max-content] to [stretch] at (0.6) should be [stretch]+Pass Web Animations: property <min-height> from [max-content] to [stretch] at (1) should be [stretch]+Pass Web Animations: property <min-height> from [max-content] to [stretch] at (1.5) should be [stretch]Pass CSS Transitions: property <min-height> from [fit-content] to neutral at (-0.3) should be [calc-size(fit-content, -3px + size * 1.3)]Pass CSS Transitions: property <min-height> from [fit-content] to neutral at (0) should be [calc-size(fit-content, 0px + size * 1)]Pass CSS Transitions: property <min-height> from [fit-content] to neutral at (0.3) should be [calc-size(fit-content, 3px + size * 0.7)]diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-width-interpolation.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-width-interpolation.txtindex 91cf0a85459..6685f1bfbf4 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-width-interpolation.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/animation/interpolate-size-width-interpolation.txt@@ -2,8 +2,7 @@ Harness status: OKFound 270 tests-228 Pass-42 Fail+270 PassPass CSS Transitions: property <width> from [initial] to [50px] at (-0.3) should be [180px]Pass CSS Transitions: property <width> from [initial] to [50px] at (0) should be [150px]Pass CSS Transitions: property <width> from [initial] to [50px] at (0.3) should be [120px]@@ -118,48 +117,48 @@ Pass Web Animations: property <width> from [auto] to [fit-content] at (0.5) shouPass Web Animations: property <width> from [auto] to [fit-content] at (0.6) should be [fit-content]Pass Web Animations: property <width> from [auto] to [fit-content] at (1) should be [fit-content]Pass Web Animations: property <width> from [auto] to [fit-content] at (1.5) should be [fit-content]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.3) should be [stretch]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.3) should be [stretch]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (-0.3) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (0) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (0.3) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Transitions: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (-0.3) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.3) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail CSS Animations: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [auto] at (0) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [auto] at (0.3) should be [stretch]-Fail CSS Animations: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail CSS Animations: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail CSS Animations: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail CSS Animations: property <width> from [stretch] to [auto] at (1.5) should be [auto]-Fail Web Animations: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [auto] at (0) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [auto] at (0.3) should be [stretch]-Fail Web Animations: property <width> from [stretch] to [auto] at (0.5) should be [auto]-Fail Web Animations: property <width> from [stretch] to [auto] at (0.6) should be [auto]-Fail Web Animations: property <width> from [stretch] to [auto] at (1) should be [auto]-Fail Web Animations: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.3) should be [stretch]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Transitions with transition-behavior:allow-discrete: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.3) should be [stretch]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Transitions with transition-property:all and transition-behavor:allow-discrete: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (-0.3) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (0) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (0.3) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Transitions: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (-0.3) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.3) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Transitions with transition: all: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass CSS Animations: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [auto] at (0) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [auto] at (0.3) should be [stretch]+Pass CSS Animations: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass CSS Animations: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass CSS Animations: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass CSS Animations: property <width> from [stretch] to [auto] at (1.5) should be [auto]+Pass Web Animations: property <width> from [stretch] to [auto] at (-0.3) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [auto] at (0) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [auto] at (0.3) should be [stretch]+Pass Web Animations: property <width> from [stretch] to [auto] at (0.5) should be [auto]+Pass Web Animations: property <width> from [stretch] to [auto] at (0.6) should be [auto]+Pass Web Animations: property <width> from [stretch] to [auto] at (1) should be [auto]+Pass Web Animations: property <width> from [stretch] to [auto] at (1.5) should be [auto]Pass CSS Transitions: property <width> from [200px] to [fit-content] at (-0.3) should be [230px]Pass CSS Transitions: property <width> from [200px] to [fit-content] at (0) should be [200px]Pass CSS Transitions: property <width> from [200px] to [fit-content] at (0.3) should be [170px]diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-flex-basis-on-column.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-flex-basis-on-column.txtindex 287f2ee8b63..9e2a2608a11 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-flex-basis-on-column.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-flex-basis-on-column.txt@@ -2,8 +2,7 @@ Harness status: OKFound 33 tests-32 Pass-1 Fail+33 PassPass resolved value for height resulting from flex-basis: 274pxPass resolved value for height resulting from flex-basis: min-contentPass resolved value for height resulting from flex-basis: fit-content@@ -19,7 +18,7 @@ Pass resolved value for height resulting from flex-basis: calc-size(83px, size *Pass resolved value for height resulting from flex-basis: calc-size(min-content, size / 0.25)Pass resolved value for height resulting from flex-basis: calc-size(max-content, size * 5.2)Pass resolved value for height resulting from flex-basis: calc-size(fit-content, size / 4 + 60px)-Fail resolved value for height resulting from flex-basis: calc-size(stretch, size * 2 - 10%)+Pass resolved value for height resulting from flex-basis: calc-size(stretch, size * 2 - 10%)Pass resolved value for height resulting from flex-basis: calc-size(30px, 15em)Pass resolved value for height resulting from flex-basis: calc-size(calc-size(any, 30px), 15em)Pass resolved value for height resulting from flex-basis: calc-size(calc-size(2in, 30px), 15em)diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-flex-basis-on-row.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-flex-basis-on-row.txtindex 6d4ad1015a0..fad2e171940 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-flex-basis-on-row.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-flex-basis-on-row.txt@@ -2,8 +2,7 @@ Harness status: OKFound 33 tests-32 Pass-1 Fail+33 PassPass resolved value for width resulting from flex-basis: 274pxPass resolved value for width resulting from flex-basis: min-contentPass resolved value for width resulting from flex-basis: fit-content@@ -19,7 +18,7 @@ Pass resolved value for width resulting from flex-basis: calc-size(83px, size *Pass resolved value for width resulting from flex-basis: calc-size(min-content, size / 2)Pass resolved value for width resulting from flex-basis: calc-size(max-content, size * 1.2)Pass resolved value for width resulting from flex-basis: calc-size(fit-content, size / 4 + 30px)-Fail resolved value for width resulting from flex-basis: calc-size(stretch, size / 2 - 10%)+Pass resolved value for width resulting from flex-basis: calc-size(stretch, size / 2 - 10%)Pass resolved value for width resulting from flex-basis: calc-size(30px, 15em)Pass resolved value for width resulting from flex-basis: calc-size(calc-size(any, 30px), 15em)Pass resolved value for width resulting from flex-basis: calc-size(calc-size(2in, 30px), 15em)diff --git a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-width.txt b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-width.txtindex 1d355125c0d..023726e7942 100644--- a/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-width.txt+++ b/Tests/LibWeb/Text/expected/wpt-import/css/css-values/calc-size/calc-size-width.txt@@ -2,8 +2,7 @@ Harness status: OKFound 20 tests-19 Pass-1 Fail+20 PassPass resolved width for width: calc-size(any, 357px)Pass resolved width for width: calc-size(any, 31%)Pass resolved width for width: calc-size(max-content, 31%)@@ -13,7 +12,7 @@ Pass resolved width for width: calc-size(83px, size * 3)Pass resolved width for width: calc-size(min-content, size / 2)Pass resolved width for width: calc-size(max-content, size * 1.2)Pass resolved width for width: calc-size(fit-content, size / 4 + 30px)-Fail resolved width for width: calc-size(stretch, size / 2 - 10%)+Pass resolved width for width: calc-size(stretch, size / 2 - 10%)Pass resolved width for width: calc-size(30px, 15em)Pass resolved width for width: calc-size(calc-size(any, 30px), 15em)Pass resolved width for width: calc-size(calc-size(2in, 30px), 15em)diff --git a/Tests/LibWeb/Text/input/css/calc-size-stretch-basis-on-flex-items.html b/Tests/LibWeb/Text/input/css/calc-size-stretch-basis-on-flex-items.htmlnew file mode 100644index 00000000000..214014660b2--- /dev/null+++ b/Tests/LibWeb/Text/input/css/calc-size-stretch-basis-on-flex-items.html@@ -0,0 +1,10 @@+<!DOCTYPE html>+<script src="../include.js"></script>+<div style="display: flex; width: 300px"><div id="a" style="flex: 0 0 calc-size(stretch, size / 2); height: 10px"></div></div>+<div style="display: flex; width: 300px"><div id="b" style="flex: 0 0 auto; width: calc-size(stretch, size / 2); height: 10px"></div></div>+<script>+test(() => {+ println(`calc-size() flex-basis with a stretch basis: ${document.getElementById("a").offsetWidth}`);+ println(`calc-size() width with a stretch basis: ${document.getElementById("b").offsetWidth}`);+});+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/aspect-ratio-1.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/aspect-ratio-1.htmlnew file mode 100644index 00000000000..518cc0458a2--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/aspect-ratio-1.html@@ -0,0 +1,53 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="stretch keyword works in the presence of aspect-ratio">++<style>+ p {+ margin-bottom: 4px;+ }++ .grandchild {+ width: 30px;+ height: 40px;+ }+</style>++<body onload="checkLayout('p + div > div')">++ <p>basic stretch into definite width</p>+ <div style="width: 100px;">+ <div style="outline: 5px solid; aspect-ratio: 2 / 1; width: stretch;"+ data-expected-height="50">+ <div class="grandchild"></div>+ </div>+ </div>++ <p>basic stretch into definite height</p>+ <div style="height: 100px;">+ <div style="outline: 5px solid; aspect-ratio: 2 / 1; height: stretch;"+ data-expected-width="200">+ <div class="grandchild"></div>+ </div>+ </div>++ <p>indefinite height stretch is ignored</p>+ <div style="width: 100px;">+ <div style="outline: 5px solid; aspect-ratio: 2 / 1; height: stretch;"+ data-expected-height="50">+ <div class="grandchild"></div>+ </div>+ </div>++ <p>indefinite min-height stretch is ignored</p>+ <div style="width: 100px;">+ <div style="outline: 5px solid; aspect-ratio: 2 / 1; min-height: stretch;"+ data-expected-height="50">+ <div class="grandchild"></div>+ </div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/aspect-ratio-2.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/aspect-ratio-2.htmlnew file mode 100644index 00000000000..6868f4a53ae--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/aspect-ratio-2.html@@ -0,0 +1,166 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="stretch keyword works as a block-size for replaced elements with intrinsic-size keyword for inline-size (which in turn depends on the stretched block-size)">+<style>+.container {+ width: 20px;+ height: 20px;+ margin: 5px;+ border: 1px solid black;+}+canvas {+ height: -webkit-fill-available;+ height: stretch;+ background: purple;+}++.withBorder {+ border: 2px solid cyan;+ border-width: 2px 3px 4px 5px;+}+.withPadding {+ padding: 2px 3px 4px 5px;+}+.withPxMargin {+ margin: 1px 2px 3px 4px;+}+.withPctMargin {+ /* This works out to 1px 2px 3px 4px */+ margin: 5% 10% 15% 20%;+}+</style>+<body onload="checkLayout('canvas')">+ <!-- Simplest cases - replaced element with stretched block-size and+ intrinsic inline-size: -->+ <div class="container">+ <canvas width="30" height="60"+ data-expected-width="10"+ data-expected-height="20"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ style="width: 1px; min-width: fit-content"+ data-expected-width="10"+ data-expected-height="20"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ style="width: 100px; max-width: fit-content"+ data-expected-width="10"+ data-expected-height="20"></canvas>+ </div>++ <!-- Now without any block-size on the containing block (this makes+ the canvas's bsize be treated as "auto", so it just takes on its+ regular intrinsic size in both axes): -->+ <div class="container" style="height: auto">+ <canvas width="30" height="60"+ data-expected-width="30"+ data-expected-height="60"></canvas>+ </div>+ <div class="container" style="height: auto">+ <canvas width="30" height="60"+ style="width: 1px; min-width: fit-content"+ data-expected-width="30"+ data-expected-height="60"></canvas>+ </div>+ <div class="container" style="height: auto">+ <canvas width="30" height="60"+ style="width: 100px; max-width: fit-content"+ data-expected-width="30"+ data-expected-height="60"></canvas>+ </div>++ <!-- Now with pixel-valued border: -->+ <div class="container">+ <canvas width="30" height="60"+ class="withBorder"+ data-expected-width="15"+ data-expected-height="20"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ class="withBorder"+ style="width: 1px; min-width: fit-content"+ data-expected-width="15"+ data-expected-height="20"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ class="withBorder"+ style="width: 100px; max-width: fit-content"+ data-expected-width="15"+ data-expected-height="20"></canvas>+ </div>++ <!-- Now with pixel-valued padding: -->+ <div class="container">+ <canvas width="30" height="60"+ class="withPadding"+ data-expected-width="15"+ data-expected-height="20"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ class="withPadding"+ style="width: 1px; min-width: fit-content"+ data-expected-width="15"+ data-expected-height="20"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ class="withPadding"+ style="width: 100px; max-width: fit-content"+ data-expected-width="15"+ data-expected-height="20"></canvas>+ </div>++ <!-- Now with a pixel-valued margin: -->+ <div class="container">+ <canvas width="30" height="60"+ class="withPxMargin"+ data-expected-width="8"+ data-expected-height="16"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ class="withPxMargin"+ style="width: 1px; min-width: fit-content"+ data-expected-width="8"+ data-expected-height="16"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ class="withPxMargin"+ style="width: 100px; max-width: fit-content"+ data-expected-width="8"+ data-expected-height="16"></canvas>+ </div>++ <!-- Now with a percent-valued margin: -->+ <div class="container">+ <canvas width="30" height="60"+ class="withPctMargin"+ data-expected-width="8"+ data-expected-height="16"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ class="withPctMargin"+ style="width: 1px; min-width: fit-content"+ data-expected-width="8"+ data-expected-height="16"></canvas>+ </div>+ <div class="container">+ <canvas width="30" height="60"+ class="withPctMargin"+ style="width: 100px; max-width: fit-content"+ data-expected-width="8"+ data-expected-height="16"></canvas>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/auto-margins-1.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/auto-margins-1.htmlnew file mode 100644index 00000000000..33b379f263c--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/auto-margins-1.html@@ -0,0 +1,21 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="auto margins are treated as 0 in basic horizontal centering cases">++<body onload="checkLayout('[data-expected-width]')">++ <div style="width: 100px; position: relative; border: solid">+ <div style="margin: 0 auto; width: stretch; background: lime;"+ data-expected-width="100" data-offset-x="0">lorem</div>+ </div>++ <div style="width: 100px; position: relative; border: solid">+ <div+ style="margin: 0 auto; min-width: stretch; width: 25px; background: lime;"+ data-expected-width="100" data-offset-x="0">lorem</div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/auto-margins-2.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/auto-margins-2.htmlnew file mode 100644index 00000000000..49066fbca23--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/auto-margins-2.html@@ -0,0 +1,56 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="auto margins are treated as 0 in stretched abspos boxes">++<style>+ .outer {+ width: 200px;+ height: 200px;+ position: relative;+ border: solid;+ }++ .outer>div {+ position: absolute;+ margin: auto;+ background: lime;+ }+</style>++<body onload="checkLayout('.outer>div')">++ <div class="outer">+ <div style="inset: 0; width: stretch; height: 100px;"+ data-expected-width="200" data-offset-x="0"></div>+ </div>++ <div class="outer">+ <div style="inset: 0; max-width: stretch; height: 100px;"+ data-expected-width="200" data-offset-x="0"></div>+ </div>++ <div class="outer">+ <div style="inset: 0; height: stretch; width: 100px;"+ data-expected-height="200" data-offset-y="0"></div>+ </div>++ <div class="outer">+ <div style="inset: 0; max-height: stretch; width: 100px;"+ data-expected-height="200" data-offset-y="0"></div>+ </div>++ <div class="outer">+ <div style="top: 0; bottom: 0; left: 25px; right: 25px; width: stretch;"+ data-expected-width="150" data-offset-x="25"></div>+ </div>++ <div class="outer">+ <div+ style="top: 25px; bottom: 25px; left: 0px; right: 0px; height: stretch;"+ data-expected-height="150" data-offset-y="25"></div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-001.htmlnew file mode 100644index 00000000000..c6c546bc4f1--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-001.html@@ -0,0 +1,128 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-3/#propdef-width">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert" content="Checks the behaviour of stretch in various configurations.">+<style>+.content {+ width: 20px;+ height: 20px;+ background: lime;+}+.tall-content {+ width: 20px;+ height: 120px;+ background: lime;+}+</style>+<body onload="checkLayout('[data-expected-height]')">++<div style="height: 100px;">+ <div data-expected-height=100 style="display: block; height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100px;">+ <div data-expected-height=100 style="display: flex; height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100px;">+ <div data-expected-height=100 style="display: grid; height: stretch;">+ <div class=content></div>+ </div>+</div>++<!-- As the height of the container is indefinite, stretch is treated as auto. -->+<div style="height: 100%;">+ <div data-expected-height=20 style="display: block; height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100%;">+ <div data-expected-height=20 style="display: flex; height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100%;">+ <div data-expected-height=20 style="display: grid; height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100px;">+ <div data-expected-height=100 style="display: block; min-height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100px;">+ <div data-expected-height=100 style="display: flex; min-height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100px;">+ <div data-expected-height=100 style="display: grid; min-height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100%;">+ <div data-expected-height=20 style="display: block; min-height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100%;">+ <div data-expected-height=20 style="display: flex; min-height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100%;">+ <div data-expected-height=20 style="display: grid; min-height: stretch;">+ <div class=content></div>+ </div>+</div>++<div style="height: 100px;">+ <div data-expected-height=100 style="display: block; max-height: stretch;">+ <div class=tall-content></div>+ </div>+</div>++<div style="height: 100px;">+ <div data-expected-height=100 style="display: flex; max-height: stretch;">+ <div class=tall-content></div>+ </div>+</div>++<div style="height: 100px;">+ <div data-expected-height=100 style="display: grid; max-height: stretch;">+ <div class=tall-content></div>+ </div>+</div>++<div style="height: 100%;">+ <div data-expected-height=120 style="display: block; max-height: stretch;">+ <div class=tall-content></div>+ </div>+</div>++<div style="height: 100%;">+ <div data-expected-height=120 style="display: flex; max-height: stretch;">+ <div class=tall-content></div>+ </div>+</div>++<div style="height: 100%;">+ <div data-expected-height=120 style="display: grid; max-height: stretch;">+ <div class=tall-content></div>+ </div>+</div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-002.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-002.htmlnew file mode 100644index 00000000000..38614ee736c--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-002.html@@ -0,0 +1,61 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#example-174ae518">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<link rel="stylesheet" type="text/css" href="../../../fonts/ahem.css" />+<meta name="assert"+ content="the stretch examples in the spec are rendered correctly">++<style>+ main {+ font: 20px/1 Ahem;+ }+</style>+<p>These tests assert the behavior described at+ https://github.com/w3c/csswg-drafts/issues/11044#issuecomment-2599101601+</p>++<main>+ <!-- Example 9+[T]he outer height of the inner box will exactly match the height of the outer box (200px), but its inner height will be 20px less, to account for its margins.+-->+<div style="height: 200px; border: solid;">+ <div style="height: stretch; margin: 10px;" data-expected-height="180"></div>+</div>++<!-- Example 9, second case+In the following case, the height of the inner box will exactly match the height of the outer box (200px).+-->+<div style="height: 200px; margin: 0;">+ <div style="height: stretch; margin: 10px;" data-expected-height="200"></div>+</div>++<!-- Example 10+Similarly, width: stretch causes the box to fill its container, being 20px narrower than the width of "some more text" (due to the 10px margin)+-->+<div style="float: left; margin: 0; outline: solid;">+ <div style="width: stretch; margin: 10px; background: skyblue;"+ data-expected-width="260">+ text+ </div>+ <span>some more text</span>+</div>++<div style="clear: both;"></div>++<!-- Example 11+On the other hand, in this example the container’s height is indefinite, which would cause a percentage height on the child to behave as auto, so height: stretch behaves as auto as well.+-->+<div style="height: auto; margin: 0; background: orange;">+ lorem ipsum<br>+ cats+ <div style="height: stretch; margin: 10px; background: lime;"+ data-expected-height="20">dogs</div>+</div>++</main>++<script>+ document.fonts.ready.then(() => checkLayout("main > div > div"));+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-004.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-004.htmlnew file mode 100644index 00000000000..af48d1b8d1f--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-004.html@@ -0,0 +1,94 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11044">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="margins of the stretched element are accounted for correctly in a variety of scenarios, mostly around siblings">++<style>+ .outer {+ width: 100px;+ height: 100px;+ outline: solid;+ position: relative;+ }++ .inner {+ height: stretch;+ margin: 10px;+ }+</style>++<h2>These tests assert the behavior described at+ https://github.com/w3c/csswg-drafts/issues/11044#issuecomment-2599101601+</h2>++<p>Basic case: treat margins as 0.</p>+<div class="outer">+ <div class="inner" style="border: solid magenta;" data-expected-height="100"+ data-offset-y="0">+ </div>+</div>++<p>+ When resolving stretch treat both block margins as 0 because the parent is+ not a BFC and has no top or bottom content edge (i.e. border + padding = 0).+ <br>But cyan's margins will not actually collapse through its IFC-siblings so+ there is overflow:+</p>+<div class="outer">+ <div style="overflow: hidden"></div>+ <div class="inner" style="border: solid cyan;" data-expected-height="100"+ data-offset-y="10">+ </div>+ <div style="overflow: hidden"></div>+</div>++<div class="outer">+ <div></div>+ <div class="inner" style="border: solid blue;" data-expected-height="100"+ data-offset-y="0">+ </div>+ <div></div>+</div>++<div class="outer">+ <div></div>+ <div class="inner" style="border: solid purple;" data-expected-height="100"+ data-offset-y="0">+ </div>+</div>++<div class="outer">+ <div class="inner" style="border: solid lime;" data-expected-height="100"+ data-offset-y="0">+ </div>+ <div></div>+</div>++<p>Parent has non-zero bottom border, so only top margin is treated as 0:</p>+<div class="outer" style="border-bottom: 5px dashed blue;">+ <div class="inner" style="border: solid brown;" data-expected-height="90"+ data-offset-y="0">+ </div>+</div>++<p>Parent has non-zero top padding so only bottom margin is treated as 0:</p>+<div class="outer" style="padding-top: 5px;">+ <div class="inner" style="border: solid darkgreen;" data-expected-height="90"+ data-offset-y="15"> <!-- 15 = 10px top margin + parent's padding-->+ </div>+</div>++<p>Account for the margins when parent establishes a BFC.</p>+<div class="outer" style="display: flow-root;">+ <div class="inner" style="border: solid orange;" data-expected-height="80"+ data-offset-y="10">+ </div>+ <div></div>+</div>++<script>checkLayout(".inner");</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-005.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-005.htmlnew file mode 100644index 00000000000..a13fd945d56--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-005.html@@ -0,0 +1,63 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11044">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="stretch sizing treating margins as 0 isn't affected by preceding floats">++<style>+ .outer {+ width: 100px;+ height: 100px;+ outline: solid;+ position: relative;+ }++ .float {+ float: left;+ width: 30px;+ height: 30px;+ background: skyblue;+ }+</style>++<p>These tests assert the behavior described at+ https://github.com/w3c/csswg-drafts/issues/11044#issuecomment-2599101601+</p>++<div class="outer">+ <div class="float"></div>+ <div+ style="height: stretch; width: 30px; margin-top: 50px; display: flow-root; border: solid magenta;"+ data-expected-height="100" data-offset-y="0">+ </div>+</div>++<div class="outer">+ <div class="float"></div>+ <div+ style="height: stretch; width: 90px; margin-top: 50px; display: flow-root; border: solid cyan;"+ data-expected-height="100" data-offset-y="30">+ </div>+</div>++<div class="outer">+ <div class="float"></div>+ <div+ style="height: stretch; width: 90px; margin-top: 50px; border: solid green;"+ data-expected-height="100" data-offset-y="0">+ </div>+</div>++<div class="outer">+ <div class="float"></div>+ <div+ style="height: stretch; width: 90px; clear: both; margin-top: 50px; border: solid orange;"+ data-expected-height="100" data-offset-y="30">+ </div>+</div>++<script>checkLayout(".float + div")</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-007.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-007.htmlnew file mode 100644index 00000000000..cd64e5748b8--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-007.html@@ -0,0 +1,126 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<meta name="assert"+ content="margins of the stretched element are accounted for correctly in various writing mode combinations and presence of borders">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>++<style>+ .container {+ width: 50px;+ height: 50px;+ margin: 3px;+ background: magenta;+ position: relative;+ }++ .child {+ margin: 1px 3px 5px 7px;+ background: cyan;+ font-size: 10px;+ }+</style>++<div id="log"></div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="49"+ data-offset-y="1" style="width: 20px; height: stretch;">1</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="1" style="width: stretch; height: 20px;">2</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="50"+ data-offset-y="0" style="width: 20px; height: stretch;">3</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="0" style="width: stretch; height: 20px;">4</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="49"+ data-offset-y="1"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">5</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="1"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">6</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="50"+ data-offset-y="0"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">7</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="0"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">8</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="49"+ data-offset-y="1"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">9</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="1"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">10</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="50"+ data-offset-y="0"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">11</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="0"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">12</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="49"+ data-offset-y="1"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">13</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="1"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">14</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="50"+ data-offset-y="0"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">15</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="0"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">16</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="49"+ data-offset-y="1"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">17</div>+</div>+<div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="1"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">18</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="50"+ data-offset-y="0"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">19</div>+</div>+<div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="40" data-expected-height="20"+ data-offset-y="0"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">20</div>+</div>++<script>+ checkLayout('.child');+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-008.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-008.htmlnew file mode 100644index 00000000000..a295f69d409--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-008.html@@ -0,0 +1,608 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<meta name="assert"+ content="margins of the stretched element are accounted for correctly in more writing mode combinations and presence of borders">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>++<style>+ .container {+ width: 50px;+ height: 50px;+ margin: 3px;+ background: magenta;+ position: relative;+ }++ .child {+ margin: 1px 3px 5px 7px;+ background: cyan;+ font-size: 10px;+ }+</style>++<div id="log"></div>+<main id="main" style="display: flex; gap: 15px;">+ <div>vertical-rl+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: horizontal-tb; width: 20px; height: stretch;">1+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: horizontal-tb; width: stretch; height: 20px;">2+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: horizontal-tb; width: 20px; height: stretch;">3+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: horizontal-tb; width: stretch; height: 20px;">4+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">5+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">6+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">7+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">8+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">9+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">10+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">11+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">12+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">13+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">14+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">15+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">16+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">17+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">18+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">19+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">20+ </div>+ </div>+ </div>+ </div>+ <div>vertical-lr+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: horizontal-tb; width: 20px; height: stretch;">21+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: horizontal-tb; width: stretch; height: 20px;">22+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: horizontal-tb; width: 20px; height: stretch;">23+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: horizontal-tb; width: stretch; height: 20px;">24+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">25+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">26+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">27+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">28+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">29+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">30+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">31+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">32+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">33+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">34+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">35+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">36+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">37+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">38+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">39+ </div>+ </div>+ </div>+ <div style="writing-mode: vertical-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">40+ </div>+ </div>+ </div>+ </div>+ <div>sideways-rl+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: horizontal-tb; width: 20px; height: stretch;">41+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: horizontal-tb; width: stretch; height: 20px;">42+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: horizontal-tb; width: 20px; height: stretch;">43+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: horizontal-tb; width: stretch; height: 20px;">44+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">45+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">46+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">47+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">48+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">49+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">50+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">51+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">52+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">53+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">54+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">55+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">56+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">57+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">58+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">59+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-rl;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">60+ </div>+ </div>+ </div>+ </div>+ <div>sideways-lr+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: horizontal-tb; width: 20px; height: stretch;">61+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: horizontal-tb; width: stretch; height: 20px;">62+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: horizontal-tb; width: 20px; height: stretch;">63+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: horizontal-tb; width: stretch; height: 20px;">64+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">65+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">66+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-rl; width: 20px; height: stretch;">67+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: vertical-rl; width: stretch; height: 20px;">68+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">69+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">70+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: vertical-lr; width: 20px; height: stretch;">71+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: vertical-lr; width: stretch; height: 20px;">72+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">73+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">74+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-rl; width: 20px; height: stretch;">75+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: sideways-rl; width: stretch; height: 20px;">76+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">77+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-top: 5px solid;">+ <div class="child" data-expected-width="50" data-expected-height="20"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">78+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="20" data-expected-height="44"+ style="writing-mode: sideways-lr; width: 20px; height: stretch;">79+ </div>+ </div>+ </div>+ <div style="writing-mode: sideways-lr;">+ <div class="container" style="border-right: 5px solid;">+ <div class="child" data-expected-width="47" data-expected-height="20"+ style="writing-mode: sideways-lr; width: stretch; height: 20px;">80+ </div>+ </div>+ </div>+ </div>+</main>++<script>+ checkLayout('.child');++ // Add direction:rtl (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let container of document.querySelectorAll(".container")) {+ container.style.direction = "rtl";+ }+ checkLayout('.child');++</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-011.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-011.htmlnew file mode 100644index 00000000000..f218ed6443b--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/block-height-011.html@@ -0,0 +1,68 @@+<!DOCTYPE html>+<title>Stretching block-level on the block axis</title>+<link rel="author" title="Oriol Brufau" href="mailto:[email protected]">+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/13260">+<meta name="assert" content="The stretch size of a block-level in the block axis+ treats margins as zero when the containing block has neither border nor padding,+ and doesn't establish a BFC.">++<style>+.group { display: inline-block; vertical-align: top; }+.group > .cb { width: 100px; height: 100px; margin: 25px; }+.group.border > .cb { border: solid; }+.group.outline > .cb { outline: solid; }+.test { margin: 25px; height: stretch; background: cyan; }+</style>++<div id="log"></div>++<div class="group">+ <!-- Simple case, the containing block is just the parent. -->+ <div class="cb">+ <div class="test"></div>+ </div>++ <!-- The block-level has an inline parent, the containing block is+ the nearest block container. -->+ <div class="cb">+ <span>+ <div class="test"></div>+ </span>+ </div>++ <!-- Now the inline is wrapped inside an anonymous block, which doesn't+ establish a containing block. -->+ <div class="cb">+ <div></div>+ <span>+ <div class="test"></div>+ </span>+ </div>++ <!-- The inline now has a border, this shouldn't affect the outcome. -->+ <div class="cb">+ <span style="border: solid orange">+ <div class="test"></div>+ </span>+ </div>+</div>++<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<script>+let borderGroup = document.querySelector(".group");+let outlineGroup = borderGroup.cloneNode(true);+borderGroup.classList.add("border");+outlineGroup.classList.add("outline");+for (let el of borderGroup.querySelectorAll(".test")) {+ el.dataset.expectedHeight = "50";+}+for (let el of outlineGroup.querySelectorAll(".test")) {+ el.dataset.expectedHeight = "100";+}+borderGroup.after(outlineGroup);++checkLayout(".test");+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/content-contribution-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/content-contribution-001.htmlnew file mode 100644index 00000000000..360a869ace6--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/content-contribution-001.html@@ -0,0 +1,58 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11006">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="stretched children contribute their automatic size to parent's min/max content sizes">++<style>+ .test {+ outline: solid;+ margin-bottom: 10px;+ }+</style>++<div style="width: max-content;" class="test" data-expected-client-width="100">+ <div style="float: left; width: 100px; height: 100px;"></div>+ <div style="float: left; width: stretch; outline: solid blue;"></div>+</div>++<div style="width: max-content;" class="test" data-expected-client-width="120">+ <div style="float: left; width: 100px; height: 100px;"></div>+ <div style="float: left; width: stretch; outline: solid blue;">+ <div style="width: 20px; height: 20px;"></div>+ </div>+</div>++<div style="width: 100px; height: max-content;" class="test"+ data-expected-client-height="100">+ <div style="width: 100px; height: 100px;"></div>+ <div style="height: stretch; outline: solid blue;"></div>+</div>++<div style="width: 100px; height: max-content;" class="test"+ data-expected-client-height="120">+ <div style="width: 100px; height: 100px;"></div>+ <div style="height: stretch; outline: solid blue;">+ <div style="width: 20px; height: 20px;"></div>+ </div>+</div>++<div style="writing-mode: vertical-lr;">+ <div style="inline-size: stretch; block-size: 100px;" class="test"+ data-expected-client-height="0"></div>+</div>++<div style="writing-mode: vertical-lr;">+ <div style="inline-size: stretch; block-size: 100px; border: solid"+ data-expected-client-height="20">+ <div style="height: 20px;"></div>+ </div>+</div>++<script>+ checkLayout('.test');+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-basis-1.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-basis-1.htmlnew file mode 100644index 00000000000..3be6c8b513d--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-basis-1.html@@ -0,0 +1,73 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="stretch as a flex basis accounts for the item's margins">++<style>+ .flexbox {+ display: flex;+ width: 100px;+ }++ .item {+ flex: 0 1 stretch;+ background: lime;+ }++ .grandchild {+ width: 30px;+ height: 50px;+ }++ p {+ margin-bottom: 4px;+ }+</style>++<body onload="checkLayout('.item')">++ <p>basic:</p>+ <div class="flexbox">+ <div class="item" style="outline: 5px solid;"+ data-expected-client-width="100">+ <div class="grandchild"></div>+ </div>+ </div>++ <p>With border:</p>+ <div class="flexbox">+ <div class="item" style="border: 5px solid;"+ data-expected-client-width="90">+ <div class="grandchild"></div>+ </div>+ </div>++ <p>With border+margin:</p>+ <div class="flexbox">+ <div class="item" style="border: 5px solid; margin-right: 20px;"+ data-expected-client-width="70">+ <div class="grandchild"></div>+ </div>+ </div>++ <p>flex-basis:stretch items can still shrink:</p>+ <div class="flexbox">+ <div class="item" style="outline: 5px solid;"+ data-expected-client-width="50">+ <div class="grandchild"></div>+ </div>+ <div style="flex-basis: 100px"></div>+ </div>++ <p>column flexbox has indefinite height so flex-basis:stretch behaves as+ flex-basis:content</p>+ <div class="flexbox" style="flex-direction: column;">+ <div class="item" style="outline: 5px solid; min-height: 0px;"+ data-expected-client-height="50">+ <div class="grandchild"></div>+ </div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-001.htmlnew file mode 100644index 00000000000..8482dc7e227--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-001.html@@ -0,0 +1,22 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert" content="height:stretch resolves against the flex container definite cross size for children of stretched flex items">++<body onload="checkLayout('[data-expected-client-height]')">++ <div style="display: flex; height: 200px;">+ <div>+ <div style="height: stretch;" data-expected-client-height="200"></div>+ </div>+ </div>++ <div style="display: flex; height: 200px;">+ <div>+ <div style="height: stretch;">+ <div style="height: 50%;" data-expected-client-height="100"></div>+ </div>+ </div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-002.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-002.htmlnew file mode 100644index 00000000000..6cfa96683b7--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-002.html@@ -0,0 +1,14 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert" content="a floated element with height:stretch and aspect-ratio computes width from aspect-ratio when the flex container cross size is definite">++<body onload="checkLayout('[data-expected-client-width]')">++ <div style="display: flex; height: 200px;">+ <div>+ <div style="float: left; height: stretch; aspect-ratio: 2/1;" data-expected-client-width="400"></div>+ </div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-003.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-003.htmlnew file mode 100644index 00000000000..25cca3392fa--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-item-height-003.html@@ -0,0 +1,14 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert" content="a replaced element with height:stretch resolves to the flex container definite cross size, not its intrinsic height">++<body onload="checkLayout('[data-expected-client-height]')">++ <div style="display: flex; height: 200px;">+ <div>+ <canvas style="height: stretch; width: 100px;" data-expected-client-height="200"></canvas>+ </div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-001.htmlnew file mode 100644index 00000000000..86791d8b2e4--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-001.html@@ -0,0 +1,49 @@+<!DOCTYPE html>+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11784">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<link rel="stylesheet" type="text/css" href="../../../fonts/ahem.css" />+<meta name="assert"+ content="An item's cross-size:stretch should stretch to the line size, not the container size">+<style>+ .container {+ /* inline just so they don't overflow on each other */+ display: inline-flex;+ width: 100px;+ height: 100px;+ border: solid;+ flex-wrap: wrap;+ /* Prevent the lines from stretching. */+ align-content: start;+ font: 20px/1 Ahem;+ }++ .container > div {+ border: 3px solid;+ }++ .stretch {+ width: -moz-available;+ width: -webkit-fill-available;+ width: stretch;+ }+</style>++<div class="container">+ <div class="stretch" style="width: 75px; border-color: cyan"+ data-expected-height="26">a</div>+ <div class="stretch" style="width: 75px; border-color: magenta"+ data-expected-height="26">b</div>+</div>+<div class="container">+ <div class="stretch" style="width: 75px; border-color: cyan"+ data-expected-height="156">a</div>+ <div style="border-color: orange; height: 150px"></div>+ <div class="stretch" style="width: 75px; border-color: magenta"+ data-expected-height="26">b</div>+</div>++<script>+ document.fonts.ready.then(() => checkLayout(".stretch"));+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-002.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-002.htmlnew file mode 100644index 00000000000..819d612d10d--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-002.html@@ -0,0 +1,48 @@+<!DOCTYPE html>+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11784">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<link rel="stylesheet" type="text/css" href="../../../fonts/ahem.css" />+<meta name="assert"+ content="An item's cross-size:stretch should stretch to the line size, not the container size; container has indefinite height">+<style>+ .container {+ /* inline just so they don't overflow on each other */+ display: inline-flex;+ width: 100px;+ border: solid;+ flex-wrap: wrap;+ /* Prevent the lines from stretching. */+ align-content: start;+ font: 20px/1 Ahem;+ }++ .container>div {+ border: 3px solid;+ }++ .stretch {+ height: -moz-available;+ height: -webkit-fill-available;+ height: stretch;+ }+</style>++<div class="container">+ <div class="stretch" style="width: 75px; border-color: cyan"+ data-expected-height="26">a</div>+ <div class="stretch" style="width: 75px; border-color: magenta"+ data-expected-height="26">b</div>+</div>+<div class="container">+ <div class="stretch" style="width: 75px; border-color: cyan"+ data-expected-height="156">a</div>+ <div style="border-color: orange; height: 150px"></div>+ <div class="stretch" style="width: 75px; border-color: magenta"+ data-expected-height="26">b</div>+</div>++<script>+ document.fonts.ready.then(() => checkLayout(".stretch"));+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-003.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-003.htmlnew file mode 100644index 00000000000..ba2eb69266c--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-003.html@@ -0,0 +1,49 @@+<!DOCTYPE html>+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11784">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<link rel="stylesheet" type="text/css" href="../../../fonts/ahem.css" />+<meta name="assert"+ content="width:stretch item stretches to container width during the measure pass; container has definite width">+<style>+ .container {+ display: flex;+ flex-direction: column;+ width: 100px;+ height: 100px;+ border: solid;+ flex-wrap: wrap;+ /* Prevent the lines from stretching. */+ align-content: start;+ font: 20px/1 Ahem;+ }++ .container>div {+ border: 3px solid;+ }++ .stretch {+ width: -moz-available;+ width: -webkit-fill-available;+ width: stretch;+ }+</style>++<div class="container">+ <div class="stretch" style="height: 75px; border-color: cyan"+ data-expected-width="100">a</div>+ <div class="stretch" style="height: 75px; border-color: magenta"+ data-expected-width="100">b</div>+</div>+<div class="container">+ <div class="stretch" style="height: 75px; border-color: cyan"+ data-expected-width="156">a</div>+ <div style="border-color: orange; width: 150px"></div>+ <div class="stretch" style="height: 75px; border-color: magenta"+ data-expected-width="100">b</div>+</div>++<script>+ document.fonts.ready.then(() => checkLayout(".stretch"));+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-004.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-004.htmlnew file mode 100644index 00000000000..efe051aa19f--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-004.html@@ -0,0 +1,50 @@+<!DOCTYPE html>+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11784">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<link rel="stylesheet" type="text/css" href="../../../fonts/ahem.css" />+<meta name="assert"+ content="width:stretch item stretches to container width during the measure pass; container has min-content width">+<style>+ .container {+ display: flex;+ flex-direction: column;+ max-width: 100px;+ width: min-content;+ height: 100px;+ border: solid;+ flex-wrap: wrap;+ /* Prevent the lines from stretching. */+ align-content: start;+ font: 20px/1 Ahem;+ }++ .container>div {+ border: 3px solid;+ }++ .stretch {+ width: -moz-available;+ width: -webkit-fill-available;+ width: stretch;+ }+</style>++<div class="container">+ <div class="stretch" style="height: 75px; border-color: cyan"+ data-expected-width="26">a</div>+ <div class="stretch" style="height: 75px; border-color: magenta"+ data-expected-width="26">b</div>+</div>+<div class="container">+ <div class="stretch" style="height: 75px; border-color: cyan"+ data-expected-width="156">c</div>+ <div style="border-color: orange; width: 150px"></div>+ <div class="stretch" style="height: 75px; border-color: magenta"+ data-expected-width="100">d</div>+</div>++<script>+ document.fonts.ready.then(() => checkLayout(".stretch"));+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-005.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-005.htmlnew file mode 100644index 00000000000..eeea1e3a286--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-line-005.html@@ -0,0 +1,35 @@+<!DOCTYPE html>+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11784">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="An item's cross-size:stretch should stretch to the line size, not the container size; single-line container has indefinite height">+<style>+ .container {+ display: inline-flex;+ width: 100px;+ border: solid;+ margin: 10px;+ }++ .container>div {+ border: 3px solid;+ }++ .stretch {+ height: -moz-available;+ height: -webkit-fill-available;+ height: stretch;+ }+</style>++<div class="container">+ <div class="stretch" style="width: 75px; border-color: cyan"+ data-expected-height="156"></div>+ <div style="border-color: orange; height: 150px"></div>+</div>++<script>+ checkLayout(".stretch");+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-stretch-min-max-cross-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-stretch-min-max-cross-001.htmlnew file mode 100644index 00000000000..5b503ae1acb--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/flex-stretch-min-max-cross-001.html@@ -0,0 +1,27 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="stretch min/max-height on flex items should interact correctly with non-stretch constraints">+<style>+ .flex {+ display: inline-flex;+ width: 100px;+ height: 200px;+ vertical-align: top;+ margin: 2px;+ }+</style>++<!-- Test 1: max-height:stretch should clamp, but fixed min-height should raise.+ height:300px, max-height:stretch=200px -> 200px, min-height:250px wins -> 250px. -->+<div class="flex">+ <div style="height: 300px; max-height: stretch; min-height: 250px; background: green"+ data-expected-height="250">test 1</div>+</div>++<script>+ checkLayout("[data-expected-height]");+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/grid-item-height-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/grid-item-height-001.htmlnew file mode 100644index 00000000000..8637fea8611--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/grid-item-height-001.html@@ -0,0 +1,31 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert" content="Checks the behaviour of height: stretch on grid items.">+<style>+.content {+ width: 20px;+ height: 20px;+ background: lime;+}+</style>+<body onload="checkLayout('[data-expected-height]')">++<!-- Grid item with stretch in an indefinite-height grid with definite row tracks.+ The grid area provides a definite height even though the grid container doesn't. -->+<div style="display: grid; grid-template-rows: 80px;">+ <div data-expected-height=80 style="height: stretch;">+ <div class=content></div>+ </div>+</div>++<!-- Grid item with stretch in an indefinite-height grid with auto row tracks.+ The grid area height is indefinite, so stretch falls back to auto. -->+<div style="display: grid;">+ <div data-expected-height=20 style="height: stretch;">+ <div class=content></div>+ </div>+</div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-1.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-1.htmlnew file mode 100644index 00000000000..61240651e74--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-1.html@@ -0,0 +1,20 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11006">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="with indefinite available space, a preferred size property value of stretch behaves as auto">++<body+ onload="checkLayout('[data-expected-client-height]')">++ <div style="block-size: stretch; inline-size: 100px; border: solid"+ data-expected-client-height="0"></div>++ <div style="block-size: stretch; inline-size: 100px; border: solid"+ data-expected-client-height="20">+ <div style="height: 20px;"></div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-2.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-2.htmlnew file mode 100644index 00000000000..8b06edb8b2f--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-2.html@@ -0,0 +1,15 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11006">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="with indefinite available space, min-height:stretch resolves to 0">++<body+ onload="checkLayout('[data-expected-client-height]')">++ <div style="min-height: stretch; height: 0; width: 200px; border: solid"+ data-expected-client-height="0">lorem ipsum</div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-3.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-3.htmlnew file mode 100644index 00000000000..b1ea671c3e2--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-3.html@@ -0,0 +1,16 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11006">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="with indefinite available space, max-height: stretch resolves to infinity">++<body+ onload="checkLayout('[data-expected-client-height]')">++ <div style="max-height: stretch; height: 4000px; width: 200px; border: solid;"+ data-expected-client-height="4000">+ lorem ipsum</div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-4.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-4.htmlnew file mode 100644index 00000000000..46efa777787--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-4.html@@ -0,0 +1,26 @@+<!DOCTYPE html>+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="help" href="https://github.com/w3c/csswg-drafts/issues/11006">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="with indefinite available space, flex-item's min-height:stretch in the main axis resolves as 0, and does not invoke automatic minimum sizing">++<body+ onload="checkLayout('[data-expected-client-height]')">++ <p>If indefinite <code>min-height: stretch</code> behaves as automatic size+ then black border will encompass lorem ipsum due to flex automatic minimum+ sizing.</p>++ <p>If indefinite <code>min-height: stretch</code> behaves as 0px+ then black border will not encompass lorem ipsum.</p>++ <div+ style="display: flex; flex-direction: column; border: solid cyan; min-height: 100px; width: 200px;">+ <div style="min-height: stretch; flex-basis: 0; border: solid"+ data-expected-client-height="0">lorem ipsum+ </div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-5.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-5.htmlnew file mode 100644index 00000000000..d791dab85e0--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-5.html@@ -0,0 +1,22 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert" content="height:stretch inside a flex item behaves as auto when the flex container cross size is indefinite">++<body onload="checkLayout('[data-expected-client-height]')">++ <div style="display: flex;">+ <div>+ <div style="display: flex; height: stretch;" data-expected-client-height="0"></div>+ </div>+ </div>++ <div style="display: flex;">+ <div>+ <div style="height: stretch;" data-expected-client-height="20">+ <div style="height: 20px;"></div>+ </div>+ </div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-6.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-6.htmlnew file mode 100644index 00000000000..8d1627c1e16--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/indefinite-6.html@@ -0,0 +1,22 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert" content="height:stretch inside a flex item behaves as auto when the column flex container has indefinite main size">++<body onload="checkLayout('[data-expected-client-height]')">++ <div style="display: flex; flex-direction: column;">+ <div>+ <div style="height: stretch; width: 50px;" data-expected-client-height="0"></div>+ </div>+ </div>++ <div style="display: flex; flex-direction: column;">+ <div>+ <div style="height: stretch; width: 50px;" data-expected-client-height="20">+ <div style="height: 20px;"></div>+ </div>+ </div>+ </div>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/parsing.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/parsing.htmlnew file mode 100644index 00000000000..f54c5c3302a--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/parsing.html@@ -0,0 +1,36 @@+<!DOCTYPE html>+<html>+<head>+<meta charset="utf-8">+<title>CSS Intrinsic & Extrinsic Sizing Test: parsing stretch value</title>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../css/support/parsing-testcommon.js"></script>+<script src="../../../css/support/shorthand-testcommon.js"></script>+</head>+<body>+<script>+test_valid_value("width", "stretch");+test_valid_value("height", "stretch");+test_valid_value("max-width", "stretch");+test_valid_value("min-width", "stretch");+test_valid_value("max-height", "stretch");+test_valid_value("min-height", "stretch");+test_valid_value("inline-size", "stretch");+test_valid_value("block-size", "stretch");+test_valid_value("max-inline-size", "stretch");+test_valid_value("min-inline-size", "stretch");+test_valid_value("max-block-size", "stretch");+test_valid_value("min-block-size", "stretch");++test_valid_value("flex-basis", "stretch");+test_shorthand_value('flex', '1 0 stretch', {+ 'flex-grow': '1',+ 'flex-shrink': '0',+ 'flex-basis': 'stretch'+});++</script>+</body>+</html>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/replaced-stretch-height-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/replaced-stretch-height-001.htmlnew file mode 100644index 00000000000..81f34612159--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/replaced-stretch-height-001.html@@ -0,0 +1,24 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="min-height:stretch on replaced elements should transfer through aspect ratio to width">+<style>+ .block {+ width: 100px;+ height: 200px;+ }+</style>++<!-- canvas (1:1) with min-height:stretch in a block container.+ Intrinsic 50px, min-height:stretch=200px wins, width scales to 200px. -->+<div class="block">+ <canvas width="50" height="50" style="min-height: stretch; background: teal"+ data-expected-height="200" data-expected-width="200"></canvas>+</div>++<script>+ checkLayout("[data-expected-height], [data-expected-width]");+</script>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-block-size-001.tentative.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-block-size-001.tentative.htmlnew file mode 100644index 00000000000..4807febe231--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-block-size-001.tentative.html@@ -0,0 +1,211 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<!-- NOTE: This test is meant to be an near-exact copy of the neighboring test+ file of nearly-the-same-name, with this version just adding "-alias" and+ ".tentative" to the filename. The markup should be identical to the+ original, aside from s/stretch/-webkit-fill-available/ in the CSS rule+ ".test {...}". The expectation is that those keywords can be considered+ to be aliases that give the exact same sizing behavior. -->+<meta name="assert"+ content="block-size:stretch (setting 'height' in this case) causes an element's content-box to be sized such that its margin-box-size will fill the containing block's content-box.">+<style>+ .cb {+ block-size: 50px;+ inline-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-block: 5px;+ padding-inline: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the block axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-block-start: 2px;+ margin-block-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-height` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ block-size: -webkit-fill-available;+ inline-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-height]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('[data-expected-height]');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, various form controls: -->+ <div class="cb">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-height="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-height="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-height="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-height="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-height="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's block-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-height="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-height="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-height="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: row wrap">+ <div class="test" data-expected-height="55"></div>+ <div style="block-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-rows: 35px">+ <div class="test" data-expected-height="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track: -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-height="45"></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-inline-size-001.tentative.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-inline-size-001.tentative.htmlnew file mode 100644index 00000000000..a3eac70b4b6--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-inline-size-001.tentative.html@@ -0,0 +1,211 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<!-- NOTE: This test is meant to be an near-exact copy of the neighboring test+ file of nearly-the-same-name, with this version just adding "-alias" and+ ".tentative" to the filename. The markup should be identical to the+ original, aside from s/stretch/-webkit-fill-available/ in the CSS rule+ ".test {...}". The expectation is that those keywords can be considered+ to be aliases that give the exact same sizing behavior. -->+<meta name="assert"+ content="inline-size:stretch (setting 'width' in this case) causes an element's content-box to be sized such that its margin-box-size will fill the containing block's content-box.">+<style>+ .cb {+ inline-size: 50px;+ block-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-inline: 5px;+ padding-block: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the inline axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-inline-start: 2px;+ margin-inline-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-width` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ inline-size: -webkit-fill-available;+ block-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-width]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('[data-expected-width]');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, form controls, float: -->+ <div class="cb">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-width="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-width="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-width="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-width="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-width="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's inline-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-width="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-width="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-width="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: column wrap">+ <div class="test" data-expected-width="55"></div>+ <div style="inline-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-columns: 35px">+ <div class="test" data-expected-width="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track: -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-width="45"></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-max-block-size-001.tentative.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-max-block-size-001.tentative.htmlnew file mode 100644index 00000000000..a2e52f8615b--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-max-block-size-001.tentative.html@@ -0,0 +1,233 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<!-- NOTE: This test is meant to be an near-exact copy of the neighboring test+ file of nearly-the-same-name, with this version just adding "-alias" and+ ".tentative" to the filename. The markup should be identical to the+ original, aside from s/stretch/-webkit-fill-available/ in the CSS rule+ ".test {...}". The expectation is that those keywords can be considered+ to be aliases that give the exact same sizing behavior. -->+<meta name="assert"+ content="max-block-size:stretch (setting 'max-height' in this case) resolves and clamps as expected (producing similar results as if we had specified the keyword for the block-size property)">+<style>+ .cb {+ block-size: 50px;+ inline-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-block: 5px;+ padding-inline: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the block axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-block-start: 2px;+ margin-block-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-height` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ /* We expect "max-block-size:stretch" to cause the used value of+ * "block-size" to be clamped to the "stretch" size. */+ max-block-size: -webkit-fill-available;+ /* This is intentionally larger than our containing block's block-size,+ * and we expect it to be clamped by our max-block-size specified above+ * in nearly all of this test's subtests. */+ block-size: 55px;+ inline-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-height]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces, aside from one subtest that we skip+ // for this pass), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ if (!elem.hasAttribute("skip-second-pass")) {+ elem.style.boxSizing = "border-box";+ }+ }+ checkLayout('[data-expected-height]:not([skip-second-pass])');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, various form controls: -->+ <div class="cb">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-height="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-height="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-height="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-height="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-height="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's block-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-height="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-height="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-height="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: row wrap">+ <div class="test" data-expected-height="55"></div>+ <div style="block-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-rows: 35px">+ <div class="test" data-expected-height="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track:+ Here, the 'max-block-size:stretch' doesn't get to make a difference,+ because it doesn't resolve (and hence doesn't have any clamping effect)+ during the row's intrinsic-sizing pass. So the grid row ends up+ being sized to exactly fit the *unclamped* 'block-size'; and that+ row then establishes the containing block that we resolve the+ "max-block-size:stretch" keyword against. This ultimately means that+ the max-block-size happens to resolve to our unclamped block-size,+ and hence it trivially has no clamping impact. (This also means that+ 'box-sizing' *does affect the expected size* in this subtest, unlike the+ rest of this test's subtests! So, we use a dummy attribute to opt this+ subtest out of this test's second pass, to avoid incorrectly asserting+ that our data-expected-width is still the target size when 'box-sizing'+ is tweaked.) -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-height="65" skip-second-pass></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-max-inline-size-001.tentative.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-max-inline-size-001.tentative.htmlnew file mode 100644index 00000000000..737041f5ac5--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-max-inline-size-001.tentative.html@@ -0,0 +1,233 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<!-- NOTE: This test is meant to be an near-exact copy of the neighboring test+ file of nearly-the-same-name, with this version just adding "-alias" and+ ".tentative" to the filename. The markup should be identical to the+ original, aside from s/stretch/-webkit-fill-available/ in the CSS rule+ ".test {...}". The expectation is that those keywords can be considered+ to be aliases that give the exact same sizing behavior. -->+<meta name="assert"+ content="max-inline-size:stretch (setting 'max-width' in this case) resolves and clamps as expected (producing similar results as if we had specified the keyword for the inline-size property)">+<style>+ .cb {+ inline-size: 50px;+ block-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-inline: 5px;+ padding-block: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the inline axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-inline-start: 2px;+ margin-inline-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-width` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ /* We expect "max-inline-size:stretch" to cause the used value of+ * "inline-size" to be clamped to the resolved "stretch" size. */+ max-inline-size: -webkit-fill-available;+ /* This is intentionally larger than our containing block's inline-size,+ * and we expect it to be clamped by our max-inline-size specified above+ * in nearly all of this test's subtests. */+ inline-size: 55px;+ block-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-width]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces, aside from one subtest that we skip+ // for this pass), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ if (!elem.hasAttribute("skip-second-pass")) {+ elem.style.boxSizing = "border-box";+ }+ }+ checkLayout('[data-expected-width]:not([skip-second-pass])');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, form controls, float: -->+ <div class="cb">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-width="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-width="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-width="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-width="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-width="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's inline-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-width="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-width="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-width="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: column wrap">+ <div class="test" data-expected-width="55"></div>+ <div style="inline-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-columns: 35px">+ <div class="test" data-expected-width="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track:+ Here, the 'max-inline-size:stretch' doesn't get to make a difference,+ because it doesn't resolve (and hence doesn't have any clamping effect)+ during the column's intrinsic-sizing pass. So the grid column ends up+ being sized to exactly fit the *unclamped* 'inline-size'; and that+ column then establishes the containing block that we resolve the+ "max-inline-size:stretch" keyword against. This ultimately means that+ the max-inline-size happens to resolve to our unclamped inline-size,+ and hence it trivially has no clamping impact. (This also means that+ 'box-sizing' *does affect the expected size* in this subtest, unlike the+ rest of this test's subtests! So, we use a dummy attribute to opt this+ subtest out of this test's second pass, to avoid incorrectly asserting+ that our data-expected-width is still the target size when 'box-sizing'+ is tweaked.) -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-width="65" skip-second-pass></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-min-block-size-001.tentative.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-min-block-size-001.tentative.htmlnew file mode 100644index 00000000000..5b61b050555--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-min-block-size-001.tentative.html@@ -0,0 +1,214 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<!-- NOTE: This test is meant to be an near-exact copy of the neighboring test+ file of nearly-the-same-name, with this version just adding "-alias" and+ ".tentative" to the filename. The markup should be identical to the+ original, aside from s/stretch/-webkit-fill-available/ in the CSS rule+ ".test {...}". The expectation is that those keywords can be considered+ to be aliases that give the exact same sizing behavior. -->+<meta name="assert"+ content="min-block-size:stretch (setting 'min-height' in this case) resolves and clamps as expected (producing similar results as if we had specified the keyword for the block-size property)">+<style>+ .cb {+ block-size: 50px;+ inline-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-block: 5px;+ padding-inline: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the block axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-block-start: 2px;+ margin-block-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-height` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ /* We expect "min-block-size:stretch" to cause the used value of+ * "block-size" to be clamped to the "stretch" size. */+ min-block-size: -webkit-fill-available;+ block-size: 0;+ inline-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-height]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('[data-expected-height]');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, various form controls: -->+ <div class="cb">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-height="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-height="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-height="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-height="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-height="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's block-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-height="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-height="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-height="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: row wrap">+ <div class="test" data-expected-height="55"></div>+ <div style="block-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-rows: 35px">+ <div class="test" data-expected-height="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track: -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-height="45"></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-min-inline-size-001.tentative.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-min-inline-size-001.tentative.htmlnew file mode 100644index 00000000000..ffcf2514dc6--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-alias-min-inline-size-001.tentative.html@@ -0,0 +1,214 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<!-- NOTE: This test is meant to be an near-exact copy of the neighboring test+ file of nearly-the-same-name, with this version just adding "-alias" and+ ".tentative" to the filename. The markup should be identical to the+ original, aside from s/stretch/-webkit-fill-available/ in the CSS rule+ ".test {...}". The expectation is that those keywords can be considered+ to be aliases that give the exact same sizing behavior. -->+<meta name="assert"+ content="min-inline-size:stretch (setting 'min-width' in this case) resolves and clamps as expected (producing similar results as if we had specified the keyword for the inline-size property)">+<style>+ .cb {+ inline-size: 50px;+ block-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-inline: 5px;+ padding-block: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the inline axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-inline-start: 2px;+ margin-inline-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-width` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ /* We expect "min-inline-size:stretch" to cause the used value of+ * "inline-size" to be clamped to the resolved "stretch" size. */+ min-inline-size: -webkit-fill-available;+ inline-size: 0;+ block-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-width]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('[data-expected-width]');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, form controls, float: -->+ <div class="cb">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-width="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-width="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-width="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-width="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-width="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's inline-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-width="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-width="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-width="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: column wrap">+ <div class="test" data-expected-width="55"></div>+ <div style="inline-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-columns: 35px">+ <div class="test" data-expected-width="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track: -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-width="45"></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-001.htmlnew file mode 100644index 00000000000..3f29591c8cd--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-001.html@@ -0,0 +1,205 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="block-size:stretch (setting 'height' in this case) causes an element's content-box to be sized such that its margin-box-size will fill the containing block's content-box.">+<style>+ .cb {+ block-size: 50px;+ inline-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-block: 5px;+ padding-inline: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the block axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-block-start: 2px;+ margin-block-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-height` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ block-size: stretch;+ inline-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-height]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('[data-expected-height]');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, various form controls: -->+ <div class="cb">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-height="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-height="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-height="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-height="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-height="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's block-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-height="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-height="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-height="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: row wrap">+ <div class="test" data-expected-height="55"></div>+ <div style="block-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-rows: 35px">+ <div class="test" data-expected-height="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track: -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-height="45"></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-002.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-002.htmlnew file mode 100644index 00000000000..6cfc6ad3a4c--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-002.html@@ -0,0 +1,163 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="block-size:stretch causes an absolutely-positioned element's content-box to be sized to fill the available space in its containing block, regardless of the writing-mode of its DOM-tree parent.">+<style>+ .cb {+ block-size: 50px;+ inline-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding is relevant to 'stretch' sizing, since our padding-box+ * forms the containing block for the abspos child. Our padding-box+ * block-size 50 + 2*5 = 60px, and its inline-size is 40 + 2*3 = 46px */+ padding-block: 5px;+ padding-inline: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ position: relative;+ }++ .test {+ /* To make sizes predictable, we start out at the edge of our+ * containing block: */+ inset-inline-start: 0;+ inset-block-start: 0;++ position: absolute;+ /* We have 2+3 = 5px of margin in the block axis. This means the stretched+ * children should all have a border-box block-size that's 5px less than+ * the containing block's padding-box size in the same axis. The dimension+ * of the containing block's padding-box that we're filling will depend on+ * whether our WM is orthogonal to it or not. If we're orthogonal, our+ * expected stretch size is 46px - 5px = 41px. If we're not orthogonal,+ * our expected stretch size is 60px - 5px = 55px. */+ margin-block-start: 2px;+ margin-block-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-{width,height}` expectations, since+ * those correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ block-size: stretch;+ inline-size: 20px;+ background: fuchsia;+ }+ .htb { writing-mode: horizontal-tb; }+ .vlr { writing-mode: vertical-lr; }+ .vrl { writing-mode: vertical-rl; }+</style>+<script>+ function runTests() {+ checkLayout('.test');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('.test');+ }+</script>+<body onload="runTests()">+ <!-- This test is exercising cases where the abspos element's containing+ block (which happens to be its grandparent) has a writing-mode that+ disagrees with the abspos element's parent. We exercise all 6+ pairwise-mismatching combinations of {htb,vlr,vrl} for the grandparent &+ parent. For each such pair, we test all three of those same+ writing-modes on the innermost abspos element.++ Note that we use 'data-expected-{height,width}' depending on which axis+ is the block axis for the abspos ".test" element (since that's the+ element whose "block-size: stretch" resolution we're testing). So for+ "test htb" elements, we check the height; whereas for "test vlr" and+ "test vrl", we check the width.+ -->++ <!-- htb / vlr / {htb,vlr,vrl} -->+ <div class="cb htb"><div class="vlr">+ <div class="test htb" data-expected-height="55"></div>+ </div></div>+ <div class="cb htb"><div class="vlr">+ <div class="test vlr" data-expected-width="41"></div>+ </div></div>+ <div class="cb htb"><div class="vlr">+ <div class="test vrl" data-expected-width="41"></div>+ </div></div>+ <br>++ <!-- htb / vrl / {htb,vlr,vrl} -->+ <div class="cb htb"><div class="vrl">+ <div class="test htb" data-expected-height="55"></div>+ </div></div>+ <div class="cb htb"><div class="vrl">+ <div class="test vlr" data-expected-width="41"></div>+ </div></div>+ <div class="cb htb"><div class="vrl">+ <div class="test vrl" data-expected-width="41"></div>+ </div></div>+ <br>++ <!-- vlr / htb / {htb,vlr,vrl} -->+ <div class="cb vlr"><div class="htb">+ <div class="test htb" data-expected-height="41"></div>+ </div></div>+ <div class="cb vlr"><div class="htb">+ <div class="test vlr" data-expected-width="55"></div>+ </div></div>+ <div class="cb vlr"><div class="htb">+ <div class="test vrl" data-expected-width="55"></div>+ </div></div>+ <br>++ <!-- vlr / vrl / {htb,vlr,vrl} -->+ <div class="cb vlr"><div class="vrl">+ <div class="test htb" data-expected-height="41"></div>+ </div></div>+ <div class="cb vlr"><div class="vrl">+ <div class="test vlr" data-expected-width="55"></div>+ </div></div>+ <div class="cb vlr"><div class="vrl">+ <div class="test vrl" data-expected-width="55"></div>+ </div></div>+ <br>++ <!-- vrl / htb / {htb,vlr,vrl} -->+ <div class="cb vrl"><div class="htb">+ <div class="test htb" data-expected-height="41"></div>+ </div></div>+ <div class="cb vrl"><div class="htb">+ <div class="test vlr" data-expected-width="55"></div>+ </div></div>+ <div class="cb vrl"><div class="htb">+ <div class="test vrl" data-expected-width="55"></div>+ </div></div>+ <br>++ <!-- vrl / vlr / {htb,vlr,vrl} -->+ <div class="cb vrl"><div class="vrl">+ <div class="test htb" data-expected-height="41"></div>+ </div></div>+ <div class="cb vrl"><div class="vrl">+ <div class="test vlr" data-expected-width="55"></div>+ </div></div>+ <div class="cb vrl"><div class="vrl">+ <div class="test vrl" data-expected-width="55"></div>+ </div></div>+ <br>++</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-003.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-003.htmlnew file mode 100644index 00000000000..60fb3e9ae61--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-block-size-003.html@@ -0,0 +1,164 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="block-size:stretch causes an absolutely-positioned element's content-box to be sized to fill the available space in its containing block, regardless of the writing-mode of its DOM-tree parent.">+<style>+ .cb {+ block-size: 60px;+ inline-size: 46px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ position: relative;+ }++ .cb > * {+ /* This rule is targeting the DOM-tree-parents of the abspos elements.+ * In the interests of simplicity and consistency, this style rule makes+ * the matched elements fill *their* parent boxes (which are the abspos+ * containing blocks). Without this, there are a few edge cases where+ * some of the matched elements would be zero-sized, which would then+ * collapse away the space that we want to be available for stretching.+ */+ block-size: 100%;+ inline-size: 100%;+ }++ .test {+ position: absolute;+ /* We have 2+3 = 5px of margin in the block axis. This means the stretched+ * children should all have a border-box block-size that's 5px less than+ * the containing block's padding-box size in the same axis. The dimension+ * of the containing block's padding-box that we're filling will depend on+ * whether our WM is orthogonal to it or not. If we're orthogonal, our+ * expected stretch size is 46px - 5px = 41px. If we're not orthogonal,+ * our expected stretch size is 60px - 5px = 55px. */+ margin-block-start: 2px;+ margin-block-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-{width,height}` expectations, since+ * those correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ block-size: stretch;+ inline-size: 20px;+ background: fuchsia;+ }+ .htb { writing-mode: horizontal-tb; }+ .vlr { writing-mode: vertical-lr; }+ .vrl { writing-mode: vertical-rl; }+</style>+<script>+ function runTests() {+ checkLayout('.test');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('.test');+ }+</script>+<body onload="runTests()">+ <!-- This test is exercising cases where the abspos element's containing+ block (which happens to be its grandparent) has a writing-mode that+ disagrees with the abspos element's parent. We exercise all 6+ pairwise-mismatching combinations of {htb,vlr,vrl} for the grandparent &+ parent. For each such pair, we test all three of those same+ writing-modes on the innermost abspos element.++ Note that we use 'data-expected-{height,width}' depending on which axis+ is the block axis for the abspos ".test" element (since that's the+ element whose "block-size: stretch" resolution we're testing). So for+ "test htb" elements, we check the height; whereas for "test vlr" and+ "test vrl", we check the width.+ -->++ <!-- htb / vlr / {htb,vlr,vrl} -->+ <div class="cb htb"><div class="vlr">+ <div class="test htb" data-expected-height="55"></div>+ </div></div>+ <div class="cb htb"><div class="vlr">+ <div class="test vlr" data-expected-width="41"></div>+ </div></div>+ <div class="cb htb"><div class="vlr">+ <div class="test vrl" data-expected-width="41"></div>+ </div></div>+ <br>++ <!-- htb / vrl / {htb,vlr,vrl} -->+ <div class="cb htb"><div class="vrl">+ <div class="test htb" data-expected-height="55"></div>+ </div></div>+ <div class="cb htb"><div class="vrl">+ <div class="test vlr" data-expected-width="41"></div>+ </div></div>+ <div class="cb htb"><div class="vrl">+ <div class="test vrl" data-expected-width="41"></div>+ </div></div>+ <br>++ <!-- vlr / htb / {htb,vlr,vrl} -->+ <div class="cb vlr"><div class="htb">+ <div class="test htb" data-expected-height="41"></div>+ </div></div>+ <div class="cb vlr"><div class="htb">+ <div class="test vlr" data-expected-width="55"></div>+ </div></div>+ <div class="cb vlr"><div class="htb">+ <div class="test vrl" data-expected-width="55"></div>+ </div></div>+ <br>++ <!-- vlr / vrl / {htb,vlr,vrl} -->+ <div class="cb vlr"><div class="vrl">+ <div class="test htb" data-expected-height="41"></div>+ </div></div>+ <div class="cb vlr"><div class="vrl">+ <div class="test vlr" data-expected-width="55"></div>+ </div></div>+ <div class="cb vlr"><div class="vrl">+ <div class="test vrl" data-expected-width="55"></div>+ </div></div>+ <br>++ <!-- vrl / htb / {htb,vlr,vrl} -->+ <div class="cb vrl"><div class="htb">+ <div class="test htb" data-expected-height="41"></div>+ </div></div>+ <div class="cb vrl"><div class="htb">+ <div class="test vlr" data-expected-width="55"></div>+ </div></div>+ <div class="cb vrl"><div class="htb">+ <div class="test vrl" data-expected-width="55"></div>+ </div></div>+ <br>++ <!-- vrl / vlr / {htb,vlr,vrl} -->+ <div class="cb vrl"><div class="vrl">+ <div class="test htb" data-expected-height="41"></div>+ </div></div>+ <div class="cb vrl"><div class="vrl">+ <div class="test vlr" data-expected-width="55"></div>+ </div></div>+ <div class="cb vrl"><div class="vrl">+ <div class="test vrl" data-expected-width="55"></div>+ </div></div>+ <br>++</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-001.htmlnew file mode 100644index 00000000000..86776f3c5b2--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-001.html@@ -0,0 +1,205 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="inline-size:stretch (setting 'width' in this case) causes an element's content-box to be sized such that its margin-box-size will fill the containing block's content-box.">+<style>+ .cb {+ inline-size: 50px;+ block-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-inline: 5px;+ padding-block: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the inline axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-inline-start: 2px;+ margin-inline-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-width` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ inline-size: stretch;+ block-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-width]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('[data-expected-width]');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, form controls, float: -->+ <div class="cb">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-width="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-width="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-width="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-width="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-width="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's inline-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-width="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-width="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-width="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: column wrap">+ <div class="test" data-expected-width="55"></div>+ <div style="inline-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-columns: 35px">+ <div class="test" data-expected-width="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track: -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-width="45"></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-002.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-002.htmlnew file mode 100644index 00000000000..e86ab1b07ce--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-002.html@@ -0,0 +1,163 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="inline-size:stretch causes an absolutely-positioned element's content-box to be sized to fill the available space in its containing block, regardless of the writing-mode of its DOM-tree parent.">+<style>+ .cb {+ inline-size: 50px;+ block-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding is relevant to 'stretch' sizing, since our padding-box+ * forms the containing block for the abspos child. Our padding-box+ * block-size 50 + 2*5 = 60px, and its inline-size is 40 + 2*3 = 46px */+ padding-inline: 5px;+ padding-block: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ position: relative;+ }++ .test {+ /* To make sizes predictable, we start out at the edge of our+ * containing block: */+ inset-inline-start: 0;+ inset-block-start: 0;++ position: absolute;+ /* We have 2+3 = 5px of margin in the inline axis. This means the stretched+ * children should all have a border-box inline-size that's 5px less than+ * the containing block's padding-box size in the same axis. The dimension+ * of the containing block's padding-box that we're filling will depend on+ * whether our WM is orthogonal to it or not. If we're orthogonal, our+ * expected stretch size is 46px - 5px = 41px. If we're not orthogonal,+ * our expected stretch size is 60px - 5px = 55px. */+ margin-inline-start: 2px;+ margin-inline-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-{width,height}` expectations, since+ * those correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ inline-size: stretch;+ block-size: 20px;+ background: fuchsia;+ }+ .htb { writing-mode: horizontal-tb; }+ .vlr { writing-mode: vertical-lr; }+ .vrl { writing-mode: vertical-rl; }+</style>+<script>+ function runTests() {+ checkLayout('.test');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('.test');+ }+</script>+<body onload="runTests()">+ <!-- This test is exercising cases where the abspos element's containing+ block (which happens to be its grandparent) has a writing-mode that+ disagrees with the abspos element's parent. We exercise all 6+ pairwise-mismatching combinations of {htb,vlr,vrl} for the grandparent &+ parent. For each such pair, we test all three of those same+ writing-modes on the innermost abspos element.++ Note that we use 'data-expected-{height,width}' depending on which axis+ is the block axis for the abspos ".test" element (since that's the+ element whose "block-size: stretch" resolution we're testing). So for+ "test htb" elements, we check the height; whereas for "test vlr" and+ "test vrl", we check the width.+ -->++ <!-- htb / vlr / {htb,vlr,vrl} -->+ <div class="cb htb"><div class="vlr">+ <div class="test htb" data-expected-width="55"></div>+ </div></div>+ <div class="cb htb"><div class="vlr">+ <div class="test vlr" data-expected-height="41"></div>+ </div></div>+ <div class="cb htb"><div class="vlr">+ <div class="test vrl" data-expected-height="41"></div>+ </div></div>+ <br>++ <!-- htb / vrl / {htb,vlr,vrl} -->+ <div class="cb htb"><div class="vrl">+ <div class="test htb" data-expected-width="55"></div>+ </div></div>+ <div class="cb htb"><div class="vrl">+ <div class="test vlr" data-expected-height="41"></div>+ </div></div>+ <div class="cb htb"><div class="vrl">+ <div class="test vrl" data-expected-height="41"></div>+ </div></div>+ <br>++ <!-- vlr / htb / {htb,vlr,vrl} -->+ <div class="cb vlr"><div class="htb">+ <div class="test htb" data-expected-width="41"></div>+ </div></div>+ <div class="cb vlr"><div class="htb">+ <div class="test vlr" data-expected-height="55"></div>+ </div></div>+ <div class="cb vlr"><div class="htb">+ <div class="test vrl" data-expected-height="55"></div>+ </div></div>+ <br>++ <!-- vlr / vrl / {htb,vlr,vrl} -->+ <div class="cb vlr"><div class="vrl">+ <div class="test htb" data-expected-width="41"></div>+ </div></div>+ <div class="cb vlr"><div class="vrl">+ <div class="test vlr" data-expected-height="55"></div>+ </div></div>+ <div class="cb vlr"><div class="vrl">+ <div class="test vrl" data-expected-height="55"></div>+ </div></div>+ <br>++ <!-- vrl / htb / {htb,vlr,vrl} -->+ <div class="cb vrl"><div class="htb">+ <div class="test htb" data-expected-width="41"></div>+ </div></div>+ <div class="cb vrl"><div class="htb">+ <div class="test vlr" data-expected-height="55"></div>+ </div></div>+ <div class="cb vrl"><div class="htb">+ <div class="test vrl" data-expected-height="55"></div>+ </div></div>+ <br>++ <!-- vrl / vlr / {htb,vlr,vrl} -->+ <div class="cb vrl"><div class="vrl">+ <div class="test htb" data-expected-width="41"></div>+ </div></div>+ <div class="cb vrl"><div class="vrl">+ <div class="test vlr" data-expected-height="55"></div>+ </div></div>+ <div class="cb vrl"><div class="vrl">+ <div class="test vrl" data-expected-height="55"></div>+ </div></div>+ <br>++</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-003.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-003.htmlnew file mode 100644index 00000000000..67dc011cf63--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-inline-size-003.html@@ -0,0 +1,164 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="inline-size:stretch causes an absolutely-positioned element's content-box to be sized to fill the available space in its containing block, regardless of the writing-mode of its DOM-tree parent.">+<style>+ .cb {+ inline-size: 60px;+ block-size: 46px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ position: relative;+ }++ .cb > * {+ /* This rule is targeting the DOM-tree-parents of the abspos elements.+ * In the interests of simplicity and consistency, this style rule makes+ * the matched elements fill *their* parent boxes (which are the abspos+ * containing blocks). Without this, there are a few edge cases where+ * some of the matched elements would be zero-sized, which would then+ * collapse away the space that we want to be available for stretching.+ */+ block-size: 100%;+ inline-size: 100%;+ }++ .test {+ position: absolute;+ /* We have 2+3 = 5px of margin in the inline axis. This means the stretched+ * children should all have a border-box inline-size that's 5px less than+ * the containing block's padding-box size in the same axis. The dimension+ * of the containing block's padding-box that we're filling will depend on+ * whether our WM is orthogonal to it or not. If we're orthogonal, our+ * expected stretch size is 46px - 5px = 41px. If we're not orthogonal,+ * our expected stretch size is 60px - 5px = 55px. */+ margin-inline-start: 2px;+ margin-inline-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-{width,height}` expectations, since+ * those correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ inline-size: stretch;+ block-size: 20px;+ background: fuchsia;+ }+ .htb { writing-mode: horizontal-tb; }+ .vlr { writing-mode: vertical-lr; }+ .vrl { writing-mode: vertical-rl; }+</style>+<script>+ function runTests() {+ checkLayout('.test');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('.test');+ }+</script>+<body onload="runTests()">+ <!-- This test is exercising cases where the abspos element's containing+ block (which happens to be its grandparent) has a writing-mode that+ disagrees with the abspos element's parent. We exercise all 6+ pairwise-mismatching combinations of {htb,vlr,vrl} for the grandparent &+ parent. For each such pair, we test all three of those same+ writing-modes on the innermost abspos element.++ Note that we use 'data-expected-{height,width}' depending on which axis+ is the block axis for the abspos ".test" element (since that's the+ element whose "block-size: stretch" resolution we're testing). So for+ "test htb" elements, we check the height; whereas for "test vlr" and+ "test vrl", we check the width.+ -->++ <!-- htb / vlr / {htb,vlr,vrl} -->+ <div class="cb htb"><div class="vlr">+ <div class="test htb" data-expected-width="55"></div>+ </div></div>+ <div class="cb htb"><div class="vlr">+ <div class="test vlr" data-expected-height="41"></div>+ </div></div>+ <div class="cb htb"><div class="vlr">+ <div class="test vrl" data-expected-height="41"></div>+ </div></div>+ <br>++ <!-- htb / vrl / {htb,vlr,vrl} -->+ <div class="cb htb"><div class="vrl">+ <div class="test htb" data-expected-width="55"></div>+ </div></div>+ <div class="cb htb"><div class="vrl">+ <div class="test vlr" data-expected-height="41"></div>+ </div></div>+ <div class="cb htb"><div class="vrl">+ <div class="test vrl" data-expected-height="41"></div>+ </div></div>+ <br>++ <!-- vlr / htb / {htb,vlr,vrl} -->+ <div class="cb vlr"><div class="htb">+ <div class="test htb" data-expected-width="41"></div>+ </div></div>+ <div class="cb vlr"><div class="htb">+ <div class="test vlr" data-expected-height="55"></div>+ </div></div>+ <div class="cb vlr"><div class="htb">+ <div class="test vrl" data-expected-height="55"></div>+ </div></div>+ <br>++ <!-- vlr / vrl / {htb,vlr,vrl} -->+ <div class="cb vlr"><div class="vrl">+ <div class="test htb" data-expected-width="41"></div>+ </div></div>+ <div class="cb vlr"><div class="vrl">+ <div class="test vlr" data-expected-height="55"></div>+ </div></div>+ <div class="cb vlr"><div class="vrl">+ <div class="test vrl" data-expected-height="55"></div>+ </div></div>+ <br>++ <!-- vrl / htb / {htb,vlr,vrl} -->+ <div class="cb vrl"><div class="htb">+ <div class="test htb" data-expected-width="41"></div>+ </div></div>+ <div class="cb vrl"><div class="htb">+ <div class="test vlr" data-expected-height="55"></div>+ </div></div>+ <div class="cb vrl"><div class="htb">+ <div class="test vrl" data-expected-height="55"></div>+ </div></div>+ <br>++ <!-- vrl / vlr / {htb,vlr,vrl} -->+ <div class="cb vrl"><div class="vrl">+ <div class="test htb" data-expected-width="41"></div>+ </div></div>+ <div class="cb vrl"><div class="vrl">+ <div class="test vlr" data-expected-height="55"></div>+ </div></div>+ <div class="cb vrl"><div class="vrl">+ <div class="test vrl" data-expected-height="55"></div>+ </div></div>+ <br>++</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-max-block-size-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-max-block-size-001.htmlnew file mode 100644index 00000000000..0b35048a6f2--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-max-block-size-001.html@@ -0,0 +1,227 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="max-block-size:stretch (setting 'max-height' in this case) resolves and clamps as expected (producing similar results as if we had specified the keyword for the block-size property)">+<style>+ .cb {+ block-size: 50px;+ inline-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-block: 5px;+ padding-inline: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the block axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-block-start: 2px;+ margin-block-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-height` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ /* We expect "max-block-size:stretch" to cause the used value of+ * "block-size" to be clamped to the "stretch" size. */+ max-block-size: stretch;+ /* This is intentionally larger than our containing block's block-size,+ * and we expect it to be clamped by our max-block-size specified above+ * in nearly all of this test's subtests. */+ block-size: 55px;+ inline-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-height]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces, aside from one subtest that we skip+ // for this pass), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ if (!elem.hasAttribute("skip-second-pass")) {+ elem.style.boxSizing = "border-box";+ }+ }+ checkLayout('[data-expected-height]:not([skip-second-pass])');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, various form controls: -->+ <div class="cb">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-height="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-height="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-height="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-height="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-height="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's block-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-height="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-height="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-height="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: row wrap">+ <div class="test" data-expected-height="55"></div>+ <div style="block-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-rows: 35px">+ <div class="test" data-expected-height="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track:+ Here, the 'max-block-size:stretch' doesn't get to make a difference,+ because it doesn't resolve (and hence doesn't have any clamping effect)+ during the row's intrinsic-sizing pass. So the grid row ends up+ being sized to exactly fit the *unclamped* 'block-size'; and that+ row then establishes the containing block that we resolve the+ "max-block-size:stretch" keyword against. This ultimately means that+ the max-block-size happens to resolve to our unclamped block-size,+ and hence it trivially has no clamping impact. (This also means that+ 'box-sizing' *does affect the expected size* in this subtest, unlike the+ rest of this test's subtests! So, we use a dummy attribute to opt this+ subtest out of this test's second pass, to avoid incorrectly asserting+ that our data-expected-width is still the target size when 'box-sizing'+ is tweaked.) -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-height="65" skip-second-pass></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-max-inline-size-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-max-inline-size-001.htmlnew file mode 100644index 00000000000..6acf357f6e0--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-max-inline-size-001.html@@ -0,0 +1,227 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="max-inline-size:stretch (setting 'max-width' in this case) resolves and clamps as expected (producing similar results as if we had specified the keyword for the inline-size property)">+<style>+ .cb {+ inline-size: 50px;+ block-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-inline: 5px;+ padding-block: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the inline axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-inline-start: 2px;+ margin-inline-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-width` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ /* We expect "max-inline-size:stretch" to cause the used value of+ * "inline-size" to be clamped to the resolved "stretch" size. */+ max-inline-size: stretch;+ /* This is intentionally larger than our containing block's inline-size,+ * and we expect it to be clamped by our max-inline-size specified above+ * in nearly all of this test's subtests. */+ inline-size: 55px;+ block-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-width]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces, aside from one subtest that we skip+ // for this pass), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ if (!elem.hasAttribute("skip-second-pass")) {+ elem.style.boxSizing = "border-box";+ }+ }+ checkLayout('[data-expected-width]:not([skip-second-pass])');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, form controls, float: -->+ <div class="cb">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-width="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-width="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-width="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-width="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-width="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's inline-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-width="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-width="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-width="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: column wrap">+ <div class="test" data-expected-width="55"></div>+ <div style="inline-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-columns: 35px">+ <div class="test" data-expected-width="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track:+ Here, the 'max-inline-size:stretch' doesn't get to make a difference,+ because it doesn't resolve (and hence doesn't have any clamping effect)+ during the column's intrinsic-sizing pass. So the grid column ends up+ being sized to exactly fit the *unclamped* 'inline-size'; and that+ column then establishes the containing block that we resolve the+ "max-inline-size:stretch" keyword against. This ultimately means that+ the max-inline-size happens to resolve to our unclamped inline-size,+ and hence it trivially has no clamping impact. (This also means that+ 'box-sizing' *does affect the expected size* in this subtest, unlike the+ rest of this test's subtests! So, we use a dummy attribute to opt this+ subtest out of this test's second pass, to avoid incorrectly asserting+ that our data-expected-width is still the target size when 'box-sizing'+ is tweaked.) -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-width="65" skip-second-pass></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-min-block-size-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-min-block-size-001.htmlnew file mode 100644index 00000000000..241e1e65725--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-min-block-size-001.html@@ -0,0 +1,208 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="min-block-size:stretch (setting 'min-height' in this case) resolves and clamps as expected (producing similar results as if we had specified the keyword for the block-size property)">+<style>+ .cb {+ block-size: 50px;+ inline-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-block: 5px;+ padding-inline: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the block axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-block-start: 2px;+ margin-block-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-height` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ /* We expect "min-block-size:stretch" to cause the used value of+ * "block-size" to be clamped to the "stretch" size. */+ min-block-size: stretch;+ block-size: 0;+ inline-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-height]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('[data-expected-height]');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, various form controls: -->+ <div class="cb">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-height="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-height="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-height="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-height="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-height="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's block-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-height="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block: 0;"+ data-expected-height="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-height="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 10px"+ data-expected-height="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 10px"+ data-expected-height="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-end: 55px"+ data-expected-height="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-block-start: 55px"+ data-expected-height="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-height="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-height="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: row wrap">+ <div class="test" data-expected-height="55"></div>+ <div style="block-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-rows: 35px">+ <div class="test" data-expected-height="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track: -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-height="45"></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-min-inline-size-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-min-inline-size-001.htmlnew file mode 100644index 00000000000..946148eb839--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-min-inline-size-001.html@@ -0,0 +1,208 @@+<!DOCTYPE html>+<link rel="help" href="https://drafts.csswg.org/css-sizing-4/#sizing-values">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src="../../../resources/testharness.js"></script>+<script src="../../../resources/testharnessreport.js"></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="min-inline-size:stretch (setting 'min-width' in this case) resolves and clamps as expected (producing similar results as if we had specified the keyword for the inline-size property)">+<style>+ .cb {+ inline-size: 50px;+ block-size: 40px;++ /* This margin & border are purely cosmetic and don't impact the sizing+ * calculations in this test: */+ margin: 5px;+ border: 2px solid black;++ /* This padding only comes into play for the subtests with absolutely+ * positioned children (where our padding-box forms the containing block+ * for the abspos child). */+ padding-inline: 5px;+ padding-block: 3px;++ /* We make each containing block an inline-level box, so we can display+ * subtests in multiple rows, for easier visualization: */+ display: inline-block;+ vertical-align: top;+ }++ .test {+ /* We have 2+3 = 5px of margin in the inline axis. This means the stretched+ * children should all have a border-box size that's 5px less than the+ * containing block's content-box size, i.e. 50 - 5 = 45px. */+ margin-inline-start: 2px;+ margin-inline-end: 3px;++ /* We also have some border/padding that UAs will need to account for+ * when computing the stretched children's content-box sizes; but these+ * don't reduce our `data-expected-width` expectations, since those+ * correspond to the border-box size. */+ border: 3px solid blue;+ padding: 2px;++ /* We expect "min-inline-size:stretch" to cause the used value of+ * "inline-size" to be clamped to the resolved "stretch" size. */+ min-inline-size: stretch;+ inline-size: 0;+ block-size: 20px;+ background: fuchsia;+ }+</style>+<script>+ function runTests() {+ checkLayout('[data-expected-width]');++ // Add box-sizing:border-box (which shouldn't impact the actual resolved+ // box sizes that 'stretch' produces), and retest:+ for (let elem of document.querySelectorAll(".test")) {+ elem.style.boxSizing = "border-box";+ }+ checkLayout('[data-expected-width]');+ }+</script>+<body onload="runTests()">+ <!-- 'stretch' on a block box, replaced element, form controls, float: -->+ <div class="cb">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb">+ <canvas class="test" data-expected-width="45"></canvas>+ </div>+ <div class="cb">+ <input class="test" data-expected-width="45">+ </div>+ <div class="cb">+ <textarea class="test" data-expected-width="45"></textarea>+ </div>+ <div class="cb">+ <button class="test" data-expected-width="45"></button>+ </div>+ <div class="cb">+ <div class="test" style="float: left" data-expected-width="45"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations, which use the container's+ padding-box as the area-to-fill (which in this case is 10px larger than+ the container's content-box, hence the larger 'data-expected-*'+ values vs. the previous subtests). -->+ <!-- With 0 insets, the child's margin-box fills the CB's padding-box, so+ the child's border-box should end being+ cb-padding-box-size - child-margin-size = 60px - 5px = 55px -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With auto insets, the child is placed at its static position which is+ the origin of the CB's content-box, and then 'stretch' makes it extend+ to reach the far end of the CB's padding-box. So it should be as large+ as the zero-insets case above, minus the CB's inline-start-padding+ which is 5px. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute" data-expected-width="50"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb" style="position: relative">+ <div class="test" style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on various abspos configurations in a grid: similar to+ above, but the grid area forms the containing block. -->+ <!-- Similar to zero insets case above, but just now in a grid: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline: 0;"+ data-expected-width="55"></div>+ </div>++ <!-- With no insets, we're placed at our static position which is the grid's+ padding-box origin, and then we stretch to reach the far end of its+ padding-box. So we should be as large as the zero-insets case above. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute"+ data-expected-width="55"></div>+ </div>++ <!-- When we specify an inset, the child should be as large as the+ zero-insets case above, minus whatever nonzero inset we choose. -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 10px"+ data-expected-width="45"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 10px"+ data-expected-width="45"></div>+ </div>++ <!-- If an inset pushes the child past the edge of the CB, 'stretch' shrinks+ to just the 10px needed for the child's border/padding: -->+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-end: 55px"+ data-expected-width="10"></div>+ </div>+ <div class="cb"+ style="display: inline-grid; position: relative">+ <div class="test"+ style="position: absolute; inset-inline-start: 55px"+ data-expected-width="10"></div>+ </div>++ <br>++ <!-- 'stretch' on a flex item: -->+ <div class="cb" style="display: inline-flex; flex-direction: row">+ <div class="test" data-expected-width="45"></div>+ </div>+ <div class="cb" style="display: inline-flex; flex-direction: column">+ <div class="test" data-expected-width="45"></div>+ </div>+ <!--...now with an extra-large sibling sharing the child's flex line, to be+ sure our 'stretch' sizing value resolves against the flex line's size: -->+ <div class="cb" style="display: inline-flex; flex-flow: column wrap">+ <div class="test" data-expected-width="55"></div>+ <div style="inline-size: 60px"></div>+ </div>++ <!-- 'stretch' on a grid item in a definite-size grid track: -->+ <div class="cb" style="display: inline-grid; grid-template-columns: 35px">+ <div class="test" data-expected-width="30"></div>+ </div>++ <!-- 'stretch' on a grid item in an automatically-sized grid track: -->+ <div class="cb" style="display: inline-grid">+ <div class="test" data-expected-width="45"></div>+ </div>+</body>diff --git a/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-table-001.html b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-table-001.htmlnew file mode 100644index 00000000000..f1a98fbc5a5--- /dev/null+++ b/Tests/LibWeb/Text/input/wpt-import/css/css-sizing/stretch/stretch-table-001.html@@ -0,0 +1,124 @@+<!DOCTYPE html>+<meta charset="utf-8">+<link rel="help"+ href="https://drafts.csswg.org/css-sizing-4/#stretch-fit-sizing">+<link rel="author" title="Daniel Holbert" href="mailto:[email protected]">+<script src='../../../resources/testharness.js'></script>+<script src='../../../resources/testharnessreport.js'></script>+<script src="../../../resources/check-layout-th.js"></script>+<meta name="assert"+ content="The stretch keyword should work as a block-size for table parts">+<style>+table {+ border-spacing: 0;+ margin-bottom: 3px;+}+td {+ border: 0;+ padding: 0;+}+.stretch {+ height: -webkit-fill-available;+ height: stretch;+}+.spacer {+ height: 10px;+ width: 20px;+ background: tan;+}+</style>+<body onload="checkLayout('.stretch')">+ <!-- 'stretch' on a table: -->+ <table class="stretch"+ data-expected-width="40"+ data-expected-height="10">+ <tbody>+ <tr>+ <td><div class="spacer"></div></td>+ <td><div class="spacer"></div></td>+ </tr>+ </tbody>+ </table>++ <!-- 'stretch' on a table in a fixed-height div: -->+ <div style="height: 30px">+ <table class="stretch"+ data-expected-width="40"+ data-expected-height="30">+ <tbody>+ <tr>+ <td><div class="spacer"></div></td>+ <td><div class="spacer"></div></td>+ </tr>+ </tbody>+ </table>+ </div>++ <!-- 'stretch' on a tbody: -->+ <table>+ <tbody class="stretch"+ data-expected-width="40"+ data-expected-height="10">+ <tr>+ <td><div class="spacer"></div></td>+ <td><div class="spacer"></div></td>+ </tr>+ </tbody>+ </table>++ <!-- 'stretch' on a table row: -->+ <table>+ <tbody>+ <tr class="stretch"+ data-expected-width="40"+ data-expected-height="10">+ <td><div class="spacer"></div></td>+ <td><div class="spacer"></div></td>+ </tr>+ </tbody>+ </table>++ <!-- 'stretch' on a table cell: -->+ <table>+ <tbody>+ <tr>+ <td class="stretch"+ data-expected-width="20"+ data-expected-height="10">+ <div class="spacer"></div>+ </td>+ <td><div class="spacer"></div></td>+ </tr>+ </tbody>+ </table>++ <!-- 'stretch' on a row-spanning table cell: -->+ <table>+ <tbody>+ <tr>+ <td><div class="spacer"></div></td>+ <td class="stretch"+ data-expected-width="20"+ data-expected-height="20" rowspan="2">+ <div class="spacer"></div>+ </td>+ </tr>+ <tr><td><div class="spacer"></div></td></tr>+ </tbody>+ </table>++ <!-- 'stretch' on a caption: -->+ <table>+ <caption class="stretch"+ data-expected-width="40"+ data-expected-height="10">+ <div class="spacer"></div>+ </caption>+ <tbody>+ <tr>+ <td><div class="spacer"></div></td>+ <td><div class="spacer"></div></td>+ </tr>+ </tbody>+ </table>+</body>