Summary:
This diff changes the LogBox to show the code frame for the first non-collapsed stack frame. Let me know what you think about this change!
Changelog: [Internal] LogBox changes
Reviewed By: rickhanlonii
Differential Revision: D18372456
fbshipit-source-id: ddf6d6c53ab28d11d8355f4cb1cb071a00a7366e
Summary:
This diff adds error handling to logbox so that if there is an error either when parsing logs or when rendering LogBox, we show a native redbox with the error that was thrown and a message explaining that it's an internal React Native error.
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18394788
fbshipit-source-id: 5d74d58e4b28ef6d863079e83677fb23ef4ccb34
Summary:
I'll land this once the upgrade to v0.111 is rolled out here. That release turns this flag on by default.
Changelog: [Internal] Adjust Flow configuration
Reviewed By: panagosg7
Differential Revision: D18329245
fbshipit-source-id: a9ab92fda06d546f3246dcdd066e904b5a657062
Summary:
The diff moves an invocation of `_synchronizeAllSettings` from the constructor to `setBridge`. The side-effects of `_synchronizeAllSettings` rely on a bridge not being nil, so we need to ensure that the bridge is assigned to the instance before calling `_synchronizeAllSettings`.
Before the fix, enabling JavaScript debugger caused a stale and opening many copies of a debugger in Chrome.
Changelog: [Internal] Fixed race and possible stale in RCTDevSettings
Reviewed By: RSNara
Differential Revision: D18379596
fbshipit-source-id: 9f64b9bc5426720948113de61bc9ccc8c39193b4
Summary:
The documentation for the method says that it must be called from a subclass, but the methods wasn't marked as protected.
Calling `beat` directly will bypass custom logic implemented in subclasses (because it's not a virtual function (by-design)). That's practically what happened before and what the previous diffs in the stack fix.
Changelog: [Internal]
Reviewed By: JoshuaGross
Differential Revision: D18339594
fbshipit-source-id: 3d8c53b69e1b72d447714dd91c9392bdfb05b9ae
Summary:
This diff changes the implementation a little bit:
* We don't use RuntimeExecutor there anymore (because it's already been used in EventBeat). The actual purpose of EventBeatManager was distilled to "provide a tick synchronized with the main run loop";
* Now we use dedicated EventBeatManagerObserver interface to decouple this functionality from EventBeat-intrinsic functionality;
* A bunch of small clean-ups.
* Now we ensure threading and capturing ownership in a single function in AsyncEventBeat class. Before this change, the EventBeatManager called `beat` function of the EventBeat directly bypassing AsyncEventBeat class, and effectively bypassing the check that underlying infra still exists (aka EventBeat::OwnerBox feature). That alone might fix some C++ crashes that we see.
Changelog: [Internal] Fabric-specific internal change.
Reviewed By: sammy-SC
Differential Revision: D18307655
fbshipit-source-id: 3b582cb71085ed99ee94f8e6d575196c2082557b
Summary:
* We no more pollute the global namespace with JSI stuff;
* We don't use JSI here, so why to include;
* We don't use `Instance`, so why to forward-declare this;
Changelog: [Internal] Fabric-specific internal change.
Reviewed By: JoshuaGross, sammy-SC
Differential Revision: D18307654
fbshipit-source-id: b6c3ad55d7bd605074db9fa1d4bc58a73e0b2d74
Summary:
The C++ counterpart of EventBeatManager uses RuntimeExecutor for that, so it's redundant to do that in EventBeatManager.java.
Changelog: [Internal] Fabric-specific internal change.
Reviewed By: sammy-SC
Differential Revision: D18307657
fbshipit-source-id: 65823b25d691a56540247d317e3c0e86685150c8
Summary:
This diff adds the ability to press the file name of a code frame to open the file in your editor.
Note: I re-worked the frame location to extract the frame row and column at parse time so that we don't need to do any clowny regexes down stream.
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18358283
fbshipit-source-id: 705e07d229c66ecfd225a8fb65ef2f78b5034c9c
Summary:
This diff adds more information to the meta area so it doesn't look so empty and dims the text so it doesn't jump out so much.
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18360434
fbshipit-source-id: d460ffd59ef032d89879f88e309ac81e6d862c30
Summary:
Interop layer can now forward commands to paper components.
Changelog: [internal]
Reviewed By: shergin
Differential Revision: D18285766
fbshipit-source-id: 33fe071c3000569d52fedcbcdeccc354dfe277d9
Summary:
Based on feedback "minimize" wasn't clear and "close" is more common so it should be on the right
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18353907
fbshipit-source-id: bccfc9be6c225a9adb31ef11d6a91330a7d4e008
Summary:
This diff lowers the intensity of the shadow on the fatal button based on user feedback that it's weird.
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18353498
fbshipit-source-id: 9133aae02e5609e181a55289f349ea6a9e9fdaf6
Summary:
It's nice to be able to still see which stack frames are collapsed even when they're expanded.
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18352700
fbshipit-source-id: f76086574677ea58c6b19b3300597681a17a96ae
Summary:
The previous diff mistakenly landed an old version
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18358917
fbshipit-source-id: 284dd6754c4aea3814e5f45dae6f68ed2c261b6a
Summary:
This implement new <UnimplementedView> (only for iOS for now) that relies on the new "reactive component registration" functionality.
The `UnimplementedView` component is the perfect example of that. It's simple and uniquely required some constraints that we want to implement: the same component class registered several times with different handles and names.
This change serves two needs:
1. Providing an example of how that functionality can be used in more complex cases.
2. That will allow removing some `UnimplementedView`-specific code from the core (and very hot pathes of the system) and make them `noexcept`. That will eventually allow removing some public APIs from RawValue (constructing from folly::dynamic) that currently impose some implementation details and probably prevent us from making it slightly faster. There are only two consumers of this API, this is one of them.
Changelog: [Internal]
Reviewed By: fkgozali
Differential Revision: D17211913
fbshipit-source-id: df1a1ac1a36289ef79904d509d38ee8b3f5588fb
Summary:
It's a logical error on the application layer if a Scheduler is being deallocated before all Surfaces were stopped. Besides that this requirement must be satisfied to make concurrent deallocation of Scheduler and calling on it from `UIManager` side thread-safe.
Changelog: [Internal]
Reviewed By: JoshuaGross, sammy-SC
Differential Revision: D18333709
fbshipit-source-id: 4af0ba488bb4306eb82807c2f0ee5b7c598dcfed
Summary:
There is no need for that functionality to be delegated to Scheduler, that's a leftover of the previous iteration of the design.
Nothing really changed.
Changelog: [Internal] Fabric-specific internal change.
Reviewed By: sammy-SC
Differential Revision: D18285501
fbshipit-source-id: 4b60445b663a2431fbdc7cc1120f46d56819c430
Summary:
Now `UIManager` serves as `ShadowTree`'s delegate instead of `Scheduler`.
There is no good reason for Scheduler to be a ShadowTree delegate anymore, now UIManager owns all ShadowTree instances (via the registry). The existing configuration causes a crash because `ShadowTree` can overlive the `Scheduler`. Having a `UIManager` as a delegate of `ShadowTree` solves the problem because `UIManager` checks the own delegate for (which is actually a Scheduler) nullability before calling something on it (and `Scheduler` nulls that delegate during own deallocation process).
(No actual ownership relations were changed in the diff.)
Changelog: [Internal] Fabric-specific internal change.
Reviewed By: JoshuaGross
Differential Revision: D18285500
fbshipit-source-id: 35ac4f37b6abdf4857a23c4869785a323e433317
Summary:
This diff removes `ComponentDescriptorProviderRegistry::remove()` and two derivative interfaces.
First, we don't use that and there is no concrete idea why we would need to use that. Those were originally built only for symmetry with limited knowledge about what exactly we need.
Second, those methods are actually dangerous and probably must not be supported by design. Removing a ComponentDescriptorProvider destroys already registered `ComponentDescriptor`s, and at the same time we might have ShadowNodes referring to that (which will cause a crash), and there is no reasonable way to check for the existence of those nodes.
Changelog: [Internal] Fabric-specific internal change.
Reviewed By: sammy-SC
Differential Revision: D18285497
fbshipit-source-id: b461e38b923c217a256e1155689311397a994feb
Summary:
Fixes the comical level of padding at the end of the scroll container.
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18351352
fbshipit-source-id: 5482fb81d0e385f0ce36530491b407c03ad87f3e
Summary:
`getUIManagerX(...)` can return null now. Guard in a few places that use it or add comments.
Changelog: [Internal]
Reviewed By: alexeylang
Differential Revision: D18351197
fbshipit-source-id: f077835468a75d1af24cfb4210989ba875ff9086
Summary:
Previously the background for the LogBox inspector footer buttons bleed into the background behind them. This change gives them more distinct on press backgrounds.
Changelog: [Internal]
Reviewed By: cpojer
Differential Revision: D18337437
fbshipit-source-id: c0cefd4464d94dc23316208135a9bf922fb510cb
Summary:
Some feedback for logbox is that the count wasn't centered on certain devices (e.g. Nexus 6 but not Pixel 3), and that the white badge count color for warnings was hard to read. This diff fixes both issues.
Changelog: [Internal]
Differential Revision: D18336681
fbshipit-source-id: 8200bcf04dcea9a6bbcaa1555fbab000c78c0a4f
Summary:
When messages are collapsed, showing a different style for the string substitutions for interpolated strings is jarring, so let's show the plaintext instead.
Changelog: [Internal]
Differential Revision: D18335295
fbshipit-source-id: f718469ac3206fd7a934a26495ebf8b1850fb674
Summary:
This diff updates the handling for `console.disableLogBox` so that:
- It does not disable fatals and syntax errors
- When there is a fatal or syntax error, the hidden logs are still shown and browsable
Changelog: [Internal]
Differential Revision: D18339684
fbshipit-source-id: 906122cc19ce50b3a21a42ae455206796953bcf3
Summary:
There were a couple of inconsistencies and outdated checksums in `RNTester`'s `Podfile.lock` - Running `pod install` would leave a clean clone dirty.
This updates Podfile.lock (no manual changes).
## Changelog
[General] [Changed] - Update RNTester Podfile.lock
Pull Request resolved: https://github.com/facebook/react-native/pull/26976
Test Plan:
```
cd RNTester
pod install
```
Verify that `git status` is clean.
**Ensure that RNTesterPods.xcworkspace builds`
1. Run: `open ~/fbsource/xplat/js/react-native-github/RNTester/RNTesterPods.xcworkspace`
2. Press Run
3. **Assert:** The project should compile without error.
Differential Revision: D18102395
Pulled By: RSNara
fbshipit-source-id: a20a9f6b69727fa63d1eaac1a2b1150c6f6400cf
Summary:
This diff migrates ReactDialogPickerManager and ReactDropdownPickerManager to use the generated delegates for setting their properties.
Changelog:
[Android] [Added] - Use generated Java delegate for setting properties on ReactDialogPickerManager and ReactDropdownPickerManager
Reviewed By: mdvacca
Differential Revision: D17930994
fbshipit-source-id: 009ad9eceb683b7170eddeccfd986b1dc5cb8c0b
Summary:
Revert some changes from D18148890 as they broke loading of RN surfaces with following error
``Invariant Violation: Expected HMRClient.setup() call at startup`
Changelog: [internal]
Reviewed By: mmmulani
Differential Revision: D18324764
fbshipit-source-id: f1b4af630f8330444f70a4d93be2b53f6d8e31c2
Summary:
These files are currently seen by Git if opening the project in Visual Studio or VSCode.
## Changelog
[Internal] [Fixed] - Add Visual Studio files to .gitignore
Pull Request resolved: https://github.com/facebook/react-native/pull/27132
Differential Revision: D18346486
Pulled By: cpojer
fbshipit-source-id: e1ff752790d46455e85b13f2508cd0286d6bdde2
Summary:
Add handwritten view config for AndroidHorizontalScrollContentView. Same as RCTScrollContentView, this native component has no props of its own other than what View accepts. It's simply used as a container for the horizontal ScrollView on Android.
Changelog: [Internal]
Reviewed By: rickhanlonii
Differential Revision: D18284673
fbshipit-source-id: 8cd6282a3b2e5c9876da5cc0e068b12dd56acfd8
Summary:
Adding a handwritten view config for AndroidHorizontalScrollView, the native component that's used with `<ScrollView horizontal={true} />` on Android. Native props are the same as `RCTScrollView`, so I'm reusing the type for that.
Changelog: [Internal]
Reviewed By: rickhanlonii
Differential Revision: D18284517
fbshipit-source-id: 7c81f72440b93d611f9574ad2c01a96530d07bf7
Summary:
Adding a handwritten view config for RCTScrollContentView. This host component doesn't actually have any props of its own separate from View; it's just a container for a ScrollView.
Changelog: [Internal]
Reviewed By: rickhanlonii
Differential Revision: D18283792
fbshipit-source-id: db95e981f54bef7c068b907c5d1fa52774dad147
Summary:
Adding a handwritten view config for RCTScrollView, to be used in DEV only (for now).
Changelog: [Internal]
Reviewed By: rickhanlonii
Differential Revision: D18263203
fbshipit-source-id: 975499f030c7caed9851bcde0be42c5058911ad5
Summary:
Adding a new String field for `instanceKey` to ReactContext, which is set via a new constructor on ReactApplicationContext. Also adding getters to ReactContext and ThemedReactContext so that it's accessible from any instance/subclass of ReactContext.
This will only be used in bridgeless mode.
Reviewed By: mdvacca
Differential Revision: D18316556
fbshipit-source-id: 9757da72fde4ba36034c1e129326461fed496229
Summary:
still some generated files in www that need to land before we can release 0.111 here.
drop-conflicts
Changelog: [Internal]
(Note: this ignores all push blocking failures!)
Reviewed By: dsainati1
Differential Revision: D18278838
fbshipit-source-id: b20c3fefb3aab7c5fb614b33d846c7548184f49a
Summary:
Use double for YGRoundValueToPixelGrid calculations as we were losing some precision in float operations
#Changelog:
[Internal][Yoga] Use double for YGRoundValueToPixelGrid calculations
Reviewed By: astreet
Differential Revision: D18225999
fbshipit-source-id: 69c05f56a0e0f3433bf0bd958aa07d26dd83fe02
Summary:
Turns out that `SoftAssertions.java` has always been a lie - it actually always throws exceptions. Migrate it to using `ReactSoftException`.
This file hasn't been touched at all since it was originally open-sourced, besides codemods!
Changelog: [Internal]
Reviewed By: mdvacca
Differential Revision: D18336020
fbshipit-source-id: cba3db25a9f9d61325dd3f7843e92e984ae56281
Summary:
This diff fixes a crash when using TextInput.FontVariant prop in Android API level < 26
Changelog: Fix TextInput.FontVariant prop in Android API level < 26 (related to PR https://github.com/facebook/react-native/pull/27006)
Reviewed By: JoshuaGross
Differential Revision: D18331807
fbshipit-source-id: 5eac4d9e38eb099fae1287d128f3f8c249b0b8bc
Summary:
As part of `T54997838` we're auditing where removeView could possibly be called in a background thread, and adding annotations to indicate places where we don't think it's possible.
Changelog: [internal]
Reviewed By: makovkastar
Differential Revision: D18320461
fbshipit-source-id: 84b6b9e293d903f835fc42bc98614efb54158986
Summary:
This diff ensures that ReactInstanceManager has a valid catalystInstance when updating views as part of the animation system.
This also force the update of views to be posted in the UI Thread
Changelog: [internal]
Reviewed By: JoshuaGross
Differential Revision: D18311782
fbshipit-source-id: 1f1e7b0d34346f34b3607e5b75e5c14cda3f4861
Summary:
In next diff Coordinator will have get more responsibilities therefore it's better to separate the concerns to different class
Changelog: [Internal]
Reviewed By: shergin
Differential Revision: D18304834
fbshipit-source-id: 168a68969ed9da5772895f2da87e5273dccbaf30