Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove aria-expanded from listbox #1862

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open

Remove aria-expanded from listbox #1862

wants to merge 1 commit into from

Conversation

smhigley
Copy link
Contributor

@smhigley smhigley commented Jan 26, 2023

Closes #1026

TL:DR; I believe the history of this is that it was added when the expandable listbox was proposed as an alternative to the ARIA 1.1 combobox pattern. Now that we have the updated combobox pattern, there doesn't seem to be any benefit to keeping aria-expanded supported on listbox.

I wasn't sure if the best approach was to remove the attribute entirely (as in this PR), or:

  • keep it in the table, but with "(deprecated)" after it, similar to the "(deprecated on this role in ARIA 1.2)" we have for former global attrs.
  • add a note in the listbox section about it being deprecated in ARIA 1.X
  • Related Core AAM Issue/PR: N/A
  • Related AccName Issue/PR: N/A
  • Related APG Issue/PR: N/A (expandable listbox example already removed)
  • Any other dependent changes? N/A

Implementation tracking


Preview | Diff

@smhigley smhigley added this to the ARIA 1.4 milestone Jan 26, 2023
@JAWS-test
Copy link
Contributor

I think for consistency with other removed attributes, it would be useful to explicitly state "deprecated" for aria-expanded as well

@spectranaut
Copy link
Contributor

Since this has approving reviews, and we talked about it in a meeting, I'm going to make issues on browsers and validators

@spectranaut spectranaut added the waiting for implementations add to traking issue when PR is merged into main, but can't be merged into stable label Feb 22, 2024
@spectranaut
Copy link
Contributor

spectranaut commented Apr 25, 2024

I'm trying to understand if this has browser implications, but I can't find in the spec anything that says user agents shouldn't expose aria attributes that are not list in the "supported states and properties" list. I wonder if I missing something...?

edit: nevermind, its in core-aam:
Some WAI-ARIA properties are not global, and are only supported on certain roles. If a non-global WAI-ARIA state or property is used where it is not supported, user agents SHOULD NOT map the given WAI-ARIA property to the platform accessibility API.

webkit-commit-queue pushed a commit to WebKit/WebKit that referenced this pull request Apr 27, 2024
…stbox

https://bugs.webkit.org/show_bug.cgi?id=273333
rdar://problem/127124652

Reviewed by Chris Fleizach.

aria-expanded was added as a supported attribute for the listbox ARIA role when the notion of an expandable listbox
was being explored. This is now unnecessary as combobox has become the canonical way to implement this pattern, and
thus the ARIA spec is removing listbox's support for aria-expanded.

w3c/aria#1862

* Source/WebCore/accessibility/AccessibilityNodeObject.cpp:
(WebCore::AccessibilityNodeObject::setNode): Deleted.
Drive-by fix to delete this unused function.
* Source/WebCore/accessibility/AccessibilityNodeObject.h:
* Source/WebCore/accessibility/AccessibilityObject.cpp:
(WebCore::AccessibilityObject::supportsExpanded const):
* LayoutTests/platform/mac/accessibility/aria-expanded-supported-roles-expected.txt:
* LayoutTests/platform/glib/accessibility/aria-expanded-supported-roles-expected.txt:

Canonical link: https://commits.webkit.org/278080@main
Copy link
Contributor

@WilcoFiers WilcoFiers left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of removing this, can it be listed as deprecated? There is nothing bad about people using this, even if there's no major benefit to it.

@spectranaut
Copy link
Contributor

Wilco's comment on the issue opened on axe: dequelabs/axe-core#4433 (comment)

@scottaohara
Copy link
Member

it's not consistently exposed now, and per the linked Webkit issue it seems support will go down.

fwiw, i'm not opposed to marking it as deprecated for 1.3 - but maybe this PR should then be the start of addressing some of the conversation of #1990 - calling out why something was deprecated / is slated for future removal.

@spectranaut
Copy link
Contributor

Discussed in https://www.w3.org/2024/05/02-aria-minutes.html#t05

The decision was to create a deprecation section in the spec, and list this attribute there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Agenda-Editors spec:aria waiting for implementations add to traking issue when PR is merged into main, but can't be merged into stable
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Revisit allowed roles for aria-expanded
8 participants