From b6919cb4110a0a82daacf44d2ec3460d0bfd080b Mon Sep 17 00:00:00 2001 From: Drew Smirnoff Date: Mon, 15 Jun 2026 20:42:09 +0400 Subject: [PATCH] chore: update the website (#1475) ## What? Updates the website ## Why? Removes some outdated information, better UI --------- Signed-off-by: drew --- public/components/site.jsx | 408 +++++++----------- public/index.html | 17 +- public/styles.css | 819 +++++++++++++------------------------ 3 files changed, 444 insertions(+), 800 deletions(-) diff --git a/public/components/site.jsx b/public/components/site.jsx index 398462e6bddf8edef82f6ca496d1e2bb06c67198..66989925ff4aa73c07e77ed0cfb6a0586fa37c8e 100644 --- a/public/components/site.jsx +++ b/public/components/site.jsx @@ -1,5 +1,44 @@ const { useState, useEffect } = React; +// --- Global hooks --- + +function useScrollReveal() { + useEffect(() => { + const els = document.querySelectorAll(".reveal"); + if (!els.length) return; + if (!("IntersectionObserver" in window)) { + els.forEach((el) => el.classList.add("visible")); + return; + } + const obs = new IntersectionObserver( + (entries) => { + entries.forEach((e) => { + if (e.isIntersecting) { + e.target.classList.add("visible"); + obs.unobserve(e.target); + } + }); + }, + { threshold: 0.08, rootMargin: "0px 0px -40px 0px" }, + ); + els.forEach((el) => obs.observe(el)); + return () => obs.disconnect(); + }, []); +} + +function useMouseGlow() { + useEffect(() => { + const move = (e) => { + document.documentElement.style.setProperty("--mx", e.clientX + "px"); + document.documentElement.style.setProperty("--my", e.clientY + "px"); + }; + window.addEventListener("mousemove", move, { passive: true }); + return () => window.removeEventListener("mousemove", move); + }, []); +} + +// --- Components --- + function FloatpaneMark({ size = 20 }) { return ( { - // floatpane/matcha repo — fetch latest release tag fetch("https://api.github.com/repos/floatpane/matcha/releases/latest") .then((r) => (r.ok ? r.json() : null)) .then((d) => { @@ -61,7 +99,6 @@ function TopNav() {