Hide "Add Funds" and "Personalize your feed"

This commit is contained in:
Austin Chen 2022-03-01 17:19:20 -08:00
parent c1fd17aba1
commit 3633167d8a
2 changed files with 13 additions and 5 deletions

View File

@ -3,6 +3,7 @@ import { formatMoney } from '../../common/util/format'
import { Avatar } from './avatar' import { Avatar } from './avatar'
import { Col } from './layout/col' import { Col } from './layout/col'
import { MenuButton } from './menu' import { MenuButton } from './menu'
import { IS_PRIVATE_MANIFOLD } from '../lib/firebase/init'
export function ProfileMenu(props: { user: User | undefined }) { export function ProfileMenu(props: { user: User | undefined }) {
const { user } = props const { user } = props
@ -54,10 +55,15 @@ function getNavigationOptions(
name: 'Your trades', name: 'Your trades',
href: '/trades', href: '/trades',
}, },
// Disable "Add Funds" for teams
...(IS_PRIVATE_MANIFOLD
? []
: [
{ {
name: 'Add funds', name: 'Add funds',
href: '/add-funds', href: '/add-funds',
}, },
]),
{ {
name: 'Leaderboards', name: 'Leaderboards',
href: '/leaderboards', href: '/leaderboards',

View File

@ -26,6 +26,7 @@ import {
import { useGetRecentBets } from '../hooks/use-bets' import { useGetRecentBets } from '../hooks/use-bets'
import { usePropz } from '../hooks/use-propz' import { usePropz } from '../hooks/use-propz'
import { useActiveContracts } from '../hooks/use-contracts' import { useActiveContracts } from '../hooks/use-contracts'
import { IS_PRIVATE_MANIFOLD } from '../lib/firebase/init'
export async function getStaticPropz() { export async function getStaticPropz() {
const contractInfo = await getAllContractInfo() const contractInfo = await getAllContractInfo()
@ -82,7 +83,8 @@ const Home = (props: {
<Spacer h={6} /> <Spacer h={6} />
{initialFollowedFoldSlugs !== undefined && {initialFollowedFoldSlugs !== undefined &&
initialFollowedFoldSlugs.length === 0 && ( initialFollowedFoldSlugs.length === 0 &&
!IS_PRIVATE_MANIFOLD && (
<FastFoldFollowing <FastFoldFollowing
user={user} user={user}
followedFoldSlugs={initialFollowedFoldSlugs} followedFoldSlugs={initialFollowedFoldSlugs}