react-native-tvos 0.81.0-0rc3 → 0.81.1-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 (75) hide show
  1. package/Libraries/Components/Switch/Switch.js +1 -1
  2. package/Libraries/Components/TextInput/TextInput.js +6 -1
  3. package/Libraries/Core/ReactNativeVersion.js +2 -2
  4. package/React/Base/RCTUtils.h +1 -0
  5. package/React/Base/RCTUtils.mm +16 -0
  6. package/React/Base/RCTVersion.m +2 -2
  7. package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ComponentDescriptors.cpp +0 -1
  8. package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ComponentDescriptors.h +0 -1
  9. package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ShadowNodes.cpp +0 -1
  10. package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/ShadowNodes.h +0 -11
  11. package/React/FBReactNativeSpec/react/renderer/components/FBReactNativeSpec/States.h +0 -2
  12. package/React/Fabric/Mounting/ComponentViews/Modal/RCTModalHostViewComponentView.mm +22 -0
  13. package/React/Fabric/Mounting/ComponentViews/Switch/RCTSwitchComponentView.mm +1 -1
  14. package/React/Fabric/Mounting/ComponentViews/TextInput/RCTTextInputComponentView.mm +2 -1
  15. package/React/React-RCTFBReactNativeSpec.podspec +1 -4
  16. package/React/React-RCTFabric.podspec +1 -0
  17. package/React/Runtime/React-RCTRuntime.podspec +1 -3
  18. package/ReactAndroid/gradle.properties +1 -1
  19. package/ReactAndroid/src/main/java/com/facebook/react/modules/systeminfo/ReactNativeVersion.kt +2 -2
  20. package/ReactAndroid/src/main/java/com/facebook/react/runtime/ReactHostImpl.kt +2 -1
  21. package/ReactCommon/React-Fabric.podspec +1 -4
  22. package/ReactCommon/React-FabricComponents.podspec +9 -4
  23. package/ReactCommon/React-FabricImage.podspec +1 -4
  24. package/ReactCommon/React-Mapbuffer.podspec +1 -4
  25. package/ReactCommon/ReactCommon.podspec +2 -3
  26. package/ReactCommon/cxxreact/ReactNativeVersion.h +2 -2
  27. package/ReactCommon/hermes/executor/React-jsitracing.podspec +1 -4
  28. package/ReactCommon/jserrorhandler/React-jserrorhandler.podspec +2 -4
  29. package/ReactCommon/jsinspector-modern/React-jsinspector.podspec +2 -3
  30. package/ReactCommon/jsinspector-modern/cdp/React-jsinspectorcdp.podspec +1 -4
  31. package/ReactCommon/jsinspector-modern/network/React-jsinspectornetwork.podspec +1 -4
  32. package/ReactCommon/jsinspector-modern/tracing/React-jsinspectortracing.podspec +1 -4
  33. package/ReactCommon/jsitooling/React-jsitooling.podspec +1 -4
  34. package/ReactCommon/react/debug/React-debug.podspec +1 -4
  35. package/ReactCommon/react/featureflags/React-featureflags.podspec +1 -4
  36. package/ReactCommon/react/nativemodule/core/platform/ios/React-NativeModulesApple.podspec +2 -3
  37. package/ReactCommon/react/nativemodule/defaults/React-defaultsnativemodule.podspec +1 -4
  38. package/ReactCommon/react/nativemodule/dom/React-domnativemodule.podspec +1 -4
  39. package/ReactCommon/react/nativemodule/featureflags/React-featureflagsnativemodule.podspec +1 -4
  40. package/ReactCommon/react/nativemodule/idlecallbacks/React-idlecallbacksnativemodule.podspec +1 -4
  41. package/ReactCommon/react/nativemodule/microtasks/React-microtasksnativemodule.podspec +1 -4
  42. package/ReactCommon/react/nativemodule/samples/ReactCommon-Samples.podspec +2 -0
  43. package/ReactCommon/react/performance/timeline/React-performancetimeline.podspec +1 -4
  44. package/ReactCommon/react/renderer/components/switch/iosswitch/react/renderer/components/switch/AppleSwitchComponentDescriptor.h +30 -0
  45. package/ReactCommon/react/renderer/components/switch/iosswitch/react/renderer/components/switch/AppleSwitchShadowNode.h +42 -0
  46. package/ReactCommon/react/renderer/components/switch/iosswitch/react/renderer/components/switch/IOSSwitchShadowNode.mm +28 -0
  47. package/ReactCommon/react/renderer/components/switch/iosswitch/react/renderer/components/switch/MacOSSwitchShadowNode.mm +32 -0
  48. package/ReactCommon/react/renderer/components/textinput/BaseTextInputProps.h +2 -1
  49. package/ReactCommon/react/renderer/consistency/React-rendererconsistency.podspec +2 -4
  50. package/ReactCommon/react/renderer/css/React-renderercss.podspec +2 -5
  51. package/ReactCommon/react/renderer/debug/React-rendererdebug.podspec +1 -4
  52. package/ReactCommon/react/renderer/graphics/React-graphics.podspec +3 -3
  53. package/ReactCommon/react/renderer/imagemanager/platform/ios/React-ImageManager.podspec +1 -4
  54. package/ReactCommon/react/renderer/runtimescheduler/React-runtimescheduler.podspec +1 -4
  55. package/ReactCommon/react/runtime/React-RuntimeCore.podspec +1 -4
  56. package/ReactCommon/react/runtime/React-RuntimeHermes.podspec +1 -4
  57. package/ReactCommon/react/runtime/platform/ios/React-RuntimeApple.podspec +1 -4
  58. package/ReactCommon/react/runtime/platform/ios/ReactCommon/RCTInstance.mm +1 -0
  59. package/ReactCommon/react/timing/React-timing.podspec +3 -4
  60. package/ReactCommon/react/utils/React-utils.podspec +3 -3
  61. package/ReactCommon/runtimeexecutor/React-runtimeexecutor.podspec +3 -2
  62. package/package.json +8 -8
  63. package/scripts/cocoapods/new_architecture.rb +1 -0
  64. package/scripts/cocoapods/rncore.rb +1 -1
  65. package/scripts/cocoapods/utils.rb +15 -1
  66. package/scripts/codegen/generate-artifacts-executor/generateReactCodegenPodspec.js +3 -3
  67. package/scripts/codegen/templates/ReactCodegen.podspec.template +1 -0
  68. package/scripts/react-native-xcode.sh +2 -2
  69. package/scripts/react_native_pods.rb +21 -0
  70. package/scripts/xcode/with-environment.sh +1 -1
  71. package/sdks/hermesc/osx-bin/hermes +0 -0
  72. package/sdks/hermesc/osx-bin/hermesc +0 -0
  73. package/sdks/hermesc/win64-bin/hermesc.exe +0 -0
  74. package/src/private/specs_DEPRECATED/components/SwitchNativeComponent.js +1 -0
  75. package/third-party-podspecs/ReactNativeDependencies.podspec +1 -1
@@ -264,7 +264,7 @@ const Switch: component(
264
264
  disabled,
265
265
  onTintColor: trackColorForTrue,
266
266
  style: StyleSheet.compose(
267
- {height: 31, width: 51},
267
+ {alignSelf: 'flex-start' as const},
268
268
  StyleSheet.compose(
269
269
  style,
270
270
  ios_backgroundColor == null
@@ -619,6 +619,9 @@ function InternalTextInput(props: TextInputProps): React.Node {
619
619
  // so omitting onBlur and onFocus pressability handlers here.
620
620
  const {onBlur, onFocus, ...eventHandlers} = usePressability(config);
621
621
 
622
+ const _accessibilityLabel =
623
+ props?.['aria-label'] ?? props?.accessibilityLabel;
624
+
622
625
  let _accessibilityState;
623
626
  if (
624
627
  accessibilityState != null ||
@@ -689,6 +692,7 @@ function InternalTextInput(props: TextInputProps): React.Node {
689
692
  {...otherProps}
690
693
  {...eventHandlers}
691
694
  acceptDragAndDropTypes={props.experimental_acceptDragAndDropTypes}
695
+ accessibilityLabel={_accessibilityLabel}
692
696
  accessibilityState={_accessibilityState}
693
697
  accessible={accessible}
694
698
  submitBehavior={submitBehavior}
@@ -752,8 +756,9 @@ function InternalTextInput(props: TextInputProps): React.Node {
752
756
  {...otherProps}
753
757
  {...colorProps}
754
758
  {...eventHandlers}
755
- accessibilityState={_accessibilityState}
759
+ accessibilityLabel={_accessibilityLabel}
756
760
  accessibilityLabelledBy={_accessibilityLabelledBy}
761
+ accessibilityState={_accessibilityState}
757
762
  accessible={accessible}
758
763
  acceptDragAndDropTypes={props.experimental_acceptDragAndDropTypes}
759
764
  autoCapitalize={autoCapitalize}
@@ -16,6 +16,6 @@ export const version: $ReadOnly<{
16
16
  }> = {
17
17
  major: 0,
18
18
  minor: 81,
19
- patch: 0,
20
- prerelease: '0rc3',
19
+ patch: 1,
20
+ prerelease: '0',
21
21
  };
@@ -54,6 +54,7 @@ RCT_EXTERN CGFloat RCTScreenScale(void);
54
54
  RCT_EXTERN CGFloat RCTFontSizeMultiplier(void);
55
55
  RCT_EXTERN CGSize RCTScreenSize(void);
56
56
  RCT_EXTERN CGSize RCTViewportSize(void);
57
+ RCT_EXTERN CGSize RCTSwitchSize(void);
57
58
 
58
59
  // Round float coordinates to nearest whole screen pixel (not point)
59
60
  RCT_EXTERN CGFloat RCTRoundPixelValue(CGFloat value);
@@ -436,6 +436,22 @@ CGSize RCTViewportSize(void)
436
436
  return window ? window.bounds.size : RCTScreenSize();
437
437
  }
438
438
 
439
+ CGSize RCTSwitchSize(void)
440
+ {
441
+ static CGSize rctSwitchSize;
442
+ static dispatch_once_t onceToken;
443
+ dispatch_once(&onceToken, ^{
444
+ RCTUnsafeExecuteOnMainQueueSync(^{
445
+ #if TARGET_OS_TV
446
+ rctSwitchSize = CGSizeMake(0.0, 0.0); // no switch on tvOS
447
+ #else
448
+ rctSwitchSize = [UISwitch new].intrinsicContentSize;
449
+ #endif
450
+ });
451
+ });
452
+ return rctSwitchSize;
453
+ }
454
+
439
455
  CGFloat RCTRoundPixelValue(CGFloat value)
440
456
  {
441
457
  CGFloat scale = RCTScreenScale();
@@ -23,8 +23,8 @@ NSDictionary* RCTGetReactNativeVersion(void)
23
23
  __rnVersion = @{
24
24
  RCTVersionMajor: @(0),
25
25
  RCTVersionMinor: @(81),
26
- RCTVersionPatch: @(0),
27
- RCTVersionPrerelease: @"0rc3",
26
+ RCTVersionPatch: @(1),
27
+ RCTVersionPrerelease: @"0",
28
28
  };
29
29
  });
30
30
  return __rnVersion;
@@ -21,7 +21,6 @@ registry->add(concreteComponentDescriptorProvider<AndroidDrawerLayoutComponentDe
21
21
  registry->add(concreteComponentDescriptorProvider<AndroidSwipeRefreshLayoutComponentDescriptor>());
22
22
  registry->add(concreteComponentDescriptorProvider<DebuggingOverlayComponentDescriptor>());
23
23
  registry->add(concreteComponentDescriptorProvider<PullToRefreshViewComponentDescriptor>());
24
- registry->add(concreteComponentDescriptorProvider<SwitchComponentDescriptor>());
25
24
  registry->add(concreteComponentDescriptorProvider<UnimplementedNativeViewComponentDescriptor>());
26
25
  }
27
26
 
@@ -21,7 +21,6 @@ using AndroidDrawerLayoutComponentDescriptor = ConcreteComponentDescriptor<Andro
21
21
  using AndroidSwipeRefreshLayoutComponentDescriptor = ConcreteComponentDescriptor<AndroidSwipeRefreshLayoutShadowNode>;
22
22
  using DebuggingOverlayComponentDescriptor = ConcreteComponentDescriptor<DebuggingOverlayShadowNode>;
23
23
  using PullToRefreshViewComponentDescriptor = ConcreteComponentDescriptor<PullToRefreshViewShadowNode>;
24
- using SwitchComponentDescriptor = ConcreteComponentDescriptor<SwitchShadowNode>;
25
24
  using UnimplementedNativeViewComponentDescriptor = ConcreteComponentDescriptor<UnimplementedNativeViewShadowNode>;
26
25
 
27
26
  void FBReactNativeSpec_registerComponentDescriptorsFromCodegen(
@@ -17,7 +17,6 @@ extern const char AndroidDrawerLayoutComponentName[] = "AndroidDrawerLayout";
17
17
  extern const char AndroidSwipeRefreshLayoutComponentName[] = "AndroidSwipeRefreshLayout";
18
18
  extern const char DebuggingOverlayComponentName[] = "DebuggingOverlay";
19
19
  extern const char PullToRefreshViewComponentName[] = "PullToRefreshView";
20
- extern const char SwitchComponentName[] = "Switch";
21
20
  extern const char UnimplementedNativeViewComponentName[] = "UnimplementedNativeView";
22
21
 
23
22
  } // namespace facebook::react
@@ -73,17 +73,6 @@ using PullToRefreshViewShadowNode = ConcreteViewShadowNode<
73
73
  PullToRefreshViewEventEmitter,
74
74
  PullToRefreshViewState>;
75
75
 
76
- JSI_EXPORT extern const char SwitchComponentName[];
77
-
78
- /*
79
- * `ShadowNode` for <Switch> component.
80
- */
81
- using SwitchShadowNode = ConcreteViewShadowNode<
82
- SwitchComponentName,
83
- SwitchProps,
84
- SwitchEventEmitter,
85
- SwitchState>;
86
-
87
76
  JSI_EXPORT extern const char UnimplementedNativeViewComponentName[];
88
77
 
89
78
  /*
@@ -25,8 +25,6 @@ using DebuggingOverlayState = StateData;
25
25
 
26
26
  using PullToRefreshViewState = StateData;
27
27
 
28
- using SwitchState = StateData;
29
-
30
28
  using UnimplementedNativeViewState = StateData;
31
29
 
32
30
  } // namespace facebook::react
@@ -110,6 +110,8 @@ static ModalHostViewEventEmitter::OnOrientationChange onOrientationChangeStruct(
110
110
 
111
111
  @interface RCTModalHostViewComponentView () <RCTFabricModalHostViewControllerDelegate>
112
112
 
113
+ @property (nonatomic, weak) UIView *accessibilityFocusedView;
114
+
113
115
  @end
114
116
 
115
117
  @implementation RCTModalHostViewComponentView {
@@ -204,6 +206,7 @@ static ModalHostViewEventEmitter::OnOrientationChange onOrientationChangeStruct(
204
206
  {
205
207
  BOOL shouldBePresented = !_isPresented && _shouldPresent && self.window;
206
208
  if (shouldBePresented) {
209
+ [self saveAccessibilityFocusedView];
207
210
  self.viewController.presentationController.delegate = self;
208
211
 
209
212
  _isPresented = YES;
@@ -235,6 +238,8 @@ static ModalHostViewEventEmitter::OnOrientationChange onOrientationChangeStruct(
235
238
  if (eventEmitter) {
236
239
  eventEmitter->onDismiss(ModalHostViewEventEmitter::OnDismiss{});
237
240
  }
241
+
242
+ [self restoreAccessibilityFocusedView];
238
243
  }];
239
244
  }
240
245
  }
@@ -263,6 +268,23 @@ static ModalHostViewEventEmitter::OnOrientationChange onOrientationChangeStruct(
263
268
  [self ensurePresentedOnlyIfNeeded];
264
269
  }
265
270
 
271
+ - (void)saveAccessibilityFocusedView
272
+ {
273
+ id focusedElement = UIAccessibilityFocusedElement(nil);
274
+ if (focusedElement && [focusedElement isKindOfClass:[UIView class]]) {
275
+ self.accessibilityFocusedView = (UIView *)focusedElement;
276
+ }
277
+ }
278
+
279
+ - (void)restoreAccessibilityFocusedView
280
+ {
281
+ id viewToFocus = self.accessibilityFocusedView;
282
+ if (viewToFocus) {
283
+ UIAccessibilityPostNotification(UIAccessibilityScreenChangedNotification, viewToFocus);
284
+ self.accessibilityFocusedView = nil;
285
+ }
286
+ }
287
+
266
288
  #pragma mark - RCTFabricModalHostViewControllerDelegate
267
289
 
268
290
  - (void)boundsDidChange:(CGRect)newBounds
@@ -9,10 +9,10 @@
9
9
 
10
10
  #import <React/RCTConversions.h>
11
11
 
12
- #import <react/renderer/components/FBReactNativeSpec/ComponentDescriptors.h>
13
12
  #import <react/renderer/components/FBReactNativeSpec/EventEmitters.h>
14
13
  #import <react/renderer/components/FBReactNativeSpec/Props.h>
15
14
  #import <react/renderer/components/FBReactNativeSpec/RCTComponentViewHelpers.h>
15
+ #import <react/renderer/components/switch/AppleSwitchComponentDescriptor.h>
16
16
 
17
17
  #import "RCTFabricComponentsPlugins.h"
18
18
 
@@ -22,6 +22,7 @@
22
22
  #import "RCTTextInputNativeCommands.h"
23
23
  #import "RCTTextInputUtils.h"
24
24
 
25
+ #import <limits>
25
26
  #import "RCTFabricComponentsPlugins.h"
26
27
 
27
28
  /** Native iOS text field bottom keyboard offset amount */
@@ -456,7 +457,7 @@ static NSSet<NSNumber *> *returnKeyTypesSet;
456
457
  }
457
458
  }
458
459
 
459
- if (props.maxLength) {
460
+ if (props.maxLength < std::numeric_limits<int>::max()) {
460
461
  NSInteger allowedLength = props.maxLength - _backedTextInputView.attributedText.string.length + range.length;
461
462
 
462
463
  if (allowedLength > 0 && text.length > allowedLength) {
@@ -45,10 +45,7 @@ Pod::Spec.new do |s|
45
45
  "HEADER_SEARCH_PATHS" => header_search_paths.join(' '),
46
46
  }
47
47
 
48
- if ENV['USE_FRAMEWORKS']
49
- s.header_mappings_dir = 'FBReactNativeSpec'
50
- s.module_name = 'React_RCTFBReactNativeSpec'
51
- end
48
+ resolve_use_frameworks(s, header_mappings_dir: 'FBReactNativeSpec', module_name: "React_RCTFBReactNativeSpec")
52
49
 
53
50
  s.dependency "React-jsi"
54
51
  s.dependency "RCTRequired"
@@ -79,6 +79,7 @@ Pod::Spec.new do |s|
79
79
  "react/renderer/components/scrollview/platform/cxx",
80
80
  "react/renderer/components/text/platform/cxx",
81
81
  "react/renderer/components/textinput/platform/ios",
82
+ "react/renderer/components/switch/iosswitch",
82
83
  ]);
83
84
 
84
85
  add_dependency(s, "React-graphics", :additional_framework_paths => ["react/renderer/graphics/platform/ios"])
@@ -35,9 +35,7 @@ Pod::Spec.new do |s|
35
35
  s.header_dir = header_dir
36
36
  s.module_name = module_name
37
37
 
38
- if ENV['USE_FRAMEWORKS']
39
- s.header_mappings_dir = "./"
40
- end
38
+ resolve_use_frameworks(s, header_mappings_dir: "./")
41
39
 
42
40
  s.pod_target_xcconfig = {
43
41
  "OTHER_CFLAGS" => "$(inherited) " + new_arch_flags,
@@ -1,4 +1,4 @@
1
- VERSION_NAME=0.81.0-0rc3
1
+ VERSION_NAME=0.81.1-0
2
2
  react.internal.publishingGroup=io.github.react-native-tvos
3
3
 
4
4
  android.useAndroidX=true
@@ -14,7 +14,7 @@ public object ReactNativeVersion {
14
14
  public val VERSION: Map<String, Any?> = mapOf(
15
15
  "major" to 0,
16
16
  "minor" to 81,
17
- "patch" to 0,
18
- "prerelease" to "rc.3"
17
+ "patch" to 1,
18
+ "prerelease" to null
19
19
  )
20
20
  }
@@ -514,7 +514,8 @@ public class ReactHostImpl(
514
514
  internal fun <T : NativeModule> hasNativeModule(nativeModuleInterface: Class<T>): Boolean =
515
515
  reactInstance?.hasNativeModule<T>(nativeModuleInterface) ?: false
516
516
 
517
- internal val nativeModules: Collection<NativeModule> = reactInstance?.nativeModules ?: listOf()
517
+ internal val nativeModules: Collection<NativeModule>
518
+ get() = reactInstance?.nativeModules ?: listOf()
518
519
 
519
520
  internal fun <T : NativeModule> getNativeModule(nativeModuleInterface: Class<T>): T? {
520
521
  if (!ReactBuildConfig.UNSTABLE_ENABLE_MINIFY_LEGACY_ARCHITECTURE &&
@@ -32,10 +32,7 @@ Pod::Spec.new do |s|
32
32
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
33
33
  "DEFINES_MODULE" => "YES" }
34
34
 
35
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
36
- s.header_mappings_dir = './'
37
- s.module_name = 'React_Fabric'
38
- end
35
+ resolve_use_frameworks(s, header_mappings_dir: "./", module_name: "React_Fabric")
39
36
 
40
37
  s.dependency "React-jsiexecutor"
41
38
  s.dependency "RCTRequired"
@@ -49,10 +49,7 @@ Pod::Spec.new do |s|
49
49
  "HEADER_SEARCH_PATHS" => header_search_path.join(" "),
50
50
  }
51
51
 
52
- if ENV['USE_FRAMEWORKS']
53
- s.header_mappings_dir = './'
54
- s.module_name = 'React_FabricComponents'
55
- end
52
+ resolve_use_frameworks(s, header_mappings_dir: "./", module_name: "React_FabricComponents")
56
53
 
57
54
  s.dependency "React-jsiexecutor"
58
55
  s.dependency "RCTRequired"
@@ -127,6 +124,14 @@ Pod::Spec.new do |s|
127
124
  sss.header_dir = "react/renderer/components/iostextinput"
128
125
  end
129
126
 
127
+ ss.subspec "switch" do |sss|
128
+ sss.source_files = podspec_sources(
129
+ ["react/renderer/components/switch/iosswitch/**/*.{m,mm,cpp,h}"],
130
+ ["react/renderer/components/switch/iosswitch/**/*.h"])
131
+ sss.exclude_files = "react/renderer/components/switch/iosswitch/**/MacOS*.{m,mm,cpp,h}"
132
+ sss.header_dir = "react/renderer/components/switch/"
133
+ end
134
+
130
135
  ss.subspec "textinput" do |sss|
131
136
  sss.source_files = podspec_sources("react/renderer/components/textinput/*.{m,mm,cpp,h}", "react/renderer/components/textinput/**/*.h")
132
137
  sss.header_dir = "react/renderer/components/textinput"
@@ -50,10 +50,7 @@ Pod::Spec.new do |s|
50
50
  "HEADER_SEARCH_PATHS" => header_search_path.join(" ")
51
51
  }
52
52
 
53
- if ENV['USE_FRAMEWORKS']
54
- s.header_mappings_dir = './'
55
- s.module_name = 'React_FabricImage'
56
- end
53
+ resolve_use_frameworks(s, header_mappings_dir: './', module_name: "React_FabricImage")
57
54
 
58
55
  s.dependency "React-jsiexecutor", version
59
56
  s.dependency "RCTRequired", version
@@ -32,10 +32,7 @@ Pod::Spec.new do |s|
32
32
  s.pod_target_xcconfig = { "HEADER_SEARCH_PATHS" => ["\"$(PODS_TARGET_SRCROOT)\""], "USE_HEADERMAP" => "YES",
33
33
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard() }
34
34
 
35
- if ENV['USE_FRAMEWORKS']
36
- s.header_mappings_dir = './'
37
- s.module_name = 'React_Mapbuffer'
38
- end
35
+ resolve_use_frameworks(s, header_mappings_dir: './', module_name: "React_Mapbuffer")
39
36
 
40
37
  add_dependency(s, "React-debug")
41
38
  add_rn_third_party_dependencies(s)
@@ -32,9 +32,8 @@ Pod::Spec.new do |s|
32
32
  "DEFINES_MODULE" => "YES",
33
33
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
34
34
  "GCC_WARN_PEDANTIC" => "YES" }
35
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
36
- s.header_mappings_dir = './'
37
- end
35
+
36
+ resolve_use_frameworks(s, header_mappings_dir: './')
38
37
 
39
38
  add_rn_third_party_dependencies(s)
40
39
  add_rncore_dependency(s)
@@ -17,8 +17,8 @@ namespace facebook::react {
17
17
  constexpr struct {
18
18
  int32_t Major = 0;
19
19
  int32_t Minor = 81;
20
- int32_t Patch = 0;
21
- std::string_view Prerelease = "0rc3";
20
+ int32_t Patch = 1;
21
+ std::string_view Prerelease = "0";
22
22
  } ReactNativeVersion;
23
23
 
24
24
  } // namespace facebook::react
@@ -32,10 +32,7 @@ Pod::Spec.new do |s|
32
32
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
33
33
  "GCC_WARN_PEDANTIC" => "YES" }
34
34
 
35
- if ENV['USE_FRAMEWORKS']
36
- s.header_mappings_dir = './'
37
- s.module_name = 'React_jsitracing'
38
- end
35
+ resolve_use_frameworks(s, header_mappings_dir: './', module_name: "React_jsitracing")
39
36
 
40
37
  s.dependency "React-jsi"
41
38
  end
@@ -33,10 +33,8 @@ Pod::Spec.new do |s|
33
33
  "USE_HEADERMAP" => "YES",
34
34
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard()
35
35
  }
36
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
37
- s.header_mappings_dir = '../'
38
- s.module_name = 'React_jserrorhandler'
39
- end
36
+
37
+ resolve_use_frameworks(s, header_mappings_dir: '../', module_name: "React_jserrorhandler")
40
38
 
41
39
  s.dependency "React-jsi"
42
40
  s.dependency "React-cxxreact"
@@ -44,10 +44,9 @@ Pod::Spec.new do |s|
44
44
  "PUBLIC_HEADERS_FOLDER_PATH" => "#{module_name}.framework/Headers/#{header_dir}"
45
45
  } : {})
46
46
 
47
- if ENV['USE_FRAMEWORKS']
48
- s.module_name = module_name
49
- end
47
+ resolve_use_frameworks(s, module_name: module_name)
50
48
 
49
+ add_dependency(s, "React-oscompat") # Needed for USE_FRAMEWORKS=dynamic
51
50
  s.dependency "React-featureflags"
52
51
  add_dependency(s, "React-runtimeexecutor", :additional_framework_paths => ["platform/ios"])
53
52
  s.dependency "React-jsi"
@@ -41,10 +41,7 @@ Pod::Spec.new do |s|
41
41
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
42
42
  "DEFINES_MODULE" => "YES"}
43
43
 
44
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
45
- s.module_name = module_name
46
- s.header_mappings_dir = "../.."
47
- end
44
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: module_name)
48
45
 
49
46
  add_rn_third_party_dependencies(s)
50
47
  add_rncore_dependency(s)
@@ -41,10 +41,7 @@ Pod::Spec.new do |s|
41
41
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
42
42
  "DEFINES_MODULE" => "YES"}
43
43
 
44
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
45
- s.module_name = module_name
46
- s.header_mappings_dir = "../.."
47
- end
44
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: module_name)
48
45
 
49
46
  add_dependency(s, "React-jsinspectorcdp", :framework_name => 'jsinspector_moderncdp')
50
47
  add_dependency(s, "React-featureflags")
@@ -41,10 +41,7 @@ Pod::Spec.new do |s|
41
41
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
42
42
  "DEFINES_MODULE" => "YES"}
43
43
 
44
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
45
- s.module_name = module_name
46
- s.header_mappings_dir = "../.."
47
- end
44
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: module_name)
48
45
 
49
46
  s.dependency "React-oscompat"
50
47
  s.dependency "React-timing"
@@ -28,10 +28,7 @@ Pod::Spec.new do |s|
28
28
  s.source_files = podspec_sources("react/runtime/*.{cpp,h}", "react/runtime/*.h")
29
29
  s.header_dir = "react/runtime"
30
30
 
31
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
32
- s.module_name = "JSITooling"
33
- s.header_mappings_dir = "./"
34
- end
31
+ resolve_use_frameworks(s, header_mappings_dir: "./", module_name: "JSITooling")
35
32
 
36
33
  s.pod_target_xcconfig = {
37
34
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
@@ -30,8 +30,5 @@ Pod::Spec.new do |s|
30
30
  s.pod_target_xcconfig = { "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
31
31
  "DEFINES_MODULE" => "YES" }
32
32
 
33
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
34
- s.module_name = "React_debug"
35
- s.header_mappings_dir = "../.."
36
- end
33
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: "React_debug")
37
34
  end
@@ -37,10 +37,7 @@ Pod::Spec.new do |s|
37
37
  "HEADER_SEARCH_PATHS" => header_search_paths.join(' '),
38
38
  "DEFINES_MODULE" => "YES" }
39
39
 
40
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
41
- s.module_name = "React_featureflags"
42
- s.header_mappings_dir = "../.."
43
- end
40
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: "React_featureflags")
44
41
 
45
42
  add_rn_third_party_dependencies(s)
46
43
  add_rncore_dependency(s)
@@ -31,9 +31,8 @@ Pod::Spec.new do |s|
31
31
  "USE_HEADERMAP" => "YES",
32
32
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
33
33
  "GCC_WARN_PEDANTIC" => "YES" }
34
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
35
- s.header_mappings_dir = './'
36
- end
34
+
35
+ resolve_use_frameworks(s, header_mappings_dir: './')
37
36
 
38
37
  s.source_files = podspec_sources("ReactCommon/**/*.{mm,cpp,h}", "ReactCommon/**/*.{h}")
39
38
 
@@ -38,10 +38,7 @@ Pod::Spec.new do |s|
38
38
  "OTHER_CFLAGS" => "$(inherited)",
39
39
  "DEFINES_MODULE" => "YES" }
40
40
 
41
- if ENV['USE_FRAMEWORKS']
42
- s.module_name = "React_defaultsnativemodule"
43
- s.header_mappings_dir = "../.."
44
- end
41
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: "React_defaultsnativemodule")
45
42
 
46
43
  s.dependency "React-jsi"
47
44
  s.dependency "React-jsiexecutor"
@@ -40,10 +40,7 @@ Pod::Spec.new do |s|
40
40
  "OTHER_CFLAGS" => "$(inherited)",
41
41
  "DEFINES_MODULE" => "YES" }
42
42
 
43
- if ENV['USE_FRAMEWORKS']
44
- s.module_name = "React_domnativemodule"
45
- s.header_mappings_dir = "../.."
46
- end
43
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: "React_domnativemodule")
47
44
 
48
45
  s.dependency "React-jsi"
49
46
  s.dependency "React-jsiexecutor"
@@ -38,10 +38,7 @@ Pod::Spec.new do |s|
38
38
  "OTHER_CFLAGS" => "$(inherited)",
39
39
  "DEFINES_MODULE" => "YES" }
40
40
 
41
- if ENV['USE_FRAMEWORKS']
42
- s.module_name = "React_featureflagsnativemodule"
43
- s.header_mappings_dir = "../.."
44
- end
41
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: "React_featureflagsnativemodule")
45
42
 
46
43
  s.dependency "React-jsi"
47
44
  s.dependency "React-jsiexecutor"
@@ -38,10 +38,7 @@ Pod::Spec.new do |s|
38
38
  "OTHER_CFLAGS" => "$(inherited)",
39
39
  "DEFINES_MODULE" => "YES" }
40
40
 
41
- if ENV['USE_FRAMEWORKS']
42
- s.module_name = "idlecallbacksnativemodule"
43
- s.header_mappings_dir = "../.."
44
- end
41
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: "idlecallbacksnativemodule")
45
42
 
46
43
  s.dependency "React-jsi"
47
44
  s.dependency "React-jsiexecutor"
@@ -38,10 +38,7 @@ Pod::Spec.new do |s|
38
38
  "HEADER_SEARCH_PATHS" => header_search_paths.join(' '),
39
39
  "DEFINES_MODULE" => "YES" }
40
40
 
41
- if ENV['USE_FRAMEWORKS']
42
- s.module_name = "React_microtasksnativemodule"
43
- s.header_mappings_dir = "../.."
44
- end
41
+ resolve_use_frameworks(s, header_mappings_dir: "../..", module_name: "React_microtasksnativemodule")
45
42
 
46
43
  s.dependency "React-jsi"
47
44
  s.dependency "React-jsiexecutor"
@@ -40,6 +40,8 @@ Pod::Spec.new do |s|
40
40
  s.framework = "UIKit"
41
41
 
42
42
  if ENV['USE_FRAMEWORKS']
43
+ # Do not use resolve_use_frameworks here - since we're including source files.
44
+ # Then it is not needed.
43
45
  s.header_mappings_dir = './'
44
46
  end
45
47
 
@@ -38,10 +38,7 @@ Pod::Spec.new do |s|
38
38
  "CLANG_CXX_LANGUAGE_STANDARD" => rct_cxx_language_standard(),
39
39
  "HEADER_SEARCH_PATHS" => header_search_paths.join(' ')}
40
40
 
41
- if ENV['USE_FRAMEWORKS'] && ReactNativeCoreUtils.build_rncore_from_source()
42
- s.module_name = "React_performancetimeline"
43
- s.header_mappings_dir = "../../.."
44
- end
41
+ resolve_use_frameworks(s, header_mappings_dir: "../../..", module_name: "React_performancetimeline")
45
42
 
46
43
  s.dependency "React-featureflags"
47
44
  add_dependency(s, "React-jsinspectortracing", :framework_name => 'jsinspector_moderntracing')