Skip to content

add task solution - #6439

Open
pparys93 wants to merge 3 commits into
mate-academy:masterfrom
pparys93:develop
Open

pparys93 wants to merge 3 commits into
mate-academy:masterfrom
pparys93:develop

Conversation

@pparys93

@pparys93 pparys93 commented Sep 7, 2026

Copy link
Copy Markdown

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

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Review Summary

I am requesting changes because there is a clear requirement violation: the hover title color #34568b is hardcoded in src/blocks/card.scss (around lines 59–61), which breaks the rule that repeated/special colors must be stored in variables [CHECKLIST ITEM #2]. Please move this color into src/utils/_variables.scss (e.g., $color-title-hover: #34568b) and reference the variable in card.scss.

Additionally, the requirement states the card must scale by 20% on hover without affecting neighboring cards. While you use transform: scale(1.2) and a 300ms transition, there’s no explicit isolation to guarantee neighbors aren’t impacted. To fix this, add safeguards such as transform-origin: center top; and will-change: transform; on .card, and ensure overflow/clipping isn’t causing visual interference (e.g., overflow: visible; on .card or the grid container). These adjustments will prevent reflow/overlap during hover.

Everything else looks solid: BEM structure, grid breakpoints, required data-qa attributes, and transitions are correctly implemented. Once the color variable and hover isolation are addressed, the solution should fully meet the requirements.


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

Important

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

Tip

If you have any comments about this review, please leave a message in the Add a comment section below and mention me with the @mateacademy-ai-mentor tag3.
I will read your message during my next review of your pull request. Please do not reply directly to my comments, as that feature is not supported yet.

Caution

Do not close the pull request until the review is complete. Closing it early can lead to unexpected behavior and disrupt the review process.

Footnotes

  1. Rate AI review example ↩

  2. Re-request AI review example ↩

  3. Add AI review comments example ↩

Comment thread src/blocks/card.scss
Comment on lines +24 to +29
padding-left: 19px;
padding-right: 19px;

&-image {
width: 160px;
height: 134px;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Checklist/requirement violation: The header nav links must have color #060b35. The variable $color-font-major is set to #060b35 in variables, and header__menu-link uses color: $color-font-major which is correct. However, ensure there are no remaining old data-qa attributes in SCSS (task required removing old data-qa attributes). The SCSS files themselves don't contain data-qa attributes so this is fine. No code change required here unless HTML contains old attributes (check HTML).

Comment thread src/blocks/card.scss
Comment on lines +32 to +39
}

&__description {
display: flex;
flex-direction: column;

&-code {
font-size: 10px;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Requirement: Navigation link hover color must change to #00acdc and the transition should be 300ms. You use transition: color 300ms and color on :hover is set to $color-font-hover which equals #00acdc in variables — this matches the requirement. No change needed.

Comment thread src/blocks/card.scss
Comment on lines +42 to +55
color: $color-font-minor;
margin-top: 4px;
}
}

&__title {
font-size: 12px;
font-weight: 500;
line-height: 18px;
margin-top: 40px;
display: -webkit-box;
-webkit-line-clamp: 2;
-webkit-box-orient: vertical;
overflow: hidden;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Requirement: Add class is-active to first nav link and style it. The SCSS includes styling for .header__menu-link.is-active which sets color and ::after indicator; transition and color variable are correct. Ensure HTML includes the is-active class on the first link (this is an HTML change, not here).

Comment thread src/blocks/card.scss
Comment on lines +11 to +16
transition: transform 300ms;

&:hover {
transform: scale(1.2);
z-index: 2;
position: relative;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Card hover requirement: The card scale transition must be smooth during 300ms and neighboring cards should not be affected when hovered. You use transform: scale(1.2) with transition: transform 300ms and set position: relative and z-index:2 on hover. That generally prevents layout shifts; however the card root has display:flex and fixed width 200px which is fine. To fully avoid affecting neighbors in a grid you may also need to ensure the grid container doesn't reflow (e.g., by allowing overflow visible). This is not directly controlled here in card.scss; check container styles in index.scss (catalog uses grid with justify-content:center) — consider adding 'overflow: visible' to .card or to the grid items if you notice neighbor shifting. Suggest adding overflow: visible; to .card to guarantee neighbors unaffected.

Comment thread src/blocks/card.scss
Comment on lines +57 to +62
transition: color 300ms;
}

&:hover &__title {
color: #34568b;
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Exact requirement: On hover the card title color must change using selector .card:hover .card__title. Your selector &:hover &__title compiles to .card:hover .card__title — this is correct. The transition duration for color is set to 300ms on the title — also correct.

Comment thread src/blocks/header.scss
Comment on lines +24 to +29
&__menu-link {
display: flex;
align-items: center;
justify-content: center;
height: 60px;
color: $color-font-major;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

The header markup requirement: navigation links must have color #060b35 (variable $color-font-major is set to #060b35 in variables), and the first link should have class is-active. The SCSS sets .header__menu-link color to $color-font-major which is correct, and .header__menu-link.is-active uses $color-font-hover for active state. However this comment is informational — no code fix needed in this file.

Comment thread src/blocks/header.scss
Comment on lines +13 to +16
height: 40px;
}

&__menu {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Requirement: Increase the hovered card by 20% and ensure neighboring cards are not affected. You're using transform: scale(1.2) on .card:hover (line 14), and position: relative; z-index: 2; (lines 15-16) which prevents overlap affecting layout. This is correct. No change needed.

Comment thread src/blocks/header.scss
Comment on lines +3 to +56
.header {
display: flex;
align-items: center;
justify-content: space-between;
width: 100%;
padding: 0 50px;
box-sizing: border-box;

&__logo {
width: 40px;
height: 40px;
}

&__menu {
display: flex;
list-style: none;
padding: 0;
margin: 0;
gap: 20px;
}

&__menu-link {
display: flex;
align-items: center;
justify-content: center;
height: 60px;
color: $color-font-major;
font-size: 12px;
font-weight: 500;
transition: color 300ms;
text-decoration: none;
text-transform: uppercase;
position: relative;
}

&__menu-link:hover {
color: $color-font-hover;
}

&__menu-link.is-active {
color: $color-font-hover;

&::after {
content: '';
position: absolute;
left: 0;
bottom: 0;
width: 100%;
height: 4px;
border-radius: 8px;
background-color: $color-font-hover;
}
}
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Checklist item #1: "All components follow BEM and use SCSS" — blocks use BEM naming in SCSS. However confirm that HTML structure uses header__nav and header__menu-item etc. (HTML provided uses these; if any element naming deviates, ensure BEM in HTML and SCSS match). This is informational.

Comment thread src/blocks/stars.scss
Comment on lines +13 to +14

@for $i from 1 through 5 {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This implements hover scaling with transform: scale(1.2) but there is no rule ensuring neighboring grid items won’t be affected. To guarantee neighbors are not affected you should set transform-origin (for example center top) and consider adding will-change: transform; also confirm grid/container settings prevent reflow when an item scales (index.scss uses justify-content: center which can produce shifts). Without these adjustments the scaled card can push or overlap neighbors, violating the requirement "neighboring cards should not be affected".

Comment thread src/blocks/stars.scss
background-position: center;
background-repeat: no-repeat;
width: 16px;
height: 16px;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

The transition on the .card is transition: transform 300ms; which covers the scale but the &:hover &__title rule relies on color transition defined on .card__title (good). For clarity and completeness you could include color transition in the .card rule or keep as-is; no functional error here but consider centralizing hover transitions to ensure all required transitions are 300ms.

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

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Review Summary

I am requesting changes because one explicit checklist requirement remains unmet: adding will-change: transform; to .card to ensure the 20% hover scale does not affect neighboring cards. This was previously requested and is part of the hover isolation safeguards alongside transform-origin: center top, position: relative/z-index on hover, and container overflow: visible.

Critical issues to fix:

  • src/blocks/card.scss: Add will-change: transform; to the base .card rule (near the existing transform-origin and transition). This helps the browser optimize the transform and prevents unintended repaints that could visually impact adjacent cards. [CHECKLIST ITEM #5]

What’s done well:

  • $color-title-accent: #34568b; is defined in src/utils/_variables.scss and used for the title hover color as required.
  • Button hover colors map correctly via variables to #fff background and #00acdc text.
  • Grid container overflow is set to overflow: visible and transform-origin: center top is correctly applied.

Make that small addition to .card, and this will fully meet the requirements.


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

Important

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

Tip

If you have any comments about this review, please leave a message in the Add a comment section below and mention me with the @mateacademy-ai-mentor tag3.
I will read your message during my next review of your pull request. Please do not reply directly to my comments, as that feature is not supported yet.

Caution

Do not close the pull request until the review is complete. Closing it early can lead to unexpected behavior and disrupt the review process.

Footnotes

  1. Rate AI review example ↩

  2. Re-request AI review example ↩

  3. Add AI review comments example ↩

Comment thread src/blocks/card.scss
}

&:hover &__title {
color: $color-title-accent;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

This violates checklist item #2: the hover title color was required to be moved to variables. In card.scss the title hover color uses the variable $color-title-accent — however the previous review demanded the color must be placed in the variables file. Confirm that $color-title-accent: #34568b; exists in src/utils/_variables.scss (this is required). If it is missing there, move the hardcoded color into that file. If present, no change needed. (Check presence in _variables.scss).

Comment thread src/blocks/card.scss
border-radius: 5px;
color: $color-font-major;
transition: transform 300ms;
transform-origin: center top;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

The card hover scaling must increase the card by 20% while not affecting neighboring cards. Although card.scss uses transform: scale(1.2) with transform-origin: center top and a 300ms transition, ensure the grid/container and card setup prevent neighboring cards from being affected. Specifically: make sure the grid container allows overflow (e.g., overflow: visible) and that the card is not clipped by parent stacking context. In this file you set transform-origin: center top (good) but you should also ensure will-change: transform is present on .card to hint the browser and help isolation. Add will-change: transform; to .card and verify the grid container uses overflow: visible (this is set in index.scss — confirm it remains).

Comment thread src/blocks/card.scss
color 300ms;

&:hover {
background-color: $color-reversed;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Transition declaration on .card__button is split across lines and correct, but confirm the hover state colors match requirements: button hover background must become #fff and text color #00acdc. In card.scss you use background-color: $color-reversed; color: $color-button; which maps to $color-reversed: #fff and $color-button: #00acdc in variables — this matches the requirement. No change required if variables keep those exact values.

Comment thread src/blocks/header.scss
Comment on lines +11 to +12
&__logo {
width: 40px;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

The card hover scale must not affect neighboring cards (task implementation detail). You have transform: scale(1.2) with transform-origin: center top, transition: transform 300ms, and z-index: 2; position: relative inside the hover which helps. However to guarantee neighbors are not visually affected you should ensure the grid container and cards allow overflow and that the card itself has will-change: transform to hint the browser and prevent reflow. Add will-change: transform; to the .card base rules and confirm the container has overflow: visible (I see overflow: visible on .catalog in index.scss). Without will-change some browsers may still repaint neighboring elements. Please add will-change: transform; to .card to satisfy the hover isolation requirement (Checklist item #5 and previous review HIGH/MEDIUM fixes).

Comment thread src/blocks/stars.scss
background-position: center;
background-repeat: no-repeat;
width: 16px;
height: 16px;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

The task and previous review require adding safeguards so the 20% hover scale does not affect neighboring cards. Add will-change: transform to .card to hint the browser and help avoid painting/reflow issues during hover (you already have transform-origin: center top and hover z-index/position).

Comment thread src/blocks/stars.scss
background-repeat: no-repeat;
width: 16px;
height: 16px;
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

On hover you set transform: scale(1.2) and position: relative/z-index: 2 which is good, but the explicit will-change: transform is missing — add it to .card (near transition/transform-origin) to satisfy the MEDIUM requirement from the previous review and checklist item #5.

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

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Review Summary

Your implementation is approved and fully meets all task requirements. The catalog grid is responsive with correct breakpoints (1/2/3/4 columns at 488px/768px/1024px), all BEM/SCSS conventions are followed, variables are properly defined for colors and sizes, hover effects are smooth at 300ms, and the will-change: transform has been added to .card. All data-qa attributes are correctly placed, and hover isolation properly prevents neighboring cards from being affected. Great work implementing the 20% card scale with transform-origin: center top - this ensures a natural hover animation. Your attention to detail on the responsive layout and hover effects demonstrates solid understanding of CSS Grid and transitions. Well done!


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

Footnotes

  1. Rate AI review example ↩

This branch has not been deployed

No deployments
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.

2 participants