Add MP4 scan progress visibility in UI

- Add broadcast_scan_started, broadcast_scan_progress, broadcast_scan_completed to WebSocketService
- Inject WebSocketService into AnimeService for real-time scan progress broadcasts
- Add CSS styles for scan progress overlay with spinner, stats, and completion state
- Update app.js to handle scan events and display progress overlay
- Add unit tests for new WebSocket broadcast methods
- All 1022 tests passing
This commit is contained in:
2025-12-23 18:24:32 +01:00
parent 9b071fe370
commit a24f07a36e
8 changed files with 633 additions and 20 deletions

View File

@@ -236,18 +236,18 @@ Define three new message types following the existing project patterns:
### Acceptance Criteria
- [ ] Progress overlay appears immediately when scan starts
- [ ] Spinner animation is visible during scanning
- [ ] Directory counter updates periodically (every ~10 directories)
- [ ] Files found counter updates as MP4 files are discovered
- [ ] Current directory name is displayed (truncated if path is too long)
- [ ] Scan completion shows total directories, files, and elapsed time
- [ ] Overlay auto-dismisses 3 seconds after completion
- [ ] Works correctly in both light and dark mode
- [ ] No JavaScript errors in browser console
- [ ] All existing tests continue to pass
- [ ] New unit tests added and passing
- [ ] Code follows project coding standards
- [x] Progress overlay appears immediately when scan starts
- [x] Spinner animation is visible during scanning
- [x] Directory counter updates periodically (every ~10 directories)
- [x] Files found counter updates as MP4 files are discovered
- [x] Current directory name is displayed (truncated if path is too long)
- [x] Scan completion shows total directories, files, and elapsed time
- [x] Overlay auto-dismisses 3 seconds after completion
- [x] Works correctly in both light and dark mode
- [x] No JavaScript errors in browser console
- [x] All existing tests continue to pass
- [x] New unit tests added and passing
- [x] Code follows project coding standards
### Edge Cases to Handle