Open chj-damon opened 1 year ago
0.72 works fine.
I also noticed that ZView cannot cover StatusBar and NavigationBar, which makes the effect a litter weird to me.
here's the code:
<ZView>
<View
style={{
width,
height,
backgroundColor: 'rgba(0, 0, 0, 0.5)',
}}
>
<Text>{message}</Text>
</View>
</ZView>
I also tried on IOS, it works fine.
ZView cannot cover StatusBar and NavigationBar
@chj-damon This should be fixed in 0.2.3
react-native 0.66.5 failed with this library
Looks like it is failing pointer event imports which were recently added. Is something blocking you from upgrading to the latest RN?
I'm just maintaining a UI Library which supports most react-native versions from 0.66 above. I don't think it's a good idea to tell developers this UI Library is only compatiable with the latest RN.
@chj-damon Published a new version 0.2.4. It should fix the 0.66.5 compilation issue. Let me know if you still face any issues.
tried the latest 0.2.4 version. something went wrong. here's my code:
<ZView touchable>
<View
style={{
width,
// height: 200,
// padding: 40,
backgroundColor: 'rgba(0, 0, 0, 0.5)',
}}
>
<Text style={{color: 'white'}}>Full size overlay view</Text>
</View>
</ZView>
when height
or padding
not set, it works fine. ZView
will cover the StatusBar, but once either of height
or padding
been set, it won't work.
@chj-damon Seems to be working fine for me on a physical device and also emulator with/without height/padding. Can you try to repro in a new RN app and check if it is reproducible?
/Users/damon/Documents/thundersdata/frontend/rn-template/node_modules/react-native-z-view/android/src/main/java/com/reactnativezview/ZViewRootViewGroup.java:11: 错误: 找不到符号 import com.facebook.react.uimanager.JSPointerDispatcher; ^ 符号: 类 JSPointerDispatcher 位置: 程序包 com.facebook.react.uimanager /Users/damon/Documents/thundersdata/frontend/rn-template/node_modules/react-native-z-view/android/src/main/java/com/reactnativezview/ZViewRootViewGroup.java:22: 错误: 找不到符号 private JSPointerDispatcher mJSPointerDispatcher; ^ 符号: 类 JSPointerDispatcher 位置: 类 ZViewRootViewGroup /Users/damon/Documents/thundersdata/frontend/rn-template/node_modules/react-native-z-view/android/src/main/java/com/reactnativezview/ZViewRootViewGroup.java:26: 错误: 找不到符号 if (ReactFeatureFlags.dispatchPointerEvents) { ^ 符号: 变量 dispatchPointerEvents 位置: 类 ReactFeatureFlags /Users/damon/Documents/thundersdata/frontend/rn-template/node_modules/react-native-z-view/android/src/main/java/com/reactnativezview/ZViewRootViewGroup.java:26: 错误: 非法的含括号表达式 if (ReactFeatureFlags.dispatchPointerEvents) { ^ /Users/damon/Documents/thundersdata/frontend/rn-template/node_modules/react-native-z-view/android/src/main/java/com/reactnativezview/ZViewRootViewGroup.java:27: 错误: 找不到符号 this.mJSPointerDispatcher = new JSPointerDispatcher(this); ^ 符号: 类 JSPointerDispatcher 位置: 类 ZViewRootViewGroup /Users/damon/Documents/thundersdata/frontend/rn-template/node_modules/react-native-z-view/android/src/main/java/com/reactnativezview/ZViewRootViewGroup.java:91: 错误: 找不到符号 this.mJSTouchDispatcher.onChildEndedNativeGesture(ev, this.mEventDispatcher); ^ 符号: 方法 onChildEndedNativeGesture(MotionEvent,EventDispatcher) 位置: 类型为JSTouchDispatcher的变量 mJSTouchDispatcher 6 个错误
FAILURE: Build failed with an exception.