patternfly / patternfly/patternfly-react
MenuToggle - add aria-controls prop to relate toggle and content it controls
まだ誰も着手していません。
- 主要言語
- TypeScript
- スター
- 862
- フォーク
- 392
- 平均マージ
- 4日 8時間
- マージ済み PR(30日)
- 9
説明
Describe the problem
With PF6, the dropdown menu popover is by default parented to the root. When the menu is open, there is no attribute which relates the popover menu back to the toggle button which opened it.
react-table ActionColumn is an example where PF owns both components but there's still no relation. It would be possible to override the MenuToggle by supplying a custom actionsToggle function.
In writing this issue, I realize it may not be possible without "hacks" for PF to relate the two when the application controls the rendering of both the toggle and menu separately.
Having a relationship between the two at the dom level would help with test automation such as cypress.
How do you reproduce the problem?
Go to https://www.patternfly.org/components/menus/dropdown
Open a dropdown menu
Using web inspector, inspect the dropdown toggle and popover menu parented to the root. Observe there is no attribute relating the two.
Expected behavior
Expected some attribute present, wether arbitrary or a11y requirement, to relate the two dom nodes.
Is this issue blocking you?
It is possible to supply an ID which then gets applied to the popover menu.
What is your product and what release date are you targeting?
RHOAI
Jira Issue: PF-998
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
PatternFly の dropdown ドキュメントの例と、issue で説明されている MenuToggle API から始めます。toggle と root が親になる popover がどのようにレンダリングされるかを追跡し、2 つの DOM ノードが関係を持つように props の動作を定義します。結果を dropdown の例と、利用可能であればそのアクセシビリティまたはインタラクションのテストで確認します。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- react, typescript
- 領域
- accessibility, frontend
- issue の種類
- 機能追加
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 活発さ
- 静か
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 58/100