Files
firefox/testing/web-platform/tests/css/css-ruby/pseudo-first-line.html
Kent Tamura 22dd6ca6af Bug 1896317 [wpt PR 46220] - RubyLB: ::first-line style should not be applied to all rubies, a=testonly
Automatic update from web-platform-tests
RubyLB: ::first-line style should not be applied to all rubies

Sub-LineBreakers always referred to InlineItems for ::first-line
incorrectly because the constructor for them don't have an
InlineBreakToken.

This CL fixes it by passing the parent LineBreaker through
SetInputRange(), then PrepareNextLine() updates items_data_.

Bug: 324111880
Change-Id: I1c19b727335fb1b636f731b58155789b60480c09
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/5528710
Reviewed-by: Koji Ishii <[email protected]>
Auto-Submit: Kent Tamura <[email protected]>
Commit-Queue: Koji Ishii <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1299875}

--

wpt-commits: b9491b534cb1a6991c5afaf65fc4960e55c506b4
wpt-pr: 46220
2024-05-21 09:46:48 +00:00

16 lines
446 B
HTML

<!DOCTYPE html>
<link rel="help" href="https://drafts.csswg.org/css-ruby/#placement">
<link rel="help" href="https://drafts.csswg.org/css-pseudo/#first-line-styling">
<link rel="match" href="pseudo-first-line-ref.html">
<style>
div::first-line {
ruby-position: under;
color: orange;
}
ruby::first-line, rt::first-line {
color: red;
}
</style>
<div>foo <ruby>base<rt>annotation</rt></ruby><br>
bar <ruby>base<rt>annotation</rt></ruby></div>