github / github/annotation-toolkit
[Feature request] Add `aria-disabled` guidance to form element annotations
- 主要語言
- 沒有語言資料
- 星號
- 320
- 分支
- 33
- 平均合併
- 36 分鐘
- 30 天內合併 PR
- 2
描述
### Description
When annotating form elements that should be non-interactive, the toolkit currently offers a `disabled` toggle. In practice, using the native `disabled` attribute removes the element from the accessibility tree, making it undiscoverable to assistive technology users. The preferred approach in most cases is to use `aria-disabled="true"` instead, which keeps the element discoverable while preventing interaction.
### Requested change
When the disabled state is toggled on for a form element annotation, the annotation should communicate that `aria-disabled` is the recommended approach. This could look like:
- Replacing the simple "disabled: true" label with guidance text, such as: "This field should use `aria-disabled` to maintain accessibility and discoverability"
- Adding a flyout tip (similar to how Primer A11y Presets work) that appears when the toggle is enabled, explaining the rationale
### Why
Using `aria-disabled` instead of `disabled` is a widely recommended practice. By surfacing this guidance directly in the annotation, we can help designers communicate the right implementation to developers without requiring specialized accessibility knowledge.
### References
- [Make disabled buttons accessible](https://advancedbytez.com/make-disabled-buttons-accessible/)
貢獻指南
研究方向
從表單元素註解入口開始,檢查停用切換開關的呈現方式,然後將其與現有的 Primer A11y Presets flyout 行為進行比較。啟用切換開關後,註解中能夠傳達 aria-disabled 的建議及其理由,且最終的呈現方式已達成共識並完成驗證,即表示完成。
由索引模型根據 Issue 內容生成。
評估
- 技術堆疊
- figma
- 領域
- accessibility, design
- Issue 類型
- 功能
- 難度
- 4/5
- 預估耗時
- 3-5 天
- 活躍度
- 停滯
- 描述清晰度
- 基本清楚
- 新手友好度
- 45/100