Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

同层显示隐藏导致 showScrollbar 失效 #13307

Open
tenth-person opened this issue Feb 15, 2023 · 2 comments
Open

同层显示隐藏导致 showScrollbar 失效 #13307

tenth-person opened this issue Feb 15, 2023 · 2 comments
Labels
F-react Framework - React T-weapp Target - 编译到微信小程序 V-3 Version - 3.x

Comments

@tenth-person
Copy link

相关平台

微信小程序

复现仓库

git@github.com:tenth-person/taro-issue.git
小程序基础库: 2.30.0
使用框架: React

复现步骤

<View className='index'>
  <ScrollView scrollY enhanced showScrollbar={false} style={{ height: 600 }}>
    {
      [0, 1, 2, 3, 4, 5, 6, 7, 8, 9].map((_tab: any, key: number) => {
        return (
          <View key={key} style={{ height: 200 }}>
            {key}
          </View>
        )
      })
    }
  </ScrollView>

  {loading && <View>loading</View>}
  {/*<View>*/}
  {/*  {loading && <View>loading</View>}*/}
  {/*</View>*/}
</View>

loading = false 时滚动内容,滚动条会显示。

期望结果

我不知道用 View 包裹是否正确,但是用 View 包裹能解决该问题

实际结果

loading 切换显示隐藏导致 showScrollbar 失效

环境信息

👽 Taro v3.6.1


  Taro CLI 3.6.1 environment info:
    System:
      OS: Windows 10
    Binaries:
      Node: 14.20.0 - D:\software\nodejs\node.EXE
      npm: 6.14.17 - D:\software\nodejs\npm.CMD


@taro-bot2 taro-bot2 bot added F-react Framework - React T-weapp Target - 编译到微信小程序 V-3 Version - 3.x labels Feb 15, 2023
@TheKonka
Copy link
Member

可能与Taro删除节点处理有关 #13124
实测安卓会有这个问题,苹果手机上面没有出现滚动条

@shaobeichen
Copy link

shaobeichen commented Jul 24, 2023

可能与Taro删除节点处理有关 #13124 实测安卓会有这个问题,苹果手机上面没有出现滚动条

我也遇到了相同的问题,Vue,表现和你说的一模一样,稍后试一下

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
F-react Framework - React T-weapp Target - 编译到微信小程序 V-3 Version - 3.x
Projects
None yet
Development

No branches or pull requests

3 participants