这是indexloc提供的服务,不要输入任何密码
Skip to content

Ensure that elements mimicking buttons are focusable and keyboard accessible #1184

@k0ndratov

Description

@k0ndratov

Hi there!

In the current layout of some elements, such as buttons in the "View pull requests" dropdown menu, styles are applied to make them look like buttons, but in the HTML markup, they are not actual button elements (e.g., they might be div or span). This creates an accessibility issue, as these elements cannot be focused using the keyboard, making it more difficult for users who rely on keyboard navigation to interact with the interface.

This issue starts to create even bigger problems if you are using Vimium. Due to layout issues, there is no way to close the pop-up window using the keyboard

Steps to reproduce:

Open the "View pull requests" dropdown menu.
Try to focus on the close element using the "Tab" key.
Notice that the element cannot be focused and is not accessible for keyboard navigation.
Expected result: All elements that look like buttons should be elements or have appropriate attributes (e.g., role="button") and should be focusable and interactable with the keyboard.

Suggested solution:

Replace elements that mimic buttons with actual

elements or add necessary accessibility attributes (e.g., tabindex="0" and role="button").
Ensure that all interactive elements are keyboard accessible and can be activated via keyboard.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions