Skip to content

Part 1 #6

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

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
30 changes: 30 additions & 0 deletions 01-review/excercise/base.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
/* presentational CSS, no answers here -- ignore below this line */
div > div {
font-size: 5rem;
text-align: center;
color: white;
}
.a {
background-color: #fcb10f;
}
.b {
background-color: #801340;
}
.c {
background-color: #4d2975;
}
.d {
background-color: #244479;
}
.e {
background-color: #55b4af;
}
.f {
background-color: rgba(128, 19, 64, 0.7);
}
.g {
background-color: rgba(77, 41, 117, 0.5);
}
.h {
background-color: rgba(252, 177, 15, 0.7);
}
27 changes: 27 additions & 0 deletions 01-review/excercise/ex-1-flex.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
.wrapper {
display: flex;
flex-flow: row wrap;
justify-content: space-between;
align-items: stretch;
}

.wrapper > * {
margin-bottom: 1rem;
}

.a,
.h {
flex-basis: 66%;
}

.b,
.d,
.e,
.f,
.g {
flex-basis: 32%;
}

.c {
flex: 100%;
}
14 changes: 14 additions & 0 deletions 01-review/excercise/ex-1-grid.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
.wrapper {
display: grid;
grid-template-columns: repeat(3, 1fr);
grid-gap: 1rem;
}

.a,
.h {
grid-column: span 2;
}

.c {
grid-column: span 3;
}
24 changes: 24 additions & 0 deletions 01-review/excercise/start.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>Document</title>
<link rel="stylesheet" href="./base.css" />
<link rel="stylesheet" href="./ex-1-flex.css" />
<link rel="stylesheet" href="./ex-1-grid.css" />
</head>
<body>
<div class="wrapper">
<div class="a">A</div>
<div class="b">B</div>
<div class="c">C</div>
<div class="d">D</div>
<div class="e">E</div>
<div class="f">F</div>
<div class="g">G</div>
<div class="h">H</div>
</div>
</body>
</html>