layout: Add support for text-align-last (#30905)

This change adds support for `text-align-last` as well as ensuring that
it also applies to lines before forced line breaks. Two tests start to
fail because they rely on right-to-left text to pass:

 - /css/css-text/text-align/text-align-last-010.html.ini
 - /css/css-text/text-align/text-align-last-011.html.ini
This commit is contained in:
Martin Robinson 2023-12-21 15:45:34 +01:00 committed by GitHub
parent d007d265bd
commit 74798c4b7b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
36 changed files with 37 additions and 544 deletions

View file

@ -14,9 +14,6 @@
[Property hyphens inherits]
expected: FAIL
[Property text-align-last inherits]
expected: FAIL
[Property hyphens has initial value manual]
expected: FAIL
@ -29,9 +26,6 @@
[Property text-align-all inherits]
expected: FAIL
[Property text-align-last has initial value auto]
expected: FAIL
[Property line-break has initial value auto]
expected: FAIL

View file

@ -23,27 +23,5 @@
[Property text-align-last value 'left' computes to 'left']
expected: FAIL
[Property text-align-last value 'end']
expected: FAIL
[Property text-align-last value 'center']
expected: FAIL
[Property text-align-last value 'auto']
expected: FAIL
[Property text-align-last value 'start']
expected: FAIL
[Property text-align-last value 'right']
expected: FAIL
[Property text-align-last value 'left']
expected: FAIL
[Property text-align-last value 'match-parent']
expected: FAIL
[Property text-align-last value 'justify']
expected: FAIL

View file

@ -1,25 +1,3 @@
[text-align-last-valid.html]
[e.style['text-align-last'\] = "match-parent" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "right" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "center" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "auto" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "left" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "justify" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "end" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "start" should set the property value]
expected: FAIL

View file

@ -1,67 +1,4 @@
[text-align-last-interpolation.html]
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (-0.3) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (0) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (0.3) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (0.5) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (0.6) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (1) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (1.5) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (-0.3) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (0) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (0.3) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (0.5) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (0.6) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (1) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (1.5) should be [start\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (-0.3) should be [auto\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (0) should be [auto\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (0.3) should be [auto\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (0.5) should be [start\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (0.6) should be [start\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (1) should be [start\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (1.5) should be [start\]]
expected: FAIL
[Web Animations: property <text-align-last> from [auto\] to [start\] at (-0.3) should be [auto\]]
expected: FAIL
@ -83,69 +20,6 @@
[Web Animations: property <text-align-last> from [auto\] to [start\] at (1.5) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (-0.3) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (0) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (0.3) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (0.5) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (0.6) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (1) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (1.5) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (-0.3) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (0) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (0.3) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (0.5) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (0.6) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (1) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (1.5) should be [center\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (-0.3) should be [justify\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (0) should be [justify\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (0.3) should be [justify\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (0.5) should be [center\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (0.6) should be [center\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (1) should be [center\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (1.5) should be [center\]]
expected: FAIL
[Web Animations: property <text-align-last> from [justify\] to [center\] at (-0.3) should be [justify\]]
expected: FAIL
@ -167,69 +41,6 @@
[Web Animations: property <text-align-last> from [justify\] to [center\] at (1.5) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (-0.3) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (0) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (0.3) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (0.5) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (0.6) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (1) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (1.5) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (-0.3) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (0) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (0.3) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (0.5) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (0.6) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (1) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (1.5) should be [right\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (-0.3) should be [left\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (0) should be [left\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (0.3) should be [left\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (0.5) should be [right\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (0.6) should be [right\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (1) should be [right\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (1.5) should be [right\]]
expected: FAIL
[Web Animations: property <text-align-last> from [left\] to [right\] at (-0.3) should be [left\]]
expected: FAIL

View file

@ -1,2 +0,0 @@
[block-in-inline-align-last-001.html]
expected: FAIL

View file

@ -29,12 +29,6 @@
[Property text-align-all inherits]
expected: FAIL
[Property text-align-last has initial value auto]
expected: FAIL
[Property text-align-last inherits]
expected: FAIL
[Property text-wrap has initial value wrap]
expected: FAIL

View file

@ -1,24 +1,3 @@
[text-align-last-computed.html]
[Property text-align-last value 'auto']
expected: FAIL
[Property text-align-last value 'start']
expected: FAIL
[Property text-align-last value 'end']
expected: FAIL
[Property text-align-last value 'left']
expected: FAIL
[Property text-align-last value 'right']
expected: FAIL
[Property text-align-last value 'center']
expected: FAIL
[Property text-align-last value 'justify']
expected: FAIL
[Property text-align-last value 'match-parent']
expected: FAIL

View file

@ -1,24 +1,3 @@
[text-align-last-valid.html]
[e.style['text-align-last'\] = "auto" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "start" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "end" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "left" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "right" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "center" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "justify" should set the property value]
expected: FAIL
[e.style['text-align-last'\] = "match-parent" should set the property value]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-center-last-center.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-center-last-end.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-center-last-justify.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-center-last-start.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-end-last-center.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-end-last-end.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-end-last-justify.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-end-last-start.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-justify-last-center.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-justify-last-end.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-justify-last-justify.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-justify-last-start.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[text-align-last-010.html]
expected: FAIL

View file

@ -0,0 +1,2 @@
[text-align-last-011.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-last-center.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-last-end.html]
expected: FAIL

View file

@ -1,67 +1,4 @@
[text-align-last-interpolation.html]
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (-0.3) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (0) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (0.3) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (0.5) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (0.6) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (1) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [auto\] to [start\] at (1.5) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (-0.3) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (0) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (0.3) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (0.5) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (0.6) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (1) should be [start\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [auto\] to [start\] at (1.5) should be [start\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (-0.3) should be [auto\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (0) should be [auto\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (0.3) should be [auto\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (0.5) should be [start\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (0.6) should be [start\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (1) should be [start\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [auto\] to [start\] at (1.5) should be [start\]]
expected: FAIL
[Web Animations: property <text-align-last> from [auto\] to [start\] at (-0.3) should be [auto\]]
expected: FAIL
@ -83,69 +20,6 @@
[Web Animations: property <text-align-last> from [auto\] to [start\] at (1.5) should be [start\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (-0.3) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (0) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (0.3) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (0.5) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (0.6) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (1) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [justify\] to [center\] at (1.5) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (-0.3) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (0) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (0.3) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (0.5) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (0.6) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (1) should be [center\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [justify\] to [center\] at (1.5) should be [center\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (-0.3) should be [justify\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (0) should be [justify\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (0.3) should be [justify\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (0.5) should be [center\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (0.6) should be [center\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (1) should be [center\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [justify\] to [center\] at (1.5) should be [center\]]
expected: FAIL
[Web Animations: property <text-align-last> from [justify\] to [center\] at (-0.3) should be [justify\]]
expected: FAIL
@ -167,69 +41,6 @@
[Web Animations: property <text-align-last> from [justify\] to [center\] at (1.5) should be [center\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (-0.3) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (0) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (0.3) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (0.5) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (0.6) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (1) should be [right\]]
expected: FAIL
[CSS Transitions: property <text-align-last> from [left\] to [right\] at (1.5) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (-0.3) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (0) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (0.3) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (0.5) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (0.6) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (1) should be [right\]]
expected: FAIL
[CSS Transitions with transition: all: property <text-align-last> from [left\] to [right\] at (1.5) should be [right\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (-0.3) should be [left\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (0) should be [left\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (0.3) should be [left\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (0.5) should be [right\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (0.6) should be [right\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (1) should be [right\]]
expected: FAIL
[CSS Animations: property <text-align-last> from [left\] to [right\] at (1.5) should be [right\]]
expected: FAIL
[Web Animations: property <text-align-last> from [left\] to [right\] at (-0.3) should be [left\]]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-last-justify.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-last-simple.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-last-start.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-last-wins-001.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-start-last-center.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-start-last-end.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-start-last-justify.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-align-start-last-start.html]
expected: FAIL

View file

@ -1,2 +0,0 @@
[text-justify-inter-word-001.html]
expected: FAIL