ladybird/Tests/LibWeb/Text/expected/Editing/execCommand-insertLinebreak.txt
Jelle Raaijmakers 295b78f7d3 LibWeb: Do not rely on the layout tree for collapsed line breaks
The editing command that relies the most on this, `insertLinebreak`,
did not perform a layout update after inserting a `<br>` which caused
this algorithm to always return false. But instead of actually building
the layout tree needlessly, we can check the DOM tree instead.
2025-05-01 15:44:26 +03:00

11 lines
269 B
Text

Before: "foobar"
After: "foo<br>bar"
Before: "<p style="white-space: pre">foobar</p>"
After: "<p style="white-space: pre">foo
bar</p>"
Before: "<p style="white-space: pre">foobar</p>"
After: "<p style="white-space: pre">foobar
</p>"
Before: "foo"
After: "foo<br><br>"