-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.html
More file actions
50 lines (46 loc) · 1.87 KB
/
index.html
File metadata and controls
50 lines (46 loc) · 1.87 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
---
layout: default
title: News
description: Insights and Updates from the AML Lab
---
<div class="news-list">
{% for post in paginator.posts %}
<article class="post-card">
<h2 class="post-card-title"><a href="{{ post.url | relative_url }}">{{ post.title }}</a></h2>
<div class="post-meta">
<time datetime="{{ post.date | date_to_xmlschema }}">{{ post.date | date: "%B %-d, %Y" }}</time>
{% if post.author %} · {{ post.author }}{% endif %}
{% if post.categories.size > 0 %}
· {% for cat in post.categories %}<span class="post-tag">{{ cat }}</span>{% unless forloop.last %} {% endunless %}{% endfor %}
{% endif %}
</div>
<div class="post-excerpt">
{{ post.excerpt | strip_html | truncatewords: 60 }}
</div>
<a href="{{ post.url | relative_url }}" class="read-more-link">Read more →</a>
</article>
{% endfor %}
</div>
{% if paginator.total_pages > 1 %}
<nav class="news-pagination" aria-label="News pages">
{% if paginator.previous_page %}
<a href="{{ paginator.previous_page_path | relative_url }}" class="pagination-btn">« Newer</a>
{% else %}
<span class="pagination-btn disabled">« Newer</span>
{% endif %}
{% for page_num in (1..paginator.total_pages) %}
{% if page_num == paginator.page %}
<span class="pagination-btn current">{{ page_num }}</span>
{% elsif page_num == 1 %}
<a href="{{ '/news/' | relative_url }}" class="pagination-btn">{{ page_num }}</a>
{% else %}
<a href="{{ site.paginate_path | relative_url | replace: ':num', page_num }}" class="pagination-btn">{{ page_num }}</a>
{% endif %}
{% endfor %}
{% if paginator.next_page %}
<a href="{{ paginator.next_page_path | relative_url }}" class="pagination-btn">Older »</a>
{% else %}
<span class="pagination-btn disabled">Older »</span>
{% endif %}
</nav>
{% endif %}