Skip to content
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

add task solution #4913

Open
wants to merge 3 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
4 changes: 2 additions & 2 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,8 @@ The page should match the design Pixel Perfect: all the sizes, colors and distan

❗️ Replace `<your_account>` with your Github username and copy the links to `Pull Request` description:

- [DEMO LINK](https://<your_account>.github.io/layout_moyo-header/)
- [TEST REPORT LINK](https://<your_account>.github.io/layout_moyo-header/report/html_report/)
- [DEMO LINK](https://priemssonia.github.io/layout_moyo-header/)
- [TEST REPORT LINK](https://priemssonia.github.io/layout_moyo-header/report/html_report/)

❗️ Copy this `Checklist` to the `Pull Request` description after links, and put `- [x]` before each point after you checked it.

Expand Down
95 changes: 94 additions & 1 deletion src/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,105 @@
content="ie=edge"
/>
<title>Moyo header</title>

<link
rel="preconnect"
href="https://fonts.googleapis.com"
/>
<link
rel="preconnect"
href="https://fonts.gstatic.com"
crossorigin="anonymous | use-credentials"
/>
<link
href="https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap"
rel="stylesheet"
/>

<link
rel="stylesheet"
href="./style.css"
/>
</head>
<body>
<h1>Moyo header</h1>
<header class="header">
<div class="logo">
<a href="#">
<img
src="./images/logo.png"
alt="Moyo"
/>
</a>
</div>
<nav class="nav">
<ul class="nav__list">
<li class="nav__item">
<a
class="nav__link is-active"
href="#"
>
APPLE
</a>
</li>
<li class="nav__item">
<a
class="nav__link"
href="#"
>
SAMSUNG
</a>
</li>
<li class="nav__item">
<a
class="nav__link"
href="#"
>
SMARTPHONES
</a>
</li>
<li class="nav__item">
<a
class="nav__link"
data-qa="hover"
href="#"
>
LAPTOPS & COMPUTERS
</a>
</li>
<li class="nav__item">
<a
class="nav__link"
href="#"
>
GADGETS
</a>
</li>
<li class="nav__item">
<a
class="nav__link"
href="#"
>
TABLETS
</a>
</li>
<li class="nav__item">
<a
class="nav__link"
href="#"
>
PHOTO
</a>
</li>
<li class="nav__item">
<a
class="nav__link"
href="#"
>
VIDEO
</a>
</li>
</ul>
</nav>
</header>
</body>
</html>
83 changes: 83 additions & 0 deletions src/style.css
Original file line number Diff line number Diff line change
@@ -1,3 +1,86 @@
html {
box-sizing: border-box;
}

body {
margin: 0;
padding: 0;
font-family: Roboto, sans-serif;
font-size: 12px;
font-weight: 500;
}

.header {
display: flex;
justify-content: space-between;
box-sizing: border-box;
padding-left: 50px;
background-color: rgba(255, 255, 255, 1);
box-shadow: 0 2px 4px 0 rgba(0, 0, 0, 0.05);
}

.logo {
height: 40px;
width: 40px;
margin-top: 10px;
}

.nav {
align-items: center;
display: flex;
margin-right: 50px;
}

.nav__link {
text-decoration: none;
color: rgba(0, 0, 0, 1);
padding: 0;
margin: 0;
font-size: 12px;
height: 60px;
align-items: center;
display: flex;
}

.nav__link:hover {
color: rgba(0, 172, 220, 1);
}

.nav__item {
font-family: Roboto, sans-serif;
font-weight: 500;
margin-left: 20px;
font-size: 12px;
text-transform: uppercase;
color: rgba(0, 0, 0, 1);
text-align: center;
list-style-type: none;
}

.nav__item:first-child {
margin-left: 0;
}

.nav__list {
display: flex;
justify-content: space-between;
align-items: center;
padding: 0;
margin: 0;
}

.nav__link.is-active {
position: relative;
color: rgba(0, 172, 220, 1);
}

.is-active::after {
content: '';
background-color: rgba(0, 172, 220, 1);
height: 4px;
position: absolute;
width: 100%;
left: 0;
bottom: 0;
border-radius: 8px;
}
Loading