假设我在下面有这些标签。如何将 MUIprimary
和secondary
颜色用于内联 CSS?我想使用调色板中的颜色来自定义它。
<Tabs
value={value}
onChange={handleChange}
variant='fullWidth'
aria-label="simple tabs example"
className="tableViewTabs"
centered
color="primary"
// inkBarStyle={{backgroundColor: '#68C222', width: '33.3%'}}
// tabItemContainerStyle={{backgroundColor: '#FFFFFF', width: '30%'}}
>
<Tab
icon={<GradeIcon/>}
{...a11yProps(0)}
disableFocusRipple={true}
disableRipple = {true}
color="primary"
style={{ textTransform: "none", fontSize: 16, color: value === 0 ? "" : "" }}
/>
<Tab
icon={<ViewAgendaIcon />}
{...a11yProps(1)}
disableFocusRipple={true}
disableRipple={true}
style={{ textTransform: "none", fontSize: 16, fontWeight: value === 1 ? "bold" : "" }}
/>
<Tab
icon={<AppsIcon />}
{...a11yProps(2)}
disableFocusRipple = {true}
disableRipple = {true}
style={{ textTransform: "none", fontSize: 16, fontWeight: value === 2 ? "bold" : "" }}
/>
本文收集自互联网,转载请注明来源。
如有侵权,请联系 [email protected] 删除。
我来说两句