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

Get name of predefined range as a prop #236

Closed
usahai opened this issue Jun 17, 2021 · 3 comments
Closed

Get name of predefined range as a prop #236

usahai opened this issue Jun 17, 2021 · 3 comments

Comments

@usahai
Copy link

usahai commented Jun 17, 2021

I'd like to use the label in the predefined ranges to replace the label in my button component. Is there any way to extract that from the component? I looked through the event props of the onApply component, but there is nothing in there. Also looked through the Button callback, nothing there either.

@usahai
Copy link
Author

usahai commented Jun 17, 2021

image
So when I click on this month, it would be nice if I could change the label to "this month" as well

@haowjy
Copy link

haowjy commented Jul 7, 2021

you can listen to onCallback for callback(start, end, label), and the label is the label of the predefined range.

@usahai
Copy link
Author

usahai commented Jul 8, 2021

It worked! Thanks!!

@usahai usahai closed this as completed Jul 8, 2021
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

No branches or pull requests

2 participants