Skip to content

Commit 8a2c474

Browse files
committed
style: add theme-aware active route indicator to menu
Replace bold-only active state with a theme-accent left border and color highlight using router-link-exact-active. Also switch the hover background from hardcoded rgba to var(--theme-card-border) so all three themes stay consistent. https://claude.ai/code/session_01LqASmLgyjntVCZaWubRPMU
1 parent 23e582c commit 8a2c474

1 file changed

Lines changed: 7 additions & 3 deletions

File tree

components/MenuComponent.vue

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -196,7 +196,7 @@ nav ul li {
196196
}
197197
198198
nav ul li:hover {
199-
background-color: rgba(128, 128, 128, 0.1);
199+
background-color: var(--theme-card-border, rgba(128, 128, 128, 0.1));
200200
}
201201
202202
nav ul li a {
@@ -206,8 +206,12 @@ nav ul li a {
206206
font-size: 1.2rem;
207207
}
208208
209-
nav ul li a.router-link-active {
210-
font-weight: bold;
209+
nav ul li a.router-link-exact-active {
210+
font-weight: 600;
211+
color: var(--theme-accent, #6b8cae);
212+
border-left: 2px solid var(--theme-accent, #6b8cae);
213+
margin-left: -2rem;
214+
padding-left: calc(2rem - 2px);
211215
}
212216
213217
nav ul li a:focus-visible {

0 commit comments

Comments
 (0)