Skip to content

Commit f74f551

Browse files
committed
Fix documentation about galery
Galery can be fixed by using internal resolution. Adding the lang as well allows to make the target URL lang-aware even if the image is just duplicated. Example file has been fixed as well even if it might not be used.
1 parent 9620795 commit f74f551

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Diff for: docs/content/documentation/content/image-processing/index.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -153,7 +153,7 @@ picture gallery with the following shortcode named `gallery.html`:
153153
{% for asset in page.assets -%}
154154
{%- if asset is matching("[.](jpg|png)$") -%}
155155
{% set image = resize_image(path=asset, width=240, height=180) %}
156-
<a href="{{ get_url(path=asset) }}" target="_blank">
156+
<a href="{{ get_url(path='@' ~ asset, lang=lang) }}" target="_blank">
157157
<img src="{{ image.url }}" />
158158
</a>
159159
{%- endif %}

Diff for: docs/templates/shortcodes/gallery.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
{% for asset in page.assets -%}
33
{%- if asset is matching("[.](jpg|png)$") -%}
44
{% set image = resize_image(path=asset, width=240, height=180) %}
5-
<a href="{{ get_url(path=asset) }}" target="_blank">
5+
<a href="{{ get_url(path='@' ~ asset, lang=lang) }}" target="_blank">
66
<img src="{{ image.url }}" />
77
</a>
88
{%- endif %}

0 commit comments

Comments
 (0)