Show tooltip on avatar on deleted post
This commit is contained in:
parent
359a866458
commit
e0188d60c6
|
@ -56,8 +56,8 @@ Discourse.Utilities = {
|
||||||
return "<img width='" + size + "' height='" + size + "' src='" + url + "' class='" + classes + "'" + title + ">";
|
return "<img width='" + size + "' height='" + size + "' src='" + url + "' class='" + classes + "'" + title + ">";
|
||||||
},
|
},
|
||||||
|
|
||||||
tinyAvatar: function(avatarTemplate) {
|
tinyAvatar: function(avatarTemplate, options) {
|
||||||
return Discourse.Utilities.avatarImg({avatarTemplate: avatarTemplate, size: 'tiny' });
|
return Discourse.Utilities.avatarImg(_.merge({avatarTemplate: avatarTemplate, size: 'tiny' }, options));
|
||||||
},
|
},
|
||||||
|
|
||||||
postUrl: function(slug, topicId, postNumber) {
|
postUrl: function(slug, topicId, postNumber) {
|
||||||
|
|
|
@ -62,7 +62,7 @@ Discourse.ActionsHistoryComponent = Em.Component.extend({
|
||||||
if (post.get('deleted')) {
|
if (post.get('deleted')) {
|
||||||
buffer.push("<div class='post-action'>" +
|
buffer.push("<div class='post-action'>" +
|
||||||
I18n.t("post.deleted_by") + " " +
|
I18n.t("post.deleted_by") + " " +
|
||||||
Discourse.Utilities.tinyAvatar(post.get('postDeletedBy.avatar_template')) +
|
Discourse.Utilities.tinyAvatar(post.get('postDeletedBy.avatar_template'), {title: post.get('postDeletedBy.username')}) +
|
||||||
Discourse.Formatter.autoUpdatingRelativeAge(new Date(post.get('postDeletedAt'))) +
|
Discourse.Formatter.autoUpdatingRelativeAge(new Date(post.get('postDeletedAt'))) +
|
||||||
"</div>");
|
"</div>");
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue