Getting StartedStateThemingCompositionDate FrameworksLocalizationAnimatedGroupAnimatedMonthGroupExamplePropsImportingCalendarCalendarProviderClickOutsideDayDayOfWeekHeaderHomeMonthMonthGroupPopperRootWeekWeekHeaderuseCalendarDispatchuseCalendarPropsuseCalendarStateuseDateAPIuseDateInputuseDateRangeInput
Components
Hooks
AnimatedMonthGroup
The AnimatedMonthGroup
component animates it's children based on the change of the visibleFromDate
and refs, applied to the first (firstColumnRef
). and last column (groupRef
).
In the default implementation, AnimatedMonthGroup is the parent of AnimatedMonth
and is used to manage
scroll movement between columns based on the changes to visibleFromDate
.
Example
Build your own datepicker
with use-date-input
Build your own datepicker
with use-date-input
Build your own datepicker
with use-date-input
Props
Prop Name | Type | Is Required | Default Value | Description |
---|---|---|---|---|
children | element | optional | Children | |
firstColumnRef | object | required | Ref to the first column | |
groupRef | object | required | Ref to the MonthGroup | |
visibleFromDate | object | required | Visible from date, used to control animation between columns and MonthGroup |
Importing
It can be imported as either the base component
import { AnimatedMonthGroup } from "@use-date-input/core";
or as an overridable component that can be replaced through the components
prop in CalendarProvider
.
Refer to How to replace UI components.
import { CustomisableAnimatedMonthGroup } from "@use-date-input/core";
If providing your own component, it can be useful to import the base component and use it within your composition.