<commit_before>import styles from '../styles/toolbar'
import classNames from 'classnames'

import React from 'react'
import { connect } from 'react-redux'
import { translate } from '../lib/I18n'

import UploadButton from '../components/UploadButton'
import Menu, { MenuButton, Item } from 'react-bosonic/lib/Menu'

import { addFolder, showSelectionBar, uploadFile } from '../actions'

const Toolbar = ({ t, error, addFolder, disableFolderCreation, showSelectionBar, uploadFile }) => (
  <div className={styles['fil-toolbar']} role='toolbar'>
    <UploadButton
      disabled={!!error}
      onUpload={uploadFile}
      label={t('toolbar.item_upload')}
    />
    <button
        role='button'
      disabled={disableFolderCreation}
        className={classNames('coz-btn', styles['fil-action-newfolder'])}
        onClick={addFolder}
      >
      {t('toolbar.menu_new_folder')}
    </button>
    <MenuButton>
      <button
        role='button'
        className='coz-btn coz-btn--more'
        disabled={!!error}
      >
        <span className='coz-hidden'>{ t('toolbar.item_more') }</span>
      </button>
      <Menu className={styles['fil-toolbar-menu']}>
        <Item>
          <a className={styles['fil-action-upload']}>
            {t('toolbar.menu_upload')}
          </a>
        </Item>
        <Item>
          <a className={styles['fil-action-newfolder']} onClick={addFolder}>
            {t('toolbar.menu_new_folder')}
          </a>
        </Item>
        <hr />
        <Item>
          <a className={styles['fil-action-select']} onClick={showSelectionBar}><commit_msg>[fix] remove top level folder creation button<commit_after>import styles from '../styles/toolbar'
import classNames from 'classnames'

import React from 'react'
import { connect } from 'react-redux'
import { translate } from '../lib/I18n'

import UploadButton from '../components/UploadButton'
import Menu, { MenuButton, Item } from 'react-bosonic/lib/Menu'

import { addFolder, showSelectionBar, uploadFile } from '../actions'

const Toolbar = ({ t, error, addFolder, disableFolderCreation, showSelectionBar, uploadFile }) => (
  <div className={styles['fil-toolbar']} role='toolbar'>
    <UploadButton
      disabled={!!error}
      onUpload={uploadFile}
      label={t('toolbar.item_upload')}
    />
    <MenuButton>
      <button
        role='button'
        className='coz-btn coz-btn--more'
        disabled={!!error}
      >
        <span className='coz-hidden'>{ t('toolbar.item_more') }</span>
      </button>
      <Menu className={styles['fil-toolbar-menu']}>
        <Item>
          <a className={styles['fil-action-upload']}>
            {t('toolbar.menu_upload')}
          </a>
        </Item>
        <Item>
          <a
            className={styles['fil-action-newfolder']}
            onClick={addFolder}
            disabled={disableFolderCreation}
          >
            {t('toolbar.menu_new_folder')}
          </a>
        </Item>
        <hr />
        <Item>
          <a className={styles['fil-action-select']} onClick={showSelectionBar}>
{'fraction_non_alphanumeric': 0.15608638743455497, 'fraction_numerical': 0.0013089005235602095, 'mean_word_length': 2.67870036101083, 'pattern_counts': {'":': 0, '<': 43, '<?xml version=': 0, '>': 45, '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': '6407807', 'n_tokens_mistral': 893, 'n_tokens_neox': 889, 'n_words': 178}