1
0
mirror of https://github.com/tooot-app/app synced 2025-06-05 22:19:13 +02:00

Believe #638 can be closed now!

This commit is contained in:
xmflsct
2023-01-04 22:39:29 +01:00
parent 62a6594f91
commit 06324ee51a
34 changed files with 278 additions and 346 deletions

View File

@ -2,7 +2,8 @@ import { HeaderRight } from '@components/Header'
import Timeline from '@components/Timeline'
import TimelineDefault from '@components/Timeline/Default'
import SegmentedControl from '@react-native-community/segmented-control'
import { NativeStackScreenProps } from '@react-navigation/native-stack'
import { useNavigation } from '@react-navigation/native'
import { NativeStackNavigationProp, NativeStackScreenProps } from '@react-navigation/native-stack'
import { TabPublicStackParamList } from '@utils/navigation/navigators'
import { QueryKeyTimeline } from '@utils/queryHooks/timeline'
import { getGlobalStorage, setGlobalStorage } from '@utils/storage/actions'
@ -14,7 +15,12 @@ import { Dimensions } from 'react-native'
import { SceneMap, TabView } from 'react-native-tab-view'
const Route = ({ route: { key: page } }: { route: any }) => {
const navigation =
useNavigation<NativeStackNavigationProp<TabPublicStackParamList, 'Tab-Public-Root'>>()
const queryKey: QueryKeyTimeline = ['Timeline', { page }]
useEffect(() => {
navigation.setParams({ queryKey })
}, [])
return (
<Timeline
queryKey={queryKey}