fix: align hover styles and selection-toggle target with focused item

This commit is contained in:
Linus Rath
2026-04-21 23:50:55 +02:00
parent 76f6149841
commit 40982bc37b
4 changed files with 19 additions and 10 deletions
+4 -1
View File
@@ -274,7 +274,10 @@ export function ContactList({
if (allSelected) onClearSelection();
else onSelectAll(sortedIds);
} else if (sortedIds.length > 0) {
onToggleSelection(sortedIds[0]);
const target = selectedContactId && sortedIds.includes(selectedContactId)
? selectedContactId
: sortedIds[0];
onToggleSelection(target);
}
}}
className={cn(