<ul> <li> <a href=""> <img src="../../../img/goods/study.png" alt="学习"> <img class="hide_tab" src="../../../img/goods/study_1.png" alt="学习"> </a> </li> <li> <a href=""> <img src="../../../img/goods/life.png" alt="生活"> <img class="hide_tab" src="../../../img/goods/life_1.png" alt="生活"> </a> </li> <li> <a href="" > <img src="../../../img/goods/sport.png" alt="运动"> <img class="hide_tab" src="../../../img/goods/sport_1.png" alt="运动"> </a> </li> <li> <a href=""> <img src="../../../img/goods/clothes.png" alt="服饰"> <img class="hide_tab" src="../../../img/goods/clothes_1.png" alt="服饰"> </a> </li> <li> <a href="" > <img src="../../../img/goods/hat.png" alt="鞋帽"> <imgclass="hide_tab" src="../../../img/goods/hat_1.png" alt="鞋帽"> </a> </li> <li> <a href="" > <img src="../../../img/goods/food.png" alt="食品"> <img class="hide_tab" src="../../../img/goods/food_1.png" alt="食品"> </a> </li> <li> <a href=""> <img src="../../../img/goods/other.png" alt="其他"> <img class="hide_tab" src="../../../img/goods/other_1.png" alt="其他"> </a> </li> </ul>
.right {
float: left;
ul {
margin-left: 1px;
li {
display: inline-block;
margin-left: 12px;
width: 100px;
height: 100px;
a{
position: relative;
display: inline-block;
width: 100px;
height: 100px;
.hide_tab{
position: absolute;
bottom: 0;
}
}
}
}
}
data(){
return{
active: 0
}
}
showActive(index) {
this.active = index;
}
<ul> <li> <a href="" @mouseenter="showActive(1)" @mouseleave="showActive(0)"> <img src="../../../img/goods/study.png" alt="学习"> <img v-show="active === 1" class="hide_tab" src="../../../img/goods/study_1.png" alt="学习"> </a> </li> <li> <a href="" @mouseenter="showActive(2)" @mouseleave="showActive(0)"> <img src="../../../img/goods/life.png" alt="生活"> <img v-show="active === 2" class="hide_tab" src="../../../img/goods/life_1.png" alt="生活"> </a> </li> <li> <a href="" @mouseenter="showActive(3)" @mouseleave="showActive(0)"> <img src="../../../img/goods/sport.png" alt="运动"> <img v-show="active === 3" class="hide_tab" src="../../../img/goods/sport_1.png" alt="运动"> </a> </li> <li> <a href="" @mouseenter="showActive(4)" @mouseleave="showActive(0)"> <img src="../../../img/goods/clothes.png" alt="服饰"> <img v-show="active === 4" class="hide_tab" src="../../../img/goods/clothes_1.png" alt="服饰"> </a> </li> <li> <a href="" @mouseenter="showActive(5)" @mouseleave="showActive(0)"> <img src="../../../img/goods/hat.png" alt="鞋帽"> <img v-show="active === 5" class="hide_tab" src="../../../img/goods/hat_1.png" alt="鞋帽"> </a> </li> <li> <a href="" @mouseenter="showActive(6)" @mouseleave="showActive(0)"> <img src="../../../img/goods/food.png" alt="食品"> <img v-show="active === 6" class="hide_tab" src="../../../img/goods/food_1.png" alt="食品"> </a> </li> <li> <a href="" @mouseenter="showActive(7)" @mouseleave="showActive(0)"> <img src="../../../img/goods/other.png" alt="其他"> <img v-show="active === 7" class="hide_tab" src="../../../img/goods/other_1.png" alt="其他"> </a> </li> </ul>
机械节能产品生产企业官网模板...
大气智能家居家具装修装饰类企业通用网站模板...
礼品公司网站模板
宽屏简约大气婚纱摄影影楼模板...
蓝白WAP手机综合医院类整站源码(独立后台)...苏ICP备2024110244号-2 苏公网安备32050702011978号 增值电信业务经营许可证编号:苏B2-20251499 | Copyright 2018 - 2025 源码网商城 (www.ymwmall.com) 版权所有