HOMEWORK 3 — Networking & Mini-Capstone ======================================== Mobile Application Development | SUZA | Semester II 2025/2026 Weight: 20% | Pairs allowed (max 2) | Due: end of Week 14 TASK — Build a "NewsHub" app ---------------------------- Fetch articles from a public REST API, cache them with Room, and show them in a polished Compose UI that works offline after the first load. SUGGESTED APIS (pick one) ------------------------- - https://api.spaceflightnewsapi.net/v4/articles (no key needed) - https://newsdata.io/ (free key needed) - https://gnews.io/ (free key needed) CORE REQUIREMENTS ----------------- 1. Two-layer data source: Retrofit (remote) + Room (local cache). Offline-first read: UI pulls from Room; a background refresh updates it. 2. Architecture: DataSource (API + DAO) ← Repository ← ViewModel ← Compose UI Use StateFlow and sealed UiState (Loading / Success / Error / Empty). 3. Screens (Navigation-Compose): a. FeedScreen — LazyColumn of articles, pull-to-refresh b. DetailScreen — full article with image, title, summary, "Open in browser" c. SavedScreen — articles the user has starred d. SettingsScreen — light/dark theme toggle, persisted with DataStore 4. Images loaded with Coil (AsyncImage). 5. Error handling: - Distinguish IOException (no network) vs HttpException (server error) - Retry button on error state - Show snackbar when refresh fails but cache is shown 6. At least 3 unit tests and 2 Compose UI tests. 7. Accessibility: - contentDescription on every Image / IconButton - Verified with TalkBack - All tap targets ≥ 48dp GRADING (100 pts) ----------------- Retrofit + Room integration (offline-first) 25 Architecture quality (DI-friendly, testable) 15 UI polish & Material 3 compliance 15 Error / empty / loading states 10 Tests (unit + UI) 10 Accessibility audit + fixes 10 Documentation (README, architecture diagram) 5 Demo video (≤ 3 min) 10 DELIVERABLES ------------ - GitHub repo "mad-hw3-" - Signed release APK attached to a GitHub release - Screenshots: feed, detail, saved, settings (light & dark) - Architecture diagram - 3-minute demo video - Short peer-review form (if in pairs) describing contribution split