react-native-external-keyboard 0.8.5-rc → 0.9.0-alpha.0

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.
Files changed (46) hide show
  1. package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusGuideDelegate/RNCEKVFocusGuideDelegate.h +1 -1
  2. package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusOrderDelegate.h +5 -0
  3. package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusOrderDelegate.mm +82 -46
  4. package/ios/Delegates/RNCEKVFocusOrderDelegate/RNCEKVFocusOrderProtocol.h +6 -8
  5. package/ios/Delegates/RNCEKVGroupIdentifierDelegate/RNCEKVGroupIdentifierDelegate.mm +60 -60
  6. package/ios/Delegates/RNCEKVHaloDelegate/RNCEKVHaloDelegate.h +4 -3
  7. package/ios/Delegates/RNCEKVHaloDelegate/RNCEKVHaloDelegate.mm +110 -87
  8. package/ios/Delegates/RNCEKVHaloDelegate/RNCEKVHaloProtocol.h +1 -1
  9. package/ios/Extensions/RCTEnhancedScrollView+RNCEKVExternalKeyboard.mm +1 -1
  10. package/ios/Extensions/RCTTextInputComponentView+RNCEKVExternalKeyboard.mm +15 -0
  11. package/ios/Extensions/RCTViewComponentView+RNCEKVExternalKeyboard.h +1 -1
  12. package/ios/Extensions/RCTViewComponentView+RNCEKVExternalKeyboard.mm +31 -23
  13. package/ios/Extensions/UIViewController+RNCEKVExternalKeyboard.h +1 -0
  14. package/ios/Extensions/UIViewController+RNCEKVExternalKeyboard.mm +8 -0
  15. package/ios/Helpers/RNCEKVNativeProps/RNCEKVNativeProps.h +123 -0
  16. package/ios/Protocols/RNCEKVCustomFocusEffectProtocol.h +15 -0
  17. package/ios/Protocols/RNCEKVCustomGroudIdProtocol.h +15 -0
  18. package/ios/Views/Base/ContextMenu/RNCEKVViewContextMenuBase.h +33 -0
  19. package/ios/Views/Base/ContextMenu/RNCEKVViewContextMenuBase.mm +83 -0
  20. package/ios/Views/Base/FocusChange/RNCEKVViewFocusChangeBase.h +37 -0
  21. package/ios/Views/Base/FocusChange/RNCEKVViewFocusChangeBase.mm +88 -0
  22. package/ios/Views/Base/FocusOrderGroup/RNCEKVViewOrderGroupBase.h +49 -0
  23. package/ios/Views/Base/FocusOrderGroup/RNCEKVViewOrderGroupBase.mm +200 -0
  24. package/ios/Views/Base/FocusRequest/RNCEKVViewFocusRequestBase.h +34 -0
  25. package/ios/Views/Base/FocusRequest/RNCEKVViewFocusRequestBase.mm +117 -0
  26. package/ios/Views/Base/GroupIdentifier/RNCEKVViewGroupIdentifierBase.h +27 -0
  27. package/ios/Views/Base/GroupIdentifier/RNCEKVViewGroupIdentifierBase.mm +61 -0
  28. package/ios/Views/Base/KeyPress/RNCEKVViewKeyPress.h +30 -0
  29. package/ios/Views/Base/KeyPress/RNCEKVViewKeyPress.mm +82 -0
  30. package/ios/Views/Base/KeyboardHallo/RNCEKVExternalKeyboardHalloBase.h +33 -0
  31. package/ios/Views/Base/KeyboardHallo/RNCEKVExternalKeyboardHalloBase.mm +102 -0
  32. package/ios/Views/Base/ViewGroup/RNCEKVViewGroupBase.h +36 -0
  33. package/ios/Views/Base/ViewGroup/RNCEKVViewGroupBase.mm +63 -0
  34. package/ios/Views/RNCEKVExternalKeyboardView/RNCEKVExternalKeyboardView.h +75 -74
  35. package/ios/Views/RNCEKVExternalKeyboardView/RNCEKVExternalKeyboardView.mm +23 -491
  36. package/ios/Views/RNCEKVExternalKeyboardView/RNCEKVExternalKeyboardViewManager.mm +3 -6
  37. package/ios/Views/RNCEKVKeyboardFocusGroupView/RNCEKVKeyboardFocusGroup.mm +12 -12
  38. package/ios/Views/RNCEKVTextInputFocusWrapper/RNCEKVTextInputFocusWrapper.h +24 -22
  39. package/ios/Views/RNCEKVTextInputFocusWrapper/RNCEKVTextInputFocusWrapper.mm +21 -202
  40. package/ios/Views/RNCEKVTextInputFocusWrapper/RNCEKVTextInputFocusWrapperManager.mm +7 -7
  41. package/lib/commonjs/nativeSpec/TextInputFocusWrapperNativeComponent.ts +4 -0
  42. package/lib/module/nativeSpec/TextInputFocusWrapperNativeComponent.ts +4 -0
  43. package/lib/typescript/src/nativeSpec/TextInputFocusWrapperNativeComponent.d.ts +4 -1
  44. package/lib/typescript/src/nativeSpec/TextInputFocusWrapperNativeComponent.d.ts.map +1 -1
  45. package/package.json +1 -1
  46. package/src/nativeSpec/TextInputFocusWrapperNativeComponent.ts +4 -0
@@ -14,7 +14,7 @@
14
14
 
15
15
  @interface RNCEKVFocusGuideDelegate : NSObject
16
16
 
17
- - (instancetype _Nonnull)initWithView:(UIView<RNCEKVFocusOrderProtocol> *_Nonnull)view;
17
+ - (instancetype _Nonnull)initWithView:(NSObject<RNCEKVFocusOrderProtocol> *_Nonnull)view;
18
18
 
19
19
  //- (void)setLeftGuide:(UIView *_Nullable)view;
20
20
  //- (void)setRightGuide:(UIView *_Nullable)view;
@@ -41,6 +41,11 @@ typedef NS_ENUM(NSUInteger, RNCEKVLinkDirection) {
41
41
  - (void)refreshDown:(NSString*_Nullable)prev next:(NSString*_Nullable)next;
42
42
  - (void)clear;
43
43
 
44
+ - (void)link;
45
+ - (void)unlink;
46
+ - (void)updatePosition:(NSNumber*) position;
47
+ - (void)updateOrderGroup:(NSString *)orderGroup;
48
+
44
49
  @end
45
50
 
46
51
 
@@ -18,6 +18,7 @@
18
18
  #import "RNCEKVFocusLinkObserver.h"
19
19
  #import "RNCEKVFocusGuideHelper.h"
20
20
  #import "RNCEKVFocusGuideDelegate.h"
21
+ #import "UIView+React.h"
21
22
 
22
23
  static NSNumber *const FOCUS_DEFAULT = nil;
23
24
  static NSNumber *const FOCUS_LOCK = @0;
@@ -25,11 +26,12 @@ static NSNumber *const FOCUS_UPDATE = @1;
25
26
 
26
27
  @implementation RNCEKVFocusOrderDelegate{
27
28
  BOOL _isFocused;
29
+ BOOL _isLinked;
28
30
  UIView<RNCEKVFocusOrderProtocol>* _delegate;
29
31
  UIView* _entry;
30
32
  UIView* _exit;
31
33
  UIView* _lock;
32
-
34
+
33
35
  RNCEKVFocusGuideDelegate *_focusGuideDelegate;
34
36
  NSMutableDictionary<NSNumber *, id> *_updateLinks;
35
37
  NSMutableDictionary<NSNumber *, id> *_removeLinks;
@@ -47,27 +49,65 @@ static NSNumber *const FOCUS_UPDATE = @1;
47
49
  return self;
48
50
  }
49
51
 
52
+ - (void)updatePosition:(NSNumber*) position {
53
+ if (position == nil || _delegate.orderPosition == position || (_delegate.orderPosition != nil && [_delegate.orderPosition isEqualToNumber:position])) {
54
+ return;
55
+ }
56
+
57
+ if (_delegate.orderGroup != nil && _delegate.superview != nil && _isLinked) {
58
+ [[RNCEKVOrderLinking sharedInstance] update: position lastPosition: _delegate.orderPosition withOrderKey: _delegate.orderGroup withView: _delegate];
59
+ }
60
+ }
61
+
62
+ - (void)updateOrderGroup:(NSString *)orderGroup {
63
+ if(_delegate.orderPosition != nil && _delegate.superview != nil) {
64
+ [[RNCEKVOrderLinking sharedInstance] updateOrderKey: _delegate.orderGroup next:orderGroup position: _delegate.orderPosition withView: _delegate];
65
+ }
66
+ }
67
+
68
+ - (void)link {
69
+ if(_delegate.orderPosition != nil && _delegate.orderGroup != nil && !_isLinked) {
70
+ [[RNCEKVOrderLinking sharedInstance] add: _delegate.orderPosition withOrderKey: _delegate.orderGroup withObject: _delegate];
71
+ _isLinked = YES;
72
+ }
73
+ if(_delegate.orderId != nil) {
74
+ [[RNCEKVOrderLinking sharedInstance] storeOrderId: _delegate.orderId withView: _delegate];
75
+ [self linkId];
76
+ }
77
+ }
78
+
79
+ - (void)unlink {
80
+ if(_delegate.orderPosition != nil && _delegate.orderGroup != nil && _isLinked) {
81
+ [[RNCEKVOrderLinking sharedInstance] remove: _delegate.orderPosition withOrderKey: _delegate.orderGroup];
82
+ }
83
+ if(_delegate.orderId != nil) {
84
+ [[RNCEKVOrderLinking sharedInstance] cleanOrderId: _delegate.orderId];
85
+ [self clear];
86
+ }
87
+ _isLinked = NO;
88
+ }
89
+
50
90
  - (void)subscribeToDirection:(RNCEKVFocusGuideDirection)direction
51
91
  linkId:(NSString *)linkId {
52
92
  if (!linkId) {
53
93
  return;
54
94
  }
55
-
95
+
56
96
  if(_subscribers[@(direction)]) {
57
97
  [self clearDirection: direction];
58
98
  }
59
-
99
+
60
100
  __typeof(self) __weak weakSelf = self;
61
101
  RNCEKVFocusGuideDirection capturedDirection = direction;
62
-
102
+
63
103
  LinkUpdatedCallback onLinkUpdated = ^(UIView *link) {
64
104
  [self->_focusGuideDelegate setGuideFor:capturedDirection withView: link];
65
105
  };
66
-
106
+
67
107
  LinkRemovedCallback onLinkRemoved = ^{
68
108
  [self->_focusGuideDelegate removeGuideFor: capturedDirection];
69
109
  };
70
-
110
+
71
111
  RNCEKVOrderSubscriber* subscriber = [[RNCEKVFocusLinkObserver sharedManager] subscribe:linkId
72
112
  onLinkUpdated:onLinkUpdated
73
113
  onLinkRemoved:onLinkRemoved];
@@ -78,7 +118,7 @@ static NSNumber *const FOCUS_UPDATE = @1;
78
118
  if (!self.subscribers[@(direction)]) {
79
119
  return;
80
120
  }
81
-
121
+
82
122
  [[RNCEKVFocusLinkObserver sharedManager] unsubscribe:self.subscribers[@(direction)]];
83
123
  self.subscribers[@(direction)] = nil;
84
124
  [_focusGuideDelegate removeGuideFor: direction];
@@ -97,15 +137,11 @@ static NSNumber *const FOCUS_UPDATE = @1;
97
137
  }
98
138
  }
99
139
 
140
+ //ToDo: Refactor to one method with direction param, remove it
100
141
  - (void)defaultViewFocus:(UIView *)view {
101
142
  UIViewController *controller = _delegate.reactViewController;
102
-
103
143
  if (controller != nil) {
104
- controller.rncekvCustomFocusView = view;
105
- dispatch_async(dispatch_get_main_queue(), ^{
106
- [controller setNeedsFocusUpdate];
107
- [controller updateFocusIfNeeded];
108
- });
144
+ [controller rncekvFocusView:view];
109
145
  }
110
146
  }
111
147
 
@@ -115,18 +151,18 @@ static NSNumber *const FOCUS_UPDATE = @1;
115
151
  RNCEKVOrderRelationship* orderRelationship = [[RNCEKVOrderLinking sharedInstance] getInfo: _delegate.orderGroup];
116
152
  UIView* _entry = orderRelationship.entry;
117
153
  UIView* _exit = orderRelationship.exit;
118
-
154
+
119
155
  BOOL isEntry = _entry == current;
120
156
  if (isEntry) {
121
157
  UIView* firstElement = [orderRelationship getItem: 0];
122
158
  [self keyboardedViewFocus: firstElement];
123
159
  }
124
-
160
+
125
161
  BOOL isLast = currentIndex == orderRelationship.count - 1 && _exit;
126
162
  if (isLast) {
127
163
  [self defaultViewFocus: _exit];
128
164
  }
129
-
165
+
130
166
  BOOL inOrderRange = currentIndex >= 0 && currentIndex < orderRelationship.count - 1;
131
167
  if (inOrderRange) {
132
168
  UIView* nextElement = [orderRelationship getItem: currentIndex + 1];
@@ -138,22 +174,22 @@ static NSNumber *const FOCUS_UPDATE = @1;
138
174
  #pragma mark - Prev Focus Handling
139
175
  - (void)handlePrevFocus:(UIView *)current currentIndex:(NSInteger)currentIndex {
140
176
  RNCEKVOrderRelationship* orderRelationship = [[RNCEKVOrderLinking sharedInstance] getInfo: _delegate.orderGroup];
141
-
177
+
142
178
  UIView* _exit = orderRelationship.exit;
143
179
  UIView* _entry = orderRelationship.entry;
144
-
180
+
145
181
  BOOL isExit = _exit == current;
146
182
  int orderCount = [orderRelationship count];
147
183
  if (isExit) {
148
184
  UIView* lastElement = [orderRelationship getItem: orderCount - 1];
149
185
  [self keyboardedViewFocus: lastElement];
150
186
  }
151
-
187
+
152
188
  BOOL isFirst = currentIndex == 0 && _entry;
153
189
  if (isFirst) {
154
190
  [self defaultViewFocus: _entry];
155
191
  }
156
-
192
+
157
193
  BOOL inRange = currentIndex > 0 && currentIndex <= orderCount - 1;
158
194
  if (inRange) {
159
195
  UIView* prevElement = [orderRelationship getItem: currentIndex - 1];
@@ -167,7 +203,7 @@ static NSNumber *const FOCUS_UPDATE = @1;
167
203
  UIView *next = (UIView *)context.nextFocusedItem;
168
204
  UIView *current = (UIView *)context.previouslyFocusedItem;
169
205
  UIView* targetView = [_delegate getFocusTargetView];
170
-
206
+
171
207
  BOOL isTarget = current == targetView;
172
208
  if (isTarget) {
173
209
  NSMutableDictionary<NSNumber *, NSString *> *orderMapping = [NSMutableDictionary dictionary]; //Todo create custom structure
@@ -183,7 +219,7 @@ static NSNumber *const FOCUS_UPDATE = @1;
183
219
  if (_delegate.orderBackward) {
184
220
  orderMapping[@(UIFocusHeadingPrevious)] = _delegate.orderBackward;
185
221
  }
186
-
222
+
187
223
  NSString *orderKey = orderMapping[@(movementHint)];
188
224
  if (orderKey) {
189
225
  UIView *nextView = [[RNCEKVOrderLinking sharedInstance] getOrderView:orderKey];
@@ -191,80 +227,80 @@ static NSNumber *const FOCUS_UPDATE = @1;
191
227
  return FOCUS_LOCK;
192
228
  }
193
229
  }
194
-
195
-
230
+
231
+
196
232
  if (current == targetView) {
197
233
  NSUInteger rawFocusLockValue = [_delegate.lockFocus unsignedIntegerValue];
198
-
234
+
199
235
  BOOL isDirectionLock = (rawFocusLockValue & movementHint) != 0;
200
236
  if (isDirectionLock) {
201
237
  return FOCUS_LOCK;
202
238
  }
203
239
  }
204
-
240
+
205
241
  if(_delegate.orderGroup && _delegate.orderPosition != nil) {
206
242
  RNCEKVOrderRelationship* orderRelationship = [[RNCEKVOrderLinking sharedInstance] getInfo: _delegate.orderGroup];
207
243
  NSArray *order = [orderRelationship getArray];
208
244
  if(order.count == 0) {
209
245
  return FOCUS_DEFAULT;
210
246
  }
211
-
247
+
212
248
  UIView* _exit = orderRelationship.exit;
213
249
  UIView* _entry = orderRelationship.entry;
214
-
250
+
215
251
  int currentIndex = [orderRelationship getItemIndex:current];
216
252
  int nextIndex = [orderRelationship getItemIndex:next];
217
253
  // [self findOrderIndex:order element:current];
218
-
254
+
219
255
  // [self findOrderIndex:order element:next];
220
-
256
+
221
257
  BOOL isEntryElement = _entry == nil && currentIndex == -1 && movementHint == UIFocusHeadingNext;
222
-
258
+
223
259
  if(isEntryElement) {
224
260
  orderRelationship.entry = current;
225
261
  }
226
-
262
+
227
263
  BOOL isExit = _exit == nil && nextIndex == -1 && movementHint == UIFocusHeadingNext;
228
264
  if(isExit) {
229
265
  orderRelationship.exit = next;
230
266
  }
231
-
267
+
232
268
  if(context.focusHeading == UIFocusHeadingNext) {
233
269
  [self handleNextFocus:current currentIndex: currentIndex];
234
270
  return FOCUS_UPDATE;
235
271
  }
236
-
237
-
272
+
273
+
238
274
  if(context.focusHeading == UIFocusHeadingPrevious) {
239
275
  [self handlePrevFocus:current currentIndex: currentIndex];
240
276
  return FOCUS_UPDATE;
241
277
  }
242
278
  }
243
-
279
+
244
280
  return FOCUS_DEFAULT;
245
281
  }
246
282
 
247
283
  - (void)linkId {
248
284
  RNCEKVFocusLinkObserver *focusLinkObserver = [RNCEKVFocusLinkObserver sharedManager];
249
-
285
+
250
286
  NSString* orderId = _delegate.orderId;
251
287
  UIView* view = [_delegate getFocusTargetView];
252
-
288
+
253
289
  if(orderId != nil) {
254
290
  [focusLinkObserver emitWithId:orderId link:view];
255
291
  }
256
-
292
+
257
293
  [self subscribeToDirection:RNCEKVFocusGuideDirectionLeft
258
294
  linkId:_delegate.orderLeft];
259
-
295
+
260
296
  [self subscribeToDirection:RNCEKVFocusGuideDirectionRight
261
297
  linkId:_delegate.orderRight
262
298
  ];
263
-
299
+
264
300
  [self subscribeToDirection:RNCEKVFocusGuideDirectionUp
265
301
  linkId:_delegate.orderUp
266
302
  ];
267
-
303
+
268
304
  [self subscribeToDirection:RNCEKVFocusGuideDirectionDown
269
305
  linkId:_delegate.orderDown
270
306
  ];
@@ -273,13 +309,13 @@ static NSNumber *const FOCUS_UPDATE = @1;
273
309
  - (void)refreshId: (NSString*)prev next:(NSString*)next {
274
310
  RNCEKVFocusLinkObserver *focusLinkObserver = [RNCEKVFocusLinkObserver sharedManager];
275
311
  UIView* view = [_delegate getFocusTargetView];
276
-
277
-
312
+
313
+
278
314
  if(prev != nil) {
279
315
  [focusLinkObserver emitRemoveWithId: prev];
280
316
  [[RNCEKVOrderLinking sharedInstance] cleanOrderId: prev];
281
317
  }
282
-
318
+
283
319
  if(next != nil && view != nil) {
284
320
  [[RNCEKVOrderLinking sharedInstance] storeOrderId: next withView:_delegate];
285
321
  [focusLinkObserver emitWithId:next link:view];
@@ -319,7 +355,7 @@ static NSNumber *const FOCUS_UPDATE = @1;
319
355
  [self clearDirection:RNCEKVFocusGuideDirectionRight];
320
356
  [self clearDirection:RNCEKVFocusGuideDirectionUp];
321
357
  [self clearDirection:RNCEKVFocusGuideDirectionDown];
322
-
358
+
323
359
  [self refreshId: _delegate.orderId next:nil];
324
360
  }
325
361
 
@@ -13,20 +13,18 @@
13
13
  @protocol RNCEKVFocusOrderProtocol <NSObject>
14
14
 
15
15
  @property (nonatomic, strong) NSString* orderGroup;
16
- @property NSNumber* lockFocus;
17
- @property NSNumber* orderPosition;
16
+ @property (nonatomic, strong) NSNumber* lockFocus;
17
+ @property (nonatomic, strong) NSNumber* orderPosition;
18
18
  @property (nonatomic, strong) NSString* orderLeft;
19
19
  @property (nonatomic, strong) NSString* orderRight;
20
20
  @property (nonatomic, strong) NSString* orderUp;
21
21
  @property (nonatomic, strong) NSString* orderDown;
22
- @property NSString* orderForward;
23
- @property NSString* orderBackward;
24
- @property NSString* orderLast;
25
- @property NSString* orderFirst;
26
-
22
+ @property (nonatomic, strong) NSString* orderForward;
23
+ @property (nonatomic, strong) NSString* orderBackward;
24
+ @property (nonatomic, strong) NSString* orderLast;
25
+ @property (nonatomic, strong) NSString* orderFirst;
27
26
  @property (nonatomic, strong) NSString* orderId;
28
27
 
29
- - (UIViewController *)reactViewController;
30
28
  - (UIView *)getFocusTargetView;
31
29
 
32
30
  @end
@@ -53,65 +53,65 @@
53
53
  return nil;
54
54
  }
55
55
  }
56
-
57
-
58
- #ifdef RCT_NEW_ARCH_ENABLED
59
- - (void) updateGroupIdentifier {
60
- if (@available(iOS 14.0, *)) {
61
- UIView* focus = [_delegate getFocusTargetView];
62
-
63
- NSString* identifier = [self getFocusGroupIdentifier];
64
- if([focus isKindOfClass:[RCTViewComponentView class]]) {
65
- ((RCTViewComponentView*)focus).rncekvCustomGroup = identifier;
66
- } else {
67
- focus.focusGroupIdentifier = identifier;
68
- }
69
- }
70
- }
71
-
72
- #else
73
-
74
- - (void) updateGroupIdentifier {
75
- if (@available(iOS 14.0, *)) {
76
- UIView* focus = [_delegate getFocusTargetView];
77
- focus.focusGroupIdentifier = [self getFocusGroupIdentifier];
78
- }
79
- }
80
-
81
- #endif
82
-
83
- - (void) clear {
84
- if (@available(iOS 14.0, *)) {
85
- UIView* focus = [_delegate getFocusTargetView];
86
- [self clearSubview: focus];
87
- }
88
- }
89
-
90
- #ifdef RCT_NEW_ARCH_ENABLED
91
- - (void)clearSubview: (UIView*_Nullable)subview {
92
- if(!subview) return;
93
-
94
- if (@available(iOS 14.0, *)) {
95
-
96
- if(subview) {
97
- if([subview isKindOfClass:[RCTViewComponentView class]]) {
98
- ((RCTViewComponentView*)subview).rncekvCustomGroup = nil;
99
- } else {
100
- subview.focusGroupIdentifier = nil;
101
- }
102
- }
103
- }
104
- }
105
- #else
106
-
107
- - (void)clearSubview: (UIView*_Nullable)subview {
108
- if(!subview) return;
109
-
110
- if (@available(iOS 14.0, *)) {
111
- subview.focusGroupIdentifier = nil;
112
- }
113
- }
114
-
115
- #endif
56
+ //
57
+ //
58
+ //#ifdef RCT_NEW_ARCH_ENABLED
59
+ //- (void) updateGroupIdentifier {
60
+ //// if (@available(iOS 14.0, *)) {
61
+ //// UIView* focus = [_delegate getFocusTargetView];
62
+ ////
63
+ ////// NSString* identifier = [self getFocusGroupIdentifier];
64
+ ////// if([focus isKindOfClass:[RCTViewComponentView class]]) {
65
+ ////// ((RCTViewComponentView*)focus).rncekvCustomGroup = identifier;
66
+ ////// } else {
67
+ ////// focus.focusGroupIdentifier = identifier;
68
+ ////// }
69
+ //// }
70
+ //}
71
+ //
72
+ //#else
73
+ //
74
+ //- (void) updateGroupIdentifier {
75
+ // if (@available(iOS 14.0, *)) {
76
+ // UIView* focus = [_delegate getFocusTargetView];
77
+ // focus.focusGroupIdentifier = [self getFocusGroupIdentifier];
78
+ // }
79
+ //}
80
+ //
81
+ //#endif
82
+ //
83
+ //- (void) clear {
84
+ // if (@available(iOS 14.0, *)) {
85
+ //// UIView* focus = [_delegate getFocusTargetView];
86
+ //// [self clearSubview: focus];
87
+ // }
88
+ //}
89
+
90
+ //#ifdef RCT_NEW_ARCH_ENABLED
91
+ //- (void)clearSubview: (UIView*_Nullable)subview {
92
+ //// if(!subview) return;
93
+ //
94
+ //// if (@available(iOS 14.0, *)) {
95
+ ////
96
+ //// if(subview) {
97
+ //// if([subview isKindOfClass:[RCTViewComponentView class]]) {
98
+ //// ((RCTViewComponentView*)subview).rncekvCustomGroup = nil;
99
+ //// } else {
100
+ //// subview.focusGroupIdentifier = nil;
101
+ //// }
102
+ //// }
103
+ //// }
104
+ //}
105
+ //#else
106
+
107
+ //- (void)clearSubview: (UIView*_Nullable)subview {
108
+ // if(!subview) return;
109
+ //
110
+ // if (@available(iOS 14.0, *)) {
111
+ // subview.focusGroupIdentifier = nil;
112
+ // }
113
+ //}
114
+ //
115
+ //#endif
116
116
 
117
117
  @end
@@ -15,9 +15,10 @@
15
15
 
16
16
  - (instancetype _Nonnull )initWithView:(UIView<RNCEKVHaloProtocol> *_Nonnull)view;
17
17
 
18
- - (void)displayHalo:(BOOL)force;
19
- - (void)displayHalo;
20
- - (void)updateHalo;
18
+ - (UIFocusEffect*) getHalo;
19
+ //- (void)displayHalo:(BOOL)force;
20
+ //- (void)displayHalo;
21
+ //- (void)updateHalo;
21
22
  - (void)clear;
22
23
 
23
24
  @end