-
Notifications
You must be signed in to change notification settings - Fork 4.5k
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 #5022
base: master
Are you sure you want to change the base?
Develop #5022
Conversation
Detek-tor
commented
Nov 3, 2024
- DEMO LINK
- TEST REPORT LINK
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for your hard work on this project! 😊 While your code meets most of the task requirements, there are a few critical issues that need to be addressed before we can approve the pull request:
-
CSS Selector Usage: Avoid using the
*
selector for performance reasons as specified in the task checklist. -
File Structure: Each BEM block should have its own separate file. Currently, all styles are in a single CSS file. Please separate the styles for each BEM block into individual files.
-
HTML Formatting: Ensure consistent use of 2 spaces for indentation in your HTML file as per the checklist.
-
CSS Class Naming: Review your class names to ensure they represent the meaning of the content rather than styles or tag names.
-
Semantic HTML: Consider using more semantic HTML elements where possible instead of relying solely on
div
elements.
These changes will help improve the maintainability and performance of your code. Keep up the great work, and I'm confident you'll nail it with these adjustments! 🚀
✨ 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.
src/style.css
Outdated
.stars--1 .stars__star:nth-child(-n + 1) { | ||
width: 16px; | ||
height: 16px; | ||
margin-right: 4px; | ||
background-repeat: no-repeat; | ||
background-position: center; | ||
background-image: url('images/star-active.svg'); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The CSS rules for .stars--1 .stars__star:nth-child(-n + 1)
are repeated for each .stars--X
class with only the nth-child value changing. Consider using a more concise approach to avoid repetition, such as using a common class for active stars and adjusting the number of active stars with JavaScript or a more dynamic CSS approach.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job on implementing the star rating system! 🌟 Your code meets most of the task requirements, and you've done well with the HTML and CSS structure. Here are a few points to consider for improvement:
-
File Structure: Each BEM block should have its own separate file. Currently, all CSS is in a single
style.css
file. Separating them will enhance modularity and maintainability. -
CSS Styling: You've correctly avoided using the
gap
property, as required by the task. -
HTML Structure: The HTML is well-structured with the correct number of
stars
blocks andstars__star
elements, adhering to the task's constraints on class usage. -
CSS Selectors: Excellent use of
background-image
for stars, complying with the task requirements. -
Yellow Stars: You've effectively used container modifiers and pseudo-selectors to add yellow stars without extra classes.
-
Resetting Browser Defaults: Good job resetting the browser's default margin for the
body
.
While the code is approved, please address the file structure issue in future projects to ensure full compliance with task requirements. Keep up the great work and continue learning from these experiences! 🚀
✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨