Open artmarks opened 3 weeks ago
I wouldn't go as far as exposing all possible options that react-select gives us. I'd like to preserve the option to switch to another component in the future. Exposing an API that is very close to react-select's functionality would make that very hard. The following features may be a good compromise for the time being (with PRs being highly welcome):
noResultsMessage
(a string or even a custom react component). I don't know at this point if there is any context needed to render this message (there are two states: never searched and thus no results, i.e. "fresh" widget; and a search was attempted but returned no results). These may even be two props now that I think about it.I think other 'overrides' are a bit out of scope at the moment and would need a good justification before thinking about implementing them.
Issue description
We need a specific info message if there is no result found in the search. The message should have a certain format and coloring.
Discussion
To realize this we could create a new optional prop
customComponents
that looks like this:and exchange thoose given components with the defaults ones in
useCustomComponents
.We would also be open to other suggestions to our issue :)
Validations