Merge pull request #5723 from featheredtoast/topic-list-item-unread-classnames

Feature: Add unseen-topic and new-posts classnames to topic list items
This commit is contained in:
Guo Xiang Tan 2018-04-02 16:35:19 +08:00 committed by GitHub
commit d4ebbd12a6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -63,8 +63,15 @@ export default Ember.Component.extend(bufferedRender({
classes.push('has-excerpt'); classes.push('has-excerpt');
} }
if (topic.get('unseen')) {
classes.push("unseen-topic");
}
['liked', 'archived', 'bookmarked', 'pinned'].forEach(name => { if (topic.get('displayNewPosts')) {
classes.push("new-posts");
}
['liked', 'archived', 'bookmarked', 'pinned', 'closed'].forEach(name => {
if (topic.get(name)) { if (topic.get(name)) {
classes.push(name); classes.push(name);
} }