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

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

develop #4861

wants to merge 2 commits into from

Conversation

Daniil-102
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 so far! There are a few minor issues that need to be addressed before we can merge your pull request. Please take a look at the comments and make the necessary changes. Keep up the good work! 😀

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

src/index.html Outdated
Comment on lines 34 to 35
src="images/imac.jpeg"
alt="card__image"

Choose a reason for hiding this comment

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

The alt attribute of the img tag should describe the image, not just contain a class name. Try to provide a meaningful description.

src/index.html Outdated
Comment on lines 41 to 42
APPLE A1419 iMac 27" Retina 5K Monoblock (MNED2UA/A)
</h2>

Choose a reason for hiding this comment

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

Consider shortening the text inside the h2 tag. If it's necessary to keep it long, you might want to break it into smaller parts for better readability.

src/index.html Outdated
Comment on lines 47 to 52
<div class="card__stars card__stars--4">
<div class="card__stars-star"></div>
<div class="card__stars-star"></div>
<div class="card__stars-star"></div>
<div class="card__stars-star"></div>
<div class="card__stars-star"></div>

Choose a reason for hiding this comment

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

Using div elements for stars might not be the best choice semantically. It's better to use span elements for such cases.

src/index.html Outdated
Comment on lines 62 to 67
<button
class="card__button"
data-qa="hover"
>
BUY
</button>

Choose a reason for hiding this comment

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

The button element is missing a type attribute. It's a good practice to always include it for accessibility reasons. In this case, the type should be 'button'.

}

.card {
max-width: 200px;

Choose a reason for hiding this comment

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

The max-width property is not necessary here if you already set the width property in the .card__content class. It's better to remove it to avoid confusion.

}

.card {
max-width: 200px;

Choose a reason for hiding this comment

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

The max-width property limits the maximum width of an element, which may lead to unexpected behavior when the parent container is smaller than the max-width. Consider using the width property instead.

display: flex;
flex-direction: column;
box-sizing: border-box;
width: 200px;

Choose a reason for hiding this comment

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

The width property here is redundant because its parent (.card) already has a width set. This can lead to unexpected behavior, especially if the parent width changes in the future.

width: 16px;
height: 16px;
background-image: url('../images/star.svg');
background-size: auto;

Choose a reason for hiding this comment

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

The background-size property should be set to 'cover' to ensure that the background image covers the full area of the div, regardless of the div size.

&__price {
display: flex;
justify-content: space-between;
margin-block: 24px 16px;

Choose a reason for hiding this comment

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

The margin-block property is not widely supported and may not work in all browsers. Consider using the margin property instead.

line-height: 16px;
background: $blue;
border-radius: 5px;
margin: 0 1px;

Choose a reason for hiding this comment

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

The margin property here seems to be used to center the button. A better approach would be to use auto margins or flexbox for centering.

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 your work! 🎉 While there are a few minor improvements suggested, they don't impact the core functionality of your code. Keep up the good work and consider the feedback for future enhancements!

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

href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&display=swap"
rel="stylesheet"
/>

<link
rel="stylesheet"
href="./styles/index.scss"

Choose a reason for hiding this comment

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

The href attribute is linking to a SCSS file. HTML files should link to CSS files instead. Please compile your SCSS to CSS and link to the resulting CSS file.

border: 1px solid #00acdc;

&:hover {
color: $color-blue-accent;

Choose a reason for hiding this comment

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

The color value for the hover state is using a variable ($color-blue-accent), which is good for consistency. However, ensure that this variable is defined in your variables file. If it's not, this could lead to unexpected results.


&:hover {
color: $color-blue-accent;
background-color: $color-white;

Choose a reason for hiding this comment

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

The background-color value for the hover state is using a variable ($color-white), which is good for consistency. However, ensure that this variable is defined in your variables file. If it's not, this could lead to unexpected results.

margin-left: 0;
}

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

Choose a reason for hiding this comment

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

The selector '.stars--0 .stars__star:nth-child(-n + 0)' is redundant because '-n + 0' will not select any elements. Consider removing this rule if it is not needed.

Copy link

@BudnikOleksii BudnikOleksii left a comment

Choose a reason for hiding this comment

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

Looks good 🔥

background-color: #00acdc;
color: #fff;
box-sizing: border-box;
border: 1px solid #00acdc;

Choose a reason for hiding this comment

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

You have a variable for this color, don't forget to use it

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.

3 participants