Browse Source

Fix .torrent file upload on iPadOS

Mobile Safari on iOS does report `ios` platform, but iPadOS reports `mac`
instead. It is common sense to check for touch points when this happens
to differentiate Mac and iPad.

PR #19822.
Closes #19057.

---------

Co-authored-by: Vladimir Golovnev <glassez@yandex.ru>
adaptive-webui-19844
Vitaly Cheptsov 1 year ago committed by GitHub
parent
commit
e42d3f38cc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/webui/www/private/upload.html

2
src/webui/www/private/upload.html

@ -167,7 +167,7 @@
window.parent.closeWindows(); window.parent.closeWindows();
}); });
if (Browser.platform === 'ios') { if ((Browser.platform === 'ios') || ((Browser.platform === 'mac') && (navigator.maxTouchPoints > 1))) {
$('fileselect').accept = ".torrent"; $('fileselect').accept = ".torrent";
} }
</script> </script>

Loading…
Cancel
Save