Skip to content

feat: catalog landing page with HTML, SCSS and BEM methodology#6284

Open
MikeBoltUX wants to merge 1 commit into
mate-academy:masterfrom
MikeBoltUX:feat/catalog-layout
Open

feat: catalog landing page with HTML, SCSS and BEM methodology#6284
MikeBoltUX wants to merge 1 commit into
mate-academy:masterfrom
MikeBoltUX:feat/catalog-layout

Conversation

@MikeBoltUX

Copy link
Copy Markdown

No description provided.

@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 are still explicit checklist violations that count as critical blockers for this task. The main issue is [CHECKLIST ITEM #2 – repeated sizes and special colors are put to variables]: you repeatedly hardcode 200px for grid columns in _catalog.scss, _header.scss, _price.scss, _reviews.scss, and index.scss even though $card-width: 200px; already exists, and you use #fff (and rgba(0, 0, 0, 0.1) in _catalog.scss, #34568b in _card.scss) directly instead of centralizing them into SCSS variables like $color-white and a named hover color. You also hardcode 300ms in some hover transitions (e.g., in _button.scss) instead of consistently reusing $transition-time, which is required for “all hover changes are smooth” to stay consistent across components. In addition, there are leftover tooling markers like /**24**/, /**15**/, and /**8**/ at the ends of several .scss files (_price.scss, _reviews.scss, _stars.scss, index.scss) that are not valid SCSS comments and violate the code style rules [CHECKLIST ITEM #6].

To fix this, please: 1) replace all repeated 200px literals in grid templates and media queries with $card-width, 2) introduce a $color-white: #fff; (and other needed color tokens) in your variables and use those instead of raw hex/rgba literals wherever they recur, 3) reuse $transition-time instead of hardcoding 300ms in hover transitions, and 4) remove all stray /**…**/ marker comments from your SCSS files. The rest of your implementation (semantic HTML, BEM structure, grid layout, hover behaviors, and required data-qa attributes) looks solid and close to the spec. Once these variable and code-style issues are addressed, your solution should fully meet the task requirements. Keep going—your structure and logic are on the right track, this is mostly about polishing consistency and maintainability.


✨ 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
@@ -22,6 +22,399 @@
</head>

<body>

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Same as earlier: this #fff literal in the hover state should be replaced with a color variable to comply with checklist item #2.

Comment thread src/styles/_button.scss
border: 1px solid transparent;
border-radius: 5px; // El valor exacto de tu captura
cursor: pointer;
transition: background-color 300ms ease, color 300ms ease, border-color 300ms ease;

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 hover implementation correctly changes the button background and text color, but per the requirement to have all hover changes smooth over 300ms (Checklist: All changes on :hover are smooth), consider reusing the $transition-time variable instead of hardcoding 300ms in multiple places, so timing stays consistent across components.

Comment thread src/styles/_card.scss
box-sizing: border-box;
background-color: #fff;
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.

This violates checklist item "Repeated sizes and special colors are put to variables": you use #fff directly here and in other styles instead of referencing a shared SCSS variable (for example a $color-white), so repeated special colors are not centralized.

Comment thread src/styles/_card.scss

/* Al hacer hover en la card, cambiamos el color del título interno */
.card__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.

Checklist item "Repeated sizes and special colors are put to variables" is partially violated: the hardcoded #34568b should be moved into a named SCSS variable (e.g. $color-card-title-hover) so that special colors are not duplicated as literals.

Comment thread src/styles/_catalog.scss
display: grid;

/* Por defecto (pantallas pequeñas): 1 columna del ancho de la card (200px) */
grid-template-columns: 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.

You’re hardcoding 200px here even though you already have $card-width defined. This violates checklist item "Repeated sizes and special colors are put to variables"; reuse $card-width instead of duplicating the value.

Comment thread src/styles/_catalog.scss

/* 2 columnas a partir de 488px */
@media (min-width: 488px) {
grid-template-columns: repeat(2, 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.

Same issue as above: repeat(2, 200px) duplicates the card width value. To satisfy checklist item about putting repeated sizes into variables, use the $card-width variable here.

Comment thread src/styles/_catalog.scss

/* 3 columnas a partir de 768px */
@media (min-width: 768px) {
grid-template-columns: repeat(3, 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.

And here again, repeat(3, 200px) repeats the literal card width instead of using $card-width, which goes against the checklist rule for centralizing repeated sizes.

Comment thread src/styles/_catalog.scss

/* 4 columnas a partir de 1024px */
@media (min-width: 1024px) {
grid-template-columns: repeat(4, 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.

This is another repetition of 200px for card width. Consider repeat(4, $card-width) to align with the "Repeated sizes and special colors are put to variables" requirement.

Comment thread src/styles/_catalog.scss
@@ -0,0 +1,31 @@
.catalog {
/* Paddings fijos requeridos: 50px vertical, 40px horizontal */
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.

The hardcoded #fff header background is a design token; to comply with the checklist requirement about variables, consider moving this into a SCSS variable (e.g. $color-background or $color-white) instead of using the literal.

Comment thread src/styles/_catalog.scss
.catalog {
/* Paddings fijos requeridos: 50px vertical, 40px horizontal */
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.

rgba(0, 0, 0, 0.1) is another special color value that would be better as a variable (e.g. $color-border-header) to satisfy the checklist about repeated/special colors being stored in variables, especially if you reuse this elsewhere.

Comment thread src/styles/_catalog.scss

/* 3 columnas a partir de 768px */
@media (min-width: 768px) {
grid-template-columns: repeat(3, 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.

This trailing /**24**/ marker is not valid SCSS and appears to be a leftover artifact. It violates the general code-style cleanliness requirement; remove it to keep the stylesheet valid.

Comment thread src/styles/_catalog.scss
gap: 46px 48px;

/* Centramos el grid en la pantalla para que se vea bien */
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.

Same as in _price.scss: this /**15**/ looks like a leftover marker rather than a real comment. Remove it to comply with the "Code follows all the Code Style Rules" checklist item and avoid confusing, non-SCSS syntax.

Comment thread src/styles/_header.scss
&__container {
max-width: 1200px;
margin: 0 auto;
padding: 0 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.

Here and in all following grid-template-columns you hardcode 200px even though $card-width is defined; this violates checklist item #2: "Repeated sizes and special colors are put to variables". Use $card-width instead of the literal 200px.

Comment thread src/styles/_header.scss
.nav {
text-transform: uppercase;

&__list {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Same checklist item #2 applies here: replace repeat(2, 200px) with repeat(2, $card-width) to avoid repeating the literal width.

Comment thread src/styles/_header.scss
align-items: center;
list-style: none;
margin: 0;
padding: 0;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

For consistency with variables (checklist #2), this should use $card-width rather than repeating 200px again.

Comment thread src/styles/_header.scss

&__item {
margin-left: 24px;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Likewise, change repeat(4, 200px) to repeat(4, $card-width) to keep the card width centralized in a variable.

Comment thread src/styles/_header.scss
@@ -0,0 +1,62 @@
.header {
width: 100%;
background-color: #fff;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

#fff is a special color used in multiple components (header, buttons, etc.); per checklist item #2, move this into a shared SCSS variable (e.g. $color-white) instead of hardcoding it.

Comment thread src/styles/_header.scss
align-items: center;
list-style: none;
margin: 0;
padding: 0;

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 trailing /**24**/ looks like a leftover marker, not a meaningful comment; cleaning it up will help align with the code-style guideline checklist item: "Code follows all the Code Style Rules".

Comment thread src/styles/_header.scss
align-items: 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.

Same as in _price.scss, this stray /**15**/ marker at the end of the file isn’t a normal SCSS comment and should be removed to keep the stylesheet clean and compliant with the style rules.

Comment thread src/styles/_price.scss
@@ -0,0 +1,23 @@
@import "./variables";

.price {

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Since the checklist requires that “Repeated sizes and special colors are put to variables”, consider replacing the literal #fff with a named SCSS variable (e.g. $color-white) so it’s centralized and reused consistently.

Comment thread src/styles/_price.scss
justify-content: space-between;

&__label { // O &__label
font-family: $font-main;

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 the fixed card width 200px multiple times across the layout; to fully follow the checklist about repeated sizes, it would be better to replace this literal with the existing $card-width variable (or create one if needed) rather than repeating the raw value.

Comment thread src/styles/_price.scss
&__value { // O &__value
font-family: $font-main;
font-size: 18px;
font-weight: 700;

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

For the same reason as above (checklist: repeated sizes to variables), these repeated 200px values in the media queries should use the shared width variable instead of the literal.

Comment thread src/styles/_price.scss
line-height: 1.5;
color: $color-text-secondary; // Ese #707070 que suele ser el gris de la guía
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Same as in _price.scss, this /**15**/ marker doesn’t belong in the SCSS source and may confuse future readers; consider removing it to satisfy the general code style guideline.

Comment thread src/styles/_reviews.scss
@@ -0,0 +1,14 @@
@import "./variables";

.reviews {

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 hardcoded #fff is a “special color” that appears in multiple places; it violates checklist item #2: "Repeated sizes and special colors are put to variables". Consider defining a $color-white (or similar) variable and using that instead of the literal.

Comment thread src/styles/_reviews.scss
justify-content: space-between; // Aquí va el gap exacto de Figma

&__count {
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.

Here you hardcode 200px while you already have $card-width defined in your variables. This violates checklist item #2: "Repeated sizes and special colors are put to variables"; use $card-width instead of duplicating the numeric value.

Comment thread src/styles/_stars.scss
gap: 4px;

&__item {
display: inline-block;

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 tooling marker /**8**/ at the end of the variables file isn’t valid SCSS and should be removed to comply with the checklist item “Code follows all the Code Style Rules”.

Comment thread src/styles/index.scss
@import 'button';
@import 'card';
@import 'price';
@import 'reviews';

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Since $card-width: 200px; is already defined, this hardcoded 200px should be replaced with $card-width to satisfy checklist item: "Repeated sizes and special colors are put to variables".

Comment thread src/styles/index.scss
}
@import 'variables';
@import 'base';
@import 'header';

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 literal #fff is a special color used in multiple components (e.g., header background, button hover). To comply with the checklist item about variables, consider defining a $color-white (or similar) and using that variable here.

Comment thread src/styles/index.scss
/* Componentes de la Card */
@import 'button';
@import 'card';
@import 'price';

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 trailing /**8**/ marker is not part of valid SCSS and looks like a leftover from tooling. It should be removed to keep the variables file clean and aligned with the code style rules.

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