chore(0.78): Merge up to React Native 0.78.3 upstream#2621
Merged
Saadnajmi merged 21 commits intomicrosoft:0.78-stablefrom Aug 8, 2025
Merged
chore(0.78): Merge up to React Native 0.78.3 upstream#2621Saadnajmi merged 21 commits intomicrosoft:0.78-stablefrom
Saadnajmi merged 21 commits intomicrosoft:0.78-stablefrom
Conversation
Summary: Pull Request resolved: facebook#51693 This moves React Native to use the Central Portal URLs rather than the legacy OSSRH ones. See https://github.com/gradle-nexus/publish-plugin for more context. Changelog: [Internal] [Changed] - Reviewed By: cipolleschi Differential Revision: D75673984 fbshipit-source-id: 1de6746809eed72f232eac0c3fb4d809c2046620
…om (facebook#52004) Summary: Pull Request resolved: facebook#52004 This is necessary because the snapshots are now going to be published on a different repository: central.sonatype.com. Changelog: [Internal] [Changed] - Reviewed By: cipolleschi Differential Revision: D76596802 fbshipit-source-id: 424fb1134e41502d53b76209fba325c895c79ba8
Summary: Due to us moving to central.sonatype.com for publishing, we cannot publish and release the Maven repository in 2 distinct invocations. This consolidates all the publishing job to happen during build_npm_package Changelog: [Internal] [Changed] - Reviewed By: fabriziocucci Differential Revision: D76888543 fbshipit-source-id: 3cb0db6176ed2221a12b4f3f1f575232aa006a6c
Summary: Pull Request resolved: facebook#50464 Runners in GHA has been updated by github and they now ship with CMake 4.0. (actions/runner-images#11926) This version is not compatible with React Native, so we are pinning cmake to 3.36.1 ## Changelog: [Internal] - Pin cmake to 3.36.1 Reviewed By: cortinico Differential Revision: D72379834 fbshipit-source-id: ab09009102118e6590f02cf57fa6f9149482f62b
…51798) Summary: As per title, GH is [removing windows-2019](https://github.com/facebook/react-native/actions/runs/15421451006/job/43403215354) at the end of the month. We need to migrate away from them. ## Changelog: [Internal] - Bump windows runners Pull Request resolved: facebook#51798 Test Plan: GHA Reviewed By: cortinico Differential Revision: D75946994 Pulled By: cipolleschi fbshipit-source-id: 972b60300c918c0eae0403ed4149347a4ffa8bd0
Summary: See facebook#51212 - children aren't updated correctly in an old arch native view using the interop layer under Fabric. This is caused by the mountChildComponentView method not updating the view, only adding the new view to a list that will be used on the next update to mount the child. This commit fixes this by adding the same pattern as in unmountChildComponentView where children are inserted directly if the underlying paperview is available in the adapter - otherwise it uses the mounting list as before. #Closes 51212 bypass-github-export-checks ## Changelog: [IOS] [FIXED] - fixed adding child views to a native view using the interop layer Pull Request resolved: facebook#51213 Test Plan: **Previous output**: <image src="https://github.com/user-attachments/assets/472b95e7-0921-46c9-be6a-f31759c0cd26" width="200px" /> **After fix**: <image src="https://github.com/user-attachments/assets/554387cd-c264-483e-9c52-d9cd40b42601" width="200px" /> Reviewed By: sammy-SC Differential Revision: D74471278 Pulled By: cipolleschi fbshipit-source-id: 798f9e7be389359bd6e3aa1b6a6e9fb799fcb369
…with web standard (facebook#51500) Summary: Calls to create timers should return sequential ids (integers greater than zero in the spec's words). This regressed in the `TimerManager` implementation, which instead starts at zero inclusively. This has two side-effects for code assuming a spec-compliant implementation of `setTimeout` and `setInterval`: - Calls to `clearTimeout(0)` or `clearInterval(0)` will potentially cancel scheduled timers, although it's supposed to be a noop - Predicates like `if (timeoutId)` will fail since they assume non-negative ids The change in this PR is to align with WHATWG HTML 8.6.2 (Timers): https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#timers > otherwise, let id be an [implementation-defined](https://infra.spec.whatwg.org/#implementation-defined) integer that is **greater than zero** and does not already [exist](https://infra.spec.whatwg.org/#map-exists) in global's [map of setTimeout and setInterval IDs](https://html.spec.whatwg.org/multipage/timers-and-user-prompts.html#map-of-settimeout-and-setinterval-ids). Specifically, - we should return `0` to indicate that no timer was scheduled - we should start generating timer IDs at `1` instead of `0` This was previously raised in review comments here: https://github.com/facebook/react-native/pull/45092/files#r1650790008 The spec-incompliant behaviour was raised in an issue here: apollographql/apollo-client#12632 (comment) This PR does not, - add bounds checking on `timerIndex_` and add a search of an available id that isn't in the unordered map - exclude `0` from being an accepted `TimerHandle` in `TimerManager::createTimer` or `TimerManager::deleteTimer` since the above bounds checking hasn't been added either ## Changelog: [GENERAL] [FIXED] - Align timer IDs and timer function argument error handling with web standards. Pull Request resolved: facebook#51500 Test Plan: - Run `setTimeout` / `setInterval`; before applied changes the timeout for the first timer will be `0` - Run `setTimeout(null)`; before applied changes the timer ID will be non-zero - Run `setInterval(null)`; before applied changes an error will be thrown rather than `0` being returned Reviewed By: cipolleschi Differential Revision: D75145909 Pulled By: rshest fbshipit-source-id: 6646439abd29cf3cfa9e5cf0a57448e3b7cd1b48
Summary: This fixes an issue in Fabric where changing the layout direction and then reloading the JS bundle did not honor the layout direction until the app was restarted on iOS. This now calls `_updateLayoutContext` whenever RCTSurfaceView is recreated which happens on bundle reload. This is not an issue on the old architecture because the layout direction is determined within the [SurfaceViews](https://github.com/facebook/react-native/blob/acdddef48eb60b002c954d7d2447cb9c2883c8b3/packages/react-native/React/Views/RCTRootShadowView.m#L18) which were recreated on bundle reload. ## Related Issues: - react-native-community/discussions-and-proposals#847 - facebook#49451 - facebook#48311 - facebook#45661 ## How can we take this further? If we want to make it so that it doesn't require an entire bundle reload for RTL to take effect I believe these are the steps that would need to be taken: - Make it so [RCTI18nManager](https://github.com/facebook/react-native/blob/acdddef48eb60b002c954d7d2447cb9c2883c8b3/packages/react-native/React/CoreModules/RCTI18nManager.mm#L52) exports isRTL as a method instead of consts - Send Notification Center notif when RTL is forced on or off - Listen for that notification RCTSurfaceView and call _updateLayoutContext similar to UIContentSizeCategoryDidChangeNotification. ## Changelog: [iOS] [FIXED] - Layout direction changes are now honored on bundle reload. <!-- Help reviewers and the release process by writing your own changelog entry. Pick one each for the category and type tags: For more details, see: https://reactnative.dev/contributing/changelogs-in-pull-requests Pull Request resolved: facebook#49455 Test Plan: On the new architecture change force the layout direction and reload the bundle: ``` import React, { useCallback } from "react"; import { Button, I18nManager, StyleSheet, Text, View } from "react-native"; import RNRestart from "react-native-restart"; export default function Explore() { const onApplyRTL = useCallback(() => { if (!I18nManager.isRTL) { I18nManager.forceRTL(true); RNRestart.restart(); } }, []); const onApplyLTR = useCallback(() => { if (I18nManager.isRTL) { I18nManager.forceRTL(false); RNRestart.restart(); } }, []); return ( <View style={styles.area}> <Text>Test Block</Text> <View style={styles.testBlock}> <Text>Leading</Text> <Text>Trailing</Text> </View> <Button title={"Apply RTL"} onPress={onApplyRTL} /> <Button title={"Apply LTR"} onPress={onApplyLTR} /> </View> ); } const styles = StyleSheet.create({ area: { marginVertical: 50, paddingHorizontal: 24, }, testBlock: { paddingVertical: 10, flexDirection: "row", justifyContent: "space-between", }, }); ``` https://github.com/user-attachments/assets/0eab0d79-de3f-4eeb-abd0-439ba4fe25c0 Reviewed By: cortinico, cipolleschi Differential Revision: D69797645 Pulled By: NickGerleman fbshipit-source-id: 97499621f3dd735d466f5119e0f2a0eccf1c3c05
Summary: Fixes facebook#51193 [ANDROID][FIXED] Wrong borderBottomEndRadius on RTL Pull Request resolved: facebook#51229 Test Plan: Tested with Arabic (RTL) and English(LTR) English <img src="https://github.com/user-attachments/assets/5bd1eca9-194c-4d83-b75f-689bc13d827b" width=200> Arabic <img src="https://github.com/user-attachments/assets/459320a0-6bb2-4585-97bb-bd4ded6ec399" width=200> Reviewed By: cortinico Differential Revision: D74709219 Pulled By: NickGerleman fbshipit-source-id: 885bb84d97d73324983d044fd2874a457b40f646
…ough value prop is hardcoded to false (facebook#50049) Summary: Fixes facebook#50026 ## Changelog: [IOS] [FIXED] - [Fabric] iOS: Fixes Switch component incorrectly renders as toggled on even though value prop is hardcoded to false Pull Request resolved: facebook#50049 Test Plan: Repro please see facebook#50026. Reviewed By: javache Differential Revision: D71307864 Pulled By: cipolleschi fbshipit-source-id: 57238296842229cf2f23a3f44134f43e27b54609
…ok#49126) Summary: As pointed out by RyanCommits the ReactNativeFactory PR removed `enableFixForViewCommandRace` feature flag by mistake. Reference: https://github.com/facebook/react-native/pull/46298/files This PR re-adds the feature flag. ## Changelog: [IOS] [FIXED] - Re-enable enableFixForViewCommandRace feature flag Pull Request resolved: facebook#49126 Test Plan: Not needed, the feature flag was there before refactor. Reviewed By: huntie Differential Revision: D69049668 Pulled By: cipolleschi fbshipit-source-id: b7bf382c76878e72619145283fa8cc2c1046b486
Summary: Pull Request resolved: facebook#52378 This adds a Gradle property called `exclusiveEnterpriseRepository` that users can set in their `android/gradle.properties` as such: ```diff hermesEnabled=true +exclusiveEnterpriseRepository=https://my.internal.proxy.net/ ``` This will remove all the existing Maven repositories and only use the internal mirror they have. Changelog: [Android] [Added] - RNGP - Add support for `exclusiveEnterpriseRepository` to specify an internal Maven mirror. Reviewed By: mdvacca Differential Revision: D77667573 fbshipit-source-id: 835004d2ae7aa4e250b6f7a88a41918b573f5bd5
…ook#51078) Summary: Selectively disabling autolinking of a native dependency with components registered in the codegen configuration in react-native.config.js causes builds to crash upon launch on iOS. This is because the generated `RCTThirdPartyComponentsProvider.mm` file contains references to the excluded library using `NSClassFromString` causing the returned NSDictionary from `+[RCTThirdPartyComponentsProvider thirdPartyFabricComponents]` to be populated with nil values and therefore crashing the app. This has been confirmed in 0.78.2 and 0.79.2 but probably exists in 0.77.x as well. The issue has been further described in facebook#51077. [IOS][FIXED] - Skip codegen for selectively disabled libraries in react-native.config.js Pull Request resolved: facebook#51078 Test Plan: 1. Install a library that has the componentProvider field set in the codegen config (see reproducer) and install the iOS pods. 2. Build the app. 3. App should run successfully without any crashes. Reviewed By: cortinico Differential Revision: D74248371 Pulled By: cipolleschi fbshipit-source-id: 1ff7b477ed3d94ca45616ae243d3d2d30bd897db
Changelog: [Internal]
#publish-packages-to-npm&0.78-stable
Changelog: [Internal]
tido64
approved these changes
Aug 7, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary:
Merge up to upstream React Native 0.78.3. Make sure to update our peer dependency.