[css-text] Test text-align: match-parent on the root element#30175
Conversation
fb5229b to
eae5a5a
Compare
|
@zcorpan There's already a test for this: css/css-text/text-align/text-align-match-parent-root-rtl.html It was in mozilla vendor-imports then was moved to the main test suite. |
|
Wait, I guess not, this tests the computed style. |
nt1m
left a comment
There was a problem hiding this comment.
The test name could clarify that it's about the computed value.
7694a91 to
94c54b0
Compare
|
@nt1m thanks, fixed. |
|
Maybe this could be named "text-align-match-parent-root-rtl-computed.html" to be consistent with the text-align-match-parent-root-rtl.html test. Regarding the test that was renamed to "match-parent-001.html", can things be consistent with the rest of the match-parent tests: https://wpt.fyi/results/css/css-text/text-align?label=master&label=experimental&aligned&q=text-align-match-parent- ? The other tests could be renamed. |
Co-authored-by: Florian Rivoal <[email protected]>
If I understand correctly, a used value of 'direction: rtl' on the root element is propagated to the ICB per https://drafts.csswg.org/css-writing-modes-3/#icb
Then, https://drafts.csswg.org/css-text/#valdef-text-align-match-parent says
The initial value of text-align is 'start', so I guess the inherited value for the root element has to be 'start'. Therefore, it looks at the 'direction' of the ICB, which is propagated from the root element, and is thus 'rtl'. Therefore text-align should compute to 'right'.