A11y Bug 6210624: Keyboard focus and arrow key navigation in location dropdown#653
Conversation
Agent-Logs-Url: https://github.com/OneNoteDev/WebClipper/sessions/a4bc18dd-5306-49f5-accf-24b9644af25c Co-authored-by: KethanaReddy7 <257986085+KethanaReddy7@users.noreply.github.com>
|
@copilot the keyboard focus is falling inside its only working with Tab keys and not Arrow keys. Can you please fix this |
Agent-Logs-Url: https://github.com/OneNoteDev/WebClipper/sessions/029fac6a-7d39-4214-b537-4cab9afd25e1 Co-authored-by: KethanaReddy7 <257986085+KethanaReddy7@users.noreply.github.com>
Fixed in commit |
|
@copilot I'm able to navigate through sections using up and down arrow key but navigation through notebooks using up and down arrow keys is not working. I am able to navigate through the notebooks if i only open the prev notebook sections. Can you fix this |
Agent-Logs-Url: https://github.com/OneNoteDev/WebClipper/sessions/cd89f9f3-38d1-4b38-b360-6bc769e5bbbf Co-authored-by: KethanaReddy7 <257986085+KethanaReddy7@users.noreply.github.com>
Fixed in commit The fix filters focusable items to only visible ones — specifically, items whose |
…cation-dropdown-keyboard-focus
fb7808e
into
user/kpeddireddy/LocationButtonTab
When the location dropdown is expanded via keyboard, focus remains on the trigger button instead of moving to the currently selected section item. Additionally, the OneNotePicker library only handles Enter/Tab key events — there is no Up/Down arrow key navigation in the popup list, leaving keyboard users unable to navigate between sections or notebooks using arrow keys.
Changes
sectionPicker.tsx—onPopupToggle: When the popup opens, schedules asetTimeout(0)callback (to allow DOM render) that:curSectionId. Falls back to the first keyboard-navigable item in#sectionPickerContainerif no selected element is found.keydownlistener on#sectionPickerContainerfor Up/Down arrow key navigation. The listener finds all visible keyboard-navigable items in the popup and moves focus to the previous (Up) or next (Down) item relative to the currently focused element. Adata-arrow-key-handler-attachedattribute guards against duplicate listeners.Demo:
https://github.com/user-attachments/assets/b66fb057-5e67-42ab-a743-22cd4286a7f5