@@ -87,11 +87,11 @@ const DraggableProjectItemBase: React.FC<DraggableProjectItemProps> = ({
8787 < div
8888 ref = { ( node ) => drag ( drop ( node ) ) }
8989 className = { cn (
90- "py-2 px-3 flex items-center border-l-transparent transition-all duration-150 bg-separator " ,
90+ "py-2 px-3 flex items-center border-l-transparent transition-all duration-150 bg-sidebar " ,
9191 isDragging ? "cursor-grabbing opacity-40 [&_*]:!cursor-grabbing" : "cursor-grab" ,
9292 isOver && "bg-accent/[0.08]" ,
9393 selected && "bg-hover border-l-accent" ,
94- "hover:bg-hover hover: [&_button]:opacity-100 hover:[&_[data-drag-handle]]:opacity-100"
94+ "hover:[&_button]:opacity-100 hover:[&_[data-drag-handle]]:opacity-100"
9595 ) }
9696 { ...rest }
9797 >
@@ -465,19 +465,19 @@ const ProjectSidebarInner: React.FC<ProjectSidebarProps> = ({
465465 < DndProvider backend = { HTML5Backend } >
466466 < ProjectDragLayer />
467467 < div
468- className = "font-primary bg-dark border-border-light flex flex-1 flex-col overflow-hidden border-r"
468+ className = "font-primary bg-sidebar border-border-light flex flex-1 flex-col overflow-hidden border-r"
469469 role = "navigation"
470470 aria-label = "Projects"
471471 >
472472 { ! collapsed && (
473473 < >
474474 < div className = "border-dark flex items-center justify-between border-b p-4" >
475- < h2 className = "text-foreground text-md m-0 font-semibold" > Agents </ h2 >
475+ < h2 className = "text-foreground m-0 text-lg font-medium" > Projects </ h2 >
476476 < TooltipWrapper inline >
477477 < button
478478 onClick = { onAddProject }
479479 aria-label = "Add project"
480- className = "text-foreground hover:bg-hover hover:border-border-light flex h-6 w-6 cursor-pointer items-center justify-center rounded border border-transparent bg-transparent p-0 text-lg transition-all duration-200"
480+ className = "text-secondary hover:bg-hover hover:border-border-light flex h-6 w-6 cursor-pointer items-center justify-center rounded border border-transparent bg-transparent p-0 text-2xl transition-all duration-200"
481481 >
482482 +
483483 </ button >
@@ -513,42 +513,47 @@ const ProjectSidebarInner: React.FC<ProjectSidebarProps> = ({
513513 projectPath = { projectPath }
514514 onReorder = { handleReorder }
515515 selected = { false }
516- onClick = { ( ) => toggleProject ( projectPath ) }
516+ onClick = { ( ) => handleAddWorkspace ( projectPath ) }
517517 onKeyDown = { ( e : React . KeyboardEvent ) => {
518+ // Ignore key events from child buttons
519+ if ( e . target instanceof HTMLElement && e . target !== e . currentTarget ) {
520+ return ;
521+ }
518522 if ( e . key === "Enter" || e . key === " " ) {
519523 e . preventDefault ( ) ;
520- toggleProject ( projectPath ) ;
524+ handleAddWorkspace ( projectPath ) ;
521525 }
522526 } }
523527 role = "button"
524528 tabIndex = { 0 }
525529 aria-expanded = { isExpanded }
526530 aria-controls = { workspaceListId }
527- aria-label = { `${ isExpanded ? "Collapse" : "Expand" } project ${ projectName } ` }
531+ aria-label = { `Create workspace in ${ projectName } ` }
528532 data-project-path = { projectPath }
529533 >
530- < span
534+ < button
535+ onClick = { ( event ) => {
536+ event . stopPropagation ( ) ;
537+ toggleProject ( projectPath ) ;
538+ } }
539+ aria-label = { `${ isExpanded ? "Collapse" : "Expand" } project ${ projectName } ` }
531540 data-project-path = { projectPath }
532- aria-hidden = "true"
533- className = "text-muted mr-2 shrink-0 text-xs transition-transform duration-200"
534- style = { { transform : isExpanded ? "rotate(90deg)" : "rotate(0deg)" } }
541+ className = "text-secondary hover:bg-hover hover:border-border-light mr-2 flex h-5 w-5 shrink-0 cursor-pointer items-center justify-center rounded border border-transparent bg-transparent p-0 transition-all duration-200"
535542 >
536- < ChevronRight size = { 12 } />
537- </ span >
543+ < ChevronRight
544+ size = { 12 }
545+ className = "transition-transform duration-200"
546+ style = { { transform : isExpanded ? "rotate(90deg)" : "rotate(0deg)" } }
547+ />
548+ </ button >
538549 < div className = "flex min-w-0 flex-1 items-center pr-2" >
539550 < TooltipWrapper inline >
540- < div className = "text-muted-dark truncate text-sm" >
551+ < div className = "text-muted-dark flex gap-2 truncate text-sm" >
541552 { ( ( ) => {
542553 const abbrevPath = PlatformPaths . abbreviate ( projectPath ) ;
543- const { dirPath, basename } =
544- PlatformPaths . splitAbbreviated ( abbrevPath ) ;
554+ const { basename } = PlatformPaths . splitAbbreviated ( abbrevPath ) ;
545555 return (
546- < >
547- < span > { dirPath } </ span >
548- < span className = "text-foreground font-medium" >
549- { basename }
550- </ span >
551- </ >
556+ < span className = "text-foreground font-medium" > { basename } </ span >
552557 ) ;
553558 } ) ( ) }
554559 </ div >
@@ -582,34 +587,34 @@ const ProjectSidebarInner: React.FC<ProjectSidebarProps> = ({
582587 title = "Remove project"
583588 aria-label = { `Remove project ${ projectName } ` }
584589 data-project-path = { projectPath }
585- className = "text-muted-dark hover:text-danger-light hover:bg-danger-light/10 flex h-5 w-5 shrink-0 cursor-pointer items-center justify-center rounded-[3px] border-none bg-transparent text-base opacity-0 transition-all duration-200"
590+ className = "text-muted-dark hover:text-danger-light hover:bg-danger-light/10 mr-1 flex h-5 w-5 shrink-0 cursor-pointer items-center justify-center rounded-[3px] border-none bg-transparent text-base opacity-0 transition-all duration-200"
586591 >
587592 ×
588593 </ button >
589594 < Tooltip className = "tooltip" align = "right" >
590595 Remove project
591596 </ Tooltip >
592597 </ TooltipWrapper >
598+ < button
599+ onClick = { ( event ) => {
600+ event . stopPropagation ( ) ;
601+ handleAddWorkspace ( projectPath ) ;
602+ } }
603+ aria-label = { `New chat in ${ projectName } ` }
604+ data-project-path = { projectPath }
605+ className = "text-secondary hover:bg-hover hover:border-border-light shrink-0 cursor-pointer rounded border border-transparent bg-transparent px-1.5 py-0.5 text-[11px] transition-all duration-200"
606+ >
607+ + New Chat
608+ </ button >
593609 </ DraggableProjectItem >
594610
595611 { isExpanded && (
596612 < div
597613 id = { workspaceListId }
598614 role = "region"
599615 aria-label = { `Workspaces for ${ projectName } ` }
616+ className = "pt-1"
600617 >
601- < div className = "border-hover border-b px-3 py-2" >
602- < button
603- onClick = { ( ) => handleAddWorkspace ( projectPath ) }
604- data-project-path = { projectPath }
605- aria-label = { `Add workspace to ${ projectName } ` }
606- className = "text-muted border-border-medium hover:bg-hover hover:border-border-darker hover:text-foreground w-full cursor-pointer rounded border border-dashed bg-transparent px-3 py-1.5 text-left text-[13px] transition-all duration-200"
607- >
608- + New Workspace
609- { selectedWorkspace ?. projectPath === projectPath &&
610- ` (${ formatKeybind ( KEYBINDS . NEW_WORKSPACE ) } )` }
611- </ button >
612- </ div >
613618 { ( ( ) => {
614619 const allWorkspaces =
615620 sortedWorkspacesByProject . get ( projectPath ) ?? [ ] ;
0 commit comments