Skip to content
Open
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
4 changes: 4 additions & 0 deletions .Jules/palette.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@

## 2024-05-01 - Adding ARIA labels to Icon-Only Buttons
**Learning:** Found multiple icon-only buttons in the Graph Controls panel (Reset settings, Close panel, Delete group) that lacked `aria-label` attributes, relying solely on `title` or visual cues. This makes them inaccessible to screen reader users who need explicit labels for interactive elements.
**Action:** Always include an `aria-label` attribute alongside the `title` attribute for icon-only `<Button>` components to ensure both visual hover tooltips and screen reader accessibility are supported.
4 changes: 4 additions & 0 deletions src/components/graph-tab.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1319,6 +1319,7 @@ interface ForceGraphInstance {
variant="ghost"
size="icon"
title="Reset settings"
aria-label="Reset settings"
onClick={() => setPanel(DEFAULT_PANEL)}
className="size-7"
>
Expand All @@ -1328,6 +1329,7 @@ interface ForceGraphInstance {
variant="ghost"
size="icon"
title="Close panel"
aria-label="Close panel"
onClick={() => setPaneOpen(false)}
className="size-7"
>
Expand Down Expand Up @@ -1431,6 +1433,8 @@ interface ForceGraphInstance {
<Button
variant="ghost"
size="icon"
title="Delete group"
aria-label="Delete group"
onClick={() => {
const next = panel.groups.filter(
(_, i) => i !== index,
Expand Down