Hide create new option prompt text when input is empty/reset/cleared
See original GitHub issuePreconditions:
- multi: true
- createable: true
Steps:
- Type something which will show some of the options, select any of the options.
- Input is cleared on selecting option but the prompt text
Create an option "xxx"
is still there when you focus on the field. The same happens when you type something and click outside of the select container (blur) and focus on it again.
It would be great if the prompt text Create an option "xxx"
will not display when the input is empty/reset/cleared as it’s kinda strange to display suggestion to create new option when there is nothing in the input. Thanks!
Issue Analytics
- State:
- Created 7 years ago
- Reactions:13
- Comments:10 (1 by maintainers)
Top Results From Across the Web
text input with clear button which auto hide and show
So, when search box input field is empty it will not show "X". But when the user types anything inside field then "X"...
Read more ><input>: The Input (Form Input) element - HTML
A single-line text field for entering search strings. Line-breaks are automatically removed from the input value. May include a delete icon in ...
Read more >Xamarin.Forms Entry - Microsoft Learn
This article explains how to use the Xamarin.Forms Entry class to accept single-line text or password input in an application.
Read more >UITextField | Apple Developer Documentation
An object that displays an editable text area in your interface.
Read more >lightning-input-field - documentation - Salesforce Developers
To reset the form fields to their initial values, use the reset() method on each input field. For more information, see lightning-record-edit-form. Overriding ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
A quick (and dirty?) workaround currently is to manually delete the internal placeholder item whenever
onChange()
fires.Here’s an example using a stateless component:
Hello -
In an effort to sustain the
react-select
project going forward, we’re closing old issues / pull requests.We understand this might be inconvenient but in the best interest of supporting the broader community we have to direct our limited efforts to maintain the latest version.
If you feel this issue / pull request is still relevant and you’d like us to review it, please leave a comment and we’ll do our best to get back to you.