gpt4 book ai didi

html - 尝试将鼠标悬停在显示照片时如何停止闪烁背景

转载 作者:太空宇宙 更新时间:2023-11-04 03:42:09 25 4
gpt4 key购买 nike

我正在制作一个包含两个图像的显示(当你喜光时切换)但是当你这样做时容器会填充背景颜色,周围区域也会填充背景颜色

这是有问题的代码的一部分,其余部分与第一个产品几乎相同。如果有人可以看一下,将不胜感激。谢谢。 *图片只有1-1.6mb大

    <section class="wrap hidden-phone">        
<div class="wrapper">

<section class="featured">

<div class="container">
<div class="row">
<div class="span9">


<ul class="product-list isotope">
<li data-price="195">
<a href="/Pages/empty357.html" title="Classic Test">
<div class="image">
<img class="primary" src="images/features/baretest.jpg" alt="That Bare Test doe" />
<img class="secondary" src="images/features/bare%20t%20sc.jpg" alt="What you know bout this test doe" />
</div>
<div class="title">
<div class="prices">
<span class="price">$3HUNNAH</span>
</div>
<h3>Bare Test</h3>
</div>
</a>
</li>


<li class="standard" data-price="228">
<a href="product/navy-linen-blazer.1" title="Navy Linen Blazer">

<div class="image">
<img class="primary" src="images/features/IMG_8652.jpg" alt="Navy Linen Blazer" />

<img class="secondary" src="images/features/IMG_8658.jpg" alt="Navy Linen Blazer" />

</div>

<div class="title">
<div class="prices"><span class="price">$228.00</span></div>
<h3>Navy Linen Blazer</h3>

</div>

</a>
</li>



</div>


</div>
</div>
</section>


</section>








@media (max-width: 767px) {
.container {
padding: 0 10px;
width: 540px;
}
}
@media (max-width: 479px) {
.container {
padding: 0 10px;
width: 300px;
}
}





#load_more [class^="icon-"] {
display: none;
}
#load_more .icon-spin {
-webkit-animation-duration: 1s;
-moz-animation-duration: 1s;
-o-animation-duration: 1s;
-ms-animation-duration: 1s;
animation-duration: 1s;
}
#load_more.loading {
-webkit-opacity: 0.5;
-moz-opacity: 0.5;
opacity: 0.5;
}
#load_more.loading [class^="icon-"] {
display: inline-block;
}
.product-list {
margin-left: -30px;
overflow: visible !important;
zoom: 1;
}
.product-list:before {
content: '';
display: block;
}
.product-list:after {
content: '';
display: table;
clear: both;
}
@media (min-width: 768px) and (max-width: 979px) {
.product-list {
margin-left: -20px;
}
}
@media (max-width: 767px) {
.product-list {
margin-left: -20px;
}
}
@media (max-width: 480px) {
.product-list {
margin-left: 0;
}
}
.product-list li {
list-style: none;
width: 270px;
float: left;
margin-left: 30px;
margin-bottom: 30px;
}
@media (min-width: 980px) and (max-width: 1199px) {
.product-list li {
width: 213px;
}
}
@media (min-width: 768px) and (max-width: 979px) {
.product-list li {
width: 166px;
margin-left: 20px;
margin-bottom: 20px;
}
}
@media (max-width: 767px) {
.product-list li {
width: 210px;
margin-left: 20px;
margin-bottom: 20px;
}
}
@media (max-width: 480px) {
.product-list li {
width: 300px;
margin-left: 0;
margin-bottom: 20px;
}
}
.product-list li.featured {
width: 570px;
background-color:#2980b9
}
@media (min-width: 980px) and (max-width: 1199px) {
.product-list li.tu
tured {
width: 456px;
}
}
@media (min-width: 768px) and (max-width: 979px) {
.product-list li.featured {
width: 352px;
}
}
@media (max-width: 767px) {
.product-list li.featured {
width: 40px;
}
}
@media (max-width: 480px) {
.product-list li.featured {
width: 300px;
}
}
.product-list a {
position: relative;
display: block;
color: inherit;
text-decoration: none;
z-index: 20;
-webkit-box-shadow: 0 1px 2px rgba(71, 73, 72, 0.19999999999999996);
-moz-box-shadow: 0 1px 2px rgba(71, 73, 72, 0.19999999999999996);
box-shadow: 0 1px 2px rgba(71, 73, 72, 0.19999999999999996);
color: 0 1px 2px rgba(71, 73, 72, 0.19999999999999996);
}
.product-list a:hover {
-webkit-box-shadow: 0 2px 3px rgba(71, 73, 72, 0.5);
-moz-box-shadow: 0 2px 3px rgba(71, 73, 72, 0.5);
box-shadow: 0 2px 3px rgba(71, 73, 72, 0.5);
color: 0 2px 3px rgba(71, 73, 72, 0.5);
}
.product-list a:hover .image .secondary {
-webkit-opacity: 1;
-moz-opacity: 1;
opacity: 1;
}
.product-list a:hover .title .rating {
color: #3498db;
}
.product-list a .image {
position: relative;
background: url('../../img/preloader.gif') no-repeat center center;
}
.product-list a .image img {
display: block;
width: 100%;
}
.product-list a .image .secondary {
position: absolute;
top: 0;
-webkit-transition: all 200ms ease-in-out;
-moz-transition: all 200ms ease-in-out;
-o-transition: all 200ms ease-in-out;
-ms-transition: all 200ms ease-in-out;
transition: all 200ms ease-in-out;
-webkit-opacity: 0;
-moz-opacity: 0;
opacity: 0;
}
.product-list a .image .badge-sale {
position: absolute;
right: -10px;
top: 40px;
background-color: #2980b9;
font-size: 12px;
line-height: 12px;
padding: 4px 8px;
text-transform: uppercase;
-webkit-border-radius: 2px 2px 0 2px;
-webkit-background-clip: padding-box;
-moz-border-radius: 2px 2px 0 2px;
-moz-background-clip: padding;
border-radius: 2px 2px 0 2px;
background-clip: padding-box;
}
.product-list a .image .badge-sale:after {
content: '';
display: block;
width: 0;
height: 0;
border: 10px solid;
border-color: #0e6252 transparent transparent transparent;
position: absolute;
right: 0;
bottom: -20px;
z-index: -10;
}
.product-list a .title {
padding: 20px;
position: relative;
background-color: #ffffff;
}
.product-list a .title:before {
content: "";
display: block;
width: 16px;
height: 16px;
background-color: #ffffff;
position: absolute;
left: 20px;
top: -8px;
-webkit-transform: rotate(45deg);
-moz-transform: rotate(45deg);
-o-transform: rotate(45deg);
-ms-transform: rotate(45deg);
transform: rotate(45deg);
}
.product-list a .title .prices {
text-align: right;
float: right;
margin-left: 20px;
line-height: 20px;
height: 20px;
}
.product-list a .title .prices .price {
color: #7f8c8d;
font-weight: 600;
font-size: 14px;
}
.product-list a .title .prices .base {
color: #c7c8c8;
font-weight: 400;
font-size: 11px;
}
.product-list a .title h3 {
margin: 0;
font-size: 14px;
line-height: 20px;
font-weight: 700;
}
.product-list a .title .rating {
margin-top: 10px;
font-size: 12px;
line-height: 15px;
color: #c7c8c8;
}

最佳答案

您需要从 CSS 类 .product-list a:hover 中删除 box-shadow

Fiddle


来自这个

.product-list a:hover {
-webkit-box-shadow: 0 2px 3px rgba(71, 73, 72, 0.5);
-moz-box-shadow: 0 2px 3px rgba(71, 73, 72, 0.5);
box-shadow: 0 2px 3px rgba(71, 73, 72, 0.5);
color: 0 2px 3px rgba(71, 73, 72, 0.5);
}

对此

.product-list a:hover {
color: 0 2px 3px rgba(71, 73, 72, 0.5);
}

关于html - 尝试将鼠标悬停在显示照片时如何停止闪烁背景,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/24720584/

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