refactor: remove unused props from section components for cleaner code

This commit is contained in:
2025-06-15 15:04:37 -05:00
parent fec7fb62de
commit 5f900bbceb
9 changed files with 6 additions and 54 deletions

View File

@@ -203,21 +203,14 @@ const App = () => {
isDarkMode={isDarkMode}
scrollToSection={scrollToSection}
textClasses={textClasses}
cardClasses={cardClasses}
/>
{/* About Section */}
<AboutSection
isDarkMode={isDarkMode}
scrollToSection={scrollToSection}
textClasses={textClasses}
cardClasses={cardClasses}
/>
<AboutSection textClasses={textClasses} cardClasses={cardClasses} />
{/* Academic Section */}
<AcademicSection
isDarkMode={isDarkMode}
scrollToSection={scrollToSection}
textClasses={textClasses}
cardClasses={cardClasses}
/>
@@ -225,7 +218,6 @@ const App = () => {
{/* Tech Section */}
<TechSection
isDarkMode={isDarkMode}
scrollToSection={scrollToSection}
textClasses={textClasses}
cardClasses={cardClasses}
/>
@@ -233,23 +225,16 @@ const App = () => {
{/* Leadership Section */}
<LeadershipSection
isDarkMode={isDarkMode}
scrollToSection={scrollToSection}
textClasses={textClasses}
cardClasses={cardClasses}
/>
{/* Athletics Section */}
<AthleticsSection
isDarkMode={isDarkMode}
scrollToSection={scrollToSection}
textClasses={textClasses}
cardClasses={cardClasses}
/>
<AthleticsSection isDarkMode={isDarkMode} textClasses={textClasses} />
{/* Entrepreneurship Section */}
<EntrepreneurshipSection
isDarkMode={isDarkMode}
scrollToSection={scrollToSection}
textClasses={textClasses}
cardClasses={cardClasses}
/>
@@ -262,12 +247,7 @@ const App = () => {
/>
{/* Footer */}
<Footer
isDarkMode={isDarkMode}
scrollToSection={scrollToSection}
textClasses={textClasses}
cardClasses={cardClasses}
/>
<Footer isDarkMode={isDarkMode} textClasses={textClasses} />
</div>
);
};

View File

@@ -1,18 +1,11 @@
import { Zap, Users, Rocket } from "lucide-react";
interface AboutSectionProps {
isDarkMode: boolean;
scrollToSection: (sectionId: string) => void;
textClasses: string;
cardClasses: string;
}
const AboutSection = ({
isDarkMode,
scrollToSection,
textClasses,
cardClasses,
}: AboutSectionProps) => {
const AboutSection = ({ textClasses, cardClasses }: AboutSectionProps) => {
return (
<section id="about" className="relative py-20">
<div className="max-w-6xl px-6 mx-auto">

View File

@@ -2,14 +2,12 @@ import { Trophy, Award, Star } from "lucide-react";
interface AcademicSectionProps {
isDarkMode: boolean;
scrollToSection: (sectionId: string) => void;
textClasses: string;
cardClasses: string;
}
const AcademicSection = ({
isDarkMode,
scrollToSection,
textClasses,
cardClasses,
}: AcademicSectionProps) => {

View File

@@ -1,15 +1,11 @@
interface AthleticsSectionProps {
isDarkMode: boolean;
scrollToSection: (sectionId: string) => void;
textClasses: string;
cardClasses: string;
}
const AthleticsSection = ({
isDarkMode,
scrollToSection,
textClasses,
cardClasses,
}: AthleticsSectionProps) => {
return (
<section id="athletics" className="py-20">

View File

@@ -2,14 +2,12 @@ import { Rocket, Zap } from "lucide-react";
interface EntrepreneurshipSectionProps {
isDarkMode: boolean;
scrollToSection: (sectionId: string) => void;
textClasses: string;
cardClasses: string;
}
const EntrepreneurshipSection = ({
isDarkMode,
scrollToSection,
textClasses,
cardClasses,
}: EntrepreneurshipSectionProps) => {

View File

@@ -1,16 +1,9 @@
interface FooterProps {
isDarkMode: boolean;
scrollToSection: (sectionId: string) => void;
textClasses: string;
cardClasses: string;
}
const Footer = ({
isDarkMode,
scrollToSection,
textClasses,
cardClasses,
}: FooterProps) => {
const Footer = ({ isDarkMode, textClasses }: FooterProps) => {
return (
<footer
className={`py-12 ${

View File

@@ -1,17 +1,15 @@
import { ChevronDown, Trophy, Code, Users, Zap, Rocket } from "lucide-react";
import { ChevronDown, Trophy, Code, Rocket } from "lucide-react";
interface HeroSectionProps {
isDarkMode: boolean;
scrollToSection: (sectionId: string) => void;
textClasses: string;
cardClasses: string;
}
const HeroSection = ({
isDarkMode,
scrollToSection,
textClasses,
cardClasses,
}: HeroSectionProps) => {
return (
<section

View File

@@ -2,14 +2,12 @@ import { Award, Star, Users } from "lucide-react";
interface LeadershipSectionProps {
isDarkMode: boolean;
scrollToSection: (sectionId: string) => void;
textClasses: string;
cardClasses: string;
}
const LeadershipSection = ({
isDarkMode,
scrollToSection,
textClasses,
cardClasses,
}: LeadershipSectionProps) => {

View File

@@ -2,14 +2,12 @@ import { Code, Trophy } from "lucide-react";
interface TechSectionProps {
isDarkMode: boolean;
scrollToSection: (sectionId: string) => void;
textClasses: string;
cardClasses: string;
}
const TechSection = ({
isDarkMode,
scrollToSection,
textClasses,
cardClasses,
}: TechSectionProps) => {