Skip to content

Commit

Permalink
Merge pull request #3454 from Guanchishan/patch-3
Browse files Browse the repository at this point in the history
show Wikidata link on author page
  • Loading branch information
mouse-reeve authored Oct 17, 2024
2 parents 7ecf3b6 + 0a3fc58 commit 20026b9
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion bookwyrm/templates/author/author.html
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ <h1 class="title">{{ author.name }}</h1>
<meta itemprop="name" content="{{ author.name }}">

{% firstof author.aliases author.born author.died as details %}
{% firstof author.wikipedia_link author.website author.openlibrary_key author.inventaire_id author.isni author.isfdb as links %}
{% firstof author.wikipedia_link author.website author.openlibrary_key author.inventaire_id author.isni author.isfdb author.wikidata as links %}
{% if details or links %}
<div class="column is-3">
{% if details %}
Expand Down Expand Up @@ -73,6 +73,14 @@ <h2 class="title is-4">{% trans "External links" %}</h2>
</div>
{% endif %}

{% if author.wikidata %}
<div>
<a itemprop="sameAs" href="https://www.wikidata.org/wiki/{{ author.wikidata }}" rel="nofollow noopener noreferrer" target="_blank">
{% trans "View on Wikidata" %}
</a>
</div>
{% endif %}

{% if author.website %}
<div>
<a itemprop="sameAs" href="{{ author.website }}" rel="nofollow noopener noreferrer" target="_blank">
Expand Down

0 comments on commit 20026b9

Please sign in to comment.