Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion assets/css/custom-props/common.css
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
--borderRadius-lg: 14px;
--borderRadius-base: 8px;
--borderRadius-sm: 3px;
--navTabBorderWidth: 2px;
--borderWidth: 2px;

/* Font Families */
/* These mirror modern-normalize.css with "Lato" on top */
Expand Down
4 changes: 1 addition & 3 deletions assets/css/focus.css
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@ button:focus,
[type="button"]:focus,
[type="reset"]:focus,
[type="submit"]:focus {
outline: 2px solid var(--main);
/* negative offset to make outline visible when overflow hidden */
outline-offset: -2px;
outline: var(--borderWidth) solid var(--main);
}

*:focus:not(:focus-visible),
Expand Down
2 changes: 1 addition & 1 deletion assets/css/layout.css
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ body {
}

.sidebar-button {
padding: 20px 12px 18px 19px;
padding: 20px 12px 18px;
position: fixed;
z-index: 200;
top: 0;
Expand Down
4 changes: 2 additions & 2 deletions assets/css/settings.css
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,8 @@
}

& .switch-button__checkbox:focus + .switch-button__bg {
outline: 2px solid var(--main);
outline-offset: 2px;
outline: var(--borderWidth) solid var(--main);
outline-offset: var(--borderWidth);
}

& .switch-button__checkbox:focus:not(:focus-visible) + .switch-button__bg {
Expand Down
28 changes: 24 additions & 4 deletions assets/css/sidebar.css
Original file line number Diff line number Diff line change
Expand Up @@ -135,6 +135,11 @@
color: var(--sidebarStaleVersion);
font-weight: 400;
}

/* keep focus outline inside overflow-clipped ancestor */
& a:focus {
outline-offset: calc(-1 * var(--borderWidth));
}
}

& .sidebar-staleIcon {
Expand All @@ -149,6 +154,11 @@
overflow: auto;
scrollbar-width: thin;

/* keep focus outline inside overflow-clipped ancestor */
& button:focus {
outline-offset: calc(-1 * var(--borderWidth));
}

& :is(li, li button) {
text-transform: uppercase;
letter-spacing: 0.02em;
Expand All @@ -165,7 +175,7 @@
& button {
background: none;
border: 0;
border-bottom: var(--navTabBorderWidth) solid transparent;
border-bottom: var(--borderWidth) solid transparent;
border-radius: 0;
-webkit-appearance: none;
text-align: inherit;
Expand All @@ -178,13 +188,13 @@
transition: var(--transition-all);

&:not([aria-selected]):hover {
border-bottom: var(--navTabBorderWidth) solid var(--sidebarInactiveItemBorder);
border-bottom: var(--borderWidth) solid var(--sidebarInactiveItemBorder);
color: var(--sidebarAccentMain);
transition: var(--transition-all);
}

&[aria-selected] {
border-bottom: var(--navTabBorderWidth) solid var(--sidebarLanguageAccentBar);
border-bottom: var(--borderWidth) solid var(--sidebarLanguageAccentBar);
color: var(--sidebarAccentMain);
}
}
Expand Down Expand Up @@ -212,6 +222,11 @@
text-overflow: ellipsis;
}

/* keep focus outline inside overflow-clipped ancestor */
& a:focus {
outline-offset: calc(-1 * var(--borderWidth));
}

& li {
padding: 0;
line-height: 27px;
Expand Down Expand Up @@ -239,7 +254,7 @@
& a {
margin-right: 30px;
padding: 3px 0 3px 12px;
border-left: var(--navTabBorderWidth) solid transparent;
border-left: var(--borderWidth) solid transparent;
color: var(--sidebarItem);

&[aria-selected] {
Expand Down Expand Up @@ -385,6 +400,11 @@
&:hover {
color: var(--sidebarHover);
}

/* keep focus outline inside overflow-clipped ancestor */
&:focus {
outline-offset: calc(-1 * var(--borderWidth));
}
}

body:not(.sidebar-open) .sidebar-button {
Expand Down
10 changes: 7 additions & 3 deletions assets/css/tabset.css
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
.tabset {
--borderWidth: 1px;
--tabsetPadding: var(--baseLineHeight);
margin: var(--baseLineHeight) 0;
border: var(--borderWidth) solid var(--tabBorder);
border: 1px solid var(--tabBorder);
padding: 0 var(--tabsetPadding);
border-radius: var(--borderRadius-lg);
}
Expand All @@ -25,11 +24,16 @@
border: 0;
box-shadow: none;
cursor: pointer;
border-bottom-width: 2px;
border-bottom-width: var(--borderWidth);
border-bottom-style: solid;
border-bottom-color: transparent;
transition: var(--transition-all);

/* keep focus outline inside overflow-clipped ancestor */
&:focus {
outline-offset: calc(-1 * var(--borderWidth));
}

&:hover {
border-bottom-color: var(--tabBorderTop);
color: var(--textHeaders);
Expand Down
Loading