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 #4797

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

add task solution #4797

wants to merge 9 commits into from

Conversation

yurzxw
Copy link

@yurzxw yurzxw commented Oct 23, 2024

  • DEMO LINK
  • TEST REPORT LINK
  • All component follow BEM and use SCSS
  • repaeted sizes and special colors are put to variables
  • Grid is used for the columns
  • cards are shown in 1, 2, 3 or 4 columns based on screen resolution
  • All changes on :hover are smooth
  • Code follows all the Code Style Rules ❗️

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.

There are several critical issues that need to be addressed, including a syntax error in the grid layout, potential layout issues with scaling and padding, and an undefined mixin. Please resolve these to ensure the functionality and maintainability of the code. Keep up the good work! 😊

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

🔄 Fix the issues, commit the changes, and then re-request my review using the Re-request review button in the Reviewers tab.

Comment on lines +27 to +35
<a
href="#"
class="moyo"
>
<img
src="./images/logo.png"
alt="Moyo"
/>
</a>

Choose a reason for hiding this comment

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

The anchor tag has an href attribute set to '#', which might not be functional. Ensure that this is intentional or replace it with a valid URL if needed.

src/index.html Outdated
Comment on lines 39 to 44
<a
href="#"
class="nav_item__link is-active"
>
Apple
</a>

Choose a reason for hiding this comment

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

The href attribute is set to '#', which might not be functional. Consider providing a valid URL or ensuring this is intentional for navigation purposes.

src/index.html Outdated
Comment on lines 47 to 52
<a
href="#"
class="nav_item__link"
>
Samsung
</a>

Choose a reason for hiding this comment

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

The href attribute is set to '#', which might not be functional. Consider providing a valid URL or ensuring this is intentional for navigation purposes.

src/index.html Outdated
Comment on lines 56 to 61
<a
href="#"
class="nav_item__link"
>
Smartphones
</a>

Choose a reason for hiding this comment

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

The href attribute is set to '#', which might not be functional. Consider providing a valid URL or ensuring this is intentional for navigation purposes.

src/index.html Outdated
Comment on lines 64 to 70
<a
href="#"
class="nav_item__link"
data-qa="nav-hover"
>
Laptops & Computers
</a>

Choose a reason for hiding this comment

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

The href attribute is set to '#', which might not be functional. Consider providing a valid URL or ensuring this is intentional for navigation purposes.

src/index.html Outdated
Comment on lines 416 to 421
<a
href="#"
class="buy"
>
buy
</a>

Choose a reason for hiding this comment

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

The href attribute is set to '#', which might not be functional. Consider providing a valid URL or ensuring this is intentional for navigation purposes.

Comment on lines 10 to 17
width: 166px;
height: 40px;
background-color: #00acdc;
color: #fff;
text-decoration: none;
border-radius: 5px;
margin: 0 16px 16px;
padding: 12px 70px;

Choose a reason for hiding this comment

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

The width is set to 166px and padding is set to 12px 70px. This could cause layout issues as the total width including padding exceeds the specified width, potentially causing overflow or unexpected layout behavior. Consider adjusting the width or padding to ensure consistency.

row-gap: 46px;
padding: 50px 40px;

@include on-all;

Choose a reason for hiding this comment

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

The '@include on-all;' directive is used here, but it's not clear if 'on-all' is defined elsewhere in your SCSS files. Ensure that 'on-all' is a valid mixin or remove this line if it's not needed.

Comment on lines 26 to 28
&:hover {
transition: 0.3s;
transform: scale(1.2);

Choose a reason for hiding this comment

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

The transform: scale(1.2) on hover might cause layout issues by affecting the surrounding elements. Consider using a different approach or ensuring that the surrounding layout can accommodate this scaling without causing overflow or layout shifts.

@@ -0,0 +1,21 @@
@mixin on-all {
@media (min-width: 0) {
grid-template-columns: 1, 1fr;

Choose a reason for hiding this comment

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

There is a syntax error in 'grid-template-columns: 1, 1fr;'. The correct syntax should be 'grid-template-columns: repeat(1, 1fr);' to ensure proper grid layout.

@yurzxw yurzxw marked this pull request as draft October 27, 2024 12:05
@yurzxw yurzxw closed this Oct 27, 2024
@yurzxw yurzxw reopened this Oct 27, 2024
@yurzxw yurzxw marked this pull request as ready for review October 27, 2024 12:35
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.

GJ!
To improve:

  1. The card should decrease as smoothly as it increases
image
  1. Don't need to use position for the menu
image

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 improve your code

src/index.html Outdated
@@ -22,6 +22,404 @@
</head>

<body>
<h1>Catalog</h1>
<div class="moyo_catalog"></div>

Choose a reason for hiding this comment

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

Remove it

Suggested change
<div class="moyo_catalog"></div>

src/index.html Outdated
Comment on lines 37 to 41
<ul class="nav_list">
<li class="nav_item">
<a
href="#"
class="nav_item__link is-active"

Choose a reason for hiding this comment

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

Fix classes everywhere

Suggested change
<ul class="nav_list">
<li class="nav_item">
<a
href="#"
class="nav_item__link is-active"
<ul class="nav__list">
<li class="nav__item">
<a
href="#"
class="nav__link is-active"

src/index.html Outdated
Comment on lines 134 to 137
<div class="card_price">
<p class="card_text">Price:</p>
<p class="card_dollars">$2,199</p>
</div>

Choose a reason for hiding this comment

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

Suggested change
<div class="card_price">
<p class="card_text">Price:</p>
<p class="card_dollars">$2,199</p>
</div>
<div class="card__price">
<p class="card__price--label">Price:</p>
<p class="card__price--value">$2,199</p>
</div>

src/index.html Outdated
</div>
<a
href="#"
class="buy"

Choose a reason for hiding this comment

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

Suggested change
class="buy"
class="card__button"

Comment on lines +265 to +266
</div>
<div

Choose a reason for hiding this comment

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

Add the blank line between the cards

Suggested change
</div>
<div
</div>
<div

Choose a reason for hiding this comment

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

Still not fixed.

Comment on lines +22 to +23
justify-content: space-between;
}

Choose a reason for hiding this comment

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

Suggested change
justify-content: space-between;
}
justify-content: space-between;
padding: 0 50px;
}

Choose a reason for hiding this comment

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

Still not fixed

Comment on lines 49 to 53
.nav {
padding-right: 50px;
top: 0;
bottom: 0;
}

Choose a reason for hiding this comment

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

Suggested change
.nav {
padding-right: 50px;
top: 0;
bottom: 0;
}

.moyo {
display: flex;
justify-content: center;
margin-left: 50px;

Choose a reason for hiding this comment

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

Suggested change
margin-left: 50px;

Choose a reason for hiding this comment

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

Still not fixed

src/index.html Outdated
<li class="nav_item">
<a
href="#"
class="nav_item__link z"

Choose a reason for hiding this comment

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

What is z?

Suggested change
class="nav_item__link z"
class="nav__link"

Comment on lines 61 to 63
.z {
margin-right: 0;
}

Choose a reason for hiding this comment

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

Suggested change
.z {
margin-right: 0;
}

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.

Great work! Consider fixing previous comments

font-size: 14px;
font-weight: 700;
text-align: center;
width: 166px;

Choose a reason for hiding this comment

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

Not fixed

text-align: center;
width: 166px;
height: 40px;
background-color: #00acdc;

Choose a reason for hiding this comment

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

Not fixed

transition: $transition-time;

&:hover {
background-color: #fff;

Choose a reason for hiding this comment

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

Consider creating a variable for the repeating color

margin-right: 4px;
}

.stars--4 .stars__star:nth-child(-n + 4) {

Choose a reason for hiding this comment

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

Consider adding styles for other modifiers

Choose a reason for hiding this comment

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

Still not fixed

border-radius: 5px;
box-sizing: border-box;
width: 200px;
height: 408px;

Choose a reason for hiding this comment

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

Suggested change
height: 408px;

Copy link

@vadiimvooo vadiimvooo left a comment

Choose a reason for hiding this comment

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

Seems like there is no fixes from last comments. Please feel free to ask for help in fe_chat.

Comment on lines +265 to +266
</div>
<div

Choose a reason for hiding this comment

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

Still not fixed.

font-size: 14px;
font-weight: 700;
text-align: center;
width: 166px;

Choose a reason for hiding this comment

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

Still not fixed

text-align: center;
width: 166px;
height: 40px;
background-color: #00acdc;

Choose a reason for hiding this comment

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

Still not fixed

Comment on lines +22 to +23
color: var(--hover-color);
border: 1px solid var(--hover-color);

Choose a reason for hiding this comment

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

Still not fixed

}

:root {
--hover-color: #00acdc;

Choose a reason for hiding this comment

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

Still not fixed

Comment on lines +22 to +23
justify-content: space-between;
}

Choose a reason for hiding this comment

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

Still not fixed

.moyo {
display: flex;
justify-content: center;
margin-left: 50px;

Choose a reason for hiding this comment

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

Still not fixed

margin-right: 4px;
}

.stars--4 .stars__star:nth-child(-n + 4) {

Choose a reason for hiding this comment

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

Still not fixed

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.

5 participants