Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update <Confirm> to accept a React node as confirmTitle or confirmContent #9115

Merged
merged 4 commits into from
Jul 24, 2023

Conversation

yurassic
Copy link
Contributor

@yurassic yurassic commented Jul 20, 2023

All Buttons with confirmation Dialog for confirmTitle prop accepts only string type, which make not possible for customization.
In this PR I changed type to React.ReactNode, also I fixed PropTypes value for confirmContent as it was conflicted with TS types and errored in App console.

This PR resolves these issues: #9113, #9105

Copy link
Collaborator

@djhi djhi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice! Thanks!

Copy link
Contributor

@slax57 slax57 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Other than that it looks good, thanks 👍

Copy link
Contributor

@slax57 slax57 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks

@slax57 slax57 added this to the 4.13.0 milestone Jul 24, 2023
@slax57 slax57 merged commit 8b52f0f into marmelab:next Jul 24, 2023
7 checks passed
@slax57 slax57 changed the title Improve confirmTitle type Add ability to pass a React Node to confirmTitle or confirmContent in buttons with a confirmation dialog Jul 24, 2023
@fzaninotto fzaninotto changed the title Add ability to pass a React Node to confirmTitle or confirmContent in buttons with a confirmation dialog Update <Confirm> to accept a React node as confirmTitle or confirmContent Aug 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants