react-native-tinyui 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -165,6 +165,10 @@ or `type: 'divider'` for structural entries; nested entries use their own
165
165
  `options` array. SF Symbols are passed with `systemImage`; missing symbols
166
166
  simply render no image.
167
167
 
168
+ The trigger can be nested inside a React Native `Pressable` or `Touchable`.
169
+ Tapping an enabled menu trigger opens the menu without firing the parent's
170
+ touch or press handlers; tapping elsewhere in the parent keeps its normal behavior.
171
+
168
172
  To open the menu from another control, call `open()` on its ref:
169
173
 
170
174
  ```tsx
@@ -64,6 +64,21 @@ using namespace facebook::react;
64
64
  }
65
65
  }
66
66
 
67
+ #pragma mark - Touch handling
68
+
69
+ - (SharedTouchEventEmitter)touchEventEmitterAtPoint:(CGPoint)point
70
+ {
71
+ // The provider's hitTest returns its UIButton, so the surface touch handler
72
+ // finds this Fabric view first. Keep the trigger's touch sequence in UIKit:
73
+ // forwarding it to JS lets an ancestor Pressable/Touchable claim the same
74
+ // touch and run its press callbacks while the native menu is opening.
75
+ if (_menuProvider.isEnabled) {
76
+ return nullptr;
77
+ }
78
+
79
+ return [super touchEventEmitterAtPoint:point];
80
+ }
81
+
67
82
  #pragma mark - Commands
68
83
 
69
84
  - (void)handleCommand:(const NSString *)commandName args:(const NSArray *)args
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "react-native-tinyui",
3
- "version": "1.1.0",
3
+ "version": "1.1.1",
4
4
  "description": "Dependency-free native iOS Menu, Popover, TipKit, Stepper, ConcentricView, SFSymbol and LiquidGlassText components for React Native",
5
5
  "main": "./lib/module/index.js",
6
6
  "types": "./lib/typescript/src/index.d.ts",