1 import { Component } from 'inferno';
2 import { CommentNode as CommentNodeI, CommunityUser, UserView } from '../interfaces';
3 import { CommentNode } from './comment-node';
5 interface CommentNodesState {
8 interface CommentNodesProps {
9 nodes: Array<CommentNodeI>;
10 moderators?: Array<CommunityUser>;
11 admins?: Array<UserView>;
12 postCreatorId?: number;
19 export class CommentNodes extends Component<CommentNodesProps, CommentNodesState> {
21 constructor(props: any, context: any) {
22 super(props, context);
27 <div className="comments">
28 {this.props.nodes.map(node =>
29 <CommentNode node={node}
30 noIndent={this.props.noIndent}
31 viewOnly={this.props.viewOnly}
32 locked={this.props.locked}
33 moderators={this.props.moderators}
34 admins={this.props.admins}
35 postCreatorId={this.props.postCreatorId}
36 markable={this.props.markable}