我试图将Figma设计转换为代码,但它有一些使用内部阴影效果的文本
我try 使用纯文本和剪切文本阴影CSS属性来设置样式,但结果与阴影类剪切/插入文本的设计不太匹配.
h1 {
font-family: 'Poppins';
font-style: normal;
font-size: 80px;
text-align: center;
color: #6225E6;
text-shadow: -6px 0px 0px #D63737;
background-color: #151717;
}
<link href="https://fonts.googleapis.com/css2?family=Poppins&display=swap" rel="stylesheet">
<h1>This is some text<h1/>