Skip to content

Implement proposed Focus Traversal API #4784

Open

Description

@arei

Implement the proposed Focus Traversal API as explained here: https://github.com/awesomeeng/FocusTraversalAPI/blob/master/EXPLAINER.md

and discussed here: https://discourse.wicg.io/t/proposal-focus-traversal-api/3427

additional details and a sample polyfill can be found here: https://github.com/awesomeeng/FocusTraversalAPI

Activity

  1. domenic commented on Jul 17, 2019

    @domenic
    Member

    It's a bit unclear what this issue is about. Are you hoping to merge your spec into the HTML Standard? Or did you mean to file this on the implementer bug trackers instead, asking them to implement your spec?

  2. arei commented on Jul 17, 2019

    @arei
    Author

    @domenic I am proposing adding this to the spec with the end result getting it implemented across browsers. I am happy to undertake whatever steps are necessary to make this happen, but am completely at a loss as to what they are. As you can see, it was proposed to the WICG but I largely think that is ignored.

  3. arei commented on Jul 17, 2019

    @arei
    Author

    I am also very open to suggestions, discussion, changes, comments, etc.

  4. domenic commented on Jul 17, 2019

    @domenic
    Member

    Ah, OK. Well, the thing is, the working mode for the HTML Standard is kind of the opposite of that. Putting things in the spec doesn't somehow force browsers to implement them. Instead, we work together to gain browser interest and implementations, and then formalize them in the spec. You can learn more at https://whatwg.org/working-mode, in particular https://whatwg.org/working-mode#additions. https://whatwg.org/faq#adding-new-features may also be helpful.

    In general, large features like this work best if incubated in a venue like the WICG, then implemented in at least one browser and gathering 2+ browser interest in implementing, and then we merge them in to the HTML Standard. So I think most of the work is still on you engaging browser vendors to see if they are interested in implementing your proposal.

    Hope this helps!

  5. arei commented on Jul 18, 2019

    @arei
    Author
  6. arei commented on Aug 6, 2019

    @arei
    Author

    I'll be speaking about the Focus Traversal API Proposal at JSCONF US 2019 next week (August 12 2019 @2:15pm, Track B). Hope to see some of you out there and talk more about making focus better!

    https://2019.jsconf.us/speakers/glen-goodwin

  7. MisterSincere commented on Apr 22, 2026

    @MisterSincere

    Old issue I know, but:
    During my work I stumble a lot over these issues. I am developing custom web components, which can have custom components again in their slot and so on. Implementing a keyboard navigation compliant to for example a menubar or a simple dropdown to the likes of a WAI pattern is tedious. Maybe I am missing something but the need of basically parsing the DOM myself feels ugly and useless since simply pressing Tab seems to know exactly what the next element to focus is.
    Furthermore sth like a shadow DOM makes document.activeElement completely useless. Maybe the opinion is that everyone should implement this themselves, but I feel like there is a huge use-case for this and the current focus system seems more robust and capable than what most would implement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions