<commit_before>"use strict";

import React                                                                  from "react";
import User                                                                   from "../../stores/user";
import StoreKeeper                                                            from "../mixins/store_keeper";
import Router                                                                 from "react-router";
import { Toolbar, ToolbarGroup, DropDownMenu, RaisedButton, TextField, Paper} from "material-ui";
import AdminActions                                                           from "../../actions/admin";

export default React.createClass({

  onToolbarChange(e, index, payload){
    // Generate an action
    AdminActions.changeMainTab(payload);
  },

  render() {
    var dropDownItems = [
      {payload: '0', text: 'Client Info'},
    ];

    var styles = {
      searchBarStyle: {
        marginTop: '9px',
        display: 'inline-block',
      },

      graphPaper: {
        width: 'auto',
        minHeight: '60px',
        background: 'white'
      },

      graphTitleBar: {
        width: 'auto'
      },

      leftFloat: {
        float: 'left'
      },

      rightFloat: {
        paddingRight: '20px',
        float: 'right'
      }
    };

    return (
      <Paper style={styles.graphPaper} className="graph-paper">
        <div style={styles.leftFloat}>
          <DropDownMenu menuItems={dropDownItems} onChange={this.onToolbarChange}/>
        </div>
        <div style={styles.rightFloat}>
          <div style={styles.searchBarStyle}>
            <TextField hintText="Search..." />
          </div>
          <RaisedButton label="Search" secondary={true} />
        </div>
      </Paper>
    );
  }

});<commit_msg>Converts tool_bar to ES6 class<commit_after>"use strict";

import React                                                                  from "react";
import User                                                                   from "../../stores/user";
import StoreKeeper                                                            from "../mixins/store_keeper";
import Router                                                                 from "react-router";
import { Toolbar, ToolbarGroup, DropDownMenu, RaisedButton, TextField, Paper} from "material-ui";
import AdminActions                                                           from "../../actions/admin";

class ToolBar extends React.Component {

  onToolbarChange(e, index, payload){
    // Generate an action
    AdminActions.changeMainTab(payload);
  }

  render() {
    var dropDownItems = [
      {payload: '0', text: 'Client Info'},
    ];

    var styles = {
      searchBarStyle: {
        marginTop: '9px',
        display: 'inline-block',
      },

      graphPaper: {
        width: 'auto',
        minHeight: '60px',
        background: 'white'
      },

      graphTitleBar: {
        width: 'auto'
      },

      leftFloat: {
        float: 'left'
      },

      rightFloat: {
        paddingRight: '20px',
        float: 'right'
      }
    };

    return (
      <Paper style={styles.graphPaper} className="graph-paper">
        <div style={styles.leftFloat}>
          <DropDownMenu menuItems={dropDownItems} onChange={this.onToolbarChange}/>
        </div>
        <div style={styles.rightFloat}>
          <div style={styles.searchBarStyle}>
            <TextField hintText="Search..." />
          </div>
          <RaisedButton label="Search" secondary={true} />
        </div>
      </Paper>
    );
  }

}

module.exports = ToolBar;
{'fraction_non_alphanumeric': 0.11949860724233984, 'fraction_numerical': 0.0036211699164345403, 'mean_word_length': 1.3470588235294119, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 20, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6424816', 'n_tokens_mistral': 895, 'n_tokens_neox': 870, 'n_words': 199}