Attached Image of icon to set the thickness
我试图在 css 中使用 stroke 和 stroke-width 设置圆的厚度,但它们都不起作用。图标是从 antdesign 导入的。
任何人都可以帮助解决这个问题?非常感激。谢谢
目前我的代码看起来像这样( react )
<PlusCircleOutlined
style={{
fontSize: "50px",
color: "#408021",
storke: "#408021",
strokeWidth: "2px",
}}
/>
enter code here
最佳答案
你有一个拼写错误“storke”,应该是“stroke”,但这不是问题。要使线条更粗,您需要使用 stroke
属性等于 white
或等于背景颜色以删除部分填充区域:
<PlusCircleOutlined style={{
fontSize: "50px",
color: "#408021",
strokeWidth: "30", // --> higher value === more thickness the filled area
stroke: "white"
}}/>
关于css - 在 CSS 中设置 Ant 设计图标的粗细,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/65466866/