From a74cc775d027c95dd989355126d74a3bc2502ef5 Mon Sep 17 00:00:00 2001
From: Alex Lebens
Date: Sun, 15 Feb 2026 23:38:55 -0600
Subject: [PATCH] feat: final refactor of sections
---
src/components/Header.astro | 4 +-
src/components/blog/BlogLeftSection.astro | 4 +-
src/components/blog/BlogRightSection.astro | 4 +-
.../sections/EducationSection.astro | 2 +-
src/components/sections/Experience.astro | 152 -----------------
.../sections/ExperienceSection.astro | 159 ++++++++++++++++++
src/components/sections/HeaderSection.astro | 4 +-
src/components/sections/HeroSection.astro | 8 +-
...stPosts.astro => LatestPostsSection.astro} | 12 +-
...Slider.astro => SkillsSliderSection.astro} | 100 +++++------
src/components/sections/WeatherSection.astro | 1 -
src/pages/404.astro | 8 +-
src/pages/about.astro | 8 +-
src/pages/blog/[...slug].astro | 4 +-
src/pages/index.astro | 4 +-
src/styles/global.css | 1 +
src/styles/utilities.css | 2 +-
17 files changed, 232 insertions(+), 245 deletions(-)
delete mode 100644 src/components/sections/Experience.astro
create mode 100644 src/components/sections/ExperienceSection.astro
rename src/components/sections/{LatestPosts.astro => LatestPostsSection.astro} (77%)
rename src/components/sections/{SkillsSlider.astro => SkillsSliderSection.astro} (57%)
diff --git a/src/components/Header.astro b/src/components/Header.astro
index 5663548..dbd5a2c 100644
--- a/src/components/Header.astro
+++ b/src/components/Header.astro
@@ -1,6 +1,6 @@
---
import BrandLogo from '@components/ui/logos/BrandLogo.astro';
-import ThemeToggle from '@components/buttons/ThemeToggle.astro';
+import ThemeToggleButton from '@components/buttons/ThemeToggleButton.astro';
import { NavigationLinks } from '@/config';
const pathname = new URL(Astro.request.url).pathname;
@@ -90,7 +90,7 @@ const currentPath = pathname.slice(1);
})
}
-
+
diff --git a/src/components/blog/BlogLeftSection.astro b/src/components/blog/BlogLeftSection.astro
index 5b761a7..61710f6 100644
--- a/src/components/blog/BlogLeftSection.astro
+++ b/src/components/blog/BlogLeftSection.astro
@@ -1,5 +1,5 @@
---
-import GoLinkPrimary from '@components/buttons/GoLinkPrimary.astro';
+import GoLinkPrimaryButton from '@components/buttons/GoLinkPrimaryButton.astro';
import Image from '@components/ui/images/Image.astro';
interface Props {
@@ -39,6 +39,6 @@ const { title, subTitle, btnExists, btnTitle, btnURL, img, imgAlt } = Astro.prop
>
{subTitle}
- {btnExists ? : null}
+ {btnExists ? : null}
diff --git a/src/components/blog/BlogRightSection.astro b/src/components/blog/BlogRightSection.astro
index 1501902..2e2accc 100644
--- a/src/components/blog/BlogRightSection.astro
+++ b/src/components/blog/BlogRightSection.astro
@@ -1,5 +1,5 @@
---
-import GoLinkPrimary from '@components/buttons/GoLinkPrimary.astro';
+import GoLinkPrimaryButton from '@components/buttons/GoLinkPrimaryButton.astro';
import Image from '@components/ui/images/Image.astro';
interface Props {
@@ -43,7 +43,7 @@ const {
>
{subTitle}
- {btnExists ? : null}
+ {btnExists ? : null}
{
diff --git a/src/components/sections/EducationSection.astro b/src/components/sections/EducationSection.astro
index a635c54..77b6bd6 100644
--- a/src/components/sections/EducationSection.astro
+++ b/src/components/sections/EducationSection.astro
@@ -27,7 +27,7 @@ const certificates = ((await directus.request(
Education
-
diff --git a/src/components/sections/LatestPosts.astro b/src/components/sections/LatestPostsSection.astro
similarity index 77%
rename from src/components/sections/LatestPosts.astro
rename to src/components/sections/LatestPostsSection.astro
index 5c250c6..d0c32e9 100644
--- a/src/components/sections/LatestPosts.astro
+++ b/src/components/sections/LatestPostsSection.astro
@@ -1,8 +1,9 @@
---
import { readItems } from '@directus/sdk';
-import directus from '@lib/directus';
import type { Post } from '@lib/directusTypes';
+
+import directus from '@lib/directus';
import BlogCard from '@components/blog/BlogCard.astro';
const posts = await directus.request(
@@ -20,11 +21,14 @@ const recentPosts = posts
{recentPosts.map((b) =>
)}
diff --git a/src/components/sections/SkillsSlider.astro b/src/components/sections/SkillsSliderSection.astro
similarity index 57%
rename from src/components/sections/SkillsSlider.astro
rename to src/components/sections/SkillsSliderSection.astro
index 0ff10df..9f600c3 100644
--- a/src/components/sections/SkillsSlider.astro
+++ b/src/components/sections/SkillsSliderSection.astro
@@ -6,86 +6,63 @@ import type { Skill } from '@lib/directusTypes';
import directus from '@lib/directus';
-const skills = await directus.request(
- readItems('site_skills', {
+const skills = ((await directus.request(
+ readItems('site_skills' as any, {
fields: ['*'],
sort: ['-date_created'],
})
-);
-
-const baseClasses = 'mx-2 min-w-[220px] sm:mx-4 sm:min-w-[280px]';
-const borderClasses =
- 'border border-neutral-100 hover:border-neutral-200 dark:border-stone-500/20 dark:hover:border-neutral-800';
-const bgColorClasses = 'bg-neutral-100/80 dark:bg-neutral-800/60 dark:hover:bg-neutral-800/90';
-const hoverClasses = 'hover:-translate-y-2 hover:scale-105 ';
-const shadowClasses = 'shadow-xs hover:shadow-lg';
+)) as unknown) as Skill[];
---
-
+
- {
- [...skills, ...skills, ...skills].map((skill: Skill) => {
- return (
-
-
-
-
-
-
-
-
- {skill.title}
-
-
-
- {skill.level}%
-
-
-
-
-
-
- Beginner
- Advanced
-
+ {[...skills, ...skills, ...skills].map((skill: Skill) => {
+ return (
+
+ );
+ })}
-
-
-
-
-
+
+