Merge branch 'main' into production

This commit is contained in:
Mouse Reeve 2021-12-29 16:21:28 -08:00
commit 2c5265a117
49 changed files with 941 additions and 717 deletions

View file

@ -31,7 +31,7 @@
</div>
{% endif %}
{% endfor %}
<div class="is-main block" id="anchor-{{ status.id }}">
<div class="is-main block">
{% include 'snippets/status/status.html' with status=status main=True %}
</div>

View file

@ -1,29 +1,31 @@
{% extends 'components/card.html' %}
{% load i18n %}
{% block card-header %}
<h3 class="card-header-title has-background-success-dark has-text-white">
<span class="icon is-size-3 mr-2" aria-hidden="true">📚</span>
<span class="icon is-size-3 mr-2" aria-hidden="true"></span>
{% blocktrans %}{{ year }} in the books{% endblocktrans %}
</h3>
<article class="card">
<header class="card-header has-background-success-dark">
<h3 class="card-header-title has-text-white">
<span class="icon is-size-3 mr-2" aria-hidden="true">📚</span>
<span class="icon is-size-3 mr-2" aria-hidden="true"></span>
{% blocktrans %}{{ year }} in the books{% endblocktrans %}
</h3>
<div class="card-header-icon has-background-success-dark has-text-white">
{% trans "Dismiss message" as button_text %}
<button class="delete set-display" type="button" data-id="hide_annual_summary_{{ year }}" data-value="true">
<span>{% trans "Dismiss message" %}</span>
</button>
</div>
{% endblock %}
<div class="card-header-icon has-text-white">
{% trans "Dismiss message" as button_text %}
<button class="delete set-display" type="button" data-id="hide_annual_summary_{{ year }}" data-value="true">
<span>{% trans "Dismiss message" %}</span>
</button>
</div>
</header>
{% block card-content %}
<p class="mb-3">
{% blocktrans %}The end of the year is the best moment to take stock of all the books read during the last 12 months. How many pages have you read? Which book is your best-rated of the year? We compiled these stats, and more!{% endblocktrans %}
</p>
<section class="card-content">
<p class="mb-3">
{% blocktrans %}The end of the year is the best moment to take stock of all the books read during the last 12 months. How many pages have you read? Which book is your best-rated of the year? We compiled these stats, and more!{% endblocktrans %}
</p>
<p>
<a href="{% url 'annual-summary' request.user.localname year %}" class="button is-success has-background-success-dark">
{% blocktrans %}Discover your stats for {{ year }}!{% endblocktrans %}
</a>
</p>
{% endblock %}
<p>
<a href="{% url 'annual-summary' request.user.localname year %}" class="button is-success has-background-success-dark">
{% blocktrans %}Discover your stats for {{ year }}!{% endblocktrans %}
</a>
</p>
</section>
</article>

View file

@ -10,7 +10,12 @@
<div class="modal-background"></div>
<div class="modal-card is-fullwidth">
<header class="modal-card-head">
<img class="image logo mr-2" src="{% if site.logo_small %}{% get_media_prefix %}{{ site.logo_small }}{% else %}{% static "images/logo-small.png" %}{% endif %}" aria-hidden="true">
<img
class="image logo mr-2"
src="{% if site.logo_small %}{% get_media_prefix %}{{ site.logo_small }}{% else %}{% static "images/logo-small.png" %}{% endif %}"
aria-hidden="true"
alt="{{ site.name }}"
>
<h1 class="modal-card-title" id="get_started_header">
{% blocktrans %}Welcome to {{ site_name }}!{% endblocktrans %}
<span class="subtitle is-block">

View file

@ -13,13 +13,26 @@
<div class="column is-two-thirds">
<div class="block">
<label class="label" for="id_name">{% trans "Display name:" %}</label>
<input type="text" name="name" maxlength="100" class="input" id="id_name" placeholder="{{ user.localname }}" value="{% if request.user.name %}{{ request.user.name }}{% endif %}">
<input
type="text"
name="name"
maxlength="100"
class="input"
id="id_name"
placeholder="{{ user.localname }}"
value="{% if request.user.name %}{{ request.user.name }}{% endif %}"
>
{% include 'snippets/form_errors.html' with errors_list=form.name.errors id="desc_name" %}
</div>
<div class="block">
<label class="label" for="id_summary">{% trans "Summary:" %}</label>
<textarea name="summary" cols="None" rows="None" class="textarea" id="id_summary" placeholder="{% trans 'A little bit about you' %}">{% if request.user.summary %}{{ request.user.summary }}{% endif %}</textarea>
<textarea
name="summary"
class="textarea"
id="id_summary"
placeholder="{% trans 'A little bit about you' %}"
>{% if request.user.summary %}{{ request.user.summary }}{% endif %}</textarea>
{% include 'snippets/form_errors.html' with errors_list=form.summary.errors id="desc_summary" %}
</div>

View file

@ -54,13 +54,13 @@
{% csrf_token %}
<input type="hidden" name="item" value="{{ item.id }}">
<input type="hidden" name="approved" value="true">
<button class="button">{% trans "Approve" %}</button>
<button type="submit" class="button">{% trans "Approve" %}</button>
</form>
<form class="control" method="POST" action="{% url 'list-curate' list.id %}">
{% csrf_token %}
<input type="hidden" name="item" value="{{ item.id }}">
<input type="hidden" name="approved" value="false">
<button class="button is-danger is-light">{% trans "Discard" %}</button>
<button type="submit" class="button is-danger is-light">{% trans "Discard" %}</button>
</form>
</dd>
</div>

View file

@ -18,24 +18,73 @@
<fieldset class="field">
<legend class="label">{% trans "List curation:" %}</legend>
<label class="field" data-hides="list_group_selector">
<input type="radio" name="curation" value="closed"{% if not list or list.curation == 'closed' %} checked{% endif %}> {% trans "Closed" %}
<p class="help mb-2">{% trans "Only you can add and remove books to this list" %}</p>
</label>
<div class="field" data-hides="list_group_selector">
<input
type="radio"
name="curation"
value="closed"
aria-described-by="id_curation_closed_help"
id="id_curation_closed"
{% if not list or list.curation == 'closed' %} checked{% endif %}
>
<label for="id_curation_closed">
{% trans "Closed" %}
</label>
<p class="help mb-2" id="id_curation_closed_help">
{% trans "Only you can add and remove books to this list" %}
</p>
</div>
<label class="field" data-hides="list_group_selector">
<input type="radio" name="curation" value="curated"{% if list.curation == 'curated' %} checked{% endif %}> {% trans "Curated" %}
<p class="help mb-2">{% trans "Anyone can suggest books, subject to your approval" %}</p>
</label>
<div class="field" data-hides="list_group_selector">
<input
type="radio"
name="curation"
value="curated"
aria-described-by="id_curation_curated_help"
id="id_curation_curated"
{% if list.curation == 'curated' %} checked{% endif %}
>
<label for="id_curation_curated">
{% trans "Curated" %}
</label>
<p class="help mb-2" id="id_curation_curated_help">
{% trans "Anyone can suggest books, subject to your approval" %}
</p>
</div>
<label class="field" data-hides="list_group_selector">
<input type="radio" name="curation" value="open"{% if list.curation == 'open' %} checked{% endif %}> {% trans "Open" context "curation type" %}
<p class="help mb-2">{% trans "Anyone can add books to this list" %}</p>
</label>
<div class="field" data-hides="list_group_selector">
<input
type="radio"
name="curation"
value="open"
aria-described-by="id_curation_open_help"
id="id_curation_open"
{% if list.curation == 'open' %} checked{% endif %}
>
<label for="id_curation_open">
{% trans "Open" context "curation type" %}
</label>
<p class="help mb-2" id="id_curation_open_help">
{% trans "Anyone can add books to this list" %}
</p>
</div>
<div class="field hidden-form">
<input
type="radio"
name="curation"
value="group"
aria-described-by="id_curation_group_help"
id="id_curation_group"
{% if list.curation == 'group' %}checked{% endif %}
>
<label for="id_curation_group">
{% trans "Group" %}
</label>
<p class="help mb-2" id="id_curation_group_help">
{% trans "Group members can add to and remove from this list" %}
</p>
<label class="field hidden-form">
<input type="radio" name="curation" value="group"{% if list.curation == 'group' %} checked{% endif %} > {% trans "Group" %}
<p class="help mb-2">{% trans "Group members can add to and remove from this list" %}</p>
<fieldset class="{% if list.curation != 'group' %}is-hidden{% endif %}" id="list_group_selector">
{% if user.memberships.exists %}
<label class="label" for="id_group" id="group">{% trans "Select Group" %}</label>
@ -61,7 +110,7 @@
{% endwith %}
{% endif %}
</fieldset>
</label>
</div>
</fieldset>
</div>
</div>

View file

@ -56,37 +56,48 @@
<div>
{{ book|book_description|to_markdown|default:""|safe|truncatewords_html:20 }}
</div>
{% include 'snippets/shelve_button/shelve_button.html' %}
{% include 'snippets/shelve_button/shelve_button.html' with book=book %}
</div>
</div>
{% endwith %}
<div class="card-footer is-stacked-mobile has-background-white-bis is-align-items-stretch">
<div class="card-footer-item">
<div>
<p>{% blocktrans with username=item.user.display_name user_path=item.user.local_path %}Added by <a href="{{ user_path }}">{{ username }}</a>{% endblocktrans %}</p>
</div>
<p>
{% blocktrans trimmed with username=item.user.display_name user_path=item.user.local_path %}
Added by <a href="{{ user_path }}">{{ username }}</a>
{% endblocktrans %}
</p>
</div>
{% if list.user == request.user or list.group|is_member:request.user %}
<div class="card-footer-item">
<form name="set-position" method="post" action="{% url 'list-set-book-position' item.id %}">
{% csrf_token %}
<div class="field has-addons mb-0">
<div class="control">
<label for="input-list-position" class="button is-transparent is-small">{% trans "List position" %}</label>
</div>
<div class="control">
<input id="input_list_position" class="input is-small" type="number" min="1" name="position" value="{{ item.order }}">
</div>
<div class="control">
<button type="submit" class="button is-info is-small is-tablet">{% trans "Set" %}</button>
</div>
<form
name="set-position-{{ item.id }}"
method="post"
action="{% url 'list-set-book-position' item.id %}"
class="card-footer-item"
>
{% csrf_token %}
<div class="field has-addons mb-0">
<div class="control">
<label for="input-list-position" class="button is-transparent is-small">{% trans "List position" %}</label>
</div>
</form>
</div>
<div class="control">
<input id="input_list_position_{{ item.id }}" class="input is-small" type="number" min="1" name="position" value="{{ item.order }}">
</div>
<div class="control">
<button type="submit" class="button is-info is-small is-tablet">{% trans "Set" %}</button>
</div>
</div>
</form>
{% endif %}
{% if list.user == request.user or list.curation == 'open' and item.user == request.user or list.group|is_member:request.user %}
<form name="remove-book" method="post" action="{% url 'list-remove-book' list.id %}" class="card-footer-item">
<form
name="remove-book-{{ item.id }}"
method="post"
action="{% url 'list-remove-book' list.id %}"
class="card-footer-item"
>
{% csrf_token %}
<input type="hidden" name="item" value="{{ item.id }}">
<button type="submit" class="button is-small is-danger">{% trans "Remove" %}</button>
@ -172,14 +183,20 @@
<form
class="mt-1"
name="add-book"
name="add-book-{{ book.id }}"
method="post"
action="{% url 'list-add-book' %}{% if query %}?q={{ query }}{% endif %}"
>
{% csrf_token %}
<input type="hidden" name="book" value="{{ book.id }}">
<input type="hidden" name="list" value="{{ list.id }}">
<button type="submit" class="button is-small is-link">{% if list.curation == 'open' or request.user == list.user or list.group|is_member:request.user %}{% trans "Add" %}{% else %}{% trans "Suggest" %}{% endif %}</button>
<button type="submit" class="button is-small is-link">
{% if list.curation == 'open' or request.user == list.user or list.group|is_member:request.user %}
{% trans "Add" %}
{% else %}
{% trans "Suggest" %}
{% endif %}
</button>
</form>
</div>
</div>
@ -191,7 +208,16 @@
{% trans "Embed this list on a website" %}
</h2>
<div class="vertical-copy">
<textarea readonly class="textarea is-small" aria-labelledby="embed-label" data-copytext data-copytext-label="{% trans 'Copy embed code' %}" data-copytext-success="{% trans 'Copied!' %}"><iframe style="border-width:0;" id="bookwyrm_list_embed" width="400" height="600" title="{% blocktrans with list_name=list.name site_name=site.name owner=list.user.display_name %}{{ list_name }}, a list by {{owner}} on {{ site_name }}{% endblocktrans %}" src="{{ embed_url }}"></iframe></textarea>
<textarea
readonly
class="textarea is-small"
aria-labelledby="embed-label"
data-copytext
data-copytext-label="{% trans 'Copy embed code' %}"
data-copytext-success="{% trans 'Copied!' %}"
>&lt;iframe style="border-width:0;" id="bookwyrm_list_embed" width="400" height="600" title="{% blocktrans trimmed with list_name=list.name site_name=site.name owner=list.user.display_name %}
{{ list_name }}, a list by {{owner}} on {{ site_name }}
{% endblocktrans %}" src="{{ embed_url }}"&gt;&lt;/iframe&gt;</textarea>
</div>
</div>

View file

@ -13,7 +13,7 @@
<form class="block" action="{% url 'search' %}" method="GET">
<div class="field has-addons">
<div class="control">
<input type="input" class="input" name="q" value="{{ query }}" aria-label="{% trans 'Search query' %}">
<input type="text" class="input" name="q" value="{{ query }}" aria-label="{% trans 'Search query' %}">
</div>
<div class="control">
<div class="select" aria-label="{% trans 'Search type' %}">

View file

@ -31,35 +31,29 @@
<div class="block content">
<dl>
<div class="is-flex notification pt-1 pb-1 mb-0 {% if announcement in active_announcements %}is-success{% else %}is-danger{% endif %}">
<dt class="mr-1 has-text-weight-bold">{% trans "Visible:" %}</dt>
<dd>
{% if announcement in active_announcements %}
{% trans "True" %}
{% else %}
{% trans "False" %}
{% endif %}
</dd>
</div>
<dt class="is-pulled-left mr-5 has-text-weight-bold">{% trans "Visible:" %}</dt>
<dd>
<span class="tag {% if announcement in active_announcements %}is-success{% else %}is-danger{% endif %}">
{% if announcement in active_announcements %}
{% trans "True" %}
{% else %}
{% trans "False" %}
{% endif %}
</span>
</dd>
{% if announcement.start_date %}
<div class="is-flex notificationi pt-1 pb-1 mb-0 has-background-white">
<dt class="mr-1 has-text-weight-bold">{% trans "Start date:" %}</dt>
<dd>{{ announcement.start_date|naturalday }}</dd>
</div>
<dt class="is-pulled-left mr-5 has-text-weight-bold">{% trans "Start date:" %}</dt>
<dd>{{ announcement.start_date|naturalday }}</dd>
{% endif %}
{% if announcement.end_date %}
<div class="is-flex notification pt-1 pb-1 mb-0 has-background-white">
<dt class="mr-1 has-text-weight-bold">{% trans "End date:" %}</dt>
<dd>{{ announcement.end_date|naturalday }}</dd>
</div>
<dt class="is-pulled-left mr-5 has-text-weight-bold">{% trans "End date:" %}</dt>
<dd>{{ announcement.end_date|naturalday }}</dd>
{% endif %}
<div class="is-flex notification pt-1 pb-1 has-background-white">
<dt class="mr-1 has-text-weight-bold">{% trans "Active:" %}</dt>
<dd>{{ announcement.active }}</dd>
</div>
<dt class="is-pulled-left mr-5 has-text-weight-bold">{% trans "Active:" %}</dt>
<dd>{{ announcement.active }}</dd>
</dl>
<hr aria-hidden="true">

View file

@ -9,7 +9,7 @@ Finish "<em>{{ book_title }}</em>"
{% endblock %}
{% block modal-form-open %}
<form name="finish-reading" action="{% url 'reading-status' 'finish' book.id %}" method="post" {% if not refresh %}class="submit-status"{% endif %}>
<form name="finish-reading-{{ uuid }}" action="{% url 'reading-status' 'finish' book.id %}" method="post" {% if not refresh %}class="submit-status"{% endif %}>
{% csrf_token %}
<input type="hidden" name="id" value="{{ readthrough.id }}">
<input type="hidden" name="reading_status" value="read">

View file

@ -6,7 +6,7 @@
{% endblock %}
{% block modal-form-open %}
<form name="reading-progress" action="{% url 'reading-status-update' book.id %}" method="POST" class="submit-status">
<form name="reading-progress-{{ uuid }}" action="{% url 'reading-status-update' book.id %}" method="POST" class="submit-status">
{% csrf_token %}
<input type="hidden" name="id" value="{{ readthrough.id }}">
{% endblock %}

View file

@ -9,7 +9,7 @@ Start "<em>{{ book_title }}</em>"
{% endblock %}
{% block modal-form-open %}
<form name="start-reading" action="{% url 'reading-status' 'start' book.id %}" method="post" {% if not refresh %}class="submit-status"{% endif %}>
<form name="start-reading-{{ uuid }}" action="{% url 'reading-status' 'start' book.id %}" method="post" {% if not refresh %}class="submit-status"{% endif %}>
<input type="hidden" name="reading_status" value="reading">
<input type="hidden" name="shelf" value="{{ move_from }}">
{% csrf_token %}

View file

@ -9,7 +9,7 @@ Want to Read "<em>{{ book_title }}</em>"
{% endblock %}
{% block modal-form-open %}
<form name="shelve" action="{% url 'reading-status' 'want' book.id %}" method="post" {% if not refresh %}class="submit-status"{% endif %}>
<form name="want-to-read-{{ uuid }}" action="{% url 'reading-status' 'want' book.id %}" method="post" {% if not refresh %}class="submit-status"{% endif %}>
<input type="hidden" name="reading_status" value="to-read">
<input type="hidden" name="shelf" value="{{ move_from }}">
{% csrf_token %}

View file

@ -32,7 +32,7 @@
{% elif shelf.editable %}
<form name="shelve" action="/shelve/" method="post" autocomplete="off">
<form name="shelve-{{ uuid }}-{{ shelf.identifier }}" action="/shelve/" method="post" autocomplete="off">
{% csrf_token %}
<input type="hidden" name="book" value="{{ active_shelf.book.id }}">
<button class="button {{ class }}" name="shelf" type="submit" value="{{ shelf.identifier }}" {% if shelf in book.shelf_set.all %} disabled {% endif %}>

View file

@ -39,7 +39,7 @@
{% elif shelf.editable %}
<form name="shelve" action="/shelve/" method="post">
<form name="shelve-{{ uuid }}-{{ shelf.identifier }}" action="/shelve/" method="post">
{% csrf_token %}
<input type="hidden" name="book" value="{{ active_shelf.book.id }}">
<button class="button {{ class }}" name="shelf" type="submit" value="{{ shelf.identifier }}" {% if shelf in book.shelf_set.all %} disabled {% endif %}>

View file

@ -48,7 +48,9 @@ class StorygraphImport(TestCase):
self.local_user, self.csv, False, "public"
)
import_items = models.ImportItem.objects.filter(job=import_job).all()
import_items = (
models.ImportItem.objects.filter(job=import_job).order_by("index").all()
)
self.assertEqual(len(import_items), 2)
self.assertEqual(import_items[0].index, 0)
self.assertEqual(import_items[0].normalized_data["title"], "Always Coming Home")

View file

@ -0,0 +1 @@
from . import *

View file

@ -0,0 +1,101 @@
""" style fixes and lookups for templates """
from unittest.mock import patch
from django.test import TestCase
from bookwyrm import models
from bookwyrm.templatetags import bookwyrm_tags
@patch("bookwyrm.activitystreams.add_status_task.delay")
@patch("bookwyrm.activitystreams.remove_status_task.delay")
class BookWyrmTags(TestCase):
"""lotta different things here"""
def setUp(self):
"""create some filler objects"""
with patch("bookwyrm.suggested_users.rerank_suggestions_task.delay"), patch(
"bookwyrm.activitystreams.populate_stream_task.delay"
):
self.user = models.User.objects.create_user(
"mouse@example.com",
"mouse@mouse.mouse",
"mouseword",
local=True,
localname="mouse",
)
with patch("bookwyrm.models.user.set_remote_server.delay"):
self.remote_user = models.User.objects.create_user(
"rat",
"rat@rat.rat",
"ratword",
remote_id="http://example.com/rat",
local=False,
)
self.book = models.Edition.objects.create(title="Test Book")
def test_get_user_rating(self, *_):
"""get a user's most recent rating of a book"""
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
models.Review.objects.create(user=self.user, book=self.book, rating=3)
self.assertEqual(bookwyrm_tags.get_user_rating(self.book, self.user), 3)
def test_get_user_rating_doesnt_exist(self, *_):
"""there is no rating available"""
self.assertEqual(bookwyrm_tags.get_user_rating(self.book, self.user), 0)
def test_get_book_description(self, *_):
"""grab it from the edition or the parent"""
work = models.Work.objects.create(title="Test Work")
self.book.parent_work = work
self.book.save()
self.assertIsNone(bookwyrm_tags.get_book_description(self.book))
work.description = "hi"
work.save()
self.assertEqual(bookwyrm_tags.get_book_description(self.book), "hi")
self.book.description = "hello"
self.book.save()
self.assertEqual(bookwyrm_tags.get_book_description(self.book), "hello")
def test_get_next_shelf(self, *_):
"""self progress helper"""
self.assertEqual(bookwyrm_tags.get_next_shelf("to-read"), "reading")
self.assertEqual(bookwyrm_tags.get_next_shelf("reading"), "read")
self.assertEqual(bookwyrm_tags.get_next_shelf("read"), "complete")
self.assertEqual(bookwyrm_tags.get_next_shelf("blooooga"), "to-read")
@patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async")
def test_load_subclass(self, *_):
"""get a status' real type"""
review = models.Review.objects.create(user=self.user, book=self.book, rating=3)
status = models.Status.objects.get(id=review.id)
self.assertIsInstance(status, models.Status)
self.assertIsInstance(bookwyrm_tags.load_subclass(status), models.Review)
quote = models.Quotation.objects.create(
user=self.user, book=self.book, content="hi"
)
status = models.Status.objects.get(id=quote.id)
self.assertIsInstance(status, models.Status)
self.assertIsInstance(bookwyrm_tags.load_subclass(status), models.Quotation)
comment = models.Comment.objects.create(
user=self.user, book=self.book, content="hi"
)
status = models.Status.objects.get(id=comment.id)
self.assertIsInstance(status, models.Status)
self.assertIsInstance(bookwyrm_tags.load_subclass(status), models.Comment)
def test_related_status(self, *_):
"""gets the subclass model for a notification status"""
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
status = models.Status.objects.create(content="hi", user=self.user)
notification = models.Notification.objects.create(
user=self.user, notification_type="MENTION", related_status=status
)
result = bookwyrm_tags.related_status(notification)
self.assertIsInstance(result, models.Status)

View file

@ -0,0 +1,53 @@
""" style fixes and lookups for templates """
from unittest.mock import patch
from django.test import TestCase
from bookwyrm import models
from bookwyrm.templatetags import interaction
@patch("bookwyrm.activitystreams.add_status_task.delay")
@patch("bookwyrm.activitystreams.remove_status_task.delay")
class InteractionTags(TestCase):
"""lotta different things here"""
def setUp(self):
"""create some filler objects"""
with patch("bookwyrm.suggested_users.rerank_suggestions_task.delay"), patch(
"bookwyrm.activitystreams.populate_stream_task.delay"
):
self.user = models.User.objects.create_user(
"mouse@example.com",
"mouse@mouse.mouse",
"mouseword",
local=True,
localname="mouse",
)
with patch("bookwyrm.models.user.set_remote_server.delay"):
self.remote_user = models.User.objects.create_user(
"rat",
"rat@rat.rat",
"ratword",
remote_id="http://example.com/rat",
local=False,
)
self.book = models.Edition.objects.create(title="Test Book")
def test_get_user_liked(self, *_):
"""did a user like a status"""
status = models.Review.objects.create(user=self.remote_user, book=self.book)
self.assertFalse(interaction.get_user_liked(self.user, status))
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
models.Favorite.objects.create(user=self.user, status=status)
self.assertTrue(interaction.get_user_liked(self.user, status))
def test_get_user_boosted(self, *_):
"""did a user boost a status"""
status = models.Review.objects.create(user=self.remote_user, book=self.book)
self.assertFalse(interaction.get_user_boosted(self.user, status))
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
models.Boost.objects.create(user=self.user, boosted_status=status)
self.assertTrue(interaction.get_user_boosted(self.user, status))

View file

@ -0,0 +1,15 @@
""" style fixes and lookups for templates """
from django.test import TestCase
from bookwyrm.templatetags import markdown
class MarkdownTags(TestCase):
"""lotta different things here"""
def test_get_markdown(self):
"""mardown format data"""
result = markdown.get_markdown("_hi_")
self.assertEqual(result, "<p><em>hi</em></p>")
result = markdown.get_markdown("<marquee>_hi_</marquee>")
self.assertEqual(result, "<p><em>hi</em></p>")

View file

@ -0,0 +1,90 @@
""" style fixes and lookups for templates """
from unittest.mock import patch
from django.test import TestCase
from django.utils import timezone
from bookwyrm import models
from bookwyrm.templatetags import status_display
@patch("bookwyrm.activitystreams.add_status_task.delay")
@patch("bookwyrm.activitystreams.remove_status_task.delay")
class StatusDisplayTags(TestCase):
"""lotta different things here"""
def setUp(self):
"""create some filler objects"""
with patch("bookwyrm.suggested_users.rerank_suggestions_task.delay"), patch(
"bookwyrm.activitystreams.populate_stream_task.delay"
):
self.user = models.User.objects.create_user(
"mouse@example.com",
"mouse@mouse.mouse",
"mouseword",
local=True,
localname="mouse",
)
with patch("bookwyrm.models.user.set_remote_server.delay"):
self.remote_user = models.User.objects.create_user(
"rat",
"rat@rat.rat",
"ratword",
remote_id="http://example.com/rat",
local=False,
)
self.book = models.Edition.objects.create(title="Test Book")
@patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async")
def test_get_replies(self, *_):
"""direct replies to a status"""
parent = models.Review.objects.create(
user=self.user, book=self.book, content="hi"
)
first_child = models.Status.objects.create(
reply_parent=parent, user=self.user, content="hi"
)
second_child = models.Status.objects.create(
reply_parent=parent, user=self.user, content="hi"
)
third_child = models.Status.objects.create(
reply_parent=parent,
user=self.user,
deleted=True,
deleted_date=timezone.now(),
)
replies = status_display.get_replies(parent)
self.assertEqual(len(replies), 2)
self.assertTrue(first_child in replies)
self.assertTrue(second_child in replies)
self.assertFalse(third_child in replies)
def test_get_parent(self, *_):
"""get the reply parent of a status"""
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
parent = models.Review.objects.create(
user=self.user, book=self.book, content="hi"
)
child = models.Status.objects.create(
reply_parent=parent, user=self.user, content="hi"
)
result = status_display.get_parent(child)
self.assertEqual(result, parent)
self.assertIsInstance(result, models.Review)
def test_get_boosted(self, *_):
"""load a boosted status"""
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
status = models.Review.objects.create(user=self.remote_user, book=self.book)
boost = models.Boost.objects.create(user=self.user, boosted_status=status)
boosted = status_display.get_boosted(boost)
self.assertIsInstance(boosted, models.Review)
self.assertEqual(boosted, status)
def test_get_mentions(self, *_):
"""list of people mentioned"""
status = models.Status.objects.create(content="hi", user=self.remote_user)
result = status_display.get_mentions(status, self.user)
self.assertEqual(result, "@rat@example.com ")

View file

@ -0,0 +1,52 @@
""" style fixes and lookups for templates """
import re
from unittest.mock import patch
from django.test import TestCase
from bookwyrm import models
from bookwyrm.templatetags import utilities
@patch("bookwyrm.activitystreams.add_status_task.delay")
@patch("bookwyrm.activitystreams.remove_status_task.delay")
class UtilitiesTags(TestCase):
"""lotta different things here"""
def setUp(self):
"""create some filler objects"""
with patch("bookwyrm.suggested_users.rerank_suggestions_task.delay"), patch(
"bookwyrm.activitystreams.populate_stream_task.delay"
):
self.user = models.User.objects.create_user(
"mouse@example.com",
"mouse@mouse.mouse",
"mouseword",
local=True,
localname="mouse",
)
with patch("bookwyrm.models.user.set_remote_server.delay"):
self.remote_user = models.User.objects.create_user(
"rat",
"rat@rat.rat",
"ratword",
remote_id="http://example.com/rat",
local=False,
)
self.book = models.Edition.objects.create(title="Test Book")
def test_get_user_identifer_local(self, *_):
"""fall back to the simplest uid available"""
self.assertNotEqual(self.user.username, self.user.localname)
self.assertEqual(utilities.get_user_identifier(self.user), "mouse")
def test_get_user_identifer_remote(self, *_):
"""for a remote user, should be their full username"""
self.assertEqual(
utilities.get_user_identifier(self.remote_user), "rat@example.com"
)
def test_get_uuid(self, *_):
"""uuid functionality"""
uuid = utilities.get_uuid("hi")
self.assertTrue(re.match(r"hi[A-Za-z0-9\-]", uuid))

View file

@ -1,183 +0,0 @@
""" style fixes and lookups for templates """
import re
from unittest.mock import patch
from django.test import TestCase
from django.utils import timezone
from bookwyrm import models
from bookwyrm.templatetags import (
bookwyrm_tags,
interaction,
markdown,
status_display,
utilities,
)
@patch("bookwyrm.activitystreams.add_status_task.delay")
@patch("bookwyrm.activitystreams.remove_status_task.delay")
class TemplateTags(TestCase):
"""lotta different things here"""
def setUp(self):
"""create some filler objects"""
with patch("bookwyrm.suggested_users.rerank_suggestions_task.delay"), patch(
"bookwyrm.activitystreams.populate_stream_task.delay"
):
self.user = models.User.objects.create_user(
"mouse@example.com",
"mouse@mouse.mouse",
"mouseword",
local=True,
localname="mouse",
)
with patch("bookwyrm.models.user.set_remote_server.delay"):
self.remote_user = models.User.objects.create_user(
"rat",
"rat@rat.rat",
"ratword",
remote_id="http://example.com/rat",
local=False,
)
self.book = models.Edition.objects.create(title="Test Book")
def test_get_user_rating(self, *_):
"""get a user's most recent rating of a book"""
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
models.Review.objects.create(user=self.user, book=self.book, rating=3)
self.assertEqual(bookwyrm_tags.get_user_rating(self.book, self.user), 3)
def test_get_user_rating_doesnt_exist(self, *_):
"""there is no rating available"""
self.assertEqual(bookwyrm_tags.get_user_rating(self.book, self.user), 0)
def test_get_user_identifer_local(self, *_):
"""fall back to the simplest uid available"""
self.assertNotEqual(self.user.username, self.user.localname)
self.assertEqual(utilities.get_user_identifier(self.user), "mouse")
def test_get_user_identifer_remote(self, *_):
"""for a remote user, should be their full username"""
self.assertEqual(
utilities.get_user_identifier(self.remote_user), "rat@example.com"
)
@patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async")
def test_get_replies(self, *_):
"""direct replies to a status"""
parent = models.Review.objects.create(
user=self.user, book=self.book, content="hi"
)
first_child = models.Status.objects.create(
reply_parent=parent, user=self.user, content="hi"
)
second_child = models.Status.objects.create(
reply_parent=parent, user=self.user, content="hi"
)
third_child = models.Status.objects.create(
reply_parent=parent,
user=self.user,
deleted=True,
deleted_date=timezone.now(),
)
replies = status_display.get_replies(parent)
self.assertEqual(len(replies), 2)
self.assertTrue(first_child in replies)
self.assertTrue(second_child in replies)
self.assertFalse(third_child in replies)
def test_get_parent(self, *_):
"""get the reply parent of a status"""
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
parent = models.Review.objects.create(
user=self.user, book=self.book, content="hi"
)
child = models.Status.objects.create(
reply_parent=parent, user=self.user, content="hi"
)
result = status_display.get_parent(child)
self.assertEqual(result, parent)
self.assertIsInstance(result, models.Review)
def test_get_user_liked(self, *_):
"""did a user like a status"""
status = models.Review.objects.create(user=self.remote_user, book=self.book)
self.assertFalse(interaction.get_user_liked(self.user, status))
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
models.Favorite.objects.create(user=self.user, status=status)
self.assertTrue(interaction.get_user_liked(self.user, status))
def test_get_user_boosted(self, *_):
"""did a user boost a status"""
status = models.Review.objects.create(user=self.remote_user, book=self.book)
self.assertFalse(interaction.get_user_boosted(self.user, status))
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
models.Boost.objects.create(user=self.user, boosted_status=status)
self.assertTrue(interaction.get_user_boosted(self.user, status))
def test_get_boosted(self, *_):
"""load a boosted status"""
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
status = models.Review.objects.create(user=self.remote_user, book=self.book)
boost = models.Boost.objects.create(user=self.user, boosted_status=status)
boosted = status_display.get_boosted(boost)
self.assertIsInstance(boosted, models.Review)
self.assertEqual(boosted, status)
def test_get_book_description(self, *_):
"""grab it from the edition or the parent"""
work = models.Work.objects.create(title="Test Work")
self.book.parent_work = work
self.book.save()
self.assertIsNone(bookwyrm_tags.get_book_description(self.book))
work.description = "hi"
work.save()
self.assertEqual(bookwyrm_tags.get_book_description(self.book), "hi")
self.book.description = "hello"
self.book.save()
self.assertEqual(bookwyrm_tags.get_book_description(self.book), "hello")
def test_get_uuid(self, *_):
"""uuid functionality"""
uuid = utilities.get_uuid("hi")
self.assertTrue(re.match(r"hi[A-Za-z0-9\-]", uuid))
def test_get_markdown(self, *_):
"""mardown format data"""
result = markdown.get_markdown("_hi_")
self.assertEqual(result, "<p><em>hi</em></p>")
result = markdown.get_markdown("<marquee>_hi_</marquee>")
self.assertEqual(result, "<p><em>hi</em></p>")
def test_get_mentions(self, *_):
"""list of people mentioned"""
status = models.Status.objects.create(content="hi", user=self.remote_user)
result = status_display.get_mentions(status, self.user)
self.assertEqual(result, "@rat@example.com ")
def test_related_status(self, *_):
"""gets the subclass model for a notification status"""
with patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async"):
status = models.Status.objects.create(content="hi", user=self.user)
notification = models.Notification.objects.create(
user=self.user, notification_type="MENTION", related_status=status
)
result = bookwyrm_tags.related_status(notification)
self.assertIsInstance(result, models.Status)
def test_get_next_shelf(self, *_):
"""self progress helper"""
self.assertEqual(bookwyrm_tags.get_next_shelf("to-read"), "reading")
self.assertEqual(bookwyrm_tags.get_next_shelf("reading"), "read")
self.assertEqual(bookwyrm_tags.get_next_shelf("read"), "complete")
self.assertEqual(bookwyrm_tags.get_next_shelf("blooooga"), "to-read")

View file

@ -15,7 +15,11 @@ def validate_html(html):
errors = "\n".join(
e
for e in errors.split("\n")
if "&book" not in e and "id and name attribute" not in e
if "&book" not in e
and "&type" not in e
and "id and name attribute" not in e
and "illegal characters found in URI" not in e
and "escaping malformed URI reference" not in e
)
if errors:
raise Exception(errors)

View file

@ -5,6 +5,7 @@ from django.test import TestCase
from django.test.client import RequestFactory
from bookwyrm import forms, models, views
from bookwyrm.tests.validate_html import validate_html
class AnnouncementViews(TestCase):
@ -38,7 +39,7 @@ class AnnouncementViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_announcements_page_empty(self):
@ -51,7 +52,7 @@ class AnnouncementViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_announcement_page(self):
@ -68,7 +69,7 @@ class AnnouncementViews(TestCase):
result = view(request, announcement.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_create_announcement(self):
@ -138,5 +139,5 @@ class AnnouncementViews(TestCase):
result = view(request, self.local_user.localname)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)

View file

@ -1,7 +1,7 @@
"""testing the annual summary page"""
from datetime import datetime
import pytz
from unittest.mock import patch
import pytz
from django.contrib.auth.models import AnonymousUser
from django.http import Http404
@ -100,13 +100,8 @@ class AnnualSummary(TestCase):
@patch("bookwyrm.activitystreams.add_book_statuses_task.delay")
def test_annual_summary_page(self, *_):
"""there are so many views, this just makes sure it LOADS"""
shelf = self.local_user.shelf_set.filter(identifier="read").first()
models.ShelfBook.objects.create(
book=self.book,
user=self.local_user,
shelf=shelf,
shelved_date=make_date(2020, 1, 1),
models.ReadThrough.objects.create(
user=self.local_user, book=self.book, finish_date=make_date(2020, 1, 1)
)
view = views.AnnualSummary.as_view()
@ -124,7 +119,7 @@ class AnnualSummary(TestCase):
def test_annual_summary_page_with_review(self, *_):
"""there are so many views, this just makes sure it LOADS"""
self.review = models.Review.objects.create(
models.Review.objects.create(
name="Review name",
content="test content",
rating=3.0,
@ -132,12 +127,8 @@ class AnnualSummary(TestCase):
book=self.book,
)
shelf = self.local_user.shelf_set.filter(identifier="read").first()
models.ShelfBook.objects.create(
book=self.book,
user=self.local_user,
shelf=shelf,
shelved_date=make_date(2020, 1, 1),
models.ReadThrough.objects.create(
user=self.local_user, book=self.book, finish_date=make_date(2020, 1, 1)
)
view = views.AnnualSummary.as_view()

View file

@ -4,8 +4,8 @@ from django.contrib.auth.models import AnonymousUser
from django.test import TestCase
from django.test.client import RequestFactory
from bookwyrm import models
from bookwyrm import views
from bookwyrm import models, views
from bookwyrm.tests.validate_html import validate_html
class DiscoverViews(TestCase):
@ -39,7 +39,7 @@ class DiscoverViews(TestCase):
result = view(request)
self.assertEqual(mock.call_count, 1)
self.assertEqual(result.status_code, 200)
result.render()
validate_html(result.render())
@patch("bookwyrm.models.activitypub_mixin.broadcast_task.apply_async")
@patch("bookwyrm.activitystreams.add_status_task.delay")
@ -67,7 +67,7 @@ class DiscoverViews(TestCase):
result = view(request)
self.assertEqual(mock.call_count, 1)
self.assertEqual(result.status_code, 200)
result.render()
validate_html(result.render())
def test_discover_page_logged_out(self):
"""there are so many views, this just makes sure it LOADS"""

View file

@ -13,6 +13,7 @@ from django.test.client import RequestFactory
from bookwyrm import models
from bookwyrm import views
from bookwyrm.activitypub import ActivitypubResponse
from bookwyrm.tests.validate_html import validate_html
@patch("bookwyrm.activitystreams.ActivityStream.get_activity_stream")
@ -58,7 +59,7 @@ class FeedViews(TestCase):
request.user = self.local_user
result = view(request, "home")
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_status_page(self, *_):
@ -72,7 +73,7 @@ class FeedViews(TestCase):
is_api.return_value = False
result = view(request, "mouse", status.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
with patch("bookwyrm.views.feed.is_api_request") as is_api:
@ -139,7 +140,7 @@ class FeedViews(TestCase):
is_api.return_value = False
result = view(request, "mouse", status.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
with patch("bookwyrm.views.feed.is_api_request") as is_api:
@ -159,7 +160,7 @@ class FeedViews(TestCase):
is_api.return_value = False
result = view(request, "mouse", status.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
with patch("bookwyrm.views.feed.is_api_request") as is_api:
@ -175,7 +176,7 @@ class FeedViews(TestCase):
request.user = self.local_user
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_direct_messages_page_user(self, *_):
@ -185,7 +186,7 @@ class FeedViews(TestCase):
request.user = self.local_user
result = view(request, "nutria")
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
self.assertEqual(result.context_data["partner"], self.another_user)

View file

@ -5,6 +5,7 @@ from django.test import TestCase
from django.test.client import RequestFactory
from bookwyrm import forms, models, views
from bookwyrm.tests.validate_html import validate_html
@patch("bookwyrm.activitystreams.populate_stream_task.delay")
@ -40,7 +41,7 @@ class GetStartedViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
@patch("bookwyrm.suggested_users.rerank_suggestions_task.delay")
@ -72,7 +73,7 @@ class GetStartedViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_books_view_with_query(self, _):
@ -84,7 +85,7 @@ class GetStartedViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
@patch("bookwyrm.suggested_users.rerank_suggestions_task.delay")
@ -117,7 +118,7 @@ class GetStartedViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
@patch("bookwyrm.suggested_users.SuggestedUsers.get_suggestions")
@ -130,5 +131,5 @@ class GetStartedViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)

View file

@ -10,6 +10,7 @@ from django.test.client import RequestFactory
from bookwyrm import models, views
from bookwyrm.activitypub import ActivitypubResponse
from bookwyrm.tests.validate_html import validate_html
# pylint: disable=unused-argument
class ListViews(TestCase):
@ -84,14 +85,14 @@ class ListViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
request.user = self.anonymous_user
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_saved_lists_page(self):
@ -110,7 +111,7 @@ class ListViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
self.assertEqual(result.context_data["lists"].object_list, [booklist])
@ -127,7 +128,7 @@ class ListViews(TestCase):
result = view(request)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
self.assertEqual(len(result.context_data["lists"].object_list), 0)
@ -188,7 +189,7 @@ class ListViews(TestCase):
is_api.return_value = False
result = view(request, self.list.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_list_page_sorted(self):
@ -210,7 +211,7 @@ class ListViews(TestCase):
is_api.return_value = False
result = view(request, self.list.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
request = self.factory.get("/?sort_by=title")
@ -219,7 +220,7 @@ class ListViews(TestCase):
is_api.return_value = False
result = view(request, self.list.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
request = self.factory.get("/?sort_by=rating")
@ -228,7 +229,7 @@ class ListViews(TestCase):
is_api.return_value = False
result = view(request, self.list.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
request = self.factory.get("/?sort_by=sdkfh")
@ -237,7 +238,7 @@ class ListViews(TestCase):
is_api.return_value = False
result = view(request, self.list.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_list_page_empty(self):
@ -250,7 +251,7 @@ class ListViews(TestCase):
is_api.return_value = False
result = view(request, self.list.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_list_page_logged_out(self):
@ -271,7 +272,7 @@ class ListViews(TestCase):
is_api.return_value = False
result = view(request, self.list.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_list_page_json_view(self):
@ -355,7 +356,7 @@ class ListViews(TestCase):
result = view(request, self.list.id)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
request.user = self.anonymous_user
@ -375,7 +376,7 @@ class ListViews(TestCase):
result = view(request, self.local_user.localname)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)
def test_user_lists_page_logged_out(self):
@ -404,7 +405,7 @@ class ListViews(TestCase):
with patch("bookwyrm.views.list.is_api_request") as is_api:
is_api.return_value = False
with self.assertRaises(Http404):
result = view(request, self.list.id, "")
view(request, self.list.id, "")
def test_embed_call_with_key(self):
"""there are so many views, this just makes sure it LOADS"""
@ -427,5 +428,5 @@ class ListViews(TestCase):
result = view(request, self.list.id, embed_key)
self.assertIsInstance(result, TemplateResponse)
result.render()
validate_html(result.render())
self.assertEqual(result.status_code, 200)

View file

@ -12,6 +12,7 @@ import responses
from bookwyrm import models, views
from bookwyrm.settings import DOMAIN
from bookwyrm.tests.validate_html import validate_html
class Views(TestCase):
@ -62,7 +63,7 @@ class Views(TestCase):
is_api.return_value = False
response = view(request)
self.assertIsInstance(response, TemplateResponse)
response.render()
validate_html(response.render())
@responses.activate
def test_search_books(self):
@ -89,7 +90,7 @@ class Views(TestCase):
is_api.return_value = False
response = view(request)
self.assertIsInstance(response, TemplateResponse)
response.render()
validate_html(response.render())
connector_results = response.context_data["results"]
self.assertEqual(len(connector_results), 2)
self.assertEqual(connector_results[0]["results"][0].title, "Test Book")
@ -107,7 +108,7 @@ class Views(TestCase):
is_api.return_value = False
response = view(request)
self.assertIsInstance(response, TemplateResponse)
response.render()
validate_html(response.render())
connector_results = response.context_data["results"]
self.assertEqual(len(connector_results), 1)
self.assertEqual(connector_results[0]["results"][0].title, "Test Book")
@ -120,7 +121,7 @@ class Views(TestCase):
response = view(request)
self.assertIsInstance(response, TemplateResponse)
response.render()
validate_html(response.render())
self.assertEqual(response.context_data["results"][0], self.local_user)
def test_search_users_logged_out(self):
@ -134,7 +135,7 @@ class Views(TestCase):
response = view(request)
response.render()
validate_html(response.render())
self.assertFalse("results" in response.context_data)
def test_search_lists(self):
@ -149,5 +150,5 @@ class Views(TestCase):
response = view(request)
self.assertIsInstance(response, TemplateResponse)
response.render()
validate_html(response.render())
self.assertEqual(response.context_data["results"][0], booklist)

View file

@ -3,7 +3,7 @@ from datetime import date
from uuid import uuid4
from django.contrib.auth.decorators import login_required
from django.db.models import Case, When, Avg, Sum
from django.db.models import Avg, Sum, Min, Case, When
from django.http import Http404
from django.shortcuts import redirect
from django.template.response import TemplateResponse
@ -185,7 +185,12 @@ def privacy_verification(request, user, year, year_key):
def is_year_available(user, year):
"""return boolean"""
earliest_year = int(get_earliest_year(user, year))
earliest_year = user.readthrough_set.filter(finish_date__isnull=False).aggregate(
Min("finish_date")
)["finish_date__min"]
if not earliest_year:
return True
earliest_year = earliest_year.year
today = date.today()
year = int(year)
if earliest_year <= year < today.year:
@ -196,39 +201,6 @@ def is_year_available(user, year):
return False
def get_earliest_year(user, year):
"""return the earliest finish_date or shelved_date year for user books in read shelf"""
read_shelfbooks = models.ShelfBook.objects.filter(user__id=user.id).filter(
shelf__identifier__exact="read"
)
read_shelfbooks_list = list(read_shelfbooks.values("book", "shelved_date"))
book_dates = []
for book in read_shelfbooks_list:
earliest_finished = (
models.ReadThrough.objects.filter(user__id=user.id)
.filter(book_id=book["book"])
.exclude(finish_date__exact=None)
.order_by("finish_date")
.values("finish_date")
.first()
)
if earliest_finished:
book_dates.append(
min(earliest_finished["finish_date"], book["shelved_date"])
)
else:
book_dates.append(book["shelved_date"])
if book_dates:
return min(book_dates).year
return year
def get_books_from_shelfbooks(books_ids):
"""return an ordered QuerySet of books from a list"""

Binary file not shown.

View file

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: bookwyrm\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 15:00+0000\n"
"PO-Revision-Date: 2021-12-28 16:03\n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"PO-Revision-Date: 2021-12-28 21:17\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: German\n"
"Language: de\n"
@ -263,76 +263,78 @@ msgstr ""
msgid "Share this page"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:67
msgid "Copy address"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
msgid "Copied!"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:69
#: bookwyrm/templates/annual_summary/layout.html:77
msgid "Sharing status: <strong>public with key</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:70
#: bookwyrm/templates/annual_summary/layout.html:78
msgid "The page can be seen by anyone with the complete address."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:75
#: bookwyrm/templates/annual_summary/layout.html:83
msgid "Make page private"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:81
#: bookwyrm/templates/annual_summary/layout.html:89
msgid "Sharing status: <strong>private</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:82
#: bookwyrm/templates/annual_summary/layout.html:90
msgid "The page is private, only you can see it."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:87
#: bookwyrm/templates/annual_summary/layout.html:95
msgid "Make page public"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:91
#: bookwyrm/templates/annual_summary/layout.html:99
msgid "When you make your page private, the old key wont give access to the page anymore. A new key will be created if the page is once again made public."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:104
#: bookwyrm/templates/annual_summary/layout.html:112
#, python-format
msgid "Sadly %(display_name)s didnt finish any book in %(year)s"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:110
#: bookwyrm/templates/annual_summary/layout.html:118
#, python-format
msgid "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr ""
msgid "In %(year)s, %(display_name)s read %(books_total)s book<br />for a total of %(pages_total)s pages!"
msgid_plural "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr[0] ""
msgstr[1] ""
#: bookwyrm/templates/annual_summary/layout.html:112
#: bookwyrm/templates/annual_summary/layout.html:124
msgid "Thats great!"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:115
#: bookwyrm/templates/annual_summary/layout.html:127
#, python-format
msgid "That makes an average of %(pages)s pages per book."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:120
#: bookwyrm/templates/annual_summary/layout.html:132
#, python-format
msgid "(%(no_page_number)s book doesnt have pages)"
msgid_plural "(%(no_page_number)s books dont have pages)"
msgstr[0] ""
msgstr[1] ""
#: bookwyrm/templates/annual_summary/layout.html:136
#: bookwyrm/templates/annual_summary/layout.html:148
msgid "Their shortest read this year…"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:143
#: bookwyrm/templates/annual_summary/layout.html:164
#: bookwyrm/templates/annual_summary/layout.html:204
#: bookwyrm/templates/annual_summary/layout.html:155
#: bookwyrm/templates/annual_summary/layout.html:176
#: bookwyrm/templates/annual_summary/layout.html:220
#: bookwyrm/templates/book/book.html:47
#: bookwyrm/templates/discover/large-book.html:22
#: bookwyrm/templates/landing/large-book.html:25
@ -340,33 +342,35 @@ msgstr ""
msgid "by"
msgstr "von"
#: bookwyrm/templates/annual_summary/layout.html:149
#: bookwyrm/templates/annual_summary/layout.html:170
#: bookwyrm/templates/annual_summary/layout.html:161
#: bookwyrm/templates/annual_summary/layout.html:182
#, python-format
msgid "<strong>%(pages)s</strong> pages"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:157
#: bookwyrm/templates/annual_summary/layout.html:169
msgid "…and the longest"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:187
#: bookwyrm/templates/annual_summary/layout.html:199
#, python-format
msgid "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr ""
msgid "%(display_name)s left %(ratings_total)s rating, <br />their average rating is %(rating_average)s"
msgid_plural "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr[0] ""
msgstr[1] ""
#: bookwyrm/templates/annual_summary/layout.html:197
#: bookwyrm/templates/annual_summary/layout.html:213
msgid "Their best rated review"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:210
#: bookwyrm/templates/annual_summary/layout.html:226
#, python-format
msgid "Their rating: <strong>%(rating)s</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:227
#: bookwyrm/templates/annual_summary/layout.html:243
#, python-format
msgid "All the books %(display_name)s read in 2021"
msgid "All the books %(display_name)s read in %(year)s"
msgstr ""
#: bookwyrm/templates/author/author.html:18

View file

@ -8,7 +8,7 @@ msgid ""
msgstr ""
"Project-Id-Version: 0.0.1\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"POT-Creation-Date: 2021-12-29 21:32+0000\n"
"PO-Revision-Date: 2021-02-28 17:19-0800\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: English <LL@li.org>\n"
@ -61,7 +61,7 @@ msgstr ""
msgid "Rating"
msgstr ""
#: bookwyrm/forms.py:473 bookwyrm/templates/lists/list.html:110
#: bookwyrm/forms.py:473 bookwyrm/templates/lists/list.html:121
msgid "Sort By"
msgstr ""
@ -145,7 +145,7 @@ msgstr ""
msgid "%(value)s is not a valid username"
msgstr ""
#: bookwyrm/models/fields.py:183 bookwyrm/templates/layout.html:173
#: bookwyrm/models/fields.py:183 bookwyrm/templates/layout.html:170
#: bookwyrm/templates/ostatus/error.html:29
msgid "username"
msgstr ""
@ -269,7 +269,7 @@ msgid "Copy address"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
#: bookwyrm/templates/lists/list.html:217
msgid "Copied!"
msgstr ""
@ -520,7 +520,7 @@ msgstr ""
#: bookwyrm/templates/book/readthrough.html:76
#: bookwyrm/templates/groups/form.html:24
#: bookwyrm/templates/lists/bookmark_button.html:15
#: bookwyrm/templates/lists/form.html:75
#: bookwyrm/templates/lists/form.html:124
#: bookwyrm/templates/preferences/edit_user.html:124
#: bookwyrm/templates/settings/announcements/announcement_form.html:76
#: bookwyrm/templates/settings/federation/edit_instance.html:82
@ -642,7 +642,7 @@ msgstr ""
msgid "Places"
msgstr ""
#: bookwyrm/templates/book/book.html:320 bookwyrm/templates/layout.html:77
#: bookwyrm/templates/book/book.html:320 bookwyrm/templates/layout.html:74
#: bookwyrm/templates/lists/lists.html:5 bookwyrm/templates/lists/lists.html:12
#: bookwyrm/templates/search/layout.html:25
#: bookwyrm/templates/search/layout.html:50
@ -656,7 +656,7 @@ msgstr ""
#: bookwyrm/templates/book/book.html:341
#: bookwyrm/templates/book/cover_modal.html:31
#: bookwyrm/templates/lists/list.html:182
#: bookwyrm/templates/lists/list.html:195
#: bookwyrm/templates/settings/email_blocklist/domain_form.html:24
#: bookwyrm/templates/settings/ip_blocklist/ip_address_form.html:31
msgid "Add"
@ -940,8 +940,8 @@ msgstr ""
#: bookwyrm/templates/components/modal.html:11
#: bookwyrm/templates/components/tooltip.html:7
#: bookwyrm/templates/feed/layout.html:71
#: bookwyrm/templates/get_started/layout.html:20
#: bookwyrm/templates/get_started/layout.html:53
#: bookwyrm/templates/get_started/layout.html:25
#: bookwyrm/templates/get_started/layout.html:58
#: bookwyrm/templates/search/book.html:49
#: bookwyrm/templates/snippets/announcement.html:18
msgid "Close"
@ -1017,7 +1017,7 @@ msgstr ""
#: bookwyrm/templates/directory/directory.html:4
#: bookwyrm/templates/directory/directory.html:9
#: bookwyrm/templates/layout.html:103
#: bookwyrm/templates/layout.html:100
msgid "Directory"
msgstr ""
@ -1137,7 +1137,7 @@ msgstr ""
#: bookwyrm/templates/discover/discover.html:4
#: bookwyrm/templates/discover/discover.html:10
#: bookwyrm/templates/layout.html:80
#: bookwyrm/templates/layout.html:77
msgid "Discover"
msgstr ""
@ -1260,12 +1260,12 @@ msgid "%(site_name)s home page"
msgstr ""
#: bookwyrm/templates/embed-layout.html:34
#: bookwyrm/templates/landing/about.html:7 bookwyrm/templates/layout.html:232
#: bookwyrm/templates/landing/about.html:7 bookwyrm/templates/layout.html:229
#, python-format
msgid "About %(site_name)s"
msgstr ""
#: bookwyrm/templates/embed-layout.html:40 bookwyrm/templates/layout.html:236
#: bookwyrm/templates/embed-layout.html:40 bookwyrm/templates/layout.html:233
msgid "Contact site admin"
msgstr ""
@ -1279,7 +1279,7 @@ msgid "Direct Messages with <a href=\"%(path)s\">%(username)s</a>"
msgstr ""
#: bookwyrm/templates/feed/direct_messages.html:10
#: bookwyrm/templates/layout.html:113
#: bookwyrm/templates/layout.html:110
msgid "Direct Messages"
msgstr ""
@ -1332,7 +1332,7 @@ msgstr ""
msgid "Updates"
msgstr ""
#: bookwyrm/templates/feed/layout.html:12 bookwyrm/templates/layout.html:108
#: bookwyrm/templates/feed/layout.html:12 bookwyrm/templates/layout.html:105
msgid "Your Books"
msgstr ""
@ -1409,7 +1409,7 @@ msgid "What are you reading?"
msgstr ""
#: bookwyrm/templates/get_started/books.html:9
#: bookwyrm/templates/layout.html:47 bookwyrm/templates/lists/list.html:138
#: bookwyrm/templates/layout.html:47 bookwyrm/templates/lists/list.html:149
msgid "Search for a book"
msgstr ""
@ -1429,7 +1429,7 @@ msgstr ""
#: bookwyrm/templates/get_started/users.html:19
#: bookwyrm/templates/groups/group.html:19
#: bookwyrm/templates/groups/group.html:20 bookwyrm/templates/layout.html:53
#: bookwyrm/templates/layout.html:54 bookwyrm/templates/lists/list.html:142
#: bookwyrm/templates/layout.html:54 bookwyrm/templates/lists/list.html:153
#: bookwyrm/templates/search/layout.html:4
#: bookwyrm/templates/search/layout.html:9
msgid "Search"
@ -1445,12 +1445,12 @@ msgid "Popular on %(site_name)s"
msgstr ""
#: bookwyrm/templates/get_started/books.html:58
#: bookwyrm/templates/lists/list.html:155
#: bookwyrm/templates/lists/list.html:166
msgid "No books found"
msgstr ""
#: bookwyrm/templates/get_started/books.html:63
#: bookwyrm/templates/get_started/profile.html:51
#: bookwyrm/templates/get_started/profile.html:64
msgid "Save &amp; continue"
msgstr ""
@ -1459,33 +1459,33 @@ msgstr ""
msgid "Welcome"
msgstr ""
#: bookwyrm/templates/get_started/layout.html:15
#: bookwyrm/templates/get_started/layout.html:20
#, python-format
msgid "Welcome to %(site_name)s!"
msgstr ""
#: bookwyrm/templates/get_started/layout.html:17
#: bookwyrm/templates/get_started/layout.html:22
msgid "These are some first steps to get you started."
msgstr ""
#: bookwyrm/templates/get_started/layout.html:31
#: bookwyrm/templates/get_started/layout.html:36
#: bookwyrm/templates/get_started/profile.html:6
msgid "Create your profile"
msgstr ""
#: bookwyrm/templates/get_started/layout.html:35
#: bookwyrm/templates/get_started/layout.html:40
msgid "Add books"
msgstr ""
#: bookwyrm/templates/get_started/layout.html:39
#: bookwyrm/templates/get_started/layout.html:44
msgid "Find friends"
msgstr ""
#: bookwyrm/templates/get_started/layout.html:45
#: bookwyrm/templates/get_started/layout.html:50
msgid "Skip this step"
msgstr ""
#: bookwyrm/templates/get_started/layout.html:49
#: bookwyrm/templates/get_started/layout.html:54
msgid "Finish"
msgstr ""
@ -1494,29 +1494,29 @@ msgstr ""
msgid "Display name:"
msgstr ""
#: bookwyrm/templates/get_started/profile.html:21
#: bookwyrm/templates/get_started/profile.html:29
#: bookwyrm/templates/preferences/edit_user.html:47
msgid "Summary:"
msgstr ""
#: bookwyrm/templates/get_started/profile.html:22
#: bookwyrm/templates/get_started/profile.html:34
msgid "A little bit about you"
msgstr ""
#: bookwyrm/templates/get_started/profile.html:30
#: bookwyrm/templates/get_started/profile.html:43
#: bookwyrm/templates/preferences/edit_user.html:27
msgid "Avatar:"
msgstr ""
#: bookwyrm/templates/get_started/profile.html:39
#: bookwyrm/templates/get_started/profile.html:52
msgid "Manually approve followers:"
msgstr ""
#: bookwyrm/templates/get_started/profile.html:45
#: bookwyrm/templates/get_started/profile.html:58
msgid "Show this account in suggested users:"
msgstr ""
#: bookwyrm/templates/get_started/profile.html:49
#: bookwyrm/templates/get_started/profile.html:62
msgid "Your account will show up in the directory, and may be recommended to other BookWyrm users."
msgstr ""
@ -1908,7 +1908,7 @@ msgid "Login"
msgstr ""
#: bookwyrm/templates/landing/login.html:7
#: bookwyrm/templates/landing/login.html:36 bookwyrm/templates/layout.html:181
#: bookwyrm/templates/landing/login.html:36 bookwyrm/templates/layout.html:178
#: bookwyrm/templates/ostatus/error.html:37
msgid "Log in"
msgstr ""
@ -1917,7 +1917,7 @@ msgstr ""
msgid "Success! Email address confirmed."
msgstr ""
#: bookwyrm/templates/landing/login.html:21 bookwyrm/templates/layout.html:172
#: bookwyrm/templates/landing/login.html:21 bookwyrm/templates/layout.html:169
#: bookwyrm/templates/ostatus/error.html:28
#: bookwyrm/templates/snippets/register_form.html:4
msgid "Username:"
@ -1925,12 +1925,12 @@ msgstr ""
#: bookwyrm/templates/landing/login.html:27
#: bookwyrm/templates/landing/password_reset.html:26
#: bookwyrm/templates/layout.html:176 bookwyrm/templates/ostatus/error.html:32
#: bookwyrm/templates/layout.html:173 bookwyrm/templates/ostatus/error.html:32
#: bookwyrm/templates/snippets/register_form.html:20
msgid "Password:"
msgstr ""
#: bookwyrm/templates/landing/login.html:39 bookwyrm/templates/layout.html:178
#: bookwyrm/templates/landing/login.html:39 bookwyrm/templates/layout.html:175
#: bookwyrm/templates/ostatus/error.html:34
msgid "Forgot your password?"
msgstr ""
@ -1962,19 +1962,19 @@ msgstr ""
msgid "Search for a book, user, or list"
msgstr ""
#: bookwyrm/templates/layout.html:63 bookwyrm/templates/layout.html:64
#: bookwyrm/templates/layout.html:63
msgid "Main navigation menu"
msgstr ""
#: bookwyrm/templates/layout.html:74
#: bookwyrm/templates/layout.html:71
msgid "Feed"
msgstr ""
#: bookwyrm/templates/layout.html:118
#: bookwyrm/templates/layout.html:115
msgid "Settings"
msgstr ""
#: bookwyrm/templates/layout.html:127
#: bookwyrm/templates/layout.html:124
#: bookwyrm/templates/settings/invites/manage_invite_requests.html:15
#: bookwyrm/templates/settings/invites/manage_invites.html:3
#: bookwyrm/templates/settings/invites/manage_invites.html:15
@ -1982,46 +1982,46 @@ msgstr ""
msgid "Invites"
msgstr ""
#: bookwyrm/templates/layout.html:134
#: bookwyrm/templates/layout.html:131
msgid "Admin"
msgstr ""
#: bookwyrm/templates/layout.html:141
#: bookwyrm/templates/layout.html:138
msgid "Log out"
msgstr ""
#: bookwyrm/templates/layout.html:149 bookwyrm/templates/layout.html:150
#: bookwyrm/templates/layout.html:146 bookwyrm/templates/layout.html:147
#: bookwyrm/templates/notifications/notifications_page.html:5
#: bookwyrm/templates/notifications/notifications_page.html:10
msgid "Notifications"
msgstr ""
#: bookwyrm/templates/layout.html:177 bookwyrm/templates/ostatus/error.html:33
#: bookwyrm/templates/layout.html:174 bookwyrm/templates/ostatus/error.html:33
msgid "password"
msgstr ""
#: bookwyrm/templates/layout.html:189
#: bookwyrm/templates/layout.html:186
msgid "Join"
msgstr ""
#: bookwyrm/templates/layout.html:223
#: bookwyrm/templates/layout.html:220
msgid "Successfully posted status"
msgstr ""
#: bookwyrm/templates/layout.html:224
#: bookwyrm/templates/layout.html:221
msgid "Error posting status"
msgstr ""
#: bookwyrm/templates/layout.html:240
#: bookwyrm/templates/layout.html:237
msgid "Documentation"
msgstr ""
#: bookwyrm/templates/layout.html:247
#: bookwyrm/templates/layout.html:244
#, python-format
msgid "Support %(site_name)s on <a href=\"%(support_link)s\" target=\"_blank\">%(support_title)s</a>"
msgstr ""
#: bookwyrm/templates/layout.html:251
#: bookwyrm/templates/layout.html:248
msgid "BookWyrm's source code is freely available. You can contribute or report issues on <a href=\"https://github.com/mouse-reeve/bookwyrm\">GitHub</a>."
msgstr ""
@ -2097,56 +2097,56 @@ msgstr ""
msgid "List curation:"
msgstr ""
#: bookwyrm/templates/lists/form.html:22
#: bookwyrm/templates/lists/form.html:31
msgid "Closed"
msgstr ""
#: bookwyrm/templates/lists/form.html:23
#: bookwyrm/templates/lists/form.html:34
msgid "Only you can add and remove books to this list"
msgstr ""
#: bookwyrm/templates/lists/form.html:27
#: bookwyrm/templates/lists/form.html:48
msgid "Curated"
msgstr ""
#: bookwyrm/templates/lists/form.html:28
#: bookwyrm/templates/lists/form.html:51
msgid "Anyone can suggest books, subject to your approval"
msgstr ""
#: bookwyrm/templates/lists/form.html:32
#: bookwyrm/templates/lists/form.html:65
msgctxt "curation type"
msgid "Open"
msgstr ""
#: bookwyrm/templates/lists/form.html:33
#: bookwyrm/templates/lists/form.html:68
msgid "Anyone can add books to this list"
msgstr ""
#: bookwyrm/templates/lists/form.html:37
#: bookwyrm/templates/lists/form.html:82
msgid "Group"
msgstr ""
#: bookwyrm/templates/lists/form.html:38
#: bookwyrm/templates/lists/form.html:85
msgid "Group members can add to and remove from this list"
msgstr ""
#: bookwyrm/templates/lists/form.html:41
#: bookwyrm/templates/lists/form.html:90
msgid "Select Group"
msgstr ""
#: bookwyrm/templates/lists/form.html:45
#: bookwyrm/templates/lists/form.html:94
msgid "Select a group"
msgstr ""
#: bookwyrm/templates/lists/form.html:56
#: bookwyrm/templates/lists/form.html:105
msgid "You don't have any Groups yet!"
msgstr ""
#: bookwyrm/templates/lists/form.html:58
#: bookwyrm/templates/lists/form.html:107
msgid "Create a Group"
msgstr ""
#: bookwyrm/templates/lists/form.html:81
#: bookwyrm/templates/lists/form.html:130
msgid "Delete list"
msgstr ""
@ -2163,62 +2163,62 @@ msgstr ""
msgid "Added by <a href=\"%(user_path)s\">%(username)s</a>"
msgstr ""
#: bookwyrm/templates/lists/list.html:76
#: bookwyrm/templates/lists/list.html:82
msgid "List position"
msgstr ""
#: bookwyrm/templates/lists/list.html:82
#: bookwyrm/templates/lists/list.html:88
msgid "Set"
msgstr ""
#: bookwyrm/templates/lists/list.html:92
#: bookwyrm/templates/lists/list.html:103
#: bookwyrm/templates/snippets/remove_from_group_button.html:19
msgid "Remove"
msgstr ""
#: bookwyrm/templates/lists/list.html:106
#: bookwyrm/templates/lists/list.html:123
#: bookwyrm/templates/lists/list.html:117
#: bookwyrm/templates/lists/list.html:134
msgid "Sort List"
msgstr ""
#: bookwyrm/templates/lists/list.html:116
#: bookwyrm/templates/lists/list.html:127
msgid "Direction"
msgstr ""
#: bookwyrm/templates/lists/list.html:130
#: bookwyrm/templates/lists/list.html:141
msgid "Add Books"
msgstr ""
#: bookwyrm/templates/lists/list.html:132
#: bookwyrm/templates/lists/list.html:143
msgid "Suggest Books"
msgstr ""
#: bookwyrm/templates/lists/list.html:143
#: bookwyrm/templates/lists/list.html:154
msgid "search"
msgstr ""
#: bookwyrm/templates/lists/list.html:149
#: bookwyrm/templates/lists/list.html:160
msgid "Clear search"
msgstr ""
#: bookwyrm/templates/lists/list.html:154
#: bookwyrm/templates/lists/list.html:165
#, python-format
msgid "No books found matching the query \"%(query)s\""
msgstr ""
#: bookwyrm/templates/lists/list.html:182
#: bookwyrm/templates/lists/list.html:197
msgid "Suggest"
msgstr ""
#: bookwyrm/templates/lists/list.html:191
#: bookwyrm/templates/lists/list.html:208
msgid "Embed this list on a website"
msgstr ""
#: bookwyrm/templates/lists/list.html:194
#: bookwyrm/templates/lists/list.html:216
msgid "Copy embed code"
msgstr ""
#: bookwyrm/templates/lists/list.html:194
#: bookwyrm/templates/lists/list.html:218
#, python-format
msgid "%(list_name)s, a list by %(owner)s on %(site_name)s"
msgstr ""
@ -2697,7 +2697,7 @@ msgstr ""
msgid "Edit Announcement"
msgstr ""
#: bookwyrm/templates/settings/announcements/announcement.html:35
#: bookwyrm/templates/settings/announcements/announcement.html:34
msgid "Visible:"
msgstr ""
@ -2709,19 +2709,19 @@ msgstr ""
msgid "False"
msgstr ""
#: bookwyrm/templates/settings/announcements/announcement.html:47
#: bookwyrm/templates/settings/announcements/announcement.html:46
#: bookwyrm/templates/settings/announcements/announcement_form.html:44
#: bookwyrm/templates/settings/dashboard/dashboard.html:71
msgid "Start date:"
msgstr ""
#: bookwyrm/templates/settings/announcements/announcement.html:54
#: bookwyrm/templates/settings/announcements/announcement.html:51
#: bookwyrm/templates/settings/announcements/announcement_form.html:54
#: bookwyrm/templates/settings/dashboard/dashboard.html:77
msgid "End date:"
msgstr ""
#: bookwyrm/templates/settings/announcements/announcement.html:60
#: bookwyrm/templates/settings/announcements/announcement.html:55
#: bookwyrm/templates/settings/announcements/announcement_form.html:64
msgid "Active:"
msgstr ""
@ -4284,7 +4284,7 @@ msgstr ""
msgid "Not a valid csv file"
msgstr ""
#: bookwyrm/views/landing/login.py:69
#: bookwyrm/views/landing/login.py:70
msgid "Username or password are incorrect"
msgstr ""

Binary file not shown.

View file

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: bookwyrm\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 15:00+0000\n"
"PO-Revision-Date: 2021-12-28 17:59\n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"PO-Revision-Date: 2021-12-28 22:55\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: Spanish\n"
"Language: es\n"
@ -263,76 +263,78 @@ msgstr "El año de lectura de <em>%(display_name)s</em>"
msgid "Share this page"
msgstr "Compartir esta página"
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:67
msgid "Copy address"
msgstr "Copiar dirección"
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
msgid "Copied!"
msgstr "¡Copiado!"
#: bookwyrm/templates/annual_summary/layout.html:69
#: bookwyrm/templates/annual_summary/layout.html:77
msgid "Sharing status: <strong>public with key</strong>"
msgstr "Nivel de compartido: <strong>público con llave</strong>"
#: bookwyrm/templates/annual_summary/layout.html:70
#: bookwyrm/templates/annual_summary/layout.html:78
msgid "The page can be seen by anyone with the complete address."
msgstr "La página puede ser vista por cualquier persona que tenga la dirección completa."
#: bookwyrm/templates/annual_summary/layout.html:75
#: bookwyrm/templates/annual_summary/layout.html:83
msgid "Make page private"
msgstr "Hacer privada la página"
#: bookwyrm/templates/annual_summary/layout.html:81
#: bookwyrm/templates/annual_summary/layout.html:89
msgid "Sharing status: <strong>private</strong>"
msgstr "Nivel de compartido: <strong>privado</strong>"
#: bookwyrm/templates/annual_summary/layout.html:82
#: bookwyrm/templates/annual_summary/layout.html:90
msgid "The page is private, only you can see it."
msgstr "La página es privada, solo tú puedes verla."
#: bookwyrm/templates/annual_summary/layout.html:87
#: bookwyrm/templates/annual_summary/layout.html:95
msgid "Make page public"
msgstr "Hacer pública la página"
#: bookwyrm/templates/annual_summary/layout.html:91
#: bookwyrm/templates/annual_summary/layout.html:99
msgid "When you make your page private, the old key wont give access to the page anymore. A new key will be created if the page is once again made public."
msgstr "Una vez que haces privada tu página, la clave antigua ya no dará acceso a la página. Si la página se vuelve a hacer pública se creará una nueva clave."
#: bookwyrm/templates/annual_summary/layout.html:104
#: bookwyrm/templates/annual_summary/layout.html:112
#, python-format
msgid "Sadly %(display_name)s didnt finish any book in %(year)s"
msgstr "Lamentablemente, %(display_name)s no terminó ningún libro en %(year)s"
#: bookwyrm/templates/annual_summary/layout.html:110
#: bookwyrm/templates/annual_summary/layout.html:118
#, python-format
msgid "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr "En %(year)s %(display_name)s ha leído %(books_total)s libros<br />¡haciendo un total de %(pages_total)s páginas!"
msgid "In %(year)s, %(display_name)s read %(books_total)s book<br />for a total of %(pages_total)s pages!"
msgid_plural "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr[0] "En %(year)s %(display_name)s ha leído %(books_total)s libro<br />¡haciendo un total de %(pages_total)s páginas!"
msgstr[1] "En %(year)s %(display_name)s ha leído %(books_total)s libros<br />¡haciendo un total de %(pages_total)s páginas!"
#: bookwyrm/templates/annual_summary/layout.html:112
#: bookwyrm/templates/annual_summary/layout.html:124
msgid "Thats great!"
msgstr "¡Eso es genial!"
#: bookwyrm/templates/annual_summary/layout.html:115
#: bookwyrm/templates/annual_summary/layout.html:127
#, python-format
msgid "That makes an average of %(pages)s pages per book."
msgstr "Eso hace un promedio de %(pages)s páginas por libro."
#: bookwyrm/templates/annual_summary/layout.html:120
#: bookwyrm/templates/annual_summary/layout.html:132
#, python-format
msgid "(%(no_page_number)s book doesnt have pages)"
msgid_plural "(%(no_page_number)s books dont have pages)"
msgstr[0] "(%(no_page_number)s libro no tiene páginas)"
msgstr[1] "(%(no_page_number)s libros no tienen páginas)"
#: bookwyrm/templates/annual_summary/layout.html:136
#: bookwyrm/templates/annual_summary/layout.html:148
msgid "Their shortest read this year…"
msgstr "Su lectura más corta de este año…"
#: bookwyrm/templates/annual_summary/layout.html:143
#: bookwyrm/templates/annual_summary/layout.html:164
#: bookwyrm/templates/annual_summary/layout.html:204
#: bookwyrm/templates/annual_summary/layout.html:155
#: bookwyrm/templates/annual_summary/layout.html:176
#: bookwyrm/templates/annual_summary/layout.html:220
#: bookwyrm/templates/book/book.html:47
#: bookwyrm/templates/discover/large-book.html:22
#: bookwyrm/templates/landing/large-book.html:25
@ -340,34 +342,36 @@ msgstr "Su lectura más corta de este año…"
msgid "by"
msgstr "por"
#: bookwyrm/templates/annual_summary/layout.html:149
#: bookwyrm/templates/annual_summary/layout.html:170
#: bookwyrm/templates/annual_summary/layout.html:161
#: bookwyrm/templates/annual_summary/layout.html:182
#, python-format
msgid "<strong>%(pages)s</strong> pages"
msgstr "<strong>%(pages)s</strong> páginas"
#: bookwyrm/templates/annual_summary/layout.html:157
#: bookwyrm/templates/annual_summary/layout.html:169
msgid "…and the longest"
msgstr "… y la más larga"
#: bookwyrm/templates/annual_summary/layout.html:187
#: bookwyrm/templates/annual_summary/layout.html:199
#, python-format
msgid "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr "%(display_name)s dio %(ratings_total)s valoraciones, <br />su valoración media es %(rating_average)s"
msgid "%(display_name)s left %(ratings_total)s rating, <br />their average rating is %(rating_average)s"
msgid_plural "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr[0] "%(display_name)s dio %(ratings_total)s valoración, <br />su valoración media es %(rating_average)s"
msgstr[1] "%(display_name)s dio %(ratings_total)s valoraciones, <br />su valoración media es %(rating_average)s"
#: bookwyrm/templates/annual_summary/layout.html:197
#: bookwyrm/templates/annual_summary/layout.html:213
msgid "Their best rated review"
msgstr "Su mejor valoración"
#: bookwyrm/templates/annual_summary/layout.html:210
#: bookwyrm/templates/annual_summary/layout.html:226
#, python-format
msgid "Their rating: <strong>%(rating)s</strong>"
msgstr "Su valoración: <strong>%(rating)s</strong>"
#: bookwyrm/templates/annual_summary/layout.html:227
#: bookwyrm/templates/annual_summary/layout.html:243
#, python-format
msgid "All the books %(display_name)s read in 2021"
msgstr "Todos los libros que ha leído %(display_name)s en 2021"
msgid "All the books %(display_name)s read in %(year)s"
msgstr "Todos los libros que ha leído %(display_name)s en %(year)s"
#: bookwyrm/templates/author/author.html:18
#: bookwyrm/templates/author/author.html:19

Binary file not shown.

View file

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: bookwyrm\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 15:00+0000\n"
"PO-Revision-Date: 2021-12-28 16:59\n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"PO-Revision-Date: 2021-12-28 21:17\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: French\n"
"Language: fr\n"
@ -263,76 +263,78 @@ msgstr "lannée de lecture de <em>%(display_name)s</em>"
msgid "Share this page"
msgstr "Partager cette page"
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:67
msgid "Copy address"
msgstr "Copier ladresse"
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
msgid "Copied!"
msgstr "Copié!"
#: bookwyrm/templates/annual_summary/layout.html:69
#: bookwyrm/templates/annual_summary/layout.html:77
msgid "Sharing status: <strong>public with key</strong>"
msgstr "Statut de partage : <strong>public avec clé</strong>"
#: bookwyrm/templates/annual_summary/layout.html:70
#: bookwyrm/templates/annual_summary/layout.html:78
msgid "The page can be seen by anyone with the complete address."
msgstr "La page peut être consultée par toute personne ayant l'adresse complète."
#: bookwyrm/templates/annual_summary/layout.html:75
#: bookwyrm/templates/annual_summary/layout.html:83
msgid "Make page private"
msgstr "Rendre cette page privée"
#: bookwyrm/templates/annual_summary/layout.html:81
#: bookwyrm/templates/annual_summary/layout.html:89
msgid "Sharing status: <strong>private</strong>"
msgstr "Statut de partage : <strong>privé</strong>"
#: bookwyrm/templates/annual_summary/layout.html:82
#: bookwyrm/templates/annual_summary/layout.html:90
msgid "The page is private, only you can see it."
msgstr "La page est privée, seulement vous pouvez la voir."
#: bookwyrm/templates/annual_summary/layout.html:87
#: bookwyrm/templates/annual_summary/layout.html:95
msgid "Make page public"
msgstr "Rendre cette page publique"
#: bookwyrm/templates/annual_summary/layout.html:91
#: bookwyrm/templates/annual_summary/layout.html:99
msgid "When you make your page private, the old key wont give access to the page anymore. A new key will be created if the page is once again made public."
msgstr "Lorsque vous rendez votre page privée, lancienne clé ne donnera plus accès à la page. Une nouvelle clé sera créée si la page est à nouveau rendue publique."
#: bookwyrm/templates/annual_summary/layout.html:104
#: bookwyrm/templates/annual_summary/layout.html:112
#, python-format
msgid "Sadly %(display_name)s didnt finish any book in %(year)s"
msgstr "Malheureusement, %(display_name)s na terminé aucun livre en %(year)s"
#: bookwyrm/templates/annual_summary/layout.html:110
#: bookwyrm/templates/annual_summary/layout.html:118
#, python-format
msgid "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr "En %(year)s, %(display_name)s a lu %(books_total)s livres<br />pour un total de %(pages_total)s pages !"
msgid "In %(year)s, %(display_name)s read %(books_total)s book<br />for a total of %(pages_total)s pages!"
msgid_plural "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr[0] "En %(year)s, %(display_name)s a lu %(books_total)s livre<br />pour un total de %(pages_total)s pages !"
msgstr[1] "En %(year)s, %(display_name)s a lu %(books_total)s livres<br />pour un total de %(pages_total)s pages !"
#: bookwyrm/templates/annual_summary/layout.html:112
#: bookwyrm/templates/annual_summary/layout.html:124
msgid "Thats great!"
msgstr "Cest génial !"
#: bookwyrm/templates/annual_summary/layout.html:115
#: bookwyrm/templates/annual_summary/layout.html:127
#, python-format
msgid "That makes an average of %(pages)s pages per book."
msgstr "Ce qui fait en moyenne %(pages)s pages par livre."
#: bookwyrm/templates/annual_summary/layout.html:120
#: bookwyrm/templates/annual_summary/layout.html:132
#, python-format
msgid "(%(no_page_number)s book doesnt have pages)"
msgid_plural "(%(no_page_number)s books dont have pages)"
msgstr[0] "(%(no_page_number)s livre na pas de pages)"
msgstr[1] "(%(no_page_number)s livres nont pas de pages)"
#: bookwyrm/templates/annual_summary/layout.html:136
#: bookwyrm/templates/annual_summary/layout.html:148
msgid "Their shortest read this year…"
msgstr "Sa lecture la plus courte lannée…"
#: bookwyrm/templates/annual_summary/layout.html:143
#: bookwyrm/templates/annual_summary/layout.html:164
#: bookwyrm/templates/annual_summary/layout.html:204
#: bookwyrm/templates/annual_summary/layout.html:155
#: bookwyrm/templates/annual_summary/layout.html:176
#: bookwyrm/templates/annual_summary/layout.html:220
#: bookwyrm/templates/book/book.html:47
#: bookwyrm/templates/discover/large-book.html:22
#: bookwyrm/templates/landing/large-book.html:25
@ -340,34 +342,36 @@ msgstr "Sa lecture la plus courte lannée…"
msgid "by"
msgstr "de"
#: bookwyrm/templates/annual_summary/layout.html:149
#: bookwyrm/templates/annual_summary/layout.html:170
#: bookwyrm/templates/annual_summary/layout.html:161
#: bookwyrm/templates/annual_summary/layout.html:182
#, python-format
msgid "<strong>%(pages)s</strong> pages"
msgstr "<strong>%(pages)s</strong> pages"
#: bookwyrm/templates/annual_summary/layout.html:157
#: bookwyrm/templates/annual_summary/layout.html:169
msgid "…and the longest"
msgstr "…et sa plus longue lecture"
#: bookwyrm/templates/annual_summary/layout.html:187
#: bookwyrm/templates/annual_summary/layout.html:199
#, python-format
msgid "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr "%(display_name)s a laissé %(ratings_total)s notes, <br />sa note moyenne est %(rating_average)s"
msgid "%(display_name)s left %(ratings_total)s rating, <br />their average rating is %(rating_average)s"
msgid_plural "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr[0] "%(display_name)s a laissé %(ratings_total)s critique, <br />sa note moyenne est %(rating_average)s"
msgstr[1] "%(display_name)s a laissé %(ratings_total)s critiques, <br />sa note moyenne est %(rating_average)s"
#: bookwyrm/templates/annual_summary/layout.html:197
#: bookwyrm/templates/annual_summary/layout.html:213
msgid "Their best rated review"
msgstr "Son avis le mieux noté"
#: bookwyrm/templates/annual_summary/layout.html:210
#: bookwyrm/templates/annual_summary/layout.html:226
#, python-format
msgid "Their rating: <strong>%(rating)s</strong>"
msgstr "Sa note : <strong>%(rating)s</strong>"
#: bookwyrm/templates/annual_summary/layout.html:227
#: bookwyrm/templates/annual_summary/layout.html:243
#, python-format
msgid "All the books %(display_name)s read in 2021"
msgstr "Tous les livres que %(display_name)s a lus"
msgid "All the books %(display_name)s read in %(year)s"
msgstr "Tous les livres que %(display_name)s a lus en %(year)s"
#: bookwyrm/templates/author/author.html:18
#: bookwyrm/templates/author/author.html:19

Binary file not shown.

View file

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: bookwyrm\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 15:00+0000\n"
"PO-Revision-Date: 2021-12-28 16:03\n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"PO-Revision-Date: 2021-12-29 06:07\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: Galician\n"
"Language: gl\n"
@ -263,76 +263,78 @@ msgstr "Un ano de lecturas de <em>%(display_name)s</em>"
msgid "Share this page"
msgstr "Comparte esta páxina"
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:67
msgid "Copy address"
msgstr "Copiar enderezo"
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
msgid "Copied!"
msgstr "Copiado!"
#: bookwyrm/templates/annual_summary/layout.html:69
#: bookwyrm/templates/annual_summary/layout.html:77
msgid "Sharing status: <strong>public with key</strong>"
msgstr "Compartir estado: <strong>público con chave</strong>"
#: bookwyrm/templates/annual_summary/layout.html:70
#: bookwyrm/templates/annual_summary/layout.html:78
msgid "The page can be seen by anyone with the complete address."
msgstr "Esta páxina será visible para calquera que teña o enderezo completo."
#: bookwyrm/templates/annual_summary/layout.html:75
#: bookwyrm/templates/annual_summary/layout.html:83
msgid "Make page private"
msgstr "Facer privada a páxina"
#: bookwyrm/templates/annual_summary/layout.html:81
#: bookwyrm/templates/annual_summary/layout.html:89
msgid "Sharing status: <strong>private</strong>"
msgstr "Compartir estado: <strong>privado</strong>"
#: bookwyrm/templates/annual_summary/layout.html:82
#: bookwyrm/templates/annual_summary/layout.html:90
msgid "The page is private, only you can see it."
msgstr "Esta páxina é privada só ti podes vela."
#: bookwyrm/templates/annual_summary/layout.html:87
#: bookwyrm/templates/annual_summary/layout.html:95
msgid "Make page public"
msgstr "Facer pública a páxina"
#: bookwyrm/templates/annual_summary/layout.html:91
#: bookwyrm/templates/annual_summary/layout.html:99
msgid "When you make your page private, the old key wont give access to the page anymore. A new key will be created if the page is once again made public."
msgstr "Cando fas privada unha páxina, a chave antiga non dará acceso á mesma nunca máis. Crearase unha nova chave se volves a facer pública a páxina."
#: bookwyrm/templates/annual_summary/layout.html:104
#: bookwyrm/templates/annual_summary/layout.html:112
#, python-format
msgid "Sadly %(display_name)s didnt finish any book in %(year)s"
msgstr "Unha mágoa, pero %(display_name)s aínda non rematou ningún libro en %(year)s"
#: bookwyrm/templates/annual_summary/layout.html:110
#: bookwyrm/templates/annual_summary/layout.html:118
#, python-format
msgid "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr "En %(year)s, %(display_name)s leu %(books_total)s libros<br /> cun total de %(pages_total)s páxinas!"
msgid "In %(year)s, %(display_name)s read %(books_total)s book<br />for a total of %(pages_total)s pages!"
msgid_plural "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr[0] "En %(year)s, %(display_name)s leu %(books_total)s libro<br />cun total de %(pages_total)s páxinas!"
msgstr[1] "En %(year)s, %(display_name)s leu %(books_total)s libros<br />cun total de %(pages_total)s páxinas!"
#: bookwyrm/templates/annual_summary/layout.html:112
#: bookwyrm/templates/annual_summary/layout.html:124
msgid "Thats great!"
msgstr "Está moi ben!"
#: bookwyrm/templates/annual_summary/layout.html:115
#: bookwyrm/templates/annual_summary/layout.html:127
#, python-format
msgid "That makes an average of %(pages)s pages per book."
msgstr ""
msgstr "Esto fai unha media de %(pages)s páxinas por libro."
#: bookwyrm/templates/annual_summary/layout.html:120
#: bookwyrm/templates/annual_summary/layout.html:132
#, python-format
msgid "(%(no_page_number)s book doesnt have pages)"
msgid_plural "(%(no_page_number)s books dont have pages)"
msgstr[0] "(%(no_page_number)s libro non ten páxinas)"
msgstr[1] "(%(no_page_number)s libros non teñen páxinas)"
#: bookwyrm/templates/annual_summary/layout.html:136
#: bookwyrm/templates/annual_summary/layout.html:148
msgid "Their shortest read this year…"
msgstr "A lectura máis curta deste ano…"
#: bookwyrm/templates/annual_summary/layout.html:143
#: bookwyrm/templates/annual_summary/layout.html:164
#: bookwyrm/templates/annual_summary/layout.html:204
#: bookwyrm/templates/annual_summary/layout.html:155
#: bookwyrm/templates/annual_summary/layout.html:176
#: bookwyrm/templates/annual_summary/layout.html:220
#: bookwyrm/templates/book/book.html:47
#: bookwyrm/templates/discover/large-book.html:22
#: bookwyrm/templates/landing/large-book.html:25
@ -340,34 +342,36 @@ msgstr "A lectura máis curta deste ano…"
msgid "by"
msgstr "por"
#: bookwyrm/templates/annual_summary/layout.html:149
#: bookwyrm/templates/annual_summary/layout.html:170
#: bookwyrm/templates/annual_summary/layout.html:161
#: bookwyrm/templates/annual_summary/layout.html:182
#, python-format
msgid "<strong>%(pages)s</strong> pages"
msgstr "<strong>%(pages)s</strong> páxinas"
#: bookwyrm/templates/annual_summary/layout.html:157
#: bookwyrm/templates/annual_summary/layout.html:169
msgid "…and the longest"
msgstr "…e a máis longa"
#: bookwyrm/templates/annual_summary/layout.html:187
#: bookwyrm/templates/annual_summary/layout.html:199
#, python-format
msgid "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr "%(display_name)s escribiu %(ratings_total)s valoracións, <br />a media das súas valoracións é %(rating_average)s"
msgid "%(display_name)s left %(ratings_total)s rating, <br />their average rating is %(rating_average)s"
msgid_plural "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr[0] "%(display_name)s fixo %(ratings_total)s valoración,<br />cunha media de %(rating_average)s"
msgstr[1] "%(display_name)s fixo %(ratings_total)s valoracións,<br />cunha puntuación media de %(rating_average)s"
#: bookwyrm/templates/annual_summary/layout.html:197
#: bookwyrm/templates/annual_summary/layout.html:213
msgid "Their best rated review"
msgstr "A súa recensión máis valorada"
#: bookwyrm/templates/annual_summary/layout.html:210
#: bookwyrm/templates/annual_summary/layout.html:226
#, python-format
msgid "Their rating: <strong>%(rating)s</strong>"
msgstr "Valoración: <strong>%(rating)s</strong>"
#: bookwyrm/templates/annual_summary/layout.html:227
#: bookwyrm/templates/annual_summary/layout.html:243
#, python-format
msgid "All the books %(display_name)s read in 2021"
msgstr "Tódolos libros lidos por %(display_name)s en 2021"
msgid "All the books %(display_name)s read in %(year)s"
msgstr "Tódolos libros que %(display_name)s leu en %(year)s"
#: bookwyrm/templates/author/author.html:18
#: bookwyrm/templates/author/author.html:19

Binary file not shown.

View file

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: bookwyrm\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 15:00+0000\n"
"PO-Revision-Date: 2021-12-28 16:03\n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"PO-Revision-Date: 2021-12-28 21:17\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: Lithuanian\n"
"Language: lt\n"
@ -263,63 +263,67 @@ msgstr ""
msgid "Share this page"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:67
msgid "Copy address"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
msgid "Copied!"
msgstr "Nukopijuota"
#: bookwyrm/templates/annual_summary/layout.html:69
#: bookwyrm/templates/annual_summary/layout.html:77
msgid "Sharing status: <strong>public with key</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:70
#: bookwyrm/templates/annual_summary/layout.html:78
msgid "The page can be seen by anyone with the complete address."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:75
#: bookwyrm/templates/annual_summary/layout.html:83
msgid "Make page private"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:81
#: bookwyrm/templates/annual_summary/layout.html:89
msgid "Sharing status: <strong>private</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:82
#: bookwyrm/templates/annual_summary/layout.html:90
msgid "The page is private, only you can see it."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:87
#: bookwyrm/templates/annual_summary/layout.html:95
msgid "Make page public"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:91
#: bookwyrm/templates/annual_summary/layout.html:99
msgid "When you make your page private, the old key wont give access to the page anymore. A new key will be created if the page is once again made public."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:104
#: bookwyrm/templates/annual_summary/layout.html:112
#, python-format
msgid "Sadly %(display_name)s didnt finish any book in %(year)s"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:110
#: bookwyrm/templates/annual_summary/layout.html:118
#, python-format
msgid "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr ""
msgid "In %(year)s, %(display_name)s read %(books_total)s book<br />for a total of %(pages_total)s pages!"
msgid_plural "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr[0] ""
msgstr[1] ""
msgstr[2] ""
msgstr[3] ""
#: bookwyrm/templates/annual_summary/layout.html:112
#: bookwyrm/templates/annual_summary/layout.html:124
msgid "Thats great!"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:115
#: bookwyrm/templates/annual_summary/layout.html:127
#, python-format
msgid "That makes an average of %(pages)s pages per book."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:120
#: bookwyrm/templates/annual_summary/layout.html:132
#, python-format
msgid "(%(no_page_number)s book doesnt have pages)"
msgid_plural "(%(no_page_number)s books dont have pages)"
@ -328,13 +332,13 @@ msgstr[1] ""
msgstr[2] ""
msgstr[3] ""
#: bookwyrm/templates/annual_summary/layout.html:136
#: bookwyrm/templates/annual_summary/layout.html:148
msgid "Their shortest read this year…"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:143
#: bookwyrm/templates/annual_summary/layout.html:164
#: bookwyrm/templates/annual_summary/layout.html:204
#: bookwyrm/templates/annual_summary/layout.html:155
#: bookwyrm/templates/annual_summary/layout.html:176
#: bookwyrm/templates/annual_summary/layout.html:220
#: bookwyrm/templates/book/book.html:47
#: bookwyrm/templates/discover/large-book.html:22
#: bookwyrm/templates/landing/large-book.html:25
@ -342,33 +346,37 @@ msgstr ""
msgid "by"
msgstr " "
#: bookwyrm/templates/annual_summary/layout.html:149
#: bookwyrm/templates/annual_summary/layout.html:170
#: bookwyrm/templates/annual_summary/layout.html:161
#: bookwyrm/templates/annual_summary/layout.html:182
#, python-format
msgid "<strong>%(pages)s</strong> pages"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:157
#: bookwyrm/templates/annual_summary/layout.html:169
msgid "…and the longest"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:187
#: bookwyrm/templates/annual_summary/layout.html:199
#, python-format
msgid "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr ""
msgid "%(display_name)s left %(ratings_total)s rating, <br />their average rating is %(rating_average)s"
msgid_plural "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr[0] ""
msgstr[1] ""
msgstr[2] ""
msgstr[3] ""
#: bookwyrm/templates/annual_summary/layout.html:197
#: bookwyrm/templates/annual_summary/layout.html:213
msgid "Their best rated review"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:210
#: bookwyrm/templates/annual_summary/layout.html:226
#, python-format
msgid "Their rating: <strong>%(rating)s</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:227
#: bookwyrm/templates/annual_summary/layout.html:243
#, python-format
msgid "All the books %(display_name)s read in 2021"
msgid "All the books %(display_name)s read in %(year)s"
msgstr ""
#: bookwyrm/templates/author/author.html:18

Binary file not shown.

View file

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: bookwyrm\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 15:00+0000\n"
"PO-Revision-Date: 2021-12-28 16:59\n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"PO-Revision-Date: 2021-12-29 00:08\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: Portuguese, Brazilian\n"
"Language: pt\n"
@ -263,76 +263,78 @@ msgstr "O ano de leitura de <em>%(display_name)s</em>"
msgid "Share this page"
msgstr "Compartilhe esta página"
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:67
msgid "Copy address"
msgstr "Copiar endereço"
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
msgid "Copied!"
msgstr "Copiado!"
#: bookwyrm/templates/annual_summary/layout.html:69
#: bookwyrm/templates/annual_summary/layout.html:77
msgid "Sharing status: <strong>public with key</strong>"
msgstr "Compartilhamento: <strong>público com chave</strong>"
#: bookwyrm/templates/annual_summary/layout.html:70
#: bookwyrm/templates/annual_summary/layout.html:78
msgid "The page can be seen by anyone with the complete address."
msgstr "Esta página pode ser vista por qualquer pessoa que tenha seu link."
#: bookwyrm/templates/annual_summary/layout.html:75
#: bookwyrm/templates/annual_summary/layout.html:83
msgid "Make page private"
msgstr "Tornar a página particular"
#: bookwyrm/templates/annual_summary/layout.html:81
#: bookwyrm/templates/annual_summary/layout.html:89
msgid "Sharing status: <strong>private</strong>"
msgstr "Compartilhamento: <strong>particular</strong>"
#: bookwyrm/templates/annual_summary/layout.html:82
#: bookwyrm/templates/annual_summary/layout.html:90
msgid "The page is private, only you can see it."
msgstr "A página é particular, só você pode vê-la."
#: bookwyrm/templates/annual_summary/layout.html:87
#: bookwyrm/templates/annual_summary/layout.html:95
msgid "Make page public"
msgstr "Tornar a página pública"
#: bookwyrm/templates/annual_summary/layout.html:91
#: bookwyrm/templates/annual_summary/layout.html:99
msgid "When you make your page private, the old key wont give access to the page anymore. A new key will be created if the page is once again made public."
msgstr "Ao tornar a página particular, a chave antiga passa a não funcionar mais. Uma nova chave será gerada quando a página for tornada pública novamente."
#: bookwyrm/templates/annual_summary/layout.html:104
#: bookwyrm/templates/annual_summary/layout.html:112
#, python-format
msgid "Sadly %(display_name)s didnt finish any book in %(year)s"
msgstr "Infelizmente %(display_name)s não terminou nenhum livro em %(year)s"
#: bookwyrm/templates/annual_summary/layout.html:110
#: bookwyrm/templates/annual_summary/layout.html:118
#, python-format
msgid "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr "Em %(year)s, %(display_name)s leu %(books_total)s livros,<br />um total de %(pages_total)s páginas!"
msgid "In %(year)s, %(display_name)s read %(books_total)s book<br />for a total of %(pages_total)s pages!"
msgid_plural "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr[0] "Em %(year)s, %(display_name)s leu %(books_total)s livro,<br />um total de %(pages_total)s páginas!"
msgstr[1] "Em %(year)s, %(display_name)s leu %(books_total)s livros,<br />um total de %(pages_total)s páginas!"
#: bookwyrm/templates/annual_summary/layout.html:112
#: bookwyrm/templates/annual_summary/layout.html:124
msgid "Thats great!"
msgstr "Muito legal!"
#: bookwyrm/templates/annual_summary/layout.html:115
#: bookwyrm/templates/annual_summary/layout.html:127
#, python-format
msgid "That makes an average of %(pages)s pages per book."
msgstr "Isso dá uma média de %(pages)s páginas por livro."
#: bookwyrm/templates/annual_summary/layout.html:120
#: bookwyrm/templates/annual_summary/layout.html:132
#, python-format
msgid "(%(no_page_number)s book doesnt have pages)"
msgid_plural "(%(no_page_number)s books dont have pages)"
msgstr[0] "(%(no_page_number)s livro não tem páginas cadastradas)"
msgstr[1] "(%(no_page_number)s livros não têm páginas cadastradas)"
#: bookwyrm/templates/annual_summary/layout.html:136
#: bookwyrm/templates/annual_summary/layout.html:148
msgid "Their shortest read this year…"
msgstr "A leitura mais curta do ano…"
#: bookwyrm/templates/annual_summary/layout.html:143
#: bookwyrm/templates/annual_summary/layout.html:164
#: bookwyrm/templates/annual_summary/layout.html:204
#: bookwyrm/templates/annual_summary/layout.html:155
#: bookwyrm/templates/annual_summary/layout.html:176
#: bookwyrm/templates/annual_summary/layout.html:220
#: bookwyrm/templates/book/book.html:47
#: bookwyrm/templates/discover/large-book.html:22
#: bookwyrm/templates/landing/large-book.html:25
@ -340,34 +342,36 @@ msgstr "A leitura mais curta do ano…"
msgid "by"
msgstr "de"
#: bookwyrm/templates/annual_summary/layout.html:149
#: bookwyrm/templates/annual_summary/layout.html:170
#: bookwyrm/templates/annual_summary/layout.html:161
#: bookwyrm/templates/annual_summary/layout.html:182
#, python-format
msgid "<strong>%(pages)s</strong> pages"
msgstr "<strong>%(pages)s</strong> páginas"
#: bookwyrm/templates/annual_summary/layout.html:157
#: bookwyrm/templates/annual_summary/layout.html:169
msgid "…and the longest"
msgstr "…e a mais longa"
#: bookwyrm/templates/annual_summary/layout.html:187
#: bookwyrm/templates/annual_summary/layout.html:199
#, python-format
msgid "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr "%(display_name)s fez %(ratings_total)s avaliações, <br />e sua nota média é %(rating_average)s"
msgid "%(display_name)s left %(ratings_total)s rating, <br />their average rating is %(rating_average)s"
msgid_plural "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr[0] "%(display_name)s fez %(ratings_total)s avaliação, <br />com uma média de %(rating_average)s"
msgstr[1] "%(display_name)s fez %(ratings_total)s avaliações, <br />com uma média de %(rating_average)s"
#: bookwyrm/templates/annual_summary/layout.html:197
#: bookwyrm/templates/annual_summary/layout.html:213
msgid "Their best rated review"
msgstr "Sua melhor avaliação"
#: bookwyrm/templates/annual_summary/layout.html:210
#: bookwyrm/templates/annual_summary/layout.html:226
#, python-format
msgid "Their rating: <strong>%(rating)s</strong>"
msgstr "Avaliação: <strong>%(rating)s</strong>"
#: bookwyrm/templates/annual_summary/layout.html:227
#: bookwyrm/templates/annual_summary/layout.html:243
#, python-format
msgid "All the books %(display_name)s read in 2021"
msgstr "Todos os livros que %(display_name)s leu em 2021"
msgid "All the books %(display_name)s read in %(year)s"
msgstr "Todos os livros lidos por %(display_name)s em %(year)s"
#: bookwyrm/templates/author/author.html:18
#: bookwyrm/templates/author/author.html:19

Binary file not shown.

View file

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: bookwyrm\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 15:00+0000\n"
"PO-Revision-Date: 2021-12-28 16:03\n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"PO-Revision-Date: 2021-12-28 21:17\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: Chinese Simplified\n"
"Language: zh\n"
@ -263,75 +263,76 @@ msgstr ""
msgid "Share this page"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:67
msgid "Copy address"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
msgid "Copied!"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:69
#: bookwyrm/templates/annual_summary/layout.html:77
msgid "Sharing status: <strong>public with key</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:70
#: bookwyrm/templates/annual_summary/layout.html:78
msgid "The page can be seen by anyone with the complete address."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:75
#: bookwyrm/templates/annual_summary/layout.html:83
msgid "Make page private"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:81
#: bookwyrm/templates/annual_summary/layout.html:89
msgid "Sharing status: <strong>private</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:82
#: bookwyrm/templates/annual_summary/layout.html:90
msgid "The page is private, only you can see it."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:87
#: bookwyrm/templates/annual_summary/layout.html:95
msgid "Make page public"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:91
#: bookwyrm/templates/annual_summary/layout.html:99
msgid "When you make your page private, the old key wont give access to the page anymore. A new key will be created if the page is once again made public."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:104
#: bookwyrm/templates/annual_summary/layout.html:112
#, python-format
msgid "Sadly %(display_name)s didnt finish any book in %(year)s"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:110
#: bookwyrm/templates/annual_summary/layout.html:118
#, python-format
msgid "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr ""
msgid "In %(year)s, %(display_name)s read %(books_total)s book<br />for a total of %(pages_total)s pages!"
msgid_plural "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr[0] ""
#: bookwyrm/templates/annual_summary/layout.html:112
#: bookwyrm/templates/annual_summary/layout.html:124
msgid "Thats great!"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:115
#: bookwyrm/templates/annual_summary/layout.html:127
#, python-format
msgid "That makes an average of %(pages)s pages per book."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:120
#: bookwyrm/templates/annual_summary/layout.html:132
#, python-format
msgid "(%(no_page_number)s book doesnt have pages)"
msgid_plural "(%(no_page_number)s books dont have pages)"
msgstr[0] ""
#: bookwyrm/templates/annual_summary/layout.html:136
#: bookwyrm/templates/annual_summary/layout.html:148
msgid "Their shortest read this year…"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:143
#: bookwyrm/templates/annual_summary/layout.html:164
#: bookwyrm/templates/annual_summary/layout.html:204
#: bookwyrm/templates/annual_summary/layout.html:155
#: bookwyrm/templates/annual_summary/layout.html:176
#: bookwyrm/templates/annual_summary/layout.html:220
#: bookwyrm/templates/book/book.html:47
#: bookwyrm/templates/discover/large-book.html:22
#: bookwyrm/templates/landing/large-book.html:25
@ -339,33 +340,34 @@ msgstr ""
msgid "by"
msgstr "作者"
#: bookwyrm/templates/annual_summary/layout.html:149
#: bookwyrm/templates/annual_summary/layout.html:170
#: bookwyrm/templates/annual_summary/layout.html:161
#: bookwyrm/templates/annual_summary/layout.html:182
#, python-format
msgid "<strong>%(pages)s</strong> pages"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:157
#: bookwyrm/templates/annual_summary/layout.html:169
msgid "…and the longest"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:187
#: bookwyrm/templates/annual_summary/layout.html:199
#, python-format
msgid "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr ""
msgid "%(display_name)s left %(ratings_total)s rating, <br />their average rating is %(rating_average)s"
msgid_plural "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr[0] ""
#: bookwyrm/templates/annual_summary/layout.html:197
#: bookwyrm/templates/annual_summary/layout.html:213
msgid "Their best rated review"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:210
#: bookwyrm/templates/annual_summary/layout.html:226
#, python-format
msgid "Their rating: <strong>%(rating)s</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:227
#: bookwyrm/templates/annual_summary/layout.html:243
#, python-format
msgid "All the books %(display_name)s read in 2021"
msgid "All the books %(display_name)s read in %(year)s"
msgstr ""
#: bookwyrm/templates/author/author.html:18

Binary file not shown.

View file

@ -2,8 +2,8 @@ msgid ""
msgstr ""
"Project-Id-Version: bookwyrm\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-12-28 15:00+0000\n"
"PO-Revision-Date: 2021-12-28 16:03\n"
"POT-Creation-Date: 2021-12-28 20:12+0000\n"
"PO-Revision-Date: 2021-12-28 21:17\n"
"Last-Translator: Mouse Reeve <mousereeve@riseup.net>\n"
"Language-Team: Chinese Traditional\n"
"Language: zh\n"
@ -263,75 +263,76 @@ msgstr ""
msgid "Share this page"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:67
msgid "Copy address"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:61
#: bookwyrm/templates/annual_summary/layout.html:68
#: bookwyrm/templates/lists/list.html:194
msgid "Copied!"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:69
#: bookwyrm/templates/annual_summary/layout.html:77
msgid "Sharing status: <strong>public with key</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:70
#: bookwyrm/templates/annual_summary/layout.html:78
msgid "The page can be seen by anyone with the complete address."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:75
#: bookwyrm/templates/annual_summary/layout.html:83
msgid "Make page private"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:81
#: bookwyrm/templates/annual_summary/layout.html:89
msgid "Sharing status: <strong>private</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:82
#: bookwyrm/templates/annual_summary/layout.html:90
msgid "The page is private, only you can see it."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:87
#: bookwyrm/templates/annual_summary/layout.html:95
msgid "Make page public"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:91
#: bookwyrm/templates/annual_summary/layout.html:99
msgid "When you make your page private, the old key wont give access to the page anymore. A new key will be created if the page is once again made public."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:104
#: bookwyrm/templates/annual_summary/layout.html:112
#, python-format
msgid "Sadly %(display_name)s didnt finish any book in %(year)s"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:110
#: bookwyrm/templates/annual_summary/layout.html:118
#, python-format
msgid "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr ""
msgid "In %(year)s, %(display_name)s read %(books_total)s book<br />for a total of %(pages_total)s pages!"
msgid_plural "In %(year)s, %(display_name)s read %(books_total)s books<br />for a total of %(pages_total)s pages!"
msgstr[0] ""
#: bookwyrm/templates/annual_summary/layout.html:112
#: bookwyrm/templates/annual_summary/layout.html:124
msgid "Thats great!"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:115
#: bookwyrm/templates/annual_summary/layout.html:127
#, python-format
msgid "That makes an average of %(pages)s pages per book."
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:120
#: bookwyrm/templates/annual_summary/layout.html:132
#, python-format
msgid "(%(no_page_number)s book doesnt have pages)"
msgid_plural "(%(no_page_number)s books dont have pages)"
msgstr[0] ""
#: bookwyrm/templates/annual_summary/layout.html:136
#: bookwyrm/templates/annual_summary/layout.html:148
msgid "Their shortest read this year…"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:143
#: bookwyrm/templates/annual_summary/layout.html:164
#: bookwyrm/templates/annual_summary/layout.html:204
#: bookwyrm/templates/annual_summary/layout.html:155
#: bookwyrm/templates/annual_summary/layout.html:176
#: bookwyrm/templates/annual_summary/layout.html:220
#: bookwyrm/templates/book/book.html:47
#: bookwyrm/templates/discover/large-book.html:22
#: bookwyrm/templates/landing/large-book.html:25
@ -339,33 +340,34 @@ msgstr ""
msgid "by"
msgstr "作者"
#: bookwyrm/templates/annual_summary/layout.html:149
#: bookwyrm/templates/annual_summary/layout.html:170
#: bookwyrm/templates/annual_summary/layout.html:161
#: bookwyrm/templates/annual_summary/layout.html:182
#, python-format
msgid "<strong>%(pages)s</strong> pages"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:157
#: bookwyrm/templates/annual_summary/layout.html:169
msgid "…and the longest"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:187
#: bookwyrm/templates/annual_summary/layout.html:199
#, python-format
msgid "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr ""
msgid "%(display_name)s left %(ratings_total)s rating, <br />their average rating is %(rating_average)s"
msgid_plural "%(display_name)s left %(ratings_total)s ratings, <br />their average rating is %(rating_average)s"
msgstr[0] ""
#: bookwyrm/templates/annual_summary/layout.html:197
#: bookwyrm/templates/annual_summary/layout.html:213
msgid "Their best rated review"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:210
#: bookwyrm/templates/annual_summary/layout.html:226
#, python-format
msgid "Their rating: <strong>%(rating)s</strong>"
msgstr ""
#: bookwyrm/templates/annual_summary/layout.html:227
#: bookwyrm/templates/annual_summary/layout.html:243
#, python-format
msgid "All the books %(display_name)s read in 2021"
msgid "All the books %(display_name)s read in %(year)s"
msgstr ""
#: bookwyrm/templates/author/author.html:18