LifeMate — Personal, Family & Learning Companion
feat/private-planner-series-api
chore/phase1-repository-cleanup
deploy/stable-web-apk
deployment-static
design/mobile-accessibility-v2
design/mobile-navigation-review
docs/child-education-access-decision
docs/offline-data-rescue-options
docs/owner-guide-and-delivery-plan
docs/phase1-policy-options
docs/public-review-live-2026-10-15
feat/aparat-learning-library
feat/child-device-safety
feat/child-identity-schema
feat/flutter-mobile-navigation
feat/learning-content-operations
feat/local-signing-preflight
feat/online-family-stage0
feat/personal-encrypted-recovery
feat/private-planner-series-api
feat/public-review-page
feat/standalone-weekly-planner
feat/weekly-planner-android
final-feature-1/iran-family-school
fix/auth-abuse-expiry-safety
fix/auth-expiry-after-lock
fix/backend-request-safety
fix/lifeguide-bootstrap-naming-ci
fix/lifeguide-pages-qa-base-preflight
fix/lifeguide-qa-pages-env-deployment
fix/local-task-persistence
fix/managed-child-session-boundary
fix/personal-jalali-dates
fix/personal-notification-controls
fix/personal-upgrade-delivery-guard
fix/sms-approval-gates
fix/study-duration-display
infra/cloudflare-neon-migration
infra/lifeguide-cloudflare-qa
infra/lifeguide-github-pages-qa
infra/lifeguide-supabase-qa
main
phase-1/foundation-completion
phase-2/product-foundation-identity
phase-3/planner-school-family-core
phase-4/ai-learning-wellbeing
phase-5/hardening-observability-release
test/android-reminder-acceptance
test/personal-notification-settings
test/personal-recovery-acceptance
test/role-entry-apk
| 1 | **Historical snapshot — retained as decision/evidence history. Current product: LifeGuide; current execution status: PROJECT_STATE.md.** |
| 2 | |
| 3 | # Phase 2 — Product Foundation & Identity Implementation Plan |
| 4 | |
| 5 | Status: IN PROGRESS |
| 6 | |
| 7 | ## Acceptance contract |
| 8 | Phase 2 is complete only when a real Flutter Android/Web-PWA scaffold exists; email/password auth supports verification, recovery and password change; profiles and family workspaces exist; invitations and guardian relationships are server-authorized; RTL/theme shells exist for teen/parent; CI builds/tests Android and Web; and a separate staging PostgreSQL backend has been exercised. |
| 9 | |
| 10 | ## Architecture revision |
| 11 | Supabase is no longer a required platform dependency. LifeMate uses provider-neutral backend ports with PostgreSQL as the durable relational core. Neon is the preferred managed PostgreSQL target when its connector is operational, but application/domain code must not depend on Neon-specific APIs. |
| 12 | |
| 13 | Provider boundaries: |
| 14 | - Database: PostgreSQL 17-compatible SQL; managed target may be Neon. |
| 15 | - Authorization: server-side policy/service layer backed by relational membership/guardian grants; PostgreSQL RLS may provide defense in depth where supported. |
| 16 | - Authentication: `IdentityProvider` port; provider implementation can be changed without altering domain entities. |
| 17 | - Object storage: `ObjectStorage` port; not required for Phase 2 identity acceptance. |
| 18 | - Email: `TransactionalEmail` port for verification/recovery/invitations. |
| 19 | - Realtime: optional adapter; no Phase 2 domain rule depends on realtime delivery. |
| 20 | |
| 21 | ## Execution order |
| 22 | 1. Scaffold Flutter app and platform assets. |
| 23 | 2. RED tests for role/theme/auth/family domain behavior, then minimal GREEN implementation. |
| 24 | 3. Add provider-neutral client repositories for auth/profile/family flows. |
| 25 | 4. Add versioned PostgreSQL schema, constraints, authorization policy tests and optional RLS defense-in-depth policies. |
| 26 | 5. Add authentication UI: sign-in/up, verification state, forgot/reset/change password. |
| 27 | 6. Add profile + family workspace + invitation + membership/guardian UI. |
| 28 | 7. Add Persian RTL authenticated Teen/Parent shells and MyStudyLife-inspired direct student navigation. |
| 29 | 8. Add CI: format, analyze, tests, Android debug build, Web build, secret scan. |
| 30 | 9. Attach an isolated staging PostgreSQL environment, apply migrations, run authorization/smoke tests. |
| 31 | 10. Verify branch, update PROJECT_STATE, PR review and merge only after green evidence. |
| 32 | |
| 33 | ## Product rulings carried into implementation |
| 34 | - Student IA uses MyStudyLife as benchmark: direct access to Today, Schedule, Calendar, Tasks, Exams/Grades, Focus and AI; LifeMate family/wellbeing extensions remain additive. |
| 35 | - Theme defaults: girl/teen profile white + soft pink; boy/teen white + blue; parent/adult white + blue. Theme remains user-overridable later. |
| 36 | - Admin ownership never implies blanket access to private teen content. |
| 37 | - No wellbeing/AI production exposure in Phase 2. |
| 38 | |
| 39 | ## Environment rule |
| 40 | Local, staging and production are distinct. Staging must not reuse Finora/EasyFactor infrastructure. The codebase must remain deployable to standard PostgreSQL even if a managed-provider connector is temporarily unavailable. |