Repository navigation
fix(component-library): make mt-select a single tab stop - #1394
Open
Arnold Stoba (arnoldstoba) wants to merge 2 commits into
Open
Arnold Stoba (arnoldstoba) wants to merge 2 commits into
Arnold Stoba (arnoldstoba) wants to merge 2 commits into
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
…nd simplify the select keyboard story
Arnold Stoba (arnoldstoba)
force-pushed
the
fix/select-single-tab-stop
branch
from
October 6, 2026 09:34
6153935 to
af4109e
Compare
Arnold Stoba (arnoldstoba)
marked this pull request as ready for review
October 6, 2026 09:34
This branch was successfully deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What?
Shift+Tab in
mt-selectworks like Tab: it opens the select on the way in, and on the way out it focuses the previous element without clicking it.Why?
Shift+Tab out of a select called
.click()on the previous focusable element. In a form like this, Shift+Tab from the currency select toggled "Active":A button or link before a select was triggered the same way. Shift+Tab into a select also landed on its inner input without opening it.
How?
The inner input gets
tabindex="-1", so the select wrapper is the only tab stop and opens on focus in both directions. On Shift+Tab out, the select focuses the previous focusable element (skipping disabled, inert, hidden andtabindex="-1"elements) instead of clicking it.Testing?
mt-select.spec.ts: Shift+Tab focuses the previous element, skips an inert one and clicks nothing.Anything Else?
#1397 also changes
mt-select-base.vue; the two merge without conflicts.