FIX: Missing topic status icons in header

This commit is contained in:
Robin Ward 2016-04-25 13:47:57 -04:00
parent 8bad3c0eb5
commit 6978171f46
No known key found for this signature in database
GPG Key ID: 0E091E2B4ED1B83D

View File

@ -11,6 +11,8 @@ function renderIcon(name, key, canAct) {
} }
export default createWidget('topic-status', { export default createWidget('topic-status', {
tagName: 'div.topic-statuses',
html(attrs) { html(attrs) {
const topic = attrs.topic; const topic = attrs.topic;
const canAct = this.currentUser && !attrs.disableActions; const canAct = this.currentUser && !attrs.disableActions;
@ -26,13 +28,13 @@ export default createWidget('topic-status', {
if (topic.get('closed') && topic.get('archived')) { if (topic.get('closed') && topic.get('archived')) {
renderIcon('lock', 'locked_and_archived'); renderIcon('lock', 'locked_and_archived');
} else { } else {
renderIconIf('topic.closed', 'lock', 'locked'); renderIconIf('closed', 'lock', 'locked');
renderIconIf('topic.archived', 'lock', 'archived'); renderIconIf('archived', 'lock', 'archived');
} }
renderIconIf('topic.pinned', 'thumb-tack', 'pinned'); renderIconIf('pinned', 'thumb-tack', 'pinned');
renderIconIf('topic.unpinned', 'thumb-tack', 'unpinned'); renderIconIf('unpinned', 'thumb-tack', 'unpinned');
renderIconIf('topic.invisible', 'eye-slash', 'invisible'); renderIconIf('invisible', 'eye-slash', 'invisible');
return result; return result;
} }