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

Add searchBothFieldFunction to labelField, valueField and Empty result message #308

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

aravind3566
Copy link

@aravind3566 aravind3566 commented Oct 17, 2024

This pull request introduces a new function, searchBothFieldFunction, to the labelField and valueField components. This function allows for more flexible and efficient searching by enabling users to search for values that match either the label or the value field.

Key changes:

  • Added searchBothFieldFunction property: This property is added to both labelField and valueField components. It takes a function as input, which will be called with the search query and the current item being searched. The function should return true if the item matches the search query, and false otherwise.
  • Updated search logic: The search logic in both components is modified to use the searchBothFieldFunction if it's provided. If the function is not provided, the default search behavior remains unchanged.
  • Empty result message: The empty result message is updated to "No Result Found."

Benefits:

  • Enhanced search functionality: Users can now search for values based on either the label or the value field, providing more flexibility and accuracy in their searches.
  • Improved efficiency: The searchBothFieldFunction can be customized to optimize search performance for specific use cases.
  • Increased usability: The added search functionality makes it easier for users to find the information they need.

@aravind3566 aravind3566 changed the title Add searchBothFieldFunction to labelField and valueField Add searchBothFieldFunction to labelField and valueField and Empty result message Oct 17, 2024
@aravind3566 aravind3566 changed the title Add searchBothFieldFunction to labelField and valueField and Empty result message Add searchBothFieldFunction to labelField, valueField and Empty result message Oct 17, 2024
aravindIapparel
aravindIapparel approved these changes Nov 4, 2024
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.

2 participants