mirror of
https://github.com/moodle/moodle.git
synced 2025-04-14 04:52:36 +02:00
Merge branch 'MDL-80183' of https://github.com/paulholden/moodle
This commit is contained in:
commit
9e16225864
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@ -65,6 +65,7 @@ function(
|
||||
SECTION_TOTAL_COUNT: '[data-region="section-total-count"]',
|
||||
SECTION_TOTAL_COUNT_CONTAINER: '[data-region="section-total-count-container"]',
|
||||
SECTION_UNREAD_COUNT: '[data-region="section-unread-count"]',
|
||||
SECTION_UNREAD_COUNT_CONTAINER: '[data-region="section-unread-count-container"]',
|
||||
PLACEHOLDER_CONTAINER: '[data-region="placeholder-container"]'
|
||||
};
|
||||
|
||||
@ -120,7 +121,7 @@ function(
|
||||
countElement.text(count);
|
||||
container.removeClass('hidden');
|
||||
Str.get_string('totalconversations', 'core_message', count).done(function(string) {
|
||||
container.attr('aria-label', string);
|
||||
$('#' + container.attr('aria-labelledby')).text(string);
|
||||
});
|
||||
|
||||
var numPlaceholders = count > 20 ? 20 : count;
|
||||
@ -149,15 +150,16 @@ function(
|
||||
* @param {Number} count The unread count
|
||||
*/
|
||||
var renderUnreadCount = function(root, count) {
|
||||
var countElement = root.find(SELECTORS.SECTION_UNREAD_COUNT);
|
||||
var container = root.find(SELECTORS.SECTION_UNREAD_COUNT_CONTAINER);
|
||||
var countElement = container.find(SELECTORS.SECTION_UNREAD_COUNT);
|
||||
countElement.text(count);
|
||||
|
||||
Str.get_string('unreadconversations', 'core_message', count).done(function(string) {
|
||||
countElement.attr('aria-label', string);
|
||||
$('#' + container.attr('aria-labelledby')).text(string);
|
||||
});
|
||||
|
||||
if (count > 0) {
|
||||
countElement.removeClass('hidden');
|
||||
container.removeClass('hidden');
|
||||
}
|
||||
};
|
||||
|
||||
|
@ -65,7 +65,9 @@
|
||||
style="height: 38px"
|
||||
>
|
||||
{{#showonlinestatus}}
|
||||
<span class="contact-status {{#isonline}}online{{/isonline}}"></span>
|
||||
<span class="contact-status icon-size-2 {{#isonline}}online{{/isonline}}">
|
||||
{{#isonline}} {{#pix}} t/online, core, {{#str}} online, core_message {{/str}} {{/pix}} {{/isonline}}
|
||||
</span>
|
||||
{{/showonlinestatus}}
|
||||
<h6 class="ml-2 font-weight-bold">{{#highlight}}{{{highlight}}}{{/highlight}}{{^highlight}}{{fullname}}{{/highlight}}</h6>
|
||||
<div
|
||||
|
@ -54,7 +54,9 @@
|
||||
>
|
||||
{{/imageurl}}
|
||||
{{#showonlinestatus}}
|
||||
<span class="contact-status {{#isonline}}online{{/isonline}}"></span>
|
||||
<span class="contact-status icon-size-2 {{#isonline}}online{{/isonline}}">
|
||||
{{#isonline}} {{#pix}} t/online, core, {{#str}} online, core_message {{/str}} {{/pix}} {{/isonline}}
|
||||
</span>
|
||||
{{/showonlinestatus}}
|
||||
<div class="w-100 text-truncate ml-2 my-2">
|
||||
<div class="d-flex">
|
||||
|
@ -64,7 +64,9 @@
|
||||
style="height: 38px"
|
||||
>
|
||||
{{#showonlinestatus}}
|
||||
<span class="contact-status {{#isonline}}online{{/isonline}}"></span>
|
||||
<span class="contact-status icon-size-2 {{#isonline}}online{{/isonline}}">
|
||||
{{#isonline}} {{#pix}} t/online, core, {{#str}} online, core_message {{/str}} {{/pix}} {{/isonline}}
|
||||
</span>
|
||||
{{/showonlinestatus}}
|
||||
<div class="w-100 text-truncate ml-2">
|
||||
<div class="d-flex">
|
||||
|
@ -59,7 +59,9 @@
|
||||
style="height: 38px"
|
||||
>
|
||||
{{#showonlinestatus}}
|
||||
<span class="contact-status {{#isonline}}online{{/isonline}}"></span>
|
||||
<span class="contact-status icon-size-2 {{#isonline}}online{{/isonline}}">
|
||||
{{#isonline}} {{#pix}} t/online, core, {{#str}} online, core_message {{/str}} {{/pix}} {{/isonline}}
|
||||
</span>
|
||||
{{/showonlinestatus}}
|
||||
<h6 class="ml-2">{{fullname}}</h6>
|
||||
<div
|
||||
|
@ -54,19 +54,26 @@
|
||||
{{#pix}} t/expanded, core {{/pix}}
|
||||
</span>
|
||||
<span class="font-weight-bold">{{$title}}{{/title}}</span>
|
||||
<small class="hidden ml-1" data-region="section-total-count-container">
|
||||
(<span aria-hidden="true" data-region="section-total-count">{{count.total}}</span>{{!
|
||||
}}<span class="sr-only">{{#str}} totalconversations, core_message, {{count.total}} {{/str}}</span>)
|
||||
<small
|
||||
class="hidden ml-1"
|
||||
data-region="section-total-count-container" aria-labelledby="{{$region}}{{/region}}-total-count-label"
|
||||
>
|
||||
(<span aria-hidden="true" data-region="section-total-count">{{count.total}}</span>)
|
||||
<span class="sr-only" id="{{$region}}{{/region}}-total-count-label">
|
||||
{{#str}} totalconversations, core_message, {{count.total}} {{/str}}
|
||||
</span>
|
||||
</small>
|
||||
<span class="hidden ml-2" data-region="loading-icon-container">
|
||||
{{> core/loading }}
|
||||
</span>
|
||||
<span
|
||||
class="{{^count.unread}}hidden{{/count.unread}} badge rounded-pill bg-primary text-white ml-auto"
|
||||
data-region="section-unread-count"
|
||||
data-region="section-unread-count-container" aria-labelledby="{{$region}}{{/region}}-unread-count-label"
|
||||
>
|
||||
<span aria-hidden="true">{{count.unread}}</span>
|
||||
<span class="sr-only">{{#str}} unreadconversations, core_message, {{count.unread}} {{/str}}</span>
|
||||
<span aria-hidden="true" data-region="section-unread-count">{{count.unread}}</span>
|
||||
<span class="sr-only" id="{{$region}}{{/region}}-unread-count-label">
|
||||
{{#str}} unreadconversations, core_message, {{count.unread}} {{/str}}
|
||||
</span>
|
||||
</span>
|
||||
</button>
|
||||
</div>
|
||||
|
@ -442,13 +442,11 @@ $message-day-color: color-yiq($message-app-bg) !default;
|
||||
.contact-status {
|
||||
position: absolute;
|
||||
left: 39px;
|
||||
top: 39px;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-radius: 50%;
|
||||
top: 34px;
|
||||
&.online {
|
||||
border: 1px solid $body-bg;
|
||||
background-color: $green;
|
||||
.icon {
|
||||
color: $green;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -31520,14 +31520,10 @@ a.ygtvspacer:hover {
|
||||
.message-app .contact-status {
|
||||
position: absolute;
|
||||
left: 39px;
|
||||
top: 39px;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-radius: 50%;
|
||||
top: 34px;
|
||||
}
|
||||
.message-app .contact-status.online {
|
||||
border: 1px solid #fff;
|
||||
background-color: #357a32;
|
||||
.message-app .contact-status.online .icon {
|
||||
color: #357a32;
|
||||
}
|
||||
.message-app .message p {
|
||||
margin: 0;
|
||||
|
@ -31520,14 +31520,10 @@ a.ygtvspacer:hover {
|
||||
.message-app .contact-status {
|
||||
position: absolute;
|
||||
left: 39px;
|
||||
top: 39px;
|
||||
width: 10px;
|
||||
height: 10px;
|
||||
border-radius: 50%;
|
||||
top: 34px;
|
||||
}
|
||||
.message-app .contact-status.online {
|
||||
border: 1px solid #fff;
|
||||
background-color: #357a32;
|
||||
.message-app .contact-status.online .icon {
|
||||
color: #357a32;
|
||||
}
|
||||
.message-app .message p {
|
||||
margin: 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user