Files
rubix/src/components/Card/LearnCard.jsx

85 lines
2.1 KiB
React
Raw Normal View History

/* eslint-disable react/prop-types */
/* eslint-disable no-unused-vars */
import { Box, Container, Text, Image, Button } from "@chakra-ui/react";
import { Link } from "react-router-dom";
const LearnCard = ({ id, src, alt, text, href }) => {
return (
2024-04-11 13:41:31 +05:30
<Box padding={"1px"} borderRadius={"10px"}>
{/* {images.map((img) => (
<></>
))} */}
<Box
display="inline-block"
2024-04-09 13:00:11 +05:30
width={"520px"}
height={"300px"}
2024-04-09 13:00:11 +05:30
background={"#161616"}
borderRadius={"10px"}
2024-04-09 13:00:11 +05:30
padding={"20px"}
key={id}
2024-03-29 19:54:51 +05:30
sx={{
"@media (max-width: 435px)": {
width: "390px",
},
}}
>
2024-04-11 13:41:31 +05:30
<Box padding={"1rem"}>
2024-04-09 13:00:11 +05:30
<Image height={"60px"} src={src} alt={alt} />
</Box>
2024-04-11 13:41:31 +05:30
<Box padding={"1rem"}>
<Text
2024-04-09 13:00:11 +05:30
color={"#E8E8E8"}
fontSize={"18px"}
fontFamily={"Poppins"}
marginBottom={"20px"}
2024-04-09 13:00:11 +05:30
// fontWeight={"100"}
2024-04-11 13:41:31 +05:30
minHeight={"100px"}
>
{text}
</Text>
<Box
display={"flex"}
alignItems={"center"}
_hover={
{
// flexDirection: "column-reverse",
}
}
>
<Box
position={"relative"}
width={"10%"}
_before={{
content: '""',
width: "100%",
position: "absolute",
left: "0",
borderBottom: "1px solid #DE858E",
zIndex: "2",
}}
></Box>
<Link to={href} target="_blank" rel="noopener noreferrer">
<Button
position={"relative"}
backgroundColor={"transparent"}
color={"#fff"}
fontFamily={"Poppins"}
fontWeight={"400"}
_hover={{
backgroundColor: "transparent",
}}
>
Visit Website
</Button>
</Link>
</Box>
</Box>
</Box>
</Box>
);
};
export default LearnCard;