Skip to content

Commit 6979520

Browse files
committed
[DX] Improve right sidebar ToC hover contrast and accessibility (#960)
- Add padding and border-radius to ToC links for a clearer hover target - Add background-color and color transitions for smooth visual feedback - Add focus-visible style for keyboard navigation accessibility Incorporates PR #960 from @kavyakapoor420 with gemini review suggestions applied: expanded transition to include color, added focus-visible alongside hover. Signed-off-by: Lee Calcote <lee.calcote@layer5.io>
1 parent 25926e2 commit 6979520

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

assets/scss/_styles_project.scss

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -378,8 +378,12 @@ a:not([href]):not([class]):hover {
378378
#TableOfContents {
379379
a {
380380
color: $lightslategray;
381+
padding: 0.25rem 0.5rem;
382+
border-radius: 4px;
383+
transition: background-color 0.2s ease, color 0.2s ease;
381384

382-
&:hover {
385+
&:hover,
386+
&:focus-visible {
383387
color: $white;
384388
text-decoration: none;
385389
background-color: rgba($primary, 0.15);

0 commit comments

Comments
 (0)