Closed jchamberlain closed 3 weeks ago
Hi @jchamberlain , thank you for the suggestion. I don't think there is a problem with your approach :) While we could also allow all SelectProps and forward them, there could be collisions between Material's SelectProps and JsonForms's props. Thus, I think your approach makes sense. Would you like to contribute it?
+1 for adding this in the library
Thank you for the feedback, @lucas-koehler! I've just opened a PR with the changes.
Is your feature request related to a problem? Please describe.
I would like to use MUI's
Select
component, but with themultiple
flag enabled. See https://mui.com/material-ui/react-select/#multiple-select. Unfortunately, theMuiSelect
component in the material renderers does not accept themultiple
prop nor provide any way to pass it to the underlyingSelect
.Describe the solution you'd like
Locally I've added a new interface to
material-renderers/src/util/theme.ts
:Then added it to the
MuiSelect
component:This worked perfectly for me. I'm not sure if this is the right approach, but could something like this be considered for inclusion?
Describe alternatives you've considered
MUI's
Autocomplete
can do some of this, but it's overly complicated for most of my use cases and it can be confusing to users who are expecting normal<select>
-like behavior.Framework
React
RendererSet
Material
Additional context
No response