mirror of
https://github.com/zadam/trilium.git
synced 2025-11-17 18:50:41 +01:00
ctrl+tab and ctrl+shift+tab can be used to switch tabs
This commit is contained in:
@@ -47,6 +47,7 @@ async function reloadAllTabs() {
|
||||
const note = await loadNote(noteContext.note.noteId);
|
||||
|
||||
await loadNoteDetailToContext(noteContext, note);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -271,6 +272,22 @@ if (utils.isElectron()) {
|
||||
|
||||
chromeTabs.removeTab(chromeTabs.activeTabEl);
|
||||
});
|
||||
|
||||
utils.bindShortcut('ctrl+tab', () => {
|
||||
const nextTab = chromeTabs.nextTabEl;
|
||||
|
||||
if (nextTab) {
|
||||
chromeTabs.setCurrentTab(nextTab);
|
||||
}
|
||||
});
|
||||
|
||||
utils.bindShortcut('ctrl+shift+tab', () => {
|
||||
const prevTab = chromeTabs.previousTabEl;
|
||||
|
||||
if (prevTab) {
|
||||
chromeTabs.setCurrentTab(prevTab);
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
// this makes sure that when user e.g. reloads the page or navigates away from the page, the note's content is saved
|
||||
|
||||
Reference in New Issue
Block a user