From ef6ae668598f1322a9832a14c7b3d816f2616b03 Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Tue, 30 Nov 2021 15:14:43 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BC=98=E5=8C=96=E4=BB=AA=E8=A1=A8?= =?UTF-8?q?=E6=9D=BF=E7=BC=96=E8=BE=91=E6=97=B6=EF=BC=8C=E8=BE=B9=E7=95=8C?= =?UTF-8?q?=E5=8F=AF=E8=83=BD=E9=97=B4=E9=9A=99=E4=B8=8D=E4=B8=80=E8=87=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/components/DeDrag/index.vue | 33 ++----------------- .../canvas/components/Editor/Preview.vue | 5 +++ frontend/src/layout/index.vue | 5 +++ frontend/src/views/panel/edit/index.vue | 6 ++-- 4 files changed, 15 insertions(+), 34 deletions(-) diff --git a/frontend/src/components/DeDrag/index.vue b/frontend/src/components/DeDrag/index.vue index 3991959526..e06ea354ea 100644 --- a/frontend/src/components/DeDrag/index.vue +++ b/frontend/src/components/DeDrag/index.vue @@ -451,9 +451,8 @@ export default { } }, style() { - // console.log('style-top:' + this.y + '--' + this.top) return { - padding: this.curGap + 'px', + padding: this.curGap + 'px!important', transform: `translate(${this.left}px, ${this.top}px) rotate(${this.rotate}deg)`, width: this.computedWidth, height: this.computedHeight, @@ -529,7 +528,6 @@ export default { width: this.computedMainSlotWidth, height: this.computedMainSlotHeight } - // console.log('style=>' + JSON.stringify(style)) return style }, curComponent() { @@ -698,7 +696,7 @@ export default { const rect = this.$el.parentNode.getBoundingClientRect() this.parentX = rect.x this.parentY = rect.y - return [Math.round(parseFloat(style.getPropertyValue('width'), 10)), 100000] + return [Math.round(parseFloat(style.getPropertyValue('width'), 10)) + 6, 100000] } if (typeof this.parent === 'string') { const parentNode = document.querySelector(this.parent) @@ -1810,35 +1808,8 @@ export default { transition: 0.2s } -.gap_class{ - padding:5px; -} - .de-drag-active{ outline: 1px solid #70c0ff; user-select: none; } - -/*.mouseOn >>> .icon-shezhi{*/ -/* z-index: 2;*/ -/* display:block!important;*/ -/*}*/ -/*.vdr > i{*/ -/* right: 5px;*/ -/* color: gray;*/ -/* position: absolute;*/ -/*}*/ - -/*.vdr >>> i:hover {*/ -/* color: red;*/ -/*}*/ - -/*.vdr:hover >>> i {*/ -/* z-index: 2;*/ -/* display:block;*/ -/*}*/ - -/*.vdr>>>.icon-shezhi {*/ -/* display:none*/ -/*}*/ diff --git a/frontend/src/components/canvas/components/Editor/Preview.vue b/frontend/src/components/canvas/components/Editor/Preview.vue index 77fdd94f34..27cf09c80b 100644 --- a/frontend/src/components/canvas/components/Editor/Preview.vue +++ b/frontend/src/components/canvas/components/Editor/Preview.vue @@ -280,4 +280,9 @@ export default { padding: 10px 20px 20px; } + ::-webkit-scrollbar { + width: 0px!important; + height: 0px!important; + } + diff --git a/frontend/src/layout/index.vue b/frontend/src/layout/index.vue index 554743b313..ed439d8f33 100644 --- a/frontend/src/layout/index.vue +++ b/frontend/src/layout/index.vue @@ -147,5 +147,10 @@ export default { } .full-height { height: 100vh !important; + ::-webkit-scrollbar { + width: 0px; + height: 0px; + } + } diff --git a/frontend/src/views/panel/edit/index.vue b/frontend/src/views/panel/edit/index.vue index 265cf18f9f..dfd7316478 100644 --- a/frontend/src/views/panel/edit/index.vue +++ b/frontend/src/views/panel/edit/index.vue @@ -699,7 +699,7 @@ export default { if (domInfo) { this.outStyle.height = domInfo.offsetHeight - this.getGap() // 临时处理 确保每次restore 有会更新 - this.outStyle.width = domInfo.offsetWidth - this.getGap() + (Math.random() * 0.000001) + this.outStyle.width = domInfo.offsetWidth - this.getGap() + (Math.random() * 0.000001) + 2 } }) }, @@ -1057,8 +1057,8 @@ export default { } ::-webkit-scrollbar { - width: 0px; - height: 0px; + width: 2px!important; + height: 2px!important; }