1
0
mirror of https://github.com/phpbb/phpbb.git synced 2025-04-02 15:03:04 +02:00

Merge pull request #4801 from hanakin/ticket/15156

[ticket/15156] Simplify user online notification
This commit is contained in:
Marc Alexander 2017-04-27 17:04:18 -04:00
commit e60306d1e1
No known key found for this signature in database
GPG Key ID: 50E0D2423696F995
9 changed files with 138 additions and 148 deletions

View File

@ -5,7 +5,7 @@
<!-- EVENT memberlist_view_content_prepend -->
<form method="post" action="{S_PROFILE_ACTION}" id="viewprofile">
<div class="panel bg1<!-- IF S_ONLINE --> online<!-- ENDIF -->">
<div class="panel bg1">
<div class="inner">
<!-- IF AVATAR_IMG -->
@ -19,9 +19,11 @@
<!-- ENDIF -->
<dl class="left-box details profile-details">
<dt>{L_USERNAME}{L_COLON}</dt>
<dt>
{L_USERNAME}{L_COLON}
</dt>
<dd>
<!-- IF USER_COLOR --><span style="color: {USER_COLOR}; font-weight: bold;"><!-- ELSE --><span><!-- ENDIF -->{USERNAME}</span>
<!-- IF USER_COLOR --><span style="color: {USER_COLOR}; font-weight: bold;"><!-- ELSE --><span><!-- ENDIF -->{USERNAME}</span> <!-- IF S_ONLINE --> <i class="icon fa-circle fa-fw icon-md online" aria-hidden="true"></i><span class="sr-only">{L_ONLINE}</span><!-- ENDIF -->
<!-- IF U_EDIT_SELF --> [ <a href="{U_EDIT_SELF}">{L_EDIT_PROFILE}</a> ]<!-- ENDIF -->
<!-- IF U_USER_ADMIN --> [ <a href="{U_USER_ADMIN}">{L_USER_ADMIN}</a> ]<!-- ENDIF -->
<!-- IF U_USER_BAN --> [ <a href="{U_USER_BAN}">{L_USER_BAN}</a> ]<!-- ENDIF -->

View File

@ -22,147 +22,147 @@
<!-- ENDIF -->
<div id="post-{MESSAGE_ID}" class="post pm has-profile<!-- IF S_POST_UNAPPROVED or S_POST_REPORTED --> reported<!-- ENDIF --><!-- IF S_ONLINE --> online<!-- ENDIF -->">
<div class="inner">
<div id="post-{MESSAGE_ID}" class="post pm has-profile<!-- IF S_POST_UNAPPROVED or S_POST_REPORTED --> reported<!-- ENDIF -->">
<div class="inner">
<dl class="postprofile" id="profile{MESSAGE_ID}">
<dt class="<!-- IF RANK_TITLE or RANK_IMG -->has-profile-rank<!-- ELSE -->no-profile-rank<!-- ENDIF --> <!-- IF AUTHOR_AVATAR -->has-avatar<!-- ELSE -->no-avatar<!-- ENDIF -->">
<div class="avatar-container">
<!-- EVENT ucp_pm_viewmessage_avatar_before -->
<!-- IF AUTHOR_AVATAR --><a href="{U_MESSAGE_AUTHOR}" class="avatar">{AUTHOR_AVATAR}</a><!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_avatar_after -->
</div>
{MESSAGE_AUTHOR_FULL}
</dt>
<dl class="postprofile" id="profile{MESSAGE_ID}">
<dt class="<!-- IF RANK_TITLE or RANK_IMG -->has-profile-rank<!-- ELSE -->no-profile-rank<!-- ENDIF --> <!-- IF AUTHOR_AVATAR -->has-avatar<!-- ELSE -->no-avatar<!-- ENDIF -->">
<div class="avatar-container">
<!-- EVENT ucp_pm_viewmessage_avatar_before -->
<!-- IF AUTHOR_AVATAR --><a href="{U_MESSAGE_AUTHOR}" class="avatar">{AUTHOR_AVATAR}</a><!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_avatar_after -->
</div>
{MESSAGE_AUTHOR_FULL}<!-- IF S_ONLINE --> <i class="icon fa-circle fa-fw icon-md online" aria-hidden="true"></i><span class="sr-only">{L_ONLINE}</span><!-- ENDIF -->
</dt>
<!-- EVENT ucp_pm_viewmessage_rank_before -->
<!-- IF RANK_TITLE or RANK_IMG --><dd class="profile-rank">{RANK_TITLE}<!-- IF RANK_TITLE and RANK_IMG --><br /><!-- ENDIF -->{RANK_IMG}</dd><!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_rank_after -->
<!-- EVENT ucp_pm_viewmessage_rank_before -->
<!-- IF RANK_TITLE or RANK_IMG --><dd class="profile-rank">{RANK_TITLE}<!-- IF RANK_TITLE and RANK_IMG --><br /><!-- ENDIF -->{RANK_IMG}</dd><!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_rank_after -->
<dd class="profile-posts"><strong>{L_POSTS}{L_COLON}</strong> <!-- IF U_AUTHOR_POSTS != '' --><a href="{U_AUTHOR_POSTS}">{AUTHOR_POSTS}</a><!-- ELSE -->{AUTHOR_POSTS}<!-- ENDIF --></dd>
<!-- IF AUTHOR_JOINED --><dd class="profile-joined"><strong>{L_JOINED}{L_COLON}</strong> {AUTHOR_JOINED}</dd><!-- ENDIF -->
<dd class="profile-posts"><strong>{L_POSTS}{L_COLON}</strong> <!-- IF U_AUTHOR_POSTS != '' --><a href="{U_AUTHOR_POSTS}">{AUTHOR_POSTS}</a><!-- ELSE -->{AUTHOR_POSTS}<!-- ENDIF --></dd>
<!-- IF AUTHOR_JOINED --><dd class="profile-joined"><strong>{L_JOINED}{L_COLON}</strong> {AUTHOR_JOINED}</dd><!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_custom_fields_before -->
<!-- BEGIN custom_fields -->
<!-- IF not custom_fields.S_PROFILE_CONTACT -->
<dd class="profile-custom-field profile-{custom_fields.PROFILE_FIELD_IDENT}"><strong>{custom_fields.PROFILE_FIELD_NAME}{L_COLON}</strong> {custom_fields.PROFILE_FIELD_VALUE}</dd>
<!-- ENDIF -->
<!-- END custom_fields -->
<!-- EVENT ucp_pm_viewmessage_custom_fields_after -->
<!-- EVENT ucp_pm_viewmessage_custom_fields_before -->
<!-- BEGIN custom_fields -->
<!-- IF not custom_fields.S_PROFILE_CONTACT -->
<dd class="profile-custom-field profile-{custom_fields.PROFILE_FIELD_IDENT}"><strong>{custom_fields.PROFILE_FIELD_NAME}{L_COLON}</strong> {custom_fields.PROFILE_FIELD_VALUE}</dd>
<!-- ENDIF -->
<!-- END custom_fields -->
<!-- EVENT ucp_pm_viewmessage_custom_fields_after -->
<!-- EVENT ucp_pm_viewmessage_contact_fields_before -->
<!-- IF .contact -->
<dd class="profile-contact">
<strong>{L_CONTACT}{L_COLON}</strong>
<div class="dropdown-container dropdown-left">
<a href="#" class="dropdown-trigger" title="{CONTACT_USER}"><i class="icon fa-commenting-o fa-fw icon-lg" aria-hidden="true"></i><span class="sr-only">{CONTACT_USER}</span></a>
<div class="dropdown">
<div class="pointer"><div class="pointer-inner"></div></div>
<div class="dropdown-contents contact-icons">
<!-- BEGIN contact -->
{% set REMAINDER = contact.S_ROW_COUNT % 4 %}
<!-- DEFINE $S_LAST_CELL = ((REMAINDER eq 3) or (contact.S_LAST_ROW and contact.S_NUM_ROWS < 4)) -->
<!-- IF REMAINDER eq 0 -->
<div>
<!-- ENDIF -->
<a href="<!-- IF contact.U_CONTACT -->{contact.U_CONTACT}<!-- ELSE -->{contact.U_PROFILE_AUTHOR}<!-- ENDIF -->" title="{contact.NAME}"<!-- IF $S_LAST_CELL --> class="last-cell"<!-- ENDIF --><!-- IF contact.ID eq 'jabber' --> onclick="popup(this.href, 750, 320); return false;"<!-- ENDIF -->>
<span class="contact-icon {contact.ID}-icon">{contact.NAME}</span>
</a>
<!-- IF REMAINDER eq 3 or contact.S_LAST_ROW -->
</div>
<!-- ENDIF -->
<!-- END contact -->
<!-- EVENT ucp_pm_viewmessage_contact_fields_before -->
<!-- IF .contact -->
<dd class="profile-contact">
<strong>{L_CONTACT}{L_COLON}</strong>
<div class="dropdown-container dropdown-left">
<a href="#" class="dropdown-trigger" title="{CONTACT_USER}"><i class="icon fa-commenting-o fa-fw icon-lg" aria-hidden="true"></i><span class="sr-only">{CONTACT_USER}</span></a>
<div class="dropdown">
<div class="pointer"><div class="pointer-inner"></div></div>
<div class="dropdown-contents contact-icons">
<!-- BEGIN contact -->
{% set REMAINDER = contact.S_ROW_COUNT % 4 %}
<!-- DEFINE $S_LAST_CELL = ((REMAINDER eq 3) or (contact.S_LAST_ROW and contact.S_NUM_ROWS < 4)) -->
<!-- IF REMAINDER eq 0 -->
<div>
<!-- ENDIF -->
<a href="<!-- IF contact.U_CONTACT -->{contact.U_CONTACT}<!-- ELSE -->{contact.U_PROFILE_AUTHOR}<!-- ENDIF -->" title="{contact.NAME}"<!-- IF $S_LAST_CELL --> class="last-cell"<!-- ENDIF --><!-- IF contact.ID eq 'jabber' --> onclick="popup(this.href, 750, 320); return false;"<!-- ENDIF -->>
<span class="contact-icon {contact.ID}-icon">{contact.NAME}</span>
</a>
<!-- IF REMAINDER eq 3 or contact.S_LAST_ROW -->
</div>
<!-- ENDIF -->
<!-- END contact -->
</div>
</div>
</div>
</div>
</dd>
<!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_contact_fields_after -->
</dl>
<div class="postbody">
<h3 class="first">{SUBJECT}</h3>
<!-- DEFINE $SHOW_PM_POST_BUTTONS = (U_EDIT or U_DELETE or U_REPORT or U_QUOTE) -->
<!-- EVENT ucp_pm_viewmessage_post_buttons_list_before -->
<!-- IF $SHOW_PM_POST_BUTTONS -->
<ul class="post-buttons">
<!-- EVENT ucp_pm_viewmessage_post_buttons_before -->
<!-- IF U_EDIT -->
<li>
<a href="{U_EDIT}" title="{L_POST_EDIT_PM}" class="button button-icon-only">
<i class="icon fa-pencil fa-fw" aria-hidden="true"></i><span class="sr-only">{L_POST_EDIT_PM}</span>
</a>
</li>
</dd>
<!-- ENDIF -->
<!-- IF U_DELETE -->
<li>
<a href="{U_DELETE}" title="{L_DELETE_MESSAGE}" class="button button-icon-only">
<i class="icon fa-times fa-fw" aria-hidden="true"></i><span class="sr-only">{L_DELETE_MESSAGE}</span>
</a>
</li>
<!-- EVENT ucp_pm_viewmessage_contact_fields_after -->
</dl>
<div class="postbody">
<h3 class="first">{SUBJECT}</h3>
<!-- DEFINE $SHOW_PM_POST_BUTTONS = (U_EDIT or U_DELETE or U_REPORT or U_QUOTE) -->
<!-- EVENT ucp_pm_viewmessage_post_buttons_list_before -->
<!-- IF $SHOW_PM_POST_BUTTONS -->
<ul class="post-buttons">
<!-- EVENT ucp_pm_viewmessage_post_buttons_before -->
<!-- IF U_EDIT -->
<li>
<a href="{U_EDIT}" title="{L_POST_EDIT_PM}" class="button button-icon-only">
<i class="icon fa-pencil fa-fw" aria-hidden="true"></i><span class="sr-only">{L_POST_EDIT_PM}</span>
</a>
</li>
<!-- ENDIF -->
<!-- IF U_DELETE -->
<li>
<a href="{U_DELETE}" title="{L_DELETE_MESSAGE}" class="button button-icon-only">
<i class="icon fa-times fa-fw" aria-hidden="true"></i><span class="sr-only">{L_DELETE_MESSAGE}</span>
</a>
</li>
<!-- ENDIF -->
<!-- IF U_REPORT -->
<li>
<a href="{U_REPORT}" title="{L_REPORT_PM}" class="button button-icon-only">
<i class="icon fa-exclamation fa-fw" aria-hidden="true"></i><span class="sr-only">{L_REPORT_PM}</span>
</a>
</li>
<!-- ENDIF -->
<!-- IF U_QUOTE -->
<li>
<a href="{U_QUOTE}" title="{L_POST_QUOTE_PM}" class="button button-icon-only">
<i class="icon fa-quote-left fa-fw" aria-hidden="true"></i><span class="sr-only">{L_POST_QUOTE_PM}</span>
</a>
</li>
<!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_post_buttons_after -->
</ul>
<!-- ENDIF -->
<!-- IF U_REPORT -->
<li>
<a href="{U_REPORT}" title="{L_REPORT_PM}" class="button button-icon-only">
<i class="icon fa-exclamation fa-fw" aria-hidden="true"></i><span class="sr-only">{L_REPORT_PM}</span>
</a>
</li>
<!-- EVENT ucp_pm_viewmessage_post_buttons_list_after -->
<p class="author">
<strong>{L_SENT_AT}{L_COLON}</strong> {SENT_DATE}
<br /><strong>{L_PM_FROM}{L_COLON}</strong> {MESSAGE_AUTHOR_FULL}
<!-- IF S_TO_RECIPIENT --><br /><strong>{L_TO}{L_COLON}</strong> <!-- BEGIN to_recipient --><!-- IF to_recipient.NAME_FULL -->{to_recipient.NAME_FULL}<!-- ELSE --><a href="{to_recipient.U_VIEW}" style="color:<!-- IF to_recipient.COLOUR -->{to_recipient.COLOUR}<!-- ELSEIF to_recipient.IS_GROUP -->#0000FF<!-- ENDIF -->;">{to_recipient.NAME}</a><!-- ENDIF -->&nbsp;<!-- END to_recipient --><!-- ENDIF -->
<!-- IF S_BCC_RECIPIENT --><br /><strong>{L_BCC}{L_COLON}</strong> <!-- BEGIN bcc_recipient --><!-- IF bcc_recipient.NAME_FULL -->{bcc_recipient.NAME_FULL}<!-- ELSE --><a href="{bcc_recipient.U_VIEW}" style="color:<!-- IF bcc_recipient.COLOUR -->{bcc_recipient.COLOUR}<!-- ELSEIF bcc_recipient.IS_GROUP -->#0000FF<!-- ENDIF -->;">{bcc_recipient.NAME}</a><!-- ENDIF -->&nbsp;<!-- END bcc_recipient --><!-- ENDIF -->
</p>
<div class="content">{MESSAGE}</div>
<!-- IF S_HAS_ATTACHMENTS -->
<dl class="attachbox">
<dt>
{L_ATTACHMENTS}
</dt>
<!-- BEGIN attachment -->
<dd>{attachment.DISPLAY_ATTACHMENT}</dd>
<!-- END attachment -->
</dl>
<!-- ENDIF -->
<!-- IF U_QUOTE -->
<li>
<a href="{U_QUOTE}" title="{L_POST_QUOTE_PM}" class="button button-icon-only">
<i class="icon fa-quote-left fa-fw" aria-hidden="true"></i><span class="sr-only">{L_POST_QUOTE_PM}</span>
</a>
</li>
<!-- IF S_DISPLAY_NOTICE -->
<div class="post-notice error">{L_DOWNLOAD_NOTICE}</div>
<!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_post_buttons_after -->
</ul>
<!-- ENDIF -->
<!-- EVENT ucp_pm_viewmessage_post_buttons_list_after -->
<p class="author">
<strong>{L_SENT_AT}{L_COLON}</strong> {SENT_DATE}
<br /><strong>{L_PM_FROM}{L_COLON}</strong> {MESSAGE_AUTHOR_FULL}
<!-- IF S_TO_RECIPIENT --><br /><strong>{L_TO}{L_COLON}</strong> <!-- BEGIN to_recipient --><!-- IF to_recipient.NAME_FULL -->{to_recipient.NAME_FULL}<!-- ELSE --><a href="{to_recipient.U_VIEW}" style="color:<!-- IF to_recipient.COLOUR -->{to_recipient.COLOUR}<!-- ELSEIF to_recipient.IS_GROUP -->#0000FF<!-- ENDIF -->;">{to_recipient.NAME}</a><!-- ENDIF -->&nbsp;<!-- END to_recipient --><!-- ENDIF -->
<!-- IF S_BCC_RECIPIENT --><br /><strong>{L_BCC}{L_COLON}</strong> <!-- BEGIN bcc_recipient --><!-- IF bcc_recipient.NAME_FULL -->{bcc_recipient.NAME_FULL}<!-- ELSE --><a href="{bcc_recipient.U_VIEW}" style="color:<!-- IF bcc_recipient.COLOUR -->{bcc_recipient.COLOUR}<!-- ELSEIF bcc_recipient.IS_GROUP -->#0000FF<!-- ENDIF -->;">{bcc_recipient.NAME}</a><!-- ENDIF -->&nbsp;<!-- END bcc_recipient --><!-- ENDIF -->
</p>
<!-- IF EDITED_MESSAGE or EDIT_REASON -->
<div class="notice">{EDITED_MESSAGE}
<!-- IF EDIT_REASON --><br /><strong>{L_REASON}{L_COLON}</strong> <em>{EDIT_REASON}</em><!-- ENDIF -->
</div>
<!-- ENDIF -->
<div class="content">{MESSAGE}</div>
<!-- IF S_HAS_ATTACHMENTS -->
<dl class="attachbox">
<dt>
{L_ATTACHMENTS}
</dt>
<!-- BEGIN attachment -->
<dd>{attachment.DISPLAY_ATTACHMENT}</dd>
<!-- END attachment -->
</dl>
<!-- ENDIF -->
<!-- IF S_DISPLAY_NOTICE -->
<div class="post-notice error">{L_DOWNLOAD_NOTICE}</div>
<!-- ENDIF -->
<!-- IF EDITED_MESSAGE or EDIT_REASON -->
<div class="notice">{EDITED_MESSAGE}
<!-- IF EDIT_REASON --><br /><strong>{L_REASON}{L_COLON}</strong> <em>{EDIT_REASON}</em><!-- ENDIF -->
<!-- IF SIGNATURE -->
<div id="sig{MESSAGE_ID}" class="signature">{SIGNATURE}</div>
<!-- ENDIF -->
</div>
<!-- ENDIF -->
<!-- IF SIGNATURE -->
<div id="sig{MESSAGE_ID}" class="signature">{SIGNATURE}</div>
<!-- ENDIF -->
</div>
<div class="back2top">
<a href="#top" class="top" title="{L_BACK_TO_TOP}">
<i class="icon fa-chevron-circle-up fa-fw icon-gray" aria-hidden="true"></i>
<span class="sr-only">{L_BACK_TO_TOP}</span>
</a>
</div>
<div class="back2top">
<a href="#top" class="top" title="{L_BACK_TO_TOP}">
<i class="icon fa-chevron-circle-up fa-fw icon-gray" aria-hidden="true"></i>
<span class="sr-only">{L_BACK_TO_TOP}</span>
</a>
</div>
</div>
</div>

View File

@ -135,7 +135,7 @@
<!-- IF postrow.S_FIRST_UNREAD -->
<a id="unread" class="anchor"<!-- IF S_UNREAD_VIEW --> data-url="{postrow.U_MINI_POST}"<!-- ENDIF -->></a>
<!-- ENDIF -->
<div id="p{postrow.POST_ID}" class="post has-profile <!-- IF postrow.S_ROW_COUNT is odd -->bg1<!-- ELSE -->bg2<!-- ENDIF --><!-- IF postrow.S_UNREAD_POST --> unreadpost<!-- ENDIF --><!-- IF postrow.S_POST_REPORTED --> reported<!-- ENDIF --><!-- IF postrow.S_POST_DELETED --> deleted<!-- ENDIF --><!-- IF postrow.S_ONLINE and not postrow.S_POST_HIDDEN --> online<!-- ENDIF --><!-- IF postrow.POSTER_WARNINGS --> warned<!-- ENDIF -->">
<div id="p{postrow.POST_ID}" class="post has-profile <!-- IF postrow.S_ROW_COUNT is odd -->bg1<!-- ELSE -->bg2<!-- ENDIF --><!-- IF postrow.S_UNREAD_POST --> unreadpost<!-- ENDIF --><!-- IF postrow.S_POST_REPORTED --> reported<!-- ENDIF --><!-- IF postrow.S_POST_DELETED --> deleted<!-- ENDIF --><!-- IF postrow.POSTER_WARNINGS --> warned<!-- ENDIF -->">
<div class="inner">
<dl class="postprofile" id="profile{postrow.POST_ID}"<!-- IF postrow.S_POST_HIDDEN --> style="display: none;"<!-- ENDIF -->>
@ -148,7 +148,7 @@
<!-- EVENT viewtopic_body_avatar_after -->
</div>
<!-- EVENT viewtopic_body_post_author_before -->
<!-- IF not postrow.U_POST_AUTHOR --><strong>{postrow.POST_AUTHOR_FULL}</strong><!-- ELSE -->{postrow.POST_AUTHOR_FULL}<!-- ENDIF -->
<!-- IF not postrow.U_POST_AUTHOR --><strong>{postrow.POST_AUTHOR_FULL}</strong><!-- ELSE -->{postrow.POST_AUTHOR_FULL}<!-- ENDIF --><!-- IF postrow.S_ONLINE and not postrow.S_POST_HIDDEN --> <i class="icon fa-circle fa-fw icon-md online" aria-hidden="true"></i><span class="sr-only">{L_ONLINE}</span><!-- ENDIF -->
<!-- EVENT viewtopic_body_post_author_after -->
</dt>

View File

@ -633,10 +633,6 @@ li.breadcrumbs span:first-child > a {
float: right;
}
.rtl .online {
background-position: 0 0;
}
.rtl dl.pmlist dd {
margin-right: 61% !important;
margin-left: 0 !important;

View File

@ -214,6 +214,10 @@ a:hover .icon.icon-blue {
color: #196db5;
}
.icon.online {
color: #85de39;
}
.icon.icon-green,
a:hover .icon.icon-green {
color: #1b9a1b;
@ -727,7 +731,6 @@ dd.profile-warnings {
.contact-icon { background-image: url("./images/icons_contact.png"); }
/* profile icons */
.online { background-image: url("./en/icon_user_online.gif"); }
.pm-icon { background-position: 0 0; }
.email-icon { background-position: -21px 0; }
.jabber-icon { background-position: -80px 0; }

View File

@ -793,12 +793,6 @@ dd.profile-contact {
margin-right: -14px;
}
.online {
background-image: none;
background-repeat: no-repeat;
background-position: 100% 0;
}
/* Poster profile used by search */
.search .postprofile {
width: 30%;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 423 B

View File

@ -1,2 +1 @@
/* Online image */
.online { background-image: url("./icon_user_online.gif"); }
/* language specific styles go here */

View File

@ -557,10 +557,6 @@
right: 30px;
}
.online {
background-size: 40px;
}
/* Misc stuff
---------------------------------------------------------------- */
h2 {