Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug fix #261

Merged
merged 1 commit into from
May 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 1 addition & 6 deletions webapp/src/components/Game/Game.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,16 +72,11 @@ export default function Game(props: Props) {

const handleNextQuestion = () => {
if(count===0) saveAnswer(' ');
var q = questionCount;

if(questionCount < 9){
setTimeout(() => {
if(q === questionCount)
goToNextQuestion();
}, 3000);
}else{
goToNextQuestion();
}

};

const saveAnswer = (answer: string) => {
Expand Down
8 changes: 4 additions & 4 deletions webapp/src/components/stats/StatsTable.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,19 +38,19 @@ export default function StatsTable() {
</tr>
</thead>
<tbody>
<tr className="body-row transition-transform duration-100 transform hover:text-green-500">
<tr className="body-row transition-transform duration-100 transform">
<td className="self-center text-2xl p-5">Correct Answers</td>
<td className="text-2xl p-5" data-testid="correct-answers">{questionsCorrect}</td>
</tr>
<tr className="body-row transition-transform duration-100 transform hover:text-green-500">
<tr className="body-row transition-transform duration-100 transform">
<td className="self-center text-2xl p-5 " >Wrong Answers</td>
<td className="text-2xl p-5 " data-testid="wrong-answers">{questionsAnswered - questionsCorrect}</td>
</tr>
<tr className="body-row transition-transform duration-100 transform hover:text-green-500">
<tr className="body-row transition-transform duration-100 transform">
<td className="self-center text-2xl p-5">Gained chesses</td>
<td className="text-2xl p-5" data-testid="chesses-gained">{chesses}</td>
</tr>
<tr className="body-row transition-transform duration-100 transform hover:text-green-500">
<tr className="body-row transition-transform duration-100 transform">
<td className="self-center text-2xl p-5 ">Percentage Correct</td>
<td style={{ padding: '5px' }}>
<CircularProgress
Expand Down