Interactive 30-day couples reflection Progressive Web App (PWA) powered by Next.js, Supabase, and Google Gemini AI — turning a structured 30-day relationship workbook into a private, synchronized digital experience for couples.
flowchart LR
subgraph PWA["Next.js 16 PWA (Mobile & Desktop)"]
P1["Partner A Private Answers"]
P2["Partner B Private Answers"]
Dash["Dashboard, Traffic-Light Meter & Report"]
Admin["Admin Panel (/admin)"]
end
subgraph Backend["Next.js API Routes"]
RefAPI["/api/reflexion (Daily AI Summary)"]
AnaAPI["/api/analisis (Journey Insights)"]
end
subgraph Services["Cloud Services"]
Supa["Supabase (PostgreSQL + RLS + Auth)"]
Gemini["Google Gemini 2.0 Flash API"]
end
P1 --> Supa
P2 --> Supa
Dash --> Supa
Admin --> Supa
Dash --> RefAPI
Dash --> AnaAPI
RefAPI --> Gemini
AnaAPI --> Gemini
- Private Couple Spaces — Individual user authentication with invite-code pairing so each couple shares an isolated, private workspace.
- Structured 30-Day Journey (300 Prompts) — 10 progressive questions per day (
src/data/program.json); Day 1 is unlocked as a full free demo, while Days 2–30 unlock via single-use access codes. - Privacy-First Answer Reveal — Each partner answers privately first; shared reflection unlocks only once both partners submit their responses.
- AI-Assisted Daily Reflections — Integrates Google Gemini (
gemini-2.0-flash) via/api/reflexionand/api/analisisto generate empathetic, non-clinical daily summaries and relationship insights. - Connection Tracking — 1–10 daily connection meter, traffic-light status indicator (
Semaforo), progress visualization across all 30 days, and a final completion report. - PWA & Admin Panel — Installable mobile experience (
manifest.json+ Service Worker) plus an/admindashboard to manage single-use access codes without accessing private couple answers.
| Layer | Technologies |
|---|---|
| Frontend & App | Next.js 16 (App Router), React 19, Vanilla CSS (Dark Glassmorphism Design System), PWA |
| Backend & Database | Supabase (PostgreSQL, Row-Level Security, Auth), Next.js API Routes |
| Artificial Intelligence | Google Gemini API (@google/generative-ai) |
| Deployment | Vercel |
# 1. Clone the repository
git clone https://github.com/fizsmx/Libro.git
cd Libro/treinta-dias
# 2. Install dependencies
npm install
# 3. Configure environment variables
cp .env.example .env.local
# 4. Run development server
npm run devOpen http://localhost:3000 in your browser.
Released under the MIT License.
Built by Fisbert Chavez (@fizsmx)