diff --git a/app/components/Code/Viewer.vue b/app/components/Code/Viewer.vue index 2d9fe7811..6f6e82a5f 100644 --- a/app/components/Code/Viewer.vue +++ b/app/components/Code/Viewer.vue @@ -62,10 +62,11 @@ watch( function handleImportLinkNavigate() { if (!codeRef.value) return - const anchors = codeRef.value.querySelectorAll('a.import-link') + const anchors = codeRef.value.querySelectorAll('a.import-link') anchors.forEach(anchor => { // NOTE: We do not need to remove previous listeners because we re-create the entire HTML content on each html update anchor.addEventListener('click', event => { + if (event.metaKey || event.altKey || event.ctrlKey || event.shiftKey) return const href = anchor.getAttribute('href') if (href) { event.preventDefault()