mirror of
				https://github.com/zadam/trilium.git
				synced 2025-11-03 20:06:08 +01:00 
			
		
		
		
	fix autobook switching back to text
This commit is contained in:
		@@ -240,9 +240,11 @@ export default class NoteDetailWidget extends TabAwareWidget {
 | 
				
			|||||||
        this.spacedUpdate.updateNowIfNecessary();
 | 
					        this.spacedUpdate.updateNowIfNecessary();
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    autoBookDisabledEvent() {
 | 
					    autoBookDisabledEvent({tabContext}) {
 | 
				
			||||||
 | 
					        if (this.isTab(tabContext.tabId)) {
 | 
				
			||||||
            this.refresh();
 | 
					            this.refresh();
 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
    async cutIntoNoteCommand() {
 | 
					    async cutIntoNoteCommand() {
 | 
				
			||||||
        const note = appContext.tabManager.getActiveTabNote();
 | 
					        const note = appContext.tabManager.getActiveTabNote();
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -136,7 +136,7 @@ export default class BookTypeWidget extends TypeWidget {
 | 
				
			|||||||
            const $addTextLink = $('<a href="javascript:">here</a>').on('click', () => {
 | 
					            const $addTextLink = $('<a href="javascript:">here</a>').on('click', () => {
 | 
				
			||||||
                this.tabContext.autoBookDisabled = true;
 | 
					                this.tabContext.autoBookDisabled = true;
 | 
				
			||||||
 | 
					
 | 
				
			||||||
                this.triggerEvent('autoBookDisabled');
 | 
					                this.triggerEvent('autoBookDisabled', {tabContext: this.tabContext});
 | 
				
			||||||
            });
 | 
					            });
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            this.$content.append($('<div class="note-book-auto-message"></div>')
 | 
					            this.$content.append($('<div class="note-book-auto-message"></div>')
 | 
				
			||||||
 
 | 
				
			|||||||
@@ -36,4 +36,10 @@ export default class TypeWidget extends TabAwareWidget {
 | 
				
			|||||||
    scrollToTop() {
 | 
					    scrollToTop() {
 | 
				
			||||||
        this.$widget.scrollTop(0);
 | 
					        this.$widget.scrollTop(0);
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					    autoBookDisabledEvent({tabContext}) {
 | 
				
			||||||
 | 
					        if (this.isTab(tabContext.tabId)) {
 | 
				
			||||||
 | 
					            this.refresh();
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
		Reference in New Issue
	
	Block a user