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

feat(ui-search): enhance search fields with clear button for value reset on click #1756

Closed
wants to merge 2 commits into from

Conversation

laurent-laporte-pro
Copy link
Contributor

@laurent-laporte-pro laurent-laporte-pro commented Oct 6, 2023

Description

This pull request enhances the SearchFE component by adding a clear button to reset the search field's value when
clicked.

Changes Made

  • Added a clear button to the search field: InputAdornment + IconButton
  • Implemented functionality to reset the field value on button click: onClick and onChange

Screenshots

improve-search-fields

Testing

  • When the user enter a value in the search field, the clear button should be visible.
    And the list of studies should be filtered by the entered value.
  • When the user clicks the clear button, the search field should be cleared and the list of studies should be reset.

Related Issues

Closes #1729

@laurent-laporte-pro laurent-laporte-pro linked an issue Oct 6, 2023 that may be closed by this pull request
@commit-lint
Copy link

commit-lint bot commented Oct 6, 2023

Features

  • ui-search: add a clear button on studies search field (156aafa)
  • ui-search: handle the search value (5966274)

Contributors

laurent-laporte-pro

Commit-Lint commands

You can trigger Commit-Lint actions by commenting on this PR:

  • @Commit-Lint merge patch will merge dependabot PR on "patch" versions (X.X.Y - Y change)
  • @Commit-Lint merge minor will merge dependabot PR on "minor" versions (X.Y.Y - Y change)
  • @Commit-Lint merge major will merge dependabot PR on "major" versions (Y.Y.Y - Y change)
  • @Commit-Lint merge disable will desactivate merge dependabot PR
  • @Commit-Lint review will approve dependabot PR
  • @Commit-Lint stop review will stop approve dependabot PR

@laurent-laporte-pro
Copy link
Contributor Author

@hdinia / @skamril , J'essaie d'implémenter la fonctionnalité de réinitialisation (RAZ) du champ de recherche par moi-même, mais je rencontre un problème. Je n'arrive pas à faire en sorte que la liste des études se mette automatiquement à jour lorsque le champ de recherche est réinitialisé. Mon objectif idéal serait que lorsqu'un utilisateur clique sur le bouton "clear", cela déclenche un événement "change" qui serait ensuite capturé par le gestionnaire onChange.
Si vous pouviez m'aider sur ce point, je suis preneur… J'espère seulement que je ne fais pas fausse route.

@laurent-laporte-pro laurent-laporte-pro force-pushed the feature/1729-improve-search-fields branch from 631849c to 5966274 Compare October 6, 2023 09:10
@skamril skamril closed this Oct 30, 2023
@laurent-laporte-pro laurent-laporte-pro deleted the feature/1729-improve-search-fields branch May 27, 2024 16:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants