From f5eb769e4f8262b6aa37bff3997f849b77bf35d7 Mon Sep 17 00:00:00 2001 From: izbz wh <731215820@qq.com> Date: Thu, 23 May 2019 09:32:19 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E6=A8=A1=E6=80=81=E6=A1=86=E4=B8=AD?= =?UTF-8?q?=E4=BD=BF=E7=94=A8table=EF=BC=8C=E8=AE=A1=E7=AE=97=E7=9A=84?= =?UTF-8?q?=E6=BB=9A=E5=8A=A8=E6=9D=A1=E5=AE=BD=E5=BA=A6=E4=B8=BA0?= =?UTF-8?q?=E7=9A=84bug?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/Table.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Table.js b/src/Table.js index bf91e0b..6edeb4e 100644 --- a/src/Table.js +++ b/src/Table.js @@ -204,6 +204,11 @@ class Table extends Component { if(nextProps.resetScroll){ this.resetScrollX(); } + // fix:模态框中使用table,计算的滚动条宽度为0的bug + if(this.scrollbarWidth<=0 && this.props.scroll.y){ + this.scrollbarWidth = measureScrollbar(); + } + // console.log('this.scrollTop**********',this.scrollTop);