mirror of
				https://github.com/zadam/trilium.git
				synced 2025-10-31 02:16:05 +01:00 
			
		
		
		
	small fixes
This commit is contained in:
		| @@ -195,8 +195,6 @@ if (utils.isElectron()) { | ||||
|             items, | ||||
|             selectMenuItemHandler: ({command, spellingSuggestion}) => { | ||||
|                 if (command === 'replaceMisspelling') { | ||||
|                     console.log("Replacing missspeling", spellingSuggestion); | ||||
|  | ||||
|                     webContents.insertText(spellingSuggestion); | ||||
|                 } | ||||
|             } | ||||
|   | ||||
| @@ -48,7 +48,9 @@ export async function showDialog(widget) { | ||||
|     $autoComplete.on('autocomplete:cursorchanged', function(event, suggestion, dataset) { | ||||
|         const noteId = treeService.getNoteIdFromNotePath(suggestion.path); | ||||
|  | ||||
|         if (noteId) { | ||||
|             setDefaultLinkTitle(noteId); | ||||
|         } | ||||
|     }); | ||||
|  | ||||
|     noteAutocompleteService.showRecentNotes($autoComplete); | ||||
|   | ||||
| @@ -40,7 +40,7 @@ export default class ChangePasswordOptions { | ||||
|         this.$form.on('submit', () => this.save()); | ||||
|     } | ||||
|  | ||||
|     optionsLoaded(options) {console.log(options); | ||||
|     optionsLoaded(options) { | ||||
|         this.$username.text(options.username); | ||||
|     } | ||||
|  | ||||
|   | ||||
| @@ -140,7 +140,7 @@ export default class BookTypeWidget extends TypeWidget { | ||||
|             }); | ||||
|  | ||||
|             this.$content.append($('<div class="note-book-auto-message"></div>') | ||||
|                 .append(`This note doesn't have any content so we display its children. Click `) | ||||
|                 .append(`This note doesn't have any content so we display its children. <br> Click `) | ||||
|                 .append($addTextLink) | ||||
|                 .append(' if you want to add some text.')); | ||||
|         } | ||||
|   | ||||
| @@ -7,6 +7,7 @@ import toastService from "../../services/toast.js"; | ||||
| import attributeAutocompleteService from "../../services/attribute_autocomplete.js"; | ||||
| import TypeWidget from "./type_widget.js"; | ||||
| import appContext from "../../services/app_context.js"; | ||||
| import utils from "../../services/utils.js"; | ||||
|  | ||||
| const uniDirectionalOverlays = [ | ||||
|     [ "Arrow", { | ||||
| @@ -165,10 +166,6 @@ export default class RelationMapTypeWidget extends TypeWidget { | ||||
|  | ||||
|             toastService.showMessage("Click on canvas to place new note"); | ||||
|  | ||||
|             // reloading tree so that the new note appears there | ||||
|             // no need to wait for it to finish | ||||
|             treeService.reload(); | ||||
|  | ||||
|             this.clipboard = { noteId: note.noteId, title }; | ||||
|         }); | ||||
|  | ||||
| @@ -208,10 +205,9 @@ export default class RelationMapTypeWidget extends TypeWidget { | ||||
|             this.jsPlumbInstance.remove(this.noteIdToId(noteId)); | ||||
|  | ||||
|             if (confirmDialog.isDeleteNoteChecked()) { | ||||
|                 await server.remove("notes/" + noteId); | ||||
|                 const taskId = utils.randomString(10); | ||||
|  | ||||
|                 // to force it to disappear from the tree | ||||
|                 treeService.reload(); | ||||
|                 await server.remove(`notes/${noteId}?taskId=${taskId}&last=true`); | ||||
|             } | ||||
|  | ||||
|             this.mapData.notes = this.mapData.notes.filter(note => note.noteId !== noteId); | ||||
|   | ||||
		Reference in New Issue
	
	Block a user