From bf211f2a9ec93992f392c788ce7f01892a0459b0 Mon Sep 17 00:00:00 2001 From: chenjianxing Date: Wed, 7 Jul 2021 19:56:09 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E6=B5=8B=E8=AF=95=E8=AE=A1=E5=88=92?= =?UTF-8?q?=E9=A1=B5=E9=9D=A2=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/api/automation/scenario/EditApiScenario.vue | 6 ++++-- .../components/track/plan/components/TestPlanList.vue | 7 +++++++ 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue index 0e00f337ff..0e2cf95e2c 100644 --- a/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue +++ b/frontend/src/business/components/api/automation/scenario/EditApiScenario.vue @@ -579,11 +579,13 @@ export default { document.addEventListener("keydown", this.createCtrlSHandle); document.addEventListener("keydown", this.createCtrlRHandle); document.addEventListener("scroll", this.handleScroll, true); + window.addEventListener("resize", this.handleScroll); }, removeListener() { document.removeEventListener("keydown", this.createCtrlSHandle); document.removeEventListener("keydown", this.createCtrlRHandle); - document.removeEventListener("scroll", this.handleScroll); + document.removeEventListener("scroll", this.handleScroll, true); + window.removeEventListener("onresize", this.handleScroll); }, createCtrlSHandle(event) { handleCtrlSEvent(event, this.editScenario); @@ -1287,7 +1289,7 @@ export default { let stepInfo = this.$refs.stepInfo; let debugHeader = this.$refs.debugHeader; if (debugHeader) { - let originWidth = debugHeader.clientWidth; + let originWidth = debugHeader.parentElement.clientWidth; if (stepInfo.getBoundingClientRect().top <= 178) { this.isTop = true; if (originWidth > 0) { diff --git a/frontend/src/business/components/track/plan/components/TestPlanList.vue b/frontend/src/business/components/track/plan/components/TestPlanList.vue index b509b8933a..204f89c0b7 100644 --- a/frontend/src/business/components/track/plan/components/TestPlanList.vue +++ b/frontend/src/business/components/track/plan/components/TestPlanList.vue @@ -45,6 +45,7 @@ :filters="statusFilters" :label="$t('test_track.plan.plan_status')" show-overflow-tooltip + :min-width="100" :key="index">