small fixes and tweaks

This commit is contained in:
zadam
2021-09-29 12:39:28 +02:00
parent 5358b58191
commit c2d35dac4d
5 changed files with 15 additions and 24 deletions

View File

@@ -483,21 +483,6 @@ export default class AttributeEditorWidget extends NoteContextAwareWidget {
}
}
async focusOnAttributesEvent({ntxId}) {
if (this.noteContext.ntxId === ntxId) {
if (this.$editor.is(":visible")) {
this.$editor.trigger('focus');
this.textEditor.model.change(writer => { // put focus to the end of the content
writer.setSelection(writer.createPositionAt(this.textEditor.model.document.getRoot(), 'end'));
});
}
else {
this.triggerEvent('focusOnDetail', {ntxId: this.noteContext.ntxId});
}
}
}
async createNoteForReferenceLink(title) {
const {note} = await noteCreateService.createNote(this.notePath, {
activate: false,