-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Fix/add no results found search feedback #4842
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
base: master
Are you sure you want to change the base?
Fix/add no results found search feedback #4842
Conversation
- Added response handler to jQuery autocomplete in doSearch() - Added response handler to doHelpfulSearch() for consistency - Display 'No results found' message when search returns empty - Message is styled as non-interactive with gray italic text - Maintains dropdown visibility instead of disappearing - Supports internationalization with _() function Fixes issue where searching for non-existent blocks showed no feedback
|
✅ All Jest tests passed! This PR is ready to merge. |
|
hi maintainers !! kindly review the PR description and check the PR , This enhancement improves the user experience for Music Blocks users ,Hope you find it useful Thankyou. |
This reverts commit e33ec6f.
|
✅ All Jest tests passed! This PR is ready to merge. |
zealot-zew
left a comment
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.
|
i like this change, what do you think @omsuneri ? |
|
Why the special message rendering? Not sure this PR is solving a real issue. |

Add 'No results found' feedback for empty search results
✅ Solution
This PR implements a "No results found" feedback message that appears when search queries return no matching blocks.
Changes Made
Modified File:
js/activity.js1. Enhanced
doSearch()functionresponsehandler to jQuery autocompleteui.content.length === 0)isNoResult: trueflag for special rendering2. Enhanced
doHelpfulSearch()function3. Custom Rendering
_renderItemin both functions to handle the "No results found" messagepointer-events: none)Key Features
✅ Visual Feedback: Shows "No results found" instead of empty dropdown
✅ Non-interactive: Message has
pointer-events: noneso users can't click it✅ Styled Appropriately: Gray, italic text on light background to indicate it's informational
✅ Internationalized: Uses
_("No results found")for translation support✅ Maintains Dropdown: The dropdown stays visible with the message instead of disappearing
✅ Consistent UX: Applied to both main search and helpful search widgets
🧪 Testing
Manual Testing Steps
Test Cases Covered
📸 Screenshots
Before
![Before - Empty dropdown disappears]

Search dropdown disappears with no feedback
After
![After - No results found message]

Clear "No results found" message displayed
🔍 Code Quality
_()function📝 Additional Notes
responseevent🔗 Related Issues
Fixes: #4841 issue(search): Add 'No results found' feedback for empty search results
✨ Impact
This enhancement improves the user experience for Music Blocks users, especially beginners who may be confused when search results disappear without explanation. It provides clear, immediate feedback that helps users understand when their search query doesn't match any available blocks.