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

Calendar:Cannot manually reset and set today #6445

Closed
galimovkirill opened this issue Apr 22, 2024 · 6 comments · Fixed by #6447 or leoo1992/GeradorQRCode#23
Closed

Calendar:Cannot manually reset and set today #6445

galimovkirill opened this issue Apr 22, 2024 · 6 comments · Fixed by #6447 or leoo1992/GeradorQRCode#23
Assignees
Labels
Type: Bug Issue contains a defect related to a specific component.
Milestone

Comments

@galimovkirill
Copy link

Describe the bug

In this issue #6422 I described the problem of calling updateViewDate with null parameter as a value, but got an error. Errors has been fixed, but I still cannot reset current date by passing null as a value.

Also, I cannot set today date by passing new Date() as a value of updateViewDate - it's just not updating for some reasons.

Reproducer

https://codesandbox.io/p/devbox/objective-lena-ypxjyy?file=%2Fsrc%2FApp.tsx%3A22%2C16

PrimeReact version

10.6.3

React version

17.x

Language

TypeScript

Build / Runtime

Vite

Browser(s)

No response

Steps to reproduce the behavior

No response

Expected behavior

No response

@galimovkirill galimovkirill added the Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible label Apr 22, 2024
@Rekl0w
Copy link
Contributor

Rekl0w commented Apr 22, 2024

#6425 fix will be at 10.6.4

@galimovkirill
Copy link
Author

#6425 fix will be at 10.6.4

I saw this PR and it resolves an errors (because of handling nullish value) but it still cannot update date with passing null or new Date() as a value.

I reproduce it in master branch with actual state of it. Try the same code sample from sandbox in your locale environment.

@galimovkirill
Copy link
Author

galimovkirill commented Apr 22, 2024

image

I made this change to make it work as expected, but I cannot contribute because never did it yet)

@Rekl0w
Copy link
Contributor

Rekl0w commented Apr 22, 2024

If you want, you need to fork this project and create a new branch about this fix, then create PR or send me the changes and i can PR for you.

@Rekl0w
Copy link
Contributor

Rekl0w commented Apr 22, 2024

I changed a bit this code for null check and created PR.

@galimovkirill
Copy link
Author

I changed a bit this code for null check and created PR.

Thank you!

@melloware melloware added Type: Bug Issue contains a defect related to a specific component. and removed Status: Needs Triage Issue will be reviewed by Core Team and a relevant label will be added as soon as possible labels Apr 22, 2024
@melloware melloware added this to the 10.6.4 milestone Apr 22, 2024
@galimovkirill galimovkirill changed the title Calendar:Cannot manually reset and set todat Calendar:Cannot manually reset and set today Apr 26, 2024
nitrogenous added a commit that referenced this issue Apr 29, 2024
Fix #6445: Calendar updateViewDate fix
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Bug Issue contains a defect related to a specific component.
Projects
None yet
3 participants