Skip to content

Commit

Permalink
made header Moyo
Browse files Browse the repository at this point in the history
  • Loading branch information
Eduard committed Feb 7, 2024
1 parent cbb1cd7 commit 51d4e26
Show file tree
Hide file tree
Showing 3 changed files with 98 additions and 5 deletions.
6 changes: 3 additions & 3 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

19 changes: 18 additions & 1 deletion src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,25 @@
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>Moyo header</title>
<link rel="stylesheet" href="./style.css">
<link rel="preconnect" href="https://fonts.googleapis.com">
<link rel="preconnect" href="https://fonts.gstatic.com">
<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@500&display=swap" rel="stylesheet">
</head>
<body>
<h1>Moyo header</h1>
<header class="header">
<a href="index.html"><img src="./images/logo.png" alt="logo"></a>
<nav>
<ul>
<li><a class="is-active link">Apple</a></li>
<li><a class="is-active link">Samsung</a></li>
<li><a class="is-active link">Smartphones</a></li>
<li><a class="is-active link" data-qa="hover">Laptops & Computers</a></li>
<li><a class="is-active link">Gadgets</a></li>
<li><a class="is-active link">Tablets</a></li>
<li><a class="is-active link">Photo</a></li>
<li><a class="is-active link">Video</a></li>
</ul>
</nav>
</header>
</body>
</html>
78 changes: 77 additions & 1 deletion src/style.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,79 @@
body {
body, ul, li {
margin: 0;
padding: 0;
box-sizing: border-box;
}

body {
font-family: Roboto, sans-serif;
}

.header {
display: flex;
justify-content: space-between;
align-items: center;
margin: 0 auto;
padding: 0 50px;
}

img {
height: 40px;
width: 40px;
}

nav {
display: flex;
align-items: center;
height: 100%;
}

ul {
display: flex;
list-style-type: none;
}

ul li {
display: inline-block;
margin-left: 20px;
position: relative;
line-height: 60px;
}

.link {
display: block;
position: relative;
width: 100%;
height: 60px;
font-weight: 500;
text-transform: uppercase;
font-size: 12px;
}

.is-active::after {
content: " ";
display: none;
position: absolute;
bottom: 0;
height: 4px;
width: 100%;
background-color: #00ACDC;
border-radius: 8px;
}

.is-active:hover::after {
display: block;
}

.is-active:hover {
color: #00ACDC;
}



@media screen and (max-width: 1024px) {
header {
max-width: 1024px;
}
}


0 comments on commit 51d4e26

Please sign in to comment.