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

update #251

Merged
merged 5 commits into from
Mar 1, 2025
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
8 changes: 4 additions & 4 deletions src/client/components/about/AboutCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,18 +25,18 @@ const AboutCard = () => {

{/* Gradient Line */}
<div
className="absolute -bottom-12 right-6 h-2 w-[90%] rounded-full"
className="absolute -bottom-12 right-6 hidden h-2 w-[90%] rounded-full md:block"
style={{
background: "linear-gradient(to right, #0668B3 70%, white)",
}}
></div>

{/* Logo Image */}
{/* Logo Image (Reduced Size) */}
<img
src={imageUrls["SASELogoStar.png"]}
alt="Logo"
style={{ width: "200px", height: "200px" }}
className="absolute -bottom-28 -right-20 object-contain"
style={{ width: "150px", height: "150px" }} // Reduced size
className="absolute -bottom-24 -right-16 object-contain"
/>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/client/components/about/HeaderSection.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
const HeaderSection = () => (
<header className="mb-10 text-center">
<h1 className="font-oswald text-5xl font-bold text-black">ABOUT</h1>
<h1 className="font-oswald text-5xl font-medium sm:text-6xl md:text-7xl">ABOUT</h1>
<p className="mt-4 text-lg text-black">
"We help shape skills and provide knowledge that will help our members to succeed in the professional world"
</p>
Expand Down
123 changes: 85 additions & 38 deletions src/client/components/about/HistorySection.tsx
Original file line number Diff line number Diff line change
@@ -1,40 +1,87 @@
const HistorySection = () => (
<section className="mb-8">
<div className="max-w-5xl">
<p className="mb-4 text-lg text-gray-800">
<span className="font-semibold">Since being founded during the summer of 2010,</span> the University of Florida chapter has had an abundant
effort put forth for the development of our members.
</p>
<p className="mb-4 text-lg text-gray-800">
This development is centered on <span className="font-semibold">five core values</span> of our mission statement:{" "}
<span className="font-semibold">leadership, professionalism, service, academics,</span> and <span className="font-semibold">diversity.</span>{" "}
Our meetings and events are catered to ensure that not only our mission is being fulfilled, but also that a community of support among Asian
heritage students is being built. We pride ourselves on our measurable successes but could not have done so without the help of our members,
faculty, and sponsors.
</p>
<p className="mb-4 text-lg text-gray-800">
Through <span className="font-semibold">events</span> we have hosted in the past, such as our annual Quick Race or the Southeast Regional
Conferences of 2014-2016, many of our members have been able to get involved in committees and take on leadership roles. Many of our other
events allow students to <span className="font-semibold">develop professional skills</span> that are essential for positions in industry.
</p>
<p className="mb-4 text-lg text-gray-800">
Our SASE chapter is not only active on campus, but also within the <span className="font-semibold">Gainesville community</span>, such as when
we participated in a 5K raising money for a local robotics team. We are also heavily involved in the{" "}
<span className="font-semibold">Asian American Student Union</span> at the University of Florida, taking part in their annual welcome assembly
and hosting events with cultural and professional sub-organizations.
</p>
</div>
<div className="mt-2 text-center">
<a
href="2024-2025-SASE-Constitution.docx.pdf"
className="mt-6 inline-block transform rounded-full bg-[#0f6cb6] px-6 py-2 text-white transition duration-300 hover:scale-105"
target="_blank"
rel="noopener noreferrer"
>
2024-2025 SASE Constitution
</a>
</div>
</section>
);
import useIsMobile from "@hooks/useIsMobile";
import { useState } from "react";
import { FaChevronDown, FaChevronUp } from "react-icons/fa6";

const HistorySection = () => {
const [isExpanded, setIsExpanded] = useState(false);
const isMobile = useIsMobile();

return (
<section className="mb-8">
<div className={isMobile ? "max-w-full px-4" : "max-w-5xl"}>
<p className={isMobile ? "mb-3 text-sm text-gray-800" : "mb-4 text-lg text-gray-800"}>
<strong>Since being founded during the summer of 2010,</strong> the University of Florida chapter has had an abundant effort put forth for
the development of our members.
</p>
<p className={isMobile ? "mb-3 text-sm text-gray-800" : "mb-4 text-lg text-gray-800"}>
This development is centered on <strong>five core values</strong> of our mission statement:{" "}
<strong>leadership, professionalism, service, academics,</strong> and <strong>diversity.</strong> Our meetings and events are catered to
ensure that not only our mission is being fulfilled, but also that a community of support among Asian heritage students is being built. We
pride ourselves on our measurable successes but could not have done so without the help of our members, faculty, and sponsors.
</p>

{/* Full description always shown on desktop */}
{!isMobile && (
<>
<p className="mb-4 text-lg text-gray-800">
Through <strong>events</strong> we have hosted in the past, such as our annual Quick Race or the Southeast Regional Conferences of
2014-2016, many of our members have been able to get involved in committees and take on leadership roles. Many of our other events allow
students to <strong>develop professional skills</strong> that are essential for positions in industry.
</p>
<p className="mb-4 text-lg text-gray-800">
Our SASE chapter is not only active on campus, but also within the <strong>Gainesville community</strong>, such as when we participated
in a 5K raising money for a local robotics team. We are also heavily involved in the <strong>Asian American Student Union</strong> at
the University of Florida, taking part in their annual welcome assembly and hosting events with cultural and professional
sub-organizations.
</p>
</>
)}

{/* Read More Toggle (Only on Mobile) */}
{isMobile && !isExpanded && (
<div className="flex w-fit cursor-pointer items-center text-blue-600 hover:underline" onClick={() => setIsExpanded(true)}>
<span>Read more</span>
<FaChevronDown className="ml-1 h-4 w-4" />
</div>
)}

{/* Expandable Content (Only on Mobile) */}
{isMobile && (
<div className={`transition-all duration-300 ${isExpanded ? "max-h-[1000px] opacity-100" : "max-h-0 overflow-hidden opacity-0"}`}>
<p className="mb-3 text-sm text-gray-800">
Through <strong>events</strong> we have hosted in the past, such as our annual Quick Race or the Southeast Regional Conferences of
2014-2016, many of our members have been able to get involved in committees and take on leadership roles. Many of our other events allow
students to <strong>develop professional skills</strong> that are essential for positions in industry.
</p>
<p className="mb-3 text-sm text-gray-800">
Our SASE chapter is not only active on campus, but also within the <strong>Gainesville community</strong>, such as when we participated
in a 5K raising money for a local robotics team. We are also heavily involved in the <strong>Asian American Student Union</strong> at
the University of Florida, taking part in their annual welcome assembly and hosting events with cultural and professional
sub-organizations.
</p>

{/* Read Less Link (Only on Mobile) */}
<div className="flex w-fit cursor-pointer items-center text-blue-600 hover:underline" onClick={() => setIsExpanded(false)}>
<span>Read less</span>
<FaChevronUp className="ml-1 h-4 w-4" />
</div>
</div>
)}
</div>

{/* Constitution Link */}
<div className="mt-4 text-center">
<a
href="2024-2025-SASE-Constitution.docx.pdf"
className="mt-6 inline-block transform rounded-full bg-[#0f6cb6] px-6 py-2 text-white transition duration-300 hover:scale-105"
target="_blank"
rel="noopener noreferrer"
>
2024-2025 SASE Constitution
</a>
</div>
</section>
);
};

export default HistorySection;
76 changes: 47 additions & 29 deletions src/client/components/about/MissionSection.tsx
Original file line number Diff line number Diff line change
@@ -1,35 +1,53 @@
import { imageUrls } from "@/client/assets/imageUrls";
import { cn } from "@/shared/utils";
import { useEffect, useState } from "react";
import MissionCard from "./MissionCard";
import MissionSectionMobile from "./MissionSectionMobile";

const MissionSection = () => (
<section className="mb-12">
<div className="mb-4 flex items-center">
<div className="mr-3 h-12 w-1.5 rounded-sm bg-saseGreen"></div>
<h2 className="font-oswald text-3xl font-semibold text-gray-800">Mission Statement</h2>
</div>
const MissionSection: React.FC = () => {
const [isMobile, setIsMobile] = useState<boolean>(false);

<p className="mb-8 text-center text-xl text-black">To create a welcoming community where members:</p>
<div className="flex flex-nowrap justify-center gap-20">
<MissionCard
title="Professional Development"
logo={imageUrls["Suitcase.png"]}
text="To prepare Asian heritage students for success in the global business world."
shadowColor="green"
/>
<MissionCard
title="Diversity"
logo={imageUrls["People.png"]}
text="To promote diversity and tolerance on campuses and in the workplace."
shadowColor="blue"
/>
<MissionCard
title="Community"
logo={imageUrls["Lightbulb.png"]}
text="To provide opportunities for our members to contribute to their local communities."
shadowColor="green"
/>
</div>
</section>
);
useEffect(() => {
const handleResize = () => setIsMobile(window.innerWidth < 1024);
handleResize();
window.addEventListener("resize", handleResize);
return () => window.removeEventListener("resize", handleResize);
}, []);
Comment on lines +10 to +15
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be in a hook to not redeclare for every file (check if one already exists)


return isMobile ? (
<MissionSectionMobile />
) : (
<section className={cn("mx-auto mb-12 w-full max-w-7xl px-4 sm:px-0")}>
<div className={cn("mb-4 flex w-full items-center")}>
<div className={cn("mr-3 h-12 w-1.5 rounded-sm bg-saseGreen")}></div>
<h2 className={cn("font-oswald text-3xl font-semibold text-gray-800")}>Mission Statement</h2>
</div>

<p className={cn("mb-8 text-center text-xl text-black")}>To create a welcoming community where members:</p>

{/* Desktop Layout */}
<div className={cn("flex flex-nowrap justify-center gap-20")}>
<MissionCard
title="Professional Development"
logo={imageUrls["Suitcase.png"]}
text="To prepare Asian heritage students for success in the global business world."
shadowColor="green"
/>
<MissionCard
title="Diversity"
logo={imageUrls["People.png"]}
text="To promote diversity and tolerance on campuses and in the workplace."
shadowColor="blue"
/>
<MissionCard
title="Community"
logo={imageUrls["Lightbulb.png"]}
text="To provide opportunities for our members to contribute to their local communities."
shadowColor="green"
/>
</div>
</section>
);
};

export default MissionSection;
53 changes: 53 additions & 0 deletions src/client/components/about/MissionSectionMobile.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
import { imageUrls } from "@/client/assets/imageUrls";
import { cn } from "@/shared/utils";

const MissionSectionMobile: React.FC = () => (
<section className={cn("mx-auto mb-12 w-full max-w-7xl sm:px-0")}>
<div className={cn("mb-10 flex w-full max-w-7xl items-center sm:justify-start")}>
<div className={cn("mr-3 h-12 w-1.5 rounded-sm bg-saseGreen")}></div>
<h2 className={cn("font-oswald text-3xl font-semibold text-gray-800")}>Mission Statement</h2>
</div>

<p className={cn("mb-6 flex text-lg text-black")}>To create a welcoming community where members:</p>

{/* Mobile-Specific Stacked Cards */}
<div className={cn("flex flex-col items-center gap-6")}>
{/* Professional Development */}
<div className={cn("relative w-full max-w-md rounded-lg bg-gray-200 p-5 shadow-lg")}>
{/* Icon */}
<div className={cn("absolute -top-3 right-5 h-12 w-12")}>
<img src={imageUrls["Suitcase.png"]} alt="Suitcase Icon" className={cn("w-full")} />
</div>
<h3 className={cn("text-lg font-bold text-black")}>Professional Development:</h3>
<p className={cn("text-black")}>To prepare Asian heritage students for success in the global business world.</p>
{/* Edges */}
<div className={cn("absolute -left-2 -top-2 h-7 w-7 border-l-2 border-t-2 border-green-500")}></div>
<div className={cn("absolute -right-2 bottom-[-8px] h-7 w-7 border-b-2 border-r-2 border-green-500")}></div>
</div>

{/* Diversity */}
<div className={cn("relative w-full max-w-md rounded-lg bg-gray-200 p-5 shadow-lg")}>
<div className={cn("absolute -top-3 left-5 h-12 w-12")}>
<img src={imageUrls["People.png"]} alt="Diversity Icon" className={cn("w-full")} />
</div>
<h3 className={cn("text-right text-lg font-bold text-black")}>Diversity:</h3>
<p className={cn("text-black")}>To promote diversity and tolerance on campuses and in the workplace.</p>
<div className={cn("absolute -right-2 -top-2 h-7 w-7 border-r-2 border-t-2 border-blue-500")}></div>
<div className={cn("absolute -left-2 bottom-[-8px] h-7 w-7 border-b-2 border-l-2 border-blue-500")}></div>
</div>

{/* Community */}
<div className={cn("relative w-full max-w-md rounded-lg bg-gray-200 p-5 shadow-lg")}>
<div className={cn("absolute -top-3 right-5 h-12 w-12")}>
<img src={imageUrls["Lightbulb.png"]} alt="Community Icon" className={cn("w-full")} />
</div>
<h3 className={cn("text-lg font-bold text-black")}>Community:</h3>
<p className={cn("text-black")}>To provide opportunities for our members to contribute to their local communities.</p>
<div className={cn("absolute -left-2 -top-2 h-7 w-7 border-l-2 border-t-2 border-green-500")}></div>
<div className={cn("absolute -right-2 bottom-[-8px] h-7 w-7 border-b-2 border-r-2 border-green-500")}></div>
</div>
</div>
</section>
);

export default MissionSectionMobile;
22 changes: 22 additions & 0 deletions src/client/hooks/useIsMobile.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
import { useEffect, useState } from "react";

const SCREEN_BREAKPOINT = 1024;

const useIsMobile = (breakpoint: number = SCREEN_BREAKPOINT) => {
const [isMobile, setIsMobile] = useState(() => window.innerWidth < breakpoint);

useEffect(() => {
const handleResize = () => {
setIsMobile(window.innerWidth < breakpoint);
};

window.addEventListener("resize", handleResize);
return () => {
window.removeEventListener("resize", handleResize);
};
}, [breakpoint]);

return isMobile;
};

export default useIsMobile;
40 changes: 22 additions & 18 deletions src/client/routes/about.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import { cn } from "@/shared/utils";
import AboutCard from "@about/AboutCard";
import ContactForm from "@about/ContactForm";
import HeaderSection from "@about/HeaderSection";
Expand All @@ -22,50 +23,53 @@ export const Route = createFileRoute("/about")({
<div className="mt-5 flex min-h-screen flex-col items-center justify-center overflow-x-hidden bg-white font-redhat">
<div className="w-full max-w-7xl px-4 py-8">
<HeaderSection />

<div className="mb-14 flex justify-center">
<AboutCard />
</div>
<div className="relative flex w-full max-w-7xl justify-center">
<div className="absolute left-[50%] flex space-x-6">

<div className="mt-[-10px] flex w-full max-w-7xl justify-center sm:mt-2">
<div className="flex space-x-4 sm:space-x-6">
<Link
to="/board"
className="rounded-full border border-black bg-saseBlue px-8 py-1 text-center text-sm italic text-white transition duration-300 hover:scale-105"
className="flex h-9 w-28 items-center justify-center whitespace-nowrap rounded-full border border-black bg-saseBlue px-6 py-2 text-xs italic tracking-wide text-white transition duration-300 hover:scale-105 sm:h-10 sm:w-32 sm:px-7 sm:text-sm"
>
Meet Our Board!
</Link>
<Link
to="/sponsors"
className="rounded-full border border-black bg-saseBlue px-8 py-1 text-center text-sm italic text-white transition duration-300 hover:scale-105"
className="flex h-9 w-28 items-center justify-center whitespace-nowrap rounded-full border border-black bg-saseBlue px-6 py-2 text-[11px] italic tracking-wide text-white transition duration-300 hover:scale-105 sm:h-10 sm:w-32 sm:px-7 sm:text-[13px]"
>
View Our Sponsors
</Link>
</div>
</div>
<section className="mb-12 mt-20 flex justify-center">

<section className={cn("mb-12 mt-20 flex justify-center")}>
<YoutubeSection />
</section>
<MissionSection />
<div className="mb-10 flex items-center">
<div className="mr-3 h-12 w-1.5 rounded-sm bg-saseGreen"></div>
<h2 className="font-oswald text-3xl font-semibold text-gray-800">History</h2>
<div className={cn("mb-10 flex items-center")}>
<div className={cn("mr-3 h-12 w-1.5 rounded-sm bg-saseGreen")}></div>
<h2 className={cn("font-oswald text-3xl font-semibold text-gray-800")}>History</h2>
</div>
<section className="mb-6 flex justify-center">
<div className="w-full max-w-5xl">
<section className={cn("mb-6 flex justify-center")}>
<div className={cn("w-full max-w-5xl")}>
<HistorySection />
</div>
</section>

<section className="mb-20">
<div className="mb-8 flex items-center">
<div className="mr-3 h-12 w-1.5 rounded-sm bg-saseGreen"></div>{" "}
<h2 className="font-oswald text-3xl font-semibold text-gray-800">Timeline of Achievements</h2>
<section className={cn("mb-20")}>
<div className={cn("mb-8 flex items-center")}>
<div className={cn("mr-3 h-12 w-1.5 rounded-sm bg-saseGreen")}></div>{" "}
<h2 className={cn("font-oswald text-3xl font-semibold text-gray-800")}>Timeline of Achievements</h2>
</div>
<Timeline />
</section>
<section id="contact" className="mb-12">
<div className="mb-4 flex items-center">
<div className="mr-3 h-12 w-1.5 rounded-sm bg-saseGreen"></div>{" "}
<h2 className="font-oswald text-3xl font-semibold text-gray-800">Contact Us</h2>
<section id="contact" className={cn("mb-12")}>
<div className={cn("mb-4 flex items-center")}>
<div className={cn("mr-3 h-12 w-1.5 rounded-sm bg-saseGreen")}></div>{" "}
<h2 className={cn("font-oswald text-3xl font-semibold text-gray-800")}>Contact Us</h2>
</div>
<ContactForm />
</section>
Expand Down