|
|
|
@ -56,8 +56,8 @@
|
|
|
|
|
</div>
|
|
|
|
|
<div class="news-elevator">
|
|
|
|
|
<ul class="news-elevator-list">
|
|
|
|
|
<li><a href="#"></a>新鲜好物</li>
|
|
|
|
|
<li><a href="#"></a>人气推荐</li>
|
|
|
|
|
<li><a href="#">新鲜好物</a></li>
|
|
|
|
|
<li><a href="#">人气推荐</a></li>
|
|
|
|
|
<li><a href="#">热门品牌</a></li>
|
|
|
|
|
<li><a href="#">最新专题</a></li>
|
|
|
|
|
<li><a href="#">顶部</a></li>
|
|
|
|
@ -157,7 +157,7 @@
|
|
|
|
|
const elevator = document.querySelector('.news-elevator')
|
|
|
|
|
window.addEventListener('scroll',function(){
|
|
|
|
|
const n = document.documentElement.scrollTop
|
|
|
|
|
if (n >=300){
|
|
|
|
|
if (n >=500){
|
|
|
|
|
elevator.style.opacity = 1
|
|
|
|
|
}else{
|
|
|
|
|
elevator.style.opacity = 0
|
|
|
|
|