mirror of
https://github.com/discourse/discourse.git
synced 2025-03-03 18:07:23 +08:00
add category name as a css class to topic list item (props to @lagwagon) - closes #3129
This commit is contained in:
parent
ab4eb353af
commit
3b3c0d7088
@ -13,6 +13,10 @@ export default Discourse.View.extend(StringBuffer, {
|
||||
var classes = [];
|
||||
var topic = this.get('topic');
|
||||
|
||||
if (topic.get('category')) {
|
||||
classes.push("category-" + topic.get('category.slug'));
|
||||
}
|
||||
|
||||
if(topic.get('hasExcerpt')){
|
||||
classes.push('has-excerpt');
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user