-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
create product card #5076
base: master
Are you sure you want to change the base?
create product card #5076
Conversation
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! 😊 There are a few critical issues that need to be addressed before we can approve the pull request. The most important ones are:
- BEM Blocks: The task requires separate files for the
card
andstars
BEM blocks, which is not currently implemented. - SCSS Variables: SCSS variables should be placed in a separate file, which is missing.
- SCSS Compilation: The stylesheet link is pointing to an SCSS file instead of a compiled CSS file. Please ensure the SCSS is compiled and linked correctly.
- Class Name Typo: There's a typo in the class name
card-price__velue
, which should becard-price__value
.
Please address these issues to meet the core requirements of the task. Once these are resolved, your code will be in great shape! Keep up the great 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.
src/index.html
Outdated
<link | ||
rel="stylesheet" | ||
href="./styles/index.scss" |
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 stylesheet link is pointing to an SCSS file (index.scss
). SCSS files need to be compiled to CSS before they can be used in an HTML document. Ensure that the SCSS is compiled to a CSS file and link to that CSS file instead.
src/index.html
Outdated
|
||
<div class="card-price"> | ||
<p class="card-price__title">Price:</p> | ||
<p class="card-price__velue">$2,199</p> |
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.
There is a typo in the class name card-price__velue
. It should be card-price__value
.
src/styles/index.scss
Outdated
color: #616070; | ||
} | ||
|
||
&__velue { |
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.
There is a typo in the class name &__velue
. It should be &__value
to match the corrected class name in the HTML file.
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 addressing the previous issues and aligning your code with the task requirements! 🎉 The BEM blocks for card
and stars
are now correctly separated into their respective SCSS files, and the SCSS variables are organized in a dedicated variables.scss
file. The SCSS files are properly linked in the HTML using the Parcel bundler, and the class name typo has been fixed.
However, there are a few areas for improvement:
- Consider defining the color
#060b35
as an SCSS variable in thevariables.scss
file for consistency. - Ensure that SCSS variables such as
$button-text-color
,$background-button-color
,$second-text-color
,$main-text-color
, and$border-color
are defined in thevariables.scss
file. - Verify that the
stars
block is correctly separated into its own BEM block file and that the HTML structure reflects this separation.
These adjustments will enhance the maintainability and readability of your code. Keep up the great work, and continue to refine your skills! 🚀
✨ Please rate this review in the Platform's notification center. I will be grateful for your feedback! ✨
<div class="stars-rating"> | ||
<div class="stars"> |
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 stars
block should be separated into its own BEM block file as per the task requirements. Ensure that the HTML structure reflects this separation.
display: flex; | ||
flex-direction: column; | ||
width: 200px; | ||
border: 1px solid $border-color; |
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.
Ensure that the SCSS variable $border-color
is defined in a separate variables file as per the task requirements.
font-weight: 500; | ||
line-height: 18px; | ||
margin-bottom: 4px; | ||
color: $main-text-color; |
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.
Ensure that the SCSS variable $main-text-color
is defined in a separate variables file as per the task requirements.
font-size: 10px; | ||
font-weight: 400; | ||
line-height: 14px; | ||
color: $second-text-color; |
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.
Ensure that the SCSS variable $second-text-color
is defined in a separate variables file as per the task requirements.
background-color: $button-text-color; | ||
color: $background-button-color; |
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.
Ensure that the SCSS variables $button-text-color
and $background-button-color
are defined in a separate variables file as per the task requirements.
margin-bottom: 24px; | ||
|
||
&__review { | ||
color: #060b35; |
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.
Consider defining the color #060b35
as an SCSS variable in the separate variables file to maintain consistency and ease of maintenance.
DEMO LINK
TEST REPORT LINK
there 2 BEM blocks
card
andstars
each in their own fileSCSS Nesting is used for
elements
,modifiers
andpseudo-classes
SCSS Variables are used for main values and placed in a separate file
all
stars--N
modifiers work as expected (Highlight firstN
stars)Code follows all the [Code Style Rules ❗️]