reactjs / reactjs/react.dev

Mobile navigation width is offset by scrollbar

未關閉
#5,725 0 則留言 0 個 reaction 已指派 0 人 在 GitHub 檢視

還沒有人認領這個 Issue。

主要語言
JavaScript
星號
11.8k
分支
7.9k
平均合併
1 天 11 小時
30 天內合併 PR
11

描述

On browsers that support ::webkit-scrollbar, the navigation width is offset by the width of the scrollbar, hence not exactly 100% of the overflowing parent.

In other browsers (e.g. Firefox, iOS browsers), the navigation width is correctly set to 100% of the overflowing parent, and with uneven padding on the parent, the nav looks like it's overflowing.

Chrome with transparent ::webkit-scrollbar:
Screenshot 2023-03-18 at 10 58 33 pm

Chrome without:
Screenshot 2023-03-18 at 10 58 44 pm

Firefox that supports scrollbar-color instead:
Screenshot 2023-03-18 at 10 59 34 pm

貢獻指南

開啟貢獻指南

從這裡開始

  1. 先讀完整個 Issue,再讀專案的貢獻指南。
  2. 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
  3. Fork 儲存庫,在一個分支上完成修改。
  4. 送出 Pull Request,並在描述裡引用這個 Issue 編號。

研究方向

在 Chrome 和 Firefox 中重現導覽行為,重點關注發生溢出的父元素以及報告中提到的捲軸樣式。檢查導覽樣式,並比較支援和不支援 ::webkit-scrollbar 或 scrollbar-color 時的結果。當導覽在沒有視覺溢出或偏移的情況下,恰好佔據發生溢出的父元素的 100% 時,即表示完成。

由索引模型根據 Issue 內容生成。

評估

技術堆疊
css
領域
frontend
Issue 類型
缺陷
難度
3/5
預估耗時
1-2 天
活躍度
停滯
描述清晰度
基本清楚
新手友好度
38/100

把新 issue 寄到你的電子郵件信箱

精選適合新手參與的 GitHub issue 摘要。