diff options
author | Hailey <me@haileyok.com> | 2024-03-06 11:02:48 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-06 11:02:48 -0800 |
commit | b8f36a8bca0eab08e09e0a56be63ade40e710f34 (patch) | |
tree | 1f6451f840b46e792e63b6e4d8cb5dd356d5b4c2 /src/components/Lists.tsx | |
parent | 7a592d8140cbb907535b482cb43a369b0a7e4750 (diff) | |
download | voidsky-b8f36a8bca0eab08e09e0a56be63ade40e710f34.tar.zst |
Fix double border on web hashtag list (#3091)
* add `topBorder` to Views.tsx * fix double border
Diffstat (limited to 'src/components/Lists.tsx')
-rw-r--r-- | src/components/Lists.tsx | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/components/Lists.tsx b/src/components/Lists.tsx index 12a935807..58aa74b38 100644 --- a/src/components/Lists.tsx +++ b/src/components/Lists.tsx @@ -1,6 +1,7 @@ import React from 'react' import {atoms as a, useBreakpoints, useTheme} from '#/alf' import {View} from 'react-native' +import {CenteredView} from 'view/com/util/Views' import {Loader} from '#/components/Loader' import {Trans} from '@lingui/macro' import {cleanError} from 'lib/strings/errors' @@ -143,7 +144,7 @@ export function ListMaybePlaceholder({ }) { const navigation = useNavigation<NavigationProp>() const t = useTheme() - const {gtMobile} = useBreakpoints() + const {gtMobile, gtTablet} = useBreakpoints() const canGoBack = navigation.canGoBack() const onGoBack = React.useCallback(() => { @@ -165,14 +166,16 @@ export function ListMaybePlaceholder({ if (!isEmpty) return null return ( - <View + <CenteredView style={[ a.flex_1, a.align_center, - !gtMobile ? [a.justify_between, a.border_t] : a.gap_5xl, + !gtMobile ? a.justify_between : a.gap_5xl, t.atoms.border_contrast_low, {paddingTop: 175, paddingBottom: 110}, - ]}> + ]} + sideBorders={gtMobile} + topBorder={!gtTablet}> {isLoading ? ( <View style={[a.w_full, a.align_center, {top: 100}]}> <Loader size="xl" /> @@ -241,6 +244,6 @@ export function ListMaybePlaceholder({ </View> </> )} - </View> + </CenteredView> ) } |