Document the discrepancies of :visible/:hidden on select options between Firefox & the rest
まだ誰も着手していません。
評価
- 難易度
- 2/5
- 見積もり時間
- 1〜3時間
- 初心者へのやさしさ
- 48/100
- issue の種類
- ドキュメント
- 明瞭さ
- おおむね明確
- 活発さ
- 停滞
- 技術スタック
- jquery
調査の方向性
まず、:visible と :hidden の jQuery API ドキュメントを、src/css/hiddenVisibleSelectors.js およびリンクされているブラウザーテストケースと併せて確認します。Firefox、IE、その他のブラウザーで報告されている相違点を記録し、CSSOM のグレーゾーンを説明したうえで、これらのセレクターを使用する際には注意するよう推奨します。関連する Firefox のバグも、コンテキストとしてリンクされています。
索引モデルが issue の本文から書いたものです。
説明
From https://github.com/jquery/jquery/issues/4463#issuecomment-527180911 by me:
:visible & :hidden which are jQuery selector extensions defined in src/css/hiddenVisibleSelectors.js. :hidden is defined as a negation of :visible so we can focus on the latter. And browsers differ here:
- Chrome 76, Safari 12.1 & Edge 18 match 0 elements for
:visible - Firefox 68 matches 2 elements. Its results for those two:
offsetWidth: 39 offsetHeight: 14 getClientRects().length: 1 - IE 11 matches 3 elements for
:visible. The results are not affected bydisplay: none:
The rect returned byoffsetWidth: 0 offsetHeight: 0 getClientRects().length: 1getClientRects()has all properties set to0.
The test case for the results I provided above: https://output.jsbin.com/bawosuv
From https://github.com/jquery/jquery/issues/4463#issuecomment-527182735 by me:
From a quick look at the CSSOM spec, all three properties (offsetWidth, offsetHeight & getClientRects) are expressed in terms of CSS layout box which has a note in the spec:
ISSUE 1 The terms CSS layout box and SVG layout box are not currently defined by CSS or SVG.
That indicates we're in a gray area here.
From https://github.com/jquery/jquery/issues/4463#issuecomment-529558196 by @gibson042:
It is an inconsistency, but I don't know that we should solve it. Lots of elements default to not having layout (<meta>, <style>, <template>, etc.), and in some cases that can be overridden. For example, <style> elements can have display: block, and—especially relevant here—<option>s in a <select multiple> really do take up space.
I think the right approach here is to push for a fix in Firefox, acknowledge that IE is just wrong, and add documentation recommending increased caution when using :hidden and :visible.
Issue reported in Firefox's bug tracker at https://bugzilla.mozilla.org/show_bug.cgi?id=1584752.
- 主要言語
- HTML
- スター
- 324
- フォーク
- 259
- 平均マージ
- 1日 30分
- マージ済み PR(30日)
- 1
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
jquery/api.jquery.com のほかの issue
-
Mention of ‘timestamp’ in documentation for ‘cache’ parameter of ‘ajax’ is misleading対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
jquery/api.jquery.com#1241 · コメント 2 件 ·
-
難易度 1/5 1時間未満 初心者へのやさしさ 68/100
jquery/api.jquery.com#1176 ·
-
The documentation of CSS methods should be further classified再び着手できるかも このイシューのプルリクエストはマージされずにクローズされました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
jquery/api.jquery.com#1281 · コメント 2 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 35/100
jquery/api.jquery.com#1271 · コメント 2 件 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 45/100
jquery/api.jquery.com#1259 ·
jquery/api.jquery.com の issue をすべて見る
似ている issue
-
5-minutes algorithm all-levels any-language beginner-friendly community documentation easy first-timers-only good first issue hacktoberfest help wanted learning no-code-needed open-source python students
難易度 2/5 1時間未満 初心者へのやさしさ 88/100
Huerte/algo-solutions-python#253 ·
メンテナーはふだん 1 日以内に返信
-
size/s
難易度 1/5 1時間未満 初心者へのやさしさ 90/100
sipyourdrink-ltd/bernstein#7179 ·
メンテナーはふだん 1 日以内に返信
-
area/docs
難易度 1/5 1時間未満 初心者へのやさしさ 86/100
meshery/meshery#23375 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Synthetic
難易度 1/5 1時間未満 初心者へのやさしさ 66/100
samtoth/agda-synthetic-categories#373 ·
メンテナーはふだん 1 日以内に返信
-
難易度 1/5 1時間未満 初心者へのやさしさ 62/100
tanaabased/big-test-bucket#19952 ·
メンテナーはふだん 1 日以内に返信