Skip to content

Commit bae8fe0

Browse files
talissoncostaclaude
andcommitted
fix(a11y): fix Account dropdown trigger contrast in dark mode
Replace btn btn-link with scoped styles using semantic design tokens. The trigger now uses --color-text-default for proper theme-aware contrast and --color-text-action (purple) on hover for the label only. Closes #6902 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 33e4dee commit bae8fe0

File tree

2 files changed

+18
-2
lines changed

2 files changed

+18
-2
lines changed

frontend/web/components/navigation/AccountDropdown.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ const AccountDropdown: React.FC = () => {
5656
return (
5757
<div className='feature-action' tabIndex={-1}>
5858
<button
59-
className='btn btn-link p-0 d-flex ps-3 lh-1 align-items-center'
59+
className='account-dropdown-trigger d-flex ps-3 lh-1 align-items-center'
6060
onClick={(e) => {
6161
e.stopPropagation()
6262
setIsOpen(!isOpen)
@@ -68,7 +68,9 @@ const AccountDropdown: React.FC = () => {
6868
<span className='mr-1'>
6969
<Icon name='person' width={20} fill='#9DA4AE' />
7070
</span>
71-
<span className='d-none d-md-block'>Account</span>
71+
<span className='d-none d-md-block account-dropdown-trigger__label'>
72+
Account
73+
</span>
7274
</button>
7375

7476
{isOpen &&

frontend/web/styles/project/_project-nav.scss

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,20 @@ nav a {
1313
font-weight: bold;
1414
}
1515
}
16+
.account-dropdown-trigger {
17+
color: var(--color-text-default);
18+
background: none;
19+
border: none;
20+
padding: 0;
21+
cursor: pointer;
22+
font-weight: 500;
23+
&:hover,
24+
&:focus {
25+
.account-dropdown-trigger__label {
26+
color: var(--color-text-action);
27+
}
28+
}
29+
}
1630
.nav-sub-link-disabled {
1731
cursor: not-allowed;
1832
span {

0 commit comments

Comments
 (0)