Dates beyond 2030 and autoscroll in select (#12998)

We got several requests to be able to set dates beyond 2030 which seems
reasonable from a business standpoint! The problem was that then it
required scrolling to get to the current date so a bad UX for most
cases. I forced re-selecting the item to trigger auto scroll
This commit is contained in:
Félix Malfait
2025-07-02 17:21:13 +02:00
committed by GitHub
parent e8a2d71844
commit 9f0b8809cb
4 changed files with 16 additions and 4 deletions

View File

@ -26,7 +26,7 @@ const StyledCustomDatePickerHeader = styled.div`
const years = Array.from(
{ length: 200 },
(_, i) => new Date().getFullYear() + 5 - i,
(_, i) => new Date().getFullYear() + 50 - i,
).map((year) => ({ label: year.toString(), value: year }));
type AbsoluteDatePickerHeaderProps = {

View File

@ -0,0 +1 @@
export type SelectValue = string | number | boolean | null;