Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -130,6 +130,7 @@ jobs:
pip3 install -r requirements-pubsub.txt
pip3 install .
pip3 install GDAL==`gdal-config --version`
pip3 install "pyproj<3.8"
- name: setup test data ⚙️
run: |
pybabel compile -d locale -l es
Expand Down
4 changes: 3 additions & 1 deletion pygeoapi/templates/collections/items/item.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@
{# Optionally renders an img element, otherwise standard value or link rendering #}
{% macro render_item_value(v, width) -%}
{% set val = v | string | trim %}
{% if val|length and val.lower().endswith(('.jpg', '.jpeg', '.png', '.gif', '.bmp')) %}
{% if (val|length and val.lower().startswith(('http://', 'https://')) and
val.lower().endswith(('.jpg', '.jpeg', '.png', '.gif', '.bmp'))
) %}
{# Ends with image extension: render img element with link to image #}
<a href="{{ val }}"><img src="{{ val }}" alt="{{ val.split('/') | last }}" width="{{ width }}"/></a>
{% elif v is string or v is number %}
Expand Down
Loading