Browse Source

fix relative path specifier for photoswipe import (fix #545)

main
Simon Conseil 4 weeks ago
parent
commit
83297c83e4
  1. 2
      src/sigal/themes/colorbox/templates/album.html
  2. 2
      src/sigal/themes/photoswipe/templates/album_items.html
  3. 2
      src/sigal/utils.py

2
src/sigal/themes/colorbox/templates/album.html

@ -41,7 +41,7 @@
<a href="{{ media.url }}" title="{{ media.title }}"
{% endif %}
>
<img src="{{ media.thumbnail }}" alt="{{ media.url }}"
<img src="{{ media.thumbnail }}" alt="{{ media.title }}"
title="{{ media.title }}">
</a>
</div>

2
src/sigal/themes/photoswipe/templates/album_items.html

@ -19,7 +19,7 @@
data-pswp-height="600"
{% endif %}
>
<img src="{{ media.thumbnail }}" alt="{{ media.url }}" />
<img src="{{ media.thumbnail }}" alt="{{ media.title }}" />
</a>
<div class="pswp-caption-content">
{{ img_description(media, with_big=False) }}

2
src/sigal/utils.py

@ -82,6 +82,8 @@ def url_from_path(path):
if os.sep != "/":
path = "/".join(path.split(os.sep))
if path[0] != ".":
path = f"./{path}"
return quote(path)

Loading…
Cancel
Save