feat(river): warn mobile visitors that Freenet is desktop-only#65
Merged
Conversation
Mobile users could land on /river, tap "Install Freenet & Join River", and hit a dead end: the /quickstart installer auto-selects an OS tab by device and maps iPhone/iPad -> the macOS download and Android -> the Linux install, so a phone visitor was shown a desktop download button that does nothing. No page said Freenet is desktop-only. - /river hero: platform line under the CTA, visible to everyone — "Runs on Windows, macOS, and Linux. No mobile app yet." Sets the expectation before the tap. - /river "Where River is today" alpha box: bullet "Desktop only (Windows, macOS, Linux); no mobile app yet". - /quickstart os-install shortcode: detect phones/tablets (incl. iPadOS 13+ masquerading as Mac via maxTouchPoints) and, instead of a bogus desktop download, show an honest notice: open the page on a computer, no mobile app yet. Includes an "On a computer? Show the install options" safety valve in case a desktop is misdetected. Desktop behavior is unchanged. Verified with Playwright: iPhone hides the tabs and shows the notice; the safety valve restores the tabs; desktop /quickstart is unaffected. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Q5nGtN2vVKqYABT5sosrAB
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem
A mobile visitor could land on /river, tap Install Freenet & Join River, and hit a dead end. Nothing on either page said Freenet is desktop-only, and the
/quickstartinstaller made it worse: itsos-installshortcode auto-selects an OS tab by device and maps iPhone/iPad → the macOS download and Android → the Linux install — so a phone user was shown a desktop download button that does nothing.Approach
Be upfront on the landing page, and stop the installer from handing mobile users a broken download.
os-installshortcode — detect phones/tablets (including iPadOS 13+, which masquerades as desktop Mac, viamaxTouchPoints) and replace the bogus desktop download with a clear notice: open the page on a computer, no mobile app yet. Includes an "On a computer? Show the install options" safety valve in case a desktop is misdetected. Desktop behavior is unchanged (detectOS/activateTab/ tab handlers are byte-for-byte identical; the only removed line,activateTab(detectOS()), is preserved verbatim in the newelsebranch).Phrased as "no mobile app yet" — honest about the current state without promising a timeline.
Testing
Verified end-to-end with Playwright:
/quickstart: desktop tabs hidden (display:none), honest notice shown; the safety-valve button restores the tabs and re-runs detection./river: platform line renders under the CTA with the correct text./quickstart(control): tabs visible, notice hidden, correct OS tab auto-selected — unchanged from before.Hugo build clean; no em-dashes.
Review
navigator.platform, and real Macs reportmaxTouchPoints === 0);isMobile()can't throw; safety valve verified. Three edge-case NITs (keyboard focus after the safety-valve click; a brief pre-hide tab flash; no-JS mobile falls back to the Linux default — pre-existing), all dismissed as not worth blocking.Copy-only + progressive-enhancement JS; no high-risk surface.
[AI-assisted - Claude]