diff --git a/docs/APP-1.0-PLAN.md b/docs/APP-1.0-PLAN.md index cb9457b..43e8beb 100644 --- a/docs/APP-1.0-PLAN.md +++ b/docs/APP-1.0-PLAN.md @@ -35,8 +35,11 @@ it goes on sale (crosscode-site, ROADMAP §9). **Done when:** -- `app@1.0.0`, `contracts@1.20.0`, `accounts@1.9.0`, `events@3.8.0` and Hub `v2.26.0` are tagged; the Hub installs +- `app@1.0.0`, `contracts@1.20.0` (released 2026-11-30), `contracts@1.21.0`, `accounts@1.9.0`, + `events@3.8.0`, `website@1.8.0`, `agent@1.7.0` and Hub `v2.26.0` are tagged; the Hub installs the App from New install (after Accounts) and lists its releases. +- On a demo client, **Load a demo scenario** in the Hub loads Accounts, Events, the Website and + the App with the same church, people and events, in one step (§12, "Demo scenarios"). - The Hub holds 3 months of Cross Code devotionals (written or imported from CSV), and an App set to "From Cross Code" shows and sends them. - A member can add the App to their home screen (Android and iPhone), sign in once, book a one-off @@ -430,7 +433,8 @@ the band in Settings → Licence. Visitors browsing signed out never count. - **`crosscode`:** `scripts/products/app.sh` with the same hooks as the Website (`app` is already in `PRODUCT_ORDER`), `app.env.template.json` (the env template in three places, HANDOVER "A new .env variable"), `crosscode add app`. -- **Agent:** none expected (the job schemas already take `app`). Check `demo` passes `app` on. +- **Agent 1.7.0:** `seed-demo` for `app` and `accounts` (1.6.0 only passes `website` on to + `crosscode demo`), and demo scenarios (below). - **Accounts, otherwise:** Connect already accepts the App as a client (`CLIENT_PRODUCTS`) and the profile already has `links.app`. The Website's and Events' headers and `ChurchFooter` show "App" as soon as the link is there. @@ -438,18 +442,74 @@ the band in Settings → Licence. Visitors browsing signed out never count. three months of commitments and a few gaps, a campaign, testimonies, devotionals, announcements and events, for screenshots and the Hub's demo sites. +### Demo scenarios (requirement added by Joshua 2026-11-30) + +Today each product loads its own demo on its own (Events: 4 profiles, the Website: 8 by template, +the App: Acacia Hill), and nothing makes them the same church. A **demo scenario** is a preset +combination: one choice on a demo client in the Hub loads **every product the client has** with +data that describes **the same church**, so a demo shows the three products working together. + +- **What "aligned" means:** in one scenario, every product has + - the same church profile in Accounts: name, short name, logo, colours, font pairing, campuses, + service times, contact and timezone; + - the same people, one account each in Accounts (all at `@example.com`, password `Demo@1234`): + the pastor who leads on the Website, runs an Events registration and is Owner in the App; a + prayer coordinator who also serves on an Events roster; members who register for events and + book prayer slots; + - the same events: made in Events (and the App's or Website's simple events where the scenario + has them), shown in the others through the event feed, never copied; + - the same campuses throughout (one, or three for the multi-campus scenario); + - content that fits the church: a prayer campaign before its conference, announcements about its + events, messages from its pastor. +- **Scenarios** (proposal, one per kind of church Cross Code sells to; each product's profile is + new or reworked to fit): + + | Scenario | Church | Events | Website | App | + |---|---|---|---|---| + | `small-family` | A small family church, one service | `small` | `community-family` | a small prayer wall, weekly devotionals of its own | + | `conference` | A young church running a big conference | `events` | `bold-youth` | a 21-day campaign before the conference | + | `ministry` | A weekly-ministry church: courses, kids, volunteers | `ministry` | `clean-modern` | prayer teams per ministry, Cross Code's devotionals | + | `multi-campus` | Three campuses, one church | `multicampus` | `clean-campus` | one prayer wall, announcements per campus | + | `heritage` | An old parish church | `small` (reworked) | `heritage-parish` | a quiet prayer wall, Afrikaans devotionals | + + Acacia Hill (cross-demo2) is one of them, chosen with Joshua when the App's demo data is written. +- **Contracts 1.21.0:** `agent.DEMO_SCENARIOS`: each scenario's key, label, description, and the + profile it uses for each product (`accounts`, `events`, `website`, `app`), so the Hub and the + agent agree; a test checks every profile it names exists. `seed-demo` takes an optional + `scenario`, and `accounts` joins `DEMO_PRODUCTS` (its demo is the church profile and the people). +- **Agent 1.7.0:** runs `crosscode demo --profile

[--scenario ]` for + every product, so a product can tell a scenario load from a single one. +- **Hub 2.26.0:** on a demo client (every install marked as a demo site), **Load a demo + scenario**: pick one from the list, see which installs it will replace (and any product the + client has that the scenario doesn't cover), type the client's short name once, and the Hub + queues one batch in order: **Accounts first** (profile and people), then **Events**, the + **Website** and the **App**, each job starting only after the one before it succeeded; a failure + stops the rest and says which product is now out of step. At the end the products sync the + event feed, and one email reports the whole batch. The client page shows the scenario last + loaded and when. Loading one product's demo on its own stays (as now), marked "out of step with + the scenario" until a scenario is loaded again. The Hub refuses a scenario when an install + needs a newer release (each scenario lists the minimum versions it needs). +- **Products:** each product's demo loader takes `--scenario` and builds that scenario's data: + Accounts (new: the profile and the people, replacing old demo people with `people.removeDemo`), + Events 3.8.0 (its 4 profiles reworked to the scenarios' churches and people), the Website 1.8.0 + (its profiles take the people and events of the scenario they're in) and the App 1.0.0. A + product without the scenario's profile refuses the job, so a half-loaded demo is never silent. + ## 13. What changes in each repo | Repo | Change | Version | |------|--------|---------| | `crosscode-platform` `apps/app` | New (§1–§12), with `CHANGELOG.md`, `WHATS-NEW.md`, `env.template.json`, e2e, demo data | `app@1.0.0` | -| `crosscode-platform` `packages/contracts` | `app` in `DEMO_PRODUCTS`, `APP_MODULES`, the `app` part of the church export, `crosscode.devotional/1` and its CSV rules, the translations, `messaging.get` | `contracts@1.20.0` | -| `crosscode-platform` `apps/accounts` | `messaging.get` for linked products, a hint when the messaging settings change, the WhatsApp opt-out for every product | `accounts@1.9.0` | -| `crosscode-platform` `apps/events` | STOP replies passed to Accounts; the opt-out read from Accounts | `events@3.8.0` | +| `crosscode-platform` `packages/contracts` | `app` in `DEMO_PRODUCTS`, `APP_MODULES`, the `app` part of the church export, `crosscode.devotional/1` and its CSV rules, the translations, `messaging.get`, `whatsapp.optout` | `contracts@1.20.0` (**released 2026-11-30**) | +| `crosscode-platform` `packages/contracts` | `agent.DEMO_SCENARIOS`, `scenario` in `seed-demo`, `accounts` in `DEMO_PRODUCTS` | `contracts@1.21.0` | +| `crosscode-platform` `apps/accounts` | `messaging.get` for linked products, a hint when the messaging settings change, the WhatsApp opt-out for every product; demo data (the scenario's church profile and people) | `accounts@1.9.0` | +| `crosscode-platform` `apps/events` | STOP replies passed to Accounts; the opt-out read from Accounts; demo profiles reworked to the scenarios | `events@3.8.0` | +| `crosscode-platform` `apps/website` | Demo profiles take the scenario's people and events (`--scenario`) | `website@1.8.0` | +| `crosscode-platform` `apps/agent` | `seed-demo` for `app` and `accounts`, `--scenario` passed on | `agent@1.7.0` | | `crosscode-platform` `packages/ui` | The tab bar and bottom sheet, if worth sharing; otherwise nothing | workspace | | `crosscode-platform` `packages/seo` | `Article` builder for devotionals and announcements; the icon generator for the manifest | workspace | | `crosscode-platform` `scripts/` | `products/app.sh`, `app.env.template.json`, bats tests | — | -| `events-hub` | App in New install, its releases, env template, billing on the band, renewal check, FastPanel email, Devotionals (write, schedule 3 months ahead, Import CSV, the endpoint for Apps) | Hub `v2.26.0` | +| `events-hub` | App in New install, its releases, env template, billing on the band, renewal check, FastPanel email, Devotionals (write, schedule 3 months ahead, Import CSV, the endpoint for Apps), **Load a demo scenario** on a demo client (vendored contracts 1.21.0) | Hub `v2.26.0` | | `crosscode-site` | Church App on sale (ROADMAP §9): its page, the active-member tiers, House of Prayer screenshots, the bundle examples (§10), FAQ, `SoftwareApplication` JSON-LD | `v1.10.0` | ## 14. Testing @@ -471,6 +531,11 @@ the band in Settings → Licence. Visitors browsing signed out never count. blocked, by polling); a shared request waits for approval; escalation; announcement and devotional publishing; offline Home; the manifest and service worker (installable); axe on every screen; the §11 checks on public pages and `noindex` on prayer pages. +- **Demo scenarios:** contracts: every profile a scenario names exists. Hub: the batch runs in + order, stops at the first failure and says what's out of step, refuses an install on too old a + release. On cross-demo2, each scenario loaded end to end: the same church name, logo and people + in all four products, Events' events on the Website and in the App, no leftover people from the + scenario before. - **Lighthouse (mobile):** Home, an event and a devotional: SEO 100, accessibility 95+, performance 90+. - **The release checks** (ROADMAP §9) for the App, and a throwaway install from the Hub (New @@ -479,15 +544,18 @@ the band in Settings → Licence. Visitors browsing signed out never count. ## 15. Releasing and rolling it out -1. `contracts@1.20.0`, then `accounts@1.9.0` (`messaging.get`, the WhatsApp opt-out) and - `events@3.8.0` (STOP passed to Accounts), rolled out to every church. -2. Hub `v2.26.0` (vendored contracts 1.20.0) deployed, and the first 3 months of Cross Code +1. `contracts@1.20.0` (**released 2026-11-30**), then `accounts@1.9.0` (`messaging.get`, the + WhatsApp opt-out) and `events@3.8.0` (STOP passed to Accounts), rolled out to every church. +2. `contracts@1.21.0` (demo scenarios), with the scenario demo loaders in Accounts 1.9.0, Events + 3.8.0, `website@1.8.0`, and `agent@1.7.0`. +3. Hub `v2.26.0` (vendored contracts 1.21.0) deployed, and the first 3 months of Cross Code devotionals written or imported. -3. `app@1.0.0` tagged after the e2e and Lighthouse runs. -4. **cross-demo2** (Acacia Hill): New install → App, demo data loaded, the throwaway test above. -5. **Hope Family Church:** New install → App; the prayer coordinators set the wall up before it's +4. `app@1.0.0` tagged after the e2e and Lighthouse runs. +5. **cross-demo2** (Acacia Hill): New install → App, every demo scenario loaded once, the + throwaway test above. +6. **Hope Family Church:** New install → App; the prayer coordinators set the wall up before it's announced to the church. -6. crosscode-site `v1.10.0`: the App on sale (prices already in the Hub). +7. crosscode-site `v1.10.0`: the App on sale (prices already in the Hub). ## Decisions @@ -516,6 +584,9 @@ Made by Joshua on 2026-11-30, after the first draft and the mockup: 11. **Accounts keeps the WhatsApp opt-out for every product,** so a STOP to the shared number reaches the App, Events and Accounts alike (§8). Adds Events 3.8.0. 12. **Home shows today's prayer clock** in small, as the House of Prayer does (mockup redrawn). +13. **Demo scenarios** (added later on 2026-11-30): on a demo client, one choice in the Hub loads + every product with the same church, people and events, from preset combinations (§12). Adds + contracts 1.21.0, agent 1.7.0 and Website 1.8.0, and demo data in Accounts 1.9.0. The other proposals as first written, confirmed: @@ -550,6 +621,7 @@ for a group; an app-store release; moving to the church's own domain (as the Web ## Still open -- **Which two Afrikaans translations** (§6): 1933/1953 and 1983 proposed. +- ~~Which two Afrikaans translations~~: 1933/1953 and 1983, confirmed by Joshua 2026-11-30 (YouVersion ids checked, contracts 1.20.0). - **The publishers' terms** for quoting each translation in an app (§6), checked before Cross Code's devotionals go out; ask for permission where the terms don't cover it. +- **The demo scenarios** (§12): the list and each one's church, and which one is Acacia Hill.