debug: add raw URL debug output

This commit is contained in:
Ricardo
2026-01-28 22:06:28 +01:00
parent 0e82a00739
commit f9af152efd

View File

@@ -22,10 +22,12 @@ permalink: /photos/
<pre style="display:none" class="debug-photo">{{ post.data.photo | dump | safe }}</pre>
<div class="photo-gallery">
{% for img in post.data.photo %}
<pre style="display:none" class="debug-url">RAW:{{ img.url }}:END</pre>
{% set photoUrl = img.url %}
{% if photoUrl and photoUrl[0] != '/' and 'http' not in photoUrl %}
{% set photoUrl = '/' + photoUrl %}
{% endif %}
<pre style="display:none" class="debug-final">FINAL:{{ photoUrl }}:END</pre>
<a href="{{ post.url }}" class="photo-link">
<img src="{{ photoUrl }}" alt="{{ img.alt | default('Photo') }}" class="u-photo" loading="lazy">
</a>