content: import React, { Component } from 'react';
  
  class CheckList extends Component {
  
    resetRow() {
      const elem = document.getElementsByName(this.props.name);
      for (let i = 0; i < elem.length; i += 1) {
        elem[i].checked = false;
      }
      this.props.onReset(this.props.name);
    }
  
  
    render() {
      var rows = [];
      rows.push(<th key={this.props.name}>{this.props.name}</th>);
  
      rows.push(<th key={this.props.name + "0"}><input type="button" name={this.props.name} value={"RESET"} onClick={this.resetRow.bind(this)} /></th>);
  
  
  
      for (let i in this.props.groups) {
        if (this.props.active[i]) {
          rows.push(<th key={this.props.name + this.props.groups[i]}><input type="radio" name={this.props.name} value={this.props.groups[i]} onClick={this.props.onClick} /></th>);
        } else {
          rows.push(<th key={this.props.name + this.props.groups[i]}></th>);
        }
      }
  
  
      let className;
      if (this.props.conflicts[this.props.name] === undefined) {
        className = this.props.yearColor;
      } else {
        className = "conflict";
      }
  
      return (
        <tr className={className}>
            {rows}
        </tr>
      );
    }
  }
  
  
  export default CheckList;
  