Skip to content

Allow Modal to pass a dismiss label prop to DismissButton to override the defaultΒ #7787

Open
@lukpsaxo

Description

@lukpsaxo

Provide a general summary of the feature here

In Modal -
https://github.com/adobe/react-spectrum/blob/main/packages/react-aria-components/src/Modal.tsx#L217

There is no way to pass a dismiss label to override the default. It is already supported by DismissButton.

πŸ’ Possible Solution

Would you want Modal to take dismiss-aria-label ? I suppose aria-label on a Modal shouldn't be the text to dismiss?

πŸ”¦ Context

We have multiple ways to cancel/dismiss a dialog and for accessibility reasons I'd like them to have the same label. We also support some language variants you don't.

πŸ’» Examples

No response

🧒 Your Company/Team

Saxo Bank

πŸ•· Tracking Issue

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions