aboutsummaryrefslogtreecommitdiff
path: root/website/resources/js/main.js
diff options
context:
space:
mode:
authorRoel Spilker <r.spilker@gmail.com>2022-01-30 02:25:11 +0100
committerRoel Spilker <r.spilker@gmail.com>2022-01-30 02:25:11 +0100
commitc73aaceb8966bbc80e249b916cea8db639b6c9f8 (patch)
treeca3b595be6f02879474eb7e2843a8a2cc139050a /website/resources/js/main.js
parent17a2e297743488028bed2507452c5d495243a0c8 (diff)
downloadlombok-c73aaceb8966bbc80e249b916cea8db639b6c9f8.tar.gz
lombok-c73aaceb8966bbc80e249b916cea8db639b6c9f8.tar.bz2
lombok-c73aaceb8966bbc80e249b916cea8db639b6c9f8.zip
show video img, <a role="button"> respond to spacebar
Diffstat (limited to 'website/resources/js/main.js')
-rw-r--r--website/resources/js/main.js16
1 files changed, 7 insertions, 9 deletions
diff --git a/website/resources/js/main.js b/website/resources/js/main.js
index cbda59b9..eaf5e188 100644
--- a/website/resources/js/main.js
+++ b/website/resources/js/main.js
@@ -1,14 +1,6 @@
"use strict";
(function($) {
- function clickToTap() {
- if (matchMedia && matchMedia('(hover: none)').matches) $(".clickToTap").each(function() {
- var x = $(this);
- if (x.text() === "Click") x.text("Tap");
- else x.text("tap");
- });
- }
-
function clickForVideo() {
var cfv = $("#clickForVideo");
var f = function() {
@@ -41,7 +33,13 @@
video.currentTime = (((h * 60) + m) * 60) + s;
}
- $(clickToTap);
+ function aButtonsRespondToSpacebar() {
+ $('a[role="button"]').keyup(function(e) {
+ if (e.which == 32) e.target.click();
+ });
+ }
+
$(clickForVideo);
$(seekVideo);
+ $(aButtonsRespondToSpacebar);
})($);