<commit_before>var React = require('react');

var KlassBox = React.createClass({
  getInitialState: function() {
    return {
      display: 'panel'
    };
  },
  deleteClick: function(){
    this.props.delete(this.props.klass._id);
  },
  editClick: function(){
    this.setState({
      display: "edit"
    });
  },
  handleSubmit: function(event){
    event.preventDefault();
    this.props.update(event);
  },
  render: function() {
    if(this.state.display === "panel"){
      var content = <div className="panel panel-default">
        <div className="panel-heading">
          <h5 className="panel-title">{this.props.klass.name}</h5>
          <p>Pin: {this.props.klass.pin}</p>
          <p>Grade: {this.props.klass.grade}</p>
          <button onClick={this.editClick}>Edit</button>
          <button onClick={this.deleteClick}>Delete</button>
        </div>
        <div className="panel-body">
          Panel content
        </div>
      </div><commit_msg>Reset klass edit form to panel<commit_after>var React = require('react');

var KlassBox = React.createClass({
  getInitialState: function() {
    return {
      display: 'panel'
    };
  },
  deleteClick: function(){
    this.props.delete(this.props.klass._id);
  },
  editClick: function(){
    this.setState({
      display: "edit"
    });
  },
  handleSubmit: function(event){
    event.preventDefault();
    this.props.update(event);
    this.setState({
      display: panel
    });
  },
  render: function() {
    if(this.state.display === "panel"){
      var content = <div className="panel panel-default">
        <div className="panel-heading">
          <h5 className="panel-title">{this.props.klass.name}</h5>
          <p>Pin: {this.props.klass.pin}</p>
          <p>Grade: {this.props.klass.grade}</p>
          <button onClick={this.editClick}>Edit</button>
          <button onClick={this.deleteClick}>Delete</button>
        </div>
        <div className="panel-body">
          Panel content
        </div>
      </div>
{'fraction_non_alphanumeric': 0.16816367265469062, 'fraction_numerical': 0.001996007984031936, 'mean_word_length': 2.6126126126126126, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 35, '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': '2484924', 'n_tokens_mistral': 613, 'n_tokens_neox': 622, 'n_words': 109}