We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
微信小程序
https://gitlab.com/guowei2/taro-todolist.git 小程序基础库: 3.3.4 使用框架: React
import { View, Text, Button, Image, Label } from '@tarojs/components' import { useLoad } from '@tarojs/taro' import './index.scss' export default function Index() { useLoad(() => { console.log('Page loaded.') }) return ( <View className='index'> <Text>Hello world!</Text> <View onLongPress={()=>console.log('onLongPress View')}>onLongPress View</View> <Text onLongPress={()=>console.log('onLongPress Text')}>onLongPress Text</Text> <Button onLongPress={()=>console.log('onLongPress Button')}>onLongPress Button</Button> <Image src='' onLongPress={()=>console.log('onLongPress Image')} /> <Label onLongPress={()=>console.log('onLongPress Label')} >onLongPress Label</Label> </View> ) }
依次长按以上元素
都触发onLongPress
只有View ,Button ,Image 触发,Text Label 未触发onLongPress
👽 Taro v3.6.23 Taro CLI 3.6.23 environment info: System: OS: Windows 10 10.0.19045 Binaries: Node: 20.11.1 - D:\Program Files\nodejs\node.EXE npm: 10.2.4 - D:\Program Files\nodejs\npm.CMD npmPackages: @tarojs/cli: 3.6.23 => 3.6.23 @tarojs/components: 3.6.23 => 3.6.23 @tarojs/helper: 3.6.23 => 3.6.23 @tarojs/plugin-framework-react: 3.6.23 => 3.6.23 @tarojs/plugin-platform-alipay: 3.6.23 => 3.6.23 @tarojs/plugin-platform-h5: 3.6.23 => 3.6.23 @tarojs/plugin-platform-jd: 3.6.23 => 3.6.23 @tarojs/plugin-platform-qq: 3.6.23 => 3.6.23 @tarojs/plugin-platform-swan: 3.6.23 => 3.6.23 @tarojs/plugin-platform-tt: 3.6.23 => 3.6.23 @tarojs/plugin-platform-weapp: 3.6.23 => 3.6.23 @tarojs/react: 3.6.23 => 3.6.23 @tarojs/runtime: 3.6.23 => 3.6.23 @tarojs/shared: 3.6.23 => 3.6.23 @tarojs/taro: 3.6.23 => 3.6.23 @tarojs/taro-loader: 3.6.23 => 3.6.23 @tarojs/webpack5-runner: 3.6.23 => 3.6.23 babel-preset-taro: 3.6.23 => 3.6.23 eslint-config-taro: 3.6.23 => 3.6.23 react: ^18.0.0 => 18.2.0
The text was updated successfully, but these errors were encountered:
fix: add touchEvents to Text and Label
69180a3
NervJS#15256
fix: add touchEvents to Text and Label (#15265)
ba90dd9
* fix: add touchEvents to Text and Label #15256 * test: update snapshot --------- Co-authored-by: chenjiajian <798095202@qq.com>
Successfully merging a pull request may close this issue.
相关平台
微信小程序
复现仓库
https://gitlab.com/guowei2/taro-todolist.git
小程序基础库: 3.3.4
使用框架: React
复现步骤
依次长按以上元素
期望结果
都触发onLongPress
实际结果
只有View ,Button ,Image 触发,Text Label 未触发onLongPress
环境信息
The text was updated successfully, but these errors were encountered: