mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-10 07:55:46 +01:00
closes #980
This commit is contained in:
@@ -290,9 +290,14 @@ var socket,
|
||||
var el = jQuery(this),
|
||||
uid = el.parents('li').attr('data-uid');
|
||||
|
||||
if (uid && users[uid]) {
|
||||
el.siblings('i').attr('class', 'fa fa-circle status ' + users[uid].status)
|
||||
}
|
||||
translator.translate('[[global:' + users[uid].status + ']]', function(translated) {
|
||||
if (uid && users[uid]) {
|
||||
el.siblings('i')
|
||||
.attr('class', 'fa fa-circle status ' + users[uid].status)
|
||||
.attr('title', translated)
|
||||
.attr('data-original-title', translated);
|
||||
}
|
||||
});
|
||||
});
|
||||
});
|
||||
};
|
||||
@@ -325,6 +330,13 @@ var socket,
|
||||
});
|
||||
};
|
||||
|
||||
app.createStatusTooltips = function() {
|
||||
$('body').tooltip({
|
||||
selector:'.fa-circle.status',
|
||||
placement: 'top'
|
||||
});
|
||||
}
|
||||
|
||||
app.makeNumbersHumanReadable = function(elements) {
|
||||
elements.each(function() {
|
||||
$(this).html(utils.makeNumberHumanReadable($(this).attr('title')));
|
||||
@@ -343,6 +355,8 @@ var socket,
|
||||
|
||||
app.createUserTooltips();
|
||||
|
||||
app.createStatusTooltips();
|
||||
|
||||
setTimeout(function () {
|
||||
window.scrollTo(0, 1); // rehide address bar on mobile after page load completes.
|
||||
}, 100);
|
||||
|
||||
Reference in New Issue
Block a user