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

Support adding more complex text in ControlLabel #221

Merged
merged 1 commit into from
Apr 8, 2024

Conversation

badiuoanaalexandra
Copy link
Contributor

Adds support for text to be string or ReactNode

Copy link
Contributor

@miafan23 miafan23 left a comment

Choose a reason for hiding this comment

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

Looks good

Comment on lines 35 to +36
/** Label text */
text: PropTypes.string.isRequired,
text: PropTypes.oneOfType([PropTypes.string, PropTypes.node]),
Copy link
Contributor

@miafan23 miafan23 Apr 8, 2024

Choose a reason for hiding this comment

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

Could you update the description Label text to tell it supports node too? now the showing type is union which is not very clear

Copy link
Contributor Author

@badiuoanaalexandra badiuoanaalexandra Apr 8, 2024

Choose a reason for hiding this comment

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

Oh, I didn't see your comment before I merged.. how do I update this..? It is being generated like this :(

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You mean this?
image

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It seems that I cannot change the "union" part, but I added more info in the text itself (I guess that's what you originally meant)
Fix is here #222

Copy link
Contributor

Choose a reason for hiding this comment

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

Yes, this what I mean

@badiuoanaalexandra badiuoanaalexandra merged commit 355fa2d into main Apr 8, 2024
3 checks passed
@badiuoanaalexandra badiuoanaalexandra deleted the studio-2221-textarea branch April 8, 2024 13:02
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.

2 participants