Skip to content

Commit

Permalink
phoebe_prop_update
Browse files Browse the repository at this point in the history
  • Loading branch information
Phoebe Zhou authored and Phoebe Zhou committed Feb 1, 2025
1 parent 1ded22c commit a7c5666
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 15 deletions.
2 changes: 1 addition & 1 deletion src/app/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ const Home = () => {
return (
<div>
<MainText />
<BlurbHome title={""} description={""} image={""} />
<BlurbHome />
</div>
);
};
Expand Down
27 changes: 13 additions & 14 deletions src/components/home/BlurbHome.tsx
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
import Image from "next/image";
import Cupcakes from "@/public/home/cupcakes.webp";
import BlurbHomeProps from "./BlurbHomeProps";

interface CardProps {
title: string;
description: string;
image: string;
}
const BlurbHome: React.FC<CardProps> = ({ title, description, image }) => {
const BlurbHome = () => {
return (
<div>
<div className="flex w-[30vw] flex-col items-center">
<Image src={image} alt="" />
</div>
<h2 className="my-[1vh] text-[1.7vw] font-medium">{title}</h2>
<p className="w-[18vw] text-center text-[0.9vw] font-light leading-tight">
{description}
</p>
<BlurbHomeProps
title="Collaborations"
description="We collaborate with various organizations, including SAGE and St. John
Ambulance (SJA) Canada. We plan to host campus-wide events and are
actively networking with other groups focused on cardiovascular disease
initiatives!"
image={Cupcakes}
alt="12 Cupcakes on the table with two people sitting behind it"
/>
</div>
);
};

export default BlurbHome;
31 changes: 31 additions & 0 deletions src/components/home/BlurbHomeProps.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
import Image, { StaticImageData } from "next/image";

interface CardProps {
title: string;
description: string;
image: StaticImageData;
alt: string;
}
const BlurbHomeProps: React.FC<CardProps> = ({
title,
description,
image,
alt,
}) => {
return (
<div className="flex w-[30vw] flex-col items-center">
<div>
<Image
src={image}
alt={alt}
className="h-[37vh] w-[20vw] rounded-[15%] border-2 border-cvdsa-cornflower-100"
/>
</div>
<h2 className="my-[1vh] text-[1.7vw] font-medium">{title}</h2>
<p className="w-[18vw] text-center text-[0.9vw] font-light leading-tight">
{description}
</p>
</div>
);
};
export default BlurbHomeProps;

0 comments on commit a7c5666

Please sign in to comment.