<commit_before>const bindAll = require('lodash.bindall');
const classNames = require('classnames');
const FRCInput = require('formsy-react-components').Input;
const omit = require('lodash.omit');
const PropTypes = require('prop-types');
const React = require('react');

const defaultValidationHOC = require('./validations.jsx').defaultValidationHOC;
const inputHOC = require('./input-hoc.jsx');

require('./input.scss');
require('./row.scss');

class Input extends React.Component {
    constructor (props) {
        super(props);
        bindAll(this, [
            'handleInvalid',
            'handleValid'
        ]);
        this.state = {
            status: ''
        };
    }
    handleValid () {
        this.setState({
            status: 'pass'
        });
    }
    handleInvalid () {
        this.setState({
            status: 'fail'
        });
    }
    render () {
        return (
            <FRCInput
                className="input"
                rowClassName={classNames(
                    this.state.status,
                    this.props.className,
                    {'no-label': (typeof this.props.label === 'undefined')}
                )}
                onInvalid={this.handleInvalid}
                onValid={this.handleValid}
                {...omit(this.props, ['className'])}
            />
        );
    }
}

Input.propTypes = {
    className: PropTypes.string,
    label: PropTypes.string<commit_msg>Remove unrecognized props from Input<commit_after>const classNames = require('classnames');
const FRCInput = require('formsy-react-components').Input;
const omit = require('lodash.omit');
const PropTypes = require('prop-types');
const React = require('react');

const defaultValidationHOC = require('./validations.jsx').defaultValidationHOC;
const inputHOC = require('./input-hoc.jsx');

require('./input.scss');
require('./row.scss');

const Input = props => (
    <FRCInput
        className="input"
        rowClassName={classNames(
            props.className,
            {'no-label': (typeof props.label === 'undefined')}
        )}
        {...omit(props, ['className'])}
    />
);

Input.propTypes = {
    className: PropTypes.string,
    label: PropTypes.string
{'fraction_non_alphanumeric': 0.14950316169828365, 'fraction_numerical': 0.0, 'mean_word_length': 2.2573529411764706, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 6, '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': '5913298', 'n_tokens_mistral': 616, 'n_tokens_neox': 600, 'n_words': 110}