Last active
May 14, 2018 16:38
-
-
Save khattab88/bb255b9ed007ea899e2d298ca1912eb0 to your computer and use it in GitHub Desktop.
my first ui component
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<title>Pig Game</title> | |
<link href="https://fonts.googleapis.com/css?family=Lato:300,300i,400" rel="stylesheet"> | |
<link href="https://unpkg.com/ionicons@4.0.0/dist/css/ionicons.min.css" rel="stylesheet" /> | |
<link rel="stylesheet" href="css/reset.css"> | |
<link rel="stylesheet" href="css/grid.css"> | |
<link rel="stylesheet" href="css/style.css"> | |
</head> | |
<body> | |
<div class="main"> | |
<div class="new-game control"> | |
<i class="icon ion-md-add-circle-outline"></i> New Game | |
</div> | |
<div class="roll-dice control"> | |
<i class="icon ion-md-sync"></i> Roll Dice | |
</div> | |
<div class="hold control"> | |
<i class="icon ion-md-pause"></i> Hold | |
</div> | |
<div class="row clearfix"> | |
<div class="col span_1_of_2 player-box player1"> | |
<div class="row"> | |
<div class="col span_1_of_3"> </div> | |
<div class="col span_1_of_3"> | |
<div class="player-name"> | |
Player 1 | |
</div> | |
</div> | |
<div class="col span_1_of_3"> | |
<div class="active"></div> | |
</div> | |
</div> | |
<div class="score">20</div> | |
<div class="current-score-box"> | |
<div>Current</div> | |
<div class="current-score">6</div> | |
</div> | |
</div> | |
<div class="col span_1_of_2 player-box player2"> | |
<div class="row"> | |
<div class="col span_1_of_3"> </div> | |
<div class="col span_1_of_3"> | |
<div class="player-name"> | |
Player 2 | |
</div> | |
</div> | |
<div class="col span_1_of_3"> | |
<div class="active hidden"></div> | |
</div> | |
</div> | |
<div class="score">35</div> | |
<div class="current-score-box"> | |
<div>Current</div> | |
<div class="current-score">4</div> | |
</div> | |
</div> | |
</div> | |
</div> | |
</body> | |
</html> |
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
/* html5reset.css - 01/11/2011 */ | |
html, body, div, span, object, iframe, | |
h1, h2, h3, h4, h5, h6, p, blockquote, pre, | |
abbr, address, cite, code, | |
del, dfn, em, img, ins, kbd, q, samp, | |
small, strong, sub, sup, var, | |
b, i, | |
dl, dt, dd, ol, ul, li, | |
fieldset, form, label, legend, | |
table, caption, tbody, tfoot, thead, tr, th, td, | |
article, aside, canvas, details, figcaption, figure, | |
footer, header, hgroup, menu, nav, section, summary, | |
time, mark, audio, video { | |
margin: 0; | |
padding: 0; | |
border: 0; | |
outline: 0; | |
font-size: 100%; | |
vertical-align: baseline; | |
background: transparent; | |
} | |
body { | |
line-height: 1; | |
} | |
article,aside,details,figcaption,figure, | |
footer,header,hgroup,menu,nav,section { | |
display: block; | |
} | |
nav ul { | |
list-style: none; | |
} | |
blockquote, q { | |
quotes: none; | |
} | |
blockquote:before, blockquote:after, | |
q:before, q:after { | |
content: ''; | |
content: none; | |
} | |
a { | |
margin: 0; | |
padding: 0; | |
font-size: 100%; | |
vertical-align: baseline; | |
background: transparent; | |
} | |
/* change colours to suit your needs */ | |
ins { | |
background-color: #ff9; | |
color: #000; | |
text-decoration: none; | |
} | |
/* change colours to suit your needs */ | |
mark { | |
background-color: #ff9; | |
color: #000; | |
font-style: italic; | |
font-weight: bold; | |
} | |
del { | |
text-decoration: line-through; | |
} | |
abbr[title], dfn[title] { | |
border-bottom: 1px dotted; | |
cursor: help; | |
} | |
table { | |
border-collapse: collapse; | |
border-spacing: 0; | |
} | |
/* change border colour to suit your needs */ | |
hr { | |
display: block; | |
height: 1px; | |
border: 0; | |
border-top: 1px solid #cccccc; | |
margin: 1em 0; | |
padding: 0; | |
} | |
input, select { | |
vertical-align: middle; | |
} |
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
html, | |
body { | |
font-family: 'Lato', sans-serif; | |
background-color: #f3f3f3; | |
color: #333; | |
font-size: 20px; | |
} | |
.clearfix { | |
overflow: auto; | |
} | |
.clearfix::after { | |
content: ""; | |
clear: both; | |
display: table; | |
} | |
.hidden { | |
display: none; | |
} | |
.main { | |
width: 80%; | |
min-height: 75vh; | |
margin-top: 3%; | |
margin-left: 10%; | |
position: relative; | |
} | |
.control { | |
border: 1px solid #ccc; | |
position: absolute; | |
text-align: center; | |
text-transform: uppercase; | |
padding: 2px; | |
border-radius: 5px; | |
cursor: default; | |
background-color: rgba(0, 0, 0, 0.2); | |
transition: background-color 0.2s; | |
border: 1px solid #ccc; | |
} | |
.control:hover { | |
background-color: rgba(0, 0, 0, 0.1); | |
border: 1px solid #999; | |
} | |
.new-game { | |
top: 7%; | |
left: 41%; | |
width: 15vw; | |
} | |
.roll-dice { | |
top: 70%; | |
left: 43%; | |
width: 150px; | |
} | |
.hold { | |
top: 85%; | |
left: 45.5%; | |
width: 100px; | |
} | |
.player-box { | |
padding-top: 75px; | |
} | |
.player1 { | |
background-color: #fad9d1; | |
} | |
.player2 { | |
background-color: #d5f0ff; | |
} | |
.player-name { | |
text-transform: uppercase; | |
text-align: center; | |
font-size: 150%; | |
letter-spacing: 3px; | |
} | |
.active { | |
width: 10px; | |
height: 10px; | |
border-radius: 50%; | |
background-color: #ff4757; | |
margin-top: 6%; | |
} | |
.score { | |
width: 50%; | |
margin: 50px 25%; | |
text-align: center; | |
font-size: 350%; | |
font-weight: 300; | |
margin-top: 5vw; | |
color: #2ed573; | |
} | |
.current-score-box { | |
border: 1px solid #ccc; | |
width: 150px; | |
height: 100px; | |
margin: 15% 37%; | |
text-align: center; | |
background-color: #ff4757; | |
padding-top: 15px; | |
} | |
.current-score { | |
font-weight: 300; | |
font-size: 200%; | |
margin-top: 1vw; | |
color: #fff; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment