perf: remove createUserTooltips

This commit is contained in:
Baris Usakli
2021-11-12 11:18:44 -05:00
parent d196409580
commit facc10e40f
8 changed files with 2 additions and 28 deletions

View File

@@ -209,18 +209,8 @@ app.flags = {};
.addClass('active');
}
app.createUserTooltips = function (els, placement) {
if (isTouchDevice) {
return;
}
els = els || $('body');
els.find('.avatar,img[title].teaser-pic,img[title].user-img,div.user-icon,span.user-icon').each(function () {
$(this).tooltip({
placement: placement || $(this).attr('title-placement') || 'top',
title: $(this).attr('title'),
container: '#content',
});
});
app.createUserTooltips = function () {
console.warn('[removed] app.creatUserTooltips is removed');
};
app.createStatusTooltips = function () {
@@ -234,15 +224,9 @@ app.flags = {};
app.processPage = function () {
highlightNavigationLink();
$('.timeago').timeago();
utils.makeNumbersHumanReadable($('.human-readable-number'));
utils.addCommasToNumbers($('.formatted-number'));
app.createUserTooltips($('#content'));
app.createStatusTooltips();
};