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

Add Academic Component #47

Merged
merged 6 commits into from
Jan 22, 2025
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
Binary file added public/about/gradCap.webp
Binary file not shown.
2 changes: 2 additions & 0 deletions src/app/about/page.tsx
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
import WhoWeAre from "@/components/about/WhoWeAre";
import Heading from "@/components/about/FourPillTitle";
import Title from "@/components/Title";
import Academic from "@/components/about/AcademicComponent";

const page = () => {
return (
<div>
<WhoWeAre />
<Heading />
<Title text="about" />
<Academic />
</div>
);
};
Expand Down
21 changes: 21 additions & 0 deletions src/components/about/AcademicComponent.tsx
Copy link
Contributor

Choose a reason for hiding this comment

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

if you see your code, it looks like you're trying to add a background with certain dimensions when you can just use a border and you're trying to have your div start on the right side of the page -- you're overcomplicating it. try referencing this sample code I've written. it's basically your code but more optimized. you'll need to still style the text, etc but this should look more clean.

<div className="flex justify-end">
      <div className="relative h-[12vh] w-[25vw] border-8 border-csa-gray-100 rounded-3xl flex items-center">
         ......
      </div>
</div>

Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
import React from "react";
import Image from "next/image";
import gradCap from "@/public/about/gradCap.webp";

const Academic = () => {
return (
<div className="relative ml-auto mr-28 flex h-[11.9vh] w-[25vw] items-center justify-center rounded-3xl bg-csa-yellow-200">
<div className="absolute flex h-[10.3vh] w-[24vw] items-center rounded-3xl bg-white">
<p className="ml-8 text-6xl font-bold text-csa-gray-100">Academic</p>
<Image
src={gradCap}
alt="gradCap"
className="absolute translate-x-[20%] translate-y-[-9%]"
/>
</div>
<div></div>
</div>
);
};

export default Academic;
Loading