diff --git a/apps/penfield/astro.config.mjs b/apps/penfield/astro.config.mjs new file mode 100644 index 0000000..e93aeb8 --- /dev/null +++ b/apps/penfield/astro.config.mjs @@ -0,0 +1,5 @@ +import { defineConfig } from 'astro/config'; + +export default defineConfig({ + output: 'static' +}); diff --git a/apps/penfield/package.json b/apps/penfield/package.json new file mode 100644 index 0000000..ad83a29 --- /dev/null +++ b/apps/penfield/package.json @@ -0,0 +1,12 @@ +{ + "name": "@ily/penfield", + "type": "module", + "scripts": { + "dev": "astro dev", + "build": "astro build", + "preview": "astro preview" + }, + "dependencies": { + "astro": "^5.16.13" + } +} diff --git a/apps/penfield/src/data/intros.ts b/apps/penfield/src/data/intros.ts new file mode 100644 index 0000000..5ff0b77 --- /dev/null +++ b/apps/penfield/src/data/intros.ts @@ -0,0 +1,6 @@ +export const intros = [ + { text: "You wake up. Your Penfield thrums." }, + { text: "Your Penfield Mood Organ chimes." }, + { text: "Your Penfield Mood Organ wakes you." }, + { text: "You are awoken by your Penfield Mood Organ." }, +]; diff --git a/apps/penfield/src/data/moods.ts b/apps/penfield/src/data/moods.ts new file mode 100644 index 0000000..e94b40e --- /dev/null +++ b/apps/penfield/src/data/moods.ts @@ -0,0 +1,17 @@ +export const moods = [ + { num: 3, text: "Desire to dial" }, + { num: 382, text: "Desire to engage in creative activity" }, + { num: 481, text: "Awareness of the manifold possibilities open in the future" }, + { num: 594, text: "Pleased acknowledgment of husband's superior wisdom" }, + { num: 670, text: "Long-deserved peace" }, + { num: 888, text: "Desire to watch TV, no matter what's on" }, + { num: 443, text: "Self-accusatory depression" }, + { num: 72, text: "Vague unease about tomorrow" }, + { num: 158, text: "Acceptance of routine" }, + { num: 291, text: "Brief contentment with material possessions" }, + { num: 407, text: "Suppressed awareness of mortality" }, + { num: 531, text: "Calm readiness to consume" }, + { num: 816, text: "Desire to return to bed" }, + { num: 952, text: "Resigned compliance" }, + { num: 64, text: "Faint hope that things will improve" }, +]; diff --git a/apps/penfield/src/pages/index.astro b/apps/penfield/src/pages/index.astro new file mode 100644 index 0000000..9dedd26 --- /dev/null +++ b/apps/penfield/src/pages/index.astro @@ -0,0 +1,11 @@ +--- +import { intros } from '../data/intros'; +import { moods } from '../data/moods'; +const epoch = Math.floor(Date.now() / 3600000); +const start = Math.floor(new Date('2026-01-22T14:00:00Z').getTime() / 3600000); +const t = epoch; // for mood selection +const ring = epoch - start; +const intro: { text: string } = intros[t % intros.length]; +const mood: { num: number, text: string } = moods[t % moods.length]; +--- +Penfield

Ring #{ring}.

{mood.num}. {mood.text}.