A Pen by Sam Girshovich on CodePen.
Created
February 25, 2021 16:17
-
-
Save samg11/601088a6ed6727765a9107a73abb1be9 to your computer and use it in GitHub Desktop.
Scoreboard
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
<div class="scoreboard"> | |
<div class="score away"> | |
<h3>14</h3> | |
<h5>Patriots</h5> | |
</div> | |
<div class="timeAndQuarter"> | |
<h2>4th</h2> | |
<h3>4:43</h3> | |
</div> | |
<div class="score home"> | |
<h3>24</h3> | |
<h5>Eagles</h5> | |
</div> | |
</div> |
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
@homeTeamColor: rgb(102, 255, 194); | |
@awayTeamColor: rgb(94, 100, 191); | |
* { | |
font-family: Arial; | |
} | |
.scoreboard { | |
display: flex; | |
width: 500px; | |
border-radius: 15%; | |
background-color: average(@homeTeamColor, @awayTeamColor); | |
height: 300px; | |
justify-content: space-between; | |
overflow: hidden; | |
} | |
.score { | |
height: 100%; | |
width: 30%; | |
text-align: center; | |
font-size: 30px; | |
} | |
.timeAndQuarter { | |
text-align: center; | |
} | |
.home{background-color:@homeTeamColor} | |
.away{background-color:@awayTeamColor} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment