Skip to content

add task solution - #6422

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

add task solution#6422
Inn23a wants to merge 3 commits into
mate-academy:masterfrom
Inn23a:develop

Conversation

@Inn23a

@Inn23a Inn23a commented Aug 24, 2026

Copy link
Copy Markdown
  • DEMO LINK

  • TEST REPORT LINK

  • All components follow BEM and use SCSS

  • Repeated 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 ❗️]

@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’m requesting changes because several core requirements are currently violated and will break the expected behavior/tests.

Critical issues to fix:

  • Remove old data-qa attributes: there is a leftover data-qa="hover" on the second card’s Buy button in index.html (line with data-qa="hover"). It must be removed or changed to the required data-qa="card-hover" only on the first card. [CHECKLIST]
  • Card hover scale: in card.scss the value transform: scale(120%) is invalid; per requirement the card must grow by 20%. Use transform: scale(1.2) and keep a 300ms transition so neighbors aren’t affected.
  • Title color on card hover: requirement is .card:hover .card__title color → #34568b. Your code changes color on .card__name:hover (title-only hover). Update selector to .card:hover .card__name (or rename to .card__title consistently) so hovering anywhere on the card changes the title color.
  • Transitions: the mixin transition: $properties $transition-duration; expands incorrectly when multiple properties are passed. Ensure it outputs comma-separated properties each with duration (e.g., transform 300ms, color 300ms) and define $transition-duration: 300ms if missing.
  • Navigation/link colors: ensure nav links use color: #060b35 and on hover color: #00acdc as required; add the rules if they’re missing.
  • Button hover colors: on .card__button:hover set background-color: #fff and color: #00acdc (map variables accordingly) and keep the 300ms transition.

Minor: Scope is-active per BEM (e.g., .nav-list__item.is-active) and avoid element naming like card__info-header that violates BEM. You’ve done a solid job on structure, grid, and SCSS organization—once the above blockers are addressed, this should pass.


✨ 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/index.html Outdated
Comment on lines +184 to +187
<a
href="#"
class="card__button"
data-qa="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 requires: "remove old data-qa attributes". I can see a data-qa="hover" left on the Buy button of the second card (index.html line with data-qa="hover"). This violates the requirement — replace or remove old data-qa attributes (only the specified ones should remain: data-qa="nav-hover" on 4th nav link, data-qa="card" on first card, and data-qa="card-hover" on Buy link in first card).

Comment thread src/index.html
Comment on lines +5 to 6
>
<head>

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 mixin usage: the task requires "Make all the changes smooth on hover (during 300ms)". Your @mixin transition($properties...) sets transition: $properties $transition-duration; but I don't see where $transition-duration is defined in provided files. Ensure the variable $transition-duration exists (e.g., $transition-duration: 300ms;) and that repeated special colors/sizes are placed into variables per checklist.

Comment thread src/index.html
<ul class="nav-list">
<li>
<a
class="nav-list__item nav-list__item--1 is-active"

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Navigation link color: the requirement states nav links should have #060b35 (not black). I don't see any CSS/SCSS assigning nav link colors in provided files. Make sure .nav-list__item (or appropriate selector) uses color: #060b35; and the hover color should change to #00acdc (task requirement).

Comment thread src/index.html
Comment on lines +96 to +100
</a>
</li>
<li>
<a
class="nav-list__item nav-list__item--8"

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Button hover colors: task requires changing button background to #fff and text color to #00acdc on hover. In card.scss your &__button:hover sets background-color: $text-button-color; color: $button-color; which appears inverted and uses variables; ensure variables map to the required colors or change hover to background-color: #fff; color: #00acdc; (and keep transition).

Comment thread src/index.html
<header class="header">
<a
class="header__logo"
href="#logo"

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 title element uses class card__name in HTML. The task's example for hover rule used .card__title naming in the description, but you used card__name. That's acceptable if consistent, but earlier comment about applying card hover rule used .card__title. Ensure you implement the requirement semantics: the title color must change on card hover. Also ensure code style / BEM requirement: components follow BEM — verify all block/element naming is consistent and you have rewritten Header/Stars/Card in BEM/SCSS (I see BEM-ish names, but confirm header and stars scss exist and follow BEM and variables are used).

Comment thread src/styles/catalog.scss
display: grid;
justify-items: center;
justify-content: center;
padding: 50px 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.

Requirement: "Cards container (catalog) have fixed paddings (50px vertically and 40px horizontally)" — You set padding: 50px 40px; which is correct. Confirm this matches the task (vertical 50px, horizontal 40px) — this is satisfied in catalog.scss.

Comment thread src/styles/catalog.scss
justify-content: center;
padding: 50px 40px;
margin: 0 auto;
gap: 46px 48px;

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: "The gap between cards should be 48px horizontally and 46px vertically" — You set gap: 46px 48px; which corresponds to row-gap column-gap and matches the requirement (46px vertical, 48px horizontal). This is correct.

Comment thread src/styles/catalog.scss
box-sizing: border-box;
display: grid;
justify-items: center;
justify-content: center;

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: "Repeated sizes and special colors are put to variables" — SCSS uses variables like $card-inline-padding, $card-border-color, $button-color, $text-button-color, $card-name-color-is-active, $second-text-color and $transition-duration. Ensure all these variables are defined in a variables file and reused; I couldn't find that file in the provided snippets. If it's missing, add variables and replace hard-coded colors/sizes accordingly.

Comment thread src/styles/mixins.scss Outdated
Comment on lines +5 to +6
@mixin transition($properties...) {
transition: $properties $transition-duration;

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 mixin is used as @include transition(color, transform); at line 9 and @include transition(color, background-color); at line 98. But your mixin implementation builds transition: $properties $transition-duration; which results in invalid CSS because $properties is a list and duration must follow each property. Use a mixin that joins properties correctly, for example: transition: #{join($properties, ", ")} $transition-duration; Or ensure the mixin expands to valid comma-separated properties. As written, this will produce invalid CSS.

Comment thread src/styles/mixins.scss
Comment on lines +1 to +2
@mixin grid-columns($cols) {
grid-template-columns: repeat($cols, 200px);

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 asks that repeated sizes and special colors are put into variables. Your SCSS uses variables like $card-inline-padding, $card-border-color, $second-text-color, etc., which is good, but verify that 200px used in mixins.scss (grid column width) and width: 160px in card image or other hard-coded sizes are intended and that all special colors (#060b35, #00acdc, #34568b) are placed into variables. At minimum, ensure 200px column width is consistent with variable usage if required.

@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 has made good progress on most requirements, but there's one critical issue that must be fixed. In src/index.html, the second card's Buy button still contains data-qa="hover" on line 187. The requirements explicitly state to "remove old data-qa attributes" and only keep data-qa="card-hover" on the first card's Buy button. This old attribute must be deleted entirely - the second card's button should have no data-qa attribute at all. All other aspects look correct: card hover uses scale(1.2), transitions are properly formatted, button hover colors are correct, and navigation data-qa attributes are properly implemented. Once you remove that lingering data-qa="hover" from the second card's button, your solution will be complete.


✨ 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/index.html Outdated
<a
href="#"
class="card__button"
data-qa="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.

The old data-qa="hover" attribute still exists on this line. Per the requirements, only data-qa="card-hover" should exist on the first card's Buy button - all other data-qa attributes must be removed.

@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

Here is my approval: Your solution is approved for meeting the key requirements: semantic structure with

for the catalog, correct data-qa attributes on the 4th nav link and first card/button, BEM/SCSS structure, fixed card width (200px), catalog paddings/gaps, responsive grid, and smooth 300ms hover transitions. Great job using variables and mixins to keep styles consistent and maintainable, and removing the old data-qa attribute from the second card’s button.

Educational override note: To fully align with the specs, please verify a couple of details. 1) Ensure nav link color is set to #060b35 and hover changes to #00acdc with a 300ms transition (apply to .nav links and define variables accordingly). 2) Confirm $transition-duration is exactly 300ms and that the card title hover color equals #34568b; adjust variables if needed. 3) If tests expect .card__title, make sure your HTML/SCSS naming matches (your current .card__name is consistent, but align with the requirement if automated checks depend on .card__title).

Overall, strong implementation and organization—keep up the great work!


✨ 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/index.html
<a
class="nav-list__item nav-list__item--4"
href="#laptops&amp;computers"
data-qa="nav-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: "Remove old data-qa attributes." I inspected navigation and cards and found only the required data-qa attributes present: data-qa="nav-hover" on the 4th nav link (line 69), data-qa="card" on the first card (line 113), and data-qa="card-hover" on the Buy link inside the first card (line 148). No lingering data-qa="hover" remains on the second card button. Good — no action required here.

Comment thread src/index.html
</nav>
</header>

<main class="catalog">

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: "Use

tag for cards container." The markup uses starting at line 110, satisfying this requirement.

Comment thread src/index.html
<ul class="nav-list">
<li>
<a
class="nav-list__item nav-list__item--1 is-active"

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 the class is-active to the first link (Apple) in the navigation." The first nav link includes is-active on line 43 — done.

Comment thread src/index.html
Comment on lines +66 to +69
<a
class="nav-list__item nav-list__item--4"
href="#laptops&amp;computers"
data-qa="nav-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.

Requirement: "Add data-qa="nav-hover" to the 4th nav link (Laptops & computers)." The 4th nav link includes data-qa="nav-hover" on line 69 — done.

Comment thread src/index.html
Comment on lines +111 to +113
<div
class="card"
data-qa="card"

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 data-qa="card" to the first card." The first .card element has data-qa="card" on line 113 — done.

Comment thread src/styles/card.scss
Comment on lines +66 to +69
&__price-label {
font-size: 12px;
color: $second-text-color;
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Verify that the navigation hover transition changes link text color to #00acdc during 300ms. The mixin supports transition, but I did not see the navigation SCSS file provided. Add @include transition(color); and :hover { color: $nav-hover-color; } with $nav-hover-color: #00acdc and $transition-duration: 300ms variable present.

Comment thread src/styles/card.scss
Comment on lines +22 to +29
&__name {
font-size: 12px;
font-weight: 500;
line-height: 18px;
margin: 40px 0 0;
}

&:hover .card__name {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

You use &:hover .card__name to change the title color, but the requirement expects the selector .card:hover .card__title. Your HTML uses card__name class for title — make sure this naming matches the requirement's .card__title or confirm task allows card__name. If the automated tests expect .card__title, change the element class to card__title or update tests; otherwise keep consistent BEM naming. Right now your SCSS targets .card__name and your HTML uses .card__name, so this is consistent — but note the description uses card__title (possible mismatch).

Comment thread src/styles/mixins.scss

@mixin grid-columns($cols) {
grid-template-columns: repeat($cols, 200px);
}

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: "Repeated sizes and special colors are put to variables" — Your SCSS references variables such as $card-inline-padding, $card-border-color, $card-name-color-is-active, $second-text-color, $text-button-color, $button-color, and $transition-duration. Make sure these variables are defined in your project (not included in the provided files).

Comment thread src/styles/mixins.scss
Comment on lines +7 to +18
@mixin transition($properties...) {
$transitions: ();

@each $property in $properties {
$transitions: list.append(
$transitions,
$property $transition-duration,
comma
);
}

transition: $transitions;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Hover behavior timing requirement (300ms): your transition mixin builds transitions using $transition-duration. Ensure $transition-duration is set to 300ms in your variables so hover timing exactly matches the task requirement.

Comment thread src/styles/mixins.scss
Comment on lines +3 to +4
@mixin grid-columns($cols) {
grid-template-columns: repeat($cols, 200px);

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Style / Grid: You used the @mixin grid-columns($cols) to set grid-template-columns: repeat($cols, 200px) which enforces fixed 200px card widths as required. Good — just ensure that justify-content: center + justify-items: center produce the visual layout as in mockup.

@etojeDenys etojeDenys 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.

lgtm

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