-
Notifications
You must be signed in to change notification settings - Fork 29.9k
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
Accessibility improvements for finding in files #69741
Comments
this one is a bug we should fix.
IMO We need to provide more hints for screen reader when we reach the last item in the document, and users can be aware that the next search will go back to the top of the document. To allow users disable this feature, we have a tracking item #28666 , we can introduce a setting if it doesn't make sense to some users. |
@rebornix I think that having better alerts when focus moves when moving to the next/previous result would be sufficient; if I was at 3/3 and suddenly it says 1/3, then I know its moved. Another possibility is to play the system bell sound every time focus is wrapped back to the top. Regarding the proposed format of the alert, I think it can be condensed to "1/2: Found 'world' at line 9:20: ". |
@rebornix can you maybe provide a code pointer for this. So we could add a help-wanted, or I might look into this if I find time. |
@isidorn thanks for the ping. The code change is intuitive by leveraging Firstly, we listen to find results change in https://github.com/microsoft/vscode/blob/master/src/vs/editor/contrib/find/findWidget.ts#L324 and update labels when search results count change. So we can alert the status at the same position. Secondly, for the message format, we can follow Search Viewlet ones but less verbose as suggested by @Neurrone . vscode/src/vs/workbench/contrib/search/browser/searchView.ts Lines 1319 to 1335 in 579966f
|
@rebornix Great. Thanks for the pointers. Let's see if some user jumps on this. |
@georgebatalinski thanks for being interested. Feel free to provide a PR. @rebornix provided nice code pointers. |
@isidorn this is my first guess at the issue - let me know your thoughts
|
@georgebatalinski thanks! I will comment in the PR directly. |
The PR is already merged. |
@georgebatalinski this is such a massive quality of life improvement and does exactly what I would expect, thanks a lot! |
Issue Type: Bug
CC: @isidorn
Hi,
Some parts of the workflow for searching within a file with ctrl+f aren't that accessible. As a demonstration, have a blank editor with the following contents:
From the top of the file, when pressing ctrl+f and typing
world
, visually the first occurance is highlighted, but no screen reader feedback is provided at all. So my instinct is to press enter, which of course brings me to the second match instead.Next when on the second line, perform the same search. By default, it wraps you back to the beginning of the file if no more matches are found, which is doubly confusing due to the lack of feedback.
I expect to hear something similar to how its announced in the results view in project-wide search, but less verbose. E.g, "1/2: Found 'world' at 9:20 with text: "
Similar context should also be provided when moving using f3 and shift+f3, but haven't figured out what the best messages would be.
On a related note, I'm also pondering whether disabling such wrap-around by default if a screen reader is detected would be better. It is obvious that this has happened visually, but unless enough context is provided, it can be confusing.
VS Code version: Code - Insiders 1.32.0-insider (804373a, 2019-03-01T18:22:35.336Z)
OS version: Windows_NT x64 10.0.17134
System Info
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: disabled_software
rasterization: enabled
surface_synchronization: enabled_on
video_decode: enabled
webgl: enabled
webgl2: enabled
Extensions (7)
The text was updated successfully, but these errors were encountered: