feat(web): reveal project delete button only on row hover
The trash/delete button on each project row in the project switcher was always visible, adding persistent visual noise to the list. Reveal it on row hover (and on keyboard focus for accessibility), matching the existing thread-row action-button hover pattern in this file. Co-Authored-By: Claude Opus 4.8 <[email protected]>
This commit is contained in:
1 parent
1c9a6de26e
commit
735449c729
1 file changed
+2
-2
@@ -1597,7 +1597,7 @@ export default function SidebarV2() {
|
||||
key={scopeKey}
|
||||
value={scopeKey}
|
||||
closeOnClick
|
||||
className="h-8 min-h-8 px-1 py-0 text-sm font-medium [&>span:last-child]:flex [&>span:last-child]:min-w-0 [&>span:last-child]:items-center [&>span:last-child]:gap-2"
|
||||
className="group/project-row h-8 min-h-8 px-1 py-0 text-sm font-medium [&>span:last-child]:flex [&>span:last-child]:min-w-0 [&>span:last-child]:items-center [&>span:last-child]:gap-2"
|
||||
>
|
||||
<ProjectFavicon
|
||||
environmentId={project.environmentId}
|
||||
@@ -1609,7 +1609,7 @@ export default function SidebarV2() {
|
||||
type="button"
|
||||
aria-label={`Remove project ${project.title}`}
|
||||
title={`Remove ${project.title}`}
|
||||
className="ml-auto inline-flex size-6 shrink-0 cursor-pointer items-center justify-center rounded-md text-muted-foreground/55 outline-none transition-colors hover:bg-destructive/12 hover:text-destructive focus-visible:bg-destructive/12 focus-visible:text-destructive focus-visible:ring-2 focus-visible:ring-destructive/40"
|
||||
className="ml-auto inline-flex size-6 shrink-0 cursor-pointer items-center justify-center rounded-md text-muted-foreground/55 opacity-0 outline-none transition-colors hover:bg-destructive/12 hover:text-destructive focus-visible:bg-destructive/12 focus-visible:text-destructive focus-visible:opacity-100 focus-visible:ring-2 focus-visible:ring-destructive/40 group-hover/project-row:opacity-100"
|
||||
onPointerDown={(event) => event.stopPropagation()}
|
||||
onClick={(event) => {
|
||||
event.preventDefault();
|
||||
|
||||
Reference in new issue
Block a user