Skip to content

CW2-37 404 Page #20

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

Merged
merged 27 commits into from
Jul 25, 2024
Merged
Show file tree
Hide file tree
Changes from 25 commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
ee9a017
removed stats card
QuadAces Jun 26, 2024
5a03a62
added description
QuadAces Jun 26, 2024
ba2d84a
changed events to upcomming events
QuadAces Jun 26, 2024
3467cb3
removed resources and contacts completely to remove redunancy (it is …
QuadAces Jun 26, 2024
b642d03
removed imports
QuadAces Jun 26, 2024
cd5f274
changed 04 to 03 to compensate for removed resources
QuadAces Jun 26, 2024
60de018
removed numbers from navbar
QuadAces Jun 27, 2024
cdc995b
halved space between navbar components
QuadAces Jun 27, 2024
b913aa6
shortened about section
QuadAces Jun 27, 2024
6ef6abe
added button for events component
QuadAces Jun 27, 2024
3cd3231
removing numbers
QuadAces Jun 27, 2024
194affa
removing numbers
QuadAces Jun 27, 2024
e8e91bd
removing numbers
QuadAces Jun 27, 2024
c9601a0
removing numbers
QuadAces Jun 27, 2024
4c57d1c
Merge master
derekxu04 Jun 29, 2024
b70b4f5
removed number for resources (sorry trolling)
QuadAces Jul 3, 2024
37891ed
removed numbers for contact us
QuadAces Jul 3, 2024
7ea1a2e
made button smaller and allign to center
QuadAces Jul 3, 2024
b4b60de
added AboutHomepage and removed pinned. Replaced About with AboutHome…
QuadAces Jul 3, 2024
01cf7a9
balanced left side to match right side
QuadAces Jul 3, 2024
36db75e
added Navbar + Footer + 404 page component
QuadAces Jul 3, 2024
11653b5
added details to 404 page
QuadAces Jul 3, 2024
dccb2dc
added more 404 page details
QuadAces Jul 3, 2024
344f27c
added animation
QuadAces Jul 3, 2024
db24e69
removed typo
QuadAces Jul 4, 2024
19aabbe
changed message
QuadAces Jul 25, 2024
e5073a0
changed error message and implemented tailwind transitions
QuadAces Jul 25, 2024
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
42 changes: 42 additions & 0 deletions frontend/src/components/About/AboutHomepage.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
import Link from "next/link";

Check warning on line 1 in frontend/src/components/About/AboutHomepage.tsx

View workflow job for this annotation

GitHub Actions / build

'Link' is defined but never used
import Image from "next/image";
export default function AboutHomePage() {
return (
<section className="py-8 xl:px-24 sm:px-10 px-5" id="about">
<div className="text-center my-10">
<h2 className="font-bold text-6xl">ABOUT</h2>
</div>
<div className="flex justify-center items-center">
<div className="lg:grid grid-cols-6 flex-1 max-w-[90rem]">
{/* LEFT SIDE */}
<div className="col-span-2 md:mx-5">
<div className="flex items-center justify-center">
<Image src="/assets/csesoc_icon.svg" alt="CSESoc Icon" width={150} height={150} />
</div>
<h2 className="text-3xl font-extrabold">CSESoc</h2>
<button className="bg-[#444F6F] w-full my-5 py-2 rounded">Follow</button>
</div>
{/* RIGHT SIDE */}
<div className="col-span-4 lg:mt-0 mt-10">
<div className="rounded border border-[#595F6D] p-5 h-auto">
<p className="text-xs">
csesoc/README<span className="text-[#7A8192]">.md</span>
</p>
<p className="mt-5">
CSESoc is one of the biggest and most active societies at UNSW, catering to over 3500 CSE
students spanning across degrees in Computer Science, Software Engineering,
Bioinformatics and Computer Engineering.
<br/><br/>
We are here to fulfil the social, personal and
professional needs of CSE students, and promote computing through a variety of forms.
<br/><br/>
Learn more <a href="about" className="text-[#3977F9]">about us!</a>
</p>

</div>
</div>
</div>
</div>
</section>
);
}
1 change: 0 additions & 1 deletion frontend/src/components/About/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ const About = () => {
return (
<section className="py-8 xl:px-24 sm:px-10 px-5" id="about">
<div className="text-center my-10">
<p className="text-[#3977F8] font-game text-xl">01</p>
<h2 className="font-bold text-6xl">ABOUT</h2>
</div>
<div className="flex justify-center items-center">
Expand Down
10 changes: 8 additions & 2 deletions frontend/src/components/Event/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,20 @@ const Event = () => {
return (
<section className="py-8 xl:px-24 sm:px-10 px-5" id="events">
<div className="text-center my-10">
<p className="text-[#3977F8] font-game text-xl">02</p>
<h1 className="font-bold text-6xl">EVENTS</h1>
<h1 className="font-bold text-6xl">UPCOMING EVENTS</h1>
</div>
<div className="flex items-center">
<div className="flex flex-col text-center">
<p className="text-center text-3xl">
We run a wide-variety of events for fun, learning new skills and careers. For full
listings, check out the CSESoc Discord or our Facebook page!
</p>
<a href="events">
<button className="mt-10 bg-white border text-[#3977F8] border-[#A7A6E5] text-lg rounded-xl w-[60%] xl:h-12 h-10">
See all events
</button>
</a>
</div>
<div className="bg-blue-500 w-4/5 h-96 ml-80">Placeholder</div>
</div>
</section>
Expand Down
16 changes: 0 additions & 16 deletions frontend/src/components/Landing/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -25,22 +25,6 @@ const Landing = () => {
<p>{'</h2>'}</p>
</div>
</div>
<div className="w-72 font-semibold text-xl lg:block hidden">
<p className="font-bold bg-[#3977F8] inline px-3 py-1">STATS</p>
<hr className="mb-3 mt-5" />
<div className="flex justify-between">
<p>323,000</p>
<p>Members</p>
</div>
<div className="flex justify-between">
<p>300</p>
<p>Team Members</p>
</div>
<div className="flex justify-between">
<p>52</p>
<p>Events held</p>
</div>
</div>
</div>
</section>
);
Expand Down
17 changes: 6 additions & 11 deletions frontend/src/components/Navbar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -24,26 +24,21 @@ const Navbar = () => {
<p className="mt-3 text-xs">C:\INTERNAL STRUCTURE\{path}</p>
</Link>
<div>
<div className="md:flex xl:gap-36 lg:gap-20 md:gap-10 text-right font-bold hidden">
<div className="md:flex xl:gap-18 lg:gap-10 md:gap-5 text-right font-bold hidden">
<Link href="/about">
<p className="text-[0.6rem] text-[#C4C5C8]">01</p>
<div>{'//'} about us</div>
<div className="text-xl">{'//'} about us</div>
</Link>
<Link href="/events">
<p className="text-[0.6rem] text-[#C4C5C8]">02</p>
<div>{'//'} events</div>
<div className="text-xl">{'//'} events</div>
</Link>
<Link href="/resources">
<p className="text-[0.6rem] text-[#C4C5C8]">03</p>
<div>{'//'} resources</div>
<div className="text-xl">{'//'} resources</div>
</Link>
<Link href="/sponsors">
<p className="text-[0.6rem] text-[#C4C5C8]">04</p>
<div>{'//'} sponsors</div>
<div className="text-xl">{'//'} sponsors</div>
</Link>
<Link href="/contact-us">
<p className="text-[0.6rem] text-[#C4C5C8]">05</p>
<div>{'//'} contact us</div>
<div className="text-xl">{'//'} contact us</div>
</Link>
</div>
<div className="md:hidden xl:hidden lg:hidden text-right font-bold block">
Expand Down
32 changes: 24 additions & 8 deletions frontend/src/components/Resources/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

const boxStyling =
'border border-[#595F6D] rounded-lg hover:border-[#788093] hover:bg-[#070034] hover:bg-opacity-75 transition-all duration-300';
const socialsBoxStyling =

Check warning on line 6 in frontend/src/components/Resources/index.tsx

View workflow job for this annotation

GitHub Actions / build

'socialsBoxStyling' is assigned a value but never used
'xl:col-span-1 col-span-3 flex justify-center pt-2 pb-2 border border-[#595F6D] hover:border-[#788093] rounded-lg hover:bg-[#070034] hover:bg-opacity-75 transition-all duration-300';

const Resources = () => {
Expand All @@ -12,15 +12,12 @@
<div className="2xl:w-[90rem] xl:w-[75rem] w-[90%]">
<div className="relative">
<Image src="assets/resources_bg.svg" alt="Background" className="-z-50 absolute" fill />

<div className="text-center my-10">
<p className="text-[#3977F8] font-game text-xl">03</p>
<h2 className="font-bold text-6xl">RESOURCES</h2>
</div>

<div className="py-8 bg-no-repeat bg-center">
<div className="grid grid-cols-4 1 gap-x-9 gap-y-5">

{stage1.map((item: resourceCards) => {
return (
<a
Expand All @@ -30,7 +27,13 @@
className={`col-span-4 p-5 ${boxStyling} flex`}
>
<div className="flex justify-center align-middle items-center pl-2 pr-10">
<Image src={item.svg} alt={item.alt} draggable="false" width={item.width} height={item.height}/>
<Image
src={item.svg}
alt={item.alt}
draggable="false"
width={item.width}
height={item.height}
/>
</div>
<div>
<h2 className="mt-5 text-3xl font-extrabold">{item.title}</h2>
Expand All @@ -48,8 +51,14 @@
target="_blank"
className={`xl:col-span-1 col-span-4 p-5 ${boxStyling}`}
>
<div className='flex align-middle items-center pt-2 pb-4'>
<Image src={item.svg} alt={item.alt} draggable="false" width={item.width} height={item.height}/>
<div className="flex align-middle items-center pt-2 pb-4">
<Image
src={item.svg}
alt={item.alt}
draggable="false"
width={item.width}
height={item.height}
/>
</div>
<div>
<h2 className="mt-5 text-3xl font-extrabold">{item.title}</h2>
Expand All @@ -67,8 +76,15 @@
target="_blank"
className={`md:col-span-2 col-span-4 p-5 ${boxStyling} flex`}
>
<div className='flex align-middle items-center pt-2 pb-4 pr-10'>
<Image src={item.svg} alt={item.alt} draggable="false" width={item.width} height={item.height} className='rounded-md'/>
<div className="flex align-middle items-center pt-2 pb-4 pr-10">
<Image
src={item.svg}
alt={item.alt}
draggable="false"
width={item.width}
height={item.height}
className="rounded-md"
/>
</div>
<div>
<h2 className="mt-5 text-3xl font-extrabold">{item.title}</h2>
Expand Down
1 change: 0 additions & 1 deletion frontend/src/components/Sponsors/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ const Sponsors = () => {
id="sponsors"
>
<div className="text-center">
<p className="text-[#3977F8] font-game text-xl">04</p>
<h2 className="font-bold text-6xl">SUPPORT CSESOC</h2>
</div>
<div className="flex-1 flex justify-center items-center my-20">
Expand Down
29 changes: 29 additions & 0 deletions frontend/src/pages/404.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
import Footer from '@/components/Footer';
import Navbar from '@/components/Navbar';
import { motion } from 'framer-motion';
export default function Custom404() {
return (
<section className="flex flex-col min-h-screen justify-between py-8 xl:px-24 md:px-10 px-5 relative overflow-hidden">
<div className="items-center text-center">
<Navbar />
<h1 className="text-5xl font-bold pt-24">404 - Page Not Found</h1>
<p className="text-4xl pt-10">
Sorry! We can't find the page you're looking for!
<br />
</p>
<motion.div className="opacity-0" whileHover={{ opacity: 1 }} transition={{duration: 0.2}}>
<p className="text-2xl pt-10">
While we may have found some tomfoolery, we haven't found your page :'(
Copy link
Contributor

Choose a reason for hiding this comment

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

Haha I like the animation

I'm wondering if you can do this just with tailwind, don't have to use framer, could potentially be easier and more inline with the rest of the css

Also: I think it would be cool to have some CS themed error messages, maybe even alternate between a few random ones, could be a fun easter egg (e.g. just asking chatgpt lol:

  • Oops! This page must have been garbage collected.
  • Looks like this page hit a segmentation fault.
  • 404 Error: The page you’re looking for has been deprecated.
    etc.

</p>
</motion.div>
<a href="/">
<button className="mt-10 bg-white border text-[#3977F8] border-[#A7A6E5] text-lg rounded-xl w-[30%] xl:h-12 h-10">
Back to safety
</button>
</a>
</div>

<Footer />
</section>
);
}
5 changes: 0 additions & 5 deletions frontend/src/pages/contact-us.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ export default function ContactUs() {
<Navbar />
<section className="py-8 xl:px-24 sm:px-10 px-5" id="contact-us">
<div className="text-center my-10">
<p className="text-[#3977F8] font-game text-xl">05</p>
<h1 className="font-bold text-6xl">CONTACT US</h1>
</div>

Expand Down Expand Up @@ -54,10 +53,6 @@ export default function ContactUs() {
</a>
.
</p>
{/* <iframe
className="w-1/2 h-[80vh] self-center"
src="https://forms.gle/7kk3RRBJbXo3Sip86"
></iframe> */}
</li>
</ul>

Expand Down
10 changes: 4 additions & 6 deletions frontend/src/pages/index.tsx
Original file line number Diff line number Diff line change
@@ -1,16 +1,14 @@
import Landing from '@/components/Landing';
import Sponsors from '@/components/Sponsors/index';
import About from '@/components/About';
import Event from '@/components/Event';
import Resources from '@/components/Resources';
import AboutHomePage from '@/components/About/AboutHomepage';

export default function Home() {
return (
<section>
<Landing/>
<About/>
<Event/>
<Resources />
<Landing />
<AboutHomePage />
<Event />
<Sponsors />
</section>
);
Expand Down
Loading