mirror of
				https://github.com/TriliumNext/Notes.git
				synced 2025-10-31 13:01:31 +08:00 
			
		
		
		
	add keyboard shortcut for duplicate subtree, #1451
This commit is contained in:
		
							parent
							
								
									928ed7a034
								
							
						
					
					
						commit
						7d8277699c
					
				| @ -184,6 +184,12 @@ const DEFAULT_KEYBOARD_ACTIONS = [ | ||||
|         description: "Add note above to the selection", | ||||
|         scope: "note-tree" | ||||
|     }, | ||||
|     { | ||||
|         actionName: "duplicateSubtree", | ||||
|         defaultShortcuts: [], | ||||
|         description: "Duplicate subtree", | ||||
|         scope: "note-tree" | ||||
|     }, | ||||
| 
 | ||||
| 
 | ||||
|     { | ||||
|  | ||||
| @ -739,7 +739,10 @@ function duplicateSubtree(origNoteId, newParentNoteId) { | ||||
| 
 | ||||
|     const res = duplicateSubtreeInner(origNote, origBranch, newParentNoteId, noteIdMapping); | ||||
| 
 | ||||
|     if (!res.note.title.endsWith('(dup)')) { | ||||
|         res.note.title += " (dup)"; | ||||
|     } | ||||
| 
 | ||||
|     res.note.save(); | ||||
| 
 | ||||
|     return res; | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 zadam
						zadam