From 4cc8b3b4879cf9ecc724d7fa1ad72735e8e624ee Mon Sep 17 00:00:00 2001
From: Henrik Askjer <henrik.askjer@uib.no>
Date: Wed, 12 Jan 2022 16:15:27 +0100
Subject: [PATCH] shift+click and ctrl+click without updating current page

---
 src/components/DictionaryView.vue | 30 ++++++++++++++++++------------
 1 file changed, 18 insertions(+), 12 deletions(-)

diff --git a/src/components/DictionaryView.vue b/src/components/DictionaryView.vue
index 86e2aba8..5d69cd3a 100644
--- a/src/components/DictionaryView.vue
+++ b/src/components/DictionaryView.vue
@@ -472,23 +472,29 @@ export default {
       },
 
     article_link_click: function(item) {
-      if (this.article && this.article.article_id == item.article_id){
-        this.article_key++
-        this.replace_history()
-        if (!this.$route.hash) {
-          window.scrollTo(0,0)
-        }
+      let event = window.event
+      if (!(event.ctrlKey || event.shiftKey)) {
+        if (this.article && this.article.article_id == item.article_id){
+          this.article_key++
+          this.replace_history()
+          if (!this.$route.hash) {
+            window.scrollTo(0,0)
+          }
 
-      }else{
-        navigate_to_article(this, item.source)
-        if (!this.$route.hash) {
-          window.scrollTo(0,0)
+        }else{
+          navigate_to_article(this, item.source)
+          if (!this.$route.hash) {
+            window.scrollTo(0,0)
+          }
         }
       }
     },
     details_click: function(item) {
-      this.article = item.article
-      this.replace_history()
+      let event = window.event
+      if (!(event.ctrlKey || event.shiftKey)) {
+        this.article = item.article
+        this.replace_history()
+      }
     },
     return_to_results: function() {
       this.article = null
-- 
GitLab