Skip to content

Commit

Permalink
Fix: make the about us anchor specifically be centred to the section
Browse files Browse the repository at this point in the history
  • Loading branch information
teoh4770 committed Mar 29, 2024
1 parent f006ac6 commit a1ed716
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 7 deletions.
3 changes: 1 addition & 2 deletions src/components/Navbar/NavItems.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ const links = [
const rowStyle = 'flex-row items-center';
const colStyle = 'flex-col lg:p-0';
const navbarHeightPx = 80;
const scrollPaddingPx = -(navbarHeightPx + 20); // navbarHeight + extra padding

const scrollPaddingPx = -navbarHeightPx; // navbarHeight + extra padding

const NavItems: React.FC<NavItemsProps> = ({ isHorizontal, handleClick }) => {
return (
Expand Down
10 changes: 5 additions & 5 deletions src/components/sections/HeroStats.section.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -79,11 +79,11 @@ const HeroStatSection: React.FC = () => {
</p>
</div>
</div>
<div className="absolute left-1/2 top-2/3 w-2/3 -translate-x-1/2 -translate-y-1/2 transform text-[#1D4549] sm:top-[70%] md:top-3/4 ">
<h1
className="mb-5 text-center text-4.5xl uppercase drop-shadow-md lg:text-6.5xl xl:text-7.5xl"
id="about-anchor"
>
<div
id="about-anchor"
className="absolute left-1/2 top-2/3 w-2/3 -translate-x-1/2 -translate-y-1/2 transform pt-24 text-[#1D4549] sm:top-[70%] sm:pt-36 md:top-3/4 md:pt-36 "
>
<h1 className="mb-5 text-center text-4.5xl uppercase drop-shadow-md lg:text-6.5xl xl:text-7.5xl">
About Hawkhacks
</h1>
<div className="space-y-3 text-center text-[#1D4549] lg:space-y-10">
Expand Down

0 comments on commit a1ed716

Please sign in to comment.