2020-02-11 06:32:03 +00:00
|
|
|
{% extends 'layout.html' %}
|
2021-02-27 22:22:39 +00:00
|
|
|
{% load i18n %}
|
2021-05-11 22:14:42 +00:00
|
|
|
{% load markdown %}
|
2021-05-11 00:24:10 +00:00
|
|
|
{% load humanize %}
|
2021-02-28 18:00:36 +00:00
|
|
|
|
|
|
|
{% block title %}{{ author.name }}{% endblock %}
|
|
|
|
|
2020-02-11 06:32:03 +00:00
|
|
|
{% block content %}
|
2020-09-30 23:20:50 +00:00
|
|
|
<div class="block">
|
2021-02-23 21:04:24 +00:00
|
|
|
<div class="columns is-mobile">
|
2020-12-22 17:26:40 +00:00
|
|
|
<div class="column">
|
|
|
|
<h1 class="title">{{ author.name }}</h1>
|
|
|
|
</div>
|
|
|
|
{% if request.user.is_authenticated and perms.bookwyrm.edit_book %}
|
|
|
|
<div class="column is-narrow">
|
2020-12-31 01:36:35 +00:00
|
|
|
<a href="{{ author.local_path }}/edit">
|
2021-05-18 17:45:51 +00:00
|
|
|
<span class="icon icon-pencil" title="{% trans 'Edit Author' %}" aria-hidden="True"></span>
|
2021-06-14 22:55:26 +00:00
|
|
|
<span class="is-hidden-mobile">{% trans "Edit Author" %}</span>
|
2020-12-22 17:26:40 +00:00
|
|
|
</a>
|
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
</div>
|
|
|
|
</div>
|
2020-03-17 00:33:53 +00:00
|
|
|
|
2021-10-02 18:44:25 +00:00
|
|
|
<div class="block columns content" itemscope itemtype="https://schema.org/Person">
|
2021-05-23 19:17:14 +00:00
|
|
|
<meta itemprop="name" content="{{ author.name }}">
|
|
|
|
|
|
|
|
{% if author.aliases or author.born or author.died or author.wikipedia_link or author.openlibrary_key or author.inventaire_id %}
|
2021-05-24 10:51:18 +00:00
|
|
|
<div class="column is-two-fifths">
|
2021-05-24 15:17:12 +00:00
|
|
|
<div class="box py-2">
|
2021-05-11 00:24:10 +00:00
|
|
|
<dl>
|
|
|
|
{% if author.aliases %}
|
2021-05-24 15:17:12 +00:00
|
|
|
<div class="is-flex is-flex-wrap-wrap my-1">
|
2021-05-24 10:51:18 +00:00
|
|
|
<dt class="has-text-weight-bold mr-1">{% trans "Aliases:" %}</dt>
|
2021-05-24 10:36:48 +00:00
|
|
|
{% for alias in author.aliases %}
|
|
|
|
<dd itemprop="alternateName" content="{{alias}}">
|
2021-05-24 10:51:18 +00:00
|
|
|
{{alias}}{% if not forloop.last %}, {% endif %}
|
2021-05-24 10:36:48 +00:00
|
|
|
</dd>
|
|
|
|
{% endfor %}
|
2021-05-11 00:24:10 +00:00
|
|
|
</div>
|
|
|
|
{% endif %}
|
2021-05-24 15:17:12 +00:00
|
|
|
|
2021-05-11 00:24:10 +00:00
|
|
|
{% if author.born %}
|
2021-05-24 15:17:12 +00:00
|
|
|
<div class="is-flex my-1">
|
2021-05-24 10:51:18 +00:00
|
|
|
<dt class="has-text-weight-bold mr-1">{% trans "Born:" %}</dt>
|
2021-05-23 19:17:14 +00:00
|
|
|
<dd itemprop="birthDate">{{ author.born|naturalday }}</dd>
|
2021-05-11 00:24:10 +00:00
|
|
|
</div>
|
|
|
|
{% endif %}
|
2021-05-24 15:17:12 +00:00
|
|
|
|
2021-05-23 18:25:42 +00:00
|
|
|
{% if author.died %}
|
2021-05-24 15:17:12 +00:00
|
|
|
<div class="is-flex my-1">
|
2021-05-24 10:51:18 +00:00
|
|
|
<dt class="has-text-weight-bold mr-1">{% trans "Died:" %}</dt>
|
2021-05-23 19:17:14 +00:00
|
|
|
<dd itemprop="deathDate">{{ author.died|naturalday }}</dd>
|
2021-05-11 00:24:10 +00:00
|
|
|
</div>
|
|
|
|
{% endif %}
|
|
|
|
</dl>
|
2021-05-06 15:24:05 +00:00
|
|
|
|
2021-05-11 00:24:10 +00:00
|
|
|
{% if author.wikipedia_link %}
|
2021-05-24 15:17:12 +00:00
|
|
|
<p class="my-1">
|
2021-08-21 18:04:26 +00:00
|
|
|
<a itemprop="sameAs" href="{{ author.wikipedia_link }}" rel="noopener" target="_blank">
|
2021-05-23 19:17:14 +00:00
|
|
|
{% trans "Wikipedia" %}
|
|
|
|
</a>
|
|
|
|
</p>
|
2021-05-11 00:24:10 +00:00
|
|
|
{% endif %}
|
2021-05-24 10:51:18 +00:00
|
|
|
|
2021-05-11 00:24:10 +00:00
|
|
|
{% if author.openlibrary_key %}
|
2021-05-24 15:17:12 +00:00
|
|
|
<p class="my-1">
|
2021-05-24 10:36:48 +00:00
|
|
|
<a itemprop="sameAs" href="https://openlibrary.org/authors/{{ author.openlibrary_key }}" target="_blank" rel="noopener">
|
2021-05-23 19:17:14 +00:00
|
|
|
{% trans "View on OpenLibrary" %}
|
|
|
|
</a>
|
2021-05-11 00:24:10 +00:00
|
|
|
</p>
|
|
|
|
{% endif %}
|
2021-08-16 20:44:54 +00:00
|
|
|
|
2021-05-11 00:24:10 +00:00
|
|
|
{% if author.inventaire_id %}
|
2021-05-24 15:17:12 +00:00
|
|
|
<p class="my-1">
|
2021-05-24 10:36:48 +00:00
|
|
|
<a itemprop="sameAs" href="https://inventaire.io/entity/{{ author.inventaire_id }}" target="_blank" rel="noopener">
|
2021-05-23 19:17:14 +00:00
|
|
|
{% trans "View on Inventaire" %}
|
|
|
|
</a>
|
2021-05-11 00:24:10 +00:00
|
|
|
</p>
|
|
|
|
{% endif %}
|
2021-05-24 10:51:41 +00:00
|
|
|
|
|
|
|
{% if author.librarything_key %}
|
2021-05-24 15:17:12 +00:00
|
|
|
<p class="my-1">
|
2021-05-24 10:51:41 +00:00
|
|
|
<a itemprop="sameAs" href="https://www.librarything.com/author/{{ author.librarything_key }}" target="_blank" rel="noopener">
|
|
|
|
{% trans "View on LibraryThing" %}
|
|
|
|
</a>
|
|
|
|
</p>
|
|
|
|
{% endif %}
|
2021-08-16 20:44:54 +00:00
|
|
|
|
2021-05-24 10:51:41 +00:00
|
|
|
{% if author.goodreads_key %}
|
2021-05-24 15:17:12 +00:00
|
|
|
<p class="my-1">
|
2021-05-24 10:51:41 +00:00
|
|
|
<a itemprop="sameAs" href="https://www.goodreads.com/author/show/{{ author.goodreads_key }}" target="_blank" rel="noopener">
|
|
|
|
{% trans "View on Goodreads" %}
|
|
|
|
</a>
|
|
|
|
</p>
|
|
|
|
{% endif %}
|
2021-05-11 00:24:10 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
2020-12-22 17:26:40 +00:00
|
|
|
{% endif %}
|
2021-05-11 00:24:10 +00:00
|
|
|
<div class="column">
|
|
|
|
{% if author.bio %}
|
2021-05-11 22:14:42 +00:00
|
|
|
{{ author.bio|to_markdown|safe }}
|
2021-05-11 00:24:10 +00:00
|
|
|
{% endif %}
|
|
|
|
</div>
|
2020-03-17 00:33:53 +00:00
|
|
|
</div>
|
|
|
|
|
2020-09-30 23:20:50 +00:00
|
|
|
<div class="block">
|
2021-02-27 22:22:39 +00:00
|
|
|
<h3 class="title is-4">{% blocktrans with name=author.name %}Books by {{ name }}{% endblocktrans %}</h3>
|
2021-05-10 23:43:40 +00:00
|
|
|
<div class="columns is-multiline is-mobile">
|
|
|
|
{% for book in books %}
|
|
|
|
<div class="column is-one-fifth">
|
2021-08-16 20:44:54 +00:00
|
|
|
{% include 'landing/small-book.html' with book=book %}
|
2021-05-10 23:43:40 +00:00
|
|
|
</div>
|
|
|
|
{% endfor %}
|
|
|
|
</div>
|
2020-02-11 06:32:03 +00:00
|
|
|
</div>
|
|
|
|
{% endblock %}
|