diff --git a/frontend/app.js b/frontend/app.js index 2d61075..c481c57 100644 --- a/frontend/app.js +++ b/frontend/app.js @@ -353,6 +353,20 @@ dz.addEventListener('drop', (e)=>{ // --- Mobile-safe file input change handler --- const isTouch = ('ontouchstart' in window) || (navigator.maxTouchPoints > 0); + +// On iOS Safari, the `capture` attribute forces camera-only and hides Photo Library. +// Keep camera default on Android, but remove capture elsewhere to allow picking from Photos/Files. +try { + const ua = (navigator.userAgent || navigator.vendor || window.opera || ''); + const isAndroid = /Android/i.test(ua); + if (fi) { + if (isAndroid) { + fi.setAttribute('capture', 'environment'); + } else { + fi.removeAttribute('capture'); + } + } +} catch {} let suppressClicksUntil = 0; if (isTouch && dropHint) { try { dropHint.classList.add('hidden'); } catch {} diff --git a/frontend/index.html b/frontend/index.html index 752d5c9..a0ab8b6 100644 --- a/frontend/index.html +++ b/frontend/index.html @@ -50,7 +50,6 @@ type="file" multiple accept="image/*,video/*" - capture="environment" class="absolute inset-0 opacity-0 cursor-pointer" /> diff --git a/frontend/invite.html b/frontend/invite.html index ea630cc..4135a59 100644 --- a/frontend/invite.html +++ b/frontend/invite.html @@ -73,7 +73,7 @@