Commit Graph
805 Commits
Author SHA1 Message Date
joshuaandClaude Opus 5.5 3a9b032dfa app: changelog and README for the admin, uploads, backups and the export
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:53:58 +02:00
joshuaandClaude Opus 5.5 d8a101567b app: the church export's app part (APP-1.0-PLAN §11)
crosscode.church-export/1 with its app part, in plain terms with refs made
for the export: members as people with every role, the wall's rules,
commitments as rules (with skips), "I prayed" marks, campaigns, testimonies,
prayer requests with their updates and moderation (who and why; the whole
export is encrypted by the agent), the emergency numbers, announcements,
the church's own devotionals (not Cross Code's) and simple events; uploaded
images listed under uploads/. scripts/export-church.ts writes export.json
for the crosscode script (app.sh comes with slice 7). A test checks the
schema and that no internal id is in it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:53:27 +02:00
joshuaandClaude Opus 5.5 62cfb18c0b app: backups of the database and the uploaded images (APP-1.0-PLAN §10)
As the Website's: a gzipped pg_dump into backend/backups every night (02:40,
after Accounts' and the Website's) and on Back up now, named as the
crosscode script names them (app-YYYYMMDD-HHMMSS.sql.gz); a failed dump
leaves no file; the newest kept (14 by default). After each, a snapshot of
backend/uploads, hard-linking what hasn't changed. Settings → Backups lists
both, backs up now, downloads (audited) and sets how many to keep and what's
nightly; Owner and Church admin only. The heartbeat reports the newest
backup.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:50:17 +02:00
joshuaandClaude Opus 5.5 c934f47b28 app: uploaded images for announcements, campaigns and events (APP-1.0-PLAN §10)
Photos (JPEG, PNG, WebP, checked by their bytes) uploaded in the admin are
turned upright, stripped of their metadata and kept at most 2000 px wide in
backend/uploads (UPLOAD_DIR), served at /api/uploads (never a listing, a
sandboxing CSP). Content keeps the image's full address, so an upload and an
image from elsewhere work alike. 5 GB included or the licence's storage
limit; an image still in use can't be deleted. The announcement, campaign
and event forms get Upload a photo next to the address. Migration media.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:47:33 +02:00
joshuaandClaude Opus 5.5 13eaaffb95 app: the admin's side menu and pages: members, settings, jobs, logs, share (APP-1.0-PLAN §10)
Every admin page in one frame, as the Website's and Events' admins (decision
9): a bar across the top, a white side menu in groups (only what the roles
and modules allow), a drawer on a phone. The dashboard has the setup
checklist, the stat cards, what's waiting, this week on the prayer wall and
recent changes. New: Members and roles, Settings (modules, the licence and
active members, each module's settings), Background jobs, Audit and access
logs, and Share the App with a printable A4 poster and its QR code (drawn on
the server with qrcode). Role names in lib/roles.ts for client components.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:42:31 +02:00
joshuaandClaude Opus 5.5 f4cf5587be app: the admin's backend: members and roles, jobs, logs, the setup checklist (APP-1.0-PLAN §10)
Members and roles: members searched by name or email with what they hold;
roles given and taken by an Owner or Church admin (only an Owner makes or
changes an Owner, nobody changes their own), or someone added by email with
a role through Accounts' people.ensure. Background jobs: each job's switch
and schedule (winning over the .env) and Run now. The audit log and the
access log in plain words, 100 at a time. The dashboard's overview adds the
setup checklist (the church's details and icon, the wall's rules, prayer
coordinators, a first announcement, sharing the App), this week's coverage
and gaps, what waits for the prayer team and recent changes, each for the
roles it's about; Share the App marks the checklist.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:42:30 +02:00
joshua 5619a65936 Merge branch 'main' into feat/app-scaffold 2026-12-01 14:29:51 +02:00
joshua 9766db1f72 Merge branch 'docs/app-slice-5' 2026-12-01 14:29:44 +02:00
joshuaandClaude Opus 5.5 138abe90f6 docs: App slice 5 done (email and WhatsApp)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:29:41 +02:00
joshuaandClaude Opus 5.5 fc0a4ad6a0 app: email and WhatsApp's screens, changelog and README (APP-1.0-PLAN §8)
Me → What the App sends me (email, WhatsApp, both or off per kind, the
devotional's time; WhatsApp only to a verified number that hasn't replied
STOP), today's devotional offered once on Home after the first sign-in, the
booking sheet picking WhatsApp for reminders when it reaches the member, and
Admin → Email and WhatsApp (what it sends from, where it's changed, Fetch
again, Send me a test, messages waiting and not sent).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:29:14 +02:00
joshuaandClaude Opus 5.5 8bfd0b767d app: email and WhatsApp's backend (APP-1.0-PLAN §8)
The church's one set of settings from Accounts (messaging.get; the SMTP
password and WAWP token sealed with the link's secret, kept encrypted in
AppSetting messaging_settings), fetched when the App links to Accounts, on
Accounts' signed messaging.changed, once a day and on the admin's Fetch again.

messages-send (every minute): the outbox by email (nodemailer) and WhatsApp
(WAWP), STOP checked before every WhatsApp (the member and anyone with the
same number), email instead for what a member asked for (never
announcements), retries after 2, 4, 8 and 16 minutes, a reminder never after
its slot started, nothing more than 3 days late. announcement-sends and
devotional-sends queue "Also send it" at the publish time and today's
devotional at each member's time. Members' choices (NotificationSettings),
news consent kept from Accounts, MessageCount for the heartbeat's messages,
the admin's Email and WhatsApp API with Send a test.

Migration messaging (checked on PostgreSQL 18). 110 backend tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 14:29:13 +02:00
joshua 7ff318a682 Merge remote-tracking branch 'origin/main' into feat/app-scaffold 2026-12-01 13:41:49 +02:00
joshua 5097d622ff Merge branch 'docs/app-sync-website-1.12.1' 2026-12-01 13:41:29 +02:00
joshuaandClaude Opus 5.5 b0ab0dbcab docs: the App's progress in VERSIONS, @crosscode/seo 1.1.0 on the App branch, Website 1.12.1 in the handover
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 13:41:17 +02:00
joshua 63481bee12 Merge remote-tracking branch 'origin/main' into feat/app-scaffold 2026-12-01 13:40:42 +02:00
joshua 53f28cd7dd Merge branch 'docs/deployed-website-1.12.1' 2026-12-01 13:38:05 +02:00
joshuaandClaude Opus 5.5 faf6eea39a docs: Website 1.12.1 deployed
Runs on cross-demo2 (2026-12-01): the release entry and the Deployed / rolled out table.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 13:38:04 +02:00
joshua 1e5f345efa Merge branch 'fix/website-map' website@1.12.1 2026-12-01 13:31:48 +02:00
joshua 2e9df29f1e Merge branch 'docs/app-slice-4' 2026-12-01 11:38:54 +02:00
joshuaandClaude Opus 5.5 33088c1377 website 1.12.1: the With map layouts show the map
- Accounts' profile never has the address's geo, so Service times' and Contact's map layouts
  never drew a map. church/geocode.ts looks the address up on OpenStreetMap's Nominatim (the
  street, else the suburb and city) for the public site and the preview, kept in AppSetting
  church_geocode per address; one not found is retried after a day.
- Tests: backend (157, one new, with a stand-in Nominatim).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 11:38:53 +02:00
joshuaandClaude Opus 5.5 adf9ac7d1e docs: App slice 4 done (announcements, devotionals and events)
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 11:38:40 +02:00
joshuaandClaude Opus 5.5 0ac6827ddd app: announcements, devotionals and events' screens; @crosscode/seo 1.1.0 (APP-1.0-PLAN §5-§7)
Public pages: Home with today's devotional, the latest announcements (pinned
first) and what's on; Announcements and each one's page (markdown without
HTML, a button, Article JSON-LD; members-only ones ask for a sign-in and are
noindex); Devotional (the passage in full with its copyright line, Read in
YouVersion, the prayer), each day's page, the archive by month and the
Acknowledgements; Events and each one's page (Register on the Events site for
Cross Events', a canonical to the origin, Event JSON-LD on the App's own).
A sitemap of the public pages, named in robots.txt.

Admin: Announcements (schedule, end, pin, campus, who sees it, also send it),
Events (simple events, Linked products: publish and show events from), and
Devotionals (Cross Code's or our own, Sync now, a month's days, writing, the
CSV import with its preview, keep or replace days already filled).

@crosscode/seo 1.1.0: articleJsonLd. The backend gives the App's own address
and the sitemap's list, and a simple event's crosscode.event/1 for its page.

Checked in a browser on a throwaway PostgreSQL: the pages for a visitor, the
JSON-LD, a members-only announcement asking for a sign-in, the sitemap, a
Content admin publishing an announcement and a Devotional writer saving one;
no page errors. 94 backend tests, 19 seo tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 11:36:41 +02:00
joshuaandClaude Opus 5.5 a9079f1195 app: announcements, devotionals and events' backend (APP-1.0-PLAN §5-§7)
Announcements: public or members-only, pinned, a campus, a publish time and an
end, an optional button, markdown text; Content admins write them; the
heartbeat counts the last 30 days; "also send it" flags kept for §8.

Devotionals: Cross Code's from the Hub each night and on Sync now (the next
2 weeks from today in the church's timezone, with the licence; exactly those
days replaced, the rest kept, a Hub outage changes nothing), or the church's
own by its Devotional writers, by hand or the same CSV import as the Hub's
(preview, then replace or skip days already filled). Only KJV and BSB; the
passage with its copyright line and Read in YouVersion; today's or the most
recent; the archive by month; members-only ones; the acknowledgements.

Events: simple events in the church's timezone, and the feed both ways as the
Website's (publish its own as crosscode.event/1 with removals; read-only copies
of Cross Events' and the Website's, Register on the Events site, canonical to
the origin). Jobs event-feed (15 min) and crosscode-devotionals (01:15).
Migration 20261204000000_content (checked on PostgreSQL 18: applies, no diff).
93 backend tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 11:20:31 +02:00
joshua 710b762ddf Merge branch 'main' into feat/app-scaffold 2026-12-01 11:10:27 +02:00
joshua 76a44c9880 Merge branch 'docs/app-slices-2-3' 2026-12-01 11:10:16 +02:00
joshuaandClaude Opus 5.5 07182656b2 docs: App slices 2 and 3 done (House of Prayer, prayer requests); decision 15; deploys caught up
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 11:10:06 +02:00
joshuaandClaude Opus 5.5 655852278f app: changelog and README for prayer requests
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 11:06:17 +02:00
joshua 4b8cb1da4b Merge branch 'main' into feat/app-scaffold 2026-12-01 11:05:26 +02:00
joshuaandClaude Opus 5.5 09e98f6b56 app: prayer requests' screens (APP-1.0-PLAN §4)
Ask for prayer (who will see it said plainly, the prayer team by default; for
members the first name or Anonymous, approved first; fully anonymous when the
church allows it; the emergency numbers, signed out too), Pray for others (the
shared list with "I prayed"), My prayer requests (state, what the team changed
or why it wasn't shared, the team's private replies, "Answered!", close,
delete). The admin's Prayer requests: waiting, open, escalated and closed;
approve, edit out details, don't share, reply, escalate; the settings. Pastoral
care sees open and escalated requests. The Prayer tab shows with either prayer
module and opens requests when the House of Prayer is off.

Checked in a browser on a throwaway PostgreSQL: a member asks, a coordinator
edits out a name and approves, another member sees the edited text and prays,
the sender sees the note and the count but not who; no page errors.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 11:05:26 +02:00
joshua bc010fbe33 Merge branch 'docs/deployed-website-1.12.0' 2026-12-01 11:04:41 +02:00
joshuaandClaude Opus 5.5 4ffc6d27f0 docs: Website 1.12.0 deployed
Runs on cross-demo2 (2026-12-01): the release entry and the Deployed / rolled out table.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 11:04:41 +02:00
joshua 50bce1928e Merge branch 'feat/website-page-layouts' website@1.12.0 2026-12-01 11:00:19 +02:00
joshuaandClaude Opus 5.5 777b045053 website 1.12.0: three layouts for each page that lists something
- PAGE_VARIANTS: ministriesPage alternating/cards/list, leadershipPage grid/featured/list,
  eventsPage list/cards/months, messagesPage grid/featured/list, contactPage
  columns/map/cards. Kept in the design's variants beside the homepage sections', so each
  template recommends some and starts a new site on the first (its suggestion), PUT /design
  checks them, and a template switch moves an untouched one.
- A design saved before has none: cleanDesign gives it LEGACY_PAGE_LAYOUTS (the look until
  now), and the site draws a snapshot without them the same way, so nothing changes until a
  church picks one. Contact's map layout without a place on the map draws as two columns.
  Ministries and messages keep their #slug anchors in every layout.
- Admin: the layout at the top of a listing page in Pages, the suggestion marked; Template
  and style gets an Other pages tab with all five.
- Tests: backend (156, five new); e2e page-layouts.spec.ts (every layout in every template,
  axe at phone and desktop; 60 passed).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 10:59:59 +02:00
joshuaandClaude Opus 5.5 6425a6a30d app: prayer requests' backend (APP-1.0-PLAN §4)
Private by default (the prayer team only) or shared with members after a
coordinator approves it, with the first name or "Anonymous"; fully anonymous
requests when the church allows them (off by default). Coordinators approve,
redact (the sender told what changed) or remove (with a reason); anyone on the
team can escalate to Pastoral care (email and WhatsApp at once, an Owner or
Church admin when nobody has the role): it leaves the shared list and the sender
sees nothing different. "I prayed" counts without who, "Answered!" updates,
private replies from the team, closing after 30 days (7-90) and deletion 12
months later (prayer-requests-tidy). Every list with a sender is access-logged;
messages never carry a request's text; nothing in the heartbeat. Export and
delete for a member's requests. Shared helpers: parse (http.ts), accessLog
(lib/accessLog.ts). Migration 20261203000000_prayer_requests (checked on
PostgreSQL 18: applies, no diff). 78 backend tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 10:56:53 +02:00
joshuaandClaude Opus 5.5 1dd3aadb60 app: the House of Prayer's screens, changelog and README (APP-1.0-PLAN §3)
The 24-hour clock on the Prayer tab (midnight at the top, the night half darker,
open slots dashed, your own in gold, a hand at now), live over the stream with
polling as the fallback; tap an hour for Cover it / Join, the open hours as
buttons; signed out, back from Accounts with that slot's sheet open. The booking
sheet (once, every week, every day; length, end, reminder and channel, a note),
Me → My prayer (skip, add back, reminder, end date, stop, renew, "I prayed"),
the renew and "I prayed" link pages, sharing a testimony, Home's small clock
with the next gap and your next slot, the campaign card. The admin's House of
Prayer: the week, who prays when (names, access-logged), booking for a member,
the rules, campaigns, testimonies.

Checked in a browser on a throwaway PostgreSQL: one member books through the
sheet and a visitor's clock updates live; no page errors.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 10:42:35 +02:00
joshuaandClaude Opus 5.5 5213bb36c0 app: the House of Prayer's backend (APP-1.0-PLAN §3)
Commitments stored as rules (start, length, once/daily/weekly, end, skips) in the
church's timezone, daylight saving included; the day's coverage as counts only,
cached until a booking changes, live over server-sent events (X-Accel-Buffering
off, a comment every 25 s). Booking, skipping, changing, cancelling within the
8-hour rule, renewing (a signed single-use link), "I prayed" (self-reported).
Campaigns and moderated testimonies; the admin's bookings with names, always
access-logged; booking on a member's behalf. Reminders (every minute) and
renewal notices (14 and 3 days before) queued in an outbox for the messaging
slice. The heartbeat's prayer counts; export and delete for a member's prayer.
Migration 20261202000000_house_of_prayer (checked on PostgreSQL 18: applies, no
diff). 66 backend tests.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 10:29:39 +02:00
joshua 6726518175 Merge branch 'main' into feat/app-scaffold 2026-12-01 10:12:07 +02:00
joshua 43187513d7 Merge branch 'docs/deployed-2026-12-01' 2026-12-01 10:03:01 +02:00
joshuaandClaude Opus 5.5 35c4dd6915 docs: Events 3.9.0, Accounts 1.10.0, Website 1.11.0 and agent 1.7.0 deployed
The latest release of everything runs on the churches, cross-demo2 and both agents
(2026-12-01): the release entries and the Deployed / rolled out table.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 10:02:59 +02:00
joshua b9b2cadcd3 Merge branch 'feat/blocks-layouts-video' website@1.11.0 2026-12-01 09:57:13 +02:00
joshuaandClaude Opus 5.5 f5f778f0d7 website 1.11.0: layouts and backgrounds for the blocks; a video for the top of the page
- Blocks get layouts (BLOCK_VARIANTS: text standard/centred; image and text photo left,
  right or above; quote centred/with a line; call to action centred/banner), stored on
  Section.variant and checked against the type; an unknown one draws as the default, as
  every block looked before. The demo's image-text block id is now image-left.
- Each block has its own background (Section.background, migration
  20261201000000_block_background), in the published source only when set, put back by
  Discard and Restore, drawn as the homepage's (data-bg).
- MP4 uploads up to 20 MB for the hero's Video layout: QuickTime refused, metadata boxes
  (udta, meta, uuid) blanked into free boxes of the same size so where it was filmed is
  gone and the frame offsets hold; size read from tkhd. GET /media lists mime.
- Admin: a block's Layout and Background when open; the hero's Video field (only videos;
  photo fields only photos); the media library shows and takes videos. An upload over the
  limit says so instead of "That request isn't valid."
- Tests: backend (152, three new); e2e for block layouts and a video upload.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 09:57:02 +02:00
joshua a38468ba47 Merge branch 'feat/home-sections-on-page' website@1.10.0 2026-12-01 08:56:13 +02:00
joshuaandClaude Opus 5.5 8b1d1da5a9 website 1.10.0: the home page laid out from its editor; photos that match the layout
- Pages → Home: each section's layout and background when it's open, and move up, move down
  and show or hide on its header. They save straight to the design, as Template and style →
  Home page layout does (which keeps them too). Shared lists in admin/layouts.ts.
- A section offers only the photo fields its layout shows: a slot for each (hero: 1 for Photo,
  Video and Split, 3 for Collage, none for Text only); Welcome's photo and pastor and the
  Invitation's photo only for the layouts that use them. Photos for other layouts are kept.
- e2e: the hero opens with /^Top of the page/; a new test for the editor's layout controls.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 08:56:08 +02:00
joshua 101248195f Merge branch 'fix/church-from-accounts' events@3.9.0 website@1.9.0 accounts@1.10.0 2026-12-01 00:54:27 +02:00
joshuaandClaude Opus 5.5 805967a85a events 3.9.0: SVG logos in PDFs (svg-to-pdfkit), the Accounts logo copied for PDFs
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 00:54:25 +02:00
joshuaandClaude Opus 5.5 8055e1ec62 events 3.9.0, website 1.9.0, accounts 1.10.0: the church's details from Accounts everywhere
- Events: the Accounts profile's name, logo, icon, colours and contact details win over
  Events' own settings while Accounts is connected (pages, emails, WhatsApp, PDFs); Settings
  shows them read-only with a link to Accounts. The Accounts logo is copied for PDFs (PNG
  and JPEG). Fixes Events keeping its old church after a demo scenario load.
- Website: a background per homepage section in the church's colours; "More info" instead
  of "Register" for events without registration; the shared colour field.
- Accounts: the shared colour field in Church profile.
- @crosscode/ui 0.4.0: ColourField and isHexColour.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 00:46:39 +02:00
joshuaandClaude Opus 5.5 0dd1284ee8 app: the README names the branch it's built on
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 00:26:23 +02:00
joshua d0eff65e6d Merge branch 'main' into feat/app-scaffold
# Conflicts:
#	docs/APP-1.0-PLAN.md
#	docs/HANDOVER.md
#	docs/ROADMAP-v3.md
#	docs/VERSIONS.md
2026-12-01 00:26:09 +02:00
joshua 799c193fe1 Merge branch 'docs/app-foundation' 2026-12-01 00:25:48 +02:00
joshuaandClaude Opus 5.5 f651ae2530 docs: the Hub runs 2.26.1 with two years of devotionals; App 1.0.0 on feat/app-scaffold
- Apps get 2 weeks of Cross Code's devotionals, today included.
- The App is built in slices on feat/app-scaffold (pushed, merged into
  main only when app@1.0.0 is done); the foundation is done.
- VERSIONS: the Hub at 2.26.1 in "Deployed / rolled out".

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-12-01 00:25:48 +02:00