<commit_before>'use strict';

import React from 'react';
import _     from 'lodash';
import Style from './css/style.js';

export default class SkillSelector extends React.Component {

  constructor(props, state) {
    super(props, state);

    this.handleChange = this.handleChange.bind(this);
  }

  handleChange(e) {
    let selectedSkill = _.find(this.props.skills, { 'skillGuid': e.target.value });
    this.props.onChange(selectedSkill);
  }

  render() {
    let style = Style.styles();

    return (
      <div style={{paddingBottom: "30px", display: 'flex', justifyContent:'space-between'}}>
        <label for="skill-select" >
          <span style={style.label}>Sub-Outcome </span>
          <select
            id="skill-select"
            name="skill-select"
            style={style.outcomeSelect}
            defaultValue={this.props.isNew ? "select-a-skill" : this.props.selectedSkill.skillGuid}
            onChange={this.handleChange}
            >
            <option disabled="disabled" value={"select-a-skill"}>Select a Skill</option>
            {this.props.skills.map((skill, index) => {
              return (
                <option key={index} index={index} value={skill.skillGuid}>{skill.skillLongOutcome}</option>
              )
            })}
            </select>
        </label>
        <div>
          {this.props.children}
        </div>
      </div>
    )
  }
}<commit_msg>change wording on skill dropdown to 'Select a Sub-Outcome'<commit_after>'use strict';

import React from 'react';
import _     from 'lodash';
import Style from './css/style.js';

export default class SkillSelector extends React.Component {

  constructor(props, state) {
    super(props, state);

    this.handleChange = this.handleChange.bind(this);
  }

  handleChange(e) {
    let selectedSkill = _.find(this.props.skills, { 'skillGuid': e.target.value });
    this.props.onChange(selectedSkill);
  }

  render() {
    let style = Style.styles();

    return (
      <div style={{paddingBottom: "30px", display: 'flex', justifyContent:'space-between'}}>
        <label for="skill-select" >
          <span style={style.label}>Sub-Outcome </span>
          <select
            id="skill-select"
            name="skill-select"
            style={style.outcomeSelect}
            defaultValue={this.props.isNew ? "select-a-skill" : this.props.selectedSkill.skillGuid}
            onChange={this.handleChange}
            >
            <option disabled="disabled" value={"select-a-skill"}>Select a Sub-Outcome</option>
            {this.props.skills.map((skill, index) => {
              return (
                <option key={index} index={index} value={skill.skillGuid}>{skill.skillLongOutcome}</option>
              )
            })}
            </select>
        </label>
        <div>
          {this.props.children}
        </div>
      </div>
    )
  }
}
{'fraction_non_alphanumeric': 0.14559386973180077, 'fraction_numerical': 0.0013932427725531174, 'mean_word_length': 2.267349260523322, 'pattern_counts': {'":': 0, '<': 31, '<?xml version=': 0, '>': 33, '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': '3521705', 'n_tokens_mistral': 856, 'n_tokens_neox': 862, 'n_words': 156}