<commit_before>import React, { Component } from 'react';
import './UserList.css';

class UserList extends Component {
  render() {
    return (
      <section className="UserList container">
        <div className="InputArea">
          <input type="text" placeholder="e.g. <NAME>" ref={node => { this.input = node; }}></input>
          <button onClick={() => {
            this.props.onClick(this.input.value);
            this.input.value = '';
          }}>Go!</button>
        </div>
        <div className="ListContainer">
          <ul>
            { this.props.UserList.map((user) => <li key={user.index}>{user.name}</li>) }
          </ul>
        </div>
      </section>
    )
  }
}

export default UserList;<commit_msg>input field to retain focus after adding item<commit_after>import React, { Component } from 'react';
import './UserList.css';

class UserList extends Component {
  render() {
    return (
      <section className="UserList container">
        <div className="InputArea">
          <input type="text" placeholder="e.g. <NAME>" ref={node => { this.input = node; }}></input>
          <button onClick={() => {
            this.props.onClick(this.input.value);
            this.input.value = '';
            this.input.focus();
          }}>Go!</button>
        </div>
        <div className="ListContainer">
          <ul>
            { this.props.UserList.map((user) => <li key={user.index}>{user.name}</li>) }
          </ul>
        </div>
      </section>
    )
  }
}

export default UserList;
{'fraction_non_alphanumeric': 0.1725721784776903, 'fraction_numerical': 0.0, 'mean_word_length': 2.1704781704781704, 'pattern_counts': {'":': 0, '<': 33, '<?xml version=': 0, '>': 39, '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': '3611597', 'n_tokens_mistral': 446, 'n_tokens_neox': 446, 'n_words': 95}