<commit_before>import React from "react";
import { Map } from "immutable";
import ArrowIcon from "../../../img/svg-icons/arrow-icon.svg";

import css from "../../../css/portal-dashboard/overlay-class-response.less";

interface IProps {
  currentQuestion?: Map<string, any>;
}
interface IState {
  hideResponseArea: boolean;
}

export class ClassResponse extends React.PureComponent<IProps, IState> {
  constructor(props: IProps) {
    super(props);
    this.state = {
      hideResponseArea: false
    };
  }
  render() {
    const chevronClass = this.state.hideResponseArea ? `${css.arrow}  ${css.hideResponseArea}` : `${css.arrow}`;
    const responseAreaClass = this.state.hideResponseArea ? `${css.responseArea} ${css.hidden}` : `${css.responseArea}`;
    return (
      <div data-cy="overlay-class-response-area">
        <div className={css.responseHeader}>
          <div className={css.title} data-cy="class-response-title">Class Response</div>
          <div className={css.showHideButton} onClick={this.handleChevronClick} data-cy="show-hide-class-response-button">
            <ArrowIcon className={chevronClass} />
          </div>
        </div>
        <div className={responseAreaClass} data-cy="class-response-content">
          This is where aggregate info of class responses will go
        </div>
      </div>
    );
  }

  private handleChevronClick = () => {
    this.setState({
      hideResponseArea: !this.state.hideResponseArea
    });
  }
}
<commit_msg>fixed code climate error<commit_after>import React from "react";
import { Map } from "immutable";
import ArrowIcon from "../../../img/svg-icons/arrow-icon.svg";

import css from "../../../css/portal-dashboard/overlay-class-response.less";

interface IProps {
  currentQuestion?: Map<string, any>;
}
interface IState {
  hideResponseArea: boolean;
}

export class ClassResponse extends React.PureComponent<IProps, IState> {
  constructor(props: IProps) {
    super(props);
    this.state = {
      hideResponseArea: false
    };
  }
  render() {
    let chevronClass = `${css.arrow}`;
    let responseAreaClass = `${css.responseArea}`;

    if(this.state.hideResponseArea) {
      chevronClass += ` ${css.hideResponseArea}`;
      responseAreaClass += ` ${css.hidden}`;
    }

    return (
      <div data-cy="overlay-class-response-area">
        <div className={css.responseHeader}>
          <div className={css.title} data-cy="class-response-title">Class Response</div>
          <div className={css.showHideButton} onClick={this.handleChevronClick} data-cy="show-hide-class-response-button">
            <ArrowIcon className={chevronClass} />
          </div>
        </div>
        <div className={responseAreaClass} data-cy="class-response-content">
          This is where aggregate info of class responses will go
        </div>
      </div>
    );
  }

  private handleChevronClick = () => {
    this.setState({
      hideResponseArea: !this.state.hideResponseArea
    });
  }
}

{'fraction_non_alphanumeric': 0.14892183288409702, 'fraction_numerical': 0.0, 'mean_word_length': 3.100828729281768, 'pattern_counts': {'":': 0, '<': 29, '<?xml version=': 0, '>': 31, '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': '6886139', 'n_tokens_mistral': 879, 'n_tokens_neox': 897, 'n_words': 176}