Fix weekly posts
This commit is contained in:
@@ -52,36 +52,36 @@ article class="h-entry"
|
|||||||
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 flex gap-4"
|
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 flex gap-4"
|
||||||
div class="grow" hx-get="/post/top_tracks/#{post.slug}" hx-trigger="load"
|
div class="grow" hx-get="/post/top_tracks/#{post.slug}" hx-trigger="load"
|
||||||
|
|
||||||
- if past_movies.count > 0
|
- if past_movies.count > 0
|
||||||
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 mb-4"
|
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 mb-4"
|
||||||
h3 class="text-xl" Movies watched
|
h3 class="text-xl" Movies watched
|
||||||
div class="flex gap-4 pb-4 mt-4"
|
div class="flex gap-4 pb-4 mt-4"
|
||||||
- past_movies.map do |movie|
|
- past_movies.map do |movie|
|
||||||
a href=movie.url
|
a href=movie.url
|
||||||
figure class="w-24"
|
figure class="w-24"
|
||||||
img class="rounded hover:opacity-80" src=movie.poster
|
img class="rounded hover:opacity-80" src=movie.poster
|
||||||
figcaption= movie.title
|
figcaption= movie.title
|
||||||
hr
|
hr
|
||||||
- if text_posts.count > 0 || photo_posts.count > 0
|
- if text_posts.count > 0 || photo_posts.count > 0
|
||||||
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 mb-4"
|
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 mb-4"
|
||||||
h2 class="text-sm mb-0" This week, years ago
|
h2 class="text-sm mb-0" This week, years ago
|
||||||
- if text_posts.count > 0
|
- if text_posts.count > 0
|
||||||
div class="block grow bg-blue-100 dark:bg-blue-600 rounded px-4 py-2 mb-12"
|
div class="block grow bg-blue-100 dark:bg-blue-600 rounded px-4 py-2 mb-12"
|
||||||
ul class="mt-0"
|
ul class="mt-0"
|
||||||
- text_posts.each do |past_post|
|
- text_posts.each do |past_post|
|
||||||
li class="m-0"
|
li class="m-0"
|
||||||
a class="hover:underline" href=past_post.permalink
|
a class="hover:underline" href=past_post.permalink
|
||||||
= "#{past_post.display_title} (#{past_post.published_at.year})"
|
= "#{past_post.display_title} (#{past_post.published_at.year})"
|
||||||
|
|
||||||
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 flex"
|
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 flex"
|
||||||
- photo_posts.group_by{ |p| p.published_at.year }.each do |year, posts|
|
- photo_posts.group_by{ |p| p.published_at.year }.each do |year, posts|
|
||||||
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200"
|
|
||||||
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200"
|
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200"
|
||||||
= year
|
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200"
|
||||||
div class="grid grid-cols-3 gap-4 mb-4 max-w-prose mx-auto"
|
= year
|
||||||
-posts.each do |post|
|
div class="grid grid-cols-3 gap-4 mb-4 max-w-prose mx-auto"
|
||||||
== render "shared/photo_post", post: post
|
-posts.each do |post|
|
||||||
div class="mb-4 max-w-screen-md mx-auto border-t-4 border-solid border-gray-400 dark:border-gray-600"
|
== render "shared/photo_post", post: post
|
||||||
|
div class="mb-4 max-w-screen-md mx-auto border-t-4 border-solid border-gray-400 dark:border-gray-600"
|
||||||
|
|
||||||
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 flex"
|
div class="max-w-prose mx-auto text-gray-600 dark:text-gray-200 flex"
|
||||||
div class=""
|
div class=""
|
||||||
|
Reference in New Issue
Block a user