/* eslint-disable prettier/prettier */
/* eslint-disable react/no-did-mount-set-state */
/* eslint-disable prettier/prettier */
/* eslint-disable no-unused-vars */
/* eslint-disable react-native/no-inline-styles */
/* eslint-disable prettier/prettier */
import React, {Component} from 'react';
import {
  Text,
  View,
  StyleSheet,
  TouchableHighlight,
  ImageBackground,
  Image,
  Button,
  Alert,
} from 'react-native';
import styles from './style.js';
import {useNavigation} from '@react-navigation/native';

export default class TotalScore extends Component {
  constructor(props: Object) {
    super(props);
    this.state = {
      timer: 0,
      correct: 0,
      wrong: 0,
    };
  }

  componentDidMount() {
    this.setState({
      correct: this.props.route.params.c,
      wrong: this.props.route.params.w,
    });
  }

  componentWillUnmount() {
    clearInterval(this.interval);
  }
  ';';

  render() {
    const {
      container,
      selectedKeywordStyle,
      buttonStyle,
      textStyle,
      buttonB1,
      buttonB2,
      buttonB3,
      buttonB4,
      buttonB5,
      SbuttonB1,
      SbuttonB2,
      SbuttonB3,
      SbuttonB4,
      SbuttonB5,
    } = styles;
    return (
      <View style={styles.container}>
        <View style={styles.c1}>
          <View style={styles.boxScore}>
            <Text style={{fontSize: 20}}>Total Score </Text>
            <Text>Correct :{this.state.correct}</Text>
            <Text>Wrong :{this.state.wrong}</Text>
          </View>
          <Button
            title="START AGAIN"
            color="#E07EF9"
            onPress={() => this.props.navigation.navigate('1')}
          />
        </View>
      </View>
    );
  }
}
