diff options
-rw-r--r-- | fietsboek/templates/details.jinja2 | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/fietsboek/templates/details.jinja2 b/fietsboek/templates/details.jinja2 index b7ebefe..7307270 100644 --- a/fietsboek/templates/details.jinja2 +++ b/fietsboek/templates/details.jinja2 @@ -3,7 +3,18 @@ {% block content %} <div class="container"> - <h1>{{ track.title | default(_("page.details.title"), true) }}</h1> + <h1> + {{ track.title | default(_("page.details.title"), true) }} + {% if request.identity %} + <span style="display: inline-flex; vertical-align: middle;"> + {% if request.identity in track.favourees %} + <i class="bi bi-star-fill favourite-star" data-track-id="{{ track.id }}"></i> + {% else %} + <i class="bi bi-star favourite-star" data-track-id="{{ track.id }}"></i> + {% endif %} + </span> + {% endif %} + </h1> {% if show_edit_link %} <div class="btn-group" role="group"> <a class="btn btn-success" href="{{ request.route_path('edit', track_id=track.id) }}"><i class="bi-pencil-square"></i> {{ _("page.details.edit") }}</a> |