diff options
author | bptato <nincsnevem662@gmail.com> | 2024-10-15 17:01:28 +0200 |
---|---|---|
committer | bptato <nincsnevem662@gmail.com> | 2024-10-15 17:01:28 +0200 |
commit | 1cac5ae3ce2286b8fc7a591a26e5a0cc3e4f775a (patch) | |
tree | c5da2749ea87a4f745d9238eded5fdd6d46fd623 /test/layout | |
parent | e7f61dc70169a72dcdf8b50e135505bdbbfa9217 (diff) | |
download | chawan-1cac5ae3ce2286b8fc7a591a26e5a0cc3e4f775a.tar.gz |
layout: fix float positioning in inline contexts
also fixes a bug in the previous commit where whitespacenum would be reset on absolute positioning + missing absolute margin handling without top/left/etc.
Diffstat (limited to 'test/layout')
-rw-r--r-- | test/layout/float-in-inline-context.expected | 1 | ||||
-rw-r--r-- | test/layout/float-in-inline-context.html | 1 | ||||
-rw-r--r-- | test/layout/position-absolute-block-in-inline.color.expected | 2 | ||||
-rw-r--r-- | test/layout/position-absolute-margins.expected | 3 | ||||
-rw-r--r-- | test/layout/position-absolute-margins.html | 12 |
5 files changed, 18 insertions, 1 deletions
diff --git a/test/layout/float-in-inline-context.expected b/test/layout/float-in-inline-context.expected new file mode 100644 index 00000000..c82fe107 --- /dev/null +++ b/test/layout/float-in-inline-context.expected @@ -0,0 +1 @@ +lefttesting after diff --git a/test/layout/float-in-inline-context.html b/test/layout/float-in-inline-context.html new file mode 100644 index 00000000..05add44d --- /dev/null +++ b/test/layout/float-in-inline-context.html @@ -0,0 +1 @@ +testing <div style="float: left">left</div> after diff --git a/test/layout/position-absolute-block-in-inline.color.expected b/test/layout/position-absolute-block-in-inline.color.expected index 226cd8eb..b1763fb8 100644 --- a/test/layout/position-absolute-block-in-inline.color.expected +++ b/test/layout/position-absolute-block-in-inline.color.expected @@ -1,6 +1,6 @@ [48;2;255;0;0mabsolute 1[49m line two[48;2;255;0;0mabsolute 2[49m [48;2;0;0;255mabsolute 3[49m -line four +line four [38;2;109;109;109m[48;2;255;255;0mabsolute 4[39m[49m diff --git a/test/layout/position-absolute-margins.expected b/test/layout/position-absolute-margins.expected new file mode 100644 index 00000000..398aea9d --- /dev/null +++ b/test/layout/position-absolute-margins.expected @@ -0,0 +1,3 @@ +test + with top/left + without top/left diff --git a/test/layout/position-absolute-margins.html b/test/layout/position-absolute-margins.html new file mode 100644 index 00000000..e558a8c0 --- /dev/null +++ b/test/layout/position-absolute-margins.html @@ -0,0 +1,12 @@ +<!DOCTYPE html> +<style> +* { +margin: 0; padding: 0; +</style> +test +<div style="position: absolute; top: 0; left: 0; margin-left: 1ch; margin-top: 1em"> +with top/left +</div> +<div style="position: absolute; margin-left: 1ch; margin-top: 1em"> +without top/left +</div> |