我在这里因为我无法覆盖我的SelectionForm。我想将placeHolder的颜色更改为从红色到另一种颜色的图像。在材料ui Docs我找不到任何属性或道具来改变颜色..有人可以帮助我吗?
我正在使用此代码
<div className="row">
{
Object.keys(FILTRO_AGENZIA_MAPPER).map((key5: string, w: number) =>
<div className="col-sm-2" key={key5 + w} style={{display: 'inline'}}>
<Field name={FILTRO_AGENZIA_MAPPER[key5] || key5}
component={renderSelectField}
key={key5 + w}
label={FILTRO_AGENZIA_MAPPER[key5]}>
{
Object.keys(FILTRO_AGENZIA_VALUES).map((key6: string, y: number) =>
<MenuItem key={key6 + y} value={FILTRO_AGENZIA_VALUES[key6] || key6}>
{FILTRO_AGENZIA_VALUES[key6] || key6}
</MenuItem>)
}
</Field>
</div>
)}
</div>
export const renderSelectField: React.FunctionComponent = ({label, children}: TextFieldProps): any => {
return (
<FormControl fullWidth={true}>
<InputLabel>{label}</InputLabel>
<Select>
{children}
</Select>
</FormControl>
)
}
你可以覆盖error
css class,看看this代码示例。