Android visitors are offered the Linux .deb on cap.so's homepage and download page
維護者通常 1 天內回覆
評估
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 新手友好度
- 78/100
- Issue 類型
- 缺陷
- 描述清晰度
- 描述清楚
- 活躍度
- 活躍
- 技術堆疊
- nextjs, react, typescript
- 領域
- frontend
研究方向
從 apps/web/hooks/useDetectPlatform.ts 開始,這裡會把任何包含 "Linux" 的 user agent 歸類為桌面版 Linux。接著檢查首頁按鈕與下載頁面,兩者都會讀取這個 hook 的結果,並連結到 /download/linux-deb。完成的標準是:像 Pixel 8 範例那樣的 Android user agent 不再被辨識為 Linux,而 iPhone 與無法辨識的 user agent 維持原有的預設值。在 Chrome 開發者工具中將 user agent 覆寫為 Android 進行驗證。
由索引模型根據 Issue 內容生成。
描述
Description
useDetectPlatform (apps/web/hooks/useDetectPlatform.ts) treats any user agent containing "Linux" as desktop Linux. Android browsers include "Linux" in theirs (Mozilla/5.0 (Linux; Android 14; Pixel 8) ...), so on an Android phone or tablet:
- the homepage's main button reads "Download free for Linux" and links to
/download/linux-deb; - the download page's main button has the Linux logo, links to
/download/linux-deb, and is captioned "Linux x86_64 • .deb, AppImage, RPM and Arch available".
Tapping either downloads the desktop Linux package to the phone. iPhones and other unrecognised devices get the site's default instead: the macOS app on the homepage, and a generic "Download Cap" on the download page.
Reproduction
- Open cap.so in Chrome on an Android phone, or in desktop Chrome with device emulation set to an Android device such as a Pixel 8.
- The homepage's main button reads "Download free for Linux".
- On cap.so/download, the main button has the Linux logo and links to
/download/linux-deb.
Expected
Android isn't treated as desktop Linux, so it isn't offered the Linux package.
- 主要語言
- Rust
- 星號
- 24.2k
- 分支
- 2.2k
- 平均合併
- 1 天 9 小時
- 30 天內合併 PR
- 731
環境準備
- 提供 Dockerfile 或 Docker Compose 檔案
- 沒有 Pull Request 範本
- 閱讀貢獻指南
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
CapSoftware/Cap 的其他 Issue
-
Download, FAQ, privacy and terms pages have no meta description可能已有人在做 @patrickballard 今天認領。 未關閉
難度 2/5 1-3 小時 新手友好度 82/100
CapSoftware/Cap#3675 · 1 則留言 ·
維護者通常 1 天內回覆
-
Shortcut recorder rejects ⌘⇧ with a digit or symbol (e.g. ⌘⇧4)可能已有人在做 @HlaKarki 於 1 天前認領。 未關閉
難度 2/5 1-3 小時 新手友好度 72/100
CapSoftware/Cap#3634 · 1 則留言 ·
維護者通常 1 天內回覆
-
Web player intercepts ⌘⇧M and blocks Chrome profile-menu shortcut可能已有人在做 @AatmanAJ 於 18 天前認領。 未關閉
難度 2/5 1-3 小時 新手友好度 80/100
CapSoftware/Cap#2596 · 1 則留言 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 68/100
CapSoftware/Cap#2384 · 2 則留言 ·
維護者通常 1 天內回覆
-
Dashboard pagination causes full page reloads on self-hosted Cap可能重新可做 關聯的 PR 已關閉且未合併。 未關閉
難度 2/5 1-3 小時 新手友好度 88/100
CapSoftware/Cap#2305 · 2 則留言 ·
維護者通常 1 天內回覆
相似的 Issue
-
難度 2/5 1-3 小時 新手友好度 65/100
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 62/100
維護者通常 2 天內回覆
-
難度 2/5 1-3 小時 新手友好度 65/100
GiganticMinecraft/seichi-portal-backend#1651 ·
維護者通常 1 天內回覆
-
難度 2/5 1-3 小時 新手友好度 72/100
維護者通常 1 天內回覆
-
A transform transition under an anonymous block box stops part-way: resolve_transforms skips anonymous boxes可能已有人在做 關聯的 PR 仍在進行中或已合併。 未關閉
難度 2/5 1-3 小時 新手友好度 72/100
DioxusLabs/blitz#1371 ·
維護者通常 1 天內回覆