<AutoModeIcon style={{background: 'linear-gradient(to right bottom, #430089, #82ffa1)'}} sx={{ fontSize: "40px" }}/>
如何正确传递 prop ?因为背景:对那个不起作用
9avjhtql1#
<> <svg width={0} height={0}> <linearGradient id="linearColors" x1={0} y1={0} x2={1} y2={1}> <stop offset={0} stopColor="rgba(78, 91, 135, 1)" /> <stop offset={1} stopColor="rgba(174, 190, 241, 1)" /> </linearGradient> </svg> <AutoModeIcon sx={{ fontSize:40, fill: "url(#linearColors)" }} /> </> )``` Well i founded an solution, not sure if its a correct one
1条答案
按热度按时间9avjhtql1#