Open
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
hjaintech
reviewed
May 31, 2024
| onClickSearchButton, | ||
| }: TaskSearchProps) => { | ||
| const [modalOpen, setModalOpen] = useState(false); | ||
| const [filterDropdownModelOpen, setFilterDropdownModelOpen] = |
Collaborator
There was a problem hiding this comment.
There are 7 useState's currently in this component. This would be a good candidate to start using useReducer instead to better manage the state.
hjaintech
reviewed
May 31, 2024
| >(convertStringToOptions(inputValue)); | ||
| const [onEditSelectedFilterValue, setOnEditSelectedFilterValue] = | ||
| useState<string>(''); | ||
| const [onEditSelectedFilterIndex, setOnEditSelectedFilterIndex] = |
Collaborator
There was a problem hiding this comment.
Is the type false | number correct? Could the default value be -1 making the type be just number?
hjaintech
reviewed
May 31, 2024
| {modalOpen && ( | ||
| <FilterModal | ||
| dev={false} | ||
| Filter |
Collaborator
There was a problem hiding this comment.
Can such a long JSX be broken down into multiple functions? That would considerably improve the readability.
hjaintech
reviewed
May 31, 2024
| import useDebounce from '@/hooks/useDebounce'; | ||
| import { TaskSearchOption } from '@/interfaces/searchOptions.type'; | ||
| import Options from './Suggestion/Options'; | ||
| import RenderPills from './Suggestion/Pill'; |
Collaborator
There was a problem hiding this comment.
Any reason for naming this RenderPills and not just Pill ?
Desc : Made onEditSelectedFilterIndex to be of number type only & renamed import of Pill
Achintya-Chatterjee
approved these changes
Jun 2, 2024
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Date: 31/05/2024
Developer Name: @pallabez
Issue Ticket Number
Description
Documentation Updated?
Under Feature Flag
Database Changes
Breaking Changes
Development Tested?
Screenshots
Screenshot 1
Test Coverage
Screenshot 1
Additional Notes