downforacross / downforacross.com

Web frontend for downforacross.com -- continuation of stevenhao/crosswordsio
https://downforacrosscom.downforacross1.now.sh
MIT License
233 stars 91 forks source link

iPad OS no longer reports platform as iPad, by default #195

Closed ajhyndman closed 3 years ago

ajhyndman commented 3 years ago

Hello again!

Since my previous pull request, I realised that part of why my experience on iPad has been so degraded is that the "desktop" version of downforacross was never intended to support devices without a hardware keyboard.

With the introduction of iPadOS, it seems iPads stopped reporting themselves as iPads (by default). Instead, they report themselves identically to mac devices, unless a "request desktop site" option is disabled.

With that knowledge, as a user, I discovered that I can toggle that setting and get access to the mobile version of downforacross. 👍

I decided to push this pull request, but I'm not certain it's a good idea.

This pull request updates the mobile detection logic to more reliably identify iPadOS by looking at the presence of touchscreen support in combination with a "MacIntel" platform. It's definitely debatable whether the value outweighs associated risks (for example, if Apple ever does release a touchscreen laptop, or if a user is using an iPad with physical keyboard and does want the desktop site).

If other users run into this issue, another idea that might be worth considering is adding a button (or link) at the bottom of the page that allows users to opt into the mobile controls. Anyway, I'm pushing this option, but I leave it up to you to decide what, if anything, is worth pursuing!

vercel[bot] commented 3 years ago

This pull request is being automatically deployed with Vercel (learn more).
To see the status of your deployment, click below or on the icon next to each commit.

🔍 Inspect: https://vercel.com/downforacross/downforacross.com/F7aoTzPFNi3JMhtmiFdxQED2j7n8
✅ Preview: https://downforacrossc-git-fork-ajhyndman-detect-ipados-downfor-ab9443.vercel.app

stevenhao commented 3 years ago

Hey @ajhyndman, I had to revert this PR because it seems that some iPad users actually prefer the desktop experience (since their tablets come with hardware keyboards). I'm not too familiar with tablets and UserAgent, but I think the simplest solution might be to add a configurable user setting that controls whether or not the mobile experience is served.

What do you think?