mirror of
https://github.com/laurent22/joplin.git
synced 2025-01-23 18:53:36 +02:00
Desktop: Reset window hash to allow clicking an anchor multiple times (#4538)
This commit is contained in:
parent
80cb18ca90
commit
da9da7ec62
@ -395,6 +395,16 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
window.addEventListener('hashchange', webviewLib.logEnabledEventHandler(e => {
|
||||||
|
if (!window.location.hash) return;
|
||||||
|
|
||||||
|
// The timeout is necessary to prevent a race condition and give time for the window to scroll
|
||||||
|
setTimeout(() => {
|
||||||
|
// Reset the window hash to allow clicking on the same anchor link more than once
|
||||||
|
window.location.hash = '';
|
||||||
|
}, 100);
|
||||||
|
}));
|
||||||
|
|
||||||
document.addEventListener('contextmenu', webviewLib.logEnabledEventHandler(event => {
|
document.addEventListener('contextmenu', webviewLib.logEnabledEventHandler(event => {
|
||||||
let element = event.target;
|
let element = event.target;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user