mirror of
https://github.com/kuaifan/dootask.git
synced 2026-02-02 02:48:13 +00:00
perf: 优化消息未读数
This commit is contained in:
parent
2aa687a40b
commit
5afed4b85e
@ -152,7 +152,9 @@ export default {
|
|||||||
},
|
},
|
||||||
}).then(({data}) => {
|
}).then(({data}) => {
|
||||||
this.read_list = data;
|
this.read_list = data;
|
||||||
this.$refs.percent.updatePopper();
|
this.$nextTick(() => {
|
||||||
|
this.$refs.percent.updatePopper();
|
||||||
|
})
|
||||||
}).catch(() => {
|
}).catch(() => {
|
||||||
this.read_list = [];
|
this.read_list = [];
|
||||||
});
|
});
|
||||||
|
|||||||
@ -90,8 +90,13 @@
|
|||||||
</div>
|
</div>
|
||||||
</ScrollerY>
|
</ScrollerY>
|
||||||
<div class="messenger-menu">
|
<div class="messenger-menu">
|
||||||
<Icon @click="tabActive='dialog'" :class="{active:tabActive==='dialog'}" type="ios-chatbubbles" />
|
<div class="menu-icon">
|
||||||
<Icon @click="tabActive='contacts'" :class="{active:tabActive==='contacts'}" type="md-person" />
|
<Icon @click="tabActive='dialog'" :class="{active:tabActive==='dialog'}" type="ios-chatbubbles" />
|
||||||
|
<Badge class="menu-num" :count="msgUnread('all')"/>
|
||||||
|
</div>
|
||||||
|
<div class="menu-icon">
|
||||||
|
<Icon @click="tabActive='contacts'" :class="{active:tabActive==='contacts'}" type="md-person" />
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
35
resources/assets/sass/pages/page-messenger.scss
vendored
35
resources/assets/sass/pages/page-messenger.scss
vendored
@ -281,18 +281,31 @@
|
|||||||
height: 52px;
|
height: 52px;
|
||||||
flex-shrink: 0;
|
flex-shrink: 0;
|
||||||
border-top: 1px solid #f4f5f5;
|
border-top: 1px solid #f4f5f5;
|
||||||
> i {
|
.menu-icon {
|
||||||
cursor: pointer;
|
height: 100%;
|
||||||
font-size: 24px;
|
display: flex;
|
||||||
margin: 0 24px;
|
align-items: center;
|
||||||
color: #aaaaaa;
|
position: relative;
|
||||||
opacity: 0.9;
|
.menu-num {
|
||||||
&.active {
|
position: absolute;
|
||||||
opacity: 1;
|
top: 4px;
|
||||||
color: $primary-color;
|
left: 50%;
|
||||||
|
margin-left: 3px;
|
||||||
|
transform: scale(0.8);
|
||||||
}
|
}
|
||||||
&:hover {
|
> i {
|
||||||
opacity: 1;
|
cursor: pointer;
|
||||||
|
font-size: 24px;
|
||||||
|
margin: 0 24px;
|
||||||
|
color: #aaaaaa;
|
||||||
|
opacity: 0.9;
|
||||||
|
&.active {
|
||||||
|
opacity: 1;
|
||||||
|
color: $primary-color;
|
||||||
|
}
|
||||||
|
&:hover {
|
||||||
|
opacity: 1;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user