mirror of
https://github.com/flarum/core.git
synced 2025-08-06 08:27:42 +02:00
Make the toolbar fixed to the top; tweak contents
Add a comment count (which links to the full discussion) and show the reply button normally on mobile.
This commit is contained in:
@@ -31,6 +31,17 @@ export default class DiscussionPage extends BaseDiscussionPage {
|
||||
|
||||
items.remove('scrubber');
|
||||
|
||||
const count = this.discussion.repliesCount();
|
||||
|
||||
items.add('replies', <h3>
|
||||
<a href={app.route.discussion(this.discussion).replace('/embed', '/d')} config={m.route}>
|
||||
{count} comment{count == 1 ? '' : 's'}
|
||||
</a>
|
||||
</h3>, 100);
|
||||
|
||||
const props = items.get('controls').props;
|
||||
props.className = props.className.replace('App-primaryControl', '');
|
||||
|
||||
return items;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user