Skip to content
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

Feature: make hero section prototype #116

Merged
merged 14 commits into from
Mar 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7,655 changes: 7,655 additions & 0 deletions src/assets/hero/bg-desktop-svg.tsx

Large diffs are not rendered by default.

3,234 changes: 3,234 additions & 0 deletions src/assets/hero/bg-mobile-svg.tsx

Large diffs are not rendered by default.

3,300 changes: 3,300 additions & 0 deletions src/assets/hero/desktop.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1,288 changes: 1,288 additions & 0 deletions src/assets/hero/mobile.svg
juancwu marked this conversation as resolved.
Show resolved Hide resolved
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions src/assets/index.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@

export { HeroBackgroundMobile } from './hero/bg-mobile-svg';
export { HeroBackgroundDesktop } from './hero/bg-desktop-svg';

import {
MailIcon,
LinkedInIcon,
Expand Down
9 changes: 2 additions & 7 deletions src/components/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,5 @@ export { Menu } from './Navbar/Menu';
*
*/
export { TeamSection } from './sections/Team.section';

/*
*
* @section FooterSection
*
*/
export { FooterSection } from './sections/Footer.section';
export { HeroSection } from "./sections/Hero.section"
export { FooterSection } from './sections/Footer.section';
40 changes: 40 additions & 0 deletions src/components/sections/Hero.section.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
import { HeroBackgroundMobile, HeroBackgroundDesktop } from '@assets';

const HeroSection = () => {
return (
<div className="stacked place-items-end-center sm:place-items-start">
<HeroBackgroundMobile
className={'media block pb-16 sm:hidden xl:translate-y-20'}
/>
<HeroBackgroundDesktop
className={'media hidden sm:block xl:translate-y-20'}
/>

<div className="space-y-1 pb-4 text-center sm:pl-24 sm:pt-12 sm:text-left lg:pl-16 lg:pt-16 2xl:pl-60 2xl:pt-24">
<img
className="inline-block aspect-square w-20 sm:mx-0 lg:w-28 xl:w-32 2xl:w-52"
src="src/assets/logo.svg"
alt="Hawkhack logo"
/>
<div className="sm:space-y-2">
<h1 className="bg-gradient-to-b from-[#2B6469] to-[#00CEDB] bg-clip-text text-4xl font-extrabold text-transparent lg:text-5.5xl xl:text-7xl">
HawkHack 2024
</h1>
<p className="font-semibold text-[#2B6469] xl:text-2xl 2xl:text-3.5xl ">
Hosted at Wilfrid Laurier University
</p>
</div>
<div>
<p className="text-2xl font-bold text-[#2B6469] sm:hidden">
April 5th - 7th
</p>
<p className="text-2xl font-bold text-[#2B6469] sm:hidden">
In Person
</p>
</div>
</div>
</div>
);
};

export { HeroSection };
19 changes: 19 additions & 0 deletions src/index.css
Original file line number Diff line number Diff line change
Expand Up @@ -87,4 +87,23 @@ body {
--gap: 2.5rem;
--min: 25ch;
}

.stacked {
display: grid;
}

.stacked > * {
grid-column: 1 / -1;
grid-row: 1 / -1;
}

.stacked > .media {
z-index: -1;
width: 100%;
height: 100%;
}

.place-items-end-center {
place-items: end center;
}
}
5 changes: 2 additions & 3 deletions src/pages/Landing.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
import { TeamSection } from '@components';
import { FooterSection } from '@components';
import { Navbar } from '@components';
import { Navbar, HeroSection, TeamSection, FooterSection } from '@components';

const Landing: React.FC = () => {
return (
Expand All @@ -10,6 +8,7 @@ const Landing: React.FC = () => {
// total top padding = 3.5 + 4 = 7.5rem
<div className="pt-[7.5rem]">
<Navbar />
<HeroSection />
<TeamSection />
<FooterSection />
</div>
Expand Down
Loading