-
Notifications
You must be signed in to change notification settings - Fork 5k
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
moyo header task solution #3407
Open
arturgorniak
wants to merge
8
commits into
mate-academy:master
Choose a base branch
from
arturgorniak:develop
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 6 commits
Commits
Show all changes
8 commits
Select commit
Hold shift + click to select a range
6b821cc
add test solution
arturgorniak 5dadb73
add test solution
arturgorniak e43245b
final changes
arturgorniak e71aa9f
readme
arturgorniak 14f50a8
implementing requested changes
arturgorniak a3a21b8
final changes
arturgorniak 52d8e65
add box shadow
arturgorniak 661b3df
add box shadow
arturgorniak 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
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
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
Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -9,6 +9,45 @@ | |||||||||||||||||||||||||
<link rel="stylesheet" href="./style.css"> | ||||||||||||||||||||||||||
</head> | ||||||||||||||||||||||||||
<body> | ||||||||||||||||||||||||||
<h1>Moyo header</h1> | ||||||||||||||||||||||||||
<header class="header"> | ||||||||||||||||||||||||||
<a href="#home" class="logo__link"> | ||||||||||||||||||||||||||
<img | ||||||||||||||||||||||||||
src="./images/logo.png" | ||||||||||||||||||||||||||
alt="Moyo Header Logo" | ||||||||||||||||||||||||||
> | ||||||||||||||||||||||||||
</a> | ||||||||||||||||||||||||||
<nav class="nav"> | ||||||||||||||||||||||||||
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. When you have repeated tags there is no need for empty lines between them, for example: <ul>
<li></li>
<li></li>
<li></li>
<li></li>
</ul> |
||||||||||||||||||||||||||
<ul class="nav__list"> | ||||||||||||||||||||||||||
<li class="nav__item"> | ||||||||||||||||||||||||||
<a href="#apple" class="nav__link is-active">Apple</a> | ||||||||||||||||||||||||||
</li> | ||||||||||||||||||||||||||
<li class="nav__item"> | ||||||||||||||||||||||||||
<a href="#samsung" class="nav__link">Samsung</a> | ||||||||||||||||||||||||||
</li> | ||||||||||||||||||||||||||
<li class="nav__item"> | ||||||||||||||||||||||||||
<a href="#smartphones" class="nav__link">Smartphones</a> | ||||||||||||||||||||||||||
</li> | ||||||||||||||||||||||||||
<li class="nav__item"> | ||||||||||||||||||||||||||
<a | ||||||||||||||||||||||||||
href="#laptops" | ||||||||||||||||||||||||||
class="nav__link" | ||||||||||||||||||||||||||
data-qa="hover">Laptops & Computers | ||||||||||||||||||||||||||
</a> | ||||||||||||||||||||||||||
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. Should be:
Suggested change
|
||||||||||||||||||||||||||
</li> | ||||||||||||||||||||||||||
<li class="nav__item"> | ||||||||||||||||||||||||||
<a href="#gadgets" class="nav__link">Gadgets</a> | ||||||||||||||||||||||||||
</li> | ||||||||||||||||||||||||||
<li class="nav__item"> | ||||||||||||||||||||||||||
<a href="#tablets" class="nav__link">Tablets</a> | ||||||||||||||||||||||||||
</li> | ||||||||||||||||||||||||||
<li class="nav__item"> | ||||||||||||||||||||||||||
<a href="#photo" class="nav__link">Photo</a> | ||||||||||||||||||||||||||
</li> | ||||||||||||||||||||||||||
<li class="nav__item"> | ||||||||||||||||||||||||||
<a href="#video" class="nav__link">Video</a> | ||||||||||||||||||||||||||
</li> | ||||||||||||||||||||||||||
</ul> | ||||||||||||||||||||||||||
</nav> | ||||||||||||||||||||||||||
</header> | ||||||||||||||||||||||||||
</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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,76 @@ | ||
@import url("https://fonts.googleapis.com/css2?family=Roboto:wght@500&display=swap"); | ||
|
||
:root { | ||
--light-blue: #00acdc; | ||
--black: #000; | ||
} | ||
|
||
html { | ||
font-family: "Roboto", sans-serif; | ||
} | ||
|
||
body { | ||
margin: 0; | ||
} | ||
|
||
.header { | ||
position: relative; | ||
padding: 0 50px; | ||
display: flex; | ||
justify-content: space-between; | ||
align-items: center; | ||
} | ||
|
||
.nav { | ||
display: flex; | ||
} | ||
|
||
.logo__link { | ||
display: flex; | ||
} | ||
|
||
.nav__list { | ||
display: flex; | ||
list-style: none; | ||
margin: 0; | ||
padding: 0; | ||
} | ||
|
||
.nav__item { | ||
margin-right: 20px; | ||
} | ||
|
||
.nav__item:last-child { | ||
margin-right: 0; | ||
} | ||
|
||
.nav__link { | ||
position: relative; | ||
display: flex; | ||
align-items: center; | ||
font-size: 12px; | ||
line-height: 15px; | ||
padding: 22px 0; | ||
text-transform: uppercase; | ||
color: var(--black); | ||
text-decoration: none; | ||
} | ||
|
||
.nav__link:hover { | ||
color: var(--light-blue); | ||
} | ||
|
||
.nav__link.is-active { | ||
color: var(--light-blue); | ||
} | ||
|
||
.nav__link.is-active::after { | ||
position: absolute; | ||
bottom: 0; | ||
content: ""; | ||
display: block; | ||
width: 100%; | ||
height: 4px; | ||
border-radius: 8px; | ||
background-color: var(--light-blue); | ||
} |
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.
Here should be an empty space, this
a
tag is a sibling tonav
, generally the rule is (apart from the exception with repeated tags) that the siblings should have an empty space between them: