-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Calendar does not change when dates are changed via input #1845
Comments
any progress on this? I'm having the same problem.
|
Hello! 👋
An answer will be greatly appreciated. |
This may be a separate issue, but it feels related. It also doesn't seem to update if you pass startDate or initialVisibleMonth as props and later update those props outside of the component. In other words, through state changes on the parent component. Seems like something is preventing it from seeing the updated dates. |
if i understand the issue correctly, i had a similar issue. i was passing an array of objects in that contained the dates i needed highlighted. this array changed in length based on filters that were selected. the calendar would only highlight the initial array of dates passed in, it wouldnt change when the filters values changed. heres what i did to resolve, hope it helps
|
Any progress on this? I want to update the dates from outside of calendar and calendar will always in open state. When I updated the date from outside of the calendar, calendar remained at that month. |
Also curious if anyone has found a solution for this. Not a deal breaker as this is the best (most customizable) date picker I have found, but this would be the last thing needed to make it feel truly complete. |
If there's a solution that can be added to the docs, great! Please submit a PR. If there's a solution that requires changes to this library, please submit a PR (ideally after some discussion here). |
I did it by re-rendering the calendar again by passing different key to the
component on date change.
I was able to do in this way not an optimal solution but not able to find
other one.
…On Thu, 27 Jan 2022 at 1:23 AM, Dehn Hunsworth ***@***.***> wrote:
Also curious if anyone has found a solution for this. Not a deal breaker
as this is the best (most customizable) date picker I have found, but this
would be the last thing needed to make it feel truly complete.
—
Reply to this email directly, view it on GitHub
<#1845 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AKZQ7WMJHRZDGDEQ7MMYGTTUYBGLTANCNFSM4JDNSSMA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you commented.Message ID:
***@***.***>
|
This comment was marked as spam.
This comment was marked as spam.
setting an activeStartDate worked for me |
As the topic says, the calendar does not switch to the date entered via input box. I have tried it with the demos in storybook: Allow All Days Including Past Days
First enter:
![image](https://user-images.githubusercontent.com/53431443/67274420-fa4b1b80-f4f2-11e9-90f4-8c6270236535.png)
10/25/2019
in startDateYou'll see it is highlighted in the calendar.
2nd:
![image](https://user-images.githubusercontent.com/53431443/67274507-26ff3300-f4f3-11e9-9102-756bd4ace4bd.png)
10/25/2018
3rd:
![image](https://user-images.githubusercontent.com/53431443/67274552-3e3e2080-f4f3-11e9-9fb4-451a36acd204.png)
10/25/2025
As you can see in the 2nd and 3rd input, it does not render the calendar on those years. In order to see the change in calendar, you need to enter start and end date and close the calendar. Right now I am using the ff. settings:
I am using the
keepOpenOnDateSelect
for UI/UX purposes.Question is: How can I re-render the calendar without closing the calendar itself? Is it possible to re-render the calendar upon finished typing?
Also I think it is a bug when
isOutsideRange
false, the past dates that were selected aren't highlighted. They'll only be highlighted when switching months and they'll be gone when you focus on the month of the date specified. Found this Past Issue with no solution. Is there any solution now?The demo isn't enough to cover all of the props of the datepicker. I hope there will be more examples on how to properly use the props. Thank you very much in advance.
The text was updated successfully, but these errors were encountered: