-
-
Notifications
You must be signed in to change notification settings - Fork 5.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix DateInput ignores the timezone when given
## Problem The changes introduced in #10299 leads to a regression when the field value is an ISO string or date. The idea of that change was that if the value contains a date, react-admin should always display that date. This is often not what users want, because a date entered in a US browser than stored in GMT then displayed again will have shifted. Besides, this is not required to fix #10197. The fix in #10299 is the removal of the call to `parse` in `onChange` (in fact, `parse` used to be called twice). ## Solution Do not strip the timezone data, whether the field value is a string or a date.
- Loading branch information
1 parent
ad1fb56
commit fd4f57c
Showing
4 changed files
with
35 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters