-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
[pickers] Error: value.isValid is not a function at AdapterDayjs.isValid after v7 #12706
Comments
Hi, Could you provide a working reproduction, this Codesandbox template might be a good starting point. |
Hi, Thanks |
@arajczy The problem is that final-form is providing a value of {...input}
+value={input.value || null} Does it solve your problem? 🤔 |
@LukasTy thanks a lot, it solves my problem. |
@arajczy: How did we do? Your experience with our support team matters to us. If you have a moment, please share your thoughts in this short Support Satisfaction survey. |
By the way, the |
Good to know, thanks |
Steps to reproduce
go to https://codesandbox.io/p/devbox/priceless-spence-q3tmp8
Current behavior
Uncaught TypeError: value.isValid is not a function
at AdapterDayjs.isValid (@mui_x-date-pickers_AdapterDayjs.js?v=39321bad:574:20)
at Object.getTimezone (@mui_x-date-pickers_DatePicker.js?v=968b33b8:1020:58)
at @mui_x-date-pickers_DatePicker.js?v=968b33b8:1817:59
at mountMemo (chunk-WIE3TTAG.js?v=0ca62ba9:12817:27)
at Object.useMemo (chunk-WIE3TTAG.js?v=0ca62ba9:13141:24)
at Object.useMemo (chunk-VMGWFLE5.js?v=0ca62ba9:1094:29)
at useValueWithTimezone (@mui_x-date-pickers_DatePicker.js?v=968b33b8:1817:32)
at usePickerValue (@mui_x-date-pickers_DatePicker.js?v=968b33b8:1996:7)
at usePicker (@mui_x-date-pickers_DatePicker.js?v=968b33b8:2485:31)
at useDesktopPicker (@mui_x-date-pickers_DatePicker.js?v=968b33b8:3049:7)
AdapterDayjs.isValid @ @mui_x-date-pickers_AdapterDayjs.js?v=39321bad:574
getTimezone @ @mui_x-date-pickers_DatePicker.js?v=968b33b8:1020
(névtelen) @ @mui_x-date-pickers_DatePicker.js?v=968b33b8:1817
mountMemo @ chunk-WIE3TTAG.js?v=0ca62ba9:12817
useMemo @ chunk-WIE3TTAG.js?v=0ca62ba9:13141
useMemo @ chunk-VMGWFLE5.js?v=0ca62ba9:1094
useValueWithTimezone @ @mui_x-date-pickers_DatePicker.js?v=968b33b8:1817
usePickerValue @ @mui_x-date-pickers_DatePicker.js?v=968b33b8:1996
usePicker @ @mui_x-date-pickers_DatePicker.js?v=968b33b8:2485
useDesktopPicker @ @mui_x-date-pickers_DatePicker.js?v=968b33b8:3049
DesktopDatePicker2 @ @mui_x-date-pickers_DatePicker.js?v=968b33b8:10166
renderWithHooks @ chunk-WIE3TTAG.js?v=0ca62ba9:12171
updateForwardRef @ chunk-WIE3TTAG.js?v=0ca62ba9:14327
beginWork @ chunk-WIE3TTAG.js?v=0ca62ba9:15934
beginWork$1 @ chunk-WIE3TTAG.js?v=0ca62ba9:19749
performUnitOfWork @ chunk-WIE3TTAG.js?v=0ca62ba9:19194
workLoopSync @ chunk-WIE3TTAG.js?v=0ca62ba9:19133
renderRootSync @ chunk-WIE3TTAG.js?v=0ca62ba9:19112
recoverFromConcurrentError @ chunk-WIE3TTAG.js?v=0ca62ba9:18732
performConcurrentWorkOnRoot @ chunk-WIE3TTAG.js?v=0ca62ba9:18680
workLoop @ chunk-WIE3TTAG.js?v=0ca62ba9:197
flushWork @ chunk-WIE3TTAG.js?v=0ca62ba9:176
performWorkUntilDeadline @ chunk-WIE3TTAG.js?v=0ca62ba9:384
23 további keret megjelenítése
Kevesebb megjelenítése
8ServiceWorkerWrapper.jsx:17
Expected behavior
With @mui/x-date-pickers 6.19.9 - it is working but if I upgrade to @mui/x-date-pickers 7.1.1 I get the above error.
If I comment out the field labeled as "StartDate" - it works with version 7.1.1 too
Context
No response
Your environment
npx @mui/envinfo
Search keywords: isValid AdapterDayjs
The text was updated successfully, but these errors were encountered: