svelte-material-ui
svelte-material-ui copied to clipboard
feat: add items prop, proper height and validation lib support to select
Items are passed into the Select
as either an object
or an array
via the items
prop. Breaks existing Select
implementations as there is no backwards-compatibility for Select
; an array
or object
must be used. This deprecates Option.svelte
.
The Select
scales the menu according to device height if menu$fixed={true}
prop is passed.
Select
respects hiddenInput
prop by appropriately calling events on the field, including the SMUISelect:change
event. The hiddenInput
also contains a data-smui="true"
prop for easy identification in standard browser-level form validation libraries.
Closes #242, #468
Using an items array limits the structure of whatever you pass into it, so I wouldn't be willing to do that. If you can make it just the height changes, I might could accept that.