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

Inline proposals needs accessibility love #125294

Closed
hediet opened this issue Jun 2, 2021 · 3 comments
Closed

Inline proposals needs accessibility love #125294

hediet opened this issue Jun 2, 2021 · 3 comments
Assignees
Labels
accessibility Keyboard, mouse, ARIA, vision, screen readers (non-specific) issues inline-completions
Milestone

Comments

@hediet
Copy link
Member

hediet commented Jun 2, 2021

Feedback from @isidorn:

Here are some suggestion on how to improve the accessibility of the inline propsals:

  1. Once you are on an inline proposal pressing Ctrl + K, Ctrl + I, triggers the hover and moves focus into it -> very cool. However it would be nice if the left and right keybindings would move focus inside the hover on the actions. So that keyboard users can easily trigger the hover and use left and right to move the suggestion.
  2. Bonus on top of that when Ctrl + K, Ctrl + I is triggered we should remember the previously focused element so it is focused again
  3. Once an inline suggestion is shown we should probably use an aria alert to notify the user. Something like: suggestion: CONTENT. This is not the best experience but I think might be a good start. We do a similar things for parameter hints

Once we polish this a bit and there is a public way to try this out we should definitely share it with our a11y community to get better feedback.

@hediet hediet added bug Issue identified by VS Code Team member as probable bug accessibility Keyboard, mouse, ARIA, vision, screen readers (non-specific) issues inline-completions labels Jun 2, 2021
@hediet hediet added this to the May 2021 milestone Jun 2, 2021
@hediet hediet self-assigned this Jun 2, 2021
@hediet hediet added feature-request Request for new features or functionality and removed bug Issue identified by VS Code Team member as probable bug labels Jun 3, 2021
@hediet
Copy link
Member Author

hediet commented Jun 3, 2021

I'm moving this to next milestone.

Accessibility is important to me, but the actions are already focusable if "Tab Moves Focus" and "Screen Reader Optimized" are enabled.
I have to admit though, that tabbing through all the actions every time is inconvenient.

However, all those actions already have their own shortcut (which can be triggered even if the hover is not shown). So once you tab through them and the shortcut is read, there is already a more convenient way to access those actions than using the arrow keys.

What do you think, @isidorn?

@hediet hediet modified the milestones: May 2021, June 2021 Jun 3, 2021
@isidorn
Copy link
Contributor

isidorn commented Jun 4, 2021

All good points. And of course doing this in the next milestone is perfectly fine.

I think users will have to learn those shortcuts and when they do they will no longer need to focus on the inline proposals hover.
However in order to learn them they should still be able to nicely focus on the hover initially.

So from my above I think that 1. would still be great to have!
3. we need either way in order for the proposals to be read out.

So bottom line while I agree with you, I think your points do not contradict the original suggestion.
Though I agree that 2. is less important (since users will probably remember shortcut and not refocus the hover that often)

@hediet hediet modified the milestones: June 2021, July 2021 Jul 1, 2021
@alexr00 alexr00 modified the milestones: July 2021, August 2021 Jul 30, 2021
@hediet
Copy link
Member Author

hediet commented Aug 11, 2021

For 1., there is #130562 as a general feature request for all hovers.

Regarding 2, I think the focus should not be restored to the element that had focus the last time - otherwise, screenreaders might not catch up relevant text at the beginning of the hover.

For 3, see #130565.
A pull approach has been implemented as fix for #129677.

@hediet hediet closed this as completed Aug 11, 2021
@hediet hediet removed the feature-request Request for new features or functionality label Aug 11, 2021
@github-actions github-actions bot locked and limited conversation to collaborators Sep 25, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
accessibility Keyboard, mouse, ARIA, vision, screen readers (non-specific) issues inline-completions
Projects
None yet
Development

No branches or pull requests

3 participants