From 77a445393f96fe02b9dac8948ef1503d70cc5a9c Mon Sep 17 00:00:00 2001 From: MattTheTekie Date: Thu, 23 Apr 2026 18:08:22 -0400 Subject: [PATCH] chore: fixes --- legacy.html | 28 +++++++++++++++++++++++----- 1 file changed, 23 insertions(+), 5 deletions(-) diff --git a/legacy.html b/legacy.html index 9e9cd7f..63a1d33 100644 --- a/legacy.html +++ b/legacy.html @@ -110,7 +110,6 @@ function showMembers(event) { `; } - function showAbout(event) { if (event) event.preventDefault(); @@ -127,11 +126,30 @@ function showAbout(event) { const temp = document.createElement("div"); temp.innerHTML = html; - const section = temp.querySelector("article.home-text.text-containers-secondary-bg"); + const article = temp.querySelector("article.home-text.text-containers-secondary-bg"); - target.innerHTML = section - ? section.innerHTML - : "

About

Missing article.home-text.text-containers-secondary-bg in about.html

"; + if (!article) { + target.innerHTML = "

About

Missing article.home-text.text-containers-secondary-bg in about.html

"; + return; + } + + // Convert children so we can get everything after the article + const children = Array.from(temp.children); + const index = children.indexOf(article); + + let afterArticle = ""; + + if (index !== -1) { + afterArticle = children + .slice(index + 1) + .map(el => el.outerHTML) + .join(""); + } + + target.innerHTML = ` + ${article.outerHTML} + ${afterArticle} + `; }) .catch(err => { console.error(err);