Skip to content

Commit 09f28e6

Browse files
authored
Merge branch 'Developer-DAO:main' into lesson-erc20
2 parents 4bcd20b + 60142c9 commit 09f28e6

File tree

146 files changed

+5612
-1466
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

146 files changed

+5612
-1466
lines changed

.eslintrc.cjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
module.exports = {
2-
extends: ['next/core-web-vitals', 'plugin:storybook/recommended'],
2+
extends: ['next/core-web-vitals'],
33
}

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ yarn-error.log*
2727

2828
# local env files
2929
.env*.local
30+
.env
3031

3132
# vercel
3233
.vercel

.vscode/settings.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"typescript.tsdk": "node_modules/typescript/lib"
3+
}

components/Banner.tsx

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,57 @@
1+
import { Center, Flex, Text, chakra } from '@chakra-ui/react'
2+
import { CloseIcon } from '@chakra-ui/icons'
3+
4+
const Banner = () => {
5+
const dismissBanner = () => {
6+
localStorage.setItem('bannerDismissed', 'true')
7+
const banner = document.getElementById('banner')
8+
if (banner) {
9+
banner.style.display = 'none'
10+
}
11+
}
12+
13+
return (
14+
<Center
15+
py="2"
16+
px="3"
17+
bgGradient="linear(to-r,cyan.700, purple.500)"
18+
color="white"
19+
textAlign="center"
20+
id="banner"
21+
>
22+
<Flex align="center" fontSize="sm">
23+
<Text fontWeight="medium" maxW={{ base: '32ch', md: 'unset' }}>
24+
Acamdey V2 is coming soon 👀... Subscribe to our newsletter for
25+
updates!
26+
</Text>
27+
<chakra.a
28+
flexShrink={0}
29+
href="https://developerdao.substack.com/s/probably-nothing"
30+
target="_blank"
31+
ms="6"
32+
bg="blackAlpha.300"
33+
color="whiteAlpha.900"
34+
fontWeight="semibold"
35+
px="3"
36+
py="1"
37+
rounded="base"
38+
>
39+
Subscribe now!{' '}
40+
</chakra.a>
41+
<chakra.button
42+
onClick={dismissBanner}
43+
ms="6"
44+
color="whiteAlpha.900"
45+
fontWeight="semibold"
46+
px="3"
47+
py="1"
48+
rounded="base"
49+
>
50+
<CloseIcon />
51+
</chakra.button>
52+
</Flex>
53+
</Center>
54+
)
55+
}
56+
57+
export default Banner

components/Header.tsx

Lines changed: 0 additions & 5 deletions
This file was deleted.

components/Hero.tsx

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ import {
1111
} from '@chakra-ui/react'
1212
import { ArrowForwardIcon } from '@chakra-ui/icons'
1313
import Image from 'next/image'
14+
import NextLink from 'next/link'
1415

1516
const Hero = () => {
1617
return (
@@ -45,6 +46,7 @@ const Hero = () => {
4546
<Link
4647
href={'/getting-started'}
4748
alignSelf={{ base: 'center', md: 'flex-start' }}
49+
as={NextLink}
4850
>
4951
<Button
5052
colorScheme="pink"

components/Layout.tsx

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
import NavBar from '@components/NavBar'
2+
import Footer from '@components/footer/Footer'
3+
import { Box } from '@chakra-ui/react'
4+
import Banner from './Banner'
5+
6+
const Layout = ({ children }: { children: React.ReactNode }) => {
7+
return (
8+
<>
9+
<Banner />
10+
<NavBar />
11+
<Box
12+
p="1.25em"
13+
px="5%"
14+
mx={{ base: '2rem', md: '6rem', lg: '10rem' }}
15+
as="main"
16+
minH={{ base: 'calc(75vh - 3.5rem)' }}
17+
>
18+
{children}
19+
</Box>
20+
<Footer />
21+
</>
22+
)
23+
}
24+
25+
export default Layout

components/NavBar.tsx

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,12 @@ import { PomodoroTimer } from '@components/PomodoroTimer'
1919
function NavBar() {
2020
const router = useRouter()
2121
return (
22-
<Box>
22+
<Box
23+
p="1.25em"
24+
px="5%"
25+
mx={{ base: '2rem', md: '6rem', lg: '10rem' }}
26+
as="header"
27+
>
2328
<Flex justify="left" alignItems="center">
2429
<Link as={NextLink} variant="logo" href={'/'}>
2530
{router.pathname.endsWith('/[slug]') ? (
@@ -79,7 +84,7 @@ function NavBar() {
7984
GET STARTED
8085
</Link>
8186
</MenuItem>
82-
<MenuItem>
87+
{/* <MenuItem>
8388
<Link
8489
as={NextLink}
8590
href="/lessons"
@@ -92,7 +97,7 @@ function NavBar() {
9297
>
9398
Tracks
9499
</Link>
95-
</MenuItem>
100+
</MenuItem> */}
96101
</MenuList>
97102
</Menu>
98103
</Flex>
@@ -131,7 +136,7 @@ function NavBar() {
131136
Get Started
132137
</Link>
133138

134-
<Link
139+
{/* <Link
135140
as={NextLink}
136141
href="/lessons"
137142
passHref
@@ -142,7 +147,7 @@ function NavBar() {
142147
}
143148
>
144149
Tracks
145-
</Link>
150+
</Link> */}
146151

147152
{/* <Button colorScheme="gray" variant="solid">
148153
<ConnectButton chainStatus="icon" showBalance={false} />

components/PageSeoLayout.tsx

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,51 @@
1+
import { NextSeo } from 'next-seo'
2+
3+
interface PageSeoLayoutProps {
4+
title: string
5+
description?: string
6+
children?: React.ReactNode
7+
}
8+
9+
const PageSeoLayout = ({
10+
title,
11+
description,
12+
children,
13+
}: PageSeoLayoutProps) => {
14+
return (
15+
<>
16+
<NextSeo
17+
title={`Developer DAO Academy | ${title}`}
18+
description={description}
19+
openGraph={{
20+
type: 'website',
21+
locale: 'en_US',
22+
url: `https://${process.env.NEXT_PUBLIC_VERCEL_URL}/landing-page-screenshot.png`,
23+
site_name: `Developer DAO Academy`,
24+
title: `Developer DAO Academy | ${title}`,
25+
description: `${description}`,
26+
images: [
27+
{
28+
url: `https://${process.env.NEXT_PUBLIC_VERCEL_URL}/landing-page-screenshot.png`,
29+
alt: 'Developer DAO Academy',
30+
type: 'image/png',
31+
},
32+
],
33+
}}
34+
twitter={{
35+
handle: '@devdao_academy',
36+
site: '@devdao_academy',
37+
cardType: 'summary_large_image',
38+
}}
39+
additionalLinkTags={[
40+
{
41+
rel: 'icon',
42+
href: '/favicon/favicon.ico',
43+
},
44+
]}
45+
/>
46+
{children}
47+
</>
48+
)
49+
}
50+
51+
export default PageSeoLayout

components/footer/Footer.tsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,10 @@ export default function Footer() {
1414
return (
1515
<Box
1616
// bg={useColorModeValue('#00000f', '#1d1e20')}
17+
p="1.25em"
18+
px="5%"
19+
mx={{ base: '2rem', md: '6rem', lg: '10rem' }}
20+
as="footer"
1721
color={useColorModeValue('gray.700', 'gray.200')}
1822
>
1923
<Container

0 commit comments

Comments
 (0)