diff options
| author | Collin Williams <96917990+bluedragon1221@users.noreply.github.com> | 2026-08-22 17:17:49 -0500 |
|---|---|---|
| committer | Collin Williams <96917990+bluedragon1221@users.noreply.github.com> | 2026-08-22 17:17:49 -0500 |
| commit | 8964e6218f3257aeaf0c184e4895e2f8bf317c9f (patch) | |
| tree | b9b75d983480690f3a27f5983905b7855b599f2c /article.js | |
| parent | eef357ebc10246da0da3c8bce427991eeb3f1dce (diff) | |
update css, rename article, move assets to selfhosted
Diffstat (limited to 'article.js')
| -rw-r--r-- | article.js | 20 |
1 files changed, 9 insertions, 11 deletions
@@ -2,7 +2,7 @@ function addMetadata() { // Favicon const favicon = document.createElement("link"); favicon.rel = "icon"; - favicon.href = "/Logo.svg"; + favicon.href = "https://static.williamsfam.us.com/Logo.svg"; favicon.type = "image/svg+xml"; document.head.appendChild(favicon); @@ -27,20 +27,19 @@ function addMetadata() { function addHeader() { const header = document.querySelector("header"); - // Logo + const headerTop = document.createElement("div"); + headerTop.classList.add("header-top"); + const logoLink = document.createElement("a"); - logoLink.href = "/writing.html"; + logoLink.href = "writing"; logoLink.classList.add("header-logo-link"); - header.appendChild(logoLink); + headerTop.appendChild(logoLink); - // Right-side content const info = document.createElement("div"); info.classList.add("header-info"); - const h1 = document.createElement("h1"); h1.textContent = document.title; info.appendChild(h1); - const time = document.createElement("time"); const metaDate = document.querySelector('meta[property="article:published_time"]'); const dateString = metaDate.getAttribute("content"); @@ -50,12 +49,11 @@ function addHeader() { year: "numeric", timeZone: "UTC" }); - time.setAttribute("datetime", dateString); time.textContent = `Published ${displayDate}`; info.appendChild(time); - - header.appendChild(info); + headerTop.appendChild(info); + header.appendChild(headerTop); const hr = document.createElement("hr"); header.appendChild(hr); @@ -89,4 +87,4 @@ document.addEventListener("DOMContentLoaded", () => { addMetadata() addHeader() addTOC() -})
\ No newline at end of file +}) |
