@@ -59,7 +59,7 @@ <h2 class="page-title">
5959 < div class ="btn-list ">
6060 {% if activities|length > 0 %}
6161 < div class ="btn-group ">
62- < a href ="{{ url_for('list_activities_year', year=year, aspect='list', activity_type=filter_activity_type, gear=filter_gear, intensity=filter_intensity, type=filter_type, source=filter_source, sort=sort_by, order=sort_order) }} " class ="btn btn-outline-primary ">
62+ < a href ="{{ url_for('list_activities_year', year=year, aspect='list', activity_type=filter_activity_type, gear=filter_gear, intensity=filter_intensity, type=filter_type, source=filter_source, tag=filter_tag, sort=sort_by, order=sort_order) }} " class ="btn btn-outline-primary ">
6363 < svg xmlns ="http://www.w3.org/2000/svg " class ="icon icon-tabler icon-tabler-table " width ="24 " height ="24 " viewBox ="0 0 24 24 " stroke-width ="2 " stroke ="currentColor " fill ="none " stroke-linecap ="round " stroke-linejoin ="round ">
6464 < path stroke ="none " d ="M0 0h24v24H0z " fill ="none "> </ path >
6565 < path d ="M3 5a2 2 0 0 1 2 -2h14a2 2 0 0 1 2 2v14a2 2 0 0 1 -2 2h-14a2 2 0 0 1 -2 -2v-14z "> </ path >
@@ -68,7 +68,7 @@ <h2 class="page-title">
6868 </ svg >
6969 List
7070 </ a >
71- < a href ="{{ url_for('list_activities_year', year=year, aspect='feed', activity_type=filter_activity_type, gear=filter_gear, intensity=filter_intensity, type=filter_type, source=filter_source, sort=sort_by, order=sort_order) }} " class ="btn btn-outline-primary ">
71+ < a href ="{{ url_for('list_activities_year', year=year, aspect='feed', activity_type=filter_activity_type, gear=filter_gear, intensity=filter_intensity, type=filter_type, source=filter_source, tag=filter_tag, sort=sort_by, order=sort_order) }} " class ="btn btn-outline-primary ">
7272 < svg xmlns ="http://www.w3.org/2000/svg " class ="icon icon-tabler icon-tabler-layout-cards " width ="24 " height ="24 " viewBox ="0 0 24 24 " stroke-width ="2 " stroke ="currentColor " fill ="none " stroke-linecap ="round " stroke-linejoin ="round ">
7373 < path stroke ="none " d ="M0 0h24v24H0z " fill ="none "> </ path >
7474 < path d ="M4 4m0 2a2 2 0 0 1 2 -2h2a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-2a2 2 0 0 1 -2 -2z "> </ path >
@@ -209,6 +209,18 @@ <h2 class="page-title">
209209 {% endfor %}
210210 </ select >
211211 </ div >
212+
213+ < div class ="col-md-2 ">
214+ < label class ="form-label "> Tag</ label >
215+ < select class ="form-select " name ="tag " onchange ="this.form.submit() ">
216+ < option value =""> All</ option >
217+ {% for tag in unique_tags %}
218+ < option value ="{{ tag }} " {% if tag == filter_tag %}selected{% endif %} >
219+ {{ tag }}
220+ </ option >
221+ {% endfor %}
222+ </ select >
223+ </ div >
212224 </ div >
213225
214226 < div class ="row g-3 mt-2 ">
@@ -438,6 +450,16 @@ <h3 class="mb-1">
438450 < span class ="mx-2 "> ·</ span >
439451 < a href ="{{ url_for('settings_activity_types_get', key=activity.activity_type_key) }} " class ="text-reset "> {{ activity_types.name(activity.activity_type_key) }}</ a >
440452 </ div >
453+ {% if activity.tags %}
454+ < div class ="mt-1 ">
455+ {% for tag in activity.tags %}
456+ {% set tag_color = tag|tag_to_color %}
457+ < a href ="{{ url_for('list_activities_year', year=year, aspect=aspect, tag=tag) }} " class ="text-decoration-none ">
458+ < span class ="badge bg-{{ tag_color }} text-{{ tag_color }}-fg "> {{ tag }}</ span >
459+ </ a >
460+ {% endfor %}
461+ </ div >
462+ {% endif %}
441463 </ div >
442464 < div class ="text-end ">
443465 {% if activity.commute %}
0 commit comments