|
@@ -177,7 +177,7 @@ export default {
|
|
|
moveY: 0,
|
|
|
},
|
|
|
widgetListIsBottom: false,
|
|
|
- thumbYHeight: '104px',
|
|
|
+ thumbYHeight: '424px',
|
|
|
thumbYDisplay: 'none',
|
|
|
portalDetail: {
|
|
|
display: "none",
|
|
@@ -290,8 +290,7 @@ export default {
|
|
|
this.$bus.on(
|
|
|
"changeOrHiddenWidgetPosition",
|
|
|
this.changeOrHiddenWidgetPosition
|
|
|
- );
|
|
|
- // this.$bus.on("dialogWindowZIndexIsMax", this.dialogWindowZIndexIsMax);
|
|
|
+ )
|
|
|
let el = document.querySelector(".v-widget-window .ps__thumb-y");
|
|
|
let el1 = document.querySelector(".v-widget-window .v-window-header-wrapper");
|
|
|
el.addEventListener("mouseup", this.mouseupProgress);
|
|
@@ -299,13 +298,17 @@ export default {
|
|
|
let el2 = document.querySelector(".v-widget-window .v-widget-list");
|
|
|
let el3 = document.querySelector(".v-widget-window .ps__rail-y");
|
|
|
if(el2.offsetHeight > el3.offsetHeight){
|
|
|
+ this.bottom = '0'
|
|
|
this.thumbYDisplay = 'block'
|
|
|
this.thumbYHeight = 'calc((100vh - 52px) / 2)'
|
|
|
}
|
|
|
- window.onresize = ()=>{
|
|
|
+ window.onresize = (e)=>{
|
|
|
if(el2.offsetHeight > el3.offsetHeight){
|
|
|
+ this.bottom = '0'
|
|
|
this.thumbYDisplay = 'block'
|
|
|
this.thumbYHeight = 'calc((100vh - 52px) / 2)'
|
|
|
+ }else{
|
|
|
+ this.thumbYDisplay = 'none'
|
|
|
}
|
|
|
}
|
|
|
},
|
|
@@ -318,7 +321,6 @@ export default {
|
|
|
this.$bus.emit("changeMinDefaultZindexWindowCls");
|
|
|
this.$bus.emit("fixWindowZIndexMax", true);
|
|
|
}
|
|
|
- // this.dialogWindowZIndexIsMax(false);
|
|
|
},
|
|
|
// 修改changeFixWindow
|
|
|
changeFixWindowZIndex() {
|
|
@@ -326,7 +328,6 @@ export default {
|
|
|
this.zIndex = 9040;
|
|
|
}
|
|
|
if (this.cls != "deactve-win") this.cls = "deactve-win";
|
|
|
- // this.dialogWindowZIndexIsMax(true);
|
|
|
},
|
|
|
//点击进度条
|
|
|
mousedownProgress(e) {
|
|
@@ -366,8 +367,6 @@ export default {
|
|
|
} else if (moveY > el1.offsetHeight - el.offsetHeight) {
|
|
|
moveY = el1.offsetHeight - el.offsetHeight;
|
|
|
this.widgetListIsBottom = true
|
|
|
-
|
|
|
-
|
|
|
}
|
|
|
let moveY2 =
|
|
|
-(
|
|
@@ -387,11 +386,6 @@ export default {
|
|
|
let el1 = document.querySelector(".v-widget-window .ps__rail-y");
|
|
|
let el2 = document.querySelector(".v-widget-window .v-widget-list");
|
|
|
el.removeEventListener("mousemove", this.moveProgress);
|
|
|
- if(el2.offsetHeight > el1.offsetHeight){
|
|
|
- this.thumbYDisplay = 'block'
|
|
|
- this.thumbYHeight = 'calc((100vh - 52px) / 2)'
|
|
|
- }
|
|
|
- // this.clearProgressMArk();
|
|
|
},
|
|
|
// 滚动窗口列表
|
|
|
scrollList(e) {
|
|
@@ -407,10 +401,6 @@ export default {
|
|
|
// 点击勾选小窗口的加号
|
|
|
selectWidgetItem() {
|
|
|
this.$bus.emit("showOrHiddenSelectWidgetItem", this.portalDetail);
|
|
|
- window.onclick = (e) => {
|
|
|
- e.stopPropagation();
|
|
|
- this.$bus.emit("showOrHiddenSelectWidgetItem", "none");
|
|
|
- };
|
|
|
},
|
|
|
// 点击小窗口选择框的每一项
|
|
|
showOrHiddenWidgetItem(obj) {
|
|
@@ -419,9 +409,9 @@ export default {
|
|
|
this.portalDetail.detailMessageList[obj.index].cls = obj.cls1;
|
|
|
this.portalDetail.detailMessageList.forEach((item) => {
|
|
|
if (item.cls && item.cls.includes(" active")) {
|
|
|
- item.cls = item.cls.replace(" active");
|
|
|
+ item.cls = item.cls.replace(" active",'');
|
|
|
} else if (item.cls && item.cls.includes("active")) {
|
|
|
- item.cls = item.cls.replace("active");
|
|
|
+ item.cls = item.cls.replace("active",'');
|
|
|
}
|
|
|
});
|
|
|
let cls = this.portalDetail.detailMessageList[0].cls;
|
|
@@ -431,35 +421,31 @@ export default {
|
|
|
},
|
|
|
// 跟随可视小窗口的个数改变进度条高度
|
|
|
changeThumbHeight(selectedNum) {
|
|
|
+ let el1= document.querySelector(".v-widget-window .v-widget-list");
|
|
|
+ let el2 = document.querySelector(".v-widget-window .ps__rail-y");
|
|
|
if (selectedNum > 2) {
|
|
|
if (selectedNum >= 6) {
|
|
|
selectedNum = 6;
|
|
|
}
|
|
|
this.thumbYDisplay = "block";
|
|
|
this.thumbYHeight = (7 - selectedNum) * 70 + "px";
|
|
|
- } else {
|
|
|
- this.thumbYDisplay = "none";
|
|
|
+ }else{
|
|
|
+ this.thumbYDisplay = "none";
|
|
|
}
|
|
|
- if(window.screenY <= 250){
|
|
|
- this.bottom = '0'
|
|
|
- this.thumbYDisplay = 'block'
|
|
|
+ if(el2.offsetHeight < 424 && el1.offsetHeight > el2.offsetHeight){
|
|
|
+ this.thumbYDisplay = "block";
|
|
|
this.thumbYHeight = 'calc((100vh - 52px) / 2)'
|
|
|
}
|
|
|
+ // if(this.thumbYHeight >= el.offsetHeight){
|
|
|
+ // this.bottom = '0'
|
|
|
+ // this.thumbYDisplay = 'block'
|
|
|
+ // this.thumbYHeight = 'calc((100vh - 52px) / 2)'
|
|
|
+ // }
|
|
|
this.selectedNum = selectedNum;
|
|
|
},
|
|
|
- // 将记住的进度条坐标重置
|
|
|
- // clearProgressMArk() {
|
|
|
- // this.progrecssFirstClick.clientY = 0
|
|
|
- // this.moveY = 0
|
|
|
- // this.progrecssFirstClick = {
|
|
|
- // lastY: 0,
|
|
|
- // clickY: 0,
|
|
|
- // };
|
|
|
- // },
|
|
|
//点击固定窗口头部
|
|
|
mousedownWidgetHeader(e) {
|
|
|
let el = document.querySelector(".v-widget-window .v-window-header-wrapper");
|
|
|
- let el1 = document.querySelector(".v-widget-window");
|
|
|
this.widgetFirstClick.clientX = e.clientX;
|
|
|
this.widgetFirstClick.offsetX = e.offsetX;
|
|
|
this.widgetFirstClick.screenX = document.documentElement.clientWidth;
|
|
@@ -483,7 +469,6 @@ export default {
|
|
|
if (moveX > this.widgetFirstClick.screenX - el1.offsetWidth) {
|
|
|
moveX = this.widgetFirstClick.screenX - el1.offsetWidth;
|
|
|
}
|
|
|
-
|
|
|
// Y轴
|
|
|
let moveY = 0;
|
|
|
moveY = e.clientY - this.widgetFirstClick.offsetY;
|
|
@@ -545,10 +530,6 @@ export default {
|
|
|
// 显示或隐藏位置选择框
|
|
|
selectWidgetPosition() {
|
|
|
this.$bus.emit("showOrHiddenSelectWidgetPosition", this.portalDetail1);
|
|
|
- window.onclick = (e) => {
|
|
|
- e.stopPropagation();
|
|
|
- this.$bus.emit("showOrHiddenSelectWidgetPosition", "none");
|
|
|
- };
|
|
|
},
|
|
|
//改变固定弹出框的位置
|
|
|
changeOrHiddenWidgetPosition(obj) {
|
|
@@ -569,12 +550,6 @@ export default {
|
|
|
if (cls && !cls.includes("active")) {
|
|
|
this.portalDetail1.detailMessageList[0].cls = cls + " active";
|
|
|
}
|
|
|
- // sds-desktop .v-widget-window .v-widget-window .v-widget-items-wrapper{
|
|
|
- // height: calc(100vh - 42px) !important;
|
|
|
- // }
|
|
|
- // #sds-desktop .v-widget-window{
|
|
|
- // height: calc(100vh - 10px) !important;
|
|
|
- // }
|
|
|
if (obj.index == 0) {
|
|
|
let el1 = document.querySelector(".v-widget-window");
|
|
|
let el2 = document.querySelector(".v-widget-window .v-widget-items-wrapper");
|
|
@@ -656,8 +631,4 @@ input::-webkit-input-placeholder,
|
|
|
textarea::-webkit-input-placeholder {
|
|
|
color: #fff!important;
|
|
|
}
|
|
|
-
|
|
|
-/*
|
|
|
-
|
|
|
-*/
|
|
|
</style>
|