diff --git a/components/documents/document-header.tsx b/components/documents/document-header.tsx index bf35ddf47..bdde92ffd 100644 --- a/components/documents/document-header.tsx +++ b/components/documents/document-header.tsx @@ -7,6 +7,7 @@ import { Document, DocumentVersion } from "@prisma/client"; import { BetweenHorizontalStartIcon, FileDownIcon, + PencilLineIcon, SheetIcon, Sparkles, TrashIcon, @@ -587,6 +588,20 @@ export default function DocumentHeader({ + { + e.stopPropagation(); + setIsEditingName(true); + setTimeout(() => { + if (nameRef.current) { + nameRef.current.focus(); + } + }, 500); + }} + > + + Rename + {primaryVersion.type !== "notion" && primaryVersion.type !== "sheet" && (!prismaDocument.assistantEnabled ? (