From 2616803f47c3bc1162276ba85b8feb18eeb5374c Mon Sep 17 00:00:00 2001 From: BBaoVanC Date: Fri, 8 Oct 2021 22:52:58 -0500 Subject: [PATCH] Support featured videos (instead of image) --- assets/css/bobastyle.css | 4 ++-- layouts/_default/list.html | 10 +++++++++- layouts/shortcodes/video.html | 4 ++++ 3 files changed, 15 insertions(+), 3 deletions(-) create mode 100644 layouts/shortcodes/video.html diff --git a/assets/css/bobastyle.css b/assets/css/bobastyle.css index a19f698..bc794e5 100644 --- a/assets/css/bobastyle.css +++ b/assets/css/bobastyle.css @@ -21,7 +21,7 @@ margin-top: 10px; } -.post-image { +.post-media { margin-top: 15px; } @@ -91,7 +91,7 @@ body { max-width: 720px; } -img { +img, video { max-width: 100%; } diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 7ed6c15..dfe2ccd 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -69,9 +69,17 @@ {{ end }} {{ with .Resources.GetMatch "feature" }} -
+
{{ .Title }}
+ {{ else }} + {{ with .Resources.GetMatch "feature-video" }} +
+ +
+ {{ end }} {{ end }}
diff --git a/layouts/shortcodes/video.html b/layouts/shortcodes/video.html new file mode 100644 index 0000000..3e852a2 --- /dev/null +++ b/layouts/shortcodes/video.html @@ -0,0 +1,4 @@ +