summaryrefslogtreecommitdiffstats
path: root/assets/js/ed.js
diff options
context:
space:
mode:
authorSerghei Iakovlev <egrep@protonmail.ch>2022-07-24 21:09:36 +0200
committerSerghei Iakovlev <egrep@protonmail.ch>2022-07-24 21:09:36 +0200
commitf455db5d6f8aaf17f6a80ad69ef84750583ce121 (patch)
treeb23ddf8d363b92cc110421d8ae96dab25a862a93 /assets/js/ed.js
parentf3e7ebb4a9ef2463fef4de2f9b05fc8b70adba79 (diff)
downloadgohugo-theme-ed-f455db5d6f8aaf17f6a80ad69ef84750583ce121.tar.gz
Do not refresh page on hypothesis-link click
Diffstat (limited to 'assets/js/ed.js')
-rw-r--r--assets/js/ed.js7
1 files changed, 7 insertions, 0 deletions
diff --git a/assets/js/ed.js b/assets/js/ed.js
index 146ab58..e3b844a 100644
--- a/assets/js/ed.js
+++ b/assets/js/ed.js
@@ -24,4 +24,11 @@ document.addEventListener('DOMContentLoaded', function () {
document.getElementsByTagName('head')[0].appendChild(script);
});
}
+
+ const hypothesisLink = document.querySelector('#hypothesis-link');
+ if (hypothesisLink !== null) {
+ hypothesisContainer.addEventListener('click', (e) => {
+ e.preventDefault();
+ });
+ }
});