This repository was archived by the owner on Jan 14, 2024. It is now read-only.
-
-
Notifications
You must be signed in to change notification settings - Fork 609
London class 8/harsheek thanki #267
Open
HThanki
wants to merge
13
commits into
CodeYourFuture:master
Choose a base branch
from
HThanki:ondon-class-8/harsheek-thanki
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
2b525ce
sketelon HTML added
HThanki f6fc45b
HTML images added
HThanki 688be22
font added
HThanki 662adf7
some progress made on CSS grid structure
HThanki 747e615
changes to HTML and CSS grid made
HThanki fa1d144
mobile grid complete. styling needed
HThanki 2b9cfa6
CSS colours updated
HThanki 33a8f46
Starting media queries
HThanki 44c0392
starting media queries
HThanki 4cb3dcb
progress made on desktop view media query
HThanki 85b46a0
Update index.html
HThanki da64074
desktop media queries updated
HThanki b9ebce0
media queries for 2 breakpoints added
HThanki File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
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 hidden or 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 |
---|---|---|
@@ -1,16 +1,65 @@ | ||
<!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"> | ||
<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>Responsive Cake webpage</title> | ||
<!-- Add a link to your css file here --> | ||
</head> | ||
|
||
<body> | ||
<link rel="preconnect" href="https://fonts.googleapis.com" /> | ||
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin /> | ||
<link | ||
href="https://fonts.googleapis.com/css2?family=Rochester&display=swap" | ||
rel="stylesheet" | ||
/> | ||
|
||
<link rel="stylesheet" href="style.css" /> | ||
</head> | ||
|
||
<body> | ||
<!-- Add your markup here --> | ||
</body> | ||
<header> | ||
<img src="images/piece-of-cake.png" /> | ||
<p>The best cakes in town delivered to your door</p> | ||
<div class="burger"> | ||
<img src="images/burger-menu.png" /> | ||
</div> | ||
</header> | ||
<nav> | ||
<ul> | ||
<li><a href="#">HOME</a></li> | ||
<li><a href="#">CAKES</a></li> | ||
<li><a href="#">ORDERING</a></li> | ||
<li><a href="#">LESSONS</a></li> | ||
<li><a href="#">ABOUT</a></li> | ||
</ul> | ||
</nav> | ||
|
||
</html> | ||
<main> | ||
<section class="welcome"> | ||
<div class="welcome-text"> | ||
<h1>Welcome</h1> | ||
<p> | ||
Welcome to Harsheek's Cakes, your favourite online cake shop! | ||
Established in 1969, we bake and serve a tantalising selection of | ||
traditional and affordable cakes and pies that brighten everyone’s | ||
mood! Grab some cakes your family and friends for every occasion. | ||
</p> | ||
</div> | ||
<div class="welcome-image"> | ||
<img src="images/birthday-cake.png" /> | ||
</div> | ||
</section> | ||
<section class="products"> | ||
<div class="product-img"><img src="images/apple-pie.png" /></div> | ||
<div class="product-img"><img src="images/candle-cake.png" /></div> | ||
<div class="product-img"><img src="images/cupcake.png" /></div> | ||
<div class="product-img"><img src="images/donut.png" /></div> | ||
</section> | ||
</main> | ||
<footer> | ||
<img src="images/burger-menu.png" /> | ||
</footer> | ||
</body> | ||
</html> |
This file contains hidden or 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 |
---|---|---|
@@ -1 +1,222 @@ | ||
/* Add your styling here */ | ||
|
||
body { | ||
font-family: "Rochester", cursive; | ||
-webkit-font-smoothing: antialiased; | ||
color: black; | ||
background-color: #fff1e6; | ||
margin: 0; | ||
text-align: center; | ||
/* padding: 10px; */ | ||
} | ||
|
||
main { | ||
padding: 1em 3em; | ||
display: grid; | ||
grid-gap: 10px; | ||
grid-template-columns: repeat(2, 1fr); | ||
|
||
grid-template-areas: | ||
"header header" | ||
"welcome welcome" | ||
"products products" | ||
"footer footer"; | ||
} | ||
|
||
header, | ||
footer, | ||
.products img { | ||
background-color: #eddcd2; | ||
} | ||
|
||
header { | ||
display: grid; | ||
grid-template-columns: 1fr 1fr; | ||
grid-template-areas: | ||
"image burger" | ||
"image best-cakes"; | ||
} | ||
|
||
header img { | ||
grid-area: image; | ||
width: 60%; | ||
padding: 20px; | ||
} | ||
|
||
header p { | ||
grid-area: best-cakes; | ||
text-align: right; | ||
padding-right: 1em; | ||
} | ||
|
||
nav { | ||
display: grid; | ||
justify-items: end; | ||
padding-right: 1em; | ||
} | ||
|
||
nav img { | ||
grid-area: burger; | ||
width: 15%; | ||
padding-top: 40px; | ||
} | ||
|
||
nav ul { | ||
display: none; | ||
} | ||
|
||
h1 { | ||
font-size: 4em; | ||
font-weight: bold; | ||
margin-top: 0; | ||
text-align: left; | ||
} | ||
|
||
p { | ||
font-size: 30px; | ||
text-align: left; | ||
} | ||
|
||
.welcome { | ||
grid-area: welcome; | ||
padding-bottom: 30px; | ||
} | ||
|
||
.welcome img { | ||
padding: 40px 80px; | ||
width: 50%; | ||
border: 3px solid black; | ||
border-radius: 20px; | ||
background-color: #ddbea9; | ||
} | ||
|
||
.products { | ||
grid-area: products; | ||
display: grid; | ||
grid-template-columns: 1fr 1fr; | ||
grid-gap: 2rem; | ||
} | ||
|
||
.products img { | ||
border: 3px solid black; | ||
border-radius: 20px; | ||
width: 100%; | ||
padding: 10px; | ||
} | ||
Comment on lines
+100
to
+105
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. consider using relative units instead of hardcoding in px? |
||
|
||
footer { | ||
grid-area: footer; | ||
justify-items: start; | ||
|
||
border: 2px solid black; | ||
} | ||
|
||
footer img { | ||
width: 200px; | ||
} | ||
|
||
@media screen and (min-width: 540px) { | ||
main { | ||
grid-template-columns: repeat (4, 1fr); | ||
|
||
grid-area: "header header header header" "nav nav nav nav" | ||
"image image welcome welcome" "products products products products" | ||
"footer footer footer footer"; | ||
Comment on lines
+122
to
+124
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. improve readability by keeping rows at separate lines |
||
} | ||
|
||
header { | ||
display: grid; | ||
grid-template-columns: 1fr 1fr; | ||
grid-template-areas: "image best-cakes"; | ||
} | ||
|
||
header img { | ||
grid-area: image; | ||
width: 60%; | ||
padding: 20px; | ||
} | ||
|
||
header p { | ||
grid-area: best-cakes; | ||
align-self: end; | ||
} | ||
|
||
.welcome-text { | ||
display: welcome; | ||
} | ||
|
||
.welcome-image { | ||
display: image; | ||
} | ||
|
||
.burger { | ||
display: none; | ||
} | ||
|
||
header img { | ||
width: 100px; | ||
} | ||
|
||
nav ul { | ||
display: nav; | ||
display: flex; | ||
list-style: none; | ||
font-size: 30px; | ||
background-color: #eddcd2; | ||
} | ||
|
||
nav ul li { | ||
/* padding: 0px 5px; */ | ||
margin: 0px 10px; | ||
background-color: #ddbea9; | ||
} | ||
|
||
a { | ||
text-decoration: none; | ||
color: black; | ||
} | ||
|
||
a:visited { | ||
text-decoration: none; | ||
color: black; | ||
} | ||
|
||
a:hover { | ||
text-decoration: none; | ||
color: white; | ||
} | ||
|
||
.welcome { | ||
display: flex; | ||
flex-direction: row-reverse; | ||
} | ||
|
||
.welcome-text { | ||
margin-left: 100px; | ||
} | ||
|
||
.welcome-image { | ||
display: grid; | ||
align-items: center; | ||
margin: 10px; | ||
} | ||
|
||
.products { | ||
display: flex; | ||
} | ||
|
||
.products img { | ||
width: 70%; | ||
} | ||
|
||
footer img { | ||
display: none; | ||
} | ||
} | ||
|
||
@media screen and (min-width: 900px) { | ||
nav ul li { | ||
margin: 0px 40px; | ||
background-color: #ddbea9; | ||
} | ||
} | ||
Comment on lines
+217
to
+222
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. A well structured original work, well done! I see well coding practices and use of responsive media queries with confidence. Keep good work going! |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remember to provide
alt
to improve accessibility