Commit 9f85bf27 authored by 徐一鸣's avatar 徐一鸣

部署排名分析和评价轮播组件优化

parent 79fb25c9
......@@ -45,11 +45,14 @@ export default {
this.$el.scrollTop = 0;
this.timer = setInterval(() => {
let curScrollTop = this.$el.scrollTop + 50;
if (curScrollTop > this.$el.scrollHeight - this.$el.clientHeight) {
let itemHeight = 77;
let curScrollTop = this.$el.scrollTop + itemHeight;
if (curScrollTop >= this.$el.scrollHeight - this.$el.clientHeight + itemHeight) {
curScrollTop = 0;
}
this.$el.scrollTop = curScrollTop;
this.$el.scrollTop = Math.min(curScrollTop, this.$el.scrollHeight - this.$el.clientHeight);
}, 1500);
},
mouseenter() {
......
......@@ -73,11 +73,14 @@ export default {
this.$el.scrollTop = 0;
this.timer = setInterval(() => {
let curScrollTop = this.$el.scrollTop + 50;
if (curScrollTop > this.$el.scrollHeight - this.$el.clientHeight) {
let itemHeight = 50;
let curScrollTop = this.$el.scrollTop + itemHeight;
if (curScrollTop >= this.$el.scrollHeight - this.$el.clientHeight + itemHeight) {
curScrollTop = 0;
}
this.$el.scrollTop = curScrollTop;
this.$el.scrollTop = Math.min(curScrollTop, this.$el.scrollHeight - this.$el.clientHeight);
}, 1500);
},
mouseenter() {
......@@ -161,7 +164,7 @@ export default {
flex-grow: 1;
}
.item_info > span:first-child {
width: 200px;
width: 100px;
flex-grow: 1;
margin-right: 10px;
}
......@@ -171,6 +174,8 @@ export default {
color: #8e96ab;
}
.item_info > span:nth-child(2) {
flex-shrink: 0;
white-space: nowrap;
color: #0d1847;
}
.item_progress {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment