I think we found a regression in iOS 13.2/13.3 in regard to PWAs running in standalone mode.
Since on iOS PWA cannot access getUserMedia() we rely on the capture attribute on the HTML5 input tag to let the user take a picture and send it to a server.
Our code looks like this:
<div class="camera-upload">
<input type="file" class="hidden" name="uploadPhotoInput" accept="image/*" capture="environment" (change)="onTakePhoto($event)">
<button type="button" class="btn btn-primary">Take photo</button>
</div>
When we run the PWA in standalone mode on devices with iOS 13.1 or lower everything works as expected. If we run the PWA in browser mode on Safari everything works regardless of the iOS version.
When we run the PWA on devices with iOS 13.2 or 13.3 the feature works until we put the PWA in background and then in foreground again. After the PWA is sent to the background the capture launch the camera, but the preview is jut black. All the camera controls (flash, etc) works, but no picture is taken.
We run a test with the XCode console logger attached and it looks AVCaptureSession cannot be started after the app has been put in background once.
Here is a trace of the device logs:
We are building our PWA with Angular 8.
Has anyone seen something like this or can give us an hint?