generated from Arquisoft/wiq_0
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
71 additions
and
96 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,54 +1,30 @@ | ||
import React, { useState } from 'react'; | ||
import Container from '@mui/material/Container'; | ||
import React from 'react'; | ||
import Navbar from './components/navbar/NavBar'; | ||
import AddUser from './components/adduser/AddUser'; | ||
import Login from './components/login/Login'; | ||
import { AuthProvider } from './components/authcontext'; | ||
import { BrowserRouter as Router, Routes, Route } from 'react-router-dom'; | ||
import StartButton from './components/startbutton/StartButton'; | ||
import Game from './components/game/Game'; | ||
function App() { | ||
const [showLogin, setShowLogin] = useState(true); | ||
|
||
const handleToggleView = () => { | ||
setShowLogin(!showLogin); | ||
}; | ||
import Home from './components/home/Home'; | ||
import Footer from './components/footer/Footer'; | ||
|
||
const App = () => { | ||
return ( | ||
<Container component="main" maxWidth="xs"> | ||
|
||
<Game> <progressBar></progressBar></Game> | ||
|
||
|
||
{/*showLogin ? <Login /> : <AddUser /> | ||
<Typography component="div" align="center" sx={{ marginTop: 2 }}> | ||
{showLogin ? ( | ||
<Link name="gotoregister" component="button" variant="body2" onClick={handleToggleView}> | ||
Don't have an account? Register here. | ||
</Link> | ||
) : ( | ||
<Link component="button" variant="body2" onClick={handleToggleView}> | ||
Already have an account? Login here. | ||
</Link> | ||
)} | ||
</Typography> | ||
*/} | ||
|
||
</Container> | ||
<AuthProvider> | ||
<Router> | ||
<Navbar /> | ||
<Routes> | ||
<Route path="/" element={<StartButton isLoggedIn={true} />} /> | ||
<Route path="/addUser" element={<AddUser />} /> | ||
<Route path="/login" element={<Login />} /> | ||
<Route path="/game" element={<Game />} /> | ||
<Route path="/home" element={<Home />} /> | ||
</Routes> | ||
<Footer/> | ||
</Router> | ||
</AuthProvider> | ||
); | ||
} | ||
|
||
export default App; | ||
|
||
/* | ||
import React from 'react'; | ||
import GenerateQuestion from './components/GenerateQuestion'; // Asegúrate de importar GenerateQuestion correctamente | ||
import Login from './components/Login'; | ||
import CssBaseline from '@mui/material/CssBaseline'; | ||
import Container from '@mui/material/Container'; | ||
import Typography from '@mui/material/Typography'; | ||
import Footer from './components/Footer'; | ||
function App() { | ||
return ( | ||
}; | ||
|
||
<Container component="main" maxWidth="xs"> | ||
<CssBaseline /> | ||
<Typography component="h1" variant="h5" align="center" sx={{ marginTop: 2 }}> | ||
Welcome to the 2024 edition of the Software Architecture course | ||
</Typography> | ||
{ Aquí se muestra el componente GenerateQuestion */ | ||
|
||
export default App; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
import React from 'react'; | ||
import Navbar from '../navbar/NavBar'; | ||
import StartButton from '../startbutton/StartButton'; | ||
import Typography from '@mui/material/Typography'; | ||
import Footer from '../footer/Footer'; | ||
const Home = () => { | ||
return ( | ||
<div> | ||
|
||
|
||
<StartButton isLoggedIn={true} /> | ||
|
||
</div> | ||
); | ||
}; | ||
|
||
export default Home; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
body { | ||
margin: 0; | ||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', | ||
'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', | ||
sans-serif; | ||
-webkit-font-smoothing: antialiased; | ||
-moz-osx-font-smoothing: grayscale; | ||
} | ||
|
||
code { | ||
font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New', | ||
monospace; | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,53 +1,16 @@ | ||
import React from 'react'; | ||
import ReactDOM from 'react-dom/client'; | ||
import ReactDOM from 'react-dom'; | ||
import './index.css'; | ||
import App from './App'; | ||
import reportWebVitals from './reportWebVitals'; | ||
import Navbar from './components/navbar/NavBar'; | ||
import AddUser from './components/adduser/AddUser'; | ||
import Login from './components/login/Login'; | ||
import { AuthProvider } from './components/authcontext'; | ||
import { BrowserRouter as Router, Routes, Route } from 'react-router-dom'; | ||
import CssBaseline from '@mui/material/CssBaseline'; | ||
import Typography from '@mui/material/Typography'; | ||
import StartButton from './components/startbutton/StartButton'; | ||
import Game from './components/game/Game'; | ||
const root = ReactDOM.createRoot(document.getElementById('root')); | ||
|
||
root.render( | ||
ReactDOM.render( | ||
<React.StrictMode> | ||
|
||
|
||
<AuthProvider> | ||
<Router> | ||
<Navbar /> | ||
<Typography component="h1" variant="h5" align="center" sx={{ marginTop: 2 }}> | ||
Bienvenidos al curso 2024 de arquitectura de software somos el grupo : | ||
</Typography> | ||
<Typography component="h2" variant="h5" align="center" sx={{ marginTop: 2 }}>wiq_es04c</Typography> | ||
<Routes> | ||
<Route path="/" element={<StartButton isLoggedIn={true} />} /> | ||
<Route path="/addUser" element={<AddUser />} /> | ||
<Route path="/login" element={<Login />} /> | ||
<Route path="/game" element={<Game />} /> | ||
</Routes> | ||
|
||
|
||
|
||
|
||
|
||
|
||
</Router> | ||
|
||
<CssBaseline /> | ||
|
||
|
||
|
||
|
||
|
||
|
||
<App /> | ||
|
||
</AuthProvider> | ||
</React.StrictMode> | ||
</React.StrictMode>, | ||
document.getElementById('root') | ||
); | ||
|
||
reportWebVitals(); |