From 9e2b4f61bb65d5ed2c506fc289fa92a17e2cfdc1 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 29 Apr 2021 12:13:49 -0700 Subject: [PATCH 1/7] Make subheaders a lil smaller --- bookwyrm/templates/search_results.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bookwyrm/templates/search_results.html b/bookwyrm/templates/search_results.html index 4c9c23da..2dba79a2 100644 --- a/bookwyrm/templates/search_results.html +++ b/bookwyrm/templates/search_results.html @@ -11,7 +11,7 @@
-

{% trans "Matching Books" %}

+

{% trans "Matching Books" %}

{% if not local_results.results %}

{% blocktrans %}No books found for "{{ query }}"{% endblocktrans %}

@@ -71,7 +71,7 @@
-

{% trans "Matching Users" %}

+

{% trans "Matching Users" %}

{% if not user_results %}

{% blocktrans %}No users found for "{{ query }}"{% endblocktrans %}

{% endif %} @@ -88,7 +88,7 @@
-

{% trans "Lists" %}

+

{% trans "Lists" %}

{% if not list_results %}

{% blocktrans %}No lists found for "{{ query }}"{% endblocktrans %}

{% endif %} From 9d89aaf9fcdbfb84187ae0ac9c991fc2a94e8ac7 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 29 Apr 2021 12:18:55 -0700 Subject: [PATCH 2/7] Don't let logged out viwers search for users --- bookwyrm/templates/search_results.html | 6 +++-- bookwyrm/views/search.py | 37 +++++++++++++------------- 2 files changed, 22 insertions(+), 21 deletions(-) diff --git a/bookwyrm/templates/search_results.html b/bookwyrm/templates/search_results.html index 2dba79a2..9188c1f0 100644 --- a/bookwyrm/templates/search_results.html +++ b/bookwyrm/templates/search_results.html @@ -70,10 +70,11 @@ {% endif %}
+ {% if request.user.is_authenticated %}

{% trans "Matching Users" %}

{% if not user_results %} -

{% blocktrans %}No users found for "{{ query }}"{% endblocktrans %}

+

{% blocktrans %}No users found for "{{ query }}"{% endblocktrans %}

{% endif %}
    {% for result in user_results %} @@ -87,10 +88,11 @@ {% endfor %}
+ {% endif %}

{% trans "Lists" %}

{% if not list_results %} -

{% blocktrans %}No lists found for "{{ query }}"{% endblocktrans %}

+

{% blocktrans %}No lists found for "{{ query }}"{% endblocktrans %}

{% endif %} {% for result in list_results %}
diff --git a/bookwyrm/views/search.py b/bookwyrm/views/search.py index 4543b55e..bd5ac3c7 100644 --- a/bookwyrm/views/search.py +++ b/bookwyrm/views/search.py @@ -30,27 +30,30 @@ class Search(View): ) return JsonResponse([r.json() for r in book_results], safe=False) + data = {"query": query or ""} + # use webfinger for mastodon style account@domain.com username if query and re.match(regex.full_username, query): handle_remote_webfinger(query) # do a user search - user_results = ( - models.User.viewer_aware_objects(request.user) - .annotate( - similarity=Greatest( - TrigramSimilarity("username", query), - TrigramSimilarity("localname", query), + if request.user.is_authenticated: + data["user_results"] = ( + models.User.viewer_aware_objects(request.user) + .annotate( + similarity=Greatest( + TrigramSimilarity("username", query), + TrigramSimilarity("localname", query), + ) ) + .filter( + similarity__gt=0.5, + ) + .order_by("-similarity")[:10] ) - .filter( - similarity__gt=0.5, - ) - .order_by("-similarity")[:10] - ) # any relevent lists? - list_results = ( + data["list_results"] = ( privacy_filter( request.user, models.List.objects, @@ -68,11 +71,7 @@ class Search(View): .order_by("-similarity")[:10] ) - book_results = connector_manager.search(query, min_confidence=min_confidence) - data = { - "book_results": book_results, - "user_results": user_results, - "list_results": list_results, - "query": query or "", - } + data["book_results"] = connector_manager.search( + query, min_confidence=min_confidence + ) return TemplateResponse(request, "search_results.html", data) From 6d7b3e9ae76bacd98bb43c35a3cd7338fd0dafb8 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 29 Apr 2021 12:56:42 -0700 Subject: [PATCH 3/7] Show/hide individual search results --- bookwyrm/templates/search_results.html | 37 +++++++++++++++++++------- 1 file changed, 27 insertions(+), 10 deletions(-) diff --git a/bookwyrm/templates/search_results.html b/bookwyrm/templates/search_results.html index 9188c1f0..f911bec7 100644 --- a/bookwyrm/templates/search_results.html +++ b/bookwyrm/templates/search_results.html @@ -42,18 +42,35 @@ {% if result_set.results %}
{% if not result_set.connector.local %} -

- Results from {% if result_set.connector.name %}{{ result_set.connector.name }}{% else %}{{ result_set.connector.identifier }}{% endif %} -

+
+ +
+ {% trans "Show" as button_text %} + {% include 'snippets/toggle/open_button.html' with text=button_text small=True controls_text="more-results-panel" controls_uid=result_set.connector.identifier class="is-small" icon="arrow-down" pressed=forloop.first %} +
+
{% endif %} -
    - {% for result in result_set.results %} -
  • - {% include 'snippets/search_result_text.html' with result=result remote_result=True %} -
  • - {% endfor %} -
+
+
+
+ {% trans "Close" as button_text %} + {% include 'snippets/toggle/toggle_button.html' with label=button_text class="delete" nonbutton=True controls_text="more-results-panel" controls_uid=result_set.connector.identifier pressed=forloop.first %} +
+
    + {% for result in result_set.results %} +
  • + {% include 'snippets/search_result_text.html' with result=result remote_result=True %} +
  • + {% endfor %} +
+
+
{% endif %} {% endfor %} From 15790abc703619858ad019fe4ac288975ff61f8d Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 29 Apr 2021 13:03:56 -0700 Subject: [PATCH 4/7] Don't show broken image previews when cover is absent --- bookwyrm/connectors/bookwyrm_connector.py | 2 +- bookwyrm/connectors/self_connector.py | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/bookwyrm/connectors/bookwyrm_connector.py b/bookwyrm/connectors/bookwyrm_connector.py index 6b1d2f8c..10a633b2 100644 --- a/bookwyrm/connectors/bookwyrm_connector.py +++ b/bookwyrm/connectors/bookwyrm_connector.py @@ -6,7 +6,7 @@ from .abstract_connector import AbstractMinimalConnector, SearchResult class Connector(AbstractMinimalConnector): """this is basically just for search""" - def get_or_create_book(self, remote_id, work=None): + def get_or_create_book(self, remote_id): return activitypub.resolve_remote_id(remote_id, model=models.Edition) def parse_search_data(self, data): diff --git a/bookwyrm/connectors/self_connector.py b/bookwyrm/connectors/self_connector.py index 6b1b349f..a8f85834 100644 --- a/bookwyrm/connectors/self_connector.py +++ b/bookwyrm/connectors/self_connector.py @@ -69,6 +69,10 @@ class Connector(AbstractConnector): return search_results def format_search_result(self, search_result): + cover = None + if search_result.cover: + cover = "%s%s" % (self.covers_url, search_result.cover) + return SearchResult( title=search_result.title, key=search_result.remote_id, @@ -77,7 +81,7 @@ class Connector(AbstractConnector): if search_result.published_date else None, connector=self, - cover="%s%s" % (self.covers_url, search_result.cover), + cover=cover, confidence=search_result.rank if hasattr(search_result, "rank") else 1, ) From f4ebecfe75f598fa94be4d28f5048399e26e5708 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 29 Apr 2021 13:11:37 -0700 Subject: [PATCH 5/7] Add background to search result boxes --- bookwyrm/templates/search_results.html | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/bookwyrm/templates/search_results.html b/bookwyrm/templates/search_results.html index f911bec7..909b0a25 100644 --- a/bookwyrm/templates/search_results.html +++ b/bookwyrm/templates/search_results.html @@ -29,18 +29,23 @@ {% if request.user.is_authenticated %} {% if book_results|slice:":1" and local_results.results %}
-

+

{% trans "Didn't find what you were looking for?" %} -

+

{% trans "Show results from other catalogues" as button_text %} {% include 'snippets/toggle/open_button.html' with text=button_text small=True controls_text="more-results" %} + + {% if local_results.results %} + {% trans "Hide results from other catalogues" as button_text %} + {% include 'snippets/toggle/close_button.html' with text=button_text small=True controls_text="more-results" %} + {% endif %}
{% endif %}
{% for result_set in book_results|slice:"1:" %} {% if result_set.results %} -
+
{% if not result_set.connector.local %}
@@ -56,7 +61,7 @@
{% endif %} -
+
{% trans "Close" as button_text %} @@ -74,11 +79,6 @@
{% endif %} {% endfor %} - - {% if local_results.results %} - {% trans "Hide results from other catalogues" as button_text %} - {% include 'snippets/toggle/close_button.html' with text=button_text small=True controls_text="more-results" %} - {% endif %}
From 6f38ab167e6a8fa53358521352c4929c09c07811 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 29 Apr 2021 13:21:35 -0700 Subject: [PATCH 6/7] Show clarifying text for empty search when logged out --- bookwyrm/templates/search_results.html | 11 ++++++++--- bookwyrm/urls.py | 2 +- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/bookwyrm/templates/search_results.html b/bookwyrm/templates/search_results.html index 909b0a25..337e88f8 100644 --- a/bookwyrm/templates/search_results.html +++ b/bookwyrm/templates/search_results.html @@ -14,7 +14,12 @@

{% trans "Matching Books" %}

{% if not local_results.results %} -

{% blocktrans %}No books found for "{{ query }}"{% endblocktrans %}

+

{% blocktrans %}No books found for "{{ query }}"{% endblocktrans %}

+ {% if not user.is_authenticated %} +

+ {% trans "Log in to import or add books." %} +

+ {% endif %} {% else %}
    {% for result in local_results.results %} @@ -88,7 +93,7 @@
{% if request.user.is_authenticated %} -
+

{% trans "Matching Users" %}

{% if not user_results %}

{% blocktrans %}No users found for "{{ query }}"{% endblocktrans %}

@@ -106,7 +111,7 @@
{% endif %} -
+

{% trans "Lists" %}

{% if not list_results %}

{% blocktrans %}No lists found for "{{ query }}"{% endblocktrans %}

diff --git a/bookwyrm/urls.py b/bookwyrm/urls.py index 53ceeaa8..24c80b04 100644 --- a/bookwyrm/urls.py +++ b/bookwyrm/urls.py @@ -43,7 +43,7 @@ urlpatterns = [ re_path("^api/updates/notifications/?$", views.get_notification_count), re_path("^api/updates/stream/(?P[a-z]+)/?$", views.get_unread_status_count), # authentication - re_path(r"^login/?$", views.Login.as_view()), + re_path(r"^login/?$", views.Login.as_view(), name="login"), re_path(r"^register/?$", views.Register.as_view()), re_path(r"^logout/?$", views.Logout.as_view()), re_path(r"^password-reset/?$", views.PasswordResetRequest.as_view()), From 533cba3ce0c000001911164106362b3621a25989 Mon Sep 17 00:00:00 2001 From: Mouse Reeve Date: Thu, 29 Apr 2021 13:25:44 -0700 Subject: [PATCH 7/7] Updates locales --- locale/de_DE/LC_MESSAGES/django.po | 27 +++++++++++++++++++-------- locale/en_US/LC_MESSAGES/django.po | 25 +++++++++++++++++-------- locale/es/LC_MESSAGES/django.po | 27 +++++++++++++++++++-------- locale/fr_FR/LC_MESSAGES/django.po | 27 +++++++++++++++++++-------- locale/zh_Hans/LC_MESSAGES/django.po | 27 +++++++++++++++++++-------- 5 files changed, 93 insertions(+), 40 deletions(-) diff --git a/locale/de_DE/LC_MESSAGES/django.po b/locale/de_DE/LC_MESSAGES/django.po index bbdd1327..d7ad8724 100644 --- a/locale/de_DE/LC_MESSAGES/django.po +++ b/locale/de_DE/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: 0.0.1\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-04-29 11:36-0700\n" +"POT-Creation-Date: 2021-04-29 13:24-0700\n" "PO-Revision-Date: 2021-03-02 17:19-0800\n" "Last-Translator: Mouse Reeve \n" "Language-Team: English \n" @@ -282,7 +282,7 @@ msgstr "Orte" #: bookwyrm/templates/book/book.html:220 bookwyrm/templates/layout.html:65 #: bookwyrm/templates/lists/lists.html:5 bookwyrm/templates/lists/lists.html:12 -#: bookwyrm/templates/search_results.html:91 +#: bookwyrm/templates/search_results.html:115 #: bookwyrm/templates/user/user_layout.html:62 msgid "Lists" msgstr "Listen" @@ -581,6 +581,7 @@ msgstr "Veröffentlicht von %(publisher)s." #: bookwyrm/templates/feed/feed_layout.html:70 #: bookwyrm/templates/get_started/layout.html:19 #: bookwyrm/templates/get_started/layout.html:52 +#: bookwyrm/templates/search_results.html:72 msgid "Close" msgstr "Schließen" @@ -1129,7 +1130,7 @@ msgid "Search for a user" msgstr "Suche nach Buch oder Benutzer*in" #: bookwyrm/templates/get_started/users.html:13 -#: bookwyrm/templates/search_results.html:76 +#: bookwyrm/templates/search_results.html:99 #, python-format msgid "No users found for \"%(query)s\"" msgstr "Keine Nutzer*innen für \"%(query)s\" gefunden" @@ -1908,23 +1909,33 @@ msgstr "Profil" msgid "Relationships" msgstr "Beziehungen" -#: bookwyrm/templates/search_results.html:33 +#: bookwyrm/templates/search_results.html:20 +msgid "Log in to import or add books." +msgstr "" + +#: bookwyrm/templates/search_results.html:38 msgid "Didn't find what you were looking for?" msgstr "Nicht gefunden, wonach du gesucht hast?" -#: bookwyrm/templates/search_results.html:35 +#: bookwyrm/templates/search_results.html:40 msgid "Show results from other catalogues" msgstr "Ergebnisse aus anderen Katalogen zeigen" -#: bookwyrm/templates/search_results.html:62 +#: bookwyrm/templates/search_results.html:44 msgid "Hide results from other catalogues" msgstr "Ergebnisse aus anderen Katalogen ausblenden" -#: bookwyrm/templates/search_results.html:74 +#: bookwyrm/templates/search_results.html:63 +#, fuzzy +#| msgid "Show more" +msgid "Show" +msgstr "Mehr anzeigen" + +#: bookwyrm/templates/search_results.html:97 msgid "Matching Users" msgstr "Passende Nutzer*innen" -#: bookwyrm/templates/search_results.html:93 +#: bookwyrm/templates/search_results.html:117 #, python-format msgid "No lists found for \"%(query)s\"" msgstr "Keine Liste für \"%(query)s\" gefunden" diff --git a/locale/en_US/LC_MESSAGES/django.po b/locale/en_US/LC_MESSAGES/django.po index 3637bb77..c3df47ae 100644 --- a/locale/en_US/LC_MESSAGES/django.po +++ b/locale/en_US/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: 0.0.1\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-04-29 11:36-0700\n" +"POT-Creation-Date: 2021-04-29 13:24-0700\n" "PO-Revision-Date: 2021-02-28 17:19-0800\n" "Last-Translator: Mouse Reeve \n" "Language-Team: English \n" @@ -261,7 +261,7 @@ msgstr "" #: bookwyrm/templates/book/book.html:220 bookwyrm/templates/layout.html:65 #: bookwyrm/templates/lists/lists.html:5 bookwyrm/templates/lists/lists.html:12 -#: bookwyrm/templates/search_results.html:91 +#: bookwyrm/templates/search_results.html:115 #: bookwyrm/templates/user/user_layout.html:62 msgid "Lists" msgstr "" @@ -535,6 +535,7 @@ msgstr "" #: bookwyrm/templates/feed/feed_layout.html:70 #: bookwyrm/templates/get_started/layout.html:19 #: bookwyrm/templates/get_started/layout.html:52 +#: bookwyrm/templates/search_results.html:72 msgid "Close" msgstr "" @@ -1032,7 +1033,7 @@ msgid "Search for a user" msgstr "" #: bookwyrm/templates/get_started/users.html:13 -#: bookwyrm/templates/search_results.html:76 +#: bookwyrm/templates/search_results.html:99 #, python-format msgid "No users found for \"%(query)s\"" msgstr "" @@ -1739,23 +1740,31 @@ msgstr "" msgid "Relationships" msgstr "" -#: bookwyrm/templates/search_results.html:33 +#: bookwyrm/templates/search_results.html:20 +msgid "Log in to import or add books." +msgstr "" + +#: bookwyrm/templates/search_results.html:38 msgid "Didn't find what you were looking for?" msgstr "" -#: bookwyrm/templates/search_results.html:35 +#: bookwyrm/templates/search_results.html:40 msgid "Show results from other catalogues" msgstr "" -#: bookwyrm/templates/search_results.html:62 +#: bookwyrm/templates/search_results.html:44 msgid "Hide results from other catalogues" msgstr "" -#: bookwyrm/templates/search_results.html:74 +#: bookwyrm/templates/search_results.html:63 +msgid "Show" +msgstr "" + +#: bookwyrm/templates/search_results.html:97 msgid "Matching Users" msgstr "" -#: bookwyrm/templates/search_results.html:93 +#: bookwyrm/templates/search_results.html:117 #, python-format msgid "No lists found for \"%(query)s\"" msgstr "" diff --git a/locale/es/LC_MESSAGES/django.po b/locale/es/LC_MESSAGES/django.po index 8385f7f6..dab4c486 100644 --- a/locale/es/LC_MESSAGES/django.po +++ b/locale/es/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: 0.0.1\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-04-29 11:36-0700\n" +"POT-Creation-Date: 2021-04-29 13:24-0700\n" "PO-Revision-Date: 2021-03-19 11:49+0800\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -266,7 +266,7 @@ msgstr "Lugares" #: bookwyrm/templates/book/book.html:220 bookwyrm/templates/layout.html:65 #: bookwyrm/templates/lists/lists.html:5 bookwyrm/templates/lists/lists.html:12 -#: bookwyrm/templates/search_results.html:91 +#: bookwyrm/templates/search_results.html:115 #: bookwyrm/templates/user/user_layout.html:62 msgid "Lists" msgstr "Listas" @@ -548,6 +548,7 @@ msgstr "Publicado por %(publisher)s." #: bookwyrm/templates/feed/feed_layout.html:70 #: bookwyrm/templates/get_started/layout.html:19 #: bookwyrm/templates/get_started/layout.html:52 +#: bookwyrm/templates/search_results.html:72 msgid "Close" msgstr "Cerrar" @@ -1060,7 +1061,7 @@ msgid "Search for a user" msgstr "Buscar un usuario" #: bookwyrm/templates/get_started/users.html:13 -#: bookwyrm/templates/search_results.html:76 +#: bookwyrm/templates/search_results.html:99 #, python-format msgid "No users found for \"%(query)s\"" msgstr "No se encontró ningún usuario correspondiente a \"%(query)s\"" @@ -1811,23 +1812,33 @@ msgstr "Perfil" msgid "Relationships" msgstr "Relaciones" -#: bookwyrm/templates/search_results.html:33 +#: bookwyrm/templates/search_results.html:20 +msgid "Log in to import or add books." +msgstr "" + +#: bookwyrm/templates/search_results.html:38 msgid "Didn't find what you were looking for?" msgstr "¿No encontraste lo que buscabas?" -#: bookwyrm/templates/search_results.html:35 +#: bookwyrm/templates/search_results.html:40 msgid "Show results from other catalogues" msgstr "Mostrar resultados de otros catálogos" -#: bookwyrm/templates/search_results.html:62 +#: bookwyrm/templates/search_results.html:44 msgid "Hide results from other catalogues" msgstr "Ocultar resultados de otros catálogos" -#: bookwyrm/templates/search_results.html:74 +#: bookwyrm/templates/search_results.html:63 +#, fuzzy +#| msgid "Show more" +msgid "Show" +msgstr "Mostrar más" + +#: bookwyrm/templates/search_results.html:97 msgid "Matching Users" msgstr "Usuarios correspondientes" -#: bookwyrm/templates/search_results.html:93 +#: bookwyrm/templates/search_results.html:117 #, python-format msgid "No lists found for \"%(query)s\"" msgstr "No se encontró ningúna lista correspondiente a \"%(query)s\"" diff --git a/locale/fr_FR/LC_MESSAGES/django.po b/locale/fr_FR/LC_MESSAGES/django.po index ee7a5534..01963e46 100644 --- a/locale/fr_FR/LC_MESSAGES/django.po +++ b/locale/fr_FR/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: 0.1.1\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-04-29 11:36-0700\n" +"POT-Creation-Date: 2021-04-29 13:24-0700\n" "PO-Revision-Date: 2021-04-05 12:44+0100\n" "Last-Translator: Fabien Basmaison \n" "Language-Team: Mouse Reeve \n" @@ -272,7 +272,7 @@ msgstr "Lieux" #: bookwyrm/templates/book/book.html:220 bookwyrm/templates/layout.html:65 #: bookwyrm/templates/lists/lists.html:5 bookwyrm/templates/lists/lists.html:12 -#: bookwyrm/templates/search_results.html:91 +#: bookwyrm/templates/search_results.html:115 #: bookwyrm/templates/user/user_layout.html:62 msgid "Lists" msgstr "Listes" @@ -554,6 +554,7 @@ msgstr "Publié par %(publisher)s." #: bookwyrm/templates/feed/feed_layout.html:70 #: bookwyrm/templates/get_started/layout.html:19 #: bookwyrm/templates/get_started/layout.html:52 +#: bookwyrm/templates/search_results.html:72 msgid "Close" msgstr "Fermer" @@ -1072,7 +1073,7 @@ msgid "Search for a user" msgstr "Chercher un compte" #: bookwyrm/templates/get_started/users.html:13 -#: bookwyrm/templates/search_results.html:76 +#: bookwyrm/templates/search_results.html:99 #, python-format msgid "No users found for \"%(query)s\"" msgstr "Aucun compte trouvé pour « %(query)s »" @@ -1836,23 +1837,33 @@ msgstr "Profil" msgid "Relationships" msgstr "Relations" -#: bookwyrm/templates/search_results.html:33 +#: bookwyrm/templates/search_results.html:20 +msgid "Log in to import or add books." +msgstr "" + +#: bookwyrm/templates/search_results.html:38 msgid "Didn't find what you were looking for?" msgstr "Vous n’avez pas trouvé ce que vous cherchiez ?" -#: bookwyrm/templates/search_results.html:35 +#: bookwyrm/templates/search_results.html:40 msgid "Show results from other catalogues" msgstr "Montrer les résultats d’autres catalogues" -#: bookwyrm/templates/search_results.html:62 +#: bookwyrm/templates/search_results.html:44 msgid "Hide results from other catalogues" msgstr "Masquer les résultats d’autres catalogues" -#: bookwyrm/templates/search_results.html:74 +#: bookwyrm/templates/search_results.html:63 +#, fuzzy +#| msgid "Show more" +msgid "Show" +msgstr "Déplier" + +#: bookwyrm/templates/search_results.html:97 msgid "Matching Users" msgstr "Comptes correspondants" -#: bookwyrm/templates/search_results.html:93 +#: bookwyrm/templates/search_results.html:117 #, python-format msgid "No lists found for \"%(query)s\"" msgstr "Aucune liste trouvée pour « %(query)s »" diff --git a/locale/zh_Hans/LC_MESSAGES/django.po b/locale/zh_Hans/LC_MESSAGES/django.po index af3bc59b..783fc70a 100644 --- a/locale/zh_Hans/LC_MESSAGES/django.po +++ b/locale/zh_Hans/LC_MESSAGES/django.po @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: 0.1.1\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2021-04-29 11:36-0700\n" +"POT-Creation-Date: 2021-04-29 13:24-0700\n" "PO-Revision-Date: 2021-03-20 00:56+0000\n" "Last-Translator: Kana \n" "Language-Team: Mouse Reeve \n" @@ -270,7 +270,7 @@ msgstr "地点" #: bookwyrm/templates/book/book.html:220 bookwyrm/templates/layout.html:65 #: bookwyrm/templates/lists/lists.html:5 bookwyrm/templates/lists/lists.html:12 -#: bookwyrm/templates/search_results.html:91 +#: bookwyrm/templates/search_results.html:115 #: bookwyrm/templates/user/user_layout.html:62 msgid "Lists" msgstr "列表" @@ -552,6 +552,7 @@ msgstr "由 %(publisher)s 出版。" #: bookwyrm/templates/feed/feed_layout.html:70 #: bookwyrm/templates/get_started/layout.html:19 #: bookwyrm/templates/get_started/layout.html:52 +#: bookwyrm/templates/search_results.html:72 msgid "Close" msgstr "关闭" @@ -1052,7 +1053,7 @@ msgid "Search for a user" msgstr "搜索用户" #: bookwyrm/templates/get_started/users.html:13 -#: bookwyrm/templates/search_results.html:76 +#: bookwyrm/templates/search_results.html:99 #, python-format msgid "No users found for \"%(query)s\"" msgstr "没有找到 \"%(query)s\" 的用户" @@ -1801,23 +1802,33 @@ msgstr "个人资料" msgid "Relationships" msgstr "关系" -#: bookwyrm/templates/search_results.html:33 +#: bookwyrm/templates/search_results.html:20 +msgid "Log in to import or add books." +msgstr "" + +#: bookwyrm/templates/search_results.html:38 msgid "Didn't find what you were looking for?" msgstr "没有找到你想找的?" -#: bookwyrm/templates/search_results.html:35 +#: bookwyrm/templates/search_results.html:40 msgid "Show results from other catalogues" msgstr "显示其它类别的结果" -#: bookwyrm/templates/search_results.html:62 +#: bookwyrm/templates/search_results.html:44 msgid "Hide results from other catalogues" msgstr "隐藏其它类别的结果" -#: bookwyrm/templates/search_results.html:74 +#: bookwyrm/templates/search_results.html:63 +#, fuzzy +#| msgid "Show more" +msgid "Show" +msgstr "显示更多" + +#: bookwyrm/templates/search_results.html:97 msgid "Matching Users" msgstr "匹配的用户" -#: bookwyrm/templates/search_results.html:93 +#: bookwyrm/templates/search_results.html:117 #, python-format msgid "No lists found for \"%(query)s\"" msgstr "没有找到 \"%(query)s\" 的列表"