Add dialog descriptions for project rename and delete confirmations

- Introduced `DialogDescription` components in `canvas-app-menu.tsx` and `canvas-card.tsx` to provide clearer context for users when renaming and deleting projects.
- Removed redundant paragraph elements in favor of the new dialog descriptions for a cleaner UI experience.
This commit is contained in:
Matthias
2026-04-01 12:19:13 +02:00
parent 34135d643e
commit d34f965dbc
2 changed files with 23 additions and 10 deletions

View File

@@ -17,6 +17,7 @@ import { Button } from "@/components/ui/button";
import {
Dialog,
DialogContent,
DialogDescription,
DialogFooter,
DialogHeader,
DialogTitle,
@@ -163,6 +164,9 @@ export function CanvasAppMenu({ canvasId }: CanvasAppMenuProps) {
<DialogContent className="sm:max-w-md" showCloseButton>
<DialogHeader>
<DialogTitle>Projekt umbenennen</DialogTitle>
<DialogDescription>
Gib einen neuen Namen für dein Projekt ein.
</DialogDescription>
</DialogHeader>
<Input
value={renameValue}
@@ -196,11 +200,11 @@ export function CanvasAppMenu({ canvasId }: CanvasAppMenuProps) {
<DialogContent className="sm:max-w-md" showCloseButton>
<DialogHeader>
<DialogTitle>Projekt löschen?</DialogTitle>
<DialogDescription>
&ldquo;{canvas?.name ?? "dieses Projekt"}&rdquo; und alle Knoten werden dauerhaft
gelöscht. Das lässt sich nicht rückgängig machen.
</DialogDescription>
</DialogHeader>
<p className="text-sm text-muted-foreground">
{canvas?.name ?? "dieses Projekt"} und alle Knoten werden dauerhaft
gelöscht. Das lässt sich nicht rückgängig machen.
</p>
<DialogFooter>
<Button
type="button"