nhsx / antibody-web

Web application for finger prick covid19 antibody Lateral Flow Tests (LFT) and interpreting results
MIT License
28 stars 10 forks source link

Pull in the latest Audere camera flow. #44

Closed mathewsb closed 4 years ago

mathewsb commented 4 years ago

In this flow, we first try the inline camera that uses the MediaStream API. If that camera fails for some reason (e.g., the user does not give us permission to use the camera), we fall back to <input type="file">.

If the browser supports input capture mode (see inputCaptureSupported()), this will use the system camera. The user will not be allowed to upload an arbitrary file from their camera roll.

If the browser does not support image capture mode (e.g., on desktop), it falls back to an upload file dialog.

NOTE: This unfortunately introduces a few new material-ui components in order to render progress bars. I suggest that we commit this and then figure out how to remove/replace those components. Let me know if you disagree.