Skip to content
Draft
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
3 changes: 3 additions & 0 deletions .jules/palette.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
## 2024-05-18 - Missing ARIA label for conversational sidebar delete action
**Learning:** Found an icon-only button ("×") representing delete in the `ConversationsSidebar` that relied solely on the `title` attribute for accessibility. The `title` attribute is often insufficient for screen readers or when hovered.
**Action:** Always add explicit `aria-label` to icon-only buttons to guarantee screen reader accessibility.
1 change: 1 addition & 0 deletions apps/app/src/components/ConversationsSidebar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -221,6 +221,7 @@ export function ConversationsSidebar({
setConfirmDeleteId(conv.id);
}}
Comment on lines 221 to 222

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no guard against opening a new delete confirmation dialog while a delete operation is already in progress (deletingId). This could lead to inconsistent UI state if the user rapidly clicks delete on multiple conversations.

Recommended solution:
Add a check to prevent setting a new confirmation while a delete is ongoing:

if (!deletingId) setConfirmDeleteId(conv.id);

title="Delete conversation"
aria-label="Delete conversation"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

medium

Since this button is repeated for every conversation in the list, using a static aria-label makes it difficult for screen reader users to distinguish which conversation each button refers to. Including the conversation title in the label provides necessary context for the destructive action.

Suggested change
aria-label="Delete conversation"
aria-label={`Delete conversation: ${conv.title}`}

>
×
</button>
Expand Down
Loading