From 54a0bdeb1473cd841c805e2cf481b27aed8d7666 Mon Sep 17 00:00:00 2001 From: Jin <22962980+JYC333@users.noreply.github.com> Date: Thu, 10 Apr 2025 22:19:04 +0200 Subject: [PATCH] =?UTF-8?q?refactor:=20=F0=9F=92=A1=20remove=20unused=20co?= =?UTF-8?q?mmand=20data=20(editNoteTitle)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/public/app/components/app_context.ts | 1 - src/public/app/widgets/note_tree.ts | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/public/app/components/app_context.ts b/src/public/app/components/app_context.ts index 01715e071..c27f63b39 100644 --- a/src/public/app/components/app_context.ts +++ b/src/public/app/components/app_context.ts @@ -138,7 +138,6 @@ export type CommandMappings = { insertNoteAfter: ContextMenuCommandData; insertChildNote: ContextMenuCommandData; delete: ContextMenuCommandData; - editNoteTitle: ContextMenuCommandData; protectSubtree: ContextMenuCommandData; unprotectSubtree: ContextMenuCommandData; openBulkActionsDialog: diff --git a/src/public/app/widgets/note_tree.ts b/src/public/app/widgets/note_tree.ts index 96f6a4c1b..4a89425c5 100644 --- a/src/public/app/widgets/note_tree.ts +++ b/src/public/app/widgets/note_tree.ts @@ -1687,7 +1687,7 @@ export default class NoteTreeWidget extends NoteContextAwareWidget { this.triggerCommand("showImportDialog", { noteId: node.data.noteId }); } - editNoteTitleCommand({ node }: CommandListenerData<"editNoteTitle">) { + editNoteTitleCommand() { appContext.triggerCommand("focusOnTitle"); }