File size: 1,410 Bytes
1e92f2d |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 |
import { Box, Flex, SimpleGrid, Text } from "@chakra-ui/react"
import NextImage from "next/image"
interface VideoCardProps {
image: string
title: string
href: string
}
const VideoCard = (props: VideoCardProps) => {
const { image, title, href } = props
return (
<a href={href} target="_blank" rel="noopener noreferrer">
<Flex
padding="4"
borderWidth="1px"
rounded="lg"
focusRing="outside"
_hover={{ bg: "bg.subtle" }}
cursor="pointer"
align="center"
>
<Box maxW="26px" maxH="26px">
<NextImage
src={image}
alt="Migration Guide"
layout="responsive"
width="120"
height="100"
/>
</Box>
<Box p="2">
<Text textStyle="sm">{title}</Text>
</Box>
</Flex>
</a>
)
}
export const FeaturedVideo = () => {
return (
<SimpleGrid
mb="10"
columns={{ base: 1, lg: 2 }}
gap={{ base: "4", md: "8" }}
>
<VideoCard
title="Watch the migration livestream (1)"
href="https://www.youtube.com/live/eU0n9egYGzU?si=ejMOxn1pgUH_6Ox-"
image="/image.png"
/>
<VideoCard
title="Watch the migration livestream (2)"
href="https://www.youtube.com/live/Ia9CZS3it4g?si=QfWnChbkHy_qwXJm"
image="/image.png"
/>
</SimpleGrid>
)
}
|