Skip to content

Commit

Permalink
Actualizaciñon css estadísticas
Browse files Browse the repository at this point in the history
  • Loading branch information
UO289659 committed Apr 22, 2024
1 parent d29ffff commit 436f598
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 3 deletions.
Binary file modified webapp/public/estadisticas.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
3 changes: 3 additions & 0 deletions webapp/src/App.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React from 'react';
import AuthProvider from './components/login/AuthProvider';
import Routes from './components/Routes';
import Footer from "./components/footer/Footer";

function App() {

Expand All @@ -9,7 +10,9 @@ function App() {
<AuthProvider>
<Routes />
</AuthProvider>

</main>

);
}

Expand Down
18 changes: 16 additions & 2 deletions webapp/src/components/Statistics.css
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
/* Estilo para las celdas de la tabla */
th, td {
padding: 1em;
text-align: center;
color: #EE0E50;
padding: 2vh 3vh; /* espaciado de las celdas */
border-bottom: vh solid #EE0E51; /* Borde inferior */
}

/* Estilo para el encabezado de la tabla */
Expand All @@ -17,7 +19,19 @@ th {
/* Estilo para las filas al pasar el ratón */

.principal{
display: flex;
flex-direction: column;
align-items: center;
height: 100vh; /* Ocupar toda la altura de la pantalla */
width: 100vw; /* Ocupar toda la anchura de la pantalla */
background-color: #fff;
}
}
.principal p {
font-size: 1.2rem; /* Tamaño de fuente */
margin-bottom: 20px; /* Espacio debajo del mensaje */
color: #333; /* Color de texto */
font-weight: bold;
}
.table-stats{
width: 50%;
}
7 changes: 6 additions & 1 deletion webapp/src/components/Statistics.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import React, { useState, useEffect } from 'react';
import './Statistics.css';


const Statistics= () => {
const gatewayEndpoint = process.env.REACT_APP_API_ENDPOINT || 'http://localhost:8000';
const [userData, setUserData] = useState(null);
Expand All @@ -25,9 +26,11 @@ const Statistics= () => {
<div className="title">
<img src="/estadisticas.png" alt="Título como imagen" className="title-image" />
</div>

{error ? ( // Verificar si hay un error
<p>Error: {error}</p>
) : userData ? (
<div className='table.stats'>
<table>
<thead>
<tr>
Expand All @@ -46,14 +49,16 @@ const Statistics= () => {
</tr>
</tbody>
</table>

</div>
) : (
<p>Cargando estadísticas...</p>
)}

</div>


);

}

export default Statistics;

0 comments on commit 436f598

Please sign in to comment.