盘旋时从按钮上删除丑陋的白色阴影
每当我徘徊在创建的按钮上时,它都会有一个白色,在过渡中看起来很丑。我需要帮助来删除此问题。
该按钮具有两个不同的CSS块:一个用于按钮本身,另一个块为.morb_button
对于不同网页上的同一按钮。
button {
background-color: #961a75;
border-radius: 5px;
color: white;
padding: 15px 32px;
text-align: center;
display: inline-block;
font-size: 25px;
border:none;
box-shadow: 1px 1px 3px #323d73;
cursor:pointer;
transition-duration: 0.2s;
font-family: Gill Sans
}
button:hover {
background-color: #cc5caf;
color: white;
box-shadow: 0px 0px 0px
}
.morb_button {
background-color:#022b27;
box-shadow: 2px 2px 3px #4a0404
}
.morb_button:hover {
background-color: #03524a;
}
Whenever I hover over my button that I created, it has a white which looks ugly in the transition. I need help to remove this.
The button has two different blocks of css: one for the button itself and other block is .morb_button
for the same button on a different webpage.
button {
background-color: #961a75;
border-radius: 5px;
color: white;
padding: 15px 32px;
text-align: center;
display: inline-block;
font-size: 25px;
border:none;
box-shadow: 1px 1px 3px #323d73;
cursor:pointer;
transition-duration: 0.2s;
font-family: Gill Sans
}
button:hover {
background-color: #cc5caf;
color: white;
box-shadow: 0px 0px 0px
}
.morb_button {
background-color:#022b27;
box-shadow: 2px 2px 3px #4a0404
}
.morb_button:hover {
background-color: #03524a;
}
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您已经在摘要中使用了两次属性
box-shadow
。删除其中的任何一个以解决此问题。You have used the property
box-shadow
twice in the snippet. Remove either of them to fix this.删除此规则,因为它是将白色阴影赋予按钮的规则。
Remove this rule, because it's the one that gives the white shadow to the button.