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

fix: select wrong alignment #1053

Merged
merged 16 commits into from
May 20, 2024
Prev Previous commit
Next Next commit
add number of mnths
  • Loading branch information
mbauchet committed Jul 30, 2023
commit 75a94273f81ee65450e0b103ffcc913c697ecdc0
Original file line number Diff line number Diff line change
@@ -48,6 +48,7 @@ export interface DateRangePickerProps
locale?: Locale;
enableClear?: boolean;
enableYearNavigation?: boolean;
numberOfMonths?: number;
children?: React.ReactElement[] | React.ReactElement;
}

@@ -67,6 +68,7 @@ const DateRangePicker = React.forwardRef<HTMLDivElement, DateRangePickerProps>((
children,
className,
enableYearNavigation = false,
numberOfMonths = 1,
...other
} = props;

@@ -242,6 +244,7 @@ const DateRangePicker = React.forwardRef<HTMLDivElement, DateRangePickerProps>((
from: selectedStartDate,
to: selectedEndDate,
}}
numberOfMonths={numberOfMonths ?? 1}
onSelect={
((v: DateRange) => {
onValueChange?.({ from: v?.from, to: v?.to });