Improve float, gradient, and script rendering parity

This commit is contained in:
SGavrl committed 2026-08-04 05:37:03 +00:00
1 parent 0562fb4921
commit 03f506b01a
7 files changed
+1005 -117

No files matched your search

+8 -3
View File
@@ -939,6 +939,11 @@ fn float_flow_zone_preserves_blocks_inline_runs_and_clearance() {
#[test]
fn float_exclusion_continues_through_non_bfc_block_wrappers() {
// Chromium keeps each ordinary block's outer box at the containing
// block's full width. Only line boxes inside those blocks query the
// float-reduced available band; backgrounds and borders extend beneath
// the float. This is deliberately distinct from a new BFC, which avoids
// the float as one box.
let tree = parse_html(include_str!(
"../../../render-repros/float-bfc-continuation.html"
));
@@ -959,21 +964,21 @@ fn float_exclusion_continues_through_non_bfc_block_wrappers() {
assert!(
(lead.x - 0.0).abs() < 0.01
&& (lead.y - 0.0).abs() < 0.01
&& (lead.width - 650.0).abs() < 0.01
&& (lead.width - 900.0).abs() < 0.01
&& (lead.height - 250.0).abs() < 0.01,
"lead: {lead:?}"
);
assert!(
(heading.x - 0.0).abs() < 0.01
&& (heading.y - 250.0).abs() < 0.01
&& (heading.width - 650.0).abs() < 0.01
&& (heading.width - 900.0).abs() < 0.01
&& (heading.height - 50.0).abs() < 0.01,
"heading: {heading:?}"
);
assert!(
(beside.x - 0.0).abs() < 0.01
&& (beside.y - 300.0).abs() < 0.01
&& (beside.width - 650.0).abs() < 0.01
&& (beside.width - 900.0).abs() < 0.01
&& (beside.height - 100.0).abs() < 0.01,
"beside: {beside:?}"
);