- Initialize Git repository with main branch - Create comprehensive .gitignore for Node.js, React, and environment files - Set up directory structure (frontend/, backend/, docs/) - Create detailed README.md with project overview and setup instructions - Add .env.example with all required environment variables - Configure Prettier for consistent code formatting All acceptance criteria met: ✅ Git repository initialized with appropriate .gitignore ✅ Directory structure matches Technical Assumptions ✅ README.md created with project overview and setup docs ✅ .env.example file with all required environment variables ✅ Prettier config files added for code formatting consistency 🤖 Generated with Claude Code (https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
81 lines
3.5 KiB
Markdown
81 lines
3.5 KiB
Markdown
# Requirements
|
|
|
|
## Functional
|
|
|
|
**FR1:** System shall integrate with Open Library API to search books by title, author, or ISBN
|
|
|
|
**FR2:** System shall display book search results with cover images, title, author, and page count
|
|
|
|
**FR3:** System shall allow user to select a book from search results and add it to their reading list
|
|
|
|
**FR4:** System shall require user to set a deadline date when adding a book to the reading list
|
|
|
|
**FR5:** System shall display active books in a list view on the main screen
|
|
|
|
**FR6:** System shall allow user to log current page number for any active book via a quick-tap workflow (tap book → enter page → save)
|
|
|
|
**FR7:** System shall calculate required pages per day as: (Total Pages - Current Page) ÷ (Days Until Deadline)
|
|
|
|
**FR8:** System shall calculate actual reading pace as a rolling 7-day average of pages read per day
|
|
|
|
**FR9:** System shall display both required pace and actual pace with clear labeling
|
|
|
|
**FR10:** System shall show pages remaining and days remaining for each active book
|
|
|
|
**FR11:** System shall provide color-coded status indicator:
|
|
- Green: Actual pace ≥ Required pace (on track)
|
|
- Yellow: Actual pace within 10% of required pace (slightly behind)
|
|
- Red: Actual pace >10% below required pace (falling behind)
|
|
|
|
**FR12:** System shall display a calendar view showing dates when user logged progress
|
|
|
|
**FR13:** System shall highlight current date and deadline dates on the calendar
|
|
|
|
**FR14:** System shall persist all book data and reading logs in PostgreSQL database
|
|
|
|
**FR15:** System shall function as a Progressive Web App (PWA) installable via "Add to Home Screen"
|
|
|
|
**FR16:** System shall work offline for viewing existing data and logging entries (sync when online)
|
|
|
|
**FR17:** System shall validate page number inputs (must be numeric, >0, ≤ total pages)
|
|
|
|
**FR18:** System shall prevent logging page numbers that are less than previously logged page for the same book (can only move forward)
|
|
|
|
**FR19:** System shall recalculate required pace automatically each day as deadline approaches
|
|
|
|
**FR20:** System shall cache book metadata from Open Library to reduce API calls and improve performance
|
|
|
|
## Non Functional
|
|
|
|
**NFR1:** Page load time shall be <2 seconds on 3G mobile connection
|
|
|
|
**NFR2:** Log entry save operation shall complete in <1 second
|
|
|
|
**NFR3:** Application shall be mobile-responsive and fully functional on screen sizes from 320px to 1920px width
|
|
|
|
**NFR4:** Application shall support last 2 versions of Chrome, Safari, Firefox, and Edge browsers
|
|
|
|
**NFR5:** Application shall use HTTPS for all communications (enforced by Coolify/PWA requirements)
|
|
|
|
**NFR6:** Application shall sanitize all user inputs to prevent XSS attacks
|
|
|
|
**NFR7:** Application shall use parameterized queries or ORM to prevent SQL injection
|
|
|
|
**NFR8:** Application shall deploy as Docker containers to Coolify infrastructure
|
|
|
|
**NFR9:** Database shall have automated backup mechanism via Coolify PostgreSQL management
|
|
|
|
**NFR10:** Application shall respect Open Library API rate limits and implement appropriate caching/retry logic
|
|
|
|
**NFR11:** Frontend bundle size shall be optimized for mobile (<500KB initial load)
|
|
|
|
**NFR12:** Application shall handle Open Library API failures gracefully with user-friendly error messages
|
|
|
|
**NFR13:** PWA service worker shall cache static assets and implement cache-first strategy for offline support
|
|
|
|
**NFR14:** Application shall be accessible and usable with keyboard navigation for basic workflows
|
|
|
|
**NFR15:** All REST API endpoints shall validate inputs and return appropriate HTTP status codes and error messages
|
|
|
|
---
|