市北互联平台前端仓库
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

105 lines
2.0 KiB

3 years ago
<template>
3 years ago
<div class="msg-tips" :class="showTips && 'show-tips'">
3 years ago
<el-card class="tips-card">
<div class="tips-wr">
<div class="tips-wr-title">通知提醒</div>
3 years ago
<div class="tips-wr-name">{{ info.typeName }}</div>
<div class="tips-wr-desc">{{ info.content }}</div>
<div class="tips-wr-time">{{ info.remindTime }}</div>
3 years ago
<div class="tips-btn">
<el-button type="text" size="small" @click="handleClose">我知道了</el-button>
<el-button class="diy-button--search" size="small" @click="handleLook">查看详情</el-button>
</div>
</div>
</el-card>
</div>
</template>
<script>
export default {
props: {
show: {
type: Boolean,
3 years ago
default: false
3 years ago
},
info: {
type: Object,
default: () => {}
3 years ago
}
},
data() {
return {
showTips: false
}
},
created() {
this.showTips = this.show
},
methods: {
handleClose() {
this.showTips = false
3 years ago
this.$emit('close')
3 years ago
},
handleLook() {
this.$emit('look')
}
}
}
</script>
<style lang="scss" scoped>
.msg-tips {
position: fixed;
right: 0;
3 years ago
bottom: -220px;
3 years ago
z-index: 999;
transition: bottom .5s;
.tips-card {
width: 400px;
height: 200px;
background: #fff;
}
.tips-wr-title {
font-size: 16px;
color: #3E8EF7;
}
.tips-wr-name {
margin-top: 10px;
padding-left: 20px;
font-weight: bold;
}
.tips-wr-desc {
width: 100%;
3 years ago
height: 33px;
3 years ago
margin-top: 10px;
padding-left: 20px;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
overflow: hidden;
}
.tips-wr-time {
margin-top: 10px;
padding-left: 20px;
}
.tips-btn {
display: flex;
align-items: center;
justify-content: space-around;
width: 100%;
box-sizing: border-box;
margin-top: 10px;
padding: 0 20px;
text-align: center;
}
}
.hide-tips {
bottom: -220px;
3 years ago
transition: bottom .5s;
3 years ago
}
.show-tips {
bottom: 0px;
3 years ago
transition: bottom .5s;
3 years ago
}
</style>