MrBartusek / gif-picker-react

Tenor GIF Picker component for React ⚛️
http://dokurno.dev/gif-picker-react/
MIT License
38 stars 12 forks source link

feat: allow to set `initialSearchTerm` #33

Closed maiconcarraro closed 1 month ago

maiconcarraro commented 1 month ago

Based on discussion on this other PR https://github.com/MrBartusek/gif-picker-react/pull/32 I decided to send a suggestion to have a better UX + fixing some typos.

Behavior:

image

maiconcarraro commented 1 month ago

@MrBartusek not the same, it still has a different behavior related to have input value empty + still search relevant gifs, you can see the storybook, would you rather the other behavior?

MrBartusek commented 1 month ago

initialSearchTerm is just a duplicate of #32 at this point. But I would gladly merge these typo fixes. Please remove initialSearchTerm implementation from here but keep other fixes.

it still has a different behavior related to have input value empty + still search relevant gifs, you can see the storybook, would you rather the other behavior?

Oh, I overlooked that. In that case, it's just a questionable UX choice. A user can see that nothing is being searched for and then they see a search result. I would prefer #32 implementation rather than this one

Can you please tell me, does #32 fit your use case?

maiconcarraro commented 1 month ago

@MrBartusek Technically so so, it has a worst UX, our common tag used w/ creators is the name of the product, which would make no sense (or irrelevant) to show to the user as a term, they will need to remove the entire term to search something else, whereas this one will friendly change behavior based on users' interaction

MrBartusek commented 1 month ago

Hey! I've just merged #32 and the implementation for the initialSearchTerm as in this PR doesn't work for this project. I would be happy to merge a PR with these typo changes you have made, and we can discuss a fix for your use case later.

This may be tricky to update this PR specifically since I've implemented new lint rules and caused conflicts in every single file. So I would suggest you either make a new PR with the typo fixes or try to change this one.

As for your use case, please add me on discord @mrbartusek I would like to see your product and try to work out a solution.

maiconcarraro commented 1 month ago

@MrBartusek thank you, I'll take a look, lets close this one.