diff --git a/pygeoapi/templates/collections/items/index.html b/pygeoapi/templates/collections/items/index.html
index a55c47c..635bce4 100644
--- a/pygeoapi/templates/collections/items/index.html
+++ b/pygeoapi/templates/collections/items/index.html
@@ -88,13 +88,13 @@
{% for ft in data['features'] %}
- | {{ ft.id }} |
+ {{ ft.id | truncate( 12 ) }} |
{% if data['title_field'] %}
- {{ ft['properties'][data['title_field']] }} |
+ {{ ft['properties'][data['title_field']] | truncate( 35 ) }} |
{% endif %}
{% for k, v in ft['properties'].items() %}
- {% if loop.index < 5 and k != data['id_field'] and k != data['title_field'] %}
- {{ v | urlize(20) }} |
+ {% if loop.index < 5 and k not in [data['id_field'], data['title_field'], 'extent'] %}
+ {{ v | truncate( 35 ) }} |
{% endif %}
{% endfor %}
@@ -121,7 +121,7 @@
attribution: '{{ config['server']['map']['attribution'] }}'
}
));
- var geojson_data = {{ data['features'] |to_json }};
+ var geojson_data = {{ data['features'] | to_json }};
var items = new L.GeoJSON(geojson_data, {
onEachFeature: function (feature, layer) {
var url = '{{ data['items_path'] }}/' + feature.id + '?f=html';
diff --git a/pygeoapi/templates/collections/items/item.html b/pygeoapi/templates/collections/items/item.html
index 195567a..22fc0df 100644
--- a/pygeoapi/templates/collections/items/item.html
+++ b/pygeoapi/templates/collections/items/item.html
@@ -6,7 +6,7 @@
{% if val|length and val.lower().endswith(('.jpg', '.jpeg', '.png', '.gif', '.bmp')) %}
{# Ends with image extension: render img element with link to image #}
- {% elif v is string, boolean, integer, float, number %}
+ {% elif v is string or v is boolean or v is integer or v is float or v is number %}
{{ val | urlize() | wordwrap() }}
{% elif v is mapping %}
{# this is a dict #}