mirror of
https://github.com/kiwix/kiwix-js-pwa.git
synced 2025-09-09 12:19:46 -04:00
Fix regex to determine location of new tab icon
Former-commit-id: b1f74dacd14e24fb8c47a59201d246f591f1cd52 [formerly ba3a8d00272d9e1f81be1bd78597e954d21e4266] Former-commit-id: 4ee7bc7094264da98df8f9cd8f5986086012af43
This commit is contained in:
parent
13fa34645d
commit
f0267ab182
@ -337,7 +337,7 @@ define(['util'], function(util) {
|
||||
var desc = "Open article in new tab or window";
|
||||
var iframe = document.getElementById('articleContent').contentDocument;
|
||||
// Remove the file and any query string from href
|
||||
var prefix = window.location.href.replace(/^((?!.*\?).*\/|(?=.*\/).*\/(?=[^\/]+\?)).*$/, '$1');
|
||||
var prefix = window.location.href.replace(/^((?!.*\?).*\/|(?=.*\/).*\/(?=[^\/]*\?)).*$/, '$1');
|
||||
var div = document.createElement('div');
|
||||
div.style.cssText = 'left: 95%; top: 10px; position: absolute; z-index: 2;';
|
||||
div.id = "openInTab";
|
||||
|
Loading…
x
Reference in New Issue
Block a user