Add "open post" button to comments
Since I started working on the i18n support, comments lost it's previous link to the post, so it's been added back in a form of an actual button
This commit is contained in:
@ -34,6 +34,7 @@ footer_source = "Website source"
|
||||
go_to_top = "Go to Top"
|
||||
load_comments = "Load Comments"
|
||||
newest_to_oldest = "From newest to oldest"
|
||||
open_post = "Open Post"
|
||||
page_next = "Next"
|
||||
page_previous = "Previous"
|
||||
posts_in_total = "posts in total"
|
||||
@ -76,6 +77,7 @@ footer_source = "Исходный код веб-сайта"
|
||||
go_to_top = "Перейти в Начало"
|
||||
load_comments = "Загрузить Комментарии"
|
||||
newest_to_oldest = "От новейшего к старейшему"
|
||||
open_post = "Открыть Пост"
|
||||
page_next = "Следующий"
|
||||
page_previous = "Предыдущий"
|
||||
posts_in_total = "всего постов"
|
||||
|
@ -25,6 +25,12 @@ section#comments {
|
||||
margin-top: 2rem;
|
||||
}
|
||||
|
||||
.dialog-buttons {
|
||||
justify-content: start;
|
||||
gap: 0.25rem;
|
||||
margin-top: 2rem;
|
||||
}
|
||||
|
||||
.comment {
|
||||
display: grid;
|
||||
grid-template-columns: min-content;
|
||||
@ -140,14 +146,14 @@ section#comments {
|
||||
}
|
||||
|
||||
footer {
|
||||
display: flex;
|
||||
grid-area: interactions;
|
||||
gap: 0.25rem;
|
||||
margin-top: 1rem;
|
||||
|
||||
.boosts,
|
||||
.faves {
|
||||
display: inline-block;
|
||||
transition: var(--transition);
|
||||
margin-right: 0.25rem;
|
||||
border-radius: 999px;
|
||||
background-color: transparent;
|
||||
padding: 0.25rem 0.75rem;
|
||||
|
@ -13,21 +13,23 @@
|
||||
{% endif %}
|
||||
|
||||
{% set id = page.extra.comments.id %}
|
||||
{% set post_url = "https://{{ host }}/@{{ username }}/{{ id }}" %}
|
||||
|
||||
<section id="comments">
|
||||
{% if config.extra.comments.show_qr %}
|
||||
<img id="qrcode" class="no-hover pixels" alt="QR code to a Mastodon post" src="https://api.qrserver.com/v1/create-qr-code/?data={{ post_url }}&format=gif" />
|
||||
<img id="qrcode" class="no-hover pixels" alt="QR code to a Mastodon post" src="https://api.qrserver.com/v1/create-qr-code/?data=https://{{ host }}/@{{ username }}/{{ id }}&format=gif" />
|
||||
{% endif %}
|
||||
|
||||
<h2>{{ trans(key="comments", lang=lang) }}</h2>
|
||||
<p>{{ trans(key="comments_description", lang=lang) }}</p>
|
||||
|
||||
<p>
|
||||
<div class="dialog-buttons">
|
||||
<a id="load-comments" class="inline-button" onclick="loadComments()" onkeypress="loadComments()" tabindex="0">
|
||||
{{ trans(key="load_comments", lang=lang) }}
|
||||
</a>
|
||||
</p>
|
||||
<a class="inline-button colored external" href="https://{{ host }}/@{{ username }}/{{ id }}">
|
||||
{{ trans(key="open_post", lang=lang) }}
|
||||
</a>
|
||||
</div>
|
||||
|
||||
<div id="comments-wrapper">
|
||||
<noscript>
|
||||
|
Reference in New Issue
Block a user