<commit_before>/* @flow */
import React, { type Element } from 'react';
import { iif } from '../utils';

type Props = {|
    name: string,
    isActive?: boolean,
    onClick: () => void,
|};

export const Button = ({ name, isActive = false, onClick }: Props): Element<*> =>
    <div
        className={iif(isActive, 'btn btn-primary', 'btn btn-default')}
        onClick={onClick}>
        {name}
    </div>;

export default Button;<commit_msg>Minor Flow type impruvement.<commit_after>/* @flow */
import React, { type Element } from 'react';
import { iif } from '../utils';

type Props = {|
    name: string,
    isActive?: boolean,
    onClick: () => void,
|};

export const Button = ({ name, isActive = false, onClick }: Props): Element<'div'> =>
    <div
        className={iif(isActive, 'btn btn-primary', 'btn btn-default')}
        onClick={onClick}>
        {name}
    </div>;

export default Button;
{'fraction_non_alphanumeric': 0.17601760176017603, 'fraction_numerical': 0.0, 'mean_word_length': 3.0444444444444443, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 13, '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': '1438601', 'n_tokens_mistral': 288, 'n_tokens_neox': 291, 'n_words': 84}