Make home communities look better on mobile. Add Covid & AI.

This commit is contained in:
James Grugett 2022-02-03 19:00:17 -06:00
parent 00f632ec47
commit ca89fd158d
2 changed files with 7 additions and 11 deletions

View File

@ -63,14 +63,15 @@ export function FoldTag(props: { fold: { slug: string; name: string } }) {
export function FoldTagList(props: {
folds: { slug: string; name: string }[]
noLabel?: boolean
className?: string
}) {
const { folds, className } = props
const { folds, noLabel, className } = props
return (
<Row className={clsx('flex-wrap gap-2 items-center', className)}>
{folds.length > 0 && (
<>
<div className="text-gray-500 mr-1">Communities</div>
{!noLabel && <div className="text-gray-500 mr-1">Communities</div>}
{folds.map((fold) => (
<FoldTag key={fold.slug} fold={fold} />
))}

View File

@ -112,15 +112,6 @@ const Home = (props: { contracts: Contract[]; folds: Fold[] }) => {
)
: []
console.log({
followedFoldIds,
followedFolds,
yourBetContracts,
feedContracts,
feedBets,
feedComments,
})
if (user === null) {
Router.replace('/')
return <></>
@ -132,13 +123,17 @@ const Home = (props: { contracts: Contract[]; folds: Fold[] }) => {
<Col className="max-w-3xl w-full">
<FeedCreate user={user ?? undefined} />
<Spacer h={6} />
<div className="text-lg text-gray-500 px-3 pb-4">Communities</div>
<FoldTagList
className="mx-2"
noLabel
folds={[
{ name: 'Politics', slug: 'politics' },
{ name: 'Crypto', slug: 'crypto' },
{ name: 'Sports', slug: 'sports' },
{ name: 'Science', slug: 'science' },
{ name: 'Covid', slug: 'covid' },
{ name: 'AI', slug: 'ai' },
{
name: 'Manifold Markets',
slug: 'manifold-markets',