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

Develop #5391

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Develop #5391

wants to merge 3 commits into from

Conversation

taniavozniuk
Copy link

Copy link

@mateacademy-ai-mentor mateacademy-ai-mentor left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great job on structuring your HTML! 🌟 While there are some improvements to be made regarding best practices, they don't critically impact the functionality or security of your code. Keep an eye on styling conventions and indentation for future projects to enhance code readability and maintainability! 👍

✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨

Comment on lines +4 to +7
<link
rel="preconnect"
href="https://fonts.gstatic.com"
/>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The attributes in the tag should start each on a new line with 2-space indentation related to the tag to keep the attributes correctly formatted.

src/index.html Outdated
Comment on lines 29 to 106
<header class="header">
<a href="https://www.moyo.ua/ua/">
<img
src="images/logo.png"
alt="Moyo logo"
class="logo"
/>
</a>
<nav>
<ul class="nav">
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/portal_brand/apple_1/"
class="nav__link is-active"
>
Apple
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/telecommunication/smart/samsung/"
class="nav__link"
>
Samsung
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/comp-and-periphery/"
class="nav__link"
>
Smartphones
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/comp-and-periphery/"
class="nav__link"
data-qa="hover"
>
Laptops & Computers
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/gadgets/"
class="nav__link"
>
Gadgets
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/tablet_el_knigi/tablet/"
class="nav__link"
>
Tablets
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/foto_video/photo_video/"
class="nav__link"
>
Photo
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/foto_video/photo_video/"
class="nav__link"
>
Video
</a>
</li>
</ul>
</nav>
</header>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add empty lines between multiline sibling blocks of HTML to improve readability. For example, add an empty line before the

element.

src/index.html Outdated
Comment on lines 38 to 104
<ul class="nav">
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/portal_brand/apple_1/"
class="nav__link is-active"
>
Apple
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/telecommunication/smart/samsung/"
class="nav__link"
>
Samsung
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/comp-and-periphery/"
class="nav__link"
>
Smartphones
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/comp-and-periphery/"
class="nav__link"
data-qa="hover"
>
Laptops & Computers
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/gadgets/"
class="nav__link"
>
Gadgets
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/tablet_el_knigi/tablet/"
class="nav__link"
>
Tablets
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/foto_video/photo_video/"
class="nav__link"
>
Photo
</a>
</li>
<li class="nav__item">
<a
href="https://www.moyo.ua/ua/foto_video/photo_video/"
class="nav__link"
>
Video
</a>
</li>
</ul>

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remember about correct indentation between parent and child elements. The

  • elements should be indented with 2 spaces inside the
      element.

  • src/index.html Outdated
    Comment on lines 40 to 43
    <a
    href="https://www.moyo.ua/ua/portal_brand/apple_1/"
    class="nav__link is-active"
    >

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    The href attribute in the tag should not contain spaces. Instead, use a valid URL or a path that does not include spaces.

    Comment on lines +1 to +5
    *,
    *::before,
    *::after {
    box-sizing: border-box;
    }

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Don't use * selector (it impacts performance). Set styles only for elements that require them. Zeroing out your margins, paddings or other styles with '*' is still inefficient for browser.

    body {
    margin: 0;
    padding: 0;
    font-family: Roboto, Arial, sans-serif;

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Remember to use fallback fonts - alternative font-family in case the main one doesn't work. For example, font-family: Roboto, Arial, sans-serif; should have a generic family name as a fallback, like sans-serif.

    Comment on lines +40 to +45
    ul {
    margin: 0;
    padding: 0;
    list-style-type: none;
    display: flex;
    }

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Don't use tag names for styling (except html and body). Style all elements using .class and if needed with :pseudo-class, pseudo-element and [attribute]. For example, instead of styling ul, use .nav__list.

    Copy link

    @volodymyr-soltys97 volodymyr-soltys97 left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Good job 👍
    Let's make your code better

    src/style.css Outdated
    font-family: Roboto, Arial, sans-serif;
    }

    header {

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Use only class selector

    Suggested change
    header {
    .header {

    src/index.html Outdated
    <ul class="nav">
    <li class="nav__item">
    <a
    href="https://www.moyo.ua/ua/portal_brand/apple_1/"

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    You can fix href everywhere

    Suggested change
    href="https://www.moyo.ua/ua/portal_brand/apple_1/"
    href="#apple"

    src/style.css Outdated
    }

    header {
    background-color: #fff;

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    This color is default

    Suggested change
    background-color: #fff;

    src/style.css Outdated

    header {
    background-color: #fff;
    justify-content: space-between; /* Розподіляє елементи по сторонах */

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Remove all comments, it's redundant here

    Suggested change
    justify-content: space-between; /* Розподіляє елементи по сторонах */
    justify-content: space-between;

    src/style.css Outdated
    }

    .nav__link:hover {
    color: #00acdc;

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Create a variable for repeated color and use it everywhere

    Copy link

    @anastasiiavorobiova anastasiiavorobiova left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Awesome work!


    .is-active {
    position: relative;
    color: #00acdc;

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Suggested change
    color: #00acdc;
    color: var(--primary-color);

    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    None yet
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    4 participants