Fixed instant loading causing jump for code annotations

This commit is contained in:
squidfunk
2023-05-02 10:59:39 +02:00
parent 5c57458256
commit 201054e79d
6 changed files with 25 additions and 51 deletions

View File

@@ -222,7 +222,10 @@ export function mountAnnotation(
takeUntil(done$),
filter(ev => !(ev.metaKey || ev.ctrlKey))
)
.subscribe(ev => ev.preventDefault())
.subscribe(ev => {
ev.stopPropagation()
ev.preventDefault()
})
/* Allow to open link in new tab or blur on close */
fromEvent<MouseEvent>(index, "mousedown")