This repository has been archived on 2023-03-18. You can view files and clone it, but cannot push or open issues or pull requests.
osr-discourse-src/app/assets/javascripts/discourse/views/embedded_post_view.js

21 lines
516 B
JavaScript

/**
This view handles rendering of post within another (such as a collapsed reply)
@class EmbeddedPostView
@extends Discourse.View
@namespace Discourse
@module Discourse
**/
Discourse.EmbeddedPostView = Discourse.View.extend({
templateName: 'embedded_post',
classNames: ['reply'],
didInsertElement: function() {
var postView = this.get('postView') || this.get('parentView.postView');
return postView.get('screenTrack').track(this.get('elementId'), this.get('post.post_number'));
}
});