diff --git a/src/main/handlebars/feed.handlebars b/src/main/handlebars/feed.handlebars index 6455a76..102ab4a 100755 --- a/src/main/handlebars/feed.handlebars +++ b/src/main/handlebars/feed.handlebars @@ -42,20 +42,35 @@ {{> partials/weather in=.}} - - {{#with images.0}} -
- {{title}}, {{date meta.dateTime format='d.m.Y H:i'}} -
- {{/with}} -
- {{#each images}} - {{#unless (equals @index 0)}} - {{title}}, {{date meta.dateTime format='d.m.Y H:i'}} - {{/unless}} - {{/each}} + {{! Content formed of a single video can be played back inline directly }} + {{#if (all (equals 1 (size images)) images.0.is.video)}} +
+ {{#with images.0}} +
+ +
+ {{/with}}
-
+ {{else}} + + {{#with images.0}} +
+ {{title}}, {{date meta.dateTime format='d.m.Y H:i'}} +
+ {{/with}} +
+ {{#each images}} + {{#unless (equals @index 0)}} +
+ {{title}}, {{date meta.dateTime format='d.m.Y H:i'}} +
+ {{/unless}} + {{/each}} +
+
+ {{/if}}
{{& content}} @@ -75,5 +90,20 @@
{{/inline}} {{#*inline "scripts"}} + {{/inline}} {{/layout}} \ No newline at end of file diff --git a/src/main/handlebars/layout.handlebars b/src/main/handlebars/layout.handlebars index 92c9be5..bb70a9d 100755 --- a/src/main/handlebars/layout.handlebars +++ b/src/main/handlebars/layout.handlebars @@ -598,22 +598,26 @@ display: flex; isolation: isolate; - img { - display: block; + .image { + position: relative; border: .25rem solid white; border-radius: .35rem; - width: var(--_size); - aspect-ratio: 1 / 1; - object-fit: cover; box-shadow: .5rem .5rem 1rem rgb(0 0 0 / .2); transition: margin ease-in-out 150ms; + width: var(--_size); + height: var(--_size); + } + + .image img { + width: 100%; + height: 100%; } - img:not(:first-child) { + .image:not(:first-child) { margin-left: calc(-1 * var(--_overlap)); } - &:hover img:not(:first-child) { + &:hover .image:not(:first-child) { margin-left: 1rem; } }