【发布时间】:2022-01-14 21:21:25
【问题描述】:
我正在使用材质 ui 并尝试更改日历的主题,但文本框已更改,尽管日历不受主题影响我也在发布图像和代码 sn-ps 也在这里
dateIcon: {
'input[type="date"]::-webkit-calendar-picker-indicator': {
color: 'green',
},
},
DateBackGround: {
background: theme.palette.background.paper,
color: theme.palette.text.primary,
'& .MuiOutlinedInput-input': {
paddingRight: 2,
},
},
<Grid item xs={6}>
<div>
<OutlinedTextField
variant="outlined"
type="date"
id="by-this-date"
size="small"
onChange={updateWhatIfDate}
value={expiryDateFormatted}
className={`${`textInput`} ${classes.DateBackGround} ${classes.dateIcon}`}
style={{ width: '100%' }}
/>
</div>
</Grid>
提前致谢
【问题讨论】:
标签: javascript reactjs typescript material-ui