mirror of
https://github.com/xHyroM/website.git
synced 2024-11-21 14:41:04 +01:00
refactor: cleanup
This commit is contained in:
parent
016872e3af
commit
c4b15d1fad
25 changed files with 452 additions and 482 deletions
|
@ -1,2 +1,2 @@
|
|||
dist/*
|
||||
node_modules/*
|
||||
dist/**
|
||||
node_modules/**
|
|
@ -17,6 +17,10 @@ import prefetch from "@astrojs/prefetch";
|
|||
import robotsTxt from "astro-robots-txt";
|
||||
import minify from "./astro-integrations/minify";
|
||||
|
||||
import { dirname, resolve } from "node:path";
|
||||
import { fileURLToPath } from "node:url";
|
||||
const __dirname = dirname(fileURLToPath(import.meta.url));
|
||||
|
||||
// https://astro.build/config
|
||||
export default defineConfig({
|
||||
site: "https://xhyrom.dev/",
|
||||
|
@ -40,4 +44,15 @@ export default defineConfig({
|
|||
}),
|
||||
minify(),
|
||||
],
|
||||
vite: {
|
||||
resolve: {
|
||||
alias: {
|
||||
"~": resolve(__dirname, "./src"),
|
||||
"@pages": resolve(__dirname, "./src/pages"),
|
||||
"@assets": resolve(__dirname, "./src/assets"),
|
||||
"@layouts": resolve(__dirname, "./src/layouts"),
|
||||
"@components": resolve(__dirname, "./src/components"),
|
||||
},
|
||||
},
|
||||
},
|
||||
});
|
||||
|
|
|
@ -1,39 +0,0 @@
|
|||
---
|
||||
const { schemaOrg } = Astro.props;
|
||||
---
|
||||
|
||||
<meta charset="UTF-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<!-- Primary Meta Tags -->
|
||||
<title>xHyroM</title>
|
||||
<link rel="icon" type="image/x-icon" href="/favicon.ico" />
|
||||
<meta name="title" content="xHyroM" />
|
||||
<meta name="description" content="I'm Hyro :) o/" />
|
||||
<meta name="keywords" content="xhyrom developer dev hyro hyrousek" />
|
||||
|
||||
<!-- Open Graph / Facebook -->
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:url" content="https://xhyrom.dev/" />
|
||||
<meta property="og:title" content="xHyroM" />
|
||||
<meta property="og:description" content="I'm Hyro :) o/" />
|
||||
<meta property="og:image" content="/banner.png" />
|
||||
|
||||
<!-- Twitter -->
|
||||
<meta property="twitter:card" content="summary_large_image" />
|
||||
<meta property="twitter:url" content="https://xhyrom.dev/" />
|
||||
<meta property="twitter:title" content="xHyroM" />
|
||||
<meta property="twitter:description" content="I'm Hyro :) o/" />
|
||||
<meta property="twitter:image" content="/banner.png" />
|
||||
|
||||
<!-- CSP -->
|
||||
<meta
|
||||
http-equiv="Content-Security-Policy"
|
||||
content="img-src 'self'; font-src *; style-src 'self' 'unsafe-inline' fonts.googleapis.com; script-src 'self' 'unsafe-inline'; object-src 'none'"
|
||||
/>
|
||||
|
||||
{
|
||||
schemaOrg && (
|
||||
<script type="application/ld+json" set:html={JSON.stringify(schemaOrg)} />
|
||||
)
|
||||
}
|
24
src/components/widgets/SEOEmbed.astro
Normal file
24
src/components/widgets/SEOEmbed.astro
Normal file
|
@ -0,0 +1,24 @@
|
|||
---
|
||||
const { url, title, description, image } = {
|
||||
// default values
|
||||
url: "https://xhyrom.dev/",
|
||||
title: "xHyroM",
|
||||
description: "I'm Hyro :) o/",
|
||||
image: "/banner.png",
|
||||
...Astro.props,
|
||||
};
|
||||
---
|
||||
|
||||
<!-- Open Graph / Facebook -->
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:url" content={url} />
|
||||
<meta property="og:title" content={title} />
|
||||
<meta property="og:description" content={description} />
|
||||
<meta property="og:image" content="/banner.png" />
|
||||
|
||||
<!-- Twitter -->
|
||||
<meta property="twitter:card" content="summary_large_image" />
|
||||
<meta property="twitter:url" content={url} />
|
||||
<meta property="twitter:title" content={title} />
|
||||
<meta property="twitter:description" content={description} />
|
||||
<meta property="twitter:image" content="/banner.png" />
|
|
@ -1,61 +0,0 @@
|
|||
---
|
||||
const url = Astro.url.pathname;
|
||||
const { title, date } = Astro.props;
|
||||
---
|
||||
|
||||
<meta charset="UTF-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<!-- Primary Meta Tags -->
|
||||
<title>xHyroM</title>
|
||||
<link rel="icon" type="image/x-icon" href="/favicon.ico" />
|
||||
<meta name="title" content="xHyroM" />
|
||||
<meta name="description" content={title} />
|
||||
<meta name="keywords" content="xhyrom developer dev hyro hyrousek" />
|
||||
|
||||
<!-- Open Graph / Facebook -->
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:url" content={`https://xhyrom.dev${url}`} />
|
||||
<meta property="og:title" content="xHyroM" />
|
||||
<meta property="og:description" content={title} />
|
||||
<meta property="og:image" content="/banner.png" />
|
||||
|
||||
<!-- Twitter -->
|
||||
<meta property="twitter:card" content="summary_large_image" />
|
||||
<meta property="twitter:url" content={`https://xhyrom.dev${url}`} />
|
||||
<meta property="twitter:title" content="xHyroM" />
|
||||
<meta property="twitter:description" content={title} />
|
||||
<meta property="twitter:image" content="/banner.png" />
|
||||
|
||||
<!-- CSP -->
|
||||
<meta
|
||||
http-equiv="Content-Security-Policy"
|
||||
content="img-src 'self'; font-src *; style-src 'self' 'unsafe-inline' fonts.googleapis.com; script-src 'self' 'unsafe-inline'; object-src 'none'"
|
||||
/>
|
||||
|
||||
<script
|
||||
type="application/ld+json"
|
||||
set:html={JSON.stringify({
|
||||
"@context": "https://schema.org",
|
||||
"@type": "BlogPosting",
|
||||
mainEntityOfPage: {
|
||||
"@type": "WebPage",
|
||||
"@id": `https://xhyrom.dev${url}`,
|
||||
},
|
||||
headline: title,
|
||||
description: title,
|
||||
image: "https://xhyrom.dev/banner.png",
|
||||
author: {
|
||||
"@type": "Person",
|
||||
name: "xHyroM",
|
||||
url: "https://xhyrom.dev",
|
||||
},
|
||||
publisher: {
|
||||
"@type": "Person",
|
||||
name: "xHyroM",
|
||||
url: "https://xhyrom.dev"
|
||||
},
|
||||
datePublished: new Date(date).toISOString().split("T")[0],
|
||||
dateModified: new Date(date).toISOString().split("T")[0],
|
||||
})}
|
||||
></script>
|
|
@ -3,58 +3,58 @@ import type { MarkdownInstance } from "astro";
|
|||
|
||||
import rightArrow from "../../../../public/icons/chevrons-right.svg";
|
||||
|
||||
const files = await Astro.glob("../../../pages/docs/items/**/*.md");
|
||||
const files = await Astro.glob("@pages/docs/items/**/*.md");
|
||||
|
||||
const sections = files.reduce((acc, file) => {
|
||||
const category: string = file.url!.split("/")[3];
|
||||
const category: string = file.url!.split("/")[3];
|
||||
|
||||
if (!acc[category]) acc[category] = [];
|
||||
if (!acc[category]) acc[category] = [];
|
||||
|
||||
acc[category].push(file);
|
||||
acc[category].push(file);
|
||||
|
||||
return acc;
|
||||
return acc;
|
||||
}, {} as Record<string, MarkdownInstance<Record<string, any>>[]>);
|
||||
|
||||
const categories = Object.keys(sections);
|
||||
---
|
||||
|
||||
<aside aria-label="Sidebar">
|
||||
<div class="absolute z-10 text-white md:hidden">
|
||||
<button id="sidebar-show" class="p-4 pl-2">
|
||||
<span class="sr-only">sidebar menu</span>
|
||||
<img
|
||||
src={rightArrow}
|
||||
alt="sidebar hamburger menu icon"
|
||||
id="open-arrow"
|
||||
class="h-6 w-6 duration-200"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<nav
|
||||
id="sidebar"
|
||||
class="invisible absolute mt-6 mr-16 w-full -translate-x-full bg-dark py-4 transition-transform duration-200 md:visible md:relative md:mt-0 md:inline md:translate-x-0 md:bg-transparent"
|
||||
>
|
||||
<ul class="overflow-y-auto overflow-x-visible">
|
||||
{
|
||||
categories.map((category) => (
|
||||
<li>
|
||||
<div class="pt-5">
|
||||
<h1 class="w-full text-2xl font-extrabold text-white ">
|
||||
{category}
|
||||
</h1>
|
||||
<ul>
|
||||
{sections[category].map((section) => (
|
||||
<li class="my-2 rounded-sm p-2 text-white transition-colors duration-150 hover:bg-white/20">
|
||||
<a href={section.url} class="px-4">
|
||||
{section.frontmatter.title}
|
||||
</a>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</div>
|
||||
</li>
|
||||
))
|
||||
}
|
||||
</ul>
|
||||
</nav>
|
||||
<div class="absolute z-10 text-white md:hidden">
|
||||
<button id="sidebar-show" class="p-4 pl-2">
|
||||
<span class="sr-only">sidebar menu</span>
|
||||
<img
|
||||
src={rightArrow}
|
||||
alt="sidebar hamburger menu icon"
|
||||
id="open-arrow"
|
||||
class="h-6 w-6 duration-200"
|
||||
/>
|
||||
</button>
|
||||
</div>
|
||||
<nav
|
||||
id="sidebar"
|
||||
class="invisible absolute mr-16 mt-6 w-full -translate-x-full bg-dark py-4 transition-transform duration-200 md:visible md:relative md:mt-0 md:inline md:translate-x-0 md:bg-transparent"
|
||||
>
|
||||
<ul class="overflow-y-auto overflow-x-visible">
|
||||
{
|
||||
categories.map((category) => (
|
||||
<li>
|
||||
<div class="pt-5">
|
||||
<h1 class="w-full text-2xl font-extrabold text-white ">
|
||||
{category}
|
||||
</h1>
|
||||
<ul>
|
||||
{sections[category].map((section) => (
|
||||
<li class="my-2 rounded-sm p-2 text-white transition-colors duration-150 hover:bg-white/20">
|
||||
<a href={section.url} class="px-4">
|
||||
{section.frontmatter.title}
|
||||
</a>
|
||||
</li>
|
||||
))}
|
||||
</ul>
|
||||
</div>
|
||||
</li>
|
||||
))
|
||||
}
|
||||
</ul>
|
||||
</nav>
|
||||
</aside>
|
||||
|
|
|
@ -1,25 +0,0 @@
|
|||
---
|
||||
import Socials from "./Socials.astro";
|
||||
import { Picture } from "@astrojs/image/components";
|
||||
import logo from "../../../assets/logo.png";
|
||||
import Name from "./Name.astro";
|
||||
---
|
||||
|
||||
<main
|
||||
class="mt-24 flex flex-col items-center justify-center md:mt-64 md:flex-row"
|
||||
>
|
||||
<div class="justify-cener flex items-center">
|
||||
<Picture
|
||||
src={logo}
|
||||
formats={["png"]}
|
||||
sizes="(max-width: 200px) 100vw, 200px"
|
||||
widths={[200, 400]}
|
||||
alt="descriptive text"
|
||||
class={"h-[200px] w-[200px]"}
|
||||
/>
|
||||
</div>
|
||||
<section class="text-center md:ml-6 md:text-left">
|
||||
<Name />
|
||||
<Socials />
|
||||
</section>
|
||||
</main>
|
|
@ -1,3 +0,0 @@
|
|||
<div class="flex drop-shadow-yellow">
|
||||
<h1 class="text-6xl font-extrabold text-white">xHyroM</h1>
|
||||
</div>
|
|
@ -1,45 +0,0 @@
|
|||
---
|
||||
const socials = [
|
||||
{
|
||||
name: "GitHub",
|
||||
link: "https://github.com/xHyroM/",
|
||||
icon: "github.svg",
|
||||
},
|
||||
{
|
||||
name: "Discord.svg",
|
||||
link: "https://s.xhyrom.dev/discord",
|
||||
icon: "discord.svg",
|
||||
},
|
||||
{
|
||||
name: "Twitter",
|
||||
link: "https://twitter.com/hyrousek/",
|
||||
icon: "twitter.svg",
|
||||
},
|
||||
{
|
||||
name: "Instagram",
|
||||
link: "https://www.instagram.com/hyro.dev/",
|
||||
icon: "instagram.svg",
|
||||
},
|
||||
{
|
||||
name: "ko-fi",
|
||||
link: "https://ko-fi.com/xhyrom",
|
||||
icon: "ko-fi.png",
|
||||
},
|
||||
];
|
||||
---
|
||||
|
||||
<ul class="my-5 flex justify-center text-white md:justify-start">
|
||||
{
|
||||
socials.map((social) => (
|
||||
<li class="mr-4 ">
|
||||
<a class="h-10 w-10" href={social.link} title={social.name}>
|
||||
<img
|
||||
class="h-8 w-8 transition-all hover:-translate-y-1"
|
||||
src={`/icons/${social.icon}`}
|
||||
alt={`${social.name} icon`}
|
||||
/>
|
||||
</a>
|
||||
</li>
|
||||
))
|
||||
}
|
||||
</ul>
|
220
src/config.ts
Normal file
220
src/config.ts
Normal file
|
@ -0,0 +1,220 @@
|
|||
export const socials = [
|
||||
{
|
||||
name: "GitHub",
|
||||
link: "https://github.com/xHyroM/",
|
||||
icon: "github.svg",
|
||||
},
|
||||
{
|
||||
name: "Discord.svg",
|
||||
link: "https://s.xhyrom.dev/discord",
|
||||
icon: "discord.svg",
|
||||
},
|
||||
{
|
||||
name: "Twitter",
|
||||
link: "https://twitter.com/hyrousek/",
|
||||
icon: "twitter.svg",
|
||||
},
|
||||
{
|
||||
name: "Instagram",
|
||||
link: "https://www.instagram.com/hyro.dev/",
|
||||
icon: "instagram.svg",
|
||||
},
|
||||
{
|
||||
name: "ko-fi",
|
||||
link: "https://ko-fi.com/xhyrom",
|
||||
icon: "ko-fi.png",
|
||||
},
|
||||
] as {
|
||||
name: string;
|
||||
link: string;
|
||||
icon: string;
|
||||
}[];
|
||||
|
||||
export const skills = [
|
||||
{
|
||||
name: "TypeScript",
|
||||
icon: "logos:typescript-icon",
|
||||
},
|
||||
{
|
||||
name: "JavaScript",
|
||||
icon: "logos:javascript",
|
||||
},
|
||||
{
|
||||
name: "Bun",
|
||||
icon: "logos:bun",
|
||||
},
|
||||
{
|
||||
name: "NodeJS",
|
||||
icon: "logos:nodejs-icon-alt",
|
||||
},
|
||||
{
|
||||
name: "Deno",
|
||||
icon: "logos:deno",
|
||||
},
|
||||
{
|
||||
name: "React",
|
||||
icon: "logos:react",
|
||||
},
|
||||
{
|
||||
name: "NextJS",
|
||||
icon: "file-icons:nextjs",
|
||||
},
|
||||
{
|
||||
name: "Astro",
|
||||
icon: "vscode-icons:file-type-astro",
|
||||
},
|
||||
{
|
||||
name: "TailwindCSS",
|
||||
icon: "logos:tailwindcss-icon",
|
||||
},
|
||||
{
|
||||
name: "Java",
|
||||
icon: "logos:java",
|
||||
},
|
||||
{
|
||||
name: "Kotlin",
|
||||
icon: "logos:kotlin-icon",
|
||||
},
|
||||
{
|
||||
name: "Rust",
|
||||
icon: "vscode-icons:file-type-rust",
|
||||
},
|
||||
{
|
||||
name: "Go",
|
||||
icon: "vscode-icons:file-type-go-aqua",
|
||||
},
|
||||
{
|
||||
name: "MySQL",
|
||||
icon: "logos:mysql-icon",
|
||||
},
|
||||
{
|
||||
name: "MongoDB",
|
||||
icon: "devicon:mongodb",
|
||||
},
|
||||
{
|
||||
name: "Redis",
|
||||
icon: "devicon:redis",
|
||||
},
|
||||
{
|
||||
name: "Git",
|
||||
icon: "logos:git-icon",
|
||||
},
|
||||
{
|
||||
name: "GitHub",
|
||||
icon: "mdi:github",
|
||||
},
|
||||
{
|
||||
name: "GitHub Actions",
|
||||
icon: "devicon:githubactions",
|
||||
},
|
||||
{
|
||||
name: "Cloudflare",
|
||||
icon: "logos:cloudflare",
|
||||
},
|
||||
{
|
||||
name: "Cloudflare Pages",
|
||||
icon: "simple-icons:cloudflarepages",
|
||||
color: "#f48120",
|
||||
},
|
||||
{
|
||||
name: "Cloudflare Workers",
|
||||
icon: "logos:cloudflare-workers-icon",
|
||||
},
|
||||
{
|
||||
name: "Visual Studio Code",
|
||||
icon: "logos:visual-studio-code",
|
||||
},
|
||||
{
|
||||
name: "IntelliJ IDEA",
|
||||
icon: "logos:intellij-idea",
|
||||
},
|
||||
] as {
|
||||
name: string;
|
||||
icon: string;
|
||||
}[];
|
||||
|
||||
export const projects = [
|
||||
{
|
||||
name: "HyLib",
|
||||
link: "https://github.com/xHyroM/HyLib",
|
||||
desc: "Source code for HyLib, a paper plugin and powerful library.",
|
||||
},
|
||||
{
|
||||
name: "HyChat",
|
||||
link: "https://github.com/xHyroM/HyChat",
|
||||
desc: "Source code for HyChat, a paper plugin.",
|
||||
},
|
||||
{
|
||||
name: "HyX",
|
||||
link: "https://github.com/xHyroM/HyX",
|
||||
desc: "Lorem ipsum dolor sit amet consectetur adipisicing elit. Cumque, quaerat.",
|
||||
},
|
||||
{
|
||||
name: "Mashe",
|
||||
link: "https://github.com/xHyroM/mashe",
|
||||
desc: "Simple, fast, and easy to use Event Handling for Java.",
|
||||
},
|
||||
{
|
||||
name: "Mumblum",
|
||||
link: "https://github.com/xHyroM/mumblum",
|
||||
desc: "Mumblum is a simple, modern discord bot in JDA.",
|
||||
},
|
||||
{
|
||||
name: "setup-bun",
|
||||
link: "https://github.com/oven-sh/setup-bun",
|
||||
desc: "Set up your GitHub Actions workflow with a specific version of Bun.",
|
||||
},
|
||||
{
|
||||
name: "Roles Bot",
|
||||
link: "https://github.com/xHyroM/roles-bot",
|
||||
desc: 'Discord bot for "button" roles, using Cloudflare Workers.',
|
||||
},
|
||||
{
|
||||
name: "Bun Discord Bot",
|
||||
link: "https://github.com/xHyroM/bun-discord-bot",
|
||||
desc: "Official serverless discord bot for bun discord server.",
|
||||
},
|
||||
{
|
||||
name: "hykord",
|
||||
link: "https://github.com/xHyroM/hykord",
|
||||
desc: "My @discord client modification.",
|
||||
},
|
||||
{
|
||||
name: "frog",
|
||||
link: "https://github.com/xHyroM/frog",
|
||||
desc: "Frog is an extremely simple language based on the monkey language.",
|
||||
},
|
||||
{
|
||||
name: "lsx",
|
||||
link: "https://github.com/xHyroM/lsx",
|
||||
desc: "Lsx is a simple, fast, and easy to use ls implementation in Rust.",
|
||||
},
|
||||
{
|
||||
name: "Slovensko v Grafoch",
|
||||
link: "https://github.com/xHyroM/slovensko-v-grafoch",
|
||||
desc: "Slovensko v Grafoch is a website that shows data about Slovakia in graphs.",
|
||||
},
|
||||
{
|
||||
name: "Peddler's Pocket",
|
||||
link: "https://github.com/xHyroM/peddlerspocket",
|
||||
desc: "/sell command that allows you to put things into GUI and then sell them by closing",
|
||||
},
|
||||
{
|
||||
name: "Peak Pursuit",
|
||||
link: "https://github.com/xHyroM/peakpursuit",
|
||||
desc: "PeakPursuit is a plugin for King of the Hill events that adds a competitive edge to your server gameplay. Conquer the hill and claim the crown!",
|
||||
},
|
||||
{
|
||||
name: "Spawner Genz",
|
||||
link: "https://github.com/xHyroM/spawnergenz",
|
||||
desc: "Spawner Genz is a plugin that modifies the functionality of spawners so that they don't spawn entities, but instead store drops in a virtual storag in which you can then sell or move everything to your inventory.",
|
||||
},
|
||||
] as {
|
||||
name: string;
|
||||
link: string;
|
||||
desc: string;
|
||||
stats?: {
|
||||
forks: number;
|
||||
stars: number;
|
||||
};
|
||||
}[];
|
|
@ -1,31 +1,49 @@
|
|||
---
|
||||
import Snow from "../components/widgets/Snow.astro";
|
||||
import Fireworks from "../components/widgets/Fireworks.astro";
|
||||
import DefaultHead from "../components/widgets/Head.astro";
|
||||
import SEOEmbed from "@components/widgets/SEOEmbed.astro";
|
||||
|
||||
const date = new Date();
|
||||
|
||||
const fireworks =
|
||||
(date.getMonth() === 11 && date.getDate() === 31) ||
|
||||
(date.getMonth() === 0 && date.getDate() <= 3);
|
||||
const snow =
|
||||
(date.getMonth() === 11 && date.getDate() === 10) ||
|
||||
(date.getMonth() === 0 && date.getDate() <= 3);
|
||||
|
||||
const { head } = Astro.props;
|
||||
const Head = head || DefaultHead;
|
||||
const { title, description, keywords, schemaOrg } = {
|
||||
title: "xHyroM",
|
||||
description: "I'm Hyro :) o/",
|
||||
keywords: "xhyrom developer dev hyro hyrousek",
|
||||
...Astro.props,
|
||||
};
|
||||
---
|
||||
|
||||
<!DOCTYPE html>
|
||||
<html lang="en-US">
|
||||
<head>
|
||||
<Head {...Astro.props} />
|
||||
<meta charset="UTF-8" />
|
||||
<meta http-equiv="X-UA-Compatible" content="IE=edge" />
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
||||
<!-- Primary Meta Tags -->
|
||||
<title>{title}</title>
|
||||
<link rel="icon" type="image/x-icon" href="/favicon.ico" />
|
||||
<meta name="title" content={title} />
|
||||
<meta name="description" content={description} />
|
||||
<meta name="keywords" content={keywords} />
|
||||
|
||||
<SEOEmbed {...Astro.props} />
|
||||
|
||||
<!-- CSP -->
|
||||
<meta
|
||||
http-equiv="Content-Security-Policy"
|
||||
content="img-src 'self'; font-src *; style-src 'self' 'unsafe-inline' fonts.googleapis.com; script-src 'self' 'unsafe-inline'; object-src 'none'"
|
||||
/>
|
||||
|
||||
{
|
||||
schemaOrg && (
|
||||
<script
|
||||
type="application/ld+json"
|
||||
set:html={JSON.stringify(schemaOrg)}
|
||||
/>
|
||||
)
|
||||
}
|
||||
</head>
|
||||
<body class="overflow-x-hidden bg-dark font-sans">
|
||||
<slot />
|
||||
|
||||
<script>
|
||||
import "../scripts/menu.js";
|
||||
import "../scripts/menu.ts";
|
||||
</script>
|
||||
<style is:global>
|
||||
::-webkit-scrollbar {
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
---
|
||||
import PostHead from "../../components/widgets/blog/PostHead.astro";
|
||||
import Container from "../../components/atoms/Container.astro";
|
||||
import Navbar from "../../components/widgets/Navbar.astro";
|
||||
import Layout from "../Layout.astro";
|
||||
import Container from "@components/atoms/Container.astro";
|
||||
import Navbar from "@components/widgets/Navbar.astro";
|
||||
import Layout from "@layouts/Layout.astro";
|
||||
|
||||
export interface Props {
|
||||
content: {
|
||||
|
@ -14,16 +13,18 @@ export interface Props {
|
|||
const {
|
||||
content: { title, date },
|
||||
} = Astro.props;
|
||||
|
||||
const url = Astro.url.pathname;
|
||||
---
|
||||
|
||||
<Layout head={PostHead} title={title} date={date}>
|
||||
<Layout description={title} date={date} url={`https://xhyrom.dev${url}`}>
|
||||
<Navbar />
|
||||
<h1 class="w-full py-32 text-center text-5xl font-extrabold text-white">
|
||||
{title}
|
||||
</h1>
|
||||
|
||||
<Container>
|
||||
<main class="prose text-2xl prose-invert">
|
||||
<main class="prose prose-invert text-2xl">
|
||||
<article>
|
||||
<slot />
|
||||
</article>
|
||||
|
|
|
@ -1,38 +1,38 @@
|
|||
---
|
||||
import Container from "../../components/atoms/Container.astro";
|
||||
import Sidebar from "../../components/widgets/docs/Sidebar.astro";
|
||||
import Navbar from "../../components/widgets/Navbar.astro";
|
||||
import Layout from "../../layouts/Layout.astro";
|
||||
import Container from "@components/atoms/Container.astro";
|
||||
import Sidebar from "@components/widgets/docs/Sidebar.astro";
|
||||
import Navbar from "@components/widgets/Navbar.astro";
|
||||
import Layout from "@layouts/Layout.astro";
|
||||
|
||||
export interface Props {
|
||||
content: {
|
||||
title: string;
|
||||
};
|
||||
content: {
|
||||
title: string;
|
||||
};
|
||||
}
|
||||
|
||||
const {
|
||||
content: { title },
|
||||
content: { title },
|
||||
} = Astro.props;
|
||||
---
|
||||
|
||||
<Layout>
|
||||
<Navbar />
|
||||
<Navbar />
|
||||
|
||||
<Container class="flex flex-row">
|
||||
<Sidebar />
|
||||
<Container class="flex flex-row">
|
||||
<Sidebar />
|
||||
|
||||
<div class="w-full p-8">
|
||||
<h1 class="py-10 text-5xl font-extrabold text-white">
|
||||
{title}
|
||||
</h1>
|
||||
<div class="w-full p-8">
|
||||
<h1 class="py-10 text-5xl font-extrabold text-white">
|
||||
{title}
|
||||
</h1>
|
||||
|
||||
<main class="prose text-2xl text-white">
|
||||
<slot />
|
||||
</main>
|
||||
</div>
|
||||
</Container>
|
||||
<main class="prose text-2xl text-white">
|
||||
<slot />
|
||||
</main>
|
||||
</div>
|
||||
</Container>
|
||||
</Layout>
|
||||
|
||||
<script>
|
||||
import "../../scripts/sidebarToggle.js";
|
||||
import "../../scripts/sidebarToggle.js";
|
||||
</script>
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
import Container from "../components/atoms/Container.astro";
|
||||
import Navbar from "../components/widgets/Navbar.astro";
|
||||
import Layout from "../layouts/Layout.astro";
|
||||
import Container from "@components/atoms/Container.astro";
|
||||
import Navbar from "@components/widgets/Navbar.astro";
|
||||
import Layout from "@layouts/Layout.astro";
|
||||
---
|
||||
|
||||
<Layout>
|
||||
|
|
|
@ -1,108 +1,9 @@
|
|||
---
|
||||
import Container from "../components/atoms/Container.astro";
|
||||
import Navbar from "../components/widgets/Navbar.astro";
|
||||
import TechIcon from "../components/widgets/TechIcon.astro";
|
||||
import Layout from "../layouts/Layout.astro";
|
||||
|
||||
const skills = [
|
||||
{
|
||||
name: "TypeScript",
|
||||
icon: "logos:typescript-icon",
|
||||
},
|
||||
{
|
||||
name: "JavaScript",
|
||||
icon: "logos:javascript",
|
||||
},
|
||||
{
|
||||
name: "Bun",
|
||||
icon: "logos:bun",
|
||||
},
|
||||
{
|
||||
name: "NodeJS",
|
||||
icon: "logos:nodejs-icon-alt",
|
||||
},
|
||||
{
|
||||
name: "Deno",
|
||||
icon: "logos:deno",
|
||||
},
|
||||
{
|
||||
name: "React",
|
||||
icon: "logos:react",
|
||||
},
|
||||
{
|
||||
name: "NextJS",
|
||||
icon: "file-icons:nextjs",
|
||||
},
|
||||
{
|
||||
name: "Astro",
|
||||
icon: "vscode-icons:file-type-astro",
|
||||
},
|
||||
{
|
||||
name: "TailwindCSS",
|
||||
icon: "logos:tailwindcss-icon",
|
||||
},
|
||||
{
|
||||
name: "Java",
|
||||
icon: "logos:java",
|
||||
},
|
||||
{
|
||||
name: "Kotlin",
|
||||
icon: "logos:kotlin-icon",
|
||||
},
|
||||
{
|
||||
name: "Rust",
|
||||
icon: "vscode-icons:file-type-rust",
|
||||
},
|
||||
{
|
||||
name: "Go",
|
||||
icon: "vscode-icons:file-type-go-aqua",
|
||||
},
|
||||
{
|
||||
name: "MySQL",
|
||||
icon: "logos:mysql-icon",
|
||||
},
|
||||
{
|
||||
name: "MongoDB",
|
||||
icon: "devicon:mongodb",
|
||||
},
|
||||
{
|
||||
name: "Redis",
|
||||
icon: "devicon:redis",
|
||||
},
|
||||
{
|
||||
name: "Git",
|
||||
icon: "logos:git-icon",
|
||||
},
|
||||
{
|
||||
name: "GitHub",
|
||||
icon: "mdi:github",
|
||||
},
|
||||
{
|
||||
name: "GitHub Actions",
|
||||
icon: "devicon:githubactions",
|
||||
},
|
||||
{
|
||||
name: "Cloudflare",
|
||||
icon: "logos:cloudflare",
|
||||
},
|
||||
{
|
||||
name: "Cloudflare Pages",
|
||||
icon: "simple-icons:cloudflarepages",
|
||||
color: "#f48120",
|
||||
},
|
||||
{
|
||||
name: "Cloudflare Workers",
|
||||
icon: "logos:cloudflare-workers-icon",
|
||||
},
|
||||
{
|
||||
name: "Visual Studio Code",
|
||||
icon: "logos:visual-studio-code",
|
||||
},
|
||||
{
|
||||
name: "IntelliJ IDEA",
|
||||
icon: "logos:intellij-idea",
|
||||
},
|
||||
];
|
||||
import Container from "@components/atoms/Container.astro";
|
||||
import Navbar from "@components/widgets/Navbar.astro";
|
||||
import TechIcon from "@components/widgets/TechIcon.astro";
|
||||
import Layout from "@layouts/Layout.astro";
|
||||
import { skills } from "~/config";
|
||||
---
|
||||
|
||||
<Layout
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
---
|
||||
import Layout from "../../layouts/Layout.astro";
|
||||
import Navbar from "../../components/widgets/Navbar.astro";
|
||||
import Container from "../../components/atoms/Container.astro";
|
||||
import Layout from "@layouts/Layout.astro";
|
||||
import Navbar from "@components/widgets/Navbar.astro";
|
||||
import Container from "@components/atoms/Container.astro";
|
||||
|
||||
const posts = (await Astro.glob('./posts/*.md')).sort(
|
||||
(a, b) => new Date(b.frontmatter.date).valueOf() - new Date(a.frontmatter.date).valueOf()
|
||||
|
|
|
@ -1,7 +1,9 @@
|
|||
---
|
||||
import Layout from "../layouts/Layout.astro";
|
||||
import Hero from "../components/widgets/index/Hero.astro";
|
||||
import Navbar from "../components/widgets/Navbar.astro";
|
||||
import Layout from "@layouts/Layout.astro";
|
||||
import Navbar from "@components/widgets/Navbar.astro";
|
||||
import { Picture } from "@astrojs/image/components";
|
||||
import logo from "@assets/logo.png";
|
||||
import { socials } from "../config";
|
||||
---
|
||||
|
||||
<Layout
|
||||
|
@ -20,5 +22,40 @@ import Navbar from "../components/widgets/Navbar.astro";
|
|||
}}
|
||||
>
|
||||
<Navbar />
|
||||
<Hero />
|
||||
<main
|
||||
class="mt-24 flex flex-col items-center justify-center md:mt-64 md:flex-row"
|
||||
>
|
||||
<div class="justify-cener flex items-center">
|
||||
<Picture
|
||||
src={logo}
|
||||
formats={["png"]}
|
||||
sizes="(max-width: 200px) 100vw, 200px"
|
||||
widths={[200, 400]}
|
||||
aspectRatio={"1:1"}
|
||||
alt="descriptive text"
|
||||
class={"h-[200px] w-[200px]"}
|
||||
/>
|
||||
</div>
|
||||
<section class="text-center md:ml-6 md:text-left">
|
||||
<div class="flex drop-shadow-yellow">
|
||||
<h1 class="text-6xl font-extrabold text-white">xHyroM</h1>
|
||||
</div>
|
||||
|
||||
<ul class="my-5 flex justify-center text-white md:justify-start">
|
||||
{
|
||||
socials.map((social) => (
|
||||
<li class="mr-4 ">
|
||||
<a class="h-10 w-10" href={social.link} title={social.name}>
|
||||
<img
|
||||
class="h-8 w-8 transition-all hover:-translate-y-1"
|
||||
src={`/icons/${social.icon}`}
|
||||
alt={`${social.name} icon`}
|
||||
/>
|
||||
</a>
|
||||
</li>
|
||||
))
|
||||
}
|
||||
</ul>
|
||||
</section>
|
||||
</main>
|
||||
</Layout>
|
||||
|
|
|
@ -1,95 +1,8 @@
|
|||
---
|
||||
import Layout from "../layouts/Layout.astro";
|
||||
import Navbar from "../components/widgets/Navbar.astro";
|
||||
import Container from "../components/atoms/Container.astro";
|
||||
|
||||
interface Project {
|
||||
name: string;
|
||||
link: string;
|
||||
desc: string;
|
||||
stats?: {
|
||||
forks: number;
|
||||
stars: number;
|
||||
};
|
||||
}
|
||||
|
||||
const projects: Project[] = [
|
||||
{
|
||||
name: "HyLib",
|
||||
link: "https://github.com/xHyroM/HyLib",
|
||||
desc: "Source code for HyLib, a paper plugin and powerful library.",
|
||||
},
|
||||
{
|
||||
name: "HyChat",
|
||||
link: "https://github.com/xHyroM/HyChat",
|
||||
desc: "Source code for HyChat, a paper plugin.",
|
||||
},
|
||||
{
|
||||
name: "HyX",
|
||||
link: "https://github.com/xHyroM/HyX",
|
||||
desc: "Lorem ipsum dolor sit amet consectetur adipisicing elit. Cumque, quaerat.",
|
||||
},
|
||||
{
|
||||
name: "Mashe",
|
||||
link: "https://github.com/xHyroM/mashe",
|
||||
desc: "Simple, fast, and easy to use Event Handling for Java.",
|
||||
},
|
||||
{
|
||||
name: "Mumblum",
|
||||
link: "https://github.com/xHyroM/mumblum",
|
||||
desc: "Mumblum is a simple, modern discord bot in JDA.",
|
||||
},
|
||||
{
|
||||
name: "setup-bun",
|
||||
link: "https://github.com/oven-sh/setup-bun",
|
||||
desc: "Set up your GitHub Actions workflow with a specific version of Bun.",
|
||||
},
|
||||
{
|
||||
name: "Roles Bot",
|
||||
link: "https://github.com/xHyroM/roles-bot",
|
||||
desc: 'Discord bot for "button" roles, using Cloudflare Workers.',
|
||||
},
|
||||
{
|
||||
name: "Bun Discord Bot",
|
||||
link: "https://github.com/xHyroM/bun-discord-bot",
|
||||
desc: "Official serverless discord bot for bun discord server.",
|
||||
},
|
||||
{
|
||||
name: "hykord",
|
||||
link: "https://github.com/xHyroM/hykord",
|
||||
desc: "My @discord client modification.",
|
||||
},
|
||||
{
|
||||
name: "frog",
|
||||
link: "https://github.com/xHyroM/frog",
|
||||
desc: "Frog is an extremely simple language based on the monkey language.",
|
||||
},
|
||||
{
|
||||
name: "lsx",
|
||||
link: "https://github.com/xHyroM/lsx",
|
||||
desc: "Lsx is a simple, fast, and easy to use ls implementation in Rust.",
|
||||
},
|
||||
{
|
||||
name: "Slovensko v Grafoch",
|
||||
link: "https://github.com/xHyroM/slovensko-v-grafoch",
|
||||
desc: "Slovensko v Grafoch is a website that shows data about Slovakia in graphs.",
|
||||
},
|
||||
{
|
||||
name: "Peddler's Pocket",
|
||||
link: "https://github.com/xHyroM/peddlerspocket",
|
||||
desc: "/sell command that allows you to put things into GUI and then sell them by closing",
|
||||
},
|
||||
{
|
||||
name: "Peak Pursuit",
|
||||
link: "https://github.com/xHyroM/peakpursuit",
|
||||
desc: "PeakPursuit is a plugin for King of the Hill events that adds a competitive edge to your server gameplay. Conquer the hill and claim the crown!",
|
||||
},
|
||||
{
|
||||
name: "Spawner Genz",
|
||||
link: "https://github.com/xHyroM/spawnergenz",
|
||||
desc: "Spawner Genz is a plugin that modifies the functionality of spawners so that they don't spawn entities, but instead store drops in a virtual storag in which you can then sell or move everything to your inventory.",
|
||||
},
|
||||
];
|
||||
import Layout from "@layouts/Layout.astro";
|
||||
import Navbar from "@components/widgets/Navbar.astro";
|
||||
import Container from "@components/atoms/Container.astro";
|
||||
import { projects } from "~/config";
|
||||
|
||||
for (const project of projects) {
|
||||
try {
|
||||
|
|
|
@ -1,9 +0,0 @@
|
|||
document.querySelector(".hamburger").addEventListener("click", () => {
|
||||
document.querySelector(".nav-links").classList.remove("hidden");
|
||||
document.querySelector(".hamburger-close").classList.remove("hidden");
|
||||
});
|
||||
|
||||
document.querySelector(".hamburger-close").addEventListener("click", () => {
|
||||
document.querySelector(".nav-links").classList.toggle("hidden");
|
||||
document.querySelector(".hamburger-close").classList.toggle("hidden");
|
||||
});
|
9
src/scripts/menu.ts
Normal file
9
src/scripts/menu.ts
Normal file
|
@ -0,0 +1,9 @@
|
|||
document.querySelector(".hamburger")!.addEventListener("click", () => {
|
||||
document.querySelector(".nav-links")!.classList.remove("hidden");
|
||||
document.querySelector(".hamburger-close")!.classList.remove("hidden");
|
||||
});
|
||||
|
||||
document.querySelector(".hamburger-close")!.addEventListener("click", () => {
|
||||
document.querySelector(".nav-links")!.classList.toggle("hidden");
|
||||
document.querySelector(".hamburger-close")!.classList.toggle("hidden");
|
||||
});
|
|
@ -1,6 +0,0 @@
|
|||
document.getElementById("sidebar-show").addEventListener("click", () => {
|
||||
document.getElementById("sidebar-show").classList.remove("hidden");
|
||||
document.getElementById("sidebar").classList.toggle("-translate-x-full");
|
||||
document.getElementById("sidebar").classList.remove("invisible");
|
||||
document.getElementById("open-arrow").classList.toggle("rotate-180");
|
||||
});
|
10
src/scripts/sidebarToggle.ts
Normal file
10
src/scripts/sidebarToggle.ts
Normal file
|
@ -0,0 +1,10 @@
|
|||
const sidebarShow = document.getElementById("sidebar-show")!;
|
||||
|
||||
sidebarShow.addEventListener("click", () => {
|
||||
const sidebar = document.getElementById("sidebar")!;
|
||||
|
||||
sidebarShow.classList.remove("hidden");
|
||||
sidebar.classList.toggle("-translate-x-full");
|
||||
sidebar.classList.remove("invisible");
|
||||
document.getElementById("open-arrow")!.classList.toggle("rotate-180");
|
||||
});
|
|
@ -1,4 +1,14 @@
|
|||
{
|
||||
"extends": "astro/tsconfigs/strict",
|
||||
"exclude": ["node_modules", ".astro"]
|
||||
"compilerOptions": {
|
||||
"baseUrl": ".",
|
||||
"paths": {
|
||||
"~/*": ["src/*"],
|
||||
"@pages/*": ["src/pages/*"],
|
||||
"@assets/*": ["src/assets"],
|
||||
"@layouts/*": ["src/layouts/*"],
|
||||
"@components/*": ["src/components/*"]
|
||||
}
|
||||
},
|
||||
"exclude": ["node_modules", ".astro", "dist"]
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue