Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

solution #1141

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

solution #1141

wants to merge 2 commits into from

Conversation

manch0ffline
Copy link

Copy link

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

Thank you for your hard work on this project! 🚀 However, there are several critical issues with the import paths due to a misspelled directory name 'contsxts' instead of 'contexts'. This affects multiple files and needs to be corrected to ensure the application functions correctly. Additionally, there's a misplaced comma in index.tsx that could lead to syntax errors. Please address these issues to ensure the code runs smoothly. Keep up the great work, and once these changes are made, your solution will be ready to go! 😊

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

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

src/App.tsx Outdated
import { useContext, useEffect } from 'react';
import { Person } from './types';
import { getPeople } from './api';
import { PeopleContext } from './contsxts/PeopleContext';

Choose a reason for hiding this comment

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

The import path for PeopleContext is incorrect. It should be './contexts/PeopleContext' instead of './contsxts/PeopleContext'.

src/App.tsx Outdated
import { Person } from './types';
import { getPeople } from './api';
import { PeopleContext } from './contsxts/PeopleContext';
import { ErrorContext } from './contsxts/ErrorContext';

Choose a reason for hiding this comment

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

The import path for ErrorContext is incorrect. It should be './contexts/ErrorContext' instead of './contsxts/ErrorContext'.

src/App.tsx Outdated
import { getPeople } from './api';
import { PeopleContext } from './contsxts/PeopleContext';
import { ErrorContext } from './contsxts/ErrorContext';
import { LoaderContext } from './contsxts/LoaderContext';

Choose a reason for hiding this comment

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

The import path for LoaderContext is incorrect. It should be './contexts/LoaderContext' instead of './contsxts/LoaderContext'.

@@ -1,18 +1,146 @@
import { useContext, useEffect } from 'react';
import { SearchLink } from './SearchLink';
import { PeopleContext } from '../contsxts/PeopleContext';

Choose a reason for hiding this comment

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

The import path for PeopleContext is incorrect. It should be '../contexts/PeopleContext' instead of '../contsxts/PeopleContext'.

import { PeopleContext } from '../contsxts/PeopleContext';
import { Person } from '../types';
import cn from 'classnames';
import { PeopleFilteredContext } from '../contsxts/PeopleFilteredContext';

Choose a reason for hiding this comment

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

The import path for PeopleFilteredContext is incorrect. It should be '../contexts/PeopleFilteredContext' instead of '../contsxts/PeopleFilteredContext'.

src/index.tsx Outdated

import 'bulma/css/bulma.css';
import '@fortawesome/fontawesome-free/css/all.css';

import { App } from './App';
import { HomePage } from './pages/HomePage/HomePage';
import { PeoplePage } from './components/PeoplePage';
import { PeopleProvider } from './contsxts/PeopleContext';

Choose a reason for hiding this comment

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

The import path for PeopleContext is incorrect. It should be './contexts/PeopleContext' instead of './contsxts/PeopleContext'.

src/index.tsx Outdated
import { HomePage } from './pages/HomePage/HomePage';
import { PeoplePage } from './components/PeoplePage';
import { PeopleProvider } from './contsxts/PeopleContext';
import { ErrorProvider } from './contsxts/ErrorContext';

Choose a reason for hiding this comment

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

The import path for ErrorContext is incorrect. It should be './contexts/ErrorContext' instead of './contsxts/ErrorContext'.

src/index.tsx Outdated
import { PeoplePage } from './components/PeoplePage';
import { PeopleProvider } from './contsxts/PeopleContext';
import { ErrorProvider } from './contsxts/ErrorContext';
import { LoaderProvider } from './contsxts/LoaderContext';

Choose a reason for hiding this comment

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

The import path for LoaderContext is incorrect. It should be './contexts/LoaderContext' instead of './contsxts/LoaderContext'.

src/index.tsx Outdated
import { PeopleProvider } from './contsxts/PeopleContext';
import { ErrorProvider } from './contsxts/ErrorContext';
import { LoaderProvider } from './contsxts/LoaderContext';
import { PeopleFilteredProvider } from './contsxts/PeopleFilteredContext';

Choose a reason for hiding this comment

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

The import path for PeopleFilteredContext is incorrect. It should be './contexts/PeopleFilteredContext' instead of './contsxts/PeopleFilteredContext'.

src/index.tsx Outdated
</Route>
</Routes>
</Router>
,

Choose a reason for hiding this comment

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

There is a misplaced comma here that should be removed to prevent syntax errors.

Copy link

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

Great job on addressing the issues with the import paths and syntax errors! 🎉 The directory name has been corrected from 'contsxts' to 'contexts', and the misplaced comma in index.tsx has been fixed. Your implementation now meets the task requirements and constraints, including saving filters and sort parameters as URL search parameters, displaying the sidebar only when people are loaded, and implementing sorting functionality correctly.

While the code is approved, remember to always double-check import paths and syntax to avoid similar issues in the future. Keep up the good work and continue learning from these experiences to improve your coding skills! 🚀

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

import { useContext, useEffect } from 'react';
import { Person } from './types';
import { getPeople } from './api';
import { PeopleContext } from './contexts/PeopleContext';

Choose a reason for hiding this comment

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

Ensure that the import path './contexts/PeopleContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

import { Person } from './types';
import { getPeople } from './api';
import { PeopleContext } from './contexts/PeopleContext';
import { ErrorContext } from './contexts/ErrorContext';

Choose a reason for hiding this comment

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

Ensure that the import path './contexts/ErrorContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

import { getPeople } from './api';
import { PeopleContext } from './contexts/PeopleContext';
import { ErrorContext } from './contexts/ErrorContext';
import { LoaderContext } from './contexts/LoaderContext';

Choose a reason for hiding this comment

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

Ensure that the import path './contexts/LoaderContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

@@ -1,18 +1,146 @@
import { useContext, useEffect } from 'react';
import { SearchLink } from './SearchLink';
import { PeopleContext } from '../contexts/PeopleContext';

Choose a reason for hiding this comment

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

Ensure that the import path '../contexts/PeopleContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

import { PeopleContext } from '../contexts/PeopleContext';
import { Person } from '../types';
import cn from 'classnames';
import { PeopleFilteredContext } from '../contexts/PeopleFilteredContext';

Choose a reason for hiding this comment

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

Ensure that the import path '../contexts/PeopleFilteredContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

@@ -1,29 +1,47 @@
import { PeopleFilters } from './PeopleFilters';
import { Loader } from './Loader';
import { PeopleTable } from './PeopleTable';
import { useContext } from 'react';
import { ErrorContext } from '../contexts/ErrorContext';
import { LoaderContext } from '../contexts/LoaderContext';

Choose a reason for hiding this comment

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

Ensure that the import path '../contexts/LoaderContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

import { useContext } from 'react';
import { ErrorContext } from '../contexts/ErrorContext';
import { LoaderContext } from '../contexts/LoaderContext';
import { PeopleContext } from '../contexts/PeopleContext';

Choose a reason for hiding this comment

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

Ensure that the import path '../contexts/PeopleContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

import { ErrorContext } from '../contexts/ErrorContext';
import { LoaderContext } from '../contexts/LoaderContext';
import { PeopleContext } from '../contexts/PeopleContext';
import { PeopleFilteredContext } from '../contexts/PeopleFilteredContext';

Choose a reason for hiding this comment

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

Ensure that the import path '../contexts/PeopleFilteredContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

import { Link, useParams } from 'react-router-dom';
import cn from 'classnames';
import { Person } from '../types';
import { PeopleFilteredContext } from '../contexts/PeopleFilteredContext';

Choose a reason for hiding this comment

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

Ensure that the import path '../contexts/PeopleFilteredContext' is correct. Previously, there was a misspelling in the directory name 'contexts'. Verify that this has been corrected.

</LoaderProvider>
</ErrorProvider>
</PeopleFilteredProvider>
</PeopleProvider>,

Choose a reason for hiding this comment

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

Remove the comma after <PeopleProvider> to prevent syntax errors. This comma is unnecessary and could cause issues during rendering.

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