Skip to content

Commit

Permalink
Added header for MOYO
Browse files Browse the repository at this point in the history
  • Loading branch information
Iryna Mariiko authored and Iryna Mariiko committed Aug 17, 2024
1 parent dc555a1 commit a53764c
Show file tree
Hide file tree
Showing 7 changed files with 147 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
"@mate-academy/backstop-config": "latest",
"@mate-academy/bemlint": "latest",
"@mate-academy/linthtml-config": "latest",
"@mate-academy/scripts": "^1.7.3",
"@mate-academy/scripts": "^1.9.1",
"@mate-academy/stylelint-config": "latest",
"backstopjs": "6.2.2",
"jest": "^29.7.0",
Expand Down
Binary file added src/font/Roboto-Bold.ttf
Binary file not shown.
Binary file added src/font/Roboto-Medium.ttf
Binary file not shown.
Binary file added src/font/Roboto-Regular.ttf
Binary file not shown.
Binary file added src/images/moyo_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
61 changes: 60 additions & 1 deletion src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,68 @@
name="viewport"
content="width=device-width, initial-scale=1.0"
/>
<link rel="stylesheet" href="style.css">
<link rel="preconnect" href="https://fonts.googleapis.com">
<title>Document</title>
</head>
<body>
Hello, world!
<header class="header">
<a href="#logo">
<img src="/src/images/moyo_1.png" alt="moyo"
class="img">
</a>
<nav class="nav">
<ul class="container">

<li class="nav_list">
<a href="#Apple" id="Apple"
class="a is-active nav_space">Apple
</a>
</li>

<li class="nav_list">
<a href="#Samsung" id="Samsung"
class="is-active a nav_space">Samsung
</a>
</li>

<li class="nav_list">
<a href="#Smartphones" id="Smartphones"
class="is-active a nav_space">Smartphones
</a>
</li>

<li class="nav_list">
<a href="#Laptops&Computers" id="Laptops&Computers"
class="is-active a nav_space" data-qa="hover">Laptops & Computers
</a>
</li>

<li class="nav_list">
<a href="#Gadgets" id="Gadgets"
class="is-active a nav_space">Gadgets
</a>
</li>

<li class="nav_list">
<a href="#Tablets" id="Tablets"
class="is-active a nav_space">Tablets
</a>
</li>

<li class="nav_list">
<a href="#Photo" id="Photo"
class="is-active a nav_space">Photo
</a>
</li>

<li class="nav_list">
<a href="#Video" id="Video"
class="is-active a nav_no_space">Video
</a>
</li>
</ul>
</nav>
</header>
</body>
</html>
87 changes: 86 additions & 1 deletion src/style.css
Original file line number Diff line number Diff line change
@@ -1 +1,86 @@
/* styles go here */
@font-face {
font-family: Roboto;
src: url(/src/font/Roboto-Medium.ttf);
}

.header {
background: #FFF;
display: flex;
position: relative;
align-items: center;
}

.img {
width: 40px;
height: 40px;
margin-top: 10px;
margin-left: 50px;
}

.container {
height: 15px;
padding: 0;
display: flex;
align-items: center;
}

.is-active{
color: #000;
}

.nav {
display: flex;
margin-left: auto;
margin-right: 50px;
text-align: center;
justify-content: space-between;
}

.nav_no_space {
margin-right: 0;
}

.nav_space {
margin-right: 20px;
}

.a {
text-decoration: none;
font-family: Roboto, sans-serif;
font-size: 12px;
line-height: 14.06px;
white-space: nowrap;
max-width: none;
align-items: center;
position: relative;
display: inline-block;
padding: 30px 0;
text-align: center;
text-transform: uppercase;
}

.nav_list {
list-style: none;
text-align: center;
margin: 0;
}

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

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

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

0 comments on commit a53764c

Please sign in to comment.