<commit_before>import React from 'react'
import PropTypes from 'prop-types';

import Talk from './Talk';

class UnscheduledArea extends React.Component {
  constructor(props) {
    super(props)

    this.state = {
      searchInput: '',
      isHidden: false
    }
  }

  handleChange = (e) => {
    this.setState({searchInput: e.target.value})
  }

  changeHiddenState = () => {
    this.setState({isHidden: !this.state.isHidden})
  }

  render() {
    const {sessions, unscheduledSessions} = this.props;
    const {searchInput, isHidden} = this.state;

    let display = isHidden ? 'none' : '';

    let unscheduledTalks = unscheduledSessions.map(talk => <Talk key={talk.id} talk={talk} />)

    return (
      <div className='unscheduled_area'>
        <div className='header_wrapper' onClick={this.changeHiddenState}>
          <h3>Unscheduled Sessions</h3>
          <span className='badge'>{unscheduledSessions.length}/{sessions.length} </span> 
        </div>
        <div 
          className='unscheduled_sessions'
          style={{'display': display}} 
        >
          <div className='search-sessions-wrapper'>
            <label>Search:</label>
            <input 
              type='text' 
              value={searchInput}<commit_msg>Add filter by name in unscheduled<commit_after>import React from 'react'
import PropTypes from 'prop-types';

import Talk from './Talk';

class UnscheduledArea extends React.Component {
  constructor(props) {
    super(props)

    this.state = {
      searchInput: '',
      isHidden: false
    }
  }

  handleChange = (e) => {
    this.setState({searchInput: e.target.value})
  }

  changeHiddenState = () => {
    this.setState({isHidden: !this.state.isHidden})
  }

  render() {
    const {sessions, unscheduledSessions} = this.props;
    const {searchInput, isHidden} = this.state;

    let display = isHidden ? 'none' : '';

    let filteredSessions = unscheduledSessions.filter(session => {
      return session.title.toLowerCase().includes(searchInput.toLowerCase()) // also filter by track once that is
    })
    let unscheduledTalks = filteredSessions.map(talk => <Talk key={talk.id} talk={talk} />)

    return (
      <div className='unscheduled_area'>
        <div className='header_wrapper' onClick={this.changeHiddenState}>
          <h3>Unscheduled Sessions</h3>
          <span className='badge'>{unscheduledSessions.length}/{sessions.length} </span> 
        </div>
        <div 
          className='unscheduled_sessions'
          style={{'display': display}} 
        >
          <div className='search-sessions-wrapper'>
            <label>Search:</label>
            <input 
              type='text' 
              value={searchInput}
{'fraction_non_alphanumeric': 0.13426779786056806, 'fraction_numerical': 0.0014754703061600886, 'mean_word_length': 2.7150684931506848, 'pattern_counts': {'":': 0, '<': 29, '<?xml version=': 0, '>': 34, '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': '6266973', 'n_tokens_mistral': 806, 'n_tokens_neox': 797, 'n_words': 156}