document.querySelector('input').onchange = (event) => {
const file = event.target.files[0];
console.log(file.type)
}
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>JS Bin</title>
</head>
<body>
<input type="file" accept="image/*,android/force-camera-workaround" capture="environment">
</body>
</html>