Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reto con interfaz y parte de la lógica del juego #17

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
262 changes: 262 additions & 0 deletions css/main.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,262 @@
/* Colores:
#1A46E5 (azul),
#43D8C9 (verde),
#FFBD11 (amarillo),
#FF89BB (rosado),
#FFFFFF (blanco),
#000000 (negro). */

body{
margin: 0;
padding: 0;
background-color: #FFFFFF ;
}

.container .circle-one{
width: 195px;
height: 195px;
position: absolute;
background-color: #1A46E5;;
border-radius: 100%;
left: -48px;
top: 26px;
}

.container .circle-two{
width: 97px;
height: 97px;
position: absolute;
left: 162px;
top: 16px;
background-color: #1A46E5;
border-radius: 100%;
}

.container .circle-three{
width: 335px;
height: 335px;
position: absolute;
left: 1004px;
top: -222px;
background-color: #1A46E5;
border-radius: 100%;
}

.container .circle-four{
width: 49px;
height: 49px;
position: absolute;
left: 1300px;
top: 99px;
background-color: #1A46E5;
border-radius: 100px;
}

.container .titulo{
text-align: center;
font-family: 'Poppins';
font-style: normal;
font-weight: bold;
font-size: 30px;
line-height: 90px;
margin: 103px 0 103px 0;
}

.container .titulo h1{
margin: 0;
}

.players{
display: flex;
flex-wrap: wrap;
justify-content: space-around;
align-items: center;
text-align: center;
width: 100%;
height: 100%;
}

.players .player1:first-child {
width: 467px;
height: auto;
background-color: #43D8C9;;
border: 3px solid black;
color: white;
border-radius: 20px;
box-sizing: border-box;
}

.players .player1{
width: 467px;
height: auto;
background-color: #FFBD11;
border: 3px solid black;
color: white;
border-radius: 20px;
box-sizing: border-box;
}


.player1 .player-title{
margin: 39px 0 45px 0;
font-family: 'Poppins';
font-weight: bold;
font-style: normal;
font-weight: bold;
font-size: 24px;
}

.player1 .player-progress{
display: flex;
justify-content: space-around;
}

.player1 .player-progress .progress-life{
width: 40%;
}

.player1 .player-progress .progress-life .progress-vida-por-barra{
border: 3px solid #000000;
width: 97%;
height: 50px;
border-radius: 30px;
background-color: #FF89BB;

}

.player1 .player-progress .progress-life .progress-life-por h2{
margin: 0;
font-family: 'Poppins';
font-style: normal;
font-weight: bold;
font-size: 24px;
line-height: 45px;
}

.player1 .player-progress .progress-play{
display: flex;
justify-content: center;
align-items: center;
width: 40%;
}

.player1 .player-progress .progress-play .progress-play-title{
display: flex;
justify-content: center;
width: 120px;
height: 120px;
border-radius: 50%;
background-color: #1A46E5;
box-shadow: black 5px 7px 0 1px;
cursor: pointer;
}

.player1 .player-progress .progress-play .progress-play-title h2{
margin: 0;
align-self: center;
font-family: 'Poppins';
font-weight: bold;
font-style: normal;
font-weight: bold;
font-size: 24px;
}

.figure-container{
display: flex;
justify-content: center;
align-items: center;
width: 370px;
height: 231px;
margin-top: 57px;
border: 3px solid #000000;
background-color: #FFFFFF;
border-radius: 20px;
}

.figure-container img{
width: 209px;
height: 177px;
}

.footer{
width: 100%;
height: auto;
margin-top: 82px;
bottom: 0;
left: 0;
}

.footer .footer-container{
display: flex;
justify-content: flex-end;
align-items: center;
padding-right: 50px;
}

.footer .footer-container h4, p, img{
margin-right: 10px;
}

.modal{
background-color: rgba(0,0,0,.8);
position:fixed;
top:0;
right:0;
bottom:0;
left:0;
opacity:0;
pointer-events:none;
}

.modal-contenido{
display: flex;
justify-content: center;
align-items: center;
background-color: #FFFFFF;
width: 50%;
height: 50%;
padding: 10px 20px;
margin: 10% auto;
position: relative;
}

.modal-contenido .modal-contenido-img{
width: 90%;
height: 90%;
text-align: center;
border-radius: 20px;
}

.modal-contenido .modal-contenido-winner{
width: 70%;
height: 70%;
text-align: center;
justify-self: center;
margin: 10px auto;
color: #000000;
font-family: 'Poppins';
font-weight: bold;
font-style: normal;
font-weight: bold;
font-size: 14px;
}

.modal-contenido .modal-contenido-winner button{
background-color: #1A46E5;;
width: 174px;
height: 48px;
left: 888px;
top: 47px;
border-radius: 40px;
color: #FFFFFF;
font-family: 'Poppins';
font-weight: bold;
font-style: normal;
font-weight: bold;
font-size: 14px;
}

#miModal:target{
opacity:1;
pointer-events:auto;
}
Binary file added img/icons8-github-48.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/icons8-linkedin-2-50.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/personaje1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added img/personaje2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
125 changes: 125 additions & 0 deletions index.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,125 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">

<title>Platzi Game</title>
<link href="https://fonts.googleapis.com/css2?family=Poppins:wght@700&display=swap" rel="stylesheet">
<link rel="stylesheet" href="css/main.css">
</head>
<body>


<main class="container">

<div class="circle-one" ></div>
<div class="circle-two" ></div>
<div class="circle-three" ></div>
<div class="circle-four" ></div>

<div class="titulo">
<h1>Platzi Game</h1>
</div>

<section class="players">

<div class="player1">

<div class="player-title">
<h2>Player 1</h2>
</div>

<section class="player-progress">

<section class="progress-life">
<div class="progress-life-por">
<h2 id="progress-life-por-player1">100%</h2>
</div>

<div class="progress-vida-por-barra" id="progress-life-player1">

</div>
</section>

<section class="progress-play" id="player1">
<div id="player1" class="progress-play-title">
<h2>Play</h2>
</div>
</section>

</section>

<figure class="figure-container" id="figure-container">
<img src="img/personaje1.png" alt="">
</figure>

</div>

<div class="player1">

<div class="player-title">
<h2>Player 2</h2>
</div>

<section class="player-progress">

<section class="progress-life">
<div class="progress-life-por">
<h2 id="progress-life-por-player2">100%</h2>
</div>

<div class="progress-vida-por-barra" id="progress-life-player2" max="100">

</div>

</section>

<section class="progress-play" id="player2">
<div class="progress-play-title">
<h2>Play</h2>
</div>
</section>

</section>

<figure class="figure-container">
<img src="img/personaje2.png" alt="">
</figure>
</div>
</section>
</main>


<div id="miModal" class="modal">

<div class="modal-contenido">

<figure class="modal-contenido-img">
<img id="modal-image" class="modal-image" src="" width="100%" height="100%">
</figure>

<div class="modal-contenido-winner">
<h2>the winner is:</h2>
<h3>Player 1</h3>
<button id="btn-closed">Play again</button>
</div>

</div>

</div>


<footer class="footer">
<div class="footer-container">
<h4>Made by</h4>
<p>@Rijutope06</p>
<a href="https://github.com/Rijutope06" target="_blank"> <img src="img/icons8-github-48.png" width="40px" height="40px" alt="" srcset=""></a>
<a href="https://www.linkedin.com/in/ricardojuniortorresperez/" target="_blank"> <img src="img/icons8-linkedin-2-50.png" width="40px" height="40px" alt="" srcset=""></a>
</div>
</footer>

<script src="js/main.js"></script>

</body>
</html>
Loading