patternfly / patternfly/patternfly-react

[Popover] - allow its sparing usage for interactive content

未关闭
#11,746 2 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

Demo Stale
主要语言
TypeScript
星标
862
派生
392
平均合并
4 天 8 小时
30 天内合并 PR
9

描述

Is this a new component or an extension of an existing one?

And extension/adjustment of Popover

Describe the feature

Allow interactive content for using it in scenarios where other components such as Modal, Menu, or Dropdown, don’t quite fit the use case.

As an example, see the screenshots below of rough prototypes for an interface that allows users quick access to available Wi-Fi networks and keyboard layout from a top toolbar.

One concern I have is that the Popover component internally uses the aria-describedby attribute, which I believe makes the interactive content inaccessible. From my limited understanding of accessibility, and after reviewing MDN's documentation, it seems that using aria-details might help.

The aria-describedby property is appropriate when the associated content contains plain text. If the content is extensive, contains useful semantics, or has a complex structure requiring user navigation, use aria-details instead. aria-details allows assistive technology users to visit the associated structured content and provides additional navigation commands, making it easier to understand the structure, or experience the information in smaller pieces.

https://developer.mozilla.org/en-US/docs/Web/Accessibility/ARIA/Reference/Attributes/aria-describedby

Are there visuals for this feature? If applicable, please include examples for each state and for varying widths

See these rough prototypes

Available Wi-Fi networks Localization options
Available Wi-Fi networks in a Popover prototype Localization options in a Popover prototype

Any other information?

Originally posted as a discussion in #11745, but later realized that a feature request issue might be a better place for it.

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

从 packages/react-core/src/components/Popover/Popover.tsx 开始,重点查看第 456 行附近对 aria-describedby 的使用,并审阅 Popover 文档和链接的 ARIA 指南。确定交互式内容的无障碍要求,并将完成定义为:Popover 支持所要求的使用场景,同时不会使其内容变得无法访问。

由索引模型根据 Issue 内容生成。

评估

技术栈
react, typescript
领域
accessibility, frontend
Issue 类型
功能
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
35/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。