⚡ Project management that doesn't become the project. Boards, Gantt charts, and GitHub integration. Self-host it or use Kaneo Cloud.
TypeScript honoissue-managementissue-trackerjira-alternativekanbanlinear-alternativemcpproject-managementreactself-hostedtypescript
refactor: simplify CommandDialog usage in SearchCommandMenu and TaskCard components
Andrej79167cf321f7
diff --git a/apps/web/src/components/command-palette/index.tsx b/apps/web/src/components/command-palette/index.tsxindex 56966dbaa..ffb1d66be 100644--- a/apps/web/src/components/command-palette/index.tsx+++ b/apps/web/src/components/command-palette/index.tsx@@ -241,7 +241,7 @@ function CommandPalette() {return (<><CommandDialog open={open} onOpenChange={setOpen}>- <CommandDialogPopup className="max-w-4xl">+ <CommandDialogPopup><Command items={groupedItems}><CommandInput placeholder="Search for apps and commands..." /><CommandPanel>diff --git a/apps/web/src/components/kanban-board/task-card.tsx b/apps/web/src/components/kanban-board/task-card.tsxindex 8dcc5a047..761d4ea8e 100644--- a/apps/web/src/components/kanban-board/task-card.tsx+++ b/apps/web/src/components/kanban-board/task-card.tsx@@ -37,6 +37,7 @@ import useBulkSelectionStore from "@/store/bulk-selection";import useProjectStore from "@/store/project";import { useUserPreferencesStore } from "@/store/user-preferences";import type Task from "@/types/task";+import { Button } from "../ui/button";import { ContextMenu, ContextMenuTrigger } from "../ui/context-menu";import TaskCardContextMenuContent from "./task-card-context-menu/task-card-context-menu-content";import TaskCardLabels from "./task-labels";@@ -399,12 +400,15 @@ function TaskCard({ task }: TaskCardProps) {</AlertDialogDescription></AlertDialogHeader><AlertDialogFooter>- <AlertDialogClose>Cancel</AlertDialogClose>- <AlertDialogClose- onClick={handleDeleteTask}- className="bg-destructive text-destructive-foreground hover:bg-destructive/90"- >- Delete Task+ <AlertDialogClose>+ <Button variant="outline" size="sm">+ Cancel+ </Button>+ </AlertDialogClose>+ <AlertDialogClose onClick={handleDeleteTask}>+ <Button variant="destructive" size="sm">+ Delete Task+ </Button></AlertDialogClose></AlertDialogFooter></AlertDialogContent>diff --git a/apps/web/src/components/search-command-menu/index.tsx b/apps/web/src/components/search-command-menu/index.tsxindex f95c0550c..73e8b1d82 100644--- a/apps/web/src/components/search-command-menu/index.tsx+++ b/apps/web/src/components/search-command-menu/index.tsx@@ -180,12 +180,7 @@ function SearchCommandMenu({ open, setOpen }: SearchCommandMenuProps) {}, [searchEnabled, searchResults?.results]);return (- <CommandDialog- open={open}- onOpenChange={setOpen}- title="Search"- description="Search for tasks, projects, comments, and more"- >+ <CommandDialog open={open} onOpenChange={setOpen}><CommandDialogPopup><Command items={groupedItems}><CommandInput