Revert "port tab manager to ts"

This reverts commit 45a50f3aa1.
This commit is contained in:
Elian Doran
2025-03-03 23:34:54 +02:00
parent 3f641c98fb
commit 3855f0e75f
9 changed files with 152 additions and 228 deletions

View File

@@ -288,15 +288,11 @@ function goToLinkExt(evt: MouseEvent | JQuery.ClickEvent | JQuery.MouseDownEvent
const noteContext = ntxId ? appContext.tabManager.getNoteContextById(ntxId) : appContext.tabManager.getActiveContext();
if (noteContext) {
noteContext.setNote(notePath, { viewScope }).then(() => {
if (noteContext !== appContext.tabManager.getActiveContext()) {
appContext.tabManager.activateNoteContext(noteContext.ntxId);
}
});
} else {
appContext.tabManager.openContextWithNote(notePath, { viewScope, activate: true });
}
noteContext.setNote(notePath, { viewScope }).then(() => {
if (noteContext !== appContext.tabManager.getActiveContext()) {
appContext.tabManager.activateNoteContext(noteContext.ntxId);
}
});
}
} else if (hrefLink) {
const withinEditLink = $link?.hasClass("ck-link-actions__preview");