Summary:
This diff updates the minsdkversion of RN OSS template to API level 19
changelog: [Android][Deprecated] Deprecate support of Android API levels 16 to 18. The new minSDK version will be 19+ moving forward
Reviewed By: JoshuaGross
Differential Revision: D22874852
fbshipit-source-id: 1df98e422dc9debd40ab2021aafc7b165312d14b
Summary:
This babel plugin will also take care of the JS TurboModule Codegen. Therefore, we should rename this into something more generic.
Changelog:
[General][Changed] Rename babel-plugin-inline-view-configs to react-native/babel-plugin-codegen
Reviewed By: rickhanlonii, cpojer
Differential Revision: D22803209
fbshipit-source-id: 416c97fea6fa0820d25bbc91033a0cbbbbbff825
Summary:
This instruments the following marker:
- MODULE_CREATE
**Note:** This marker isn't necessary to test the JS TurboModule codegen, since the JS codegen should only affect the C++ portion of the TurboModule infra. However, I implemented this while I was in this area of the code, for completeness.
Changelog: [Internal]
Reviewed By: PeteTheHeat
Differential Revision: D22679888
fbshipit-source-id: aa04822bd5a7c889813fcd13ca23c0b7a1d8444a
Summary:
The async NativeModule method call event can fail if something goes wrong when we're about do dispatch the method call.
Changelog: [Internal]
Reviewed By: ejanzer
Differential Revision: D22609410
fbshipit-source-id: 699eeb78edfbefa85e417fd82318ae8e4f6f7d90
Summary:
In D17480605 (689233b018), I made all methods with void return types dispatch to the NativeModules thread. This diff makes the same change to methods with promise return types.
**Note:** The changes are disabled for now. I'll add an MC so that we can test this in production in a later diff.
Changelog:
[Android][Fixed] - Make promise NativeModule methods dispatch to NativeModules thread
Reviewed By: PeteTheHeat
Differential Revision: D22489338
fbshipit-source-id: d5b030871f9f7b3f48eb111225516521493cb05e
Summary:
Android's `VibrationModule` uses deprecated `vibrate(long milliseconds)` and `vibrate(long[] pattern, int repeat)` methods. Deprecation notes: [[1]](https://developer.android.com/reference/android/os/Vibrator#vibrate(long)) [[2]](https://developer.android.com/reference/android/os/Vibrator#vibrate(long[],%20int)).
Changes in this pull request use recent `Vibrator` API for devices with API Level >= 26 (since mentioned methods were depreceted in API Level 26).
## Changelog
<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
https://github.com/facebook/react-native/wiki/Changelog
-->
[Android] [Internal] - Use non-deprecated `Vibrator` API in `VibrationModule`
Pull Request resolved: https://github.com/facebook/react-native/pull/29534
Test Plan: API is the same as before, but it uses recent `Vibrator` API.
Reviewed By: makovkastar
Differential Revision: D22857382
Pulled By: mdvacca
fbshipit-source-id: 6793a7d165fa73d81064865861ed55af2de83d52
Summary:
This diff cleansup unused code on AccessibilityInfoModule class
changelog: [Android][Deprecated] Remove code used by deprecated Android API levels
Reviewed By: JoshuaGross
Differential Revision: D22771912
fbshipit-source-id: f32808fa93f75c10324e8875b85fe4e541b284b8
Summary:
This diff removes code that was used to support android APIs < kitkat
changelog: [Android][Deprecated] Remove calls to Android API < Kitkat
Reviewed By: JoshuaGross
Differential Revision: D22771913
fbshipit-source-id: b9bba9e94fbc8e18889b821050dcd6eace4c202d
Summary:
Changelog: [Internal]
Since D22098586 (476ab7481e) zIndex is only applied to views with position other than static.
Sticky header however needs to have its zIndex applied otherwise it goes below the content.
Reviewed By: mdvacca
Differential Revision: D22843134
fbshipit-source-id: d2e3a21441795b82c44b6d4245ccf89620fd9a8e
Summary:
This diff upgrades react-native-github Android to support API level 19+
changelog: [Android][Deprecated] Deprecate support of Android API levels 16 to 18. The new minSDK version will be 19+ moving forward
Reviewed By: JoshuaGross
Differential Revision: D22734208
fbshipit-source-id: b052721c8cfb44f8d74cf4bbb5b7a769e544d1d9
Summary:
To help reflect how we've collectively been thinking about partnership and engagement on React Native, this change moves Facebook into the Partners list alongside other partners like Expo, Microsoft, and others. This change helps establish that the React Native teams across Facebook & Microsoft are one big happy family :)
## Changelog
<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
https://github.com/facebook/react-native/wiki/Changelog
-->
[General] [Changed] - Updated ECOSYSTEM.md to reflect partnerships between Facebook, Microsoft, and others
Pull Request resolved: https://github.com/facebook/react-native/pull/29527
Test Plan: N/A - document change
Reviewed By: cpojer
Differential Revision: D22845420
Pulled By: TheSavior
fbshipit-source-id: b3393c8749efc924b27d101d0513ae55eba55270
Summary:
Changelog:[Fabric][iOS] Add full support for AccessibilityState
Since the AccessibilityState checked, busy or expanded only exist in Android and they don't have corresponding AccessibilityTrait to set, so we could just ignore the implementation in RCTViewComponentView.mm. What I did is to update the AccessibilityState values in AccessibilityPrimitives.h and accessibilityPropsConversions.h in order to enable further implementation in Android.
Reviewed By: shergin
Differential Revision: D22807584
fbshipit-source-id: f3ef048055d11314bc833357d8ca061e0fe219a4
Summary:
Changelog: [Internal][Added] Support for toggling all breakpoints in Chrome debuggers
This implements the Debugger.setBreakpointsActive CDP message, allowing
users in Chrome to toggle all exceptions on and off.
As with V8/Chrome, setting a breakpoint will automatically re-activate
all breakpoints.
#utd-hermes-ignore-android
Reviewed By: avp
Differential Revision: D22825209
fbshipit-source-id: bda2cc59aba04443280bca46126c19bb0cdb58d7
Summary:
After D22801173 (9e6ba9ddb8) has landed, the native mechanisms in NativeAnimated to delay queued items from immediate execution are no longer necessary.
Fabric and non-Fabric animations both look smooth after deleting this code.
Changelog: [Internal]
Reviewed By: mdvacca
Differential Revision: D22807906
fbshipit-source-id: 9241fff84376f6aa9a35049cc40dfd6561effaa1
Summary:
As a followup to D22743723 (d53fc8a3cd) on the iOS side, I implement a BackgroundExecutor that can be used from C++ to schedule layouts on their own thread, off the JS and UI thread.
This is a potential perf improvement that we will experiment with.
Changelog: [Internal]
Reviewed By: mdvacca
Differential Revision: D22826795
fbshipit-source-id: 899bd67fe1b86f52910951e9536b59a1414a304c
Summary:
In Fabric, there are two subtle differences in Animated:
1) On the native side, queued NativeAnimated operations are executed more frequently
2) On the JS side there seems to be a bigger gap between AnimatedNodes being set up, and the final `componentDidMount`/`componentDidUpdate` that results in `_attachNativeEvents` being called.
This results in some visual glitching for certain features like StickyScrollViewHeader and other animations that are frequently rerendered. Rerendering an animated component relies on sync-like behavior
(new animations must be set up in the same frame that old animations are torn down, and the UI must flush any updates in the same frame). This sync-like behavior is trickier to achieve in Fabric, so
we introduce this mechanism, in Fabric only, to queued operations more aggressively on the JS side and only flush them when `componentDidMount`/`componentDidUpdate` have been called on all relevant nodes.
This seems to resolve longstanding issues with animations in Fabric on Android.
There are unrelated issues on iOS that make this difficult to test currently, so I'll keep the new path Android-only for now.
Changelog: [Internal]
Reviewed By: sammy-SC
Differential Revision: D22801173
fbshipit-source-id: 3db2235483636c9074df941cfac0a30f3f97545a
Summary:
This PR allows the use_flipper! helper function to be used in projects that
have more than just Debug/Release configurations. For example, a project
may have DevDebug, DevRelease, ProdDebug, and ProdRelease configurations.
These projects can now do:
```ruby
use_flipper!(configurations: ['DevDebug', 'ProdDebug'])
```
## Changelog
[iOS][Added] Ability to set which configuration to enable flipper for when using use_flipper!
Pull Request resolved: https://github.com/facebook/react-native/pull/29074
Test Plan:
I don't know how to run code in this repository, so I copy and pasted this function into the Podfile of an existing project. My complete Podfile is as below:
```ruby
# Uncomment the next line to define a global platform for your project
platform :ios, '10.0'
require_relative '../node_modules/react-native-community/cli-platform-ios/native_modules'
project 'marketplace',
'Dev.Debug' => :debug,
'Dev.Release' => :release,
'Prod.Debug' => :debug,
'Prod.Release' => :release
def use_flipper!(versions = {}, configurations: ['Debug'])
versions['Flipper'] ||= '~> 0.33.1'
versions['DoubleConversion'] ||= '1.1.7'
versions['Flipper-Folly'] ||= '~> 2.1'
versions['Flipper-Glog'] ||= '0.3.6'
versions['Flipper-PeerTalk'] ||= '~> 0.0.4'
versions['Flipper-RSocket'] ||= '~> 1.0'
pod 'FlipperKit', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FlipperKitLayoutPlugin', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/SKIOSNetworkPlugin', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FlipperKitUserDefaultsPlugin', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FlipperKitReactPlugin', versions['Flipper'], :configurations => configurations
# List all transitive dependencies for FlipperKit pods
# to avoid them being linked in Release builds
pod 'Flipper', versions['Flipper'], :configurations => configurations
pod 'Flipper-DoubleConversion', versions['Flipper-DoubleConversion'], :configurations => configurations
pod 'Flipper-Folly', versions['Flipper-Folly'], :configurations => configurations
pod 'Flipper-Glog', versions['Flipper-Glog'], :configurations => configurations
pod 'Flipper-PeerTalk', versions['Flipper-PeerTalk'], :configurations => configurations
pod 'Flipper-RSocket', versions['Flipper-RSocket'], :configurations => configurations
pod 'FlipperKit/Core', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/CppBridge', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FBCxxFollyDynamicConvert', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FBDefines', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FKPortForwarding', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FlipperKitHighlightOverlay', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FlipperKitLayoutTextSearchable', versions['Flipper'], :configurations => configurations
pod 'FlipperKit/FlipperKitNetworkPlugin', versions['Flipper'], :configurations => configurations
end
# Post Install processing for Flipper
def flipper_post_install(installer)
installer.pods_project.targets.each do |target|
if target.name == 'YogaKit'
target.build_configurations.each do |config|
config.build_settings['SWIFT_VERSION'] = '4.1'
end
end
end
end
target 'marketplace' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
#use_frameworks!
pod 'FBLazyVector', :path => '../node_modules/react-native/Libraries/FBLazyVector'
pod 'FBReactNativeSpec', :path => '../node_modules/react-native/Libraries/FBReactNativeSpec'
pod 'RCTRequired', :path => '../node_modules/react-native/Libraries/RCTRequired'
pod 'RCTTypeSafety', :path => '../node_modules/react-native/Libraries/TypeSafety'
pod 'React', :path => '../node_modules/react-native/'
pod 'React-Core', :path => '../node_modules/react-native/'
pod 'React-CoreModules', :path => '../node_modules/react-native/React/CoreModules'
pod 'React-Core/DevSupport', :path => '../node_modules/react-native/'
pod 'React-RCTActionSheet', :path => '../node_modules/react-native/Libraries/ActionSheetIOS'
pod 'React-RCTAnimation', :path => '../node_modules/react-native/Libraries/NativeAnimation'
pod 'React-RCTBlob', :path => '../node_modules/react-native/Libraries/Blob'
pod 'React-RCTImage', :path => '../node_modules/react-native/Libraries/Image'
pod 'React-RCTLinking', :path => '../node_modules/react-native/Libraries/LinkingIOS'
pod 'React-RCTNetwork', :path => '../node_modules/react-native/Libraries/Network'
pod 'React-RCTSettings', :path => '../node_modules/react-native/Libraries/Settings'
pod 'React-RCTText', :path => '../node_modules/react-native/Libraries/Text'
pod 'React-RCTVibration', :path => '../node_modules/react-native/Libraries/Vibration'
pod 'React-Core/RCTWebSocket', :path => '../node_modules/react-native/'
pod 'React-cxxreact', :path => '../node_modules/react-native/ReactCommon/cxxreact'
pod 'React-jsi', :path => '../node_modules/react-native/ReactCommon/jsi'
pod 'React-jsiexecutor', :path => '../node_modules/react-native/ReactCommon/jsiexecutor'
pod 'React-jsinspector', :path => '../node_modules/react-native/ReactCommon/jsinspector'
pod 'ReactCommon/callinvoker', :path => '../node_modules/react-native/ReactCommon'
pod 'ReactCommon/turbomodule/core', :path => '../node_modules/react-native/ReactCommon'
pod 'Yoga', :path => '../node_modules/react-native/ReactCommon/yoga', :modular_headers => true
pod 'DoubleConversion', :podspec => '../node_modules/react-native/third-party-podspecs/DoubleConversion.podspec'
pod 'glog', :podspec => '../node_modules/react-native/third-party-podspecs/glog.podspec'
pod 'Folly', :podspec => '../node_modules/react-native/third-party-podspecs/Folly.podspec'
pod 'Intercom', '~> 6.0.0'
pod 'RNDeviceInfo', :path => '../node_modules/react-native-device-info'
pod 'react-native-netinfo', :podspec => '../node_modules/react-native-community/netinfo/react-native-netinfo.podspec'
pod 'BugsnagReactNative', :podspec => '../node_modules/bugsnag-react-native/BugsnagReactNative.podspec'
pod 'rn-fetch-blob', :podspec => '../node_modules/rn-fetch-blob/rn-fetch-blob.podspec'
use_native_modules!
pod 'react-native-intercom', :path => '../node_modules/react-native-intercom'
pod 'react-native-image-resizer', :path => '../node_modules/react-native-image-resizer'
pod 'RNVectorIcons', :path => '../node_modules/react-native-vector-icons'
pod 'react-native-camera', :path => '../node_modules/react-native-camera'
pod 'RNCPushNotificationIOS', :path => '../node_modules/react-native-community/push-notification-ios'
pod 'RNDateTimePicker', :path => '../node_modules/react-native-community/datetimepicker'
# Enables Flipper.
#
# Note that if you have use_frameworks! enabled, Flipper will not work and
# you should disable these next few lines.
use_flipper!(configurations: ['Dev.Debug', 'Prod.Debug'])
post_install do |installer|
flipper_post_install(installer)
installer.pods_project.targets.each do |target|
# The following is needed to ensure the "archive" step works in XCode.
# It removes React & Yoga from the Pods project, as it is already included in the main project.
# Without this, you'd see errors when you archive like:
# "Multiple commands produce ... libReact.a"
# "Multiple commands produce ... libyoga.a"
targets_to_ignore = %w(React yoga)
if targets_to_ignore.include? target.name
target.remove_from_project
end
end
end
end
```
I then ran `pod install`:
```
nico:ios/ (dev*) $ pod install [20:14:43]
Adding a custom script phase for Pod RNFBApp: [RNFB] Core Configuration
Detected React Native module pods for BVLinearGradient, RNCAsyncStorage, RNCPicker, RNCPushNotificationIOS, RNDateTimePicker, RNFBApp, RNFBAuth, RNFBDatabase, RNFBDynamicLinks, RNFBFirestore, RNFBStorage, RNSVG, RNVectorIcons, ReactNativeNavigation, react-native-camera, react-native-cameraroll, react-native-config, react-native-flipper, react-native-get-random-values, react-native-image-resizer, and react-native-intercom
Analyzing dependencies
Downloading dependencies
Generating Pods project
Integrating client project
Pod installation complete! There are 73 dependencies from the Podfile and 88 total pods installed.
[!] use_native_modules! skipped the react-native dependency 'react-native-photo-view'. No podspec file was found.
- Check to see if there is an updated version that contains the necessary podspec file
- Contact the library maintainers or send them a PR to add a podspec. The react-native-webview podspec is a good
example of a package.json driven podspec. See
https://github.com/react-native-community/react-native-webview/blob/master/react-native-webview.podspec
- If necessary, you can disable autolinking for the dependency and link it manually. See
https://github.com/react-native-community/cli/blob/master/docs/autolinking.md#how-can-i-disable-autolinking-for-unsupported-library
[!] use_native_modules! skipped the react-native dependency 'detox'. No podspec file was found.
- Check to see if there is an updated version that contains the necessary podspec file
- Contact the library maintainers or send them a PR to add a podspec. The react-native-webview podspec is a good
example of a package.json driven podspec. See
https://github.com/react-native-community/react-native-webview/blob/master/react-native-webview.podspec
- If necessary, you can disable autolinking for the dependency and link it manually. See
https://github.com/react-native-community/cli/blob/master/docs/autolinking.md#how-can-i-disable-autolinking-for-unsupported-library
```
Reviewed By: cpojer
Differential Revision: D22795421
Pulled By: passy
fbshipit-source-id: 89ba555eadc4918e9ac464a19a318198b237e01e
Summary:
Discovered when debugging a React Native app in Chrome. The function `performanceNow` was recently changed, so that in Chrome it now refers to `performance.now()` method. However, `now()` cannot be called standalone without a context.
Reproduced by a synthetic example in Chrome:
```
const performanceNow = window.performance.now;
performanceNow();
Uncaught TypeError: Illegal invocation
at <anonymous>:1:1
```
Changelog:
[General] [Fixed] - Fix failure when debugging code in a browser; was caused by `performanceNow()` function.
Reviewed By: cpojer
Differential Revision: D22739176
fbshipit-source-id: f89b8a215b7b4c430ffd72a1d23539c4f1b31d24
Summary:
Using RCTFabricSurface in bridgeless mode, this comment seems incorrect to me.
`[_surface start]` needs to be called after initialization, or else the stage and `SurfacePresenter` registration never happen.
Maybe this comment used to be true, but it is misleading with the current implementation.
Changelog: [Internal]
Reviewed By: shergin
Differential Revision: D22800934
fbshipit-source-id: c396cbd3fc1749b8e7ab571c9e7bc05cd352fc14
Summary:
In the next react sync we removed the `displayName` from forwardRef and useMemo components ([PR here](https://github.com/facebook/react/pull/18495 )).
This means we need to manually add the displayName in the mock.
Changelog: [General] [Fixed] Fix test renderer mocks to use the displayName more often.
Reviewed By: TheSavior
Differential Revision: D22775470
fbshipit-source-id: 1390dc325e34f7ccea32bbdf1c6a8f6efea3a080
Summary:
This diff adds some integration tests that throw read React errors and asserts on the LogBox data.
Changelog: [Internal]
Reviewed By: motiz88
Differential Revision: D22752147
fbshipit-source-id: eb2e1542524d67558f2450130015164acd4d6093
Summary:
In the next version of React they've changed the format of component stacks from a custom format to the same format as call stacks. This diff adds handling (and test) for the new format.
Changelog: [Internal]
Reviewed By: motiz88
Differential Revision: D22752034
fbshipit-source-id: 38d74bffd9ed623cbdd71e70103d66d8f0765fd9
Summary:
Changelog: Fix [TypeError: Network request failed] on file upload
# Problem
In 3198009410 I made method `loadImageForURL` blocking and nil returning since it was no longer cancellable.
However inside `[RCTNetworkTask validateRequestToken]` was a logic counting on request token being non nil.
This diff removes this check and adds `nullable` to `[RCTImageURLLoader loadImageForURL]` making it explicit.
Reviewed By: PeteTheHeat
Differential Revision: D22767174
fbshipit-source-id: 04d5562e381912233b9c14e8156cbf145288f063
Summary:
Only add Sec-WebSocket-Protocol header if has _requestedProtocols.
## Changelog
<!-- Help reviewers and the release process by writing your own changelog entry. For an example, see:
https://github.com/facebook/react-native/wiki/Changelog
-->
[iOS] [Fixed] - when Sec-WebSocket-Protocol header is empty vaulue, IIS server will return error 502.
Pull Request resolved: https://github.com/facebook/react-native/pull/29419
Reviewed By: cpojer
Differential Revision: D22782867
Pulled By: PeteTheHeat
fbshipit-source-id: d588997a345929b0c11c554d4452e612a336901a
Summary: As part of our usage color detection that relies on precise values of colors, it appears that the ration used was 256, but RBGA scale is 0-255
Reviewed By: shergin
Differential Revision: D22785378
fbshipit-source-id: 87a6f9b4611ceaadbbbb75a4566f4cf9b8285b68
Summary:
This diff fixes the rendering of ART Shapes that uses null paths
changelog: [internal] internal fix
Reviewed By: JoshuaGross
Differential Revision: D22780163
fbshipit-source-id: 2aded726ad47fce243ec1c28fbd4c39dd71820ef
Summary:
See title. Basically during stopSurface a single BatchMountInstruction can contain both the Create and Delete MountItem for a single view, which will cause *only* the deletion to be executed.
There isn't really a way to prevent this and we're just trying to clean up as aggressively as possible, so we can safely ignore this.
Changelog: [Internal]
Reviewed By: mdvacca
Differential Revision: D22779189
fbshipit-source-id: c44fd736835b04c5de776346ec3d34afa4860199
Summary:
This exception will be more disruptive during development than necessary.
This can be upgraded again if there's a reasonable root-cause, but right now this error isn't actionable enough, is too common, and the repercussions aren't obvious.
Changelog: [Internal]
Reviewed By: mdvacca
Differential Revision: D22775734
fbshipit-source-id: 2cd9449f5b78025f7a230fbbd5f2e87bce183d04
Summary:
Changelog:
[Internal] - Add additional tests to cover other features in RCTParagraphComponentView.
I mainly test the correctness of attributedString and fragments in the RCTParagraphComponentView.
Reviewed By: shergin
Differential Revision: D22668022
fbshipit-source-id: 6879eb6b6a6ace9e6e05f1486d4e4034ebfd73bc
Summary:
Changelog:
[Internal] - Build the basic RCTParagraphComponentViewTests. Add the content of tests.
I mainly test the cases of text with multiple links inside, text with link which crosses multiple lines and truncated text with link.
Reviewed By: shergin
Differential Revision: D22607097
fbshipit-source-id: c98b8d4c5424a3e51e2869f50bc5038f969e45e8
Summary:
Pull Request resolved: https://github.com/facebook/react-native/pull/29470
Changelog:
[Internal] - Build the framework of the RCTParagraphComponentViewTests and do some setup.
I built a shadowNode tree here for future tests.
Reviewed By: shergin
Differential Revision: D22536626
fbshipit-source-id: c74b63b3319693b90c9d64b7f782a1a922b0d499
Summary:
The Animated native module cannot be converted to a TM because it has perf regressions when used in conjunction with Paper renderer. Instead of fixing these complicated perf issues (which will disappear when Fabric ships this half), temporarily fork the native module. The new fork is converted to a TM, and only used to unblock bridgeless mode testing.
Changelog:[Internal]
Reviewed By: RSNara
Differential Revision: D22651010
fbshipit-source-id: 912123ef38ac8c66025b7bba34a65ec6d98f330d
Summary:
Changelog:
[Internal][Added] - Change signature of `addTimestamp` for IPerformanceLogger and rename old implementation to addTimeAnnotation
Adding this because there is no current ability to add a timespan to our perf logging with pre-defined start and end timestamps. The naming is a bit confusing because the current implementation of `addTimespan` in FB doesn't add a timespan, it adds an annotation of duration. We rename the old implementation to `addTimeAnnotation/s` and update `addTimespan` to suit our needs.
Reviewed By: rubennorte
Differential Revision: D22633202
fbshipit-source-id: 0e32099241f1f3835257cbb4ad108a4f437869e6
Summary:
I want to be able parse error stacks in contexts where I have a call stack string but no error object.
This diff changes parseErrorStack to only accept the stack, instead of a whole error object.
Changelog: [Internal]
Reviewed By: motiz88
Differential Revision: D22752048
fbshipit-source-id: b4b1cd58802eefe736130d48a82bc091241a11ee
Summary:
This diff reverts a revert of D22456266 (0060b5de55) and fixes the reason why it was reverted. Reverted in D22532594 (c0e7e1bd9c).
For reason why it was introduced in the first place, please refer to D22456266 (0060b5de55).
Problem:
`includeTransform` was not taken into account when calculating offset.
I added a unit test covering this specific scenario.
Reviewed By: shergin
Differential Revision: D22763011
fbshipit-source-id: e7d88fc19608ad1a4c7b5e594a9cc48122a2799b
Summary:
Changelog: Fix possible race condition inside `KeyboardAvoidingView`
Fabric has different order of events
In Fabric, `keyboardWillChangeFrame` event is fired before `onLayout`, but in Paper it is the other way around.
`KeyboardAvoidingView` depends on the order of events to function properly. Inside `_relativeKeyboardHeight` 0 is returned if `this._frame` is null.
To fix this, `bottom` margin is recalculated whenever `keyboardWillChangeFrame` or `onLayout` is triggered.
Reviewed By: shergin
Differential Revision: D22764192
fbshipit-source-id: 591ac59af4395a4d43c4e78e4fbc0ff118b292f8
Summary:
Enable registerSegment in Venice and verify bundle splitting works for Pokes with Venice.
Changelog: [Internal]
Reviewed By: ejanzer
Differential Revision: D22666115
fbshipit-source-id: 74ef830b802634b1019d4371873aba599438de37
Summary:
The standard says that zIndex should only be defined for non-`static` positioned views. This diff implements it.
For now, it actually enables zIndex for all views in RN because there is no way to specify `position: static` but will will give that ability by changing Flow definitions in future diffs in a couple of weeks (to ensure OTA safety).
Changelog: [Internal] Fabric-specific internal change.
Reviewed By: sammy-SC
Differential Revision: D22098586
fbshipit-source-id: 77dacbee0fe887f667ba81640b8bd759e1df11fd
Summary:
In W3C standard, `zIndex` prop can have `auto` value which is the default.
In classic React Native and in Fabric before this diff, the default value was `0`. The only difference between `auto` and `0` is that nodes with `auto` do not form stacking context whereas nodes with `0` (or any other numeric value) do. This worked fine in pre-Fabric RN where every view always formed staking context but in Fabric we need to finally implement it right.
https://developer.mozilla.org/en-US/docs/Web/CSS/z-indexhttps://stackoverflow.com/a/57892072/496389
Changelog: [Internal] Fabric-specific internal change.
Reviewed By: sammy-SC
Differential Revision: D22403383
fbshipit-source-id: 6532d180a00f22bde763e3ebadd6683b344a0672
Summary:
Due to subtle differences in lifecycle on the native side, as well as in JS, Fabric constructs partial graphs more frequently than non-Fabric RN did.
We still crash if we detect a cycle, which we check for more explicitly now; and we still always crash in non-Fabric. But if we detect a partial graph in Fabric,
we warn instead of crashing. We also print the state of the graph before crashing/warning, to assist in debugging in production.
Changelog: [Internal]
Reviewed By: shergin
Differential Revision: D22752291
fbshipit-source-id: f452892678fbe7b5a49f93644d39d3b6ae5bda75