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

add task solution #1593

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

add task solution #1593

wants to merge 1 commit into from

Conversation

zhudim
Copy link

@zhudim zhudim commented Jan 9, 2025

  • Replace <your_account> with your Github username in the DEMO LINK and add it to the PR description.

Copy link

@volodymyr-soltys97 volodymyr-soltys97 left a comment

Choose a reason for hiding this comment

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

Great work! 🔥

Comment on lines +179 to +204
<section className="todoapp__main" data-cy="TodoList">
<TransitionGroup>
{filteredTodos.map(todo => (
<CSSTransition key={todo.id} timeout={300} classNames="item">
<TodoItem
todo={todo}
key={todo.id}
onUpdateTodo={handleUpdateTodo}
onDeleteTodo={handleDeleteTodo}
isLoading={loadingTodoIds.includes(todo.id)}
/>
</CSSTransition>
))}

{tempTodo && (
<CSSTransition key={0} timeout={300} classNames="temp-item">
<TodoItem
todo={tempTodo}
onUpdateTodo={handleUpdateTodo}
onDeleteTodo={handleDeleteTodo}
isLoading={isAddingLoading}
/>
</CSSTransition>
)}
</TransitionGroup>
</section>

Choose a reason for hiding this comment

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

Consider will be better if you create a separate component for this logic, for example TodoList

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