Skip to content

Commit 58b4eeb

Browse files
fix: add tree header active styling
1 parent 31ecb84 commit 58b4eeb

File tree

1 file changed

+9
-5
lines changed

1 file changed

+9
-5
lines changed

src/webview/SearchSidebar/SearchResultList/TreeHeader.tsx

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -29,10 +29,13 @@ const styles = stylex.create({
2929
boxShadow: 'var(--vscode-scrollbar-shadow) 0 0 6px',
3030
},
3131
active: {
32-
background: 'var(--vscode-list-activeSelectionBackground)',
33-
outline:
34-
'1px solid var(--vscode-list-focusAndSelectionOutline, var(--vscode-contrastActiveBorder, var(--vscode-list-focusOutline)))',
35-
outlineOffset: -1,
32+
background: 'var(--vscode-list-inactiveSelectionBackground)',
33+
':focus': {
34+
background: 'var(--vscode-list-activeSelectionBackground)',
35+
outline:
36+
'1px solid var(--vscode-list-focusAndSelectionOutline, var(--vscode-contrastActiveBorder, var(--vscode-list-focusOutline)))',
37+
outlineOffset: -1,
38+
},
3639
},
3740
toggleButton: {
3841
flex: 0,
@@ -72,7 +75,8 @@ export default function TreeHeader({
7275
setActive()
7376
}, [toggleIsExpanded, setActive])
7477
const element = (hovered: boolean) => (
75-
<div {...styleProps} onClick={onClick}>
78+
// biome-ignore lint/a11y/noNoninteractiveTabindex: need it for styling
79+
<div {...styleProps} onClick={onClick} tabIndex={0}>
7680
<div
7781
{...stylex.props(styles.toggleButton)}
7882
aria-label="expand/collapse button"

0 commit comments

Comments
 (0)