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

Display "No result" when necessary #284

Merged
merged 4 commits into from
Nov 2, 2023

Conversation

MGaetan89
Copy link
Member

Pull request

Description

When a query returned no results, the search view would only display the BU selector, and nothing else.
Now we display the BU selector, followed by the "No result" message.

Changes made

  • Display "No result" when we receive only the BU selector
  • Simplify state management in the search view

Checklist

  • Your branch has been rebased onto the main branch.
  • APIs have been properly documented (if relevant).
  • The documentation has been updated (if relevant).
  • New unit tests have been written (if relevant).
  • The demo has been updated (if relevant).
  • All pull request status checks pass.

@MGaetan89 MGaetan89 linked an issue Nov 2, 2023 that may be closed by this pull request
1 task
@@ -142,6 +134,16 @@ private fun SearchResultList(
}
}
}
// We didn't receive any results
if (lazyPagingItems.itemCount == 1 && lazyPagingItems[0] is SearchContent.BuSelector) {
Copy link
Contributor

Choose a reason for hiding this comment

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

We shouldn't see the message no result when loading. Maybe use LoadState.

@StaehliJ StaehliJ force-pushed the 278-no-result-found-in-search-view branch from 8de327d to ed03b02 Compare November 2, 2023 10:48
@MGaetan89 MGaetan89 merged commit aa2245d into main Nov 2, 2023
4 checks passed
@MGaetan89 MGaetan89 deleted the 278-no-result-found-in-search-view branch November 2, 2023 13:02
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.

No result found in search view
2 participants