From 8449c89b4d8752449b387ed196eb3af2a00b1dd9 Mon Sep 17 00:00:00 2001 From: Timo Tijhof Date: Sun, 16 Feb 2020 01:02:56 +0000 Subject: [PATCH] Use _blank instead of _new for link targets Target "_blank" is a reserved value which prompts the browser to create a new tab (or new window), and load the link question there. Any other target value, including "_new", instructs the browser to seek a window with that internal ID assigned to it (or create it if one doesn't exist yet), make it navigate to this link. This means that when you've click a link, kept the tab open for further analsys and then go back to the stream and click another, surprise surprise, it overwrites the tab you kept with this new link. --- public/js/app.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/public/js/app.js b/public/js/app.js index d52e265..3d27c83 100644 --- a/public/js/app.js +++ b/public/js/app.js @@ -46,7 +46,7 @@ function getNumUpdates() { function addUpdate(msg) { var lang = $('').attr({'class': 'lang'}).text('[' + msg.wikipediaShort + ']'); - var a = $('').attr({'class': 'page', 'href': msg.url, 'title': msg.comment, target: '_new'}).text(msg.page); + var a = $('').attr({'class': 'page', 'href': msg.url, 'title': msg.comment, target: '_blank'}).text(msg.page); var delta; if (msg.delta == null) delta = "n/a"; else if (msg.delta < 0) delta = msg.delta;