generated from WildCodeSchool/create-js-monorepo
-
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.
Merge pull request #14 from WildCodeSchool-2023-09/homeGame
Home game
- Loading branch information
Showing
16 changed files
with
177 additions
and
15 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
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
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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,24 @@ | ||
import React from "react"; | ||
import { Link } from "react-router-dom"; | ||
import PropTypes from "prop-types"; | ||
|
||
function ListGames({ games }) { | ||
return ( | ||
<div className="all-game-list"> | ||
<h2 className="game-available">Jeux disponibles</h2> | ||
<div className="game-list"> | ||
{games.map((e) => ( | ||
<Link to={`/games/${e.id}`} key={e.id}> | ||
<img className="size-image-list" src={e.image} alt={e.alt} /> | ||
</Link> | ||
))} | ||
</div> | ||
</div> | ||
); | ||
} | ||
|
||
ListGames.propTypes = { | ||
data: PropTypes.array.isRequired, | ||
}.isRequired; | ||
|
||
export default ListGames; |
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
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,29 @@ | ||
import React from "react"; | ||
import { useLoaderData, Link } from "react-router-dom"; | ||
import LeaderBoard from "../components/LeaderBoard/LeaderBoard"; | ||
|
||
function InfoGame() { | ||
const info = useLoaderData(); | ||
|
||
return ( | ||
<div className="all-page-info-game"> | ||
<LeaderBoard /> | ||
<div className="container-info-game"> | ||
<img className="info-image" src={info.image} alt={info.alt} /> | ||
<div className="name-info"> | ||
<h2 className="name-game">{info.name}</h2> | ||
<h3 className="detail-game">Détail du jeu:</h3> | ||
<p className="info-game">{info.description}</p> | ||
</div> | ||
|
||
<div className="link-go"> | ||
<Link className="go" to="/tictactoe"> | ||
JOUER | ||
</Link> | ||
</div> | ||
</div> | ||
</div> | ||
); | ||
} | ||
|
||
export default InfoGame; |
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 |
---|---|---|
|
@@ -84,7 +84,6 @@ | |
display: none; | ||
} | ||
} | ||
|
||
.menuBurguerRankingContainer { | ||
.leaderBoardLineContainer { | ||
display: flex; | ||
|
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,20 @@ | ||
.game-available { | ||
color: #ffffff; | ||
margin-left: 16rem; | ||
margin-top: 2rem; | ||
} | ||
.game-list { | ||
display: flex; | ||
flex-direction: row; | ||
justify-content: center; | ||
background-color: #2b2d31; | ||
width: 60rem; | ||
margin: auto; | ||
border-radius: 20px; | ||
margin-top: 2rem; | ||
margin-bottom: 2rem; | ||
} | ||
.size-image-list { | ||
width: 15rem; | ||
margin: 2rem; | ||
} |
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,3 @@ | ||
.container-home { | ||
background-color: #383a40; | ||
} |
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,53 @@ | ||
.all-page-info-game { | ||
display: flex; | ||
flex-direction: row; | ||
} | ||
.container-info-game { | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
margin-top: 8rem; | ||
} | ||
.info-image { | ||
border: solid; | ||
border-width: 22px; | ||
border-radius: 15px; | ||
border-color: #2b2d31; | ||
width: 50rem; | ||
margin: 5rem; | ||
} | ||
.name-info { | ||
background-color: #2b2d31; | ||
color: #ffffff; | ||
width: 50rem; | ||
padding: 2rem; | ||
border-radius: 15px; | ||
} | ||
.name-game { | ||
font-size: 1rem; | ||
} | ||
.detail-game { | ||
font-size: 1rem; | ||
padding: 0; | ||
margin-top: 3rem; | ||
} | ||
.info-game { | ||
background-color: #383a40; | ||
} | ||
.link-go { | ||
display: flex; | ||
} | ||
.go { | ||
background-color: #5865f2; | ||
color: #ffffff; | ||
width: 7rem; | ||
height: 2.5rem; | ||
border-radius: 5px; | ||
display: flex; | ||
align-items: center; | ||
justify-content: center; | ||
margin-left: 39rem; | ||
margin-top: 1rem; | ||
} | ||
@media (max-width: 900px) { | ||
} |
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