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

fix: more focus style fixes for small devices #1532

Merged
merged 1 commit into from Sep 25, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
57 changes: 29 additions & 28 deletions src/scss/focus.scss
Expand Up @@ -20,21 +20,21 @@
/* Another hack to make some focus styles appear better */
.focus-after {
position: relative;
}

.focus-after:focus {
outline: none;
}
&:focus {
outline: none;
}

.focus-after:focus::after {
position: absolute;
left: 0;
right: 0;
bottom: 0;
top: 0;
content: '';
border: var(--focus-width) solid var(--focus-outline);
pointer-events: none;
&:focus::after {
position: absolute;
left: 0;
right: 0;
bottom: 0;
top: 0;
content: '';
border: var(--focus-width) solid var(--focus-outline);
pointer-events: none;
}
}

// For KaiOS, do some additional things to improve the focus styles, which don't show up well
Expand All @@ -52,23 +52,24 @@
opacity: 0.8;
}

button, .button {
// add extremely visible styles for buttons, ala .focus-after
button, .button, a.main-nav-link {
position: relative;
}

// add extremely visible styles for buttons, ala .focus-after
button:focus, .button:focus {
outline: none;
}
&:focus {
outline: none;
}

&:focus::after {
position: absolute;
left: 0;
right: 0;
bottom: 0;
top: 0;
content: '';
border: var(--focus-width) solid var(--focus-outline);
pointer-events: none;
}

button:focus::after, .button:focus::after {
position: absolute;
left: 0;
right: 0;
bottom: 0;
top: 0;
content: '';
border: var(--focus-width) solid var(--focus-outline);
pointer-events: none;
}
}