mirror of
https://github.com/discourse/discourse.git
synced 2025-02-25 18:55:32 -06:00
Merge pull request #2739 from techAPJ/patch-1
hide poster avatars when only two posts
This commit is contained in:
commit
defe1dd86f
@ -22,6 +22,8 @@ export default Ember.Component.extend({
|
|||||||
this.set('mapCollapsed', Discourse.Mobile.mobileView || (!this.get('topic.has_summary')));
|
this.set('mapCollapsed', Discourse.Mobile.mobileView || (!this.get('topic.has_summary')));
|
||||||
},
|
},
|
||||||
|
|
||||||
|
showPosterAvatar: Em.computed.gt('topic.posts_count', 2),
|
||||||
|
|
||||||
toggleMapClass: function() {
|
toggleMapClass: function() {
|
||||||
return this.get('mapCollapsed') ? 'fa fa-chevron-down' : 'fa fa-chevron-up';
|
return this.get('mapCollapsed') ? 'fa fa-chevron-down' : 'fa fa-chevron-up';
|
||||||
}.property('mapCollapsed'),
|
}.property('mapCollapsed'),
|
||||||
|
@ -39,14 +39,16 @@
|
|||||||
</li>
|
</li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
{{#if details.links.length}}
|
{{#if details.links.length}}
|
||||||
<li class='secondary'>
|
<li class='secondary'>
|
||||||
{{number details.links.length}}
|
{{number details.links.length}}
|
||||||
<h4>{{i18n links_lowercase}}</h4>
|
<h4>{{i18n links_lowercase}}</h4>
|
||||||
</li>
|
</li>
|
||||||
|
{{/if}}
|
||||||
|
{{#if showPosterAvatar}}
|
||||||
|
<li {{bind-attr class=":avatars mapCollapsed::hidden"}}>
|
||||||
|
{{#grouped-each participant in details.fewParticipants}}{{topic-participant participant=participant}}{{/grouped-each}}
|
||||||
|
</li>
|
||||||
{{/if}}
|
{{/if}}
|
||||||
<li {{bind-attr class=":avatars mapCollapsed::hidden"}}>
|
|
||||||
{{#grouped-each participant in details.fewParticipants}}{{topic-participant participant=participant}}{{/grouped-each}}
|
|
||||||
</li>
|
|
||||||
</ul>
|
</ul>
|
||||||
</section>
|
</section>
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user