From dc9f70af3ae7759f5fca0c28c81c765a09345abe Mon Sep 17 00:00:00 2001 From: emmanueposu Date: Tue, 14 May 2024 04:01:38 -0700 Subject: [PATCH] Added title to pages --- trivia-forge/frontend/index.html | 1 - trivia-forge/frontend/src/App.css | 2 - trivia-forge/frontend/src/App.jsx | 2 - .../src/Components/BootstrapTable.jsx | 42 ------------------- trivia-forge/frontend/src/Pages/HomePage.jsx | 5 ++- trivia-forge/frontend/src/Pages/MyTrivia.jsx | 7 ++-- .../frontend/src/Pages/SignUpPage.jsx | 1 + .../frontend/src/Pages/TriviaGenPage.jsx | 1 + .../frontend/src/Pages/TriviaReviewPage.jsx | 1 + .../frontend/src/Services/TF-db_services.jsx | 1 - trivia-forge/frontend/src/assets/react.svg | 1 - 11 files changed, 10 insertions(+), 54 deletions(-) delete mode 100644 trivia-forge/frontend/src/Components/BootstrapTable.jsx delete mode 100644 trivia-forge/frontend/src/assets/react.svg diff --git a/trivia-forge/frontend/index.html b/trivia-forge/frontend/index.html index 88bf1490..8fd94635 100644 --- a/trivia-forge/frontend/index.html +++ b/trivia-forge/frontend/index.html @@ -6,7 +6,6 @@ - Trivia Forge diff --git a/trivia-forge/frontend/src/App.css b/trivia-forge/frontend/src/App.css index 591f1174..1c90ffdd 100644 --- a/trivia-forge/frontend/src/App.css +++ b/trivia-forge/frontend/src/App.css @@ -242,6 +242,4 @@ footer { .card:hover { box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2); - /* border: solid; - border-color: darkgrey; */ } \ No newline at end of file diff --git a/trivia-forge/frontend/src/App.jsx b/trivia-forge/frontend/src/App.jsx index 1af5f7e1..a7801c33 100644 --- a/trivia-forge/frontend/src/App.jsx +++ b/trivia-forge/frontend/src/App.jsx @@ -1,6 +1,4 @@ import { useState } from 'react'; -import reactLogo from './assets/react.svg'; -import viteLogo from '/vite.svg'; import './App.css'; import { BrowserRouter, Routes, Route } from "react-router-dom"; import Home from "./Pages/HomePage"; diff --git a/trivia-forge/frontend/src/Components/BootstrapTable.jsx b/trivia-forge/frontend/src/Components/BootstrapTable.jsx deleted file mode 100644 index 07362ad4..00000000 --- a/trivia-forge/frontend/src/Components/BootstrapTable.jsx +++ /dev/null @@ -1,42 +0,0 @@ -import React from "react"; -import Table from 'react-bootstrap/Table'; -import Card from 'react-bootstrap/Card'; - -function BootstrapTable() { - return ( - <> -

test 2

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
#First NameLast NameUsername
1MarkOtto@mdo
2JacobThornton@fat
3Larry the Bird@twitter
-
- ); -} -export default BootstrapTable; \ No newline at end of file diff --git a/trivia-forge/frontend/src/Pages/HomePage.jsx b/trivia-forge/frontend/src/Pages/HomePage.jsx index d48ce9ea..6fb6d01a 100644 --- a/trivia-forge/frontend/src/Pages/HomePage.jsx +++ b/trivia-forge/frontend/src/Pages/HomePage.jsx @@ -9,10 +9,11 @@ function Home() { return ( + Home - - + + Trivia Forge diff --git a/trivia-forge/frontend/src/Pages/MyTrivia.jsx b/trivia-forge/frontend/src/Pages/MyTrivia.jsx index 4471a2f5..9b049622 100644 --- a/trivia-forge/frontend/src/Pages/MyTrivia.jsx +++ b/trivia-forge/frontend/src/Pages/MyTrivia.jsx @@ -37,6 +37,7 @@ function MyTrivia() { return ( <> + My Trivia {games &&( games.length > 0 ? ( @@ -45,11 +46,11 @@ function MyTrivia() { {game.title} - Category: + Categories: - Number of Questions: + Questions: @@ -63,7 +64,7 @@ function MyTrivia() { ))} ) : ( -

No games to display.

+

No games to display.

) )} diff --git a/trivia-forge/frontend/src/Pages/SignUpPage.jsx b/trivia-forge/frontend/src/Pages/SignUpPage.jsx index 3159b317..a15eddb6 100644 --- a/trivia-forge/frontend/src/Pages/SignUpPage.jsx +++ b/trivia-forge/frontend/src/Pages/SignUpPage.jsx @@ -30,6 +30,7 @@ function SignUpPage() { return ( <> + Sign Up
diff --git a/trivia-forge/frontend/src/Pages/TriviaGenPage.jsx b/trivia-forge/frontend/src/Pages/TriviaGenPage.jsx index 815cd06d..801a0993 100644 --- a/trivia-forge/frontend/src/Pages/TriviaGenPage.jsx +++ b/trivia-forge/frontend/src/Pages/TriviaGenPage.jsx @@ -121,6 +121,7 @@ function TriviaGenPage() { // render component as a form return (
+ Create New Trivia

Trivia Generator

diff --git a/trivia-forge/frontend/src/Pages/TriviaReviewPage.jsx b/trivia-forge/frontend/src/Pages/TriviaReviewPage.jsx index 0a8ce3a5..33e7e931 100644 --- a/trivia-forge/frontend/src/Pages/TriviaReviewPage.jsx +++ b/trivia-forge/frontend/src/Pages/TriviaReviewPage.jsx @@ -13,6 +13,7 @@ function TriviaReviewPage() { return (
+ Trivia Review

Review and Edit Trivia Questions

{categories.map((cat, index) => ( diff --git a/trivia-forge/frontend/src/Services/TF-db_services.jsx b/trivia-forge/frontend/src/Services/TF-db_services.jsx index f1ebc363..fd75449b 100644 --- a/trivia-forge/frontend/src/Services/TF-db_services.jsx +++ b/trivia-forge/frontend/src/Services/TF-db_services.jsx @@ -235,7 +235,6 @@ export const getChoices = async (questions) => { for (let i = 0; i < response.data.length; i++) { questions[response.data[i].question_id]['choices'].push(response.data[i].text); } - console.log(questions) return questions; } catch (error) { console.error('Failed to fetch choices'); diff --git a/trivia-forge/frontend/src/assets/react.svg b/trivia-forge/frontend/src/assets/react.svg deleted file mode 100644 index 6c87de9b..00000000 --- a/trivia-forge/frontend/src/assets/react.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file