@mui/material
Version:
Material UI is an open-source React component library that implements Google's Material Design. It's comprehensive and can be used in production out of the box.
14 lines • 381 B
JavaScript
export default function formControlState(_ref) {
var props = _ref.props,
states = _ref.states,
muiFormControl = _ref.muiFormControl;
return states.reduce(function (acc, state) {
acc[state] = props[state];
if (muiFormControl) {
if (typeof props[state] === 'undefined') {
acc[state] = muiFormControl[state];
}
}
return acc;
}, {});
}