Refine homepage project discovery
Deploy production / deploy (push) Successful in 5s

This commit is contained in:
2026-08-12 07:19:27 -07:00
parent 4223691e43
commit 84fad22f4c
4 changed files with 51 additions and 25 deletions
+1 -1
View File
@@ -9,7 +9,7 @@
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin>
<link href="https://fonts.googleapis.com/css2?family=IBM+Plex+Mono:wght@400;500;600&family=Inter:wght@400;500&family=Playfair+Display:ital,wght@0,600;0,700;1,500;1,600&display=swap" rel="stylesheet">
<link rel="icon" href="{{ '/static/favicon.svg'|url }}" type="image/svg+xml">
<link rel="stylesheet" href="{{ '/static/style.css'|url }}?v=11">
<link rel="stylesheet" href="{{ '/static/style.css'|url }}?v=12">
<script src="{{ '/static/tags.js'|url }}?v=1" defer></script>
<script src="{{ '/static/activity.js'|url }}?v=1" defer></script>
</head>
+28 -11
View File
@@ -21,14 +21,12 @@
{% if entries.append(item) %}{% endif %}
{% endfor %}
{% endfor %}
{% for project in site.query('/projects') %}
{% if project._model == 'project' %}
{% set devlog = site.get(project.path ~ '/devlog') %}
{% if devlog %}
{% for entry in devlog.children %}
{% if entries.append(entry) %}{% endif %}
{% endfor %}
{% endif %}
{% for project in site.query('/projects').filter(F._model == 'project') %}
{% set devlog = site.get(project.path ~ '/devlog') %}
{% if devlog %}
{% for entry in devlog.children %}
{% if entries.append(entry) %}{% endif %}
{% endfor %}
{% endif %}
{% endfor %}
{% for item in entries|sort(attribute='date', reverse=true) %}
@@ -56,14 +54,33 @@
</div>
<div class="featured-project-list">
{% for project in site.query('/projects').filter(F._model == 'project').filter(F.featured == true).order_by('featured_order', '-date').limit(3) %}
<article class="featured-project">
<div class="entry-meta">
{% set devlog = site.get(project.path ~ '/devlog') %}
{% set latest_activity = devlog.children.order_by('-date', '-source_commit_time').first() if devlog else none %}
<article class="featured-project-card">
<div class="featured-project-meta">
<span class="label">{{ project.status }}</span>
<time datetime="{{ project.date }}">{{ project.date|dateformat('YYYY.MM.dd') }}</time>
</div>
<h2><a href="{{ project|url }}">{{ project.title }}</a></h2>
<p>{{ project.summary }}</p>
<a class="read-more" href="{{ project|url }}">View project →</a>
{% if project.technology_labels %}
<div class="featured-project-technologies" aria-label="Technologies">
{% for technology in project.technology_labels[:4] %}
{% set parts = technology.split('\t', 1) %}
<span>{{ parts[1] if parts|length > 1 else parts[0] }}</span>
{% endfor %}
</div>
{% endif %}
{% if latest_activity %}
<div class="featured-project-latest">
<span>Latest activity</span>
<a href="{{ latest_activity|url }}"><time datetime="{{ latest_activity.date }}">{{ latest_activity.date|dateformat('YYYY.MM.dd') }}</time> {{ latest_activity.title }} →</a>
</div>
{% endif %}
<div class="featured-project-actions">
<a href="{{ project|url }}">View project →</a>
{% if devlog %}<a href="{{ devlog|url }}">Devlog →</a>{% endif %}
</div>
</article>
{% else %}
<p class="featured-projects-empty">Selected projects will appear here.</p>