Skip to content

Commit 76ff3f2

Browse files
committed
chore: complete v3.2 milestone
1 parent c28cf6f commit 76ff3f2

7 files changed

Lines changed: 445 additions & 58 deletions

File tree

.planning/MILESTONES.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,33 @@
11
# Milestones: Lumio
22

3+
## v3.2 Deck Management UX (Shipped: 2026-03-17)
4+
5+
**Delivered:** Improved shared deck management UX in the Android app — Discovery promoted to 2nd tab, platform repo hidden, swipe-to-unsubscribe with atomic data cleanup, and full card browsing for shared decks.
6+
7+
**Phases completed:** 45-46 (3 plans, 6 tasks)
8+
9+
**Key accomplishments:**
10+
11+
- Discovery tab promoted to 2nd nav position (Dashboard → Discovery → Repos → Settings)
12+
- Platform repo lumio-decks hidden from repo list, stats, and manual add with info toast
13+
- Atomic unsubscribe_deck SECURITY DEFINER RPC (deletes card_review_schedule + user_repositories in one transaction)
14+
- SharedDeckListItem with swipe-to-unsubscribe, confirmation dialog, and success toast
15+
- Unified FlatList with discriminated union (kind: 'deck' | 'repo') merging shared decks and personal repos
16+
- Subfolder-aware card list filtering and CardDetail navigation for shared decks
17+
18+
**Stats:**
19+
20+
- 25 files changed (+2,276 / -128 lines)
21+
- 2 phases, 3 plans, 6 tasks
22+
- 1 day (2026-03-17)
23+
- UAT: 6/6 tests passed
24+
25+
**Git range:** `b6e237e``24b5982` (4 feat commits)
26+
27+
**What's next:** TBD
28+
29+
---
30+
331
## v3.1 Deck Discovery (Shipped: 2026-03-16)
432

533
**Delivered:** End-to-end deck discovery pipeline — from deck.yaml metadata authoring in the deck builder, through Docora webhook indexing into a fulltext-searchable deck_index table, to a Discovery tab in the Android app where users search, browse by tag, and subscribe to shared decks with a single tap.

.planning/PROJECT.md

Lines changed: 16 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -111,18 +111,16 @@ Gli utenti studiano concetti tramite quiz generati dall'AI — il contenuto vien
111111
- ✓ Discovery tab (4° tab, icona bussola) con ricerca fulltext, chip tag, subscribe/unsubscribe ottimistico — v3.1
112112
- ✓ Deck condivisi visibili nella schermata Repos con display_name arricchito da deck_index — v3.1
113113
- ✓ i18n completa Discovery IT/EN (17 chiavi per lingua) — v3.1
114+
- ✓ Tab Discovery promosso a 2° posizione nav (Dashboard → Discovery → Repos → Settings) — v3.2
115+
- ✓ Repo piattaforma lumio-decks nascosto da lista repo, stats, e add manuale con info toast — v3.2
116+
- ✓ Unsubscribe atomico da mazzo condiviso via SECURITY DEFINER RPC (card_review_schedule + user_repositories) — v3.2
117+
- ✓ Swipe-to-unsubscribe su mazzi condivisi con dialog conferma e toast — v3.2
118+
- ✓ Lista unificata FlatList con discriminated union (deck | repo) per repos e mazzi condivisi — v3.2
119+
- ✓ Filtro carte per subfolder e navigazione CardDetail per mazzi condivisi — v3.2
114120

115121
### Active
116122

117-
**Current Milestone: v3.2 Deck Management UX**
118-
119-
**Goal:** Migliorare la gestione dei mazzi condivisi nell'app Android — riordino tab, nascondi repo piattaforma, e parità funzionale (swipe unsubscribe, tap → carte) con i repo normali.
120-
121-
**Target features:**
122-
- Riordino tab bottom: Discovery prima di Repository
123-
- Nascondi repo condiviso lumio-decks dalla lista repository
124-
- Swipe a sinistra su mazzi condivisi per disiscriversi (con cancellazione dati studio)
125-
- Tap su mazzi condivisi per navigare a lista carte → dettaglio carta
123+
(No active milestone — start next with `/gsd:new-milestone`)
126124

127125
### Out of Scope
128126

@@ -160,7 +158,7 @@ Gli utenti studiano concetti tramite quiz generati dall'AI — il contenuto vien
160158

161159
## Context
162160

163-
**Stato attuale (post v3.1):**
161+
**Stato attuale (post v3.2):**
164162
- Monorepo pnpm: apps/android (Expo/React Native), apps/deck-builder (Vite/React SPA), apps/landing (static HTML), packages/core, packages/shared
165163
- Backend Supabase: auth (Google OAuth + email/password), DB, storage, edge functions (deck-commit con 9 azioni GitHub API + docora-webhook con deck.yaml indexing), Docora webhook + study_sessions + card_review_schedule + deck_index tables
166164
- Tech stack Android: Expo SDK 54, React Native 0.81, react-navigation, @lumio/core, i18n-js, react-native-marked, supermemo@2.0.23
@@ -172,7 +170,7 @@ Gli utenti studiano concetti tramite quiz generati dall'AI — il contenuto vien
172170
- Deck builder web bilingue IT/EN con dark mode, deck CRUD, card authoring con markdown editor, live preview, toolbar, metadata form (deck.yaml)
173171
- Discovery pipeline: deck.yaml → Docora webhook → deck_index (tsvector/GIN) → search_decks RPC → Discovery screen
174172
- ~56,900 LOC (TS/TSX/CSS/SQL) — ~28,300 Android + ~28,600 deck-builder
175-
- 13 milestones shipped: v1.1 → v3.1
173+
- 14 milestones shipped: v1.1 → v3.2
176174

177175
## Constraints
178176

@@ -282,6 +280,12 @@ Gli utenti studiano concetti tramite quiz generati dall'AI — il contenuto vien
282280
| 409 conflict as success in subscribeToDeck | Idempotent double-tap handling without error UI | ✓ Good — v3.1 |
283281
| Optimistic UI with Set rollback for subscribe | Immediate visual feedback, revert on error | ✓ Good — v3.1 |
284282
| Collapsible metadata form (collapsed by default) | Non-intrusive for quick deck browsing, expand when needed | ✓ Good — v3.1 |
283+
| Post-query array filter for is_platform exclusion | Simpler than nested Supabase filter syntax | ✓ Good — v3.2 |
284+
| Sentinel error string PLATFORM_REPO for client detection | Clean client-side routing to info toast vs error toast | ✓ Good — v3.2 |
285+
| SECURITY DEFINER RPC for atomic unsubscribe | Deletes card_review_schedule + user_repositories in single transaction | ✓ Good — v3.2 |
286+
| Discriminated union (kind: 'deck' \| 'repo') for FlatList | Type-safe rendering of mixed shared decks and personal repos | ✓ Good — v3.2 |
287+
| Skip .lumioignore when subfolderPath is set | Shared decks don't have per-user .lumioignore | ✓ Good — v3.2 |
288+
| Fallback Repository object for shared deck CardDetail | Enables CardDetail navigation without repo in user's personal collection | ✓ Good — v3.2 |
285289

286290
---
287-
*Last updated: 2026-03-16 after v3.1 milestone*
291+
*Last updated: 2026-03-17 after v3.2 milestone*

.planning/ROADMAP.md

Lines changed: 9 additions & 40 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
-**v2.3 Dashboard Polish** — Phases 34-35 (shipped 2026-03-05)
1616
-**v3.0 Deck Builder Web** — Phases 36-40 (shipped 2026-03-13)
1717
-**v3.1 Deck Discovery** — Phases 41-44 (shipped 2026-03-16)
18-
- 🚧 **v3.2 Deck Management UX** — Phases 45-46 (in progress)
18+
- **v3.2 Deck Management UX** — Phases 45-46 (shipped 2026-03-17)
1919

2020
## Phases
2121

@@ -167,48 +167,18 @@ Full details: `.planning/milestones/v3.1-ROADMAP.md`
167167

168168
</details>
169169

170-
### v3.2 Deck Management UX (In Progress)
171-
172-
**Milestone Goal:** Migliorare la gestione dei mazzi condivisi nell'app Android -- riordino tab, nascondi repo piattaforma, e parita funzionale (swipe unsubscribe, tap per carte) con i repo normali.
173-
174-
- [x] **Phase 45: Navigation & Display Cleanup** - Tab reorder e filtro repo piattaforma (completed 2026-03-17)
175-
- [x] **Phase 46: Shared Deck Interaction** - Swipe unsubscribe e card browsing per mazzi condivisi (completed 2026-03-17)
176-
177-
## Phase Details
178-
179-
### Phase 45: Navigation & Display Cleanup
180-
**Goal**: Users see a cleaner, more logical navigation layout with Discovery promoted and platform internals hidden
181-
**Depends on**: Phase 44
182-
**Requirements**: NAV-01, REPO-01
183-
**Success Criteria** (what must be TRUE):
184-
1. The Discovery tab appears as the 2nd tab (after Dashboard, before Repository) in the bottom navigation bar
185-
2. The lumio-decks shared repository does not appear in the Repository list -- only user-subscribed deck entries and personal repos are visible
186-
3. Tab order is consistent across all app screens (no stale order on navigation)
187-
**Plans**: 1 plan
170+
<details>
171+
<summary>✅ v3.2 Deck Management UX (Phases 45-46) — SHIPPED 2026-03-17</summary>
188172

189-
Plans:
190-
- [ ] 45-01-PLAN.md — Tab reorder, platform repo filter, and add-repo guard
173+
- [x] Phase 45: Navigation & Display Cleanup (1 plan) — completed 2026-03-17
174+
- [x] Phase 46: Shared Deck Interaction (2 plans) — completed 2026-03-17
191175

192-
### Phase 46: Shared Deck Interaction
193-
**Goal**: Users can manage and browse shared decks with the same interactions available for personal repositories
194-
**Depends on**: Phase 45
195-
**Requirements**: DECK-01, DECK-02, DECK-03
196-
**Success Criteria** (what must be TRUE):
197-
1. User can swipe left on a shared deck entry in the Repository screen to reveal an unsubscribe action
198-
2. Unsubscribing from a shared deck removes the subscription and associated study data (card_review_schedule entries)
199-
3. User can tap a shared deck entry to see a list of cards filtered by the deck's subfolder path
200-
4. User can tap a card in the shared deck card list to view full card detail with markdown, code highlighting, LaTeX, and images
201-
**Plans**: 2 plans
176+
Full details: `.planning/milestones/v3.2-ROADMAP.md`
202177

203-
Plans:
204-
- [ ] 46-01-PLAN.md — Backend RPC, client function, route params, and i18n keys
205-
- [ ] 46-02-PLAN.md — SharedDeckListItem component, unified list, swipe unsubscribe, card browsing
178+
</details>
206179

207180
## Progress
208181

209-
**Execution Order:**
210-
Phases execute in numeric order: 45 -> 46
211-
212182
| Phase | Milestone | Plans Complete | Status | Completed |
213183
|-------|-----------|----------------|--------|-----------|
214184
| 1-5. Foundation to Cleanup | v1.1 | 20/20 | Complete | 2026-02-08 |
@@ -224,9 +194,8 @@ Phases execute in numeric order: 45 -> 46
224194
| 34-35. Dashboard Polish | v2.3 | 2/2 | Complete | 2026-03-05 |
225195
| 36-40. Deck Builder Web | v3.0 | 10/10 | Complete | 2026-03-13 |
226196
| 41-44. Deck Discovery | v3.1 | 8/8 | Complete | 2026-03-16 |
227-
| 45. Navigation & Display Cleanup | 1/1 | Complete | 2026-03-17 | - |
228-
| 46. Shared Deck Interaction | 2/2 | Complete | 2026-03-17 | - |
197+
| 45-46. Deck Management UX | v3.2 | 3/3 | Complete | 2026-03-17 |
229198

230199
---
231200
*Roadmap created: 2026-01-29*
232-
*Last updated: 2026-03-17 -- Phase 46 planned (2 plans)*
201+
*Last updated: 2026-03-17 — v3.2 Deck Management UX shipped*

.planning/STATE.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ milestone: v3.2
44
milestone_name: Deck Management UX
55
status: completed
66
stopped_at: Completed 46-02-PLAN.md (Phase 46 complete)
7-
last_updated: "2026-03-17T09:58:05.180Z"
7+
last_updated: "2026-03-17T11:38:31.689Z"
88
last_activity: 2026-03-17 — Completed 46-02 (Shared Deck UI)
99
progress:
1010
total_phases: 2
@@ -18,10 +18,10 @@ progress:
1818

1919
## Project Reference
2020

21-
See: .planning/PROJECT.md (updated 2026-03-16)
21+
See: .planning/PROJECT.md (updated 2026-03-17)
2222

2323
**Core value:** Gli utenti studiano concetti tramite quiz generati dall'AI -- il contenuto viene dai repository Git, le domande vengono generate e pre-cachate dal sistema.
24-
**Current focus:** Phase 46 - Shared Deck Interaction
24+
**Current focus:** Planning next milestone
2525

2626
## Current Position
2727

@@ -35,9 +35,9 @@ Progress: [██████████] 100%
3535
## Performance Metrics
3636

3737
**Velocity:**
38-
- Total plans completed: 88 (70 across v1.1-v2.3 + 10 in v3.0 + 8 in v3.1)
39-
- Total milestones shipped: 13 (v1.1 through v3.1)
40-
- Timeline: 47 days (2026-01-29 to 2026-03-16)
38+
- Total plans completed: 91 (70 across v1.1-v2.3 + 10 in v3.0 + 8 in v3.1 + 3 in v3.2)
39+
- Total milestones shipped: 14 (v1.1 through v3.2)
40+
- Timeline: 48 days (2026-01-29 to 2026-03-17)
4141

4242
## Accumulated Context
4343

Lines changed: 93 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,93 @@
1+
---
2+
milestone: v3.2
3+
audited: 2026-03-17T12:30:00Z
4+
status: passed
5+
scores:
6+
requirements: 5/5
7+
phases: 2/2
8+
integration: 8/8
9+
flows: 4/4
10+
gaps:
11+
requirements: []
12+
integration: []
13+
flows: []
14+
tech_debt:
15+
- phase: 46-shared-deck-interaction
16+
items:
17+
- "CardListScreen handleCardPress silently no-ops when repository is null (empty deck edge case before sync) — affects DECK-03 in non-realistic scenario only"
18+
nyquist:
19+
compliant_phases: []
20+
partial_phases: []
21+
missing_phases: [45, 46]
22+
overall: missing
23+
---
24+
25+
# Milestone v3.2: Deck Management UX — Audit Report
26+
27+
**Audited:** 2026-03-17
28+
**Status:** passed
29+
**Phases:** 45-46 (2 phases, 3 plans)
30+
31+
## Milestone Definition of Done
32+
33+
Migliorare la gestione dei mazzi condivisi nell'app Android — riordino tab, nascondi repo piattaforma, e parità funzionale (swipe unsubscribe, tap per carte) con i repo normali.
34+
35+
## Requirements Coverage (3-Source Cross-Reference)
36+
37+
| REQ-ID | Description | VERIFICATION.md | SUMMARY Frontmatter | REQUIREMENTS.md | Final Status |
38+
|--------|-------------|-----------------|---------------------|-----------------|--------------|
39+
| NAV-01 | Tab Discovery prima di Repository | passed (Phase 45) | 45-01-SUMMARY | [x] | **satisfied** |
40+
| REPO-01 | Repo lumio-decks nascosto dalla lista | passed (Phase 45) | 45-01-SUMMARY | [x] | **satisfied** |
41+
| DECK-01 | Swipe unsubscribe con cancellazione dati studio | passed (Phase 46) | 46-01, 46-02 SUMMARY | [x] | **satisfied** |
42+
| DECK-02 | Tap mazzo condiviso per lista carte filtrate | passed (Phase 46) | 46-01, 46-02 SUMMARY | [x] | **satisfied** |
43+
| DECK-03 | Navigazione da mazzo condiviso a dettaglio carta | passed (Phase 46) | 46-02 SUMMARY | [x] | **satisfied** |
44+
45+
**Orphaned requirements:** None
46+
**Unsatisfied requirements:** None
47+
48+
## Phase Verifications
49+
50+
| Phase | Status | Score | Gaps |
51+
|-------|--------|-------|------|
52+
| 45 - Navigation & Display Cleanup | passed | 4/4 | None |
53+
| 46 - Shared Deck Interaction | passed | 9/9 | None |
54+
55+
## Integration Check
56+
57+
| Metric | Result |
58+
|--------|--------|
59+
| Connected exports | 8/8 |
60+
| Orphaned exports | 0 |
61+
| Missing connections | 0 |
62+
| Auth-protected routes | All |
63+
64+
### E2E Flows
65+
66+
| Flow | Requirements | Status |
67+
|------|-------------|--------|
68+
| Discovery → Subscribe → Repos → Swipe unsubscribe | DECK-01 | Complete |
69+
| Discovery → Subscribe → Repos → Tap → Card list → Card detail | DECK-02, DECK-03 | Complete (latent edge case) |
70+
| Platform repo hidden + manual add rejected | REPO-01 | Complete |
71+
| Tab order correct | NAV-01 | Complete |
72+
73+
## Tech Debt
74+
75+
### Phase 46: Shared Deck Interaction
76+
- `CardListScreen.tsx` line 104: `handleCardPress` silently no-ops when `repository` is null. The fallback Repository is only constructed when `allCards.length > 0`. For empty shared decks (pre-sync), tapping would do nothing. In practice: empty list means nothing to tap, so not user-visible. Minimal fix: build fallback unconditionally when `subfolderPath` is set, or show error toast in else branch.
77+
78+
**Total:** 1 item across 1 phase
79+
80+
## Nyquist Compliance
81+
82+
| Phase | VALIDATION.md | Compliant | Action |
83+
|-------|---------------|-----------|--------|
84+
| 45 | missing || `/gsd:validate-phase 45` |
85+
| 46 | missing || `/gsd:validate-phase 46` |
86+
87+
## UAT Results
88+
89+
Phase 46 UAT completed: 6/6 tests passed, 0 issues.
90+
91+
---
92+
_Audited: 2026-03-17_
93+
_Auditor: Claude (audit-milestone)_
Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# Requirements Archive: v3.2 Deck Management UX
2+
3+
**Archived:** 2026-03-17
4+
**Status:** SHIPPED
5+
6+
For current requirements, see `.planning/REQUIREMENTS.md`.
7+
8+
---
9+
10+
# Requirements: Lumio
11+
12+
**Defined:** 2026-03-17
13+
**Core Value:** Gli utenti studiano concetti tramite quiz generati dall'AI — il contenuto viene dai repository Git, le domande vengono generate e pre-cachate dal sistema.
14+
15+
## v3.2 Requirements
16+
17+
Requirements for Deck Management UX milestone. Each maps to roadmap phases.
18+
19+
### Navigation
20+
21+
- [x] **NAV-01**: Tab Discovery appare prima di tab Repository nella bottom navigation
22+
23+
### Repository Display
24+
25+
- [x] **REPO-01**: Il repository condiviso lumio-decks non appare nella lista repository
26+
27+
### Shared Decks
28+
29+
- [x] **DECK-01**: L'utente può disiscriversi da un mazzo condiviso tramite swipe a sinistra nella pagina Repository (con cancellazione dati studio)
30+
- [x] **DECK-02**: L'utente può fare tap su un mazzo condiviso per vedere la lista carte filtrate per subfolder
31+
- [x] **DECK-03**: L'utente può navigare dal mazzo condiviso al dettaglio singola carta (markdown preview, code, LaTeX, immagini)
32+
33+
## Future Requirements
34+
35+
None — focused milestone.
36+
37+
## Out of Scope
38+
39+
| Feature | Reason |
40+
|---------|--------|
41+
| Modifica carte da app Android | Il deck builder web è l'editor, l'app è per lo studio |
42+
| Gestione metadata mazzo da app | deck.yaml si gestisce dal deck builder web |
43+
44+
## Traceability
45+
46+
| Requirement | Phase | Status |
47+
|-------------|-------|--------|
48+
| NAV-01 | Phase 45 | Complete |
49+
| REPO-01 | Phase 45 | Complete |
50+
| DECK-01 | Phase 46 | Complete |
51+
| DECK-02 | Phase 46 | Complete |
52+
| DECK-03 | Phase 46 | Complete |
53+
54+
**Coverage:**
55+
- v3.2 requirements: 5 total
56+
- Mapped to phases: 5
57+
- Unmapped: 0
58+
59+
---
60+
*Requirements defined: 2026-03-17*
61+
*Last updated: 2026-03-17 after roadmap creation*

0 commit comments

Comments
 (0)