angular / angular/components

bug(mat-form-field): VoiceOver reads multiple group, set aria-hidden to supporting elements

Đang mở
#32,850 2 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Accessibility area: material/form-field P4
Ngôn ngữ chính
TypeScript
Star
25k
Fork
6.8k
Merge trung bình
1 ngày 8 giờ
Pull request đã merge (30 ngày)
91

Mô tả

Is this a regression?
  • Yes, this behavior used to work in the previous version
The previous version in which this bug was not present was

No response

Description

related to #32797

Supporting elements in MatFormField should have aria-hidden="true" here because they do not contribute to accessibility. I suggest the "Ripple" family of components, in this case selector matformfieldlineripple but also in all other places, to automatically add aria-hidden="true".

If hints and errors are empty, MatFormField still renders a hint wrapper, which then would read as an empty "group". In this case, this wrapper should also be "aria-hidden="true".

Reproduction

StackBlitz link: https://stackblitz.com/edit/components-issue-starter-cudkchbv?file=src%2Fmain.ts
Steps to reproduce:

  1. enable VoiceOver
  2. navigate through elements
Expected Behavior

At best, it should should skip the first "input", directly read "Input, edit text" and after that "test"

Actual Behavior

VoiceOver is reading the following at each navigation step:

  1. Input
  2. Input, edit text
  3. group
  4. group
Environment
  • Angular: tested with 18 and 20
  • CDK/Material: tested with 18 and 20
  • Browser(s): Chrome
  • Operating System (e.g. Windows, macOS, Ubuntu): macOS 26

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Bắt đầu với bản tái hiện StackBlitz được liên kết và phần triển khai MatFormField, tập trung vào các phần tử hỗ trợ và selector matformfieldlineripple được mô tả trong báo cáo. Kiểm tra cách nội dung hint và error trống tạo ra hint wrapper, sau đó xác minh bằng VoiceOver rằng các phần tử không đóng góp sẽ được bỏ qua và input cùng văn bản kiểm thử mong đợi vẫn có thể nghe được.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
angular, typescript
Lĩnh vực
accessibility, frontend
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
45/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.