fix(web): ask Safari users for Mac type#2090
Conversation
Co-authored-by: npub1qvn3cujt28pg06ehlstrxyz6ayzp06t4uc7r566vxwwgrv24hglq9zju0n <03271c724b51c287eb37fc1633105ae90417e975e63c3a6b4c339c81b155ba3e@sprout-oss.stage.blox.sqprod.co> Signed-off-by: npub1qvn3cujt28pg06ehlstrxyz6ayzp06t4uc7r566vxwwgrv24hglq9zju0n <03271c724b51c287eb37fc1633105ae90417e975e63c3a6b4c339c81b155ba3e@sprout-oss.stage.blox.sqprod.co>
Co-authored-by: npub1rf6fvdj6ut0c4kcmjv4p5mmgh89nj58n69uu3fz3cvk3jn500hqs7emz79 <1a7496365ae2df8adb1b932a1a6f68b9cb3950f3d179c8a451c32d194e8f7dc1@sprout-oss.stage.blox.sqprod.co> Signed-off-by: npub1rf6fvdj6ut0c4kcmjv4p5mmgh89nj58n69uu3fz3cvk3jn500hqs7emz79 <1a7496365ae2df8adb1b932a1a6f68b9cb3950f3d179c8a451c32d194e8f7dc1@sprout-oss.stage.blox.sqprod.co>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 591ffcf903
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| setShowMacChoice(false); | ||
| try { | ||
| const url = await resolveBuzzDownloadUrlForPlatform(platform); | ||
| downloadWindow?.location.replace(url); |
There was a problem hiding this comment.
Fall back when the chooser popup is blocked
In browsers or managed environments that block window.open, selecting either Mac option still calls event.preventDefault() and then this optional call becomes a no-op because downloadWindow is null; the dialog closes but no download or releases page opens. Since the anchors already have href={BUZZ_RELEASES_URL}, fall back to same-tab navigation (or avoid preventing default) when the popup can't be created.
Useful? React with 👍 / 👎.
Why
Safari does not expose whether a Mac is Apple Silicon or Intel, so invite landing pages silently selected the Intel DMG.
What
Validation
pnpm typecheckpnpm checkpnpm exec playwright test --project=smoke --grep 'invite asks Safari users|invite download falls back|invite requires age'\n\nPre-push also passed repository Rust tests; the unrelated desktop Tauri suite had 3 existing Codex adapter discovery failures under the hook environment.\n\nGenerated with mini