mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-27 09:06:15 +01:00
This commit is contained in:
@@ -220,7 +220,7 @@ if (document.readyState === 'loading') {
|
|||||||
if (!isTouchDevice) {
|
if (!isTouchDevice) {
|
||||||
els = els || $('body');
|
els = els || $('body');
|
||||||
els.tooltip({
|
els.tooltip({
|
||||||
selector: '.avatar.avatar-tooltip',
|
selector: '.avatar-tooltip',
|
||||||
placement: placement || 'top',
|
placement: placement || 'top',
|
||||||
container: '#content',
|
container: '#content',
|
||||||
animation: false,
|
animation: false,
|
||||||
|
|||||||
@@ -214,9 +214,9 @@ module.exports = function (utils, Benchpress, relative_path) {
|
|||||||
|
|
||||||
function renderTopicImage(topicObj) {
|
function renderTopicImage(topicObj) {
|
||||||
if (topicObj.thumb) {
|
if (topicObj.thumb) {
|
||||||
return '<img src="' + topicObj.thumb + '" class="img-circle user-img" title="' + topicObj.user.username + '" />';
|
return '<img src="' + topicObj.thumb + '" class="img-circle user-img" title="' + topicObj.user.displayname + '" />';
|
||||||
}
|
}
|
||||||
return '<img component="user/picture" data-uid="' + topicObj.user.uid + '" src="' + topicObj.user.picture + '" class="user-img" title="' + topicObj.user.username + '" />';
|
return '<img component="user/picture" data-uid="' + topicObj.user.uid + '" src="' + topicObj.user.picture + '" class="user-img" title="' + topicObj.user.displayname + '" />';
|
||||||
}
|
}
|
||||||
|
|
||||||
function renderDigestAvatar(block) {
|
function renderDigestAvatar(block) {
|
||||||
@@ -313,7 +313,7 @@ module.exports = function (utils, Benchpress, relative_path) {
|
|||||||
let output = '';
|
let output = '';
|
||||||
|
|
||||||
if (userObj.picture) {
|
if (userObj.picture) {
|
||||||
output += `<img${attr2String(attributes)} alt="${userObj.username}" loading="lazy" component="${component || 'avatar/picture'}" src="${userObj.picture}" style="${styles.join(' ')}" onError="this.remove()" itemprop="image" />`;
|
output += `<img${attr2String(attributes)} alt="${userObj.displayname}" loading="lazy" component="${component || 'avatar/picture'}" src="${userObj.picture}" style="${styles.join(' ')}" onError="this.remove()" itemprop="image" />`;
|
||||||
}
|
}
|
||||||
output += `<span${attr2String(attributes)} component="${component || 'avatar/icon'}" style="${styles.join(' ')} background-color: ${userObj['icon:bgColor']}">${userObj['icon:text']}</span>`;
|
output += `<span${attr2String(attributes)} component="${component || 'avatar/icon'}" style="${styles.join(' ')} background-color: ${userObj['icon:bgColor']}">${userObj['icon:text']}</span>`;
|
||||||
return output;
|
return output;
|
||||||
|
|||||||
Reference in New Issue
Block a user