Closed Bug 1789378 Opened 2 years ago Closed 2 years ago

[CTW] Implement IAccessibleAction (AKA NVDA doesn't render empty div elements with onclick attribute)

Categories

(Core :: Disability Access APIs, defect)

Firefox 106
defect

Tracking

()

RESOLVED FIXED
107 Branch
Tracking Status
firefox107 --- fixed

People

(Reporter: grishakonzalaev, Assigned: Jamie, NeedInfo)

References

(Blocks 1 open bug)

Details

(Whiteboard: [ctw-m3])

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:106.0) Gecko/20100101 Firefox/106.0

Steps to reproduce:

  1. Go to site contains this divs.
  2. navigate up and down arrows in this site.

Actual results:

Screenreader must navigate to empty line, when focus on this div, but element skips.

Expected results:

Focus of screenreader must navigate to this divs. This behavior observed in latest release version of Firefox.
Example of this div:
<div class="left_settings" onclick="menuSettings(0)">
<div class="left_settings_inner"></div>
</div>

Setting this to Core: Disability Access APIs, if this is not the right component, please move it to a more suitable one. Thanks!

Component: Untriaged → Disability Access APIs
Product: Firefox → Core

Firefox does expose the div in the tree. Screen readers may choose to ignore it though if it contains no text and nothing else of semantic relevance. NVDA ignores the clickable div in your example because they have a width and height of 0, but even with a non-0 width/height, they will still get ignored because they have no text and no other semantics. Any change there would need to be made in NVDA.

Status: UNCONFIRMED → RESOLVED
Closed: 2 years ago
Resolution: --- → WORKSFORME

Firefox without cache the world and same version of NVDA don't ignores this div. This is the cache the world's bug. Not NVDA.

I just tested with Cache the World disabled and I can't reproduce the issue with your test case. Could you provide an example of a site where this reproduces? Thanks.

Flags: needinfo?(grishakonzalaev)

It's vk.com on news page. Left menu.
https://vk.com/feed
registration is required to test it.

Flags: needinfo?(grishakonzalaev)

Ah. I figured it out.

STR:

  1. Open this test case:
    data:text/html,<p>before</p><div onclick="alert('clicked');" style="width: 5px; height: 5px;"></div><p>after</p>
  2. Press control+home to go to the top of the document.
    • Observe: NVDA says "before"
  3. Press down arrow.
    • Expected: NVDA says "blank"
    • Actual: NVDA says "after"

The reason is that we don't implement IAccessibleAction with CTW. NVDA vbufs depend on this to determine whether the element is clickable (and thus interactive).

Assignee: nobody → jteh
Status: RESOLVED → REOPENED
Ever confirmed: true
Resolution: WORKSFORME → ---
Summary: Firefox Nightly: cache the world don't shows empty div elements with onclick attribute in accessibility tree → [CTW] Implement IAccessibleAction (AKA NVDA doesn't render empty div elements with onclick attribute)
Blocks: a11y-ctw
Whiteboard: [ctw-m3]
Severity: -- → S3
Pushed by jteh@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/cca06f0c2bad Support IAccessibleAction for cached RemoteAccessible. r=morgan
Status: REOPENED → RESOLVED
Closed: 2 years ago2 years ago
Resolution: --- → FIXED
Target Milestone: --- → 107 Branch
Flags: qe-verify+

Hi @James, I tried tp verify this fix by using these steps :

Open this test case:
data:text/html,<p>before</p><div onclick="alert('clicked');" style="width: 5px; height: 5px;"></div><p>after</p>
Press control+home to go to the top of the document.
Observe: NVDA says "before"
Press down arrow.
Expected: NVDA says "blank"
Actual: NVDA says "after"

but I always get the same behavior :
Hitting Ctrl Home will reach the top of the document and NVDA will say Before
Hitting Down arrow once - it will always say Clickable
Hitting Down arrow again - it will say After

Ive tested this issue in Our latest builds as well as older builds and Im always getting the same result, am I missing something ?

Flags: needinfo?(jteh)

Thanks for testing. You're missing just one step which I realise isn't clear from this bug: you need to set accessibility.cache.enabled to true in about:config, then restart Firefox.

Flags: needinfo?(jteh)

I did set accessibility.cache.enabled - true in about config and after a restart this test case : data:text/html,<p>before</p><div onclick="alert('clicked');" style="width: 5px; height: 5px;"></div><p>after</p>

will always say Before > Clickable > After.

Im trying on Windows 10 with NVDA enabled.

Flags: needinfo?(jteh)
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: