diff --git a/__mocks__/react-native.ts b/__mocks__/react-native.ts index 4e2e668e7e36..0d53bb3e38b4 100644 --- a/__mocks__/react-native.ts +++ b/__mocks__/react-native.ts @@ -87,17 +87,6 @@ jest.doMock('react-native', () => { dimensions = newDimensions; }, }, - - // `runAfterInteractions` method would normally be triggered after the native animation is completed, - // we would have to mock waiting for the animation end and more state changes, - // so it seems easier to just run the callback immediately in tests. - InteractionManager: { - ...ReactNative.InteractionManager, - runAfterInteractions: (callback: () => void) => { - callback(); - return {cancel: () => {}}; - }, - }, }, ReactNative, ) as ReactNativeMock; diff --git a/contributingGuides/INP_IMPROVEMENT_WORKFLOW.md b/contributingGuides/INP_IMPROVEMENT_WORKFLOW.md index 0a52c31d503a..e65bf2b9b772 100644 --- a/contributingGuides/INP_IMPROVEMENT_WORKFLOW.md +++ b/contributingGuides/INP_IMPROVEMENT_WORKFLOW.md @@ -158,7 +158,7 @@ The most common ways to improve a component's performance are: *Examples: [#89120](https://github.com/Expensify/App/pull/89120), [#86865](https://github.com/Expensify/App/pull/86865)* > [!WARNING] -> Do not reach for `InteractionManager.runAfterInteractions` as a deferral primitive. It is being removed from React Native and is in the process of being migrated out of the codebase. New usages should not be introduced. See [INTERACTION_MANAGER.md](https://github.com/Expensify/App/blob/main/contributingGuides/INTERACTION_MANAGER.md) for more details. +> Do not reach for `InteractionManager.runAfterInteractions` as a deferral primitive. It is deprecated in React Native and now ships as a no-op stub, and it has been migrated out of the codebase. New usages must not be introduced - use `TransitionTracker` or the `afterTransition` callbacks built on it. See [INTERACTION_MANAGER.md](https://github.com/Expensify/App/blob/main/contributingGuides/INTERACTION_MANAGER.md) for more details. 2. Defer non-critical work past the next paint. diff --git a/contributingGuides/INTERACTION_MANAGER.md b/contributingGuides/INTERACTION_MANAGER.md index 5d152fc04532..2d5b10352e84 100644 --- a/contributingGuides/INTERACTION_MANAGER.md +++ b/contributingGuides/INTERACTION_MANAGER.md @@ -2,13 +2,17 @@ ## Why -`InteractionManager` is being removed from React Native. We currently maintain a patch to keep it working, but that's a temporary measure and upstream libraries will also drop support over time. +`InteractionManager` is being removed from React Native. It is already deprecated, and as of RN 0.86 the shipped implementation is a no-op stub: `runAfterInteractions` falls through to `setImmediate`, `createInteractionHandle` returns `-1`, and `clearInteractionHandle` does nothing. Nothing can block the queue anymore. -Rather than keep patching, we're replacing `InteractionManager.runAfterInteractions` with purpose-built alternatives that are more precise. +We used to carry patches that restored the real implementation (`react-native+…+restore-interaction-manager.patch`) and that opened interaction handles during screen transitions (`@react-navigation+native-stack+…+added-interaction-manager-integration.patch`). Both patches have been removed - the app no longer calls `InteractionManager` anywhere, so there was nothing left for them to serve. + +`InteractionManager.runAfterInteractions` has been replaced with purpose-built alternatives that are more precise. ## Current state -`runAfterInteractions` is used across the codebase for a wide range of reasons: waiting for navigation transitions, deferring work after modals close, managing input focus, delaying scroll operations, and many other cases that are hard to classify. +Application code no longer uses `runAfterInteractions`. + +Historically `runAfterInteractions` was used across the codebase for a wide range of reasons: waiting for navigation transitions, deferring work after modals close, managing input focus, delaying scroll operations, and many other cases that are hard to classify. ## The problem @@ -83,10 +87,10 @@ For reference, here's how the available timing primitives compare: ### `InteractionManager.runAfterInteractions` (legacy — do not use) -- React Native-specific. Fires after all **ongoing interactions** (animations, touches) complete -- Tracks interactions via `createInteractionHandle()` — anything that calls `handle.done()` unblocks the queue -- In practice, this means "run after the current navigation transition finishes" -- Problem: it's a global queue with no granularity — you can't say "after _this specific_ transition" +- React Native-specific. Deprecated upstream, the current RN implementation is a stub, so it no longer waits for anything - it is just `setImmediate` with extra steps +- Historically it fired after all **ongoing interactions** (animations, touches) completed, tracked via `createInteractionHandle()` - clearing the last handle unblocked the queue +- In practice that meant "run after the current navigation transition finishes" +- Problem: it was a global queue with no granularity — you couldn't say "after _this specific_ transition" ### Summary @@ -94,4 +98,4 @@ For reference, here's how the available timing primitives compare: | ---------------------- | ------------------------- | ------------------------- | --------------------- | | `rAF` | Next frame (~16ms) | None — just "next paint" | Web + RN | | `requestIdleCallback` | When idle (unpredictable) | None — "whenever free" | Web + RN (polyfilled) | -| `runAfterInteractions` | After animations finish | Global — all interactions | RN only | +| `runAfterInteractions` | Same as `setImmediate` (stubbed) | None - nothing blocks the queue | RN only | diff --git a/contributingGuides/NAVIGATION.md b/contributingGuides/NAVIGATION.md index df646603ae1e..db741e60d7f1 100644 --- a/contributingGuides/NAVIGATION.md +++ b/contributingGuides/NAVIGATION.md @@ -246,7 +246,7 @@ Navigation.dismissModalWithReport({ > Why do we need a separate method to open a report from a modal? > > 1. On a narrow screen, we do not want to perform two operations: closing the modal and opening the report. This would cause two actions to be displayed on the screen, which could be confusing for users. Instead of two operations, we perform a replace on the modal, thanks to which there is a smooth transition to the report with simultaneous closing of the modal. -> 2. On a wide screen, we need to be sure that the modal has been closed before we want to navigate to the report. For this purpose, `navigate` called after `dismissModal` is wrapped in `InteractionManager.runAfterInteractions`. +> 2. On a wide screen, we need to be sure that the modal has been closed before we want to navigate to the report. For this purpose, `navigate` is passed as the `afterTransition` callback to `dismissModal`, so it only runs once the dismiss transition has completed (tracked via `TransitionTracker`). ### Summary diff --git a/patches/react-native/details.md b/patches/react-native/details.md index 2dfc6e9d96df..e688927b7e57 100644 --- a/patches/react-native/details.md +++ b/patches/react-native/details.md @@ -146,22 +146,6 @@ - E/App issue: [#69005](https://github.com/Expensify/App/issues/69005) - PR introducing patch: [#69004](https://github.com/Expensify/App/pull/69004) -### [react-native+0.86.0+020+restore-interaction-manager.patch](react-native+0.86.0+020+restore-interaction-manager.patch) - -- Reason: - - ``` - This patch restores the old InteractionManager behavior. React Native 0.80 deprecated InteractionManager and modified - it to behave like `setImmediate`, more info here - https://github.com/facebook/react-native/blob/d9262c60f4c02d66417008970dc9c34b742aaa75/CHANGELOG.md?plain=1#L597 - - We need to restore the previous behavior to avoid introducing any bugs in the app. - Bug example - https://github.com/Expensify/App/pull/69535#issuecomment-3443059319 - ``` - -- Upstream PR/issue: There won't be any upstream changes. We need to get rid of InteractionManager -- E/App issue: https://github.com/Expensify/App/issues/71913 -- PR introducing patch: https://github.com/Expensify/App/pull/69535 - ### [react-native+0.86.0+021+perf-increase-initial-heap-size.patch](react-native+0.86.0+021+perf-increase-initial-heap-size.patch) - Reason: This patch increases the initial heap size of the Hermes runtime. This allows us to disable Hermes Young-Gen Garbage Collection (GC) in a separate patch, which improves initial TTI and app startup time. diff --git a/patches/react-native/react-native+0.86.0+020+restore-interaction-manager.patch b/patches/react-native/react-native+0.86.0+020+restore-interaction-manager.patch deleted file mode 100644 index 297b0e763785..000000000000 --- a/patches/react-native/react-native+0.86.0+020+restore-interaction-manager.patch +++ /dev/null @@ -1,473 +0,0 @@ -diff --git a/node_modules/react-native/Libraries/Interaction/InteractionManager.js b/node_modules/react-native/Libraries/Interaction/InteractionManager.js -index 55c4c27..446c99c 100644 ---- a/node_modules/react-native/Libraries/Interaction/InteractionManager.js -+++ b/node_modules/react-native/Libraries/Interaction/InteractionManager.js -@@ -10,9 +10,6 @@ - - import type {EventSubscription} from '../vendor/emitter/EventEmitter'; - --const toError = require('../../src/private/utilities/toError').default; --const invariant = require('invariant'); -- - export type SimpleTask = { - name: string, - run: () => void, -@@ -21,7 +18,6 @@ export type PromiseTask = { - name: string, - gen: () => Promise, - }; --export type Task = SimpleTask | PromiseTask | (() => void); - - export type Handle = number; - -@@ -33,6 +29,26 @@ function reject(error: Error): void { - }, 0); - } - -+import type {Task} from './TaskQueue'; -+ -+import EventEmitter from '../vendor/emitter/EventEmitter'; -+ -+const BatchedBridge = require('../BatchedBridge/BatchedBridge').default; -+const TaskQueue = require('./TaskQueue').default; -+const invariant = require('invariant'); -+ -+export type {Task, SimpleTask, PromiseTask} from './TaskQueue'; -+ -+export type Handle = number; -+ -+const _emitter = new EventEmitter<{ -+ interactionComplete: [], -+ interactionStart: [], -+}>(); -+ -+const DEBUG_DELAY: 0 = 0; -+const DEBUG: false = false; -+ - /** - * InteractionManager allows long-running work to be scheduled after any - * interactions/animations have completed. In particular, this allows JavaScript -@@ -84,106 +100,154 @@ function reject(error: Error): void { - * - * @deprecated - */ --const InteractionManagerStub = { -+const InteractionManagerImpl = { - Events: { - interactionStart: 'interactionStart', - interactionComplete: 'interactionComplete', - }, - - /** -- * Schedule a function to run after all interactions have completed. Returns a cancellable -- * "promise". -- * -- * @deprecated -- */ -+ * Schedule a function to run after all interactions have completed. Returns a cancellable -+ * "promise". -+ */ - runAfterInteractions(task: ?Task): { - then: ( - onFulfill?: ?(void) => ?(Promise | U), -- onReject?: ?(error: unknown) => ?(Promise | U), -+ onReject?: ?(error: mixed) => ?(Promise | U), - ) => Promise, - cancel: () => void, - ... - } { -- let immediateID: ?$FlowFixMe; -- const promise = new Promise(resolve => { -- immediateID = setImmediate(() => { -- if (typeof task === 'object' && task !== null) { -- if (typeof task.gen === 'function') { -- task.gen().then(resolve, reject); -- } else if (typeof task.run === 'function') { -- try { -- task.run(); -- resolve(); -- } catch (error: unknown) { -- reject(toError(error)); -- } -- } else { -- reject(new TypeError(`Task "${task.name}" missing gen or run.`)); -- } -- } else if (typeof task === 'function') { -- try { -- task(); -- resolve(); -- } catch (error: unknown) { -- reject(toError(error)); -- } -- } else { -- reject(new TypeError('Invalid task of type: ' + typeof task)); -- } -+ const tasks: Array = []; -+ const promise = new Promise((resolve: () => void) => { -+ _scheduleUpdate(); -+ if (task) { -+ tasks.push(task); -+ } -+ tasks.push({ -+ run: resolve, -+ name: 'resolve ' + ((task && task.name) || '?'), - }); -+ _taskQueue.enqueueTasks(tasks); - }); -- - return { - // $FlowFixMe[method-unbinding] added when improving typing for this parameters - then: promise.then.bind(promise), -- cancel() { -- clearImmediate(immediateID); -+ cancel: function () { -+ _taskQueue.cancelTasks(tasks); - }, - }; - }, - - /** -- * Notify manager that an interaction has started. -- * -- * @deprecated -- */ -+ * Notify manager that an interaction has started. -+ */ - createInteractionHandle(): Handle { -- return -1; -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && console.log('InteractionManager: create interaction handle'); -+ _scheduleUpdate(); -+ const handle = ++_inc; -+ _addInteractionSet.add(handle); -+ return handle; - }, - - /** -- * Notify manager that an interaction has completed. -- * -- * @deprecated -- */ -+ * Notify manager that an interaction has completed. -+ */ - clearInteractionHandle(handle: Handle) { -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && console.log('InteractionManager: clear interaction handle'); - invariant(!!handle, 'InteractionManager: Must provide a handle to clear.'); -+ _scheduleUpdate(); -+ _addInteractionSet.delete(handle); -+ _deleteInteractionSet.add(handle); - }, - -- /** -- * @deprecated -- */ -- addListener( -+ // $FlowFixMe[unclear-type] unclear type of _emitter -+ // $FlowFixMe[method-unbinding] added when improving typing for this parameters -+ addListener: _emitter.addListener.bind(_emitter) as ( - eventType: string, -- // $FlowFixMe[unclear-type] -- listener: (...args: any) => unknown, -- context: unknown, -- ): EventSubscription { -- return { -- remove() {}, -- }; -- }, -+ // $FlowFixMe[unclear-type] unclear type of arguments -+ listener: (...args: any) => mixed, -+ context: mixed, -+ ) => EventSubscription, - - /** -- * A positive number will use setTimeout to schedule any tasks after the -- * eventLoopRunningTime hits the deadline value, otherwise all tasks will be -- * executed in one setImmediate batch (default). -- * -- * @deprecated -- */ -+ * A positive number will use setTimeout to schedule any tasks after the -+ * eventLoopRunningTime hits the deadline value, otherwise all tasks will be -+ * executed in one setImmediate batch (default). -+ */ - setDeadline(deadline: number) { -- // Do nothing. -+ _deadline = deadline; - }, - }; - --export default InteractionManagerStub; -+const _interactionSet = new Set(); -+const _addInteractionSet = new Set(); -+const _deleteInteractionSet = new Set(); -+const _taskQueue = new TaskQueue({onMoreTasks: _scheduleUpdate}); -+let _nextUpdateHandle: $FlowFixMe | TimeoutID = 0; -+let _inc = 0; -+let _deadline = -1; -+ -+/** -+ * Schedule an asynchronous update to the interaction state. -+ */ -+function _scheduleUpdate() { -+ if (!_nextUpdateHandle) { -+ if (_deadline > 0) { -+ _nextUpdateHandle = setTimeout(_processUpdate, 0 + DEBUG_DELAY); -+ } else { -+ _nextUpdateHandle = setImmediate(_processUpdate); -+ } -+ } -+} -+ -+/** -+ * Notify listeners, process queue, etc -+ */ -+function _processUpdate() { -+ _nextUpdateHandle = 0; -+ -+ const interactionCount = _interactionSet.size; -+ _addInteractionSet.forEach(handle => _interactionSet.add(handle)); -+ _deleteInteractionSet.forEach(handle => _interactionSet.delete(handle)); -+ const nextInteractionCount = _interactionSet.size; -+ -+ if (interactionCount !== 0 && nextInteractionCount === 0) { -+ // transition from 1+ --> 0 interactions -+ /* $FlowFixMe[prop-missing] Natural Inference rollout. See -+ * https://fburl.com/workplace/6291gfvu */ -+ /* $FlowFixMe[invalid-computed-prop] Natural Inference rollout. See -+ * https://fburl.com/workplace/6291gfvu */ -+ _emitter.emit(InteractionManagerImpl.Events.interactionComplete); -+ } else if (interactionCount === 0 && nextInteractionCount !== 0) { -+ // transition from 0 --> 1+ interactions -+ /* $FlowFixMe[prop-missing] Natural Inference rollout. See -+ * https://fburl.com/workplace/6291gfvu */ -+ /* $FlowFixMe[invalid-computed-prop] Natural Inference rollout. See -+ * https://fburl.com/workplace/6291gfvu */ -+ _emitter.emit(InteractionManagerImpl.Events.interactionStart); -+ } -+ -+ // process the queue regardless of a transition -+ if (nextInteractionCount === 0) { -+ while (_taskQueue.hasTasksToProcess()) { -+ _taskQueue.processNext(); -+ if ( -+ _deadline > 0 && -+ BatchedBridge.getEventLoopRunningTime() >= _deadline -+ ) { -+ // Hit deadline before processing all tasks, so process more later. -+ _scheduleUpdate(); -+ break; -+ } -+ } -+ } -+ _addInteractionSet.clear(); -+ _deleteInteractionSet.clear(); -+} -+ -+export default InteractionManagerImpl; -diff --git a/node_modules/react-native/Libraries/Interaction/TaskQueue.js b/node_modules/react-native/Libraries/Interaction/TaskQueue.js -new file mode 100644 -index 0000000..70e6314 ---- /dev/null -+++ b/node_modules/react-native/Libraries/Interaction/TaskQueue.js -@@ -0,0 +1,198 @@ -+/** -+ * Copyright (c) Meta Platforms, Inc. and affiliates. -+ * -+ * This source code is licensed under the MIT license found in the -+ * LICENSE file in the root directory of this source tree. -+ * -+ * @flow strict -+ * @format -+ */ -+ -+'use strict'; -+ -+const invariant = require('invariant'); -+ -+export type SimpleTask = { -+ name: string, -+ run: () => void, -+}; -+export type PromiseTask = { -+ name: string, -+ gen: () => Promise, -+}; -+export type Task = SimpleTask | PromiseTask | (() => void); -+ -+const DEBUG: false = false; -+ -+/** -+ * TaskQueue - A system for queueing and executing a mix of simple callbacks and -+ * trees of dependent tasks based on Promises. No tasks are executed unless -+ * `processNext` is called. -+ * -+ * `enqueue` takes a Task object with either a simple `run` callback, or a -+ * `gen` function that returns a `Promise` and puts it in the queue. If a gen -+ * function is supplied, then the promise it returns will block execution of -+ * tasks already in the queue until it resolves. This can be used to make sure -+ * the first task is fully resolved (including asynchronous dependencies that -+ * also schedule more tasks via `enqueue`) before starting on the next task. -+ * The `onMoreTasks` constructor argument is used to inform the owner that an -+ * async task has resolved and that the queue should be processed again. -+ * -+ * Note: Tasks are only actually executed with explicit calls to `processNext`. -+ */ -+class TaskQueue { -+ /** -+ * TaskQueue instances are self contained and independent, so multiple tasks -+ * of varying semantics and priority can operate together. -+ * -+ * `onMoreTasks` is invoked when `PromiseTask`s resolve if there are more -+ * tasks to process. -+ */ -+ constructor({ onMoreTasks }: { onMoreTasks: () => void, ... }) { -+ this._onMoreTasks = onMoreTasks; -+ this._queueStack = [{ tasks: [], popable: false }]; -+ } -+ -+ /** -+ * Add a task to the queue. It is recommended to name your tasks for easier -+ * async debugging. Tasks will not be executed until `processNext` is called -+ * explicitly. -+ */ -+ enqueue(task: Task): void { -+ this._getCurrentQueue().push(task); -+ } -+ -+ enqueueTasks(tasks: Array): void { -+ tasks.forEach(task => this.enqueue(task)); -+ } -+ -+ cancelTasks(tasksToCancel: Array): void { -+ // search through all tasks and remove them. -+ this._queueStack = this._queueStack -+ .map(queue => ({ -+ ...queue, -+ tasks: queue.tasks.filter(task => tasksToCancel.indexOf(task) === -1), -+ })) -+ .filter((queue, idx) => queue.tasks.length > 0 || idx === 0); -+ } -+ -+ /** -+ * Check to see if `processNext` should be called. -+ * -+ * @returns {boolean} Returns true if there are tasks that are ready to be -+ * processed with `processNext`, or returns false if there are no more tasks -+ * to be processed right now, although there may be tasks in the queue that -+ * are blocked by earlier `PromiseTask`s that haven't resolved yet. -+ * `onMoreTasks` will be called after each `PromiseTask` resolves if there are -+ * tasks ready to run at that point. -+ */ -+ hasTasksToProcess(): boolean { -+ return this._getCurrentQueue().length > 0; -+ } -+ -+ /** -+ * Executes the next task in the queue. -+ */ -+ processNext(): void { -+ const queue = this._getCurrentQueue(); -+ if (queue.length) { -+ const task = queue.shift(); -+ try { -+ if (typeof task === 'object' && task.gen) { -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && console.log('TaskQueue: genPromise for task ' + task.name); -+ this._genPromise(task); -+ } else if (typeof task === 'object' && task.run) { -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && console.log('TaskQueue: run task ' + task.name); -+ task.run(); -+ } else { -+ invariant( -+ typeof task === 'function', -+ 'Expected Function, SimpleTask, or PromiseTask, but got:\n' + -+ JSON.stringify(task, null, 2), -+ ); -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && console.log('TaskQueue: run anonymous task'); -+ task(); -+ } -+ } catch (e) { -+ e.message = -+ // $FlowFixMe[incompatible-type] -+ // $FlowFixMe[incompatible-use] -+ 'TaskQueue: Error with task ' + (task.name || '') + ': ' + e.message; -+ throw e; -+ } -+ } -+ } -+ -+ _queueStack: Array<{ -+ tasks: Array, -+ popable: boolean, -+ ... -+ }>; -+ _onMoreTasks: () => void; -+ -+ _getCurrentQueue(): Array { -+ const stackIdx = this._queueStack.length - 1; -+ const queue = this._queueStack[stackIdx]; -+ if ( -+ queue.popable && -+ queue.tasks.length === 0 && -+ this._queueStack.length > 1 -+ ) { -+ this._queueStack.pop(); -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && -+ console.log('TaskQueue: popped queue: ', { -+ stackIdx, -+ queueStackSize: this._queueStack.length, -+ }); -+ return this._getCurrentQueue(); -+ } else { -+ return queue.tasks; -+ } -+ } -+ -+ _genPromise(task: PromiseTask) { -+ // Each async task pushes it's own queue onto the queue stack. This -+ // effectively defers execution of previously queued tasks until the promise -+ // resolves, at which point we allow the new queue to be popped, which -+ // happens once it is fully processed. -+ this._queueStack.push({ tasks: [], popable: false }); -+ const stackIdx = this._queueStack.length - 1; -+ const stackItem = this._queueStack[stackIdx]; -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && console.log('TaskQueue: push new queue: ', { stackIdx }); -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && console.log('TaskQueue: exec gen task ' + task.name); -+ task -+ .gen() -+ .then(() => { -+ /* $FlowFixMe[constant-condition] Error discovered during Constant -+ * Condition roll out. See https://fburl.com/workplace/1v97vimq. */ -+ DEBUG && -+ console.log('TaskQueue: onThen for gen task ' + task.name, { -+ stackIdx, -+ queueStackSize: this._queueStack.length, -+ }); -+ stackItem.popable = true; -+ this.hasTasksToProcess() && this._onMoreTasks(); -+ }) -+ .catch(ex => { -+ setTimeout(() => { -+ ex.message = `TaskQueue: Error resolving Promise in task ${task.name}: ${ex.message}`; -+ throw ex; -+ }, 0); -+ }); -+ } -+} -+ -+export default TaskQueue; -+ diff --git a/patches/react-navigation/@react-navigation+native-stack+7.14.5+001+added-interaction-manager-integration.patch b/patches/react-navigation/@react-navigation+native-stack+7.14.5+001+added-interaction-manager-integration.patch deleted file mode 100644 index 86e0ff9b3562..000000000000 --- a/patches/react-navigation/@react-navigation+native-stack+7.14.5+001+added-interaction-manager-integration.patch +++ /dev/null @@ -1,144 +0,0 @@ -diff --git a/node_modules/@react-navigation/native-stack/lib/module/views/NativeStackView.native.js b/node_modules/@react-navigation/native-stack/lib/module/views/NativeStackView.native.js -index b83806b..f537ec0 100644 ---- a/node_modules/@react-navigation/native-stack/lib/module/views/NativeStackView.native.js -+++ b/node_modules/@react-navigation/native-stack/lib/module/views/NativeStackView.native.js -@@ -3,7 +3,7 @@ - import { getDefaultHeaderHeight, getHeaderTitle, HeaderBackContext, HeaderHeightContext, HeaderShownContext, SafeAreaProviderCompat, useFrameSize } from '@react-navigation/elements'; - import { NavigationProvider, StackActions, usePreventRemoveContext, useTheme } from '@react-navigation/native'; - import * as React from 'react'; --import { Animated, Platform, StatusBar, StyleSheet, useAnimatedValue, View } from 'react-native'; -+import { Animated, InteractionManager, Platform, StatusBar, StyleSheet, useAnimatedValue, View } from 'react-native'; - import { useSafeAreaInsets } from 'react-native-safe-area-context'; - import { compatibilityFlags, ScreenStack, ScreenStackItem } from 'react-native-screens'; - import { debounce } from "../utils/debounce.js"; -@@ -137,6 +137,31 @@ const SceneView = ({ - const { - preventedRoutes - } = usePreventRemoveContext(); -+ const interactionHandleRef = React.useRef(undefined); -+ const finishInteraction = React.useCallback(() => { -+ if (interactionHandleRef.current !== undefined) { -+ InteractionManager.clearInteractionHandle(interactionHandleRef.current); -+ interactionHandleRef.current = undefined; -+ } -+ }, []); -+ // this memo acts as a synchronous `useEffect` -+ React.useMemo(() => { -+ if (focused && interactionHandleRef.current === undefined) { -+ interactionHandleRef.current = InteractionManager.createInteractionHandle(); -+ // actually transition is highly unlikely to be more than 500ms, but sometimes BottomTabNavigator -+ // can become unfocused and then focused again, and in this case `onAppear` will not be fired an -+ // we will get infinite interaction manager handler. To fix that we are making a running timeout -+ // action that will clear an interaction 100% -+ setTimeout(finishInteraction, 500); -+ } -+ }, [focused]); -+ // in case if screen is unmounted faster than transition finishes, then `onAppear` will not be fired -+ // so we clean up an interaction here -+ React.useEffect(() => finishInteraction, [finishInteraction]); -+ const onAppearCallback = React.useCallback(e => { -+ onAppear?.(e); -+ finishInteraction(); -+ }, [onAppear, finishInteraction]); - const [headerHeight, setHeaderHeight] = React.useState(defaultHeaderHeight); - - // eslint-disable-next-line react-hooks/exhaustive-deps -@@ -274,7 +299,7 @@ const SceneView = ({ - transitionDuration: animationDuration, - onWillAppear: onWillAppear, - onWillDisappear: onWillDisappear, -- onAppear: onAppear, -+ onAppear: onAppearCallback, - onDisappear: onDisappear, - onDismissed: onDismissed, - onGestureCancel: onGestureCancel, -diff --git a/node_modules/@react-navigation/native-stack/lib/module/views/NativeStackView.native.js.map b/node_modules/@react-navigation/native-stack/lib/module/views/NativeStackView.native.js.map -index a8c1b71..ac72390 100644 ---- a/node_modules/@react-navigation/native-stack/lib/module/views/NativeStackView.native.js.map -+++ b/node_modules/@react-navigation/native-stack/lib/module/views/NativeStackView.native.js.map -@@ -1 +1 @@ --{"version":3,"names":["getDefaultHeaderHeight","getHeaderTitle","HeaderBackContext","HeaderHeightContext","HeaderShownContext","SafeAreaProviderCompat","useFrameSize","NavigationProvider","StackActions","usePreventRemoveContext","useTheme","React","Animated","Platform","StatusBar","StyleSheet","useAnimatedValue","View","useSafeAreaInsets","compatibilityFlags","ScreenStack","ScreenStackItem","debounce","getModalRouteKeys","AnimatedHeaderHeightContext","useDismissedRouteError","useInvalidPreventRemoveError","useHeaderConfigProps","jsx","_jsx","jsxs","_jsxs","ANDROID_DEFAULT_HEADER_HEIGHT","isFabric","global","useNativeDriver","OS","SceneView","index","focused","shouldFreeze","descriptor","previousDescriptor","nextDescriptor","isPresentationModal","isPreloaded","onWillDisappear","onWillAppear","onAppear","onDisappear","onDismissed","onHeaderBackButtonClicked","onNativeDismissCancelled","onGestureCancel","onSheetDetentChanged","route","navigation","options","render","animation","animationMatchesGesture","presentation","fullScreenGestureEnabled","animationDuration","animationTypeForReplace","fullScreenGestureShadowEnabled","gestureEnabled","gestureDirection","gestureResponseDistance","header","headerBackButtonMenuEnabled","headerShown","headerBackground","headerTransparent","autoHideHomeIndicator","keyboardHandlingEnabled","navigationBarColor","navigationBarTranslucent","navigationBarHidden","orientation","sheetAllowedDetents","sheetLargestUndimmedDetentIndex","sheetGrabberVisible","sheetCornerRadius","sheetElevation","sheetExpandsWhenScrolledToEdge","sheetInitialDetentIndex","sheetShouldOverflowTopInset","sheetResizeAnimationEnabled","statusBarAnimation","statusBarHidden","statusBarStyle","statusBarTranslucent","statusBarBackgroundColor","unstable_sheetFooter","scrollEdgeEffects","freezeOnBlur","contentStyle","undefined","nextGestureDirection","gestureDirectionOverride","colors","insets","isModal","isIPhone","isPad","isTV","isParentHeaderShown","useContext","parentHeaderHeight","parentHeaderBack","isLandscape","frame","width","height","topInset","top","defaultHeaderHeight","select","android","default","preventedRoutes","headerHeight","setHeaderHeight","useState","setHeaderHeightDebounced","useCallback","hasCustomHeader","usesNewAndroidHeaderHeightImplementation","headerHeightCorrectionOffset","statusBarHeight","currentHeight","rawAnimatedHeaderHeight","animatedHeaderHeight","useMemo","add","headerTopInsetEnabled","canGoBack","backTitle","name","title","headerBack","href","isRemovePrevented","key","preventRemove","headerConfig","headerBackTitle","onHeaderHeightChange","event","nativeEvent","listener","e","doesHeaderAnimate","headerLargeTitleEnabled","headerSearchBarOptions","Math","round","children","screenId","activityState","style","absoluteFill","customAnimationOnSwipe","fullScreenSwipeEnabled","fullScreenSwipeShadowEnabled","homeIndicatorHidden","hideKeyboardOnSwipe","replaceAnimation","stackPresentation","stackAnimation","screenOrientation","sheetDefaultResizeAnimationEnabled","statusBarColor","swipeDirection","transitionDuration","nativeBackButtonDismissalEnabled","preventNativeDismiss","bottom","left","right","backgroundColor","background","Provider","value","styles","translucent","onLayout","layout","setValue","absolute","back","NativeStackView","state","descriptors","describe","setNextDismissedKey","modalRouteKeys","routes","preloadedDescriptors","preloadedRoutes","reduce","acc","container","concat","map","isFocused","isBelowFocused","previousKey","nextKey","includes","isModalOnIos","emit","type","data","closing","target","dispatch","pop","dismissCount","source","stable","isStable","create","flex","zIndex","position","start","end","elevation","overflow"],"sourceRoot":"../../../src","sources":["views/NativeStackView.native.tsx"],"mappings":";;AAAA,SACEA,sBAAsB,EACtBC,cAAc,EACdC,iBAAiB,EACjBC,mBAAmB,EACnBC,kBAAkB,EAClBC,sBAAsB,EACtBC,YAAY,QACP,4BAA4B;AACnC,SACEC,kBAAkB,EAGlBC,YAAY,EAEZC,uBAAuB,EACvBC,QAAQ,QACH,0BAA0B;AACjC,OAAO,KAAKC,KAAK,MAAM,OAAO;AAC9B,SACEC,QAAQ,EACRC,QAAQ,EACRC,SAAS,EACTC,UAAU,EACVC,gBAAgB,EAChBC,IAAI,QACC,cAAc;AACrB,SAASC,iBAAiB,QAAQ,gCAAgC;AAClE,SACEC,kBAAkB,EAElBC,WAAW,EACXC,eAAe,QACV,sBAAsB;AAO7B,SAASC,QAAQ,QAAQ,sBAAmB;AAC5C,SAASC,iBAAiB,QAAQ,gCAA6B;AAC/D,SAASC,2BAA2B,QAAQ,qCAAkC;AAC9E,SAASC,sBAAsB,QAAQ,oCAAiC;AACxE,SAASC,4BAA4B,QAAQ,0CAAuC;AACpF,SAASC,oBAAoB,QAAQ,2BAAwB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAE9D,MAAMC,6BAA6B,GAAG,EAAE;AAExC,SAASC,QAAQA,CAAA,EAAG;EAClB,OAAO,uBAAuB,IAAIC,MAAM;AAC1C;AAsBA,MAAMC,eAAe,GAAGtB,QAAQ,CAACuB,EAAE,KAAK,KAAK;AAE7C,MAAMC,SAAS,GAAGA,CAAC;EACjBC,KAAK;EACLC,OAAO;EACPC,YAAY;EACZC,UAAU;EACVC,kBAAkB;EAClBC,cAAc;EACdC,mBAAmB;EACnBC,WAAW;EACXC,eAAe;EACfC,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E+G,KAAK,CAACC,WAAW,CAAChH,KAAK;gBAC9BuL,MAAM,EAAExE,KAAK,CAACC,WAAW,CAACwE;cAC5B;YACF,CAAC,CAAC;UACJ;QAAE,GA3EGvK,KAAK,CAACyF,GA4EZ,CAAC;MAEN,CAAC;IAAC,CACS;EAAC,CACQ,CAAC;AAE7B;AAEA,MAAMyC,MAAM,GAAG1K,UAAU,CAACgN,MAAM,CAAC;EAC/BpB,SAAS,EAAE;IACTqB,IAAI,EAAE;EACR,CAAC;EACD3J,MAAM,EAAE;IACN4J,MAAM,EAAE;EACV,CAAC;EACDnC,QAAQ,EAAE;IACRoC,QAAQ,EAAE,UAAU;IACpB9G,GAAG,EAAE,CAAC;IACN+G,KAAK,EAAE,CAAC;IACRC,GAAG,EAAE;EACP,CAAC;EACD1C,WAAW,EAAE;IACXwC,QAAQ,EAAE,UAAU;IACpB9G,GAAG,EAAE,CAAC;IACN+G,KAAK,EAAE,CAAC;IACRC,GAAG,EAAE,CAAC;IACNH,MAAM,EAAE,CAAC;IACTI,SAAS,EAAE;EACb,CAAC;EACD/C,UAAU,EAAE;IACVgD,QAAQ,EAAE;EACZ;AACF,CAAC,CAAC","ignoreList":[]} -\ No newline at end of file -+{"version":3,"sources":["../../../src/views/NativeStackView.native.tsx"],"names":["getDefaultHeaderHeight","getHeaderTitle","HeaderBackContext","HeaderHeightContext","HeaderShownContext","SafeAreaProviderCompat","useFrameSize","NavigationProvider","StackActions","usePreventRemoveContext","useTheme","React","Animated","Platform","StatusBar","StyleSheet","useAnimatedValue","View","useSafeAreaInsets","compatibilityFlags","ScreenStack","ScreenStackItem","debounce","getModalRouteKeys","AnimatedHeaderHeightContext","useDismissedRouteError","useInvalidPreventRemoveError","useHeaderConfigProps","jsx","_jsx","jsxs","_jsxs","ANDROID_DEFAULT_HEADER_HEIGHT","isFabric","global","useNativeDriver","OS","SceneView","index","focused","shouldFreeze","descriptor","previousDescriptor","nextDescriptor","isPresentationModal","isPreloaded","onWillDisappear","onWillAppear","onAppear","onDisappear","onDismissed","onHeaderBackButtonClicked","onNativeDismissCancelled","onGestureCancel","onSheetDetentChanged","route","navigation","options","render","animation","animationMatchesGesture","presentation","fullScreenGestureEnabled","animationDuration","animationTypeForReplace","fullScreenGestureShadowEnabled","gestureEnabled","gestureDirection","gestureResponseDistance","header","headerBackButtonMenuEnabled","headerShown","headerBackground","headerTransparent","autoHideHomeIndicator","keyboardHandlingEnabled","navigationBarColor","navigationBarTranslucent","navigationBarHidden","orientation","sheetAllowedDetents","sheetLargestUndimmedDetentIndex","sheetGrabberVisible","sheetCornerRadius","sheetElevation","sheetExpandsWhenScrolledToEdge","sheetInitialDetentIndex","sheetShouldOverflowTopInset","sheetResizeAnimationEnabled","statusBarAnimation","statusBarHidden","statusBarStyle","statusBarTranslucent","statusBarBackgroundColor","unstable_sheetFooter","scrollEdgeEffects","freezeOnBlur","contentStyle","undefined","nextGestureDirection","gestureDirectionOverride","colors","insets","isModal","isIPhone","isPad","isTV","isParentHeaderShown","useContext","parentHeaderHeight","parentHeaderBack","isLandscape","frame","width","height","topInset","top","defaultHeaderHeight","select","android","default","preventedRoutes","headerHeight","setHeaderHeight","useState","setHeaderHeightDebounced","useCallback","hasCustomHeader","usesNewAndroidHeaderHeightImplementation","headerHeightCorrectionOffset","statusBarHeight","currentHeight","rawAnimatedHeaderHeight","animatedHeaderHeight","useMemo","add","headerTopInsetEnabled","canGoBack","backTitle","name","title","headerBack","href","isRemovePrevented","key","preventRemove","headerConfig","headerBackTitle","onHeaderHeightChange","event","nativeEvent","listener","e","doesHeaderAnimate","headerLargeTitleEnabled","headerSearchBarOptions","Math","round","children","screenId","activityState","style","absoluteFill","customAnimationOnSwipe","fullScreenSwipeEnabled","fullScreenSwipeShadowEnabled","homeIndicatorHidden","hideKeyboardOnSwipe","replaceAnimation","stackPresentation","stackAnimation","screenOrientation","sheetDefaultResizeAnimationEnabled","statusBarColor","swipeDirection","transitionDuration","nativeBackButtonDismissalEnabled","preventNativeDismiss","bottom","left","right","backgroundColor","background","Provider","value","styles","translucent","onLayout","layout","setValue","absolute","back","NativeStackView","state","descriptors","describe","setNextDismissedKey","modalRouteKeys","routes","preloadedDescriptors","preloadedRoutes","reduce","acc","container","concat","map","isFocused","isBelowFocused","previousKey","nextKey","includes","isModalOnIos","emit","type","data","closing","target","dispatch","pop","dismissCount","source","stable","isStable","create","flex","zIndex","position","start","end","elevation","overflow"],"mappings":";;AAAA,SACEA,sBAAsB,EACtBC,cAAc,EACdC,iBAAiB,EACjBC,mBAAmB,EACnBC,kBAAkB,EAClBC,sBAAsB,EACtBC,YAAY,QACP,4BAA4B;AACnC,SACEC,kBAAkB,EAGlBC,YAAY,EAEZC,uBAAuB,EACvBC,QAAQ,QACH,0BAA0B;AACjC,OAAO,KAAKC,KAAK,MAAM,OAAO;AAC9B,SACEC,QAAQ,EACRC,QAAQ,EACRC,SAAS,EACTC,UAAU,EACVC,gBAAgB,EAChBC,IAAI,QACC,cAAc;AACrB,SAASC,iBAAiB,QAAQ,gCAAgC;AAClE,SACEC,kBAAkB,EAElBC,WAAW,EACXC,eAAe,QACV,sBAAsB;AAO7B,SAASC,QAAQ,QAAQ,sBAAmB;AAC5C,SAASC,iBAAiB,QAAQ,gCAA6B;AAC/D,SAASC,2BAA2B,QAAQ,qCAAkC;AAC9E,SAASC,sBAAsB,QAAQ,oCAAiC;AACxE,SAASC,4BAA4B,QAAQ,0CAAuC;AACpF,SAASC,oBAAoB,QAAQ,2BAAwB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAE9D,MAAMC,6BAA6B,GAAG,EAAE;AAExC,SAASC,QAAQA,CAAA,EAAG;EAClB,OAAO,uBAAuB,IAAIC,MAAM;AAC1C;AAsBA,MAAMC,eAAe,GAAGtB,QAAQ,CAACuB,EAAE,KAAK,KAAK;AAE7C,MAAMC,SAAS,GAAGA,CAAC;EACjBC,KAAK;EACLC,OAAO;EACPC,YAAY;EACZC,UAAU;EACVC,kBAAk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AEjK,KAAK,CAACyF,GAAG;cACjBsE,IAAI,EAAE;gBACJhL,KAAK,EAAE+G,KAAK,CAACC,WAAW,CAAChH,KAAK;gBAC9BuL,MAAM,EAAExE,KAAK,CAACC,WAAW,CAACwE;cAC5B;YACF,CAAC,CAAC;UACJ;QAAE,GA3EGvK,KAAK,CAACyF,GA4EZ,CAAC;MAEN,CAAC;IAAC,CACS;EAAC,CACQ,CAAC;AAE7B;AAEA,MAAMyC,MAAM,GAAG1K,UAAU,CAACgN,MAAM,CAAC;EAC/BpB,SAAS,EAAE;IACTqB,IAAI,EAAE;EACR,CAAC;EACD3J,MAAM,EAAE;IACN4J,MAAM,EAAE;EACV,CAAC;EACDnC,QAAQ,EAAE;IACRoC,QAAQ,EAAE,UAAU;IACpB9G,GAAG,EAAE,CAAC;IACN+G,KAAK,EAAE,CAAC;IACRC,GAAG,EAAE;EACP,CAAC;EACD1C,WAAW,EAAE;IACXwC,QAAQ,EAAE,UAAU;IACpB9G,GAAG,EAAE,CAAC;IACN+G,KAAK,EAAE,CAAC;IACRC,GAAG,EAAE,CAAC;IACNH,MAAM,EAAE,CAAC;IACTI,SAAS,EAAE;EACb,CAAC;EACD/C,UAAU,EAAE;IACVgD,QAAQ,EAAE;EACZ;AACF,CAAC,CAAC","sourceRoot":"../../../src"} -\ No newline at end of file -diff --git a/node_modules/@react-navigation/native-stack/lib/typescript/src/views/NativeStackView.native.d.ts.map b/node_modules/@react-navigation/native-stack/lib/typescript/src/views/NativeStackView.native.d.ts.map -index df09fc6..b351ddc 100644 ---- a/node_modules/@react-navigation/native-stack/lib/typescript/src/views/NativeStackView.native.d.ts.map -+++ b/node_modules/@react-navigation/native-stack/lib/typescript/src/views/NativeStackView.native.d.ts.map -@@ -1 +1 @@ --{"version":3,"file":"NativeStackView.native.d.ts","sourceRoot":"","sources":["../../../../src/views/NativeStackView.native.tsx"],"names":[],"mappings":"AASA,OAAO,EAEL,KAAK,aAAa,EAClB,KAAK,SAAS,EAEd,KAAK,oBAAoB,EAG1B,MAAM,0BAA0B,CAAC;AAkBlC,OAAO,KAAK,EACV,qBAAqB,EACrB,wBAAwB,EACxB,4BAA4B,EAC7B,MAAM,UAAU,CAAC;AAkclB,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,oBAAoB,CAAC,aAAa,CAAC,CAAC;IAC3C,UAAU,EAAE,4BAA4B,CAAC;IACzC,WAAW,EAAE,wBAAwB,CAAC;IACtC,QAAQ,EAAE,CACR,KAAK,EAAE,SAAS,CAAC,aAAa,CAAC,EAC/B,WAAW,EAAE,OAAO,KACjB,qBAAqB,CAAC;CAC5B,CAAC;AAEF,wBAAgB,eAAe,CAAC,EAC9B,KAAK,EACL,UAAU,EACV,WAAW,EACX,QAAQ,GACT,EAAE,KAAK,2CA6HP"} -\ No newline at end of file -+{"version":3,"sources":["../../../../src/views/NativeStackView.native.tsx"],"names":[],"mappings":"AASA,OAAO,EAEL,KAAK,aAAa,EAClB,KAAK,SAAS,EAEd,KAAK,oBAAoB,EAG1B,MAAM,0BAA0B,CAAC;AAkBlC,OAAO,KAAK,EACV,qBAAqB,EACrB,wBAAwB,EACxB,4BAA4B,EAC7B,MAAM,UAAU,CAAC;AAqelB,KAAK,KAAK,GAAG;IACX,KAAK,EAAE,oBAAoB,CAAC,aAAa,CAAC,CAAC;IAC3C,UAAU,EAAE,4BAA4B,CAAC;IACzC,WAAW,EAAE,wBAAwB,CAAC;IACtC,QAAQ,EAAE,CACR,KAAK,EAAE,SAAS,CAAC,aAAa,CAAC,EAC/B,WAAW,EAAE,OAAO,KACjB,qBAAqB,CAAC;CAC5B,CAAC;AAEF,wBAAgB,eAAe,CAAC,EAC9B,KAAK,EACL,UAAU,EACV,WAAW,EACX,QAAQ,GACT,EAAE,KAAK,2CA6HP","file":"NativeStackView.native.d.ts","sourceRoot":""} -\ No newline at end of file -diff --git a/node_modules/@react-navigation/native-stack/src/views/NativeStackView.native.tsx b/node_modules/@react-navigation/native-stack/src/views/NativeStackView.native.tsx -index 06aa31e..2ae4654 100644 ---- a/node_modules/@react-navigation/native-stack/src/views/NativeStackView.native.tsx -+++ b/node_modules/@react-navigation/native-stack/src/views/NativeStackView.native.tsx -@@ -19,6 +19,7 @@ import { - import * as React from 'react'; - import { - Animated, -+ InteractionManager, - Platform, - StatusBar, - StyleSheet, -@@ -62,7 +63,7 @@ type SceneViewProps = { - isPreloaded?: boolean; - onWillDisappear: () => void; - onWillAppear: () => void; -- onAppear: () => void; -+ onAppear: ScreenProps['onAppear']; - onDisappear: () => void; - onDismissed: ScreenProps['onDismissed']; - onHeaderBackButtonClicked: ScreenProps['onHeaderBackButtonClicked']; -@@ -207,6 +208,41 @@ const SceneView = ({ - - const { preventedRoutes } = usePreventRemoveContext(); - -+ const interactionHandleRef = React.useRef(undefined); -+ -+ const finishInteraction = React.useCallback(() => { -+ if (interactionHandleRef.current !== undefined) { -+ InteractionManager.clearInteractionHandle(interactionHandleRef.current); -+ interactionHandleRef.current = undefined; -+ } -+ }, []); -+ // this memo acts as a synchronous `useEffect` -+ React.useMemo(() => { -+ if (focused && interactionHandleRef.current === undefined) { -+ interactionHandleRef.current = -+ InteractionManager.createInteractionHandle(); -+ // actually transition is highly unlikely to be more than 500ms, but sometimes BottomTabNavigator -+ // can become unfocused and then focused again, and in this case `onAppear` will not be fired an -+ // we will get infinite interaction manager handler. To fix that we are making a running timeout -+ // action that will clear an interaction 100% -+ setTimeout(finishInteraction, 500); -+ } -+ }, [focused]); -+ // in case if screen is unmounted faster than transition finishes, then `onAppear` will not be fired -+ // so we clean up an interaction here -+ React.useEffect(() => finishInteraction, [finishInteraction]); -+ -+ const onAppearCallback = React.useCallback< -+ NonNullable -+ >( -+ (e) => { -+ onAppear?.(e); -+ -+ finishInteraction(); -+ }, -+ [onAppear, finishInteraction] -+ ); -+ - const [headerHeight, setHeaderHeight] = React.useState(defaultHeaderHeight); - - // eslint-disable-next-line react-hooks/exhaustive-deps -@@ -400,7 +436,7 @@ const SceneView = ({ - transitionDuration={animationDuration} - onWillAppear={onWillAppear} - onWillDisappear={onWillDisappear} -- onAppear={onAppear} -+ onAppear={onAppearCallback} - onDisappear={onDisappear} - onDismissed={onDismissed} - onGestureCancel={onGestureCancel} diff --git a/patches/react-navigation/details.md b/patches/react-navigation/details.md index 910c00da78d3..8ec7e6bdf161 100644 --- a/patches/react-navigation/details.md +++ b/patches/react-navigation/details.md @@ -33,14 +33,6 @@ - PR Introducing Patch: [#93268](https://github.com/Expensify/App/pull/93268) - PR Updating Patch: N/A -### [@react-navigation+native-stack+7.14.5+001+added-interaction-manager-integration.patch](@react-navigation+native-stack+7.14.5+001+added-interaction-manager-integration.patch) - -- Reason: Adds `InteractionManager` implementation to `@react-navigation/native-stack` -- Upstream PR/issue: https://github.com/react-navigation/react-navigation/pull/11887 (closed/declined upstream; we re-implement it). Still required on v7 — `runAfterInteractions` is used across the app and relies on this. Removing it is gated on migrating those consumers to `navigation.addListener('transitionEnd', ...)`, tracked in [#71913](https://github.com/Expensify/App/issues/71913). That migration works on v7 today and is not a v8-only task — v8 just forces it, since RN deprecated `InteractionManager` in 0.82+. -- E/App issue: [#29948](https://github.com/Expensify/App/issues/29948) -- PR Introducing Patch: [#37891](https://github.com/Expensify/App/pull/37891) -- PR Updating Patch: [#64155](https://github.com/Expensify/App/pull/64155) - ### [@react-navigation+native+7.1.33+001+initial.patch](@react-navigation+native+7.1.33+001+initial.patch) - Reason: Allows us to use some more advanced navigation actions without messing up the browser history diff --git a/src/components/Modal/ReanimatedModal/index.tsx b/src/components/Modal/ReanimatedModal/index.tsx index e83763266120..a50b8f35ce7a 100644 --- a/src/components/Modal/ReanimatedModal/index.tsx +++ b/src/components/Modal/ReanimatedModal/index.tsx @@ -17,8 +17,7 @@ import type {NativeEventSubscription, ViewStyle} from 'react-native'; import noop from 'lodash/noop'; import React, {useCallback, useEffect, useMemo, useRef, useState} from 'react'; -// eslint-disable-next-line no-restricted-imports -import {BackHandler, InteractionManager, Modal, StyleSheet, View} from 'react-native'; +import {BackHandler, Modal, StyleSheet, View} from 'react-native'; import {LayoutAnimationConfig} from 'react-native-reanimated'; import type ReanimatedModalProps from './types'; @@ -67,7 +66,6 @@ function ReanimatedModal({ const {windowWidth, windowHeight} = useWindowDimensions(); const backHandlerListener = useRef(null); - const handleRef = useRef(undefined); const transitionHandleRef = useRef(null); const styles = useThemeStyles(); @@ -111,10 +109,6 @@ function ReanimatedModal({ useEffect( () => () => { - if (handleRef.current) { - // eslint-disable-next-line @typescript-eslint/no-deprecated - InteractionManager.clearInteractionHandle(handleRef.current); - } if (transitionHandleRef.current) { TransitionTracker.endTransition(transitionHandleRef.current); transitionHandleRef.current = null; @@ -129,8 +123,6 @@ function ReanimatedModal({ useEffect(() => { if (isVisible && !isContainerOpen && !isTransitioning) { - // eslint-disable-next-line @typescript-eslint/no-deprecated - handleRef.current = InteractionManager.createInteractionHandle(); transitionHandleRef.current = TransitionTracker.startTransition(); onModalWillShow(); @@ -138,7 +130,6 @@ function ReanimatedModal({ setIsVisibleState(true); setIsTransitioning(true); } else if (!isVisible && isContainerOpen && !isTransitioning) { - handleRef.current = InteractionManager.createInteractionHandle(); transitionHandleRef.current = TransitionTracker.startTransition(); onModalWillHide(); @@ -156,10 +147,6 @@ function ReanimatedModal({ const onOpenCallBack = useCallback(() => { setIsTransitioning(false); setIsContainerOpen(true); - if (handleRef.current) { - // eslint-disable-next-line @typescript-eslint/no-deprecated - InteractionManager.clearInteractionHandle(handleRef.current); - } if (transitionHandleRef.current) { TransitionTracker.endTransition(transitionHandleRef.current); transitionHandleRef.current = null; @@ -170,9 +157,6 @@ function ReanimatedModal({ const onCloseCallBack = useCallback(() => { setIsTransitioning(false); setIsContainerOpen(false); - if (handleRef.current) { - InteractionManager.clearInteractionHandle(handleRef.current); - } if (transitionHandleRef.current) { TransitionTracker.endTransition(transitionHandleRef.current); transitionHandleRef.current = null; diff --git a/src/components/TransactionItemRow/EditableCell/usePopoverEditState.ts b/src/components/TransactionItemRow/EditableCell/usePopoverEditState.ts index 4be1e571a4b3..5b267dcf3bce 100644 --- a/src/components/TransactionItemRow/EditableCell/usePopoverEditState.ts +++ b/src/components/TransactionItemRow/EditableCell/usePopoverEditState.ts @@ -130,7 +130,7 @@ type UsePopoverEditStateOptionsGeneric = { * - measureInWindow-based position calculation * - Overflow detection (inverts when too close to bottom) * - Adaptive height calculation (shrinks popover when space is limited) - * - Auto-open after layout via InteractionManager + * - Auto-open after layout via requestAnimationFrame * - isEditing + isPopoverVisible toggling * - Auto-cancel when canEdit becomes false * - Value comparison to prevent no-op saves diff --git a/tests/unit/PusherSubscribeTest.ts b/tests/unit/PusherSubscribeTest.ts index 83ea59a4f484..f727545989bd 100644 --- a/tests/unit/PusherSubscribeTest.ts +++ b/tests/unit/PusherSubscribeTest.ts @@ -12,7 +12,7 @@ import {Pusher as MockedPusher} from '../../__mocks__/@pusher/pusher-websocket-r * * This covers the race condition where: * 1. Pusher.init() is called and connects - * 2. Pusher.subscribe() is called, which defers work via InteractionManager + * 2. Pusher.subscribe() is called, which defers work via TransitionTracker.runAfterTransitions * 3. Pusher.disconnect() is called (e.g. during "Upgrade Required" teardown) * 4. The deferred callback finally runs and finds socket === null * @@ -61,14 +61,14 @@ describe('Pusher.subscribe', () => { await initPusher(); // 2. Start subscribe — captures the already-resolved initPromise - // InteractionManager.runAfterInteractions callback is queued but hasn't fired yet + // TransitionTracker.runAfterTransitions callback is queued but hasn't fired yet const subscribePromise = Pusher.subscribe('private-user-123', 'multipleEvents'); - // 3. Disconnect BEFORE the InteractionManager callback runs (sets socket = null) + // 3. Disconnect BEFORE the TransitionTracker callback runs (sets socket = null) // This simulates the race condition during "Upgrade Required" teardown Pusher.disconnect(); - // 4. Flush timers and microtasks so the InteractionManager callback fires + // 4. Flush timers and microtasks so the TransitionTracker callback fires await jest.runAllTimersAsync(); // 5. Subscribe should NOT throw — it should resolve gracefully @@ -116,7 +116,7 @@ describe('Pusher.subscribe', () => { const subscribePromise = Pusher.subscribe('private-user-789', 'multipleEvents'); - // Flush so InteractionManager callback fires and subscription completes + // Flush so the TransitionTracker callback fires and subscription completes await jest.runAllTimersAsync(); await expect(subscribePromise).resolves.toBeUndefined(); @@ -229,7 +229,7 @@ describe('Per-callback subscription handles', () => { // Unsubscribe immediately (sets disposed = true) handle.unsubscribe(); - // Now flush — the InteractionManager callback should see disposed=true and skip binding + // Now flush — the TransitionTracker callback should see disposed=true and skip binding await jest.runAllTimersAsync(); await expect(handle).resolves.toBeUndefined(); @@ -316,7 +316,7 @@ describe('Per-callback subscription handles', () => { const callback = jest.fn(); const handle = Pusher.subscribe(CHANNEL, EVENT, callback); - // Flush InteractionManager — socket.subscribe() fires, but onSubscriptionSucceeded is deferred + // Flush TransitionTracker — socket.subscribe() fires, but onSubscriptionSucceeded is deferred await jest.runAllTimersAsync(); expect(capturedOnSuccess).toBeDefined(); diff --git a/tests/unit/focusFirstInteractiveElementTest.ts b/tests/unit/focusFirstInteractiveElementTest.ts index afa3c5c934a3..30125ed9f69f 100644 --- a/tests/unit/focusFirstInteractiveElementTest.ts +++ b/tests/unit/focusFirstInteractiveElementTest.ts @@ -1,7 +1,7 @@ /** * Tests for focusFirstInteractiveElement — the pure DOM logic extracted * from useDialogContainerFocus (web). Tests run in jsdom without needing - * React hooks, InteractionManager, or requestAnimationFrame mocks. + * React hooks, TransitionTracker, or requestAnimationFrame mocks. */ // Import the web implementation directly (Jest resolves index.native.ts by default). diff --git a/tests/unit/hooks/useSearchBulkActionsDeleteTest.ts b/tests/unit/hooks/useSearchBulkActionsDeleteTest.ts index fb3fdb695147..56e46b9d2f88 100644 --- a/tests/unit/hooks/useSearchBulkActionsDeleteTest.ts +++ b/tests/unit/hooks/useSearchBulkActionsDeleteTest.ts @@ -172,16 +172,6 @@ jest.mock('@hooks/useDuplicateTransactionsAndViolations', () => ({ default: () => ({duplicateTransactions: {}, duplicateTransactionViolations: {}}), })); -// Make InteractionManager execute callbacks immediately so we don't need fake timers -jest.mock('react-native', () => ({ - InteractionManager: { - runAfterInteractions: (callback: () => void | Promise) => { - callback(); - return {cancel: jest.fn()}; - }, - }, -})); - // Make TransitionTracker execute callbacks immediately too (it can't wait for a real // modal/popover transition in a unit test, and waitForUpcomingTransition would otherwise // stall until MAX_TRANSITION_START_WAIT_MS). diff --git a/tests/unit/hooks/useSearchBulkActionsExportTest.ts b/tests/unit/hooks/useSearchBulkActionsExportTest.ts index 610aec26cff0..293ac73a570e 100644 --- a/tests/unit/hooks/useSearchBulkActionsExportTest.ts +++ b/tests/unit/hooks/useSearchBulkActionsExportTest.ts @@ -190,15 +190,6 @@ jest.mock('@hooks/useDuplicateTransactionsAndViolations', () => ({ default: () => ({duplicateTransactions: {}, duplicateTransactionViolations: {}}), })); -jest.mock('react-native', () => ({ - InteractionManager: { - runAfterInteractions: (callback: () => void | Promise) => { - callback(); - return {cancel: jest.fn()}; - }, - }, -})); - // --------------------------------------------------------------------------- // Mutable context state // ---------------------------------------------------------------------------