adjust footer on web

This commit is contained in:
Hailey
2024-06-07 12:07:26 -07:00
parent 8a1b22d5d6
commit 3d6817a64c
+10 -7
View File
@@ -12,7 +12,7 @@ import {NativeStackScreenProps} from '@react-navigation/native-stack'
import {HITSLOP_10} from 'lib/constants' import {HITSLOP_10} from 'lib/constants'
import {CommonNavigatorParams, NavigationProp} from 'lib/routes/types' import {CommonNavigatorParams, NavigationProp} from 'lib/routes/types'
import {enforceLen} from 'lib/strings/helpers' import {enforceLen} from 'lib/strings/helpers'
import {isAndroid, isWeb} from 'platform/detection' import {isAndroid, isNative, isWeb} from 'platform/detection'
import {useProfileQuery} from 'state/queries/profile' import {useProfileQuery} from 'state/queries/profile'
import {useAgent, useSession} from 'state/session' import {useAgent, useSession} from 'state/session'
import {useSetMinimalShellMode} from 'state/shell' import {useSetMinimalShellMode} from 'state/shell'
@@ -315,21 +315,25 @@ function Footer({
<View <View
style={[ style={[
a.border_t, a.border_t,
a.border_l,
a.border_r,
a.align_center, a.align_center,
a.px_md, a.px_md,
a.pt_lg, a.pt_lg,
a.pb_5xl, a.pb_5xl,
a.gap_sm, a.gap_sm,
t.atoms.bg, t.atoms.bg,
t.atoms.shadow_md,
t.atoms.border_contrast_medium, t.atoms.border_contrast_medium,
{ {
height: 190, height: 190,
borderTopLeftRadius: 14,
borderTopRightRadius: 14,
}, },
isNative && [
a.border_l,
a.border_r,
t.atoms.shadow_md,
{
borderTopLeftRadius: 14,
borderTopRightRadius: 14,
},
],
]}> ]}>
<View style={[a.flex_row, a.gap_xs]}> <View style={[a.flex_row, a.gap_xs]}>
{items.slice(0, 5).map((p, index) => ( {items.slice(0, 5).map((p, index) => (
@@ -431,7 +435,6 @@ function Footer({
} }
function getName(item: AppBskyActorDefs.ProfileViewBasic | GeneratorView) { function getName(item: AppBskyActorDefs.ProfileViewBasic | GeneratorView) {
// TODO hack for now since these are not full profiles and wont validate
if (typeof item.displayName === 'string') { if (typeof item.displayName === 'string') {
return enforceLen(item.displayName, 16, true) return enforceLen(item.displayName, 16, true)
} else if (typeof item.handle === 'string') { } else if (typeof item.handle === 'string') {