mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-30 00:01:50 +00:00
50168d214b
Even with the fix above, we get the caret baseline wrong because the line is non-empty, but the baseline is all the way to the top. Maybe an alternative to this would be to move the line-height hack to the beginning of layout but that sounds a bit more fishy. Otherwise we should do this more often, I suspect. I added one test that fails because of nsInlineFrame... Anyhow probably follow-up material? Depends on D73362 Differential Revision: https://phabricator.services.mozilla.com/D73363
26 lines
678 B
HTML
26 lines
678 B
HTML
<!doctype html>
|
|
<html class="reftest-wait">
|
|
<title>Caret is correctly position for block whose only child is an abspos pseudo</title>
|
|
<script src="/tests/SimpleTest/SimpleTest.js"></script>
|
|
<style>
|
|
div:focus {
|
|
outline: 3px solid blue;
|
|
}
|
|
div::before {
|
|
content: "";
|
|
/* This is the point of the test */
|
|
position: absolute;
|
|
}
|
|
</style>
|
|
<div contenteditable="true" spellcheck="false"></div>
|
|
<script>
|
|
SimpleTest.waitForFocus(function() {
|
|
document.querySelector('[contenteditable="true"]').focus();
|
|
requestAnimationFrame(function() {
|
|
requestAnimationFrame(function() {
|
|
document.documentElement.removeAttribute("class");
|
|
});
|
|
});
|
|
});
|
|
</script>
|