<commit_before>/** @jsx React.DOM */

define([
  "React",
  "mixins/BackboneMixin",
  "models/Task",
  "jsx!components/TimeFieldComponent",
  "jsx!components/TaskHealthComponent"
], function(React, BackboneMixin, Task,
  TimeFieldComponent, TaskHealthComponent) {

  return React.createClass({
    displayName: "TaskDetailComponent",
    mixins: [BackboneMixin],
    propTypes: {
      hasHealth: React.PropTypes.bool,
      onShowTaskList: React.PropTypes.func.isRequired,
      task: React.PropTypes.object.isRequired
    },
    getResource: function() {
      return this.props.task;
    },
    handleShowTaskList: function (event) {
      event.preventDefault();
      this.props.onShowTaskList();
    },
    render: function() {
      var task = this.props.task;
      var hasHealth = !!this.props.hasHealth;
      var hasError = this.props.fetchState === this.props.STATES.STATE_ERROR || task.collection == null;
      var taskHealth = task.getHealth();
      var healthClassSet;
      var timeNodes;
      var timeFields;
      if (!hasError) {

        healthClassSet = React.addons.classSet({
          "text-healthy": taskHealth === Task.HEALTH.HEALTHY,
          "text-unhealthy": taskHealth === Task.HEALTH.UNHEALTHY,
          "text-muted": taskHealth === Task.HEALTH.UNKNOWN
        });

        timeNodes = [
          {
            label: "Staged at",
            time: task.get("stagedAt")
          }, {
            label: "Started success",
            time: task.get("startedAt")
          }
        ];
        timeFields = timeNodes.map(function(timeNode, index) {
          return (
            <TimeFieldComponent
              key={index}
              label={timeNode.label}
              time={timeNode.time} />
          );
        });
      }

      return (
        <div>
          <ol className="breadcrumb">
            <li><commit_msg>Review: wrong label name<commit_after>/** @jsx React.DOM */

define([
  "React",
  "mixins/BackboneMixin",
  "models/Task",
  "jsx!components/TimeFieldComponent",
  "jsx!components/TaskHealthComponent"
], function(React, BackboneMixin, Task,
  TimeFieldComponent, TaskHealthComponent) {

  return React.createClass({
    displayName: "TaskDetailComponent",
    mixins: [BackboneMixin],
    propTypes: {
      hasHealth: React.PropTypes.bool,
      onShowTaskList: React.PropTypes.func.isRequired,
      task: React.PropTypes.object.isRequired
    },
    getResource: function() {
      return this.props.task;
    },
    handleShowTaskList: function (event) {
      event.preventDefault();
      this.props.onShowTaskList();
    },
    render: function() {
      var task = this.props.task;
      var hasHealth = !!this.props.hasHealth;
      var hasError = this.props.fetchState === this.props.STATES.STATE_ERROR || task.collection == null;
      var taskHealth = task.getHealth();
      var healthClassSet;
      var timeNodes;
      var timeFields;
      if (!hasError) {

        healthClassSet = React.addons.classSet({
          "text-healthy": taskHealth === Task.HEALTH.HEALTHY,
          "text-unhealthy": taskHealth === Task.HEALTH.UNHEALTHY,
          "text-muted": taskHealth === Task.HEALTH.UNKNOWN
        });

        timeNodes = [
          {
            label: "Staged at",
            time: task.get("stagedAt")
          }, {
            label: "Started at",
            time: task.get("startedAt")
          }
        ];
        timeFields = timeNodes.map(function(timeNode, index) {
          return (
            <TimeFieldComponent
              key={index}
              label={timeNode.label}
              time={timeNode.time} />
          );
        });
      }

      return (
        <div>
          <ol className="breadcrumb">
            <li>
{'fraction_non_alphanumeric': 0.12754010695187165, 'fraction_numerical': 0.0, 'mean_word_length': 2.1436974789915966, 'pattern_counts': {'":': 6, '<': 11, '<?xml version=': 0, '>': 11, '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': '1564010', 'n_tokens_mistral': 1114, 'n_tokens_neox': 1097, 'n_words': 194}