Merge pull request #149 from WoltLab/simplify-notification-phrases
authorAlexander Ebert <ebert@woltlab.com>
Sun, 14 Feb 2021 16:05:43 +0000 (17:05 +0100)
committerGitHub <noreply@github.com>
Sun, 14 Feb 2021 16:05:43 +0000 (17:05 +0100)
Simplify phrases for notifications

templates/conversation.tpl
templates/conversationList.tpl
templates/conversationListUserPanel.tpl
templates/conversationMessageListLog.tpl
templates/conversationMessagePreview.tpl
templates/moderationConversationMessage.tpl

index 9cd78083c67f1d9caca5ae36f3bbf0a7bd885101..2c6956dabec9f0122420e0ad090e54c85880d278 100644 (file)
                                
                                <li>
                                        <span class="icon icon16 fa-user"></span>
-                                       {if $conversation->userID}
-                                               {user object=$conversation->getUserProfile()}
-                                       {else}
-                                               {$conversation->username}
-                                       {/if}
+                                       {user object=$conversation->getUserProfile()}
                                </li>
                                
                                <li>
                        {foreach from=$participants item=participant}
                                <li class="jsParticipant{if !$participant->userID || $participant->hideConversation == 2 || $participant->leftAt > 0} conversationLeft{/if}">
                                        <div class="box24">
-                                               {if $participant->userID}
-                                                       {user object=$participant type='avatar24'}
-                                               {else}
-                                                       <span>{@$participant->getAvatar()->getImageTag(24)}</span>
-                                               {/if}
+                                               {user object=$participant type='avatar24' ariaHidden='true' tabindex='-1'}
                                                <div>
                                                        <p>
-                                                               {if $participant->userID}
-                                                                       {user object=$participant}
-                                                               {else}
-                                                                       <span>{$participant->username}</span>
-                                                               {/if}
+                                                               {user object=$participant}
                                                                {if $participant->isInvisible}<small>({lang}wcf.conversation.invisible{/lang})</small>{/if}
                                                                {if $participant->userID && ($conversation->userID == $__wcf->getUser()->userID) && ($participant->userID != $__wcf->getUser()->userID) && $participant->hideConversation != 2 && $participant->leftAt == 0}
                                                                        <a href="#" class="jsDeleteButton jsTooltip jsOnly" title="{lang}wcf.conversation.participants.removeParticipant{/lang}" data-confirm-message-html="{lang __encode=true}wcf.conversation.participants.removeParticipant.confirmMessage{/lang}" data-object-id="{@$participant->userID}"><span class="icon icon16 fa-times"></span></a>
index 2dd61e69fdb02b316f737715f3659b1356ce4034..73c29f87c32977b196661dc73025a7ff75391ed5 100644 (file)
                                                        </aside>
                                                        
                                                        <ul class="inlineList dotSeparated small messageGroupInfo">
-                                                               <li class="messageGroupAuthor">{if $conversation->userID}{user object=$conversation->getUserProfile()}{else}{$conversation->username}{/if}</li>
+                                                               <li class="messageGroupAuthor">{user object=$conversation->getUserProfile()}</li>
                                                                <li class="messageGroupTime">{@$conversation->time|time}</li>
                                                                <li class="messageGroupEditLink jsOnly"><a href="#" class="jsConversationInlineEditor">{lang}wcf.global.button.edit{/lang}</a></li>
                                                                {event name='messageGroupInfo'}
                                                                        
                                                                        <div>
                                                                                <p>
-                                                                                       {if $conversation->lastPosterID}
-                                                                                               {user object=$conversation->getLastPosterProfile()}
-                                                                                       {else}
-                                                                                               {$conversation->lastPoster}
-                                                                                       {/if}
+                                                                                       {user object=$conversation->getLastPosterProfile()}
                                                                                </p>
                                                                                <small>{@$conversation->lastPostTime|time}</small>
                                                                        </div>
index 6e154facc3eb85556ad3c48d0adfa57d0d7057ca..c5badc78e8c59fdc73ed5333a47e6e60e0cd7a79 100644 (file)
                                                                {implode from=$conversation->getParticipantSummary() item=participant}<a href="{$participant->getLink()}" class="userLink{if $participant->hideConversation == 2} conversationLeft{/if}" data-object-id="{@$participant->userID}">{$participant->username}</a>{/implode}
                                                                {if $participantSummaryCount < $conversation->participants}{lang}wcf.conversation.participants.other{/lang}{/if}
                                                        {else}
-                                                               {if $conversation->getOtherParticipantProfile()->userID}
-                                                                       {user object=$conversation->getOtherParticipantProfile()}
-                                                               {else}
-                                                                       {$conversation->getOtherParticipantProfile()->username}
-                                                               {/if}
+                                                               {user object=$conversation->getOtherParticipantProfile()}
                                                        {/if}
                                                {else}
-                                                       {if $conversation->userID}
-                                                               {user object=$conversation->getUserProfile()}
-                                                       {else}
-                                                               {$conversation->username}
-                                                       {/if}
+                                                       {user object=$conversation->getUserProfile()}
                                                {/if}
                                        </span>
                                        
index 80d066b1ec3439a2325193f474101bd96bb054d0..a74d1dec0886c0ae6aff10c7a35c2e77497b09f1 100644 (file)
@@ -6,7 +6,7 @@
                                <div class="messageContent">
                                        <div class="messageHeader">
                                                <div class="box32 messageHeaderWrapper">
-                                                       {user object=$modificationLogEntry->getUserProfile() type='avatar32' ariaHidden='true'}
+                                                       {user object=$modificationLogEntry->getUserProfile() type='avatar32' ariaHidden='true' tabindex='-1'}
                                                        
                                                        <div class="messageHeaderBox">
                                                                <h2 class="messageTitle">
index 2a86033a7e2fa83e31a81bad85fc766a8b3315bf..8385544226a372d2782282d7267408df2ab1c3b4 100644 (file)
@@ -1,6 +1,6 @@
 <div class="box48">
        {if $message->getUserProfile()->getAvatar()}
-               {user object=$message->getUserProfile() type='avatar48' ariaHidden='true'}
+               {user object=$message->getUserProfile() type='avatar48' ariaHidden='true' tabindex='-1'}
        {/if}
        
        <div>
index faec6f14b08b61ab3eaed53840bf94146af1e5a2..eb91b2d40666f526fd325f000825592b7abe9a1d 100644 (file)
@@ -2,23 +2,13 @@
        <div class="messageContent">
                <header class="messageHeader">
                        <div class="box32 messageHeaderWrapper">
-                               {if $message->userID}
-                                       {user object=$message->getUserProfile() type='avatar32' ariaHidden='true'}
-                               {else}
-                                       <span>{@$message->getUserProfile()->getAvatar()->getImageTag(32)}</span>
-                               {/if}
+                               {user object=$message->getUserProfile() type='avatar32' ariaHidden='true' tabindex='-1'}
                                
                                <div class="messageHeaderBox">
                                        <h2 class="messageTitle">{if $message->getConversation()->canRead()}<a href="{@$message->getLink()}">{$message->getTitle()}</a>{else}{$message->getTitle()}{/if}</h2>
                                        
                                        <ul class="messageHeaderMetaData">
-                                               <li>
-                                                       {if $message->userID}
-                                                               {user object=$message->getUserProfile() class='username'}
-                                                       {else}
-                                                               <span class="username">{$message->getUsername()}</span>
-                                                       {/if}
-                                               </li>
+                                               <li>{user object=$message->getUserProfile() class='username'}</li>
                                                <li><span class="messagePublicationTime">{@$message->getTime()|time}</span></li>
                                                
                                                {event name='messageHeaderMetaData'}