mirror of
https://github.com/zadam/trilium.git
synced 2025-12-03 22:14:24 +01:00
feat(tree_context_menu): disable "Convert to attachment" if no eligible notes
This commit is contained in:
parent
eb84da4c51
commit
5fd488e210
@ -140,7 +140,13 @@ export default class TreeContextMenu implements SelectMenuItemEventListener<Tree
|
||||
uiIcon: "bx bx-rename",
|
||||
enabled: isNotRoot && parentNotSearch && notOptionsOrHelp
|
||||
},
|
||||
{ title: t("tree-context-menu.convert-to-attachment"), command: "convertNoteToAttachment", uiIcon: "bx bx-paperclip", enabled: isNotRoot && !isHoisted && notOptionsOrHelp },
|
||||
{
|
||||
title:
|
||||
t("tree-context-menu.convert-to-attachment"),
|
||||
command: "convertNoteToAttachment",
|
||||
uiIcon: "bx bx-paperclip",
|
||||
enabled: isNotRoot && !isHoisted && notOptionsOrHelp && selectedNotes.some(note => note.isEligibleForConversionToAttachment())
|
||||
},
|
||||
|
||||
{ kind: "separator" },
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user