在右侧,我有社交媒体图标。当您滚动到一个时,其他的应该会消失,而您悬停的那个应该会留下。这适用于 jsfiddle,但不适用于我的页面。
此外,当您将鼠标悬停时,图标的名称应该显示在其上方。确实如此,但它非常紧张,但是在 jsfiddle 中它可以正常工作......
有什么想法吗?
该网站位于
非常感谢!
.social { list-style:none;margin:0; padding:0;}
.social li { display:inline; float:left;}
.social li a { display:block;width:32px; height:32px; position:relative; text- decoration:none; padding-right:-5px}
.social li a strong { font-weight:normal; position:absolute; left:30px; top:-1px; color:#fff; padding:3px; z-index:9999;
text-shadow:1px 1px 0 rgba(0, 0, 0, 0.75); background-color:rgba(0, 0, 0, 0.7);
-moz-border-radius:3px; -moz-box-shadow: 0 0 5px rgba(0, 0, 0, 0.5); -webkit-border-radius:3px; -webkit-box-shadow: 0 0 5px rgba(0, 0, 0, 0.5); border-radius:3px; box-shadow: 0 0 5px rgba(0, 0, 0, 0.5);
}
</p>
/* SOCIAL ICONS - CSS3 */
#css3:hover li { opacity:0.2; }
#css3 li { -webkit-transition-property: opacity; -webkit-transition-duration: 500ms;
-moz-transition-property: opacity; -moz-transition-duration: 500ms; }
#css3 li a strong { opacity:0;
-webkit-transition-property: opacity, top; -webkit-transition-duration: 300ms;
-moz-transition-property: opacity, top; -moz-transition-duration: 300ms; }
#css3 li:hover { opacity:1; }
#css3 li:hover a strong { opacity:1; top:-30px; }
li.facebook{background:url("http://static.tumblr.com/4aqmjkd/kVVm77wsy/facebook-32x32.png" ) no-repeat; width:32px; height:32px;}
li.twitter {background:url("http://static.tumblr.com/4aqmjkd/yllm77x0x/twitter-32x32.png") no-repeat; width:32px; height:32px;}
li.flickr {background:url("http://static.tumblr.com/4aqmjkd/ZzZm77wzi/flickr-32x32.png") no-repeat; width:32px; height:32px;}
li.pintrest {background:url("http://static.tumblr.com/4aqmjkd/9RNm77x0c/pintrest__32_x_32.png") no-repeat; width:32px; height:32px;}
li.etsy {background:url("http://static.tumblr.com/4aqmjkd/lWXm77wyk/etsy_32_x_32.png") no-repeat; width:32px; height:32px;}
li.contact {background:url("http://static.tumblr.com/4aqmjkd/f5om77wxr/email_32_x_32.png") no-repeat; width:32px; height:32px;}
<ul class="social" id="css3">
<li class="facebook"><a href="http://www.facebook.com/lolabellasco" target="_blank"><strong>Facebook</strong></a></li>
<li class="twitter"><a href="http://twitter.com/lolabellasco" target="_blank"><strong>Twitter</strong></a></li>
<li class="flickr"><a href="http://www.flickr.com" target="_blank"><strong>Flickr</strong></a></li>
<li class="pintrest"><a href="http://pinterest.com/lolabellas/" target="_blank"><strong>Pintrest</strong></a></li>
<li class="etsy"><a href="http://lolabellas.etsy.com" target="_blank"><strong>Etsy</strong></a></li>
<li class="contact"><a href="mailto:lolabellasetsy@gmail.com"><strong>Contact</strong></a></li>
</ul>