@applicaster/quick-brick-native-apple 6.11.0 → 6.11.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.
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "QuickBrickApple",
3
- "version": "6.11.0",
3
+ "version": "6.11.1",
4
4
  "platforms": {
5
5
  "ios": "16.0",
6
6
  "tvos": "16.0"
@@ -16,7 +16,7 @@
16
16
  "authors": "Applicaster LTD.",
17
17
  "source": {
18
18
  "git": "https://github.com/applicaster/Zapp-Frameworks.git",
19
- "tag": "@@applicaster/quick-brick-native-apple/6.11.0"
19
+ "tag": "@@applicaster/quick-brick-native-apple/6.11.1"
20
20
  },
21
21
  "requires_arc": true,
22
22
  "source_files": "universal/**/*.{m,swift}",
@@ -23,7 +23,7 @@ RCT_EXPORT_VIEW_PROPERTY(onGroupBlur, RCTDirectEventBlock)
23
23
  RCT_EXPORT_VIEW_PROPERTY(itemId, NSString);
24
24
  RCT_EXPORT_VIEW_PROPERTY(groupId, NSString);
25
25
  RCT_EXPORT_VIEW_PROPERTY(initialItemId, NSString);
26
- RCT_EXPORT_VIEW_PROPERTY(isPreferredFocusEnvironmentDisabled, BOOL);
26
+ RCT_EXPORT_VIEW_PROPERTY(isPreferredFocusDisabled, BOOL);
27
27
  RCT_EXPORT_VIEW_PROPERTY(isFocusDisabled, BOOL);
28
28
  @end
29
29
 
@@ -23,7 +23,7 @@ public class FocusableGroupView: RCTTVView {
23
23
  /// Completion that will be used when focus manager forcing to update focusable group
24
24
  public var didFocusCallBack: (completion: () -> Void, focusableItemId: String)?
25
25
 
26
- private var activeStateNotifier: FocusableGroupStateNotifier?
26
+ private lazy var activeStateNotifier: FocusableGroupStateNotifier = FocusableGroupStateNotifierDefault(action: notifyReactNativeFocusUpdate)
27
27
 
28
28
  @objc public var onGroupFocus: RCTDirectEventBlock?
29
29
  @objc public var onGroupBlur: RCTDirectEventBlock?
@@ -71,7 +71,6 @@ public class FocusableGroupView: RCTTVView {
71
71
  private weak var module: FocusableGroupViewModule?
72
72
  public func setModule(_ module: FocusableGroupViewModule) {
73
73
  self.module = module
74
- activeStateNotifier = FocusableGroupStateNotifierDefault(action: notifyReactNativeFocusUpdate)
75
74
  }
76
75
 
77
76
  override init(bridge: RCTBridge) {
@@ -178,8 +177,8 @@ public class FocusableGroupView: RCTTVView {
178
177
  return params
179
178
  }
180
179
 
181
- private func notifyReactNativeFocusUpdate(_ type: FocusableGroupNotifierActionType,
182
- _ context: UIFocusUpdateContext) {
180
+ @MainActor private func notifyReactNativeFocusUpdate(_ type: FocusableGroupNotifierActionType,
181
+ _ context: UIFocusUpdateContext) {
183
182
  switch type {
184
183
  case .onBlur:
185
184
  onGroupBlur?(createFocusEventParams(context: context, isActive: false))
@@ -310,7 +309,7 @@ public class FocusableGroupView: RCTTVView {
310
309
  }
311
310
 
312
311
  let isActive = focusItemIsDescendant(nextFocusItem: context.nextFocusedItem)
313
- activeStateNotifier?.updateFocus(currentlyActive: isActive, context: context)
312
+ activeStateNotifier.updateFocus(currentlyActive: isActive, context: context)
314
313
 
315
314
  tryDidFocusCallCallback(context: context)
316
315
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@applicaster/quick-brick-native-apple",
3
- "version": "6.11.0",
3
+ "version": "6.11.1",
4
4
  "description": "iOS and tvOS native code for QuickBrick applications. This package is used to provide native logic for QuickBrick",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"