-
Notifications
You must be signed in to change notification settings - Fork 7
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
fix: disable transaction type filter when there are no transactions #818
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
@@ -148,6 +149,14 @@ export const Transactions = memo(function Transactions({ | |||
return !hasEmptyResults || hasFilter || hasMore; | |||
}, [activeMode, hasEmptyResults, activeTransactionType, isLoadingTransactions, hasMore]); | |||
|
|||
const enableFilter = useMemo(() => { | |||
if (isLoadingTransactions || hasFilter) { |
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.
We want to enable filter when transactions are loading or when a filter is applied - I mean by that is initially we have all possible options selected this should be understood as no filters applied, when user picks a filter it means there was at least one transaction to display, so we shouldn't disable the filter.
Summary
Closes: https://app.clickup.com/t/86dv5gmyt
Checklist