mirror of
https://github.com/NodeBB/NodeBB.git
synced 2026-01-24 00:09:41 +01:00
Added new core component for topic with tid
Added new core component for topic with a specific tid
To use
```javascript
var topicContainer = components.get('topic', 'tid', tid);
```javascript
in a view with more topics / posts
This commit is contained in:
@@ -10,6 +10,9 @@ define('components', function() {
|
||||
return $('[component="topic/teaser"]');
|
||||
}
|
||||
},
|
||||
'topic': function(name, value) {
|
||||
return $('[component="topic"][data-' + name + '="' + value + '"]');
|
||||
},
|
||||
'post': function(name, value) {
|
||||
return $('[component="post"][data-' + name + '="' + value + '"]');
|
||||
},
|
||||
@@ -63,4 +66,4 @@ define('components', function() {
|
||||
};
|
||||
|
||||
return components;
|
||||
});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user