about summary refs log tree commit diff
path: root/app/javascript/flavours/glitch/packs/error.js
diff options
context:
space:
mode:
Diffstat (limited to 'app/javascript/flavours/glitch/packs/error.js')
-rw-r--r--app/javascript/flavours/glitch/packs/error.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/app/javascript/flavours/glitch/packs/error.js b/app/javascript/flavours/glitch/packs/error.js
new file mode 100644
index 000000000..9f692ad37
--- /dev/null
+++ b/app/javascript/flavours/glitch/packs/error.js
@@ -0,0 +1,14 @@
+import 'packs/public-path';
+import ready from 'flavours/glitch/util/ready';
+
+ready(() => {
+  const image = document.querySelector('img');
+
+  image.addEventListener('mouseenter', () => {
+    image.src = '/oops.gif';
+  });
+
+  image.addEventListener('mouseleave', () => {
+    image.src = '/oops.png';
+  });
+});