Rearrange nav, add Rules link, singular leaderboard
This commit is contained in:
parent
a266de380f
commit
e4a2f8acbb
|
@ -7,6 +7,7 @@ import {
|
||||||
HeartIcon,
|
HeartIcon,
|
||||||
TrendingUpIcon,
|
TrendingUpIcon,
|
||||||
ChatIcon,
|
ChatIcon,
|
||||||
|
ExternalLinkIcon,
|
||||||
} from '@heroicons/react/outline'
|
} from '@heroicons/react/outline'
|
||||||
import clsx from 'clsx'
|
import clsx from 'clsx'
|
||||||
import Link from 'next/link'
|
import Link from 'next/link'
|
||||||
|
@ -40,7 +41,7 @@ function getNavigation() {
|
||||||
icon: NotificationsIcon,
|
icon: NotificationsIcon,
|
||||||
},
|
},
|
||||||
|
|
||||||
{ name: 'Leaderboards', href: '/leaderboards', icon: TrendingUpIcon },
|
{ name: 'Leaderboard', href: '/leaderboards', icon: TrendingUpIcon },
|
||||||
|
|
||||||
...(IS_PRIVATE_MANIFOLD
|
...(IS_PRIVATE_MANIFOLD
|
||||||
? []
|
? []
|
||||||
|
@ -51,6 +52,10 @@ function getNavigation() {
|
||||||
function getMoreNavigation(user?: User | null) {
|
function getMoreNavigation(user?: User | null) {
|
||||||
if (IS_PRIVATE_MANIFOLD) {
|
if (IS_PRIVATE_MANIFOLD) {
|
||||||
return [
|
return [
|
||||||
|
{
|
||||||
|
name: 'Rules',
|
||||||
|
href: 'https://www.cspicenter.com/p/introducing-the-salemcspi-forecasting',
|
||||||
|
},
|
||||||
{ name: 'Discord', href: 'https://discord.gg/ZtT7PxapSS' },
|
{ name: 'Discord', href: 'https://discord.gg/ZtT7PxapSS' },
|
||||||
{ name: 'Manifold Markets', href: 'https://manifold.markets' },
|
{ name: 'Manifold Markets', href: 'https://manifold.markets' },
|
||||||
{
|
{
|
||||||
|
@ -115,13 +120,22 @@ const signedOutNavigation = [
|
||||||
|
|
||||||
const signedOutMobileNavigation = IS_PRIVATE_MANIFOLD
|
const signedOutMobileNavigation = IS_PRIVATE_MANIFOLD
|
||||||
? [
|
? [
|
||||||
{ name: 'Leaderboards', href: '/leaderboards', icon: TrendingUpIcon },
|
{ name: 'Leaderboard', href: '/leaderboards', icon: TrendingUpIcon },
|
||||||
|
{
|
||||||
|
name: 'Rules',
|
||||||
|
href: 'https://www.cspicenter.com/p/introducing-the-salemcspi-forecasting',
|
||||||
|
icon: BookOpenIcon,
|
||||||
|
},
|
||||||
{
|
{
|
||||||
name: 'Discord',
|
name: 'Discord',
|
||||||
href: 'https://discord.gg/ZtT7PxapSS',
|
href: 'https://discord.gg/ZtT7PxapSS',
|
||||||
icon: ChatIcon,
|
icon: ChatIcon,
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: 'Manifold Markets',
|
||||||
|
href: 'https://manifold.markets',
|
||||||
|
icon: ExternalLinkIcon,
|
||||||
|
},
|
||||||
]
|
]
|
||||||
: [
|
: [
|
||||||
{ name: 'Charity', href: '/charity', icon: HeartIcon },
|
{ name: 'Charity', href: '/charity', icon: HeartIcon },
|
||||||
|
@ -134,9 +148,25 @@ const signedOutMobileNavigation = IS_PRIVATE_MANIFOLD
|
||||||
]
|
]
|
||||||
|
|
||||||
const signedInMobileNavigation = [
|
const signedInMobileNavigation = [
|
||||||
{ name: 'Leaderboards', href: '/leaderboards', icon: TrendingUpIcon },
|
{ name: 'Leaderboard', href: '/leaderboards', icon: TrendingUpIcon },
|
||||||
...(IS_PRIVATE_MANIFOLD
|
...(IS_PRIVATE_MANIFOLD
|
||||||
? []
|
? [
|
||||||
|
{
|
||||||
|
name: 'Rules',
|
||||||
|
href: 'https://www.cspicenter.com/p/introducing-the-salemcspi-forecasting',
|
||||||
|
icon: BookOpenIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Discord',
|
||||||
|
href: 'https://discord.gg/ZtT7PxapSS',
|
||||||
|
icon: ChatIcon,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: 'Manifold Markets',
|
||||||
|
href: 'https://manifold.markets',
|
||||||
|
icon: ExternalLinkIcon,
|
||||||
|
},
|
||||||
|
]
|
||||||
: [
|
: [
|
||||||
{ name: 'Get M$', href: '/add-funds', icon: CashIcon },
|
{ name: 'Get M$', href: '/add-funds', icon: CashIcon },
|
||||||
{
|
{
|
||||||
|
@ -150,10 +180,7 @@ const signedInMobileNavigation = [
|
||||||
function getMoreMobileNav() {
|
function getMoreMobileNav() {
|
||||||
return [
|
return [
|
||||||
...(IS_PRIVATE_MANIFOLD
|
...(IS_PRIVATE_MANIFOLD
|
||||||
? [
|
? []
|
||||||
{ name: 'Manifold Markets', href: 'https://manifold.markets' },
|
|
||||||
{ name: 'Discord', href: 'https://discord.gg/ZtT7PxapSS' },
|
|
||||||
]
|
|
||||||
: CHALLENGES_ENABLED
|
: CHALLENGES_ENABLED
|
||||||
? [
|
? [
|
||||||
{ name: 'Challenges', href: '/challenges' },
|
{ name: 'Challenges', href: '/challenges' },
|
||||||
|
|
|
@ -3,7 +3,6 @@ import { Leaderboard } from 'web/components/leaderboard'
|
||||||
import { Page } from 'web/components/page'
|
import { Page } from 'web/components/page'
|
||||||
import { User, getFirstDayProfit, listAllUsers } from 'web/lib/firebase/users'
|
import { User, getFirstDayProfit, listAllUsers } from 'web/lib/firebase/users'
|
||||||
import { useEffect, useState } from 'react'
|
import { useEffect, useState } from 'react'
|
||||||
import { Title } from 'web/components/title'
|
|
||||||
import { useTracking } from 'web/hooks/use-tracking'
|
import { useTracking } from 'web/hooks/use-tracking'
|
||||||
import { SEO } from 'web/components/SEO'
|
import { SEO } from 'web/components/SEO'
|
||||||
import { sortBy } from 'lodash'
|
import { sortBy } from 'lodash'
|
||||||
|
@ -60,11 +59,10 @@ export default function Leaderboards(_props: { topTraders: User[] }) {
|
||||||
return (
|
return (
|
||||||
<Page>
|
<Page>
|
||||||
<SEO
|
<SEO
|
||||||
title="Leaderboards"
|
title="Leaderboard"
|
||||||
description="Manifold's leaderboards show the top traders and market creators."
|
description="See the top traders of the CSPI/Salem Center Tournament."
|
||||||
url="/leaderboards"
|
url="/leaderboards"
|
||||||
/>
|
/>
|
||||||
<Title text={'Leaderboards'} className={'hidden md:block'} />
|
|
||||||
|
|
||||||
<Col className="mx-4 max-w-sm items-center gap-10 lg:flex-row">
|
<Col className="mx-4 max-w-sm items-center gap-10 lg:flex-row">
|
||||||
<Leaderboard
|
<Leaderboard
|
||||||
|
|
Loading…
Reference in New Issue
Block a user