2022-09-12 22:34:13 +00:00
|
|
|
import Image from 'next/future/image'
|
2022-06-13 04:42:41 +00:00
|
|
|
import { SparklesIcon } from '@heroicons/react/solid'
|
2022-06-13 16:19:46 +00:00
|
|
|
|
|
|
|
import { Contract } from 'common/contract'
|
|
|
|
|
2022-01-21 18:33:58 +00:00
|
|
|
import { Spacer } from './layout/spacer'
|
2022-06-13 04:42:41 +00:00
|
|
|
import { firebaseLogin } from 'web/lib/firebase/users'
|
2022-08-06 00:46:32 +00:00
|
|
|
import { ContractsGrid } from './contract/contracts-grid'
|
2022-01-27 00:21:14 +00:00
|
|
|
import { Col } from './layout/col'
|
2022-03-03 08:56:03 +00:00
|
|
|
import { Row } from './layout/row'
|
2022-06-15 03:00:36 +00:00
|
|
|
import { withTracking } from 'web/lib/service/analytics'
|
2022-06-16 02:42:11 +00:00
|
|
|
import { useTracking } from 'web/hooks/use-tracking'
|
2022-01-21 18:33:58 +00:00
|
|
|
|
2022-06-13 16:19:46 +00:00
|
|
|
export function LandingPagePanel(props: { hotContracts: Contract[] }) {
|
2022-01-22 00:28:12 +00:00
|
|
|
const { hotContracts } = props
|
2022-01-21 18:33:58 +00:00
|
|
|
|
2022-06-16 02:42:11 +00:00
|
|
|
useTracking('view landing page')
|
|
|
|
|
2022-01-21 18:33:58 +00:00
|
|
|
return (
|
|
|
|
<>
|
2022-06-13 16:19:46 +00:00
|
|
|
<Col className="mb-6 rounded-xl sm:m-12 sm:mt-0">
|
2022-09-12 22:34:13 +00:00
|
|
|
<Image
|
2022-05-17 14:25:51 +00:00
|
|
|
height={250}
|
|
|
|
width={250}
|
|
|
|
className="self-center"
|
|
|
|
src="/flappy-logo.gif"
|
|
|
|
/>
|
2022-06-13 16:52:29 +00:00
|
|
|
<div className="m-4 max-w-[550px] self-center">
|
2022-06-13 16:19:46 +00:00
|
|
|
<h1 className="text-3xl sm:text-6xl xl:text-6xl">
|
|
|
|
<div className="font-semibold sm:mb-2">
|
2022-09-07 20:01:02 +00:00
|
|
|
A{' '}
|
2022-06-13 16:19:46 +00:00
|
|
|
<span className="bg-gradient-to-r from-indigo-500 to-blue-500 bg-clip-text font-bold text-transparent">
|
2022-09-07 20:01:02 +00:00
|
|
|
market
|
|
|
|
</span>{' '}
|
|
|
|
for every question
|
2022-06-13 16:19:46 +00:00
|
|
|
</div>
|
|
|
|
</h1>
|
|
|
|
<Spacer h={6} />
|
|
|
|
<div className="mb-4 px-2 ">
|
2022-09-07 20:01:02 +00:00
|
|
|
Create a play-money prediction market on any topic you care about.
|
|
|
|
Trade with your friends to forecast the future.
|
2022-06-13 16:19:46 +00:00
|
|
|
<br />
|
|
|
|
</div>
|
2022-01-21 18:33:58 +00:00
|
|
|
</div>
|
2022-01-27 00:21:14 +00:00
|
|
|
<Spacer h={6} />
|
|
|
|
<button
|
2022-06-13 16:19:46 +00:00
|
|
|
className="self-center rounded-md border-none bg-gradient-to-r from-indigo-500 to-blue-500 py-4 px-6 text-lg font-semibold normal-case text-white hover:from-indigo-600 hover:to-blue-600"
|
2022-06-15 03:00:36 +00:00
|
|
|
onClick={withTracking(firebaseLogin, 'landing page button click')}
|
2022-01-27 00:21:14 +00:00
|
|
|
>
|
2022-06-13 16:19:46 +00:00
|
|
|
Get started
|
2022-01-27 00:21:14 +00:00
|
|
|
</button>{' '}
|
|
|
|
</Col>
|
2022-01-22 20:52:49 +00:00
|
|
|
|
2022-03-03 08:56:03 +00:00
|
|
|
<Row className="m-4 mb-6 items-center gap-1 text-xl font-semibold text-gray-800">
|
|
|
|
<SparklesIcon className="inline h-5 w-5" aria-hidden="true" />
|
2022-05-07 23:44:01 +00:00
|
|
|
Trending markets
|
2022-03-03 08:56:03 +00:00
|
|
|
</Row>
|
2022-08-09 22:28:27 +00:00
|
|
|
<ContractsGrid contracts={hotContracts?.slice(0, 10) || []} />
|
2022-01-21 18:33:58 +00:00
|
|
|
</>
|
|
|
|
)
|
|
|
|
}
|