<commit_before>import React, {
  View,
  Text,
  Image,
  StyleSheet,
  TouchableHighlight,
  TouchableOpacity
} from 'react-native'

import { toRows } from '../lib/utils'
import Answer from './Answer'

const renderAnswer = (selectedAnswer, onSelectAnswer) => ({ key, value }, i) => (
  <Answer
    key={i}
    selectedAnswer={selectedAnswer}
    onSelectAnswer={() => onSelectAnswer({ index: 0, answer: key })}
    answerKey={key}
    answerText={value} />
)

export default ({ image, question, answers, selectedAnswer, onSelectAnswer }) => (
  <View style={{ flex: 1 }}>
    <Image style={styles.image} source={image} />
    <View style={styles.heading}>
      <Text style={styles.question}>
       {question}
      </Text>
    </View>
    <View>
      {toRows(answers).map(renderAnswer(selectedAnswer, onSelectAnswer))}
    </View>
    <View style={styles.buttonContainer}>
      <TouchableOpacity style={styles.button}>
        <Text style={styles.buttonText}>Submit Answer</Text>
      </TouchableOpacity>
    </View>
  </View>
)

const styles = StyleSheet.create({
  heading: {
    backgroundColor: '#F8F8F8'
  },
  image: {
    width: 400,
    height: 300
  },
  question: {
    fontSize: 18,
    margin: 5,
    color: '#656565'
  },
  buttonContainer: {
    flex: 1,
    alignItems: 'flex-end',
    justifyContent: 'flex-end',
  },
  buttonText: {
    fontSize: 18,
    color: 'white',
    alignSelf: 'center'
  },
  button: {
    height: 36,
    backgroundColor: '#48BBEC',
    borderColor: '#48BBEC',
    borderWidth: 1,
    alignSelf: 'stretch',
    justifyContent: 'center'
  }
})
<commit_msg>remove unused components<commit_after>import React, {
  View,
  Text,
  Image,
  StyleSheet,
  TouchableOpacity
} from 'react-native'

import { toRows } from '../lib/utils'
import Answer from './Answer'

const renderAnswer = (selectedAnswer, onSelectAnswer) => ({ key, value }, i) => (
  <Answer
    key={i}
    selectedAnswer={selectedAnswer}
    onSelectAnswer={() => onSelectAnswer({ index: 0, answer: key })}
    answerKey={key}
    answerText={value} />
)

export default ({ image, question, answers, selectedAnswer, onSelectAnswer }) => (
  <View style={{ flex: 1 }}>
    <Image style={styles.image} source={image} />
    <View style={styles.heading}>
      <Text style={styles.question}>
       {question}
      </Text>
    </View>
    <View>
      {toRows(answers).map(renderAnswer(selectedAnswer, onSelectAnswer))}
    </View>
    <View style={styles.buttonContainer}>
      <TouchableOpacity style={styles.button}>
        <Text style={styles.buttonText}>Submit Answer</Text>
      </TouchableOpacity>
    </View>
  </View>
)

const styles = StyleSheet.create({
  heading: {
    backgroundColor: '#F8F8F8'
  },
  image: {
    width: 400,
    height: 300
  },
  question: {
    fontSize: 18,
    margin: 5,
    color: '#656565'
  },
  buttonContainer: {
    flex: 1,
    alignItems: 'flex-end',
    justifyContent: 'flex-end',
  },
  buttonText: {
    fontSize: 18,
    color: 'white',
    alignSelf: 'center'
  },
  button: {
    height: 36,
    backgroundColor: '#48BBEC',
    borderColor: '#48BBEC',
    borderWidth: 1,
    alignSelf: 'stretch',
    justifyContent: 'center'
  }
})

{'fraction_non_alphanumeric': 0.15723663644889027, 'fraction_numerical': 0.018755861206627072, 'mean_word_length': 3.1237113402061856, 'pattern_counts': {'":': 0, '<': 35, '<?xml version=': 0, '>': 43, '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': '4302639', 'n_tokens_mistral': 1132, 'n_tokens_neox': 1060, 'n_words': 233}