Compare commits

...
3 Commits
Author SHA1 Message Date
encie22 3b702a1399 Prevent duplicate form and navbar listeners after page transitions, tidy env, env example
Build and Deploy to Web Server / deploy (push) Successful in 19m17s
2026-10-15 12:19:04 +10:30
encie22 433b84ea8f Fix IMG nesting div in p tags - invalid HTML 2026-10-15 12:11:28 +10:30
encie22 e22a4dc112 Upgrade to latest Astro (v7) 2026-10-15 12:05:04 +10:30
12 changed files with 2075 additions and 4082 deletions

No files matched your search

+7
View File
@@ -0,0 +1,7 @@
# Copy to `.env` and fill in real values. Never commit `.env`.
EMAIL_HOST=smtp.example.com
EMAIL_PORT=587
EMAIL_SECURE=false
EMAIL_USER=user@example.com
EMAIL_PASS=change-me
EMAIL_FROM=noreply@example.com
+2 -2
View File
@@ -7,7 +7,7 @@ below, unless otherwise indicated in a specific file's header.
## MIT License
Copyright (c) 2025 Nathan Cummins
Copyright (c) 2026 Nathan Cummins
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
@@ -32,7 +32,7 @@ SOFTWARE.
All non-code content in this repository — including, but not limited to, music
(including melodies, harmonies, arrangements, lyrics, sound recordings, and
other musical elements), audio recordings, images, photographs, written
biographies, descriptive texts, and project documentation — is copyright © 2025
biographies, descriptive texts, and project documentation — is copyright © 2026
Nathan Cummins, all rights reserved, unless otherwise stated in the file itself.
Such non-code content may not be copied, modified, distributed, or otherwise
+1 -1
View File
@@ -10,7 +10,7 @@ Thanks for checking it out!
## TL;DR
- **Code:** All source code in this repository is licensed under the [MIT License](LICENSE). You are welcome to fork, clone, modify, or otherwise use the code in your own projects, provided you give appropriate credit.
- **Non-code content:** All other materials — including music and audio (melodies, harmonies, arrangements, lyrics, sound recordings, and other musical elements and audio), images, photographs, written biographies, project descriptions, and any other creative works — are copyright © 2025 Nathan Cummins, **all rights reserved**. These may not be copied, modified, distributed, or otherwise used without prior written permission.
- **Non-code content:** All other materials — including music and audio (melodies, harmonies, arrangements, lyrics, sound recordings, and other musical elements and audio), images, photographs, written biographies, project descriptions, and any other creative works — are copyright © 2026 Nathan Cummins, **all rights reserved**. These may not be copied, modified, distributed, or otherwise used without prior written permission.
If you use the code, I would appreciate proper credit by linking back to my [website](https://www.nathancummins.com.au) or including my name and email ([nathan@nathancummins.com.au](https://www.nathancummins.com.au)).
+2034 -4053
View File
File diff suppressed because it is too large. Load diff
+6 -6
View File
@@ -9,19 +9,19 @@
"astro": "astro"
},
"dependencies": {
"@astrojs/mdx": "^4.3.1",
"@astrojs/node": "^9.4.3",
"@astrojs/sitemap": "^3.4.2",
"@astrojs/mdx": "^8.0.3",
"@astrojs/node": "^11.1.7",
"@astrojs/sitemap": "^3.7.4",
"@iconify-json/fa": "^1.2.1",
"@iconify-json/fa7-brands": "^1.2.0",
"@iconify-json/fa7-solid": "^1.2.0",
"@iconify-json/mdi": "^1.2.3",
"@iconify-json/simple-icons": "^1.2.44",
"@tailwindcss/vite": "^4.1.11",
"astro": "^5.18.2",
"astro": "^7.3.8",
"astro-icon": "^1.1.5",
"astro-robots-txt": "^1.0.0",
"astro-seo-schema": "^5.1.0",
"astro-seo-schema": "^7.0.1",
"get-audio-duration": "^4.0.1",
"nodemailer": "^7.0.5",
"schema-dts": "^1.1.5",
@@ -29,7 +29,7 @@
},
"devDependencies": {
"@cspell/dict-en-au": "^1.1.4",
"@shikijs/transformers": "^3.9.2",
"@shikijs/transformers": "^4.5.0",
"@types/howler": "^2.2.12",
"@types/nodemailer": "^7.0.1",
"@typescript-eslint/eslint-plugin": "^8.38.0",
+2 -1
View File
@@ -77,7 +77,8 @@ const { id: ID = "contact-form" } = Astro.props;
<script define:vars={{ ID }}>
function init() {
const form = document.getElementById(ID);
if (!form) return;
if (!form || form.dataset.initialised) return;
form.dataset.initialised = "true";
const responseMsg = form.querySelector(
`#${CSS.escape(ID + "-response-message")}`
);
+3 -3
View File
@@ -11,14 +11,14 @@ const image = getImageByPath(src);
{
image && (
<div class="my-8">
<span class="my-8 block">
<Image
src={image}
alt={alt}
width={1344}
class="transition ease-in-out lg:hover:scale-150"
/>
<div class="mt-2 block w-full text-center text-sm italic">{alt}</div>
</div>
<span class="mt-2 block w-full text-center text-sm italic">{alt}</span>
</span>
)
}
+9 -2
View File
@@ -139,7 +139,8 @@ const { navbarDisplay = "normal" } = Astro.props as Props;
nav = document.getElementById("nav");
toggle = document.getElementById("menu-toggle");
if (toggle) {
if (toggle && !toggle.dataset.bound) {
toggle.dataset.bound = "true";
toggle.addEventListener("click", () => {
if (nav) {
const visible = nav.getAttribute("data-mobile-menu") === "visible";
@@ -151,6 +152,8 @@ const { navbarDisplay = "normal" } = Astro.props as Props;
});
}
if (!document.documentElement.dataset.navbarKeydownBound) {
document.documentElement.dataset.navbarKeydownBound = "true";
document.addEventListener("keydown", (e) => {
if (
e.key === "Escape" &&
@@ -160,9 +163,13 @@ const { navbarDisplay = "normal" } = Astro.props as Props;
toggle?.setAttribute("aria-expanded", "false");
}
});
}
checkScroll();
});
window.addEventListener("scroll", checkScroll);
if (!document.documentElement.dataset.navbarScrollBound) {
document.documentElement.dataset.navbarScrollBound = "true";
window.addEventListener("scroll", checkScroll, { passive: true });
}
</script>
+2 -1
View File
@@ -1,5 +1,6 @@
import { glob } from "astro/loaders";
import { defineCollection, z } from "astro:content";
import { z } from "astro/zod";
import { defineCollection } from "astro:content";
const projects = defineCollection({
loader: glob({ pattern: "**/*.mdx", base: "./projects" }),
+1 -2
View File
@@ -1,4 +1,4 @@
/// <reference types="@astrojs/image/client" />
/// <reference types="astro/client" />
/// <reference types="./types/SiteImage" />
interface Window {
@@ -14,7 +14,6 @@ interface Window {
}
interface ImportMetaEnv {
readonly SITE?: string;
readonly EMAIL_USER: string;
readonly EMAIL_PASS: string;
readonly EMAIL_PORT: number;
+2 -4
View File
@@ -67,10 +67,8 @@ import { Image } from "astro:assets";
<ul>
<LI>
<span class="font-bold"
><TextLink
href="/projects/video-game/dungeons-and-dining-tables/"
>
Dungeons and Dining Tables</TextLink
><TextLink href="/projects/video-game/dungeons-and-dining-tables/"
>Dungeons and Dining Tables</TextLink
>:</span
> a cosy, highly orchestral score full of warmth and colour.
</LI>
+6 -7
View File
@@ -8,25 +8,24 @@
"dist"
],
"compilerOptions": {
"baseUrl": ".",
"paths": {
"@/*": [
"src/*"
"./src/*"
],
"@layouts/*": [
"src/layouts/*"
"./src/layouts/*"
],
"@components/*": [
"src/components/*"
"./src/components/*"
],
"@assets/*": [
"src/assets/*"
"./src/assets/*"
],
"@lib/*": [
"src/lib/*"
"./src/lib/*"
],
"@data/*": [
"src/data/*"
"./src/data/*"
]
}
}