From 8a19c8ced2e76908fc6ce64c460a90dd134dcc4b Mon Sep 17 00:00:00 2001 From: Kamran Ahmed Date: Thu, 1 Sep 2022 22:56:03 +0400 Subject: [PATCH] Add email to download PDF functionality --- components/roadmap/roadmap-page-header.tsx | 119 +++++++++++++-------- 1 file changed, 75 insertions(+), 44 deletions(-) diff --git a/components/roadmap/roadmap-page-header.tsx b/components/roadmap/roadmap-page-header.tsx index fbca9cda8..5518ca439 100644 --- a/components/roadmap/roadmap-page-header.tsx +++ b/components/roadmap/roadmap-page-header.tsx @@ -8,17 +8,63 @@ import { Container, Flex, Heading, + Input, Link, + Modal, + ModalBody, + ModalCloseButton, + ModalContent, + ModalOverlay, Stack, Text, + useDisclosure } from '@chakra-ui/react'; -import { ChatIcon, AtSignIcon, DownloadIcon } from '@chakra-ui/icons'; +import { AtSignIcon, ChatIcon, DownloadIcon } from '@chakra-ui/icons'; import React from 'react'; +import { SIGNUP_EMAIL_INPUT_NAME, SIGNUP_FORM_ACTION } from '../../pages/signup'; type RoadmapPageHeaderType = { roadmap: RoadmapType; }; +function RoadmapDownloader() { + const { isOpen, onOpen, onClose } = useDisclosure(); + const initialRef = React.useRef(null); + + return ( + <> + + + + + + + + Download Roadmap + Enter your email below to receive the download link. +
+ + +
+
+
+
+ + ); +} + export function RoadmapPageHeader(props: RoadmapPageHeaderType) { const { roadmap } = props; @@ -27,13 +73,13 @@ export function RoadmapPageHeader(props: RoadmapPageHeaderType) { pt={['25px', '20px', '45px']} pb={['20px', '15px', '30px']} borderBottomWidth={1} - mb="30px" + mb='30px' > - + {roadmap.description} - + - {roadmap.pdfUrl && ( - - )} + +