summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authors1nical <[email protected]>2019-08-26 04:45:40 -0700
committers1nical <[email protected]>2019-08-26 04:45:40 -0700
commit87273ed64d4a83db0387180153d5ab845d2e0485 (patch)
treee173bc80ee7bdac326c3ac4d7fee35e6e854a9c5
parentformatting fix (diff)
downloads1n.pw-admin-87273ed64d4a83db0387180153d5ab845d2e0485.tar.xz
s1n.pw-admin-87273ed64d4a83db0387180153d5ab845d2e0485.zip
disable context menu on right click on home
-rw-r--r--index.html1
-rw-r--r--js/hide-context-menu.js3
2 files changed, 4 insertions, 0 deletions
diff --git a/index.html b/index.html
index f41f546..68be50c 100644
--- a/index.html
+++ b/index.html
@@ -22,6 +22,7 @@
<link rel="icon" type="image/ico" href="/favicon.ico" sizes="128x128">
<link rel="canonical" href="https://s1n.pw/">
<link rel="author" href="humans.txt" />
+ <script src="/js/hide-context-menu.js"></script>
<script type="application/ld+json">
{
"name": "s1nical",
diff --git a/js/hide-context-menu.js b/js/hide-context-menu.js
new file mode 100644
index 0000000..af01311
--- /dev/null
+++ b/js/hide-context-menu.js
@@ -0,0 +1,3 @@
+document.addEventListener("contextmenu", function (e) {
+ e.preventDefault();
+}, false) \ No newline at end of file