Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Autocomplete[a11y]: Update focus order for search bar on homepage, stops summary, retail sales location tool#3093

Merged
lvachon1 merged 5 commits intomainmbta/dotcom:mainfrom
lev/a11y/search_tab_ordermbta/dotcom:lev/a11y/search_tab_orderCopy head branch name to clipboard
Apr 13, 2026
Merged

Autocomplete[a11y]: Update focus order for search bar on homepage, stops summary, retail sales location tool#3093
lvachon1 merged 5 commits intomainmbta/dotcom:mainfrom
lev/a11y/search_tab_ordermbta/dotcom:lev/a11y/search_tab_orderCopy head branch name to clipboard

Conversation

@lvachon1
Copy link
Copy Markdown
Contributor

@lvachon1 lvachon1 commented Apr 8, 2026

Scope

Asana Ticket: ♿ Update focus order for search bar on homepage, stops summary, retail sales location tool

Implementation

Added some JS to rearrange the items in the search bar to reflect the way they are arranged visually. We use CSS to rearrange things, but that doesn't affect tab order. This updates the HTML so that tab order behaves as expected.

Fun fact: appendChild() will not create duplicates, it will move the element instead

Screenshots

Main header and stop overview autocomplete tab order:

Screen.Recording.2026-04-08.at.1.55.46.PM.mov

Retail Sales Locations autocomplete tab order

Screen.Recording.2026-04-08.at.1.56.28.PM.mov

How to test

Check the autocomplete tab order in the main header and on the following pages, ensure it aligns with the visuals:

Compare and contrast with dev/prod where the search icon is focused first among the autocomplete elements despite being last in the layout.

http://localhost:4001/stops/subway
http://localhost:4001/fares/retail-sales-locations

@lvachon1 lvachon1 requested a review from a team as a code owner April 8, 2026 18:02
@lvachon1 lvachon1 requested a review from thecristen April 8, 2026 18:02
Copy link
Copy Markdown
Collaborator

@thecristen thecristen left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, that's just perfectly simple :)

@lvachon1 lvachon1 merged commit f1b77c5 into main Apr 13, 2026
17 checks passed
@lvachon1 lvachon1 deleted the lev/a11y/search_tab_order branch April 13, 2026 17:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.