From 47f02589b226ef92774ec7ea04c53571c3fe37e8 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Paul=20H=C3=A4nsch?= Date: Wed, 13 Oct 2021 17:55:53 +0200 Subject: [PATCH] clickable video thumbnail --- page_channel.sh | 10 ++++++---- rawnet.css | 7 +++++++ 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/page_channel.sh b/page_channel.sh index 8d1d183..ff7fa21 100755 --- a/page_channel.sh +++ b/page_channel.sh @@ -172,10 +172,12 @@ w_video(){ thumb="${_BASE}/video/${CHANNEL_ID}/${VIDEO_ID}_thumb.jpg" [ "$NAME" = \\ ] && NAME="(Unnamed Video)" printf '[div .video .thumb - [h3 [a href="%s/channel/%s/%s/" . %s]] - [figure [img src="%s" alt=""]] - [span .duration . %i:%02i] - [div .description . %s] + [a href="%s/channel/%s/%s/" + [h3 . %s] + [figure [img src="%s" alt=""]] + [span .duration . %i:%02i] + [div .description . %s] + ] ]' "$_BASE" "$CHANNEL_ID" "$VIDEO_ID" \ "$(HTML "${VIDEO_NAME:-(Unnamed Video)}")" \ "$thumb" \ diff --git a/rawnet.css b/rawnet.css index d034a6d..99bb014 100644 --- a/rawnet.css +++ b/rawnet.css @@ -151,6 +151,13 @@ body.channels main .channel > .description h2 { @media(min-width: 84em) { .channel > .description, .video.thumb, .newvideo { max-width: 19%; } } @media(min-width: 104em) { .channel > .description, .video.thumb, .newvideo { max-width: 19em; } } +.video.thumb > a { + display: block; + color: inherit; + font-style: inherit; + text-decoration: inherit; +} + .video.thumb figure { position: absolute; top: 0; height: 11em; width: 100%; -- 2.39.2