kotlin-material-ui icon indicating copy to clipboard operation
kotlin-material-ui copied to clipboard

Inconsistent behavior of `inputProps`

Open altavir opened this issue 4 years ago • 1 comments

Switch element exposes input properties as INPUT.() -> Unit, while TextField exposes them as InputElementBuilder<InputProps>.() -> Unit. The resulting code looks different for different elements which does not look good. It seems like Switch way is preferable.

Actually, these two lines:

    var Tag.InputProps: RProps? by materialProps
    var Tag.inputProps: RProps? by materialProps

look really uncomfortable.

altavir avatar May 10 '20 12:05 altavir

It seems like this one is a problem of Material-UI, not the wrapper. Still, for those not familiar with it, it is really confusing. I think that the difference should be documented.

altavir avatar May 10 '20 19:05 altavir