discourse/app/assets/javascripts/discourse/views/replies_view.js.coffee
2013-02-05 14:16:51 -05:00

14 lines
413 B
CoffeeScript

window.Discourse.RepliesView = Ember.CollectionView.extend
templateName: 'replies'
tagName: 'section'
classNames: ['replies-list', 'embedded-posts', 'bottom']
itemViewClass: Discourse.EmbeddedPostView
repliesShown: (->
$this = @.$()
if @get('parentView.repliesShown')
Em.run.next -> $this.slideDown()
else
Em.run.next -> $this.slideUp()
).observes('parentView.repliesShown')