-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Giving Day] New Heros #874
Changes from all commits
94add34
97a6d38
5645cc8
2a731ca
91864e5
16a1e7e
9db728f
b60114c
6b26bd1
8ee8491
c0f70d4
1d7f2ab
b03a31a
765f061
bc23704
8542e10
306587f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
import SectionWrapper from './hoc/SectionWrapper'; | ||
|
||
type HeroProps = { | ||
title: string; | ||
description: string; | ||
image: { | ||
src: string; | ||
alt: string; | ||
}; | ||
action?: { | ||
buttonText: string; | ||
link: string; | ||
disabled?: boolean; | ||
}; | ||
}; | ||
|
||
const Hero = ({ title, description, image, action }: HeroProps) => ( | ||
<SectionWrapper id={`${title} hero`}> | ||
<img src={image.src} alt={image.alt} height={600} className="w-[100%] rounded-[16px]" /> | ||
<div className="flex flex-col gap-4"> | ||
<div className="flex flex-col gap-2"> | ||
<h1 className="md:text-[40px] md:leading-[46px] font-bold mt-4 xs:text-[32px] xs:leading-[36.8px] text-[#ffffff]"> | ||
{title} | ||
</h1> | ||
<p className="md:text-[18px] text-hero-secondary leading-[28.8px]">{description}</p> | ||
</div> | ||
{action && | ||
(action.disabled ? ( | ||
<button className="primary-button opacity-50 cursor-not-allowed" disabled={true}> | ||
{action.buttonText} | ||
</button> | ||
) : ( | ||
<a className="primary-button" href={action.link}> | ||
{action.buttonText} | ||
</a> | ||
))} | ||
Comment on lines
+27
to
+36
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
||
</div> | ||
</SectionWrapper> | ||
); | ||
|
||
export default Hero; |
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
This file was deleted.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for the Apply button in hero section to be disabled when applications not open