Skip to content

feat: camera capture (webcam/phone) for OCR, Receipt Scanner + standalone tool - #48

Merged
slaveofcode merged 5 commits into
developfrom
feat/camera-capture
Jul 31, 2026
Merged

feat: camera capture (webcam/phone) for OCR, Receipt Scanner + standalone tool#48
slaveofcode merged 5 commits into
developfrom
feat/camera-capture

Conversation

@slaveofcode

Copy link
Copy Markdown
Owner

Adds camera capture as an input alongside upload/paste.

  • useCamera hook — getUserMedia lifecycle: rear-camera default, switch, reason-typed errors, track cleanup on capture/cancel/unmount.
  • CameraCapture component — live preview + Capture/Switch/Cancel, with a native <input capture> fallback when the camera is denied/unavailable.
  • Use camera button in the shared OcrWorkbench → both Image OCR and Receipt Scanner gain it (feeds the existing pipeline).
  • New Camera Capture tool — snap a photo → Download / Copy / Edit in Annotator.

Client-side only (frames never leave the browser). 479 tests pass · lint 0 errors · build green (/tools/camera-capture added).

slaveofcode and others added 5 commits July 31, 2026 06:30
Promote to production: receipt row-grouping fix
Reusable CameraCapture in OcrWorkbench (OCR + Receipt Scanner) plus a standalone
Camera Capture tool. Rear default + switch; JPEG; Download/Copy/Edit-in-Annotator.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
getUserMedia lifecycle (rear default, switch, reason-typed errors, track
cleanup) + JPEG frame capture + live-preview UI with native <input capture>
fallback. Reusable across OCR and a standalone tool.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Adds a Use camera button to the shared OcrWorkbench (covers Image OCR and
Receipt Scanner) and a new Camera Capture tool (photo -> download/copy/edit
in annotator).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@slaveofcode
slaveofcode merged commit b32c7e2 into develop Jul 31, 2026
1 of 2 checks passed
@slaveofcode
slaveofcode deleted the feat/camera-capture branch July 31, 2026 03:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant