mirror of
https://github.com/flarum/core.git
synced 2025-07-30 21:20:24 +02:00
Excerpt added to core
This commit is contained in:
@@ -11,11 +11,11 @@ export default function addStickyControl() {
|
||||
extend(DiscussionListItem.prototype, 'infoItems', function(items) {
|
||||
const discussion = this.props.discussion;
|
||||
|
||||
if (discussion.isSticky()) {
|
||||
if (discussion.isSticky() && !this.props.params.q) {
|
||||
const startPost = discussion.startPost();
|
||||
|
||||
if (startPost) {
|
||||
const excerpt = <span>{truncate(startPost.contentPlain(), 200)}</span>;
|
||||
const excerpt = truncate(startPost.contentPlain(), 175);
|
||||
|
||||
items.add('excerpt', excerpt, -100);
|
||||
}
|
||||
|
Reference in New Issue
Block a user