-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* created responsive hero section for homepage * completed adding the about us section for the homepage * removed black border around second img of homepage * removed about us section for now, at request of design team * setting up adding upcoming events to the homepage * added events to the homepage * got rid of the borders on the events, now it looks even better * allowed for dark and light mode color shifting of the event cards * Fixed spacing issue --------- Co-authored-by: saltyypanda <esh7943@rit.edu>
- Loading branch information
1 parent
788e4c1
commit 80e889c
Showing
11 changed files
with
99 additions
and
62 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
'use client' | ||
import { Event } from "./event"; | ||
import { clsx } from "clsx"; // you will need to do 'npm install' if you haven't already, as I have added this for light and dark mode color switching | ||
import { useTheme } from "next-themes"; | ||
import { Theme } from '@/types/theme'; | ||
|
||
export const EventCard: React.FC<Event> = (event: Event) => { | ||
const { theme } = useTheme(); | ||
|
||
return ( | ||
<div className={clsx("flex flex-col shadow-md rounded-3xl overflow-hidden", | ||
{ "bg-white": theme === Theme.Light, "bg-[#172630]": theme === Theme.Dark, }, | ||
)}> | ||
<img src={event.imageSrc} className="w-full h-1/3" alt="" /> | ||
<div className="p-4"> | ||
<h4 className="text-primary">{event.title.slice(0, 1).toUpperCase() + event.title.slice(1)}</h4> {/* Make sure the title is captialized, but otherwise, this is just the title of the card */} | ||
<h5>{event.date}</h5> | ||
<h5>{event.location}</h5> | ||
<p>{event.description}</p> | ||
</div> | ||
</div> | ||
); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
export interface Event { | ||
title: string, | ||
date: string, | ||
location: string, | ||
imageSrc: string, | ||
description: string | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.