From 3e2bde7ad9bb622e55d3611d59de44d674db8278 Mon Sep 17 00:00:00 2001 From: Lu Chaohai Date: Tue, 25 Sep 2018 11:10:45 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20=E9=A1=B6=E9=83=A8?= =?UTF-8?q?=E8=8F=9C=E5=8D=95=E6=BB=9A=E5=8A=A8=E7=9A=84=E4=B8=80=E4=B8=AA?= =?UTF-8?q?bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Former-commit-id: a073a125015cbb0add924e5c5bc9ac3197bc87b2 [formerly a073a125015cbb0add924e5c5bc9ac3197bc87b2 [formerly a073a125015cbb0add924e5c5bc9ac3197bc87b2 [formerly a073a125015cbb0add924e5c5bc9ac3197bc87b2 [formerly 66daa14037aec6e43c6ba88af97de64b4a50b2d3 [formerly 2114dfc43f5ad6986a769742ab26266e54cb0b6c]]]]] Former-commit-id: 183f171b097c28f166e251331b9e514d9028f78d Former-commit-id: 92682d28b258c607affc03588dcacf68f47be925 Former-commit-id: 2f9faec630870376eb3df7e23db37e15afed77ad [formerly 930b7c4c442af8a61884acdef83e730aa9585dec] Former-commit-id: ea2ec0ac5bf3f9ea05b0deae96f3bf52433b6407 Former-commit-id: 99cc6af72d213c54666e94da7e97969a04c8cdf6 Former-commit-id: 239aba85af1497940905675ab224b7679389cada Former-commit-id: 8887f62b06b3cd4e67f7749e23522fe49f77893f Former-commit-id: 248cdd954e099a4c910894e75a0f44444ab2ae10 --- src/layout/header-aside/components/menu-header/index.vue | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/layout/header-aside/components/menu-header/index.vue b/src/layout/header-aside/components/menu-header/index.vue index 816667f3..e3e5df18 100644 --- a/src/layout/header-aside/components/menu-header/index.vue +++ b/src/layout/header-aside/components/menu-header/index.vue @@ -87,12 +87,12 @@ export default { // 更新元素数据 this.contentWidth = contentWidth this.scrollWidth = scrollWidth - // 判断何时滚动消失: 当page > content + btns(40) - if (contentWidth > scrollWidth + 40) { + // 判断何时滚动消失: 当scroll > content + if (contentWidth > scrollWidth) { this.isScroll = false } } - // 判断何时滚动出现: 当page < content + // 判断何时滚动出现: 当scroll < content if (!this.isScroll && contentWidth < scrollWidth) { this.isScroll = true // 注意,当isScroll变为true,对应的元素盒子大小会发生变化