<commit_before>var React = require('react-native');
var GroupMembers = require('./GroupMembers');
var GroupComments = require('./GroupComments');
var GroupChallenges = require('./GroupChallenges');

var {
  Component,
  Text,
  View,
  Navigator,
  Image,
  StyleSheet,
  TouchableHighlight
} = React;

var styles = StyleSheet.create({
  container: {
    marginTop: 55,
    flex: 1
  },
  image: {
    height: 350,
  },
  buttonText: {
    fontSize: 24,
    color: 'white',
    alignSelf: 'center'
  }
});

class GroupPage extends Component {
  constructor(props) {
    super(props);
    this.state = {
      group: "hello"
    };
  }

  makeBackground(btn){
    var obj = {
      flexDirection:'column',
      height: 150,
      width: 150,
      borderRadius: 75,
      justifyContent: 'center',
    }
    if(btn === 0){
      obj.alignSelf = 'flex-start';
      obj.backgroundColor = '#48BBEC';
      obj.marginLeft = 10;
    } else if (btn === 1){
      obj.marginRight = 10;
      obj.alignSelf = 'flex-end';
      obj.backgroundColor = '#E77AAE';
    } else {
      obj.marginLeft = 10;
      obj.alignSelf = 'flex-start';
      obj.backgroundColor = '#758BF4';
    }
    return obj;
  }
  goToMembers(){
    this.props.navigator.push({
      component: GroupMembers,
      passProps: {members: this.props.group.members, user: this.props.user, group: this.props.group }
    });
  }

  goToComments(){
    this.props.navigator.push({
      component: GroupComments,
      passProps: {
        comments: this.props.group.comments,
        group: this.props.group,
        user: this.props.user
       }
    });
  }

  goToChallenges(){
    this.props.navigator.push({
      component: GroupChallenges,
      passProps: { challenges: this.props.group.challenges, user: this.props.user, group: this.props.group }
    });
  }

  render(){
    return (
      <View style={styles.container}>
        <TouchableHighlight
            style={this.makeBackground(2)}
            onPress={this.goToChallenges.bind(this)}
            underlayColor="#9BAAF3">
              <Text style={styles.buttonText}>View Challenges</Text>
        </TouchableHighlight>
        <TouchableHighlight
            style={this.makeBackground(1)}
            onPress={this.goToComments.bind(this)}
            underlayColor="#E39EBF">
              <Text style={styles.buttonText}>Chat Room</Text>
        </TouchableHighlight>
        <TouchableHighlight
            style={this.makeBackground(0)}
            onPress={this.goToMembers.bind(this)}
            underlayColor="#88D4F5">
              <Text style={styles.buttonText}>View Members</Text>
        </TouchableHighlight>
      </View>
    )
  }
};

// GroupPage.propTypes = {
//   userInfo: React.PropTypes.object.isRequired
// }

module.exports = GroupPage;<commit_msg>trying to footer<commit_after>var React = require('react-native');
var GroupMembers = require('./GroupMembers');
var GroupComments = require('./GroupComments');
var GroupChallenges = require('./GroupChallenges');

var {
  Component,
  Text,
  View,
  Navigator,
  Image,
  StyleSheet,
  TouchableHighlight
} = React;


class GroupPage extends Component {
  constructor(props) {
    super(props);
    this.state = {
      group: "hello",
      btnLocation: 0,
    };
  }

  makeBackground(btn){
    var obj = {
      borderRadius: 6,
      justifyContent: 'center',
      padding: 20,
    }
    if(btn === 0){
      obj.alignSelf = 'flex-start';
      obj.backgroundColor = '#48BBEC';
      obj.margin = 10;
    } else if (btn === 1){
      obj.margin = 10;
      obj.alignSelf = 'flex-end';
      obj.backgroundColor = '#E77AAE';
    } else {
      obj.margin = 10;
      obj.alignSelf = 'flex-start';
      obj.backgroundColor = '#758BF4';
    }
    return obj;
  }
  goToMembers(){
    this.props.navigator.push({
      component: GroupMembers,
      passProps: {members: this.props.group.members, user: this.props.user, group: this.props.group }
    });
  }

  goToComments(){
    this.props.navigator.push({
      component: GroupComments,
      passProps: {
        comments: this.props.group.comments,
        group: this.props.group,
        user: this.props.user
       }
    });
  }

  goToChallenges(){
    this.props.navigator.push({
      component: GroupChallenges,
      passProps: { challenges: this.props.group.challenges, user: this.props.user, group: this.props.group }
    });
  }

  render(){
    return (
      <View style={styles.container}>

        <TouchableHighlight
            style={this.makeBackground(2)}
            onPress={this.goToChallenges.bind(this)}
            underlayColor="#9BAAF3">
              <Text style={styles.buttonText}>Challenges</Text>
        </TouchableHighlight>
        <TouchableHighlight
            style={this.makeBackground(1)}
            onPress={this.goToComments.bind(this)}
            underlayColor="#E39EBF">
              <Text style={styles.buttonText}>Chat Room</Text>
        </TouchableHighlight>
        <TouchableHighlight
            style={this.makeBackground(0)}
            onPress={this.goToMembers.bind(this)}
            underlayColor="#88D4F5">
              <Text style={styles.buttonText}>Members</Text>
        </TouchableHighlight>
        <View style={{bottom: this.state.btnLocation}}>
        <TouchableHighlight
            style={styles.footer}>
        <Text style={styles.buttonText}>{this.props.group.name}</Text>
        </TouchableHighlight></View>
      </View>
    )
  }
};

var styles = StyleSheet.create({
  container: {
    paddingTop: 55,
    flex: 1,
    backgroundColor: 'white'
  },
  footer: {
    height: 60,
    backgroundColor: '#4800a8',
    alignItems: 'center',
    justifyContent: 'center'
  },
  footyText: {
    color: 'white',
    fontSize: 35,
    margin: 10
  },
  buttonText: {
    fontSize: 35,
    color: 'white',
    padding: 10,
    alignSelf: 'center'
  }
});

module.exports = GroupPage;
{'fraction_non_alphanumeric': 0.1395034622529978, 'fraction_numerical': 0.015537915892585711, 'mean_word_length': 2.417195614541258, 'pattern_counts': {'":': 0, '<': 37, '<?xml version=': 0, '>': 37, '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': '4009407', 'n_tokens_mistral': 1943, 'n_tokens_neox': 1827, 'n_words': 328}