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

Add feature for focusable display: contents elements #24766

Merged
merged 1 commit into from
Oct 28, 2024

Conversation

ddbeck
Copy link
Collaborator

@ddbeck ddbeck commented Oct 20, 2024

Summary

Add a feature representing a specification change, where descendants of display: contents must be accessible.

Test results and supporting details

display: contents has severe accessibility issues (for example). It's difficult for web-features to generate a status for display: contents without data reflecting this fact. This PR attempts to add the data needed to accurately report support for display: contents in a non-surprising way.

Admittedly, this is a weird feature. No browser has actually shipped this "feature" yet, though there's work in progress in Chrome (Chrome Platform Status; intent to ship) and it's an Interop 2024 selection.

Alternatives considered:

  • Representing this as a partial_implementation on css.properties.display.contents itself. Advantages include more aggressively warning developers about the seriousness of display: contents as it is currently implemented. The disadvantages include trying to communicate a rather large thing as an unstructured note and that it would (wrongly) imply that browsers have implemented display: contents incorrectly or non-interoperably, when it was the spec that changed.

  • Representing this inversely as a deprecated feature (e.g., css.properties.display.contents.unfocusable_elements). This has a maintenance advantage: you get to remove this feature as irrelevant in a few years, after everyone has "removed" the old behavior. This has the disadvantage of implying that browsers have shipped some extra behavior, not that the behavior is, strictly speaking, wrong.

Links

Related issues

`display: contents` has severe accessibility issues without this feature
and web-features can't compute a (useful) status for `display: contents`
without data along these lines.
@github-actions github-actions bot added the data:css 🎨 Compat data for CSS features. https://developer.mozilla.org/docs/Web/CSS label Oct 20, 2024
Copy link
Contributor

@caugner caugner left a comment

Choose a reason for hiding this comment

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

Overall, this change is plausible to me.

@caugner caugner requested a review from Elchi3 October 25, 2024 17:34
@caugner
Copy link
Contributor

caugner commented Oct 25, 2024

Requesting a second opinion from @Elchi3.

Copy link
Member

@Elchi3 Elchi3 left a comment

Choose a reason for hiding this comment

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

Thanks Daniel, for the careful consideration of sub feature vs. partial_implementation. I think a sub feature sounds good to me here, too.

@Elchi3 Elchi3 merged commit aa4b916 into mdn:main Oct 28, 2024
5 checks passed
@ddbeck ddbeck deleted the display-contents-focusable-descendants branch October 28, 2024 14:01
This was referenced Oct 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
data:css 🎨 Compat data for CSS features. https://developer.mozilla.org/docs/Web/CSS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants