Skip to content

fix(LabelGroup): updated tab order to match visual order#5172

Closed
thatblindgeye wants to merge 1 commit intopatternfly:mainfrom
thatblindgeye:iss5122_labelGroup_tabOrder
Closed

fix(LabelGroup): updated tab order to match visual order#5172
thatblindgeye wants to merge 1 commit intopatternfly:mainfrom
thatblindgeye:iss5122_labelGroup_tabOrder

Conversation

@thatblindgeye
Copy link
Contributor

@thatblindgeye thatblindgeye commented Oct 13, 2022

WIP for #5122

Had a conversation with @mcoker regarding this and #5157. The tldr is that this can be a bit of a gray area, where both the visual order and the logical/expected order both make sense.

The following link should link to the "Vertical category removable, updated markup" example which shows a potential fix for the linked issue. The example immediately below it, "Vertical category removable", is the behavior seen in our React repo.
Label group

For label group with truncated label + overflow button + close button, the visual order seems to be more left to right, top to bottom, e.g. the label should receive focus, then the close button (visually to the right of the label), then the overflow. However:

  • If you view it more as a column then top to bottom, left to right also makes sense. E.g., the label receives focus, then the overflow (within the same "column" as the label, then over to the next "column" the close button receives focus.
  • The horizontal label group tab order currently is setup in a way that tab order + visual order just happen to match, but updating the tab order for the vertical label group could be confusing since you'd be going from label > overflow > close button, to label > close button > overflow

Placing the interactive elements in an order that follows sequences and relationships within the content may be relevant.

@jessiehuff @nicolethoen your input would be appreciated

@patternfly-build
Copy link
Collaborator

patternfly-build commented Oct 13, 2022

@thatblindgeye
Copy link
Contributor Author

@mcoker @jessiehuff Nicole and I had a quick chat regarding this update, and we're both leaning towards keeping things as-is per the reasons stated above (may cause confusion if we update the tab order for vertical only and either train of thought makes sense; Nicole also brought up a good point about how having the close button in the middle may interrupt the flow for screen readers).

Would both of you agree with that?

@mcoker
Copy link
Contributor

mcoker commented Oct 17, 2022

@thatblindgeye sounds good to me!

@thatblindgeye
Copy link
Contributor Author

Spoke with Jessie, and based on the discussion above for now I'll close this PR and issue (as well as the React followup).

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.

Bug - Label group: vertical category with overflow produces wrong tab order

3 participants