This commit is contained in:
Danilo Reyes
2025-11-02 01:47:25 -06:00
parent 48020b6f42
commit 010df31455
45 changed files with 8045 additions and 720 deletions

View File

@@ -183,45 +183,45 @@ Implementation tasks for the Reference Board Viewer, organized by user story (fu
**User Story:** Users must be able to add images to boards through multiple methods
**Independent Test Criteria:**
- [ ] Users can upload via file picker
- [ ] Users can drag-drop images
- [ ] Users can paste from clipboard
- [ ] Users can upload ZIP files (auto-extracted)
- [ ] File validation rejects invalid files
- [ ] Thumbnails generated automatically
- [X] Users can upload via file picker
- [X] Users can drag-drop images
- [X] Users can paste from clipboard
- [X] Users can upload ZIP files (auto-extracted)
- [X] File validation rejects invalid files
- [X] Thumbnails generated automatically
**Backend Tasks:**
- [ ] T076 [P] [US3] Create Image model in backend/app/database/models/image.py from data-model.md
- [ ] T077 [P] [US3] Create BoardImage model in backend/app/database/models/board_image.py from data-model.md
- [ ] T078 [P] [US3] Create image schemas in backend/app/images/schemas.py (ImageUpload, ImageResponse)
- [ ] T079 [US3] Implement file validation in backend/app/images/validation.py (magic bytes, size, type)
- [ ] T080 [US3] Implement image upload handler in backend/app/images/upload.py (streaming to MinIO)
- [ ] T081 [US3] Implement thumbnail generation in backend/app/images/processing.py (Pillow resizing)
- [ ] T082 [US3] Create image repository in backend/app/images/repository.py (metadata operations)
- [ ] T083 [US3] Implement upload endpoint POST /boards/{id}/images in backend/app/api/images.py
- [ ] T084 [US3] Implement ZIP extraction handler in backend/app/images/zip_handler.py
- [ ] T085 [US3] Set up background task queue for thumbnail generation in backend/app/core/tasks.py
- [ ] T086 [P] [US3] Write unit tests for file validation in backend/tests/images/test_validation.py
- [ ] T087 [P] [US3] Write unit tests for thumbnail generation in backend/tests/images/test_processing.py
- [ ] T088 [P] [US3] Write integration tests for upload endpoint in backend/tests/api/test_images.py
- [X] T076 [P] [US3] Create Image model in backend/app/database/models/image.py from data-model.md
- [X] T077 [P] [US3] Create BoardImage model in backend/app/database/models/board_image.py from data-model.md
- [X] T078 [P] [US3] Create image schemas in backend/app/images/schemas.py (ImageUpload, ImageResponse)
- [X] T079 [US3] Implement file validation in backend/app/images/validation.py (magic bytes, size, type)
- [X] T080 [US3] Implement image upload handler in backend/app/images/upload.py (streaming to MinIO)
- [X] T081 [US3] Implement thumbnail generation in backend/app/images/processing.py (Pillow resizing)
- [X] T082 [US3] Create image repository in backend/app/images/repository.py (metadata operations)
- [X] T083 [US3] Implement upload endpoint POST /boards/{id}/images in backend/app/api/images.py
- [X] T084 [US3] Implement ZIP extraction handler in backend/app/images/zip_handler.py
- [X] T085 [US3] Set up background task queue for thumbnail generation in backend/app/core/tasks.py
- [X] T086 [P] [US3] Write unit tests for file validation in backend/tests/images/test_validation.py
- [X] T087 [P] [US3] Write unit tests for thumbnail generation in backend/tests/images/test_processing.py
- [X] T088 [P] [US3] Write integration tests for upload endpoint in backend/tests/api/test_images.py
**Frontend Tasks:**
- [ ] T089 [P] [US3] Create images API client in frontend/src/lib/api/images.ts
- [ ] T090 [P] [US3] Create images store in frontend/src/lib/stores/images.ts
- [ ] T091 [US3] Implement file picker upload in frontend/src/lib/components/upload/FilePicker.svelte
- [ ] T092 [US3] Implement drag-drop zone in frontend/src/lib/components/upload/DropZone.svelte
- [ ] T093 [US3] Implement clipboard paste handler in frontend/src/lib/utils/clipboard.ts
- [ ] T094 [US3] Implement ZIP upload handler in frontend/src/lib/utils/zip-upload.ts
- [ ] T095 [P] [US3] Create upload progress component in frontend/src/lib/components/upload/ProgressBar.svelte
- [ ] T096 [P] [US3] Create upload error display in frontend/src/lib/components/upload/ErrorDisplay.svelte
- [X] T089 [P] [US3] Create images API client in frontend/src/lib/api/images.ts
- [X] T090 [P] [US3] Create images store in frontend/src/lib/stores/images.ts
- [X] T091 [US3] Implement file picker upload in frontend/src/lib/components/upload/FilePicker.svelte
- [X] T092 [US3] Implement drag-drop zone in frontend/src/lib/components/upload/DropZone.svelte
- [X] T093 [US3] Implement clipboard paste handler in frontend/src/lib/utils/clipboard.ts
- [X] T094 [US3] Implement ZIP upload handler in frontend/src/lib/utils/zip-upload.ts
- [X] T095 [P] [US3] Create upload progress component in frontend/src/lib/components/upload/ProgressBar.svelte
- [X] T096 [P] [US3] Create upload error display in frontend/src/lib/components/upload/ErrorDisplay.svelte
- [ ] T097 [P] [US3] Write upload component tests in frontend/tests/components/upload.test.ts
**Infrastructure:**
- [ ] T098 [US3] Configure MinIO bucket creation in backend/app/core/storage.py
- [ ] T099 [US3] Set up MinIO via Nix in flake.nix services configuration
- [X] T098 [US3] Configure MinIO bucket creation in backend/app/core/storage.py
- [X] T099 [US3] Set up MinIO via Nix in flake.nix services configuration
**Deliverables:**
- Multi-method upload working