remove root sibling library (#9097)

This commit is contained in:
Samuel Newman
2025-09-29 22:31:55 +03:00
committed by GitHub
parent ae2c9a832f
commit 031fa95715
5 changed files with 118 additions and 134 deletions
+3 -7
View File
@@ -1,22 +1,18 @@
import React from 'react'
import {render} from '@testing-library/react-native'
import {GestureHandlerRootView} from 'react-native-gesture-handler' import {GestureHandlerRootView} from 'react-native-gesture-handler'
import {RootSiblingParent} from 'react-native-root-siblings'
import {SafeAreaProvider} from 'react-native-safe-area-context' import {SafeAreaProvider} from 'react-native-safe-area-context'
import {RootStoreProvider, RootStoreModel} from '../src/state' import {render} from '@testing-library/react-native'
import {ThemeProvider} from '../src/lib/ThemeContext' import {ThemeProvider} from '../src/lib/ThemeContext'
import {type RootStoreModel, RootStoreProvider} from '../src/state'
const customRender = (ui: any, rootStore: RootStoreModel) => const customRender = (ui: any, rootStore: RootStoreModel) =>
render( render(
// eslint-disable-next-line react-native/no-inline-styles
<GestureHandlerRootView style={{flex: 1}}> <GestureHandlerRootView style={{flex: 1}}>
<RootSiblingParent>
<RootStoreProvider value={rootStore}> <RootStoreProvider value={rootStore}>
<ThemeProvider theme="light"> <ThemeProvider theme="light">
<SafeAreaProvider>{ui}</SafeAreaProvider> <SafeAreaProvider>{ui}</SafeAreaProvider>
</ThemeProvider> </ThemeProvider>
</RootStoreProvider> </RootStoreProvider>
</RootSiblingParent>
</GestureHandlerRootView>, </GestureHandlerRootView>,
) )
-1
View File
@@ -197,7 +197,6 @@
"react-native-progress": "bluesky-social/react-native-progress", "react-native-progress": "bluesky-social/react-native-progress",
"react-native-qrcode-styled": "^0.3.3", "react-native-qrcode-styled": "^0.3.3",
"react-native-reanimated": "^3.19.1", "react-native-reanimated": "^3.19.1",
"react-native-root-siblings": "^5.0.1",
"react-native-safe-area-context": "~5.6.0", "react-native-safe-area-context": "~5.6.0",
"react-native-screens": "~4.16.0", "react-native-screens": "~4.16.0",
"react-native-svg": "15.12.1", "react-native-svg": "15.12.1",
-3
View File
@@ -4,7 +4,6 @@ import '#/view/icons'
import React, {useEffect, useState} from 'react' import React, {useEffect, useState} from 'react'
import {GestureHandlerRootView} from 'react-native-gesture-handler' import {GestureHandlerRootView} from 'react-native-gesture-handler'
import {RootSiblingParent} from 'react-native-root-siblings'
import { import {
initialWindowMetrics, initialWindowMetrics,
SafeAreaProvider, SafeAreaProvider,
@@ -137,7 +136,6 @@ function InnerApp() {
<ThemeProvider theme={theme}> <ThemeProvider theme={theme}>
<ContextMenuProvider> <ContextMenuProvider>
<Splash isReady={isReady && hasCheckedReferrer}> <Splash isReady={isReady && hasCheckedReferrer}>
<RootSiblingParent>
<VideoVolumeProvider> <VideoVolumeProvider>
<React.Fragment <React.Fragment
// Resets the entire tree below when it changes: // Resets the entire tree below when it changes:
@@ -194,7 +192,6 @@ function InnerApp() {
</QueryProvider> </QueryProvider>
</React.Fragment> </React.Fragment>
</VideoVolumeProvider> </VideoVolumeProvider>
</RootSiblingParent>
</Splash> </Splash>
</ContextMenuProvider> </ContextMenuProvider>
</ThemeProvider> </ThemeProvider>
-3
View File
@@ -3,7 +3,6 @@ import '#/view/icons'
import './style.css' import './style.css'
import React, {useEffect, useState} from 'react' import React, {useEffect, useState} from 'react'
import {RootSiblingParent} from 'react-native-root-siblings'
import {SafeAreaProvider} from 'react-native-safe-area-context' import {SafeAreaProvider} from 'react-native-safe-area-context'
import {msg} from '@lingui/macro' import {msg} from '@lingui/macro'
import {useLingui} from '@lingui/react' import {useLingui} from '@lingui/react'
@@ -111,7 +110,6 @@ function InnerApp() {
<Alf theme={theme}> <Alf theme={theme}>
<ThemeProvider theme={theme}> <ThemeProvider theme={theme}>
<ContextMenuProvider> <ContextMenuProvider>
<RootSiblingParent>
<VideoVolumeProvider> <VideoVolumeProvider>
<ActiveVideoProvider> <ActiveVideoProvider>
<React.Fragment <React.Fragment
@@ -166,7 +164,6 @@ function InnerApp() {
</React.Fragment> </React.Fragment>
</ActiveVideoProvider> </ActiveVideoProvider>
</VideoVolumeProvider> </VideoVolumeProvider>
</RootSiblingParent>
</ContextMenuProvider> </ContextMenuProvider>
</ThemeProvider> </ThemeProvider>
</Alf> </Alf>
-5
View File
@@ -17071,11 +17071,6 @@ react-native-reanimated@^3.19.1:
invariant "^2.2.4" invariant "^2.2.4"
react-native-is-edge-to-edge "1.1.7" react-native-is-edge-to-edge "1.1.7"
react-native-root-siblings@^5.0.1:
version "5.0.1"
resolved "https://registry.yarnpkg.com/react-native-root-siblings/-/react-native-root-siblings-5.0.1.tgz#97e050e5155228f65810fb1c466ff8e769c5272c"
integrity sha512-Ay3k/fBj6ReUkWX5WNS+oEAcgPLEGOK8n7K/L7D85mf3xvd8rm/b4spsv26E4HlFzluVx5HKbxEt9cl0wQ1u3g==
react-native-safe-area-context@~5.6.0: react-native-safe-area-context@~5.6.0:
version "5.6.1" version "5.6.1"
resolved "https://registry.yarnpkg.com/react-native-safe-area-context/-/react-native-safe-area-context-5.6.1.tgz#cb4d249ef1a6f7e8fd0cfdfa9764838dffda26b6" resolved "https://registry.yarnpkg.com/react-native-safe-area-context/-/react-native-safe-area-context-5.6.1.tgz#cb4d249ef1a6f7e8fd0cfdfa9764838dffda26b6"