fix: use page.collection() for tracker descending date order

page.children ignores the order.by/dir frontmatter config; page.collection()
applies it, so entries now render newest-first as intended.

Also wire Grav asset pipeline into base template (assets.css/js tags).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-06-18 22:34:19 +02:00
parent f0768c297b
commit c63378740c
2 changed files with 4 additions and 1 deletions
@@ -9,6 +9,8 @@
<link href="https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,400&family=DM+Serif+Display:ital@0;1&display=swap" rel="stylesheet"> <link href="https://fonts.googleapis.com/css2?family=DM+Sans:ital,opsz,wght@0,9..40,400;0,9..40,500;0,9..40,600;1,9..40,400&family=DM+Serif+Display:ital@0;1&display=swap" rel="stylesheet">
<link rel="stylesheet" href="{{ url('theme://css/tokens.css') }}"> <link rel="stylesheet" href="{{ url('theme://css/tokens.css') }}">
<link rel="stylesheet" href="{{ url('theme://css/style.css') }}"> <link rel="stylesheet" href="{{ url('theme://css/style.css') }}">
{{ assets.css()|raw }}
{{ assets.js()|raw }}
</head> </head>
<body class="{% if page.template == 'map' %}map-page{% endif %}"> <body class="{% if page.template == 'map' %}map-page{% endif %}">
<header class="site-header"> <header class="site-header">
@@ -22,5 +24,6 @@
<main class="site-main"> <main class="site-main">
{% block content %}{% endblock %} {% block content %}{% endblock %}
</main> </main>
{{ assets.js('bottom')|raw }}
</body> </body>
</html> </html>
@@ -1,7 +1,7 @@
{% extends 'default.html.twig' %} {% extends 'default.html.twig' %}
{% block content %} {% block content %}
{% set entries = page.children %} {% set entries = page.collection() %}
{# Collect GPS entries for mini-map #} {# Collect GPS entries for mini-map #}
{% set map_entries = [] %} {% set map_entries = [] %}