Skip to content

feat: finished task#4333

Open
TarasPidkuimukha wants to merge 3 commits intomate-academy:masterfrom
TarasPidkuimukha:develop
Open

feat: finished task#4333
TarasPidkuimukha wants to merge 3 commits intomate-academy:masterfrom
TarasPidkuimukha:develop

Conversation

@TarasPidkuimukha
Copy link
Copy Markdown

Copy link
Copy Markdown

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

Choose a reason for hiding this comment

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

Review Summary

Great job on the initial decomposition of the App component! You've correctly separated the Header, Welcome, and Article components. However, a couple of key requirements are missing, so I'm requesting a few changes.

First, the decomposition is incomplete. The Header component still contains all the navigation logic and styling. To fully meet the task's goal of modularity, please extract the <nav> element and its associated styles into a new, separate Navigation component.

Second, a style is missing. The <h1> element in Article.jsx uses the class article__title, but the corresponding CSS rule is not present in Article.css, leaving the title unstyled. Please ensure all styles are moved to their correct component-specific files.

Once these two issues are addressed, your solution will be perfect!


✨ 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

.article {
margin: 3.5em auto;
}
}
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 Article.jsx component uses an <h1> element with the class article__title, but the corresponding styles are missing from this file. Remember to move all styles associated with a component into its dedicated CSS file.

Comment on lines +22 to +35
.navigation__link {
display: inline-block;
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;
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Based on the task description, it's recommended to create a separate Navigation component. These styles are specific to the navigation and should be moved to that component's own CSS file (e.g., Navigation.css) to improve modularity.

Comment on lines +9 to +19
<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>
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 description suggests creating a separate Navigation component. This entire <nav> block should be extracted into its own component (e.g., Navigation.jsx) with its corresponding styles. You would then import and render the Navigation component here.

Copy link
Copy Markdown

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

Choose a reason for hiding this comment

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

Review Summary

Excellent progress on refactoring the application! You've correctly created the Navigation component and separated the styles. There's just one final structural change needed. The Navigation component is currently rendered in App.jsx, which breaks the intended layout and causes the tests to fail.

To fix this, please make the following changes:

  1. In src/App.jsx, remove the import and rendering of the <Navigation /> component.
  2. In src/components/Header/Header.jsx, import the Navigation component and render it inside the <header> element.

This will place the navigation bar inside the header where it belongs, restoring the correct visual layout and allowing the tests to pass. Once that's done, the task 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

src/App.jsx Outdated
import Header from './components/Header/Header';
import Welcome from './components/Welcome/Welcome';
import Article from './components/Article/Article';
import Navigation from './components/Navigation/Navigation';
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 import will no longer be necessary in App.jsx once the Navigation component is rendered inside the Header component.

src/App.jsx Outdated
<main className="app">
<Welcome />
<Article />
<Navigation />
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 navigation bar is semantically part of the header. To restore the original layout where the title and navigation links are side-by-side in a sticky bar, the <Navigation /> component should be rendered inside the Header component, not here in the <main> element.

function Header() {
return (
<header className="header">
<h1 className="header__title">Site Name</h1>
Copy link
Copy Markdown

Choose a reason for hiding this comment

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

To complete the component structure, please import the Navigation component and render it here, inside the <header> element. The existing CSS in Header.css is already set up to position the title and navigation links side-by-side.

Copy link
Copy Markdown

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

Choose a reason for hiding this comment

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

Review Summary

Excellent work on this submission! You've successfully addressed all the feedback from the previous review, resulting in a perfectly structured application. The component decomposition is spot-on, with each component and its styles correctly isolated in their own folders. Placing the Navigation component inside the Header was handled perfectly. I am approving your solution—great job!


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

Footnotes

  1. Rate AI review example

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