feat: projects page, with overhauld portfolio items system

+1 -1
src/components/Badgebar.astro
···
---
<span class="flex gap-2 bg-ctp-crust p-2 pl-3 pr-3 rounded-full h-min">
{badges.map(badge =>
-
<a href=`${badge.href}`>
<LucideIcon name=`${badge.icon}` width=`${size}` height=`${size}` style={`stroke:${badge.color}`}
class="hover:rotate-15 ease-in hover:ease-out transition-transform"
/>
···
---
<span class="flex gap-2 bg-ctp-crust p-2 pl-3 pr-3 rounded-full h-min">
{badges.map(badge =>
+
<a href=`${badge.href}` target="_blank" rel="noopener noreferrer">
<LucideIcon name=`${badge.icon}` width=`${size}` height=`${size}` style={`stroke:${badge.color}`}
class="hover:rotate-15 ease-in hover:ease-out transition-transform"
/>
+22 -4
src/components/PortfolioItem.astro
···
interface Props {
type: string
-
icon: string,
title: string,
subtitle: string,
tag?: string,
tagcolor?: string,
href: string
-
badges: Badge[]
}
const { type, icon, title, subtitle, tag, tagcolor, href, badges } = Astro.props
···
}
const colorCss = "var(" + color + ")"
import LucideIcon from "./LucideIcon.astro";
import Badgebar from "./Badgebar.astro"
import Tag from "./Tag.astro"
···
<div class="flex justify-between gap-16">
<a href=`${href}` class="flex flex-col gap-1 group">
<span class="text-xl flex gap-2 items-center">
-
<LucideIcon name=`${icon}` width="20" height="20" style={`stroke:${colorCss}`} />
<span class="group-hover:underline font-bold">{title} </span>
{tag && tagcolor && (
<Tag text={tag} color={tagcolor} />
···
<span class="flex gap-1">{subtitle}</span>
</span>
</a>
-
<Badgebar badges={badges} size="20"/>
</div>
<div>
<slot/>
···
interface Props {
type: string
+
icon?: string,
title: string,
subtitle: string,
tag?: string,
tagcolor?: string,
href: string
+
badges?: Badge[]
}
const { type, icon, title, subtitle, tag, tagcolor, href, badges } = Astro.props
···
}
const colorCss = "var(" + color + ")"
+
var iconName = icon
+
if (type=="project") {
+
iconName = "Archive"
+
} else if (type=="repo") {
+
iconName = "BookMarked"
+
} else if (type=="team") {
+
iconName = "Users"
+
} else if (type=="misc") {
+
color = "Box"
+
} else if (type=="freelance") {
+
color = "ReceiptText"
+
}
+
+
import LucideIcon from "./LucideIcon.astro";
import Badgebar from "./Badgebar.astro"
import Tag from "./Tag.astro"
···
<div class="flex justify-between gap-16">
<a href=`${href}` class="flex flex-col gap-1 group">
<span class="text-xl flex gap-2 items-center">
+
<LucideIcon name=`${iconName}` width="20" height="20" style={`stroke:${colorCss}`} />
<span class="group-hover:underline font-bold">{title} </span>
{tag && tagcolor && (
<Tag text={tag} color={tagcolor} />
···
<span class="flex gap-1">{subtitle}</span>
</span>
</a>
+
<span>
+
{ badges && (
+
<Badgebar badges={badges} size="20"/>
+
)}
+
</span>
</div>
<div>
<slot/>
+1 -1
src/components/navbar/Navbar.astro
···
<div class="flex gap-6 items-center">
<Btn page="home"/>
<Btn page="projects"/>
-
<Btn page="experience"/>
</div>
</div>
<style>
···
<div class="flex gap-6 items-center">
<Btn page="home"/>
<Btn page="projects"/>
+
<Btn page="gallery"/>
</div>
</div>
<style>
+24
src/components/projects/Dotfiles.astro
···
···
+
---
+
import Item from "../PortfolioItem.astro"
+
export const priority = 1;
+
---
+
<Item
+
type="repo"
+
title="dotfiles"
+
subtitle="My personal configuration dotfiles for endeavouros linux."
+
href="https://tangled.org/@banana.tngl.sh/dotfiles"
+
badges={[
+
{
+
icon: "Github",
+
href: "https://github.com/imabanana80/dotfiles",
+
color: "var(--catppuccin-color-green)"
+
},
+
+
{
+
icon: "Book",
+
href: "https://wiki.archlinux.org/title/Dotfiles",
+
color: "var(--catppuccin-color-sapphire)"
+
},
+
]}
+
/>
+
+28
src/components/projects/IsleStats.astro
···
···
+
---
+
import Item from "../PortfolioItem.astro"
+
---
+
<Item
+
type="project"
+
title="IsleStats"
+
subtitle="An MCC Island Discord statistics bot that renders beautiful stat cards to show off your stats."
+
href="https://islestats.net"
+
tag="Python"
+
tagcolor="--catppuccin-color-blue"
+
badges={[
+
{
+
icon: "Github",
+
href: "https://github.com/islestats",
+
color: "var(--catppuccin-color-green)"
+
},
+
{
+
icon: "MessageCircle",
+
href: "https://discord.gg//islestats",
+
color: "var(--catppuccin-color-blue)"
+
},
+
{
+
icon: "Mail",
+
href: "mailto:contact@islestats.net",
+
color: "var(--catppuccin-color-maroon)"
+
}
+
]}
+
/>
+18
src/components/projects/PassgenAstro.astro
···
···
+
---
+
import Item from "../PortfolioItem.astro"
+
---
+
<Item
+
type="repo"
+
title="passgen-astro"
+
subtitle="Static client-based password phrase generator built with astro."
+
href="https://pass.imabanana80.com"
+
tag="Astro"
+
tagcolor="--catppuccin-color-pink"
+
badges={[
+
{
+
icon: "Github",
+
href: "https://github.com/imabanana80/passgen-astro",
+
color: "var(--catppuccin-color-green)"
+
},
+
]}
+
/>
+29
src/components/projects/PotassiumSh.astro
···
···
+
---
+
import Item from "../PortfolioItem.astro"
+
export const priority = 2;
+
---
+
<Item
+
type="team"
+
title="potassium.sh"
+
subtitle="An indie software development studio for the creative and insane, founded by me!"
+
href="https://tangled.org/@banana.tngl.sh/dotfiles"
+
tag="Founder"
+
tagcolor="--catppuccin-color-rosewater"
+
badges={[
+
{
+
icon: "Mail",
+
href: "mailto:team@potassium.sh",
+
color: "var(--catppuccin-color-maroon)"
+
},
+
{
+
icon: "Spool",
+
href: "https://tangled.org/@potassium.sh",
+
color: "var(--catppuccin-color-lavender)"
+
},
+
{
+
icon: "Bird",
+
href: "https://bsky.app/profile/potassium.sh",
+
color: "var(--catppuccin-color-sapphire)"
+
},
+
]}
+
/>
+18
src/components/projects/SMPSales.astro
···
···
+
---
+
import Item from "../PortfolioItem.astro"
+
---
+
<Item
+
type="team"
+
title="SMP Sales"
+
subtitle="A Minecraft SMP freelancing hub, from developers to artists, all you'll need to start an SMP of your own."
+
href="https://discord.gg/DUa3asXpvs"
+
tag="Developer"
+
tagcolor="--catppuccin-color-rosewater"
+
badges={[
+
{
+
icon: "Github",
+
href: "https://github.com/smpsales",
+
color: "var(--catppuccin-color-green)"
+
},
+
]}
+
/>
+11
src/components/projects/StatusPage.astro
···
···
+
---
+
import Item from "../PortfolioItem.astro"
+
---
+
<Item
+
type="project"
+
title="Status Page"
+
subtitle="A custom status page design that could automatically fetch data from a custom api to display live information."
+
href="https://status.imabanana80.com"
+
tag="Astro"
+
tagcolor="--catppuccin-color-pink"
+
/>
+4 -40
src/components/section/Pinned.astro
···
---
import Label from "../Label.astro"
import Item from "../PortfolioItem.astro"
---
<div class="flex flex-col p-8 border-ctp-surface0 border w-full h-min relative">
<Label name="Pinned"/>
<div class="flex flex-wrap">
-
<Item
-
type="project"
-
title="IsleStats"
-
subtitle="An MCC Island Discord statistics bot that renders beautiful stat cards to show off your stats."
-
icon="Archive"
-
href="https://islestats.net"
-
tag="Python"
-
tagcolor="--catppuccin-color-blue"
-
badges={[
-
{
-
icon: "Github",
-
href: "https://github.com/islestats",
-
color: "var(--catppuccin-color-green)"
-
},
-
{
-
icon: "MessageCircle",
-
href: "https://discord.gg//islestats",
-
color: "var(--catppuccin-color-blue)"
-
},
-
{
-
icon: "Mail",
-
href: "mailto:contact@islestats.net",
-
color: "var(--catppuccin-color-maroon)"
-
}
-
]}
-
/>
<Item
type="team"
title="potassium.sh"
···
},
]}
/>
-
<Item
-
type="repo"
-
title="dotfiles"
-
subtitle="My personal configuration dotfiles for endeavouros linux."
-
icon="BookMarked"
-
href="https://tangled.org/@banana.tngl.sh/dotfiles"
-
badges={[
-
{
-
icon: "Book",
-
href: "https://wiki.archlinux.org/title/Dotfiles",
-
color: "var(--catppuccin-color-sapphire)"
-
},
-
]}
-
/>
</div>
</div>
···
---
import Label from "../Label.astro"
import Item from "../PortfolioItem.astro"
+
import Dotfiles from "../projects/Dotfiles.astro"
+
import IsleStats from "../projects/IsleStats.astro"
---
<div class="flex flex-col p-8 border-ctp-surface0 border w-full h-min relative">
<Label name="Pinned"/>
<div class="flex flex-wrap">
+
<IsleStats/>
<Item
type="team"
title="potassium.sh"
···
},
]}
/>
+
<Dotfiles />
</div>
</div>
+4 -4
src/components/section/Profile.astro
···
<a href="mailto:banana@potassium.sh" class="hover:underline ease-in hover:ease-out transition-all">banana@potassium.sh</a>
</span>
<span class="flex gap-2 bg-ctp-crust p-2 pl-3 pr-3 rounded-full h-min">
-
<a href="https://github.com/imabanana80">
<Github size="20"
-
class="stroke-ctp-green hover:rotate-15 ease-in hover:ease-out transition-transform"/></a>
-
<a href="https://tangled.org/@banana.tngl.sh/">
<Spool size="20"
class="stroke-ctp-lavender hover:rotate-15 ease-in hover:ease-out transition-transform"/></a>
</a>
-
<a href="https://bsky.app/profile/imabanana80.com">
<Icon iconNode={butterfly} size="20"
class="stroke-ctp-sapphire hover:rotate-15 ease-in hover:ease-out transition-transform"/></a>
</span>
···
<a href="mailto:banana@potassium.sh" class="hover:underline ease-in hover:ease-out transition-all">banana@potassium.sh</a>
</span>
<span class="flex gap-2 bg-ctp-crust p-2 pl-3 pr-3 rounded-full h-min">
+
<a href="https://github.com/imabanana80" target="_blank" rel="noopener noreferrer">
<Github size="20"
+
class="stroke-ctp-green hover:rotate-15 ease-in hover:ease-out transition-transform" /></a>
+
<a href="https://tangled.org/@banana.tngl.sh/" target="_blank" rel="noopener noreferrer">
<Spool size="20"
class="stroke-ctp-lavender hover:rotate-15 ease-in hover:ease-out transition-transform"/></a>
</a>
+
<a href="https://bsky.app/profile/imabanana80.com" target="_blank" rel="noopener noreferrer">
<Icon iconNode={butterfly} size="20"
class="stroke-ctp-sapphire hover:rotate-15 ease-in hover:ease-out transition-transform"/></a>
</span>
+19
src/components/section/Projects.astro
···
···
+
---
+
import Label from "../Label.astro"
+
let projects = Object.values(import.meta.glob('../projects/*.astro', { eager: true }));
+
+
projects = projects.sort((a, b) => {
+
const projectA = a.priority ?? Infinity;
+
const projectB = b.priority ?? Infinity;
+
+
return projectA - projectB
+
})
+
---
+
<div class="flex flex-col p-8 border-ctp-surface0 border w-full h-min relative">
+
<Label name="Projects"/>
+
<div class="flex flex-wrap gap-4">
+
{projects.map(Project => (
+
<Project.default />
+
))}
+
</div>
+
</div>
+2
src/pages/projects.astro
···
---
import Page from '../layouts/Page.astro';
---
<Page>
</Page>
···
---
import Page from '../layouts/Page.astro';
+
import ProjectsC from "../components/section/Projects.astro"
---
<Page>
+
<ProjectsC/>
</Page>