-
Notifications
You must be signed in to change notification settings - Fork 46
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
refacto timetable filters #10958
refacto timetable filters #10958
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## dev #10958 +/- ##
==========================================
- Coverage 81.60% 81.60% -0.01%
==========================================
Files 1095 1095
Lines 110438 110409 -29
Branches 742 742
==========================================
- Hits 90128 90098 -30
- Misses 20268 20269 +1
Partials 42 42
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, tested, works as before, thanks !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great job on the refactoring ! Everything is very clean and well-organized! I especially appreciate how you divided the commits; it really made the review process much easier.
Just one small note: it looks like you forgot to rename the file useFilterTimetableItems
to match the new logic.
Thanks again for your work!
c964055
to
f24ec4c
Compare
Good catch, fixed. |
f24ec4c
to
f50ff1a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, not tested ✅
No change of filters behavior. - move all filter states in useFilterTrainSchedules - move useFilterTrainSchedules in Timetable component - remove useEffects in the custom hook in favor of useMemos - remove displayedTimetableItems state and reuse the filtered array from the custom hook - group the filters to a single object to facilitate the props drilling - rename some ref to train schedule in timetable item Signed-off-by: SharglutDev <[email protected]>
f50ff1a
to
64bcc82
Compare
See individual commits (will all be squashed before merging)
No behavior change expected, it's just refacto
close #10956