Skip to content

[feat]: File Upload – Add ability to provide aria-label to the input #263

@albert-tarly

Description

@albert-tarly

Feature description

Currently it's not possible to pass aria-label to the file input in File Upload. It has an aria-labelledby though, but it points to a label with sr-only class, which makes it invisible for non screen readers: docs/registry/bases/radix/ui/file-upload.tsx#L653. axe-core validation rule label-title-only fails on the input field due to that (see my report in their repository for the context)

It would be good if the aria-label parameter passed to root component would be assigned to the input, not the wrapping element. That could improve the accessibility of the whole thing.

Before submitting

  • I've made research efforts and searched the documentation
  • I've searched for existing issues and PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions