无法弄清楚将大括号放在哪里以及其他错误?
我正在尝试从该网站添加一个简单的向下滚动图标动画, https://codepen.io/TKS31/pen/gOaKaxx 到我的项目,但我收到错误。
10 problems
} expected css(css-rcurlyexpected) x1
{ expected css(css-rcurlyexpected) x8
at-rule or selector expected css(css-ruleorselectorexpected)
CSS:
.scroll {
width: 60px;
height: 60px;
border: 2px solid #333;
border-radius: 50%;
position: relative;
animation: down 1.5s infinite;
-webkit-animation: down 1.5s infinite;
&::before {
content: '';
position: absolute;
top: 15px;
left: 18px;
width: 18px;
height: 18px;
border-left: 2px solid red;
border-bottom: 2px solid red;
transform: rotate(-45deg);
}
}
问题来自这里的某个地方,因为一旦我删除这部分,问题就消失了。对于这一切还是新鲜事。它可以在网站上运行,但不能在我的项目上运行。
I'm trying to add a simple scroll-down icon animation from this website,
https://codepen.io/TKS31/pen/gOaKaxx
to my project but I'm getting an error.
10 problems
} expected css(css-rcurlyexpected) x1
{ expected css(css-rcurlyexpected) x8
at-rule or selector expected css(css-ruleorselectorexpected)
CSS:
.scroll {
width: 60px;
height: 60px;
border: 2px solid #333;
border-radius: 50%;
position: relative;
animation: down 1.5s infinite;
-webkit-animation: down 1.5s infinite;
&::before {
content: '';
position: absolute;
top: 15px;
left: 18px;
width: 18px;
height: 18px;
border-left: 2px solid red;
border-bottom: 2px solid red;
transform: rotate(-45deg);
}
}
The problem is coming from somewhere here because as soon as I delete this part, the problem goes away. Still new to all of this. It works on the website but not on my project.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论