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(combobox): add resetSearchTermOnSelect param to ComboboxRoot #1257

Merged

Conversation

hrynevychroman
Copy link
Contributor

I added the clearSearchTermOnSelect prop so that the search term will not automatically clear when Combobox selects triggers. Maybe users will want to select multiple values based on the same search fields

Original Issue: unovue/shadcn-vue#709.

Video example:

radix-vue-combobox-clear-search-term.mp4

Docs updated too:
image

@hrynevychroman
Copy link
Contributor Author

I managed to rename clearSearchTermOnSelect to resetSearchTermOnSelect as we already have resetSearchTermOnBlur which will be more intuitive 🙂

commit: c2733af (#1257)

@zernonia
Copy link
Member

zernonia commented Sep 3, 2024

Cool addition @romanhrynevych . Can you check the failing test? 😁

@hrynevychroman
Copy link
Contributor Author

@zernonia interesting test case, thanks for such approach, updated in 4e8e420 (#1257) 🙌

@hrynevychroman hrynevychroman changed the title feat(combobox): add clearSearchTermOnSelect param to ComboboxRoot feat(combobox): add resetSearchTermOnSelect param to ComboboxRoot Sep 5, 2024
@knutole
Copy link

knutole commented Dec 23, 2024

@hrynevychroman Great addition, will use this. Could you please finalise this PR by fixing the failing test? 💯

@hrynevychroman
Copy link
Contributor Author

@knutole this test case was fixed in radix-vue/radix-vue@4e8e420 (#1257), need @zernonia review, updated branch to be up to date with a main one

@zernonia could we merge this?

@knutole
Copy link

knutole commented Jan 16, 2025

@zernonia @hrynevychroman This is great, but seems a check is failing:
Screenshot 2025-01-16 at 09 01 23

Could this be fixed? We're looking forward to using this fix!

Thanks!

@zernonia
Copy link
Member

Yoo @hrynevychroman ! Im sooooo sorry for missing his out! I was thinking to not additional feature to 1.9, but saw this #1559 and thhinking we can push this as a feature & fix.

Reviewing this now 😁

@zernonia zernonia merged commit 1fad29d into unovue:main Jan 21, 2025
3 of 4 checks passed
@hrynevychroman hrynevychroman deleted the feat/combobox-disable-search-clear branch January 21, 2025 10:30
Copy link

pkg-pr-new bot commented Jan 21, 2025

Open in Stackblitz

npm i https://pkg.pr.new/radix-vue@1257

commit: 02b3dd1

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.

3 participants