diff --git a/webui/src/components/ChatList.tsx b/webui/src/components/ChatList.tsx index de65ced9d..ccc44a45a 100644 --- a/webui/src/components/ChatList.tsx +++ b/webui/src/components/ChatList.tsx @@ -40,6 +40,8 @@ import type { ChatSummary, SidebarDensity, SidebarSortMode } from "@/lib/types"; const INITIAL_VISIBLE_SESSIONS = 160; const VISIBLE_SESSIONS_INCREMENT = 160; +const ACTION_MENU_CONTENT_CLASS = "w-[8.5rem] min-w-[8.5rem]"; +const ACTION_MENU_ITEM_CLASS = "grid w-[7.75rem] grid-cols-[1rem_minmax(0,1fr)] items-center gap-2"; interface ChatListProps { sessions: ChatSummary[]; @@ -309,32 +311,36 @@ export const ChatList = memo(function ChatList({ event.preventDefault()} > onTogglePin(s.key)} + className={ACTION_MENU_ITEM_CLASS} > {isPinned ? ( - + ) : ( - + )} {isPinned ? t("chat.unpin") : t("chat.pin")} onRequestRename(s.key, title)} + className={ACTION_MENU_ITEM_CLASS} > - + {t("chat.rename")} onToggleArchive(s.key)} + className={ACTION_MENU_ITEM_CLASS} > {isArchived ? ( - + ) : ( - + )} {isArchived ? t("chat.unarchive") : t("chat.archive")} @@ -342,9 +348,12 @@ export const ChatList = memo(function ChatList({ onSelect={() => { window.setTimeout(() => onRequestDelete(s.key, title), 0); }} - className="text-destructive focus:text-destructive" + className={cn( + ACTION_MENU_ITEM_CLASS, + "text-destructive focus:text-destructive", + )} > - + {t("chat.delete")} @@ -439,11 +448,12 @@ function ProjectGroupHeader({ event.preventDefault()} > - - + + {t("chat.rename")}