Skip to content
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

Add a treatment for consistent appearance of content on focus #338

Closed
ericwbailey opened this issue Dec 13, 2022 · 1 comment
Closed

Add a treatment for consistent appearance of content on focus #338

ericwbailey opened this issue Dec 13, 2022 · 1 comment

Comments

@ericwbailey
Copy link
Contributor

This issue arose from primer/react#2593.

The SplitPageLayout component uses a small form with an input and submit button to allow for adjusting the pane width without the need for pointer input. This form is visually hidden, meaning that in its current implementation that only screen reader users will be aware of its presence.

Controls such as this need to also be visually apparent on focus. While only the SplitPageLayout component has this need right now, I anticipate other components needing similar functionality—and therefore a consistent visual treatment—as our Primer accessibility work continues.

Currently there is no one set way to handle this kind of content. The closest examples I am aware of are our Skip to main content link and our dashboard favorites reordering functionality:

A blue rectangle containing the phrase, 'Skip to content' appended to the top lefthand corner of the viewport on GitHub's homepage.

The favorite repo sidebar on GitHub's dashboard. A button containing an arrow with an upward-facing chevron and a focus ring is placed next to a favorited repo, indicating that it may be moved up in the list of favorite repos.

I am thinking that this is worth codifying as something that can be used as a subcomponent for other components, to help ensure a consistent, accessible experience that feels like it is a part of Primer. We'll likely want something along the lines of how our Dialog component looks.

Additional context

@alliethu
Copy link
Contributor

Closing in place of https://github.com/github/primer/issues/1591

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants