DEV: Improve how topic status icons are handled
This commit is contained in:
parent
1850e3746a
commit
411a0b5dc6
|
@ -26,6 +26,15 @@ export default {
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
else {
|
||||||
|
promise = promise.then(data => {
|
||||||
|
data.topics.topic_list.topics = data.topics.topic_list.topics.map(topic => {
|
||||||
|
topic = Topic.create(topic);
|
||||||
|
return topic;
|
||||||
|
});
|
||||||
|
return data;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
return promise;
|
return promise;
|
||||||
},
|
},
|
||||||
|
|
|
@ -27,14 +27,7 @@
|
||||||
<tr>
|
<tr>
|
||||||
<td class="main-link">
|
<td class="main-link">
|
||||||
<span class="link-top-line">
|
<span class="link-top-line">
|
||||||
<div class="topic-statuses">
|
{{topic-status topic=topic}}
|
||||||
{{#if topic.closed}}
|
|
||||||
<span title={{i18n 'topic_statuses.locked.help'}} class="topic-status">{{d-icon 'lock'}}</span>
|
|
||||||
{{/if}}
|
|
||||||
{{#unless topic.visible}}
|
|
||||||
<span title={{i18n 'topic_statuses.unlisted.help'}} class="topic-status">{{d-icon 'far-eye-slash'}}</span>
|
|
||||||
{{/unless}}
|
|
||||||
</div>
|
|
||||||
{{knowledge-explorer-topic-link
|
{{knowledge-explorer-topic-link
|
||||||
topic=topic
|
topic=topic
|
||||||
selectTopic=selectTopic
|
selectTopic=selectTopic
|
||||||
|
|
Loading…
Reference in New Issue