From 46aa9294e8c8fd7b73a66d91841022654a19f691 Mon Sep 17 00:00:00 2001 From: Nap Joseph Calub Date: Tue, 17 Nov 2026 23:50:17 +0800 Subject: [PATCH] Align site with the Wireframe & Copy Deck - Restructure to the deck's eight pages: Home, About, Local Networks, #HACK, Pray & Online Workers, Stories, Partner & Give, Contact. Events, Projects and Resources stay as footer-only pages. - Use the deck's copy and voice throughout ("local network", "missions in a digital age"); tagline "Locally rooted. Digitally sent." - Add deck components: AnnouncementBar, Countdown, Intro, EventFeature, Gifts, StoryCards, SplitText, Timeline, Beliefs, GlobalBand, StartBand, Steps, EventDetails, ChallengeCards, Gallery, PrayerFocus, EventHero, Choices, and Interest/Prayer/Contact forms; rename PageHeader, CtaBand, FAQ and CommunityCard to PageHero, CTABand, Accordion and NetworkCard. - Feature #HACK for Christmas, Iloilo (Nov 20-21) with an announcement bar, home card and #HACK countdown. Events auto-expire at build time, in the browser, and via a daily scheduled rebuild. - New content: networks, challenges, and site.json for the announcement, prayer time and prayer focus; prayer time .ics endpoint. - Drop the /fil/ mirror; old URLs redirect to their new pages. - Rewrite AGENTS.md and README around the deck, including its voice guide, component map and open questions. --- .env.example | 10 +- .github/workflows/deploy.yml | 4 + AGENTS.md | 250 ++++++++++----- README.md | 52 ++-- astro.config.mjs | 62 +++- public/og-default.svg | 2 +- src/components/cards/CommunityCard.astro | 49 --- src/components/cards/CommunityCard.stories.ts | 20 -- src/components/cards/EventCard.stories.ts | 16 +- src/components/cards/NetworkCard.astro | 58 ++++ src/components/cards/NetworkCard.stories.ts | 30 ++ src/components/cards/StoryCard.stories.ts | 11 +- src/components/cards/TeamCard.astro | 34 ++- src/components/cards/TeamCard.stories.ts | 10 +- src/components/cards/TestimonialCard.astro | 42 --- .../cards/TestimonialCard.stories.ts | 27 -- src/components/forms/ContactForm.astro | 32 ++ src/components/forms/ContactForm.stories.ts | 14 + src/components/forms/FormShell.astro | 87 ++++++ src/components/forms/FormShell.stories.ts | 30 ++ src/components/forms/InterestForm.astro | 42 +++ src/components/forms/InterestForm.stories.ts | 14 + src/components/forms/PrayerForm.astro | 54 ++++ src/components/forms/PrayerForm.stories.ts | 14 + src/components/layout/Footer.astro | 130 +++++--- src/components/layout/Footer.stories.ts | 4 +- src/components/layout/Header.astro | 122 ++++---- src/components/layout/Header.stories.ts | 8 +- .../sections/{FAQ.astro => Accordion.astro} | 2 +- src/components/sections/Accordion.stories.ts | 25 ++ src/components/sections/Beliefs.astro | 37 +++ src/components/sections/Beliefs.stories.ts | 29 ++ .../sections/{CtaBand.astro => CTABand.astro} | 21 +- src/components/sections/CTABand.stories.ts | 34 +++ src/components/sections/ChallengeCards.astro | 42 +++ .../sections/ChallengeCards.stories.ts | 28 ++ src/components/sections/CtaBand.stories.ts | 28 -- src/components/sections/EventDetails.astro | 53 ++++ .../sections/EventDetails.stories.ts | 32 ++ src/components/sections/EventFeature.astro | 66 ++++ .../sections/EventFeature.stories.ts | 20 ++ src/components/sections/EventHero.astro | 61 ++++ src/components/sections/EventHero.stories.ts | 21 ++ src/components/sections/FAQ.stories.ts | 22 -- src/components/sections/FeatureGrid.astro | 18 +- .../sections/FeatureGrid.stories.ts | 52 +++- src/components/sections/Gallery.astro | 30 ++ src/components/sections/Gallery.stories.ts | 16 + src/components/sections/Gifts.astro | 42 +++ src/components/sections/Gifts.stories.ts | 27 ++ src/components/sections/GlobalBand.astro | 37 +++ src/components/sections/GlobalBand.stories.ts | 18 ++ src/components/sections/Hero.astro | 89 +++--- src/components/sections/Hero.stories.ts | 23 +- src/components/sections/Intro.astro | 24 ++ src/components/sections/Intro.stories.ts | 19 ++ src/components/sections/NewsletterBand.astro | 90 ------ .../sections/NewsletterBand.stories.ts | 19 -- src/components/sections/PageHeader.astro | 46 --- src/components/sections/PageHeader.stories.ts | 28 -- src/components/sections/PageHero.astro | 53 ++++ src/components/sections/PageHero.stories.ts | 37 +++ src/components/sections/PrayerFocus.astro | 38 +++ .../sections/PrayerFocus.stories.ts | 19 ++ src/components/sections/Section.astro | 10 +- .../sections/SectionHeading.stories.ts | 2 +- src/components/sections/SplitText.astro | 79 +++++ src/components/sections/SplitText.stories.ts | 36 +++ src/components/sections/StartBand.astro | 24 ++ src/components/sections/StartBand.stories.ts | 18 ++ src/components/sections/StatsBand.astro | 43 --- src/components/sections/StatsBand.stories.ts | 20 -- src/components/sections/Steps.astro | 20 ++ src/components/sections/Steps.stories.ts | 21 ++ src/components/sections/StoryCards.astro | 40 +++ src/components/sections/StoryCards.stories.ts | 31 ++ src/components/sections/Timeline.astro | 25 ++ src/components/sections/Timeline.stories.ts | 20 ++ src/components/ui/AnnouncementBar.astro | 64 ++++ src/components/ui/AnnouncementBar.stories.ts | 21 ++ src/components/ui/Button.astro | 7 +- src/components/ui/Button.stories.ts | 18 +- src/components/ui/Choices.astro | 47 +++ src/components/ui/Choices.stories.ts | 37 +++ src/components/ui/Countdown.astro | 89 ++++++ src/components/ui/Countdown.stories.ts | 19 ++ src/components/ui/Field.astro | 5 +- src/components/ui/Icon.astro | 19 ++ src/components/ui/SwitchTabs.astro | 5 +- src/config/site.ts | 50 +-- src/content.config.ts | 103 +++++-- src/content/challenges/_example.md | 6 + src/content/communities/en/iloilo.md | 10 - src/content/communities/en/manila.md | 12 - src/content/communities/fil/iloilo.md | 10 - src/content/communities/fil/manila.md | 10 - .../events/en/coffee-talk-faith-and-ai.md | 18 -- src/content/events/en/hack2026-manila.md | 11 - .../en/hack2027-champion-info-session.md | 15 - .../events/en/iloilo-creatives-meetup.md | 10 - .../events/fil/coffee-talk-faith-and-ai.md | 16 - .../events/hack-for-christmas-iloilo.md | 18 ++ src/content/networks/iloilo.md | 7 + src/content/networks/manila.md | 7 + .../{en => }/bible-in-your-dialect.md | 2 +- .../projects/{en => }/church-website-kit.md | 0 src/content/projects/{en => }/ofw-stories.md | 0 src/content/site/site.json | 22 ++ .../en/getting-started-as-a-creative.mdx | 14 - .../stories/en/what-happened-at-hack2026.md | 12 - .../stories/en/why-indigitous-philippines.md | 18 -- .../stories/fil/why-indigitous-philippines.md | 12 - .../stories/getting-started-as-a-creative.mdx | 14 + src/content/stories/what-happens-at-a-hack.md | 12 + .../stories/why-indigitous-philippines.md | 16 + src/content/team/{en => }/juan-dela-cruz.md | 3 +- src/content/team/{en => }/maria-dela-cruz.md | 3 +- src/content/team/{en => }/pedro-penduko.md | 3 +- src/i18n/en.ts | 62 ++-- src/i18n/fil.ts | 77 ----- src/i18n/index.ts | 65 ++-- src/layouts/BaseLayout.astro | 70 ++++- src/lib/content.ts | 52 ++-- src/pages/404.astro | 15 +- src/pages/about.astro | 131 ++++++++ src/pages/about/index.astro | 5 - src/pages/about/team.astro | 5 - src/pages/communities/[slug].astro | 13 - src/pages/communities/index.astro | 5 - src/pages/contact.astro | 53 +++- src/pages/events/[slug].astro | 78 ++++- src/pages/events/index.astro | 79 ++++- src/pages/fil/about/index.astro | 5 - src/pages/fil/about/team.astro | 5 - src/pages/fil/communities/[slug].astro | 13 - src/pages/fil/communities/index.astro | 5 - src/pages/fil/contact.astro | 5 - src/pages/fil/events/[slug].astro | 13 - src/pages/fil/events/index.astro | 5 - src/pages/fil/get-involved.astro | 5 - src/pages/fil/give.astro | 5 - src/pages/fil/hack.astro | 5 - src/pages/fil/index.astro | 5 - src/pages/fil/projects/[slug].astro | 13 - src/pages/fil/projects/index.astro | 5 - src/pages/fil/resources.astro | 5 - src/pages/fil/start-here.astro | 5 - src/pages/fil/stories/[slug].astro | 13 - src/pages/fil/stories/index.astro | 5 - src/pages/get-involved.astro | 5 - src/pages/give.astro | 5 - src/pages/hack.astro | 162 +++++++++- src/pages/index.astro | 157 +++++++++- src/pages/networks.astro | 93 ++++++ src/pages/partner.astro | 78 +++++ src/pages/pray/index.astro | 125 ++++++++ src/pages/pray/prayer-time.ics.ts | 53 ++++ src/pages/projects/[slug].astro | 68 ++++- src/pages/projects/index.astro | 65 +++- src/pages/resources.astro | 106 ++++++- src/pages/start-here.astro | 5 - src/pages/stories/[slug].astro | 69 ++++- src/pages/stories/index.astro | 68 ++++- src/pages/storybook/index.astro | 11 +- src/views/About.astro | 163 ---------- src/views/Communities.astro | 75 ----- src/views/CommunityDetail.astro | 112 ------- src/views/Contact.astro | 141 --------- src/views/EventDetail.astro | 81 ----- src/views/Events.astro | 99 ------ src/views/GetInvolved.astro | 147 --------- src/views/Give.astro | 92 ------ src/views/Hack.astro | 208 ------------- src/views/Home.astro | 285 ------------------ src/views/NotFound.astro | 22 -- src/views/ProjectDetail.astro | 68 ----- src/views/Projects.astro | 85 ------ src/views/Resources.astro | 186 ------------ src/views/StartHere.astro | 195 ------------ src/views/Stories.astro | 65 ---- src/views/StoryDetail.astro | 60 ---- src/views/Team.astro | 63 ---- 182 files changed, 4120 insertions(+), 3552 deletions(-) delete mode 100644 src/components/cards/CommunityCard.astro delete mode 100644 src/components/cards/CommunityCard.stories.ts create mode 100644 src/components/cards/NetworkCard.astro create mode 100644 src/components/cards/NetworkCard.stories.ts delete mode 100644 src/components/cards/TestimonialCard.astro delete mode 100644 src/components/cards/TestimonialCard.stories.ts create mode 100644 src/components/forms/ContactForm.astro create mode 100644 src/components/forms/ContactForm.stories.ts create mode 100644 src/components/forms/FormShell.astro create mode 100644 src/components/forms/FormShell.stories.ts create mode 100644 src/components/forms/InterestForm.astro create mode 100644 src/components/forms/InterestForm.stories.ts create mode 100644 src/components/forms/PrayerForm.astro create mode 100644 src/components/forms/PrayerForm.stories.ts rename src/components/sections/{FAQ.astro => Accordion.astro} (88%) create mode 100644 src/components/sections/Accordion.stories.ts create mode 100644 src/components/sections/Beliefs.astro create mode 100644 src/components/sections/Beliefs.stories.ts rename src/components/sections/{CtaBand.astro => CTABand.astro} (55%) create mode 100644 src/components/sections/CTABand.stories.ts create mode 100644 src/components/sections/ChallengeCards.astro create mode 100644 src/components/sections/ChallengeCards.stories.ts delete mode 100644 src/components/sections/CtaBand.stories.ts create mode 100644 src/components/sections/EventDetails.astro create mode 100644 src/components/sections/EventDetails.stories.ts create mode 100644 src/components/sections/EventFeature.astro create mode 100644 src/components/sections/EventFeature.stories.ts create mode 100644 src/components/sections/EventHero.astro create mode 100644 src/components/sections/EventHero.stories.ts delete mode 100644 src/components/sections/FAQ.stories.ts create mode 100644 src/components/sections/Gallery.astro create mode 100644 src/components/sections/Gallery.stories.ts create mode 100644 src/components/sections/Gifts.astro create mode 100644 src/components/sections/Gifts.stories.ts create mode 100644 src/components/sections/GlobalBand.astro create mode 100644 src/components/sections/GlobalBand.stories.ts create mode 100644 src/components/sections/Intro.astro create mode 100644 src/components/sections/Intro.stories.ts delete mode 100644 src/components/sections/NewsletterBand.astro delete mode 100644 src/components/sections/NewsletterBand.stories.ts delete mode 100644 src/components/sections/PageHeader.astro delete mode 100644 src/components/sections/PageHeader.stories.ts create mode 100644 src/components/sections/PageHero.astro create mode 100644 src/components/sections/PageHero.stories.ts create mode 100644 src/components/sections/PrayerFocus.astro create mode 100644 src/components/sections/PrayerFocus.stories.ts create mode 100644 src/components/sections/SplitText.astro create mode 100644 src/components/sections/SplitText.stories.ts create mode 100644 src/components/sections/StartBand.astro create mode 100644 src/components/sections/StartBand.stories.ts delete mode 100644 src/components/sections/StatsBand.astro delete mode 100644 src/components/sections/StatsBand.stories.ts create mode 100644 src/components/sections/Steps.astro create mode 100644 src/components/sections/Steps.stories.ts create mode 100644 src/components/sections/StoryCards.astro create mode 100644 src/components/sections/StoryCards.stories.ts create mode 100644 src/components/sections/Timeline.astro create mode 100644 src/components/sections/Timeline.stories.ts create mode 100644 src/components/ui/AnnouncementBar.astro create mode 100644 src/components/ui/AnnouncementBar.stories.ts create mode 100644 src/components/ui/Choices.astro create mode 100644 src/components/ui/Choices.stories.ts create mode 100644 src/components/ui/Countdown.astro create mode 100644 src/components/ui/Countdown.stories.ts create mode 100644 src/content/challenges/_example.md delete mode 100644 src/content/communities/en/iloilo.md delete mode 100644 src/content/communities/en/manila.md delete mode 100644 src/content/communities/fil/iloilo.md delete mode 100644 src/content/communities/fil/manila.md delete mode 100644 src/content/events/en/coffee-talk-faith-and-ai.md delete mode 100644 src/content/events/en/hack2026-manila.md delete mode 100644 src/content/events/en/hack2027-champion-info-session.md delete mode 100644 src/content/events/en/iloilo-creatives-meetup.md delete mode 100644 src/content/events/fil/coffee-talk-faith-and-ai.md create mode 100644 src/content/events/hack-for-christmas-iloilo.md create mode 100644 src/content/networks/iloilo.md create mode 100644 src/content/networks/manila.md rename src/content/projects/{en => }/bible-in-your-dialect.md (64%) rename src/content/projects/{en => }/church-website-kit.md (100%) rename src/content/projects/{en => }/ofw-stories.md (100%) create mode 100644 src/content/site/site.json delete mode 100644 src/content/stories/en/getting-started-as-a-creative.mdx delete mode 100644 src/content/stories/en/what-happened-at-hack2026.md delete mode 100644 src/content/stories/en/why-indigitous-philippines.md delete mode 100644 src/content/stories/fil/why-indigitous-philippines.md create mode 100644 src/content/stories/getting-started-as-a-creative.mdx create mode 100644 src/content/stories/what-happens-at-a-hack.md create mode 100644 src/content/stories/why-indigitous-philippines.md rename src/content/team/{en => }/juan-dela-cruz.md (58%) rename src/content/team/{en => }/maria-dela-cruz.md (57%) rename src/content/team/{en => }/pedro-penduko.md (57%) delete mode 100644 src/i18n/fil.ts create mode 100644 src/pages/about.astro delete mode 100644 src/pages/about/index.astro delete mode 100644 src/pages/about/team.astro delete mode 100644 src/pages/communities/[slug].astro delete mode 100644 src/pages/communities/index.astro delete mode 100644 src/pages/fil/about/index.astro delete mode 100644 src/pages/fil/about/team.astro delete mode 100644 src/pages/fil/communities/[slug].astro delete mode 100644 src/pages/fil/communities/index.astro delete mode 100644 src/pages/fil/contact.astro delete mode 100644 src/pages/fil/events/[slug].astro delete mode 100644 src/pages/fil/events/index.astro delete mode 100644 src/pages/fil/get-involved.astro delete mode 100644 src/pages/fil/give.astro delete mode 100644 src/pages/fil/hack.astro delete mode 100644 src/pages/fil/index.astro delete mode 100644 src/pages/fil/projects/[slug].astro delete mode 100644 src/pages/fil/projects/index.astro delete mode 100644 src/pages/fil/resources.astro delete mode 100644 src/pages/fil/start-here.astro delete mode 100644 src/pages/fil/stories/[slug].astro delete mode 100644 src/pages/fil/stories/index.astro delete mode 100644 src/pages/get-involved.astro delete mode 100644 src/pages/give.astro create mode 100644 src/pages/networks.astro create mode 100644 src/pages/partner.astro create mode 100644 src/pages/pray/index.astro create mode 100644 src/pages/pray/prayer-time.ics.ts delete mode 100644 src/pages/start-here.astro delete mode 100644 src/views/About.astro delete mode 100644 src/views/Communities.astro delete mode 100644 src/views/CommunityDetail.astro delete mode 100644 src/views/Contact.astro delete mode 100644 src/views/EventDetail.astro delete mode 100644 src/views/Events.astro delete mode 100644 src/views/GetInvolved.astro delete mode 100644 src/views/Give.astro delete mode 100644 src/views/Hack.astro delete mode 100644 src/views/Home.astro delete mode 100644 src/views/NotFound.astro delete mode 100644 src/views/ProjectDetail.astro delete mode 100644 src/views/Projects.astro delete mode 100644 src/views/Resources.astro delete mode 100644 src/views/StartHere.astro delete mode 100644 src/views/Stories.astro delete mode 100644 src/views/StoryDetail.astro delete mode 100644 src/views/Team.astro diff --git a/.env.example b/.env.example index 8adc4dc..13eb1c9 100644 --- a/.env.example +++ b/.env.example @@ -1,4 +1,6 @@ -# Optional. A form backend (e.g. Formspree, Basin, Web3Forms) that accepts POSTs. -# When unset, the contact and newsletter forms fall back to links (Messenger / email). -PUBLIC_FORM_ENDPOINT= -PUBLIC_NEWSLETTER_ENDPOINT= +# Form backends (e.g. Formspree, Basin, Web3Forms) that accept POSTs. +# Set them as GitHub repository variables for the deployed site. +# When unset, each form shows contact links instead. +PUBLIC_FORM_ENDPOINT= # contact + local network interest forms +PUBLIC_PRAYER_ENDPOINT= # prayer requests (private inbox, prayer team only) +PUBLIC_NEWSLETTER_ENDPOINT= # footer newsletter diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index e1ea819..3103fb0 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -5,6 +5,9 @@ on: branches: [main] pull_request: workflow_dispatch: + # Daily rebuild at 00:05 Manila time (16:05 UTC) so ended events and announcements drop off. + schedule: + - cron: '5 16 * * *' permissions: contents: read @@ -26,6 +29,7 @@ jobs: package-manager: pnpm@12.16.1 env: PUBLIC_FORM_ENDPOINT: ${{ vars.PUBLIC_FORM_ENDPOINT }} + PUBLIC_PRAYER_ENDPOINT: ${{ vars.PUBLIC_PRAYER_ENDPOINT }} PUBLIC_NEWSLETTER_ENDPOINT: ${{ vars.PUBLIC_NEWSLETTER_ENDPOINT }} deploy: diff --git a/AGENTS.md b/AGENTS.md index 1e8bb78..55a7971 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,21 +1,23 @@ # AGENTS.md — Indigitous Philippines website -Read this file before you change anything. It applies to human contributors and to AI coding agents (Claude Code, Cursor, Codex, Copilot and others). +Read this file before you change anything. It applies to human contributors and to AI coding agents (Cursor, Codex, Copilot and others). + +The source of truth for structure and copy is the team's **Wireframe & Copy Deck** (Nov 4, 2026). When the deck and the code disagree, follow the deck, or ask. ## What this is -This is the static website for **Indigitous Philippines**, the Philippine community of [Indigitous](https://indigitous.org). Indigitous is a global network (since 2013, partnered with Cru) helping followers of Jesus take the gospel to new people, places and spaces through tech and creativity. Its flagship program is **#HACK**, a faith-driven hackathon held every October. +This is the static website for **Indigitous Philippines**: a movement of Filipino believers using their gifts for missions in a digital age. It is part of the global [Indigitous](https://indigitous.org) movement. The name joins _indigenous_ (locally rooted, culturally adapted) and _digital_ (the tools and spaces where people now gather). - Live: https://indigitousph.github.io (GitHub Pages) -- Languages: English (`/`) and Filipino (`/fil/`) +- Language: English, with small Filipino touches. Helpers in `src/i18n/` keep the door open for Filipino later. - Component showcase: `/storybook` ## Stack -- **Astro 7**, static output. There's no UI framework, and pages ship almost zero JS. +- **Astro 7**, static output. There is no UI framework, and pages ship almost zero JS. - **Tailwind CSS 4** via `@tailwindcss/vite`. Design tokens live in `src/styles/global.css` (`@theme`). - **TypeScript** in strict mode. Path alias `@/*` points to `src/*`. -- **Content collections** (Markdown/MDX + Zod schemas) for events, communities, projects, stories and team. +- **Content collections** (Markdown + Zod schemas). A missing date or broken link fails the build instead of the live site. - **pnpm**, Node 22+. ## Commands @@ -29,110 +31,196 @@ pnpm preview # serve dist/ pnpm format # prettier ``` -Run `pnpm build` before you call a change done. It must finish with **0 errors**. +Run `pnpm build` before you call a change done. It must finish with **0 errors**. Test at **360px** wide, since most visitors arrive from Facebook or Messenger on a phone. + +## Site map (from the deck) + +| Page | URL | Primary call to action | +| --------------------- | ------------------------------------ | ----------------------------------------------------- | +| Home | `/` | Join a local network | +| About | `/about` | Meet the team (`/about#team`) | +| Local Networks | `/networks` | Find your local network (interest form at `#connect`) | +| #HACK | `/hack` | Register for the next #HACK | +| Pray & Online Workers | `/pray` | Join the prayer time | +| Stories | `/stories`, `/stories/[slug]` | Read a story | +| Partner & Give | `/partner` | Partner with us | +| Contact | `/contact` | Send a message | +| _Footer only_ | `/events`, `/projects`, `/resources` | Not in the deck; kept as extras | + +- **Header:** Home · About · Local Networks · #HACK · Pray · Stories, plus a **Partner with us** button. +- **Footer:** Brand / Explore / Get involved / Stay connected, with the newsletter. +- **Old URLs** from the first version (including the retired `/fil/` pages) redirect via `redirects` in `astro.config.mjs`. ## Folder map ``` src/ components/ - ui/ Button, PillTag, SwitchTabs, Field, Icon, Logo, Placeholder - cards/ EventCard, StoryCard, CommunityCard, ProjectCard, TeamCard, TestimonialCard - sections/ Hero, PageHeader, Section, SectionHeading, CardGrid, StatsBand, CtaBand, - FeatureGrid, FAQ, NewsletterBand - layout/ Header, Footer + ui/ Button, Field, Choices, PillTag, SwitchTabs, Icon, Logo, Placeholder, + Countdown, AnnouncementBar + cards/ EventCard, NetworkCard, StoryCard, ProjectCard, TeamCard + sections/ one file per block named in the deck (see table below) + forms/ FormShell, InterestForm, PrayerForm, ContactForm + layout/ Header, Footer */X.stories.ts ← story for X.astro, rendered on /storybook - config/site.ts nav, socials, external links (edit links HERE) - content///.md(x) + config/site.ts nav, socials, external links, form endpoints (edit links HERE) + content/ + events/ #HACK and other events (date, endDate, venue, fee, register link) + networks/ one file per local network + stories/ Markdown stories (category: hack | networks | prayer | testimonies) + challenges/ #HACK challenges (see _example.md) + team/ team members + projects/ projects (footer-only page) + site/site.json announcement bar, prayer time, monthly prayer focus content.config.ts collection schemas - i18n/ en.ts, fil.ts (short UI strings), index.ts (helpers) - layouts/BaseLayout.astro , SEO, header/footer - lib/content.ts getLocalized() + sort helpers - lib/story.ts Story type for *.stories.ts - pages/ thin route files only (EN at root, FIL under pages/fil/) - pages/storybook/ component showcase + i18n/ en.ts (short UI strings) + helpers (t, formatDate, formatRange) + layouts/BaseLayout.astro , SEO, announcement, header, footer, shared scripts + lib/content.ts getAll, getFeaturedEvent, getSite, sort helpers + pages/ one file per page; page copy sits in a `copy` object at the top styles/global.css Tailwind import + brand tokens - views/ one file per page; holds the page's layout and copy -public/ favicon, OG image, robots.txt, static images +public/ favicon, OG image, robots.txt, images ``` +## Deck block → component + +| Deck name | Component | +| -------------------------------------------- | ------------------------------------------------------------------------------------- | +| Header / Footer / AnnouncementBar | `layout/Header`, `layout/Footer`, `ui/AnnouncementBar` | +| Hero / PageHero / EventHero | `sections/Hero`, `sections/PageHero`, `sections/EventHero` (+ `ui/Countdown`) | +| Intro | `sections/Intro` | +| Pillars / IconList | `sections/FeatureGrid` (`variant="cards"` / `"plain"`) | +| EventFeature / EventDetails | `sections/EventFeature`, `sections/EventDetails` | +| Gifts / StoryCards | `sections/Gifts`, `sections/StoryCards` | +| CTABand / StartBand / GlobalBand | `sections/CTABand`, `sections/StartBand`, `sections/GlobalBand` | +| SplitText / Timeline / Beliefs | `sections/SplitText`, `sections/Timeline`, `sections/Beliefs` | +| TeamGrid | `cards/TeamCard` in a grid on `/about` | +| NetworkCards | `cards/NetworkCard` in a grid on `/networks` | +| Steps / ChallengeCards / Gallery / Accordion | `sections/Steps`, `sections/ChallengeCards`, `sections/Gallery`, `sections/Accordion` | +| PrayerFocus | `sections/PrayerFocus` | +| InterestForm / PrayerForm / Contact form | `forms/InterestForm`, `forms/PrayerForm`, `forms/ContactForm` | + ## Core conventions (follow these) -1. **Pages are written once, in `src/views/`.** Route files in `src/pages/` and `src/pages/fil/` only render a view with `lang="en"` or `lang="fil"`. Never put page markup in `src/pages/`. -2. **Every UI string is translated.** - - Short reusable strings (nav, buttons, labels) go in `src/i18n/en.ts` and `fil.ts`. TypeScript fails the build if a key is missing from `fil.ts`. - - Page copy goes in a `copy = pick({ en: {...}, fil: {...} }, lang)` object at the top of the view. -3. **Internal links go through `localizePath(path, lang)`.** Never hard-code `/fil/...`. -4. **Use design tokens only.** Use `bg-brand-orange`, `text-ink`, `rounded-pill`, `font-mono` and so on. Don't use raw hex values or arbitrary colors like `bg-[#ef4e25]` in components. -5. **Every component in `src/components/` has a `*.stories.ts` file.** Its variants show on `/storybook`. Cards and sections take plain props, not collection entries, so they can be demoed. -6. **Content lives in collections, not in views.** To add an event, add a Markdown file. Don't edit the page. -7. **Keep JavaScript minimal.** Prefer `
`, CSS, and small inline ` diff --git a/src/components/forms/PrayerForm.stories.ts b/src/components/forms/PrayerForm.stories.ts new file mode 100644 index 0000000..c2dd53e --- /dev/null +++ b/src/components/forms/PrayerForm.stories.ts @@ -0,0 +1,14 @@ +import type { Story } from '@/lib/story'; +import PrayerForm from './PrayerForm.astro'; + +export default { + title: 'PrayerForm', + component: PrayerForm, + description: + 'Posts to a form service. The first variant uses a demo endpoint; the second shows the fallback when no endpoint is configured.', + width: 'md', + variants: [ + { name: 'With endpoint', props: { endpoint: '#' } }, + { name: 'No endpoint (fallback)', props: { endpoint: '' } }, + ], +} satisfies Story; diff --git a/src/components/layout/Footer.astro b/src/components/layout/Footer.astro index 06d8a0d..8a9374a 100644 --- a/src/components/layout/Footer.astro +++ b/src/components/layout/Footer.astro @@ -1,44 +1,50 @@ --- import Logo from '../ui/Logo.astro'; import Icon from '../ui/Icon.astro'; -import { footerNav, site } from '@/config/site'; -import { localizePath, useTranslations, type Lang } from '@/i18n'; +import Button from '../ui/Button.astro'; +import { exploreNav, forms, involvedNav, site } from '@/config/site'; +import { t } from '@/i18n'; -interface Props { - lang: Lang; -} -const { lang } = Astro.props; -const t = useTranslations(lang); +/** Footer (deck: Footer.astro): dark band, four columns (Brand / Explore / Get involved / Stay connected). */ const year = new Date().getFullYear(); +const linkClass = 'text-white/85 hover:text-brand-yellow'; ---