<commit_before>'use strict';

const React = require('react');
const CommentStore = require('../../stores/CommentStore');
const ImageLoader = require('react-imageloader');
const Card = require('material-ui/lib/card/card');
const CardHeader = require('material-ui/lib/card/card-header');
const CardText = require('material-ui/lib/card/card-text');
const TableRow = require('material-ui/lib/table/table-row');
const TableRowColumn = require('material-ui/lib/table/table-row-column');
const Snipper = require('material-ui/lib/circular-progress');
const usericonURL = require('nicolive/lib/api.json').url.usericonURL;
const cardHeader = {wordWrap: 'break-word', height: '20px'};
const avater = {width: '48px', paddingLeft: '10px'};

let Comment = React.createClass({
  displayName: 'Comment',

  propTypes: {
    comment: React.PropTypes.any
  },

  render() {
    let userId = this.props.comment.getIn(['attr', 'user_id']);
    let userName = CommentStore.getNickname(userId);
    let userIcon = `${usericonURL}${parseInt(userId / 10000)}/${userId}.jpg`;
    return (
      <TableRow className='CommentItemBody'
                key={this.props.comment.getIn(['attr', 'no'])}
                selectable={false} >
        <TableRowColumn style={avater}>
          <ImageLoader style={{width: '78px', height: '78px'}}
                       preloader={() => { return <Snipper/> }}
                       imgProps={{width: '78px', height: '78px'}}
                       src={userIcon}>
            <img width='78px' height='78px' src='./assets/img/blank.jpg' />
          </ImageLoader>
        </TableRowColumn>
        <TableRowColumn>
          <Card>
            <CardHeader title={userName}
                        style={cardHeader} />
            <CardText>
              {this.props.comment.get('text')}<commit_msg>Fix image path<commit_after>'use strict';

const React = require('react');
const CommentStore = require('../../stores/CommentStore');
const ImageLoader = require('react-imageloader');
const Card = require('material-ui/lib/card/card');
const CardHeader = require('material-ui/lib/card/card-header');
const CardText = require('material-ui/lib/card/card-text');
const TableRow = require('material-ui/lib/table/table-row');
const TableRowColumn = require('material-ui/lib/table/table-row-column');
const Snipper = require('material-ui/lib/circular-progress');
const usericonURL = require('nicolive/lib/api.json').url.usericonURL;
const cardHeader = {wordWrap: 'break-word', height: '20px'};
const avater = {width: '48px', paddingLeft: '10px'};

let Comment = React.createClass({
  displayName: 'Comment',

  propTypes: {
    comment: React.PropTypes.any
  },

  render() {
    let userId = this.props.comment.getIn(['attr', 'user_id']);
    let userName = CommentStore.getNickname(userId);
    let userIcon = userName === '184' ? './assets/img/blank.jpg'
                 : `${usericonURL}${parseInt(userId / 10000)}/${userId}.jpg`;
    return (
      <TableRow className='CommentItemBody'
                key={this.props.comment.getIn(['attr', 'no'])}
                selectable={false} >
        <TableRowColumn style={avater}>
          <ImageLoader style={{width: '78px', height: '78px'}}
                       preloader={() => { return <Snipper/> }}
                       imgProps={{width: '78px', height: '78px'}}
                       src={userIcon}>
            <img width='78px' height='78px' src='./assets/img/blank.jpg' />
          </ImageLoader>
        </TableRowColumn>
        <TableRowColumn>
          <Card>
            <CardHeader title={userName}
                        style={cardHeader} />
            <CardText>
              {this.props.comment.get('text')}
{'fraction_non_alphanumeric': 0.167658193618172, 'fraction_numerical': 0.01325040562466198, 'mean_word_length': 2.889589905362776, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 27, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1758402', 'n_tokens_mistral': 1126, 'n_tokens_neox': 1103, 'n_words': 200}