Updated template and content

This commit is contained in:
Bashy 2025-11-10 21:04:56 +01:00
parent 142a478a6a
commit 9dd5ca83c5
33 changed files with 415 additions and 222 deletions

View file

@ -1,22 +1,23 @@
<section id="feed_preview">
<div class="feed_preview">
<% counter = 3 %>
<% page.posts.forEach(function(post) { %>
<% if (counter != 0) { %>
<% isEvent = false %>
<% post.tags.data.forEach(function(tag) { %>
<% if (tag.name == "Events") { %>
<% isEvent = true %>
<% } %>
<% }); %>
<div class="feed_preview">
<% counter = 3 %>
<% page.posts.forEach(function(post) { %>
<% if (counter != 0) { %>
<% isEvent = false %>
<% post.tags.data.forEach(function(tag) { %>
<% if (tag.name == "Events") { %>
<% isEvent = true %>
<% if (isEvent == false) { %>
<%- include('./../post_feed',
{ post: post,
source: "index"
}) %>
<% counter = counter - 1 %>
<% } %>
<% }); %>
<% if (isEvent == false) { %>
<%- include('./../post_feed', { post: post }) %>
<% counter = counter - 1 %>
<% } %>
<% } %>
<% }); %>
</div>
<% }); %>
</div>
</section>

View file

@ -1,13 +1,11 @@
<section class="event">
<% counter = false %>
<% counter = 2 %>
<% page.posts.forEach(function(post) { %>
<% post.tags.data.forEach(function(tag) { %>
<% if ( (tag.name == "Events") && (counter == false) ) { %>
<%- include('./../post_event', { post: post }) %>
<% counter = true %>
<% if ( (tag.name == "Events") && (counter != 0) ) { %>
<%- include('./../post_feed', { post: post, source: "index", event: counter }) %>
<% counter = counter - 1 %>
<% } %>
<% }); %>
<% }); %>
</section>