v14.2.0

Playroom

Github

Calendar

View Source

Render days in a calendar to allow users to pick dates easier.

Simple

Sun
Mon
Tue
Wed
Thu
Fri
Sat
28
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
1
2
3
4
5
6
7
8
9
10
Copy
Edit

Statuses

Sun
Mon
Tue
Wed
Thu
Fri
Sat
28
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
1
2
3
4
5
6
7
8
9
10
Copy
Edit

Drag to select

Sun
Mon
Tue
Wed
Thu
Fri
Sat
28
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
1
2
3
4
5
6
7
8
9
10
Copy
Edit

Props

dateDate

Used to calculate the month and year.

Used to calculate the initial month and year.

The minimum date the calendar can be navigated to.

The maximum date the calendar can be navigated to.

onDateChange(month: number) => void

Callback when month or year navigation occurs.

onDateSelect(day: Date) => void

Callback when a day is selected.

renderDay(props: Object) => void

Controls rendering of each day. Returns props that should be forwarded to Calendar.Day.

Displays a primary colored circle around the selected date.

size'sm' | 'md' | 'lg'

Sets the size of the calendar by changing cell and font sizes.

weekStartsOn0 | 1 | 2 | 3 | 4 | 5 | 6

Determines what day of the week the calendar should start on.

  • Simple
  • Statuses
  • Drag to select
  • Props
PreviousButton.InputNextCard