Commit 76c6c15e authored by Robert Lyon's avatar Robert Lyon Committed by Gerrit Code Review
Browse files

Merge "Bug 1594298 - Fixed sidebar notification links showing under profile icon"

parents 1102ea40 8ba1204f
...@@ -3435,7 +3435,7 @@ function profile_sideblock() { ...@@ -3435,7 +3435,7 @@ function profile_sideblock() {
if ($authobj->authname == 'xmlrpc') { if ($authobj->authname == 'xmlrpc') {
$peer = get_peer($authobj->wwwroot); $peer = get_peer($authobj->wwwroot);
if ($SESSION->get('mnetuser')) { if ($SESSION->get('mnetuser')) {
$data['mnetloggedinfrom'] = '<span class="icon icon-external-link moodle-login"></span>' . get_string('youhaveloggedinfrom1', 'auth.xmlrpc', $authobj->wwwroot, $peer->name); $data['mnetloggedinfrom'] = '<span class="icon left icon-external-link moodle-login"></span>' . get_string('youhaveloggedinfrom1', 'auth.xmlrpc', $authobj->wwwroot, $peer->name);
} }
else { else {
$data['peer'] = array('name' => $peer->name, 'wwwroot' => $peer->wwwroot); $data['peer'] = array('name' => $peer->name, 'wwwroot' => $peer->wwwroot);
......
...@@ -341,10 +341,6 @@ ...@@ -341,10 +341,6 @@
} }
} }
.moodle-login.icon {
margin: 10px;
}
.containobjectionable { .containobjectionable {
background-color: #FEE7E7; background-color: #FEE7E7;
} }
......
// // modiufications for list elements such a list of pages, collections // // modifications for list elements such a list of pages, collections
// Left panel // Left panel
.list-group { .list-group {
...@@ -90,21 +90,15 @@ h4.list-group-item-heading { ...@@ -90,21 +90,15 @@ h4.list-group-item-heading {
color: $state-warning-text; color: $state-warning-text;
} }
&.list-group-item-profile-notification { }
padding-right: 70px;
word-wrap: normal; // Sidebar notification item styles
word-break: break-all; .list-group-item-profile-notification {
white-space: normal; word-wrap: normal;
a { word-break: break-all;
display: table-row; white-space: normal;
} &:first-child {
div, padding-right: 80px;
> span {
display: table-cell;
}
&#invitedgroups + #pendingfriends {
padding-right: 0;
}
} }
} }
...@@ -139,6 +133,19 @@ h4.list-group-item-heading { ...@@ -139,6 +133,19 @@ h4.list-group-item-heading {
color: darken($brand-default, 40%); color: darken($brand-default, 40%);
} }
} }
// Online user link see onlineusers.tpl
.online-user {
position: relative;
padding-left: 50px;
min-height: 50px;
.user-icon {
position: absolute;
left: 20px;
top: 15px;
}
}
} }
// list-group-item with btn-group // list-group-item with btn-group
......
...@@ -7,12 +7,14 @@ ...@@ -7,12 +7,14 @@
<ul class="list-group"> <ul class="list-group">
{foreach from=$sbdata.users item=user} {foreach from=$sbdata.users item=user}
<li class="list-group-item list-unstyled list-group-item-link"> <li class="list-group-item list-unstyled list-group-item-link">
<a href="{profile_url($user)}" class=""> <a href="{profile_url($user)}" class="online-user">
<span class="user-icon"> <span class="user-icon">
<img src="{$user->profileiconurl}" alt="{str tag=profileimagetext arg1=$user|display_default_name}" class="profile-icon-container"> <img src="{$user->profileiconurl}" alt="{str tag=profileimagetext arg1=$user|display_default_name}" class="profile-icon-container">
</span> </span>
{$user|display_name} <span class="user-name">
{if $user->loggedinfrom} ({$user->loggedinfrom}){/if} {$user|display_name}
{if $user->loggedinfrom} ({$user->loggedinfrom}){/if}
</span>
</a> </a>
</li> </li>
{/foreach} {/foreach}
......
...@@ -7,16 +7,14 @@ ...@@ -7,16 +7,14 @@
</h3> </h3>
<div class="list-group"> <div class="list-group">
{if $sbdata.mnetloggedinfrom} {if $sbdata.mnetloggedinfrom}
<div class="sidebar-content"> <div class="list-group-item list-group-item-profile-notification">
<p>{$sbdata.mnetloggedinfrom|clean_html|safe}</p> {$sbdata.mnetloggedinfrom|clean_html|safe}
</div> </div>
{/if} {/if}
{if $sbdata.invitedgroups} {if $sbdata.invitedgroups}
<div id="invitedgroups" class="list-group-item list-group-item-warning list-group-item-profile-notification"> <div id="invitedgroups" class="list-group-item list-group-item-warning list-group-item-profile-notification">
<a href="{$WWWROOT}group/mygroups.php?filter=invite"> <a href="{$WWWROOT}group/mygroups.php?filter=invite">
<div> <span id="invitedgroupscount" class="label label-warning">{$sbdata.invitedgroups}</span>
<span id="invitedgroupscount" class="label label-warning">{$sbdata.invitedgroups}</span>
</div>
<span id="invitedgroupsmessage">{$sbdata.invitedgroupsmessage}</span> <span id="invitedgroupsmessage">{$sbdata.invitedgroupsmessage}</span>
</a> </a>
</div> </div>
...@@ -24,9 +22,7 @@ ...@@ -24,9 +22,7 @@
{if $sbdata.pendingfriends} {if $sbdata.pendingfriends}
<div id="pendingfriends" class="list-group-item list-group-item-warning list-group-item-profile-notification"> <div id="pendingfriends" class="list-group-item list-group-item-warning list-group-item-profile-notification">
<a href="{$WWWROOT}user/myfriends.php?filter=pending"> <a href="{$WWWROOT}user/myfriends.php?filter=pending">
<div> <span id="pendingfriendscount" class="label label-warning">{$sbdata.pendingfriends}</span>
<span id="pendingfriendscount" class="label label-warning">{$sbdata.pendingfriends}</span>
</div>
<span id="pendingfriendsmessage">{$sbdata.pendingfriendsmessage}</span> <span id="pendingfriendsmessage">{$sbdata.pendingfriendsmessage}</span>
</a> </a>
</div> </div>
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment