task solution#4464
Conversation
mateacademy-ai-mentor
left a comment
There was a problem hiding this comment.
Review Summary
I am approving your solution because all core requirements are implemented: the app is correctly decomposed into Welcome, Header, Article, and Navigation, each in its own folder with its own CSS file and export default, and there are no functional issues indicated by the code. The remaining problems called out in the review are all about formatting and spacing (over‑indented JSX, extra blank lines, slightly misaligned closing tags), which fall into style/Prettier territory rather than breaking behavior or violating a hard functional requirement. Even though checklist item #1 mentions spacing between components, the issues here are minor visual gaps and indentation rather than something that would prevent tests from passing or the UI from rendering.
If you want to polish this further, you can:
- Run Prettier or re-indent the JSX in
Article.jsx,Header.jsx, andNavigation.jsxso that tags line up consistently and extra leading spaces are removed. - Remove unnecessary blank lines between imports, component definitions, and exports to better match the checklist’s “GOOD EXAMPLE” spacing.
- Optionally add a base
.navigation { ... }rule inNavigation.cssto keep your BEM blocks consistent with.header,.welcome, and.article.
Overall, you’ve met the task’s functional and structural goals; any remaining tweaks are cosmetic and good practice for keeping your code clean and consistent.
✨ Please rate this review in the Platform's notification center1. I will be grateful for your feedback! ✨
Footnotes
| return ( | ||
| <main className="app"> |
There was a problem hiding this comment.
This pattern of multiple empty lines inside JSX between elements matches the "BAD EXAMPLE" from checklist item #1: "[CODE STYLE] - Don't overuse empty lines between components." Consider tightening the vertical spacing so adjacent JSX elements are not separated by more than a single blank line.
| const Article = () => ( | ||
| <article className="article"> |
There was a problem hiding this comment.
The JSX inside Article is visually mis-indented and starts far to the right; reformat so that <article> and its children are consistently indented, avoiding patterns similar to the "BAD EXAMPLE" in checklist item #1 about spacing between components.
| </p> | ||
| <p className="article__paragraph"> | ||
| In ac nisi lacus. Fusce est dolor, tincidunt ut bibendum vitae, | ||
| fermentum ac quam. Aliquam pretium tristique nibh quis iaculis. In et | ||
| cursus ex, eu aliquet ex. Proin facilisis lacus sit amet sapien | ||
| ultrices, ut vehicula arcu lobortis. Vivamus mollis ipsum ut hendrerit |
There was a problem hiding this comment.
Indentation of </header> is off relative to the opening tag; reformat the JSX so sibling elements are aligned consistently, avoiding awkward gaps that resemble the checklist #1 bad example for spacing between components.
|
|
||
| // Add a default export statement for Article component to use it in the other files | ||
| import './Article.css'; | ||
|
|
There was a problem hiding this comment.
The JSX in Navigation is over-indented; reformat the <nav> and its children so they align consistently and avoid unnecessary visual gaps, staying closer to the checklist #1 good example style.
| top: 0; | ||
| left: 0; | ||
| right: 0; | ||
| transition: opacity 0.2s ease-in-out; | ||
| text-align: center; | ||
| } | ||
|
|
||
| .header__title { | ||
| font-weight: 600; | ||
| display: inline; | ||
| margin: 0; | ||
| padding: 0; | ||
| font-size: inherit; | ||
| } |
There was a problem hiding this comment.
This section has extra blank lines between the comment, the App function, and the export default, which matches the "BAD EXAMPLE" of checklist item #1: "[CODE STYLE] - Don't overuse empty lines between components." Try to keep imports, component definition, and export grouped without unnecessary empty lines.
| @@ -0,0 +1,14 @@ | |||
| .navigation__link { | |||
There was a problem hiding this comment.
In the BEM structure used elsewhere (.header, .welcome, .article), the block itself has a base CSS rule. Here className="navigation" is used but there is no .navigation rule in Navigation.css. Consider adding a base .navigation { ... } rule to keep your BEM blocks consistent with the rest of the layout.
|
|
||
| .navigation__link:hover, | ||
| .navigation__link:focus { | ||
| opacity: 1; |
There was a problem hiding this comment.
The closing </header> tag is misaligned relative to the opening <header> and its children. While this won’t break functionality, it makes the JSX harder to read; consider reformatting so the opening and closing tags and their children are consistently indented (Prettier should handle this).
| outline: none; | ||
| text-decoration: none; | ||
| opacity: 0.7; | ||
| padding: 0 0.5em; | ||
| color: black; | ||
| transition: opacity 0.2s ease-in-out; | ||
| } | ||
|
|
||
| .navigation__link:hover, | ||
| .navigation__link:focus { | ||
| opacity: 1; | ||
| } No newline at end of file |
There was a problem hiding this comment.
The JSX inside the Navigation component is over-indented, which makes the structure harder to read. After running Prettier, <nav> and its <a> children should be indented consistently, improving clarity.
| </a> | ||
| <a className="navigation__link" href="#contact"> | ||
| Contact | ||
| </a> |
There was a problem hiding this comment.
The closing </header> tag is misaligned with the opening tag. Reformat the JSX so opening and closing tags of header and its children are consistently indented to keep the structure clear.
| const Navigation = () => ( | ||
| <nav className="navigation"> | ||
| <a className="navigation__link" href="#about"> | ||
| About | ||
| </a> | ||
| <a className="navigation__link" href="#services"> | ||
| Services | ||
| </a> | ||
| <a className="navigation__link" href="#contact"> | ||
| Contact | ||
| </a> | ||
| </nav> |
There was a problem hiding this comment.
This JSX is over‑indented (lots of leading spaces before <nav> and child tags), which goes against the spacing/structure implied by checklist item #1. Run Prettier or manually reindent so that <nav> and its children are indented consistently and don’t appear separated by visual gaps.
DEMO LINK