patternfly / patternfly/patternfly-react

MenuToggle - add aria-controls prop to relate toggle and content it controls

オープン
#11,304 コメント 10 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

A11y Stale
主要言語
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

コントリビューションガイド

コントリビューションガイドを開く

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. 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

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。