feat: home page template with carousel, news, about, services, team sections

- Extends base.html, uses shared image macro for resize_image
- Refactored img shortcode to forward to macros/image.html (DRY)
- News pulled via get_page from content/news.md
- Notfall section skipped (was unpublished in grav)
- Map call commented out until shortcode lands in Task 20
This commit is contained in:
2026-05-20 22:39:59 +02:00
parent 218b82372d
commit 9cf54f9459
3 changed files with 119 additions and 22 deletions
+15
View File
@@ -0,0 +1,15 @@
{# Image-rendering macro, used both by templates (directly via import)
and indirectly by the `img` shortcode (which forwards to it). #}
{% macro render(src, width, alt="", class="") %}
{%- set source_path = "static/images/" ~ src -%}
{%- set resized = resize_image(path=source_path, width=width, op="fit_width", quality=85) -%}
<img
src="{{ resized.url }}"
width="{{ resized.width }}"
height="{{ resized.height }}"
alt="{{ alt }}"
{%- if class %} class="{{ class }}"{% endif %}
loading="lazy"
>
{% endmacro render %}