【发布时间】:2020-12-20 18:32:36
【问题描述】:
我想根据手风琴是否展开来更改图标。
我在 CSS 具有 .Mui-expanded 的材料 ui 页面上看到,它可以查看 expand={true} 还是 false,但是当扩展为 true 或 false 时,我如何使用它来设置不同的图标。
因此,如果 expand 为 true,我想设置 IconA,如果 expand 为 false,我想设置 IconB。
expandIcon={<IconA/>}
【问题讨论】:
标签: reactjs typescript material-ui accordion