gpt4 book ai didi

CSS 可见性属性在 Firefox 中不起作用,当悬停 div 时内部 标记不显示

转载 作者:行者123 更新时间:2023-11-28 02:52:40 24 4
gpt4 key购买 nike

最佳答案

您可以试试这个:注意:这是解决您问题的方法

.circle {
margin: 36px;
display: inline-block;
padding: 16px;
text-align: center;
width: 180px;
height: 180px;
border-radius: 50%;
border: 2px solid #1d2087;
}

.circle::before,
.circle::after {
position: absolute;
z-index: -1;
display: block;
content: '';
}
.circle,
.circle::before,
.circle::after {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
box-sizing: border-box;
-webkit-transition: all .5s;
transition: all .5s;
}

.circle {
position: relative;
z-index: 2;
background-color: #fff;
border: 2px solid #5c5eae;
color: transparent;
line-height: 50px;
overflow: hidden;
}

.circle::after {
top: 0;
left: 0;
width: 100%;
height: 100%;
border-radius: 50%;
-webkit-transform: scale(.5);
transform: scale(.5);
}
.circle:hover::after {
background: #5c5eae;
border-radius: 50%;
-webkit-transform: scale(.9);
transform: scale(.9);
}

.circle1 {
opacity: 0.4;
}

.circle2 {
opacity: 0.6;
}

.circle3 {
opacity: 0.8;
}

.circle a {
text-decoration: none;
color: transparent;
}

.circle h2 {
font-size: 60px;
}

.circle h2 small {
color: transparent;
}

.circle p {
font-size: 24px;
line-height: 26px;
}
a.hyper:hover {
color: #fff;
visibility: visible;
}

a:hover, p:hover, .circle:hover, h2:hover{
color: #fff;
}
<div class="col-lg-3 col-md-3 col-sm-6" style="font-family: arial;">
<div class="circle" id="userImg" style="background-image: url('http://i68.tinypic.com/1zfr32v.png'); background-position: center;">
<a href="javascript:void(0);" onClick="LoadUrl('upd-details.jsp',1)" class="hyper"><h1>Profile<small></small><p>Update</p></h1></a>
</div>
</div>

注意:如果您愿意,您也可以删除 visibility 属性,因为您的代码中不需要它。

关于CSS 可见性属性在 Firefox 中不起作用,当悬停 div 时内部 <a> 标记不显示,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46601098/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com