Overview
qr-scanner.tsx catches camera permission errors in a bare catch block with no user feedback or error logging. If permission is denied or the request fails, the QR scanner renders a blank screen with no explanation.
Specifications
Features:
- Show a permission-denied UI with a "Go to Settings" deep link when camera access is denied
- Log permission request failures to Sentry
Tasks:
- Replace the bare catch with a structured error handler
- Add a
PermissionDeniedView component with a Settings link
- Write a test that mocks permission denial and checks the view renders
Impacted Files:
src/screens/qr-scanner.tsx
src/components/common/PermissionDeniedView.tsx (new)
Acceptance Criteria
- Permission denial shows a clear message with Settings link
- Permission errors are logged to Sentry
- Test confirms correct view renders on denial
Overview
qr-scanner.tsxcatches camera permission errors in a bare catch block with no user feedback or error logging. If permission is denied or the request fails, the QR scanner renders a blank screen with no explanation.Specifications
Features:
Tasks:
PermissionDeniedViewcomponent with a Settings linkImpacted Files:
src/screens/qr-scanner.tsxsrc/components/common/PermissionDeniedView.tsx(new)Acceptance Criteria