LibWeb: Fix accessible-name computation for pseudo-element content

This change fixes handling for substep ii of the “F. Name From Content”
step at https://w3c.github.io/accname/#step2F in the “Accessible Name
and Description Computation” spec — to correctly include any ::before
and ::after pseudo-element content in the computation of accessible
names. Otherwise, without this change, accessible names unexpectedly
don’t include that pseudo-element content.
This commit is contained in:
sideshowbarker 2024-11-04 14:47:55 +09:00 committed by Andrew Kaster
commit b1587cc60f
Notes: github-actions[bot] 2024-11-11 21:58:09 +00:00
3 changed files with 24 additions and 14 deletions

View file

@ -330,7 +330,7 @@ struct ContentData {
// FIXME: Data is a list of identifiers, strings and image values.
String data {};
String alt_text {};
Optional<String> alt_text {};
};
struct CounterData {