Merge branch 'next-lantia' of github.com:WoltLab/WCF into next-lantia
[GitHub/WoltLab/WCF.git] / com.woltlab.wcf / templates / messageSidebar.tpl
1 {if !$__messageSidebarJavascript|isset}
2 {assign var=__messageSidebarJavascript value=true}
3 {/if}
4
5 <aside class="messageSidebar{if MESSAGE_SIDEBAR_ENABLE_ONLINE_STATUS && $userProfile->isOnline()} userOnline{/if} {if $userProfile->userID}member{else}guest{/if}"{if $userProfile->userID} itemscope itemtype="http://data-vocabulary.org/Person"{/if}>
6 <div class="messageAuthor">
7 {if $userProfile->userID}
8 {assign var='username' value=$userProfile->username}
9
10 {if MESSAGE_SIDEBAR_ENABLE_AVATAR}
11 {if $userProfile->getAvatar()}
12 <div class="userAvatar">
13 {capture assign='__userAvatar'}{@$userProfile->getAvatar()->getImageTag(128)}{/capture}
14 <a href="{link controller='User' object=$userProfile->getDecoratedObject()}{/link}" class="framed">{@'<img'|str_replace:'<img itemprop="photo"':$__userAvatar}</a>
15
16 {if MESSAGE_SIDEBAR_ENABLE_ONLINE_STATUS && $userProfile->isOnline()}<span class="badge green badgeOnline" title="{lang}wcf.user.online.title{/lang}">{lang}wcf.user.online{/lang}</span>{/if}
17 </div>
18 {/if}
19 {/if}
20
21 <p class="messageAuthorContainer">
22 <a href="{link controller='User' object=$userProfile->getDecoratedObject()}{/link}" class="username userLink" data-user-id="{@$userProfile->userID}" rel="author">
23 <span itemprop="name">{if MESSAGE_SIDEBAR_ENABLE_USER_ONLINE_MARKING}{@$userProfile->getFormattedUsername()}{else}{$username}{/if}</span>
24 </a>
25 {if $userProfile->banned}<span class="icon icon16 fa-lock jsTooltip jsUserBanned" title="{lang user=$userProfile}wcf.user.banned{/lang}"></span>{/if}
26
27 {event name='header'}
28 </p>
29
30 {if MODULE_USER_RANK && MESSAGE_SIDEBAR_ENABLE_RANK}
31 {if $userProfile->getUserTitle()}
32 <div class="userTitle">
33 <p class="badge userTitleBadge{if $userProfile->getRank() && $userProfile->getRank()->cssClassName} {@$userProfile->getRank()->cssClassName}{/if}" itemprop="title">{$userProfile->getUserTitle()}</p>
34 </div>
35 {/if}
36 {if $userProfile->getRank() && $userProfile->getRank()->rankImage}
37 <div class="userRank">{@$userProfile->getRank()->getImage()}</div>
38 {/if}
39 {/if}
40 {else}
41 <p class="messageAuthor">
42 <span class="username">{$userProfile->username}</span>
43
44 <div class="userTitle">
45 <p class="badge">{lang}wcf.user.guest{/lang}</p>
46 </div>
47
48 {event name='header'}
49 </p>
50 {/if}
51 </div>
52
53 {event name='beforeCredits'}
54
55 {if $userProfile->userID}
56 {hascontent}
57 <div class="userCredits">
58 <dl class="plain dataList">
59 {content}
60 {if MODULE_LIKE && MESSAGE_SIDEBAR_ENABLE_LIKES_RECEIVED && $userProfile->likesReceived}
61 <dt><a href="{link controller='User' object=$userProfile}{/link}#likes" class="jsTooltip" title="{lang user=$userProfile}wcf.like.showLikesReceived{/lang}">{lang}wcf.like.likesReceived{/lang}</a></dt>
62 <dd>{#$userProfile->likesReceived}</dd>
63 {/if}
64
65 {if MESSAGE_SIDEBAR_ENABLE_ACTIVITY_POINTS && $userProfile->activityPoints}
66 <dt><a href="#" class="activityPointsDisplay jsTooltip" title="{lang user=$userProfile}wcf.user.activityPoint.showActivityPoints{/lang}" data-user-id="{@$userProfile->userID}">{lang}wcf.user.activityPoint{/lang}</a></dt>
67 <dd>{#$userProfile->activityPoints}</dd>
68 {/if}
69 {event name='userCredits'}
70 {if MESSAGE_SIDEBAR_USER_OPTIONS && $userProfile->isAccessible('canViewProfile')}
71 {assign var='__sidebarUserOptions' value=','|explode:MESSAGE_SIDEBAR_USER_OPTIONS}
72 {foreach from=$__sidebarUserOptions item='__sidebarUserOption'}
73 {if $userProfile->getUserOption($__sidebarUserOption)}
74 {assign var='__formattedUserOption' value=$userProfile->getFormattedUserOption($__sidebarUserOption)}
75 {if $__formattedUserOption}
76 <dt>{lang}wcf.user.option.{$__sidebarUserOption}{/lang}</dt>
77 <dd{if $__sidebarUserOption == 'location'} itemprop="locality"{/if}>{@$__formattedUserOption}</dd>
78 {/if}
79 {/if}
80 {/foreach}
81 {/if}
82 {/content}
83 </dl>
84 </div>
85 {/hascontent}
86 {/if}
87
88 {event name='afterCredits'}
89 </aside>