diff --git a/src/client/src/TournamentOverview.js b/src/client/src/TournamentOverview.js index a1b3286..83852ad 100644 --- a/src/client/src/TournamentOverview.js +++ b/src/client/src/TournamentOverview.js @@ -3,10 +3,12 @@ import { Link } from "react-router-dom"; import Appbar from './components/AsuraBar'; import TournamentBar from "./components/TournamentBar"; import { useParams } from 'react-router-dom' -import { Button, Paper, Stack, CircularProgress, Box, Grid } from "@mui/material"; +import { Button, IconButton, Paper, Stack, CircularProgress, Box, Grid, Typography, Container } from "@mui/material"; import "./components/tournamentBracket.css"; import EmojiEventsIcon from '@mui/icons-material/EmojiEvents'; import DoDisturbIcon from '@mui/icons-material/DoDisturb'; +import BackspaceIcon from '@mui/icons-material/Backspace'; +import AddCircleIcon from '@mui/icons-material/AddCircle'; function showError(error) { alert("Something went wrong. \n" + error); @@ -44,6 +46,10 @@ function Match(props){ showError("No team selected"); return; } + // if(props.match.winnerId === teamId){ + // showError("Team already won"); + // return; + // } let formData = new FormData(); formData.append("winnerId",teamId); let body = new URLSearchParams(formData); @@ -66,13 +72,27 @@ function Match(props){ return ( <> {/* Team 1 (Winner-status?) (Team name) */} -
  • - {team1Name} +
  • + + + {team1Name} + + {/* */} + + {/* */} +
  •  
  • {/* Team 2 (Winner-status?) (Team name) */} -
  • - {team2Name} +
  • + + + {team2Name} + + {/* */} + + {/* */} +
  •  
  • diff --git a/src/client/src/components/tournamentBracket.css b/src/client/src/components/tournamentBracket.css index 30a9c4e..b80c01a 100644 --- a/src/client/src/components/tournamentBracket.css +++ b/src/client/src/components/tournamentBracket.css @@ -25,30 +25,43 @@ /* * General Styles */ - body{ + /* body{ font-family:sans-serif; font-size:small; padding:10px; line-height:1.4em; + } */ + + .teamName{ + max-width: 5vw; + overflow: hidden; + word-wrap: none; } li.game{ padding-left:20px; } - li.game > span{ + .winnerTrophy{ visibility: hidden; } - - li.game.winner{ + li.game > .removeWinner{ + display: none; + } + + li.game.winner > .removeWinner{ + display:inline-flex; + } + + .teamName.winner{ font-weight:bold; } - li.game.winner > span{ + li.game.winner > div.winnerTrophy{ visibility: visible; } - li.game span{ + /* li.game .winnerTrophy{ float:right; margin-right:5px; - } + } */ li.game-top{ border-bottom:1px solid #aaa; }