<commit_before>import React, { Component } from 'react';
import { primaryColor } from './colors';
import LeftNav from 'material-ui/lib/left-nav';
import MenuItem from 'material-ui/lib/menus/menu-item';

class AppNav extends Component {

  constructor(props) {
    super(props);
    this.state = {open: false};
  }

  handleToggle() {
    this.setState({open: !this.state.open});
  }

  _weibo() {
    window.open("http://weibo.com/wudizhuo");
  }

  _help() {
    window.open("http://sspai.com/28388");
  }

  render() {
    return (
      <div>
        <LeftNav open={this.state.open} docked={false} onRequestChange={open => this.setState({open})}>
          <div style={styles.label}>Kindle助手</div>
          <MenuItem style={styles.item} onTouchTap={this._weibo}>
            微博</MenuItem>
          <MenuItem onTouchTap={this._help}>使用帮助</MenuItem>
        </LeftNav>
      </div>
    )
  }
}


var styles = {
  label: {
    lineHeight: '64px',
    color: '#ffffff',
    backgroundColor: primaryColor,
    fontSize: '16px',
    paddingLeft: '16px',
  },
  item: {
    marginTop: '16px',
  },
};

export default AppNav;<commit_msg>add contribute<commit_after>import React, { Component } from 'react';
import { primaryColor } from './colors';
import LeftNav from 'material-ui/lib/left-nav';
import MenuItem from 'material-ui/lib/menus/menu-item';

class AppNav extends Component {

  constructor(props) {
    super(props);
    this.state = {open: false};
  }

  handleToggle() {
    this.setState({open: !this.state.open});
  }

  _weibo() {
    window.open("http://weibo.com/wudizhuo");
  }

  _help() {
    window.open("http://sspai.com/28388");
  }

  _contribute() {
    window.open("http://weibo.com/ttarticle/p/show?id=2309403946927568873479");
  }

  render() {
    return (
      <div>
        <LeftNav open={this.state.open} docked={false} onRequestChange={open => this.setState({open})}>
          <div style={styles.label}>Kindle助手</div>
          <MenuItem style={styles.item} onTouchTap={this._weibo}>
            微博</MenuItem>
          <MenuItem onTouchTap={this._help}>使用帮助</MenuItem>
          <MenuItem onTouchTap={this._contribute}>打赏支持</MenuItem>
        </LeftNav>
      </div>
    )
  }
}


var styles = {
  label: {
    lineHeight: '64px',
    color: '#ffffff',
    backgroundColor: primaryColor,
    fontSize: '16px',
    paddingLeft: '16px',
  },
  item: {
    marginTop: '16px',
  },
};

export default AppNav;
{'fraction_non_alphanumeric': 0.1681706316652994, 'fraction_numerical': 0.019688269073010665, 'mean_word_length': 2.9338709677419357, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 27, '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': '5274027', 'n_tokens_mistral': 890, 'n_tokens_neox': 851, 'n_words': 144}