Tweak rendering of top headers so they always appear even during load (#4982)

Co-authored-by: Eric Bailey <git@esb.lol>
This commit is contained in:
Hailey 2024-08-30 00:20:46 -07:00 committed by GitHub
parent 8651f31ebb
commit 8cddce5f30
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
12 changed files with 120 additions and 130 deletions

View file

@ -1,12 +1,16 @@
import React from 'react'
import {View} from 'react-native'
import {useFocusEffect} from '@react-navigation/native'
import {NativeStackScreenProps, CommonNavigatorParams} from 'lib/routes/types'
import {ViewHeader} from '../com/util/ViewHeader'
import {ProfileFollows as ProfileFollowsComponent} from '../com/profile/ProfileFollows'
import {useSetMinimalShellMode} from '#/state/shell'
import {useLingui} from '@lingui/react'
import {msg} from '@lingui/macro'
import {useLingui} from '@lingui/react'
import {useFocusEffect} from '@react-navigation/native'
import {useSetMinimalShellMode} from '#/state/shell'
import {CommonNavigatorParams, NativeStackScreenProps} from 'lib/routes/types'
import {isWeb} from 'platform/detection'
import {CenteredView} from 'view/com/util/Views'
import {atoms as a} from '#/alf'
import {ListHeaderDesktop} from '#/components/Lists'
import {ProfileFollows as ProfileFollowsComponent} from '../com/profile/ProfileFollows'
import {ViewHeader} from '../com/util/ViewHeader'
type Props = NativeStackScreenProps<CommonNavigatorParams, 'ProfileFollows'>
export const ProfileFollowsScreen = ({route}: Props) => {
@ -21,9 +25,10 @@ export const ProfileFollowsScreen = ({route}: Props) => {
)
return (
<View style={{flex: 1}}>
<ViewHeader title={_(msg`Following`)} />
<CenteredView style={a.h_full_vh} sideBorders={true}>
<ListHeaderDesktop title={_(msg`Following`)} />
<ViewHeader title={_(msg`Following`)} showBorder={!isWeb} />
<ProfileFollowsComponent name={name} />
</View>
</CenteredView>
)
}