Display user title on the forum.

This commit is contained in:
flash 2019-01-18 21:24:35 +01:00
parent f57afbc9c7
commit 2f89996679
3 changed files with 14 additions and 12 deletions

View file

@ -75,7 +75,6 @@
&__content {
width: 150px;
word-break: break-all;
text-align: center;
display: flex;
flex-direction: column;
@ -84,11 +83,6 @@
flex: 0 0 auto;
margin-right: 4px;
&--tolerate-wide {
width: auto;
min-width: 150px;
}
@media (max-width: @site-mobile-width) {
width: 100%;
flex-direction: row;
@ -138,12 +132,9 @@
&__joined {
flex: 1 1 auto;
margin: 2px;
max-width: 170px;
font-size: .9em;
justify-self: flex-end;
margin-top: 10px;
margin-bottom: -10px;
@media (max-width: @site-mobile-width) {
display: none;
@ -164,9 +155,8 @@
&__username {
color: inherit;
font-size: 1.4em;
line-height: 1.5em;
line-height: 2em;
text-decoration: none;
margin: 2px 0 1px;
&[href]:hover {
text-decoration: underline;
@ -179,6 +169,16 @@
}
}
&__usertitle {
font-size: .9em;
line-height: 1.5em;
margin-bottom: 4px;
@media (max-width: @site-mobile-width) {
display: none;
}
}
&__options {
margin: 2px;
display: flex;

View file

@ -133,6 +133,7 @@ function forum_post_listing(int $topicId, int $offset = 0, int $take = 0, bool $
u.`user_created` AS `poster_joined`,
u.`user_country` AS `poster_country`,
COALESCE(u.`user_colour`, r.`role_colour`) AS `poster_colour`,
COALESCE(u.`user_title`, r.`role_title`) AS `poster_title`,
(
SELECT COUNT(`post_id`)
FROM `msz_forum_posts`

View file

@ -385,7 +385,7 @@
<div class="container forum__post{% if is_deleted %} forum__post--deleted{% endif %}" id="p{{ post.post_id }}" style="{{ post.poster_colour|html_colour('--accent-colour') }}">
<div class="forum__post__info">
<div class="forum__post__info__background"></div>
<div class="forum__post__info__content{% if null|date('Ym') < 201902 %} forum__post__info__content--tolerate-wide{% endif %}">
<div class="forum__post__info__content">
{% if post.poster_id is not null %}
<a class="avatar forum__post__avatar"
style="background-image:url('/profile.php?u={{ post.poster_id }}&amp;m=avatar');"
@ -393,6 +393,7 @@
</a>
<a class="forum__post__username" href="/profile.php?u={{ post.poster_id }}">{{ post.poster_name }}</a>
<a class="forum__post__usertitle">{{ post.poster_title }}</a>
<div class="forum__post__icons">
<div class="flag flag--{{ post.poster_country|lower }}" title="{{ post.poster_country|country_name }}"></div>