mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-05 07:41:01 +00:00
LibWeb: Compute accessible names for hidden/hidden-but-referenced nodes
This change implements full support for the “A. Hidden Not Referenced” step at https://w3c.github.io/accname/#step2A in the “Accessible Name and Description Computation” spec — including handling all hidden nodes that must be ignored, as well as handling hidden nodes that, for the purposes of accessible-name computation, must not be ignored (due to having aria-labelledby/aria-describedby references from other nodes). Otherwise, without this change, not all cases of hidden nodes get ignored as expected, while cases of nodes that are hidden but that have aria-labelledby/aria-describedby references from other nodes get unexpectedly ignored.
This commit is contained in:
parent
c00b97a1f0
commit
314e5d6bb7
Notes:
github-actions[bot]
2024-11-29 12:19:31 +00:00
Author: https://github.com/sideshowbarker
Commit: 314e5d6bb7
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2294
Reviewed-by: https://github.com/AtkinsSJ
Reviewed-by: https://github.com/gmta
Reviewed-by: https://github.com/yyny
7 changed files with 489 additions and 21 deletions
|
@ -348,6 +348,12 @@ public:
|
|||
|
||||
virtual bool include_in_accessibility_tree() const override;
|
||||
|
||||
bool is_hidden() const;
|
||||
bool has_hidden_ancestor() const;
|
||||
|
||||
bool is_referenced() const;
|
||||
bool has_referenced_and_hidden_ancestor() const;
|
||||
|
||||
void enqueue_a_custom_element_upgrade_reaction(HTML::CustomElementDefinition& custom_element_definition);
|
||||
void enqueue_a_custom_element_callback_reaction(FlyString const& callback_name, GC::MarkedVector<JS::Value> arguments);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue