- topMenu.js: 添加 home-btn 圆形按钮 (el-icon-s-home) - topMenu.js: 添加 goIndex() 方法跳转 /index - dark-override.css: home-btn 图标样式(18px/灰色/hover蓝)
This commit is contained in:
@@ -89,6 +89,11 @@ const topMenu = {
|
|||||||
</el-autocomplete>
|
</el-autocomplete>
|
||||||
</div>
|
</div>
|
||||||
<div class="header-right">
|
<div class="header-right">
|
||||||
|
<div class="header-right-item">
|
||||||
|
<div class="right-item home-btn" @click="goIndex">
|
||||||
|
<i class="el-icon-s-home"></i>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<div class="header-right-item car-item">
|
<div class="header-right-item car-item">
|
||||||
<div v-if="isShowCart" class="right-item" @click="goShoppingCar">
|
<div v-if="isShowCart" class="right-item" @click="goShoppingCar">
|
||||||
<el-badge :value="shoppingCarNum" class="item" :max="999" :hidden="shoppingCarNum === 0 ? true : false">
|
<el-badge :value="shoppingCarNum" class="item" :max="999" :hidden="shoppingCarNum === 0 ? true : false">
|
||||||
@@ -409,6 +414,9 @@ const topMenu = {
|
|||||||
this.isGetData = true;
|
this.isGetData = true;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
goIndex () {
|
||||||
|
location.href = "/index";
|
||||||
|
},
|
||||||
goShoppingCar () {
|
goShoppingCar () {
|
||||||
localStorage.frontMenusActiveId = "";
|
localStorage.frontMenusActiveId = "";
|
||||||
location.href = "/cart/shoppingCar.htm";
|
location.href = "/cart/shoppingCar.htm";
|
||||||
|
|||||||
@@ -150,11 +150,21 @@ html, body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.header-right .header-right-item {
|
.header-right .header-right-item {
|
||||||
display: flex !important;
|
display: flex;
|
||||||
align-items: center !important;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* ============ 顶栏右侧按钮 — 纯圆形 ============ */
|
/* ============ 顶栏右侧按钮 — 纯圆形 ============ */
|
||||||
|
/* 首页按钮 */
|
||||||
|
.home-btn i {
|
||||||
|
font-size: 18px !important;
|
||||||
|
color: #4E5969 !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.home-btn:hover i {
|
||||||
|
color: #165DFF !important;
|
||||||
|
}
|
||||||
|
|
||||||
/* 购物车按钮 */
|
/* 购物车按钮 */
|
||||||
.header-right .header-right-item .right-item {
|
.header-right .header-right-item .right-item {
|
||||||
width: 36px !important;
|
width: 36px !important;
|
||||||
|
|||||||
Reference in New Issue
Block a user