@lazerlen/legend-calendar 1.3.0 → 1.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,12 +9,12 @@
9
9
  CJS Build start
10
10
  ESM Build start
11
11
  DTS Build start
12
- CJS dist/index.js 74.31 KB
13
- CJS dist/index.js.map 142.39 KB
14
- CJS ⚡️ Build success in 1155ms
15
- ESM dist/index.mjs 71.21 KB
16
- ESM dist/index.mjs.map 141.86 KB
17
- ESM ⚡️ Build success in 1155ms
18
- DTS ⚡️ Build success in 1283ms
19
- DTS dist/index.d.ts 24.36 KB
20
- DTS dist/index.d.mts 24.36 KB
12
+ CJS dist/index.js 75.57 KB
13
+ CJS dist/index.js.map 144.75 KB
14
+ CJS ⚡️ Build success in 1193ms
15
+ ESM dist/index.mjs 72.47 KB
16
+ ESM dist/index.mjs.map 144.21 KB
17
+ ESM ⚡️ Build success in 1193ms
18
+ DTS ⚡️ Build success in 1295ms
19
+ DTS dist/index.d.ts 24.86 KB
20
+ DTS dist/index.d.mts 24.86 KB
@@ -5,213 +5,213 @@
5
5
  src/hooks/useDateRange.test.ts:
6
6
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
7
7
  The current testing environment is not configured to support act(...)
8
- ✓ useDateRange > should initialize with correct default values [7.06ms]
8
+ ✓ useDateRange > should initialize with correct default values [7.12ms]
9
9
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
10
10
  The current testing environment is not configured to support act(...)
11
11
  The current testing environment is not configured to support act(...)
12
12
  The current testing environment is not configured to support act(...)
13
13
  The current testing environment is not configured to support act(...)
14
14
  The current testing environment is not configured to support act(...)
15
- ✓ useDateRange > should update dateRange correctly on onCalendarDayPress [1.84ms]
15
+ ✓ useDateRange > should update dateRange correctly on onCalendarDayPress [1.26ms]
16
16
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
17
17
  The current testing environment is not configured to support act(...)
18
18
  The current testing environment is not configured to support act(...)
19
19
  The current testing environment is not configured to support act(...)
20
20
  The current testing environment is not configured to support act(...)
21
- ✓ useDateRange > should clear dateRange on onClearDateRange [0.95ms]
21
+ ✓ useDateRange > should clear dateRange on onClearDateRange [1.26ms]
22
22
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
23
23
  The current testing environment is not configured to support act(...)
24
24
  The current testing environment is not configured to support act(...)
25
25
  The current testing environment is not configured to support act(...)
26
26
  The current testing environment is not configured to support act(...)
27
- ✓ useDateRange > should update isDateRangeValid correctly [0.37ms]
27
+ ✓ useDateRange > should update isDateRangeValid correctly [0.57ms]
28
28
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
29
29
  The current testing environment is not configured to support act(...)
30
- ✓ useDateRange > can initialize a date range [0.11ms]
30
+ ✓ useDateRange > can initialize a date range [0.14ms]
31
31
  
32
32
  src/hooks/useCalendarList.test.ts:
33
- ✓ getHeightForMonth > Measures months with 5 weeks (no calendar spacing) [0.10ms]
34
- ✓ getHeightForMonth > Measures months with 5 weeks (with calendar spacing) [0.03ms]
35
- ✓ getHeightForMonth > Accounts for additional height [0.02ms]
36
- ✓ getHeightForMonth > Measures months with 6 weeks [0.02ms]
37
- ✓ getHeightForMonth > February 24 has the right height with base options [0.66ms]
33
+ ✓ getHeightForMonth > Measures months with 5 weeks (no calendar spacing) [0.07ms]
34
+ ✓ getHeightForMonth > Measures months with 5 weeks (with calendar spacing)
35
+ ✓ getHeightForMonth > Accounts for additional height
36
+ ✓ getHeightForMonth > Measures months with 6 weeks
37
+ ✓ getHeightForMonth > February 24 has the right height with base options [0.60ms]
38
38
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
39
39
  The current testing environment is not configured to support act(...)
40
40
  The current testing environment is not configured to support act(...)
41
41
  The current testing environment is not configured to support act(...)
42
- ✓ useCalendarList > Min/Max dates > Max: virtualization still works as expected [1.04ms]
42
+ ✓ useCalendarList > Min/Max dates > Max: virtualization still works as expected [1.51ms]
43
43
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
44
44
  The current testing environment is not configured to support act(...)
45
45
  The current testing environment is not configured to support act(...)
46
46
  The current testing environment is not configured to support act(...)
47
- ✓ useCalendarList > Min/Max dates > Min: virtualization still works as expected [0.28ms]
47
+ ✓ useCalendarList > Min/Max dates > Min: virtualization still works as expected [1.08ms]
48
48
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
49
49
  The current testing environment is not configured to support act(...)
50
- ✓ useCalendarList > Min/Max dates > Returns a single month when min and max are in the same month [0.06ms]
50
+ ✓ useCalendarList > Min/Max dates > Returns a single month when min and max are in the same month [0.30ms]
51
51
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
52
52
  The current testing environment is not configured to support act(...)
53
- ✓ useCalendarList > Min/Max dates > Returns a range of months bounded by the min and max dates [0.10ms]
53
+ ✓ useCalendarList > Min/Max dates > Returns a range of months bounded by the min and max dates [0.23ms]
54
54
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
55
55
  The current testing environment is not configured to support act(...)
56
56
  ✓ useCalendarList > Min/Max dates > Ignores past/future scroll ranges when min/max dates are used [0.10ms]
57
57
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
58
58
  The current testing environment is not configured to support act(...)
59
- ✓ useCalendarList > Min/Max dates > Append/Prepend are no-op if min/max are reached [0.10ms]
59
+ ✓ useCalendarList > Min/Max dates > Append/Prepend are no-op if min/max are reached [0.15ms]
60
60
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
61
61
  The current testing environment is not configured to support act(...)
62
62
  The current testing environment is not configured to support act(...)
63
63
  The current testing environment is not configured to support act(...)
64
- ✓ useCalendarList > Min/Max dates > Prepend does not trigger a state update when starting month is already present [0.52ms]
64
+ ✓ useCalendarList > Min/Max dates > Prepend does not trigger a state update when starting month is already present [0.85ms]
65
65
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
66
66
  The current testing environment is not configured to support act(...)
67
- ✓ useCalendarList > github issues > #16: Incorrect scroll position when setting calendarMinDateId [0.15ms]
67
+ ✓ useCalendarList > github issues > #16: Incorrect scroll position when setting calendarMinDateId [0.48ms]
68
68
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
69
69
  The current testing environment is not configured to support act(...)
70
- ✓ useCalendarList > Data is correctly built when future/past ranges are 0 [0.12ms]
70
+ ✓ useCalendarList > Data is correctly built when future/past ranges are 0 [0.13ms]
71
71
  
72
72
  src/hooks/useCalendar.test.ts:
73
- ✓ buildCalendar > isLastDayOfWeek > isLastDayOfWeek respects "sunday" as last day of week [11.87ms]
74
- ✓ buildCalendar > isLastDayOfWeek > isLastDayOfWeek respects "monday" as last day of week [1.15ms]
75
- ✓ buildCalendar > isWeekend > starting on sunday [1.51ms]
76
- ✓ buildCalendar > isWeekend > starting on monday [1.05ms]
77
- ✓ buildCalendar > state > active: supersedes today [1.27ms]
78
- ✓ buildCalendar > state > active: supersedes disabled (with calendarDisabledDateIds) [1.36ms]
79
- ✓ buildCalendar > state > active: supersedes disabled (with min) [0.90ms]
80
- ✓ buildCalendar > state > active: supersedes disabled (with max) [1.09ms]
81
- ✓ buildCalendar > state > active: supersedes idle [1.14ms]
82
- ✓ buildCalendar > state > disabled: supersedes idle [1.11ms]
83
- ✓ buildCalendar > state > today: supersedes idle [1.29ms]
84
- ✓ buildCalendar > state > idle: serves as the base state [1.58ms]
85
- ✓ buildCalendar > builds the month row [1.37ms]
86
- ✓ buildCalendar > build the month row with custom formatting [2.73ms]
87
- ✓ buildCalendar > builds the week days row starting on sunday [1.14ms]
88
- ✓ buildCalendar > builds the week days row starting on monday [1.29ms]
89
- ✓ buildCalendar > builds the weeks row [1.51ms]
90
- ✓ buildCalendar > build the weeks row with custom formatting [0.82ms]
91
- ✓ buildCalendar > handles the expected range [0.93ms]
92
- ✓ buildCalendar > calendarMinDate [1.17ms]
93
- ✓ buildCalendar > calendarMaxDate [1.07ms]
73
+ ✓ buildCalendar > isLastDayOfWeek > isLastDayOfWeek respects "sunday" as last day of week [8.85ms]
74
+ ✓ buildCalendar > isLastDayOfWeek > isLastDayOfWeek respects "monday" as last day of week [0.87ms]
75
+ ✓ buildCalendar > isWeekend > starting on sunday [1.57ms]
76
+ ✓ buildCalendar > isWeekend > starting on monday [2.32ms]
77
+ ✓ buildCalendar > state > active: supersedes today [2.13ms]
78
+ ✓ buildCalendar > state > active: supersedes disabled (with calendarDisabledDateIds) [1.13ms]
79
+ ✓ buildCalendar > state > active: supersedes disabled (with min) [1.33ms]
80
+ ✓ buildCalendar > state > active: supersedes disabled (with max) [1.06ms]
81
+ ✓ buildCalendar > state > active: supersedes idle [1.09ms]
82
+ ✓ buildCalendar > state > disabled: supersedes idle [1.23ms]
83
+ ✓ buildCalendar > state > today: supersedes idle [1.14ms]
84
+ ✓ buildCalendar > state > idle: serves as the base state [1.81ms]
85
+ ✓ buildCalendar > builds the month row [1.05ms]
86
+ ✓ buildCalendar > build the month row with custom formatting [2.47ms]
87
+ ✓ buildCalendar > builds the week days row starting on sunday [1.37ms]
88
+ ✓ buildCalendar > builds the week days row starting on monday [1.23ms]
89
+ ✓ buildCalendar > builds the weeks row [1.58ms]
90
+ ✓ buildCalendar > build the weeks row with custom formatting [0.65ms]
91
+ ✓ buildCalendar > handles the expected range [1.07ms]
92
+ ✓ buildCalendar > calendarMinDate [1.13ms]
93
+ ✓ buildCalendar > calendarMaxDate [1.32ms]
94
94
  
95
95
  src/hooks/useOptimizedDayMetadata.test.ts:
96
96
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
97
97
  The current testing environment is not configured to support act(...)
98
- ✓ useOptimizedDayMetadata > return the base metadata as the initial value [1.08ms]
98
+ ✓ useOptimizedDayMetadata > return the base metadata as the initial value [0.76ms]
99
99
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
100
100
  The current testing environment is not configured to support act(...)
101
101
  The current testing environment is not configured to support act(...)
102
- ✓ useOptimizedDayMetadata > if the base changes, the returned value should match it. [1.01ms]
102
+ ✓ useOptimizedDayMetadata > if the base changes, the returned value should match it. [0.76ms]
103
103
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
104
104
  The current testing environment is not configured to support act(...)
105
105
  The current testing environment is not configured to support act(...)
106
- ✓ useOptimizedDayMetadata > endOfRange: returns the updated metadata once an event is emitted [1.01ms]
106
+ ✓ useOptimizedDayMetadata > endOfRange: returns the updated metadata once an event is emitted [0.37ms]
107
107
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
108
108
  The current testing environment is not configured to support act(...)
109
109
  The current testing environment is not configured to support act(...)
110
- ✓ useOptimizedDayMetadata > startOfRange: returns the updated metadata once an event is emitted [0.37ms]
110
+ ✓ useOptimizedDayMetadata > startOfRange: returns the updated metadata once an event is emitted [0.16ms]
111
111
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
112
112
  The current testing environment is not configured to support act(...)
113
113
  The current testing environment is not configured to support act(...)
114
- ✓ useOptimizedDayMetadata > startOfRange|endOfRange: returns the updated metadata once an event is emitted [0.25ms]
114
+ ✓ useOptimizedDayMetadata > startOfRange|endOfRange: returns the updated metadata once an event is emitted [0.13ms]
115
115
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
116
116
  The current testing environment is not configured to support act(...)
117
117
  The current testing environment is not configured to support act(...)
118
- ✓ useOptimizedDayMetadata > doesn't re-render if the active dates don't overlap [0.24ms]
118
+ ✓ useOptimizedDayMetadata > doesn't re-render if the active dates don't overlap [0.13ms]
119
119
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
120
120
  The current testing environment is not configured to support act(...)
121
121
  The current testing environment is not configured to support act(...)
122
122
  The current testing environment is not configured to support act(...)
123
- ✓ useOptimizedDayMetadata > resets the state once a new range is selected [0.18ms]
123
+ ✓ useOptimizedDayMetadata > resets the state once a new range is selected [0.13ms]
124
124
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
125
125
  The current testing environment is not configured to support act(...)
126
126
  The current testing environment is not configured to support act(...)
127
- ✓ useOptimizedDayMetadata with calendarInstanceId > uses the default instance ID when not provided [0.16ms]
127
+ ✓ useOptimizedDayMetadata with calendarInstanceId > uses the default instance ID when not provided [0.09ms]
128
128
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
129
129
  The current testing environment is not configured to support act(...)
130
130
  The current testing environment is not configured to support act(...)
131
- ✓ useOptimizedDayMetadata with calendarInstanceId > responds to events for the correct instance ID [0.12ms]
131
+ ✓ useOptimizedDayMetadata with calendarInstanceId > responds to events for the correct instance ID [0.08ms]
132
132
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
133
133
  The current testing environment is not configured to support act(...)
134
- ✓ useOptimizedDayMetadata with calendarInstanceId > ignores events for different instance IDs [0.09ms]
134
+ ✓ useOptimizedDayMetadata with calendarInstanceId > ignores events for different instance IDs [0.06ms]
135
135
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
136
136
  The current testing environment is not configured to support act(...)
137
137
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
138
138
  The current testing environment is not configured to support act(...)
139
139
  The current testing environment is not configured to support act(...)
140
140
  The current testing environment is not configured to support act(...)
141
- ✓ useOptimizedDayMetadata with calendarInstanceId > handles multiple instances correctly [0.21ms]
141
+ ✓ useOptimizedDayMetadata with calendarInstanceId > handles multiple instances correctly [0.18ms]
142
142
  react-test-renderer is deprecated. See https://react.dev/warnings/react-test-renderer
143
143
  The current testing environment is not configured to support act(...)
144
144
  The current testing environment is not configured to support act(...)
145
145
  The current testing environment is not configured to support act(...)
146
- ✓ useOptimizedDayMetadata with calendarInstanceId > resets state for the correct instance when a new range is selected [0.15ms]
146
+ ✓ useOptimizedDayMetadata with calendarInstanceId > resets state for the correct instance when a new range is selected [0.10ms]
147
147
  
148
148
  src/helpers/dates.test.ts:
149
149
  ✓ toDateId: UTC time zone > January 1st, 2024
150
- ✓ toDateId: UTC time zone > January 31th, 2024 [0.02ms]
151
- ✓ toDateId: UTC time zone > February 1st, 2024 [0.01ms]
150
+ ✓ toDateId: UTC time zone > January 31th, 2024
151
+ ✓ toDateId: UTC time zone > February 1st, 2024
152
152
  ✓ toDateId: UTC time zone > February 10th, 2024
153
- ✓ toDateId: UTC time zone > convert between ID -> Date -> ID returns the original result [0.01ms]
153
+ ✓ toDateId: UTC time zone > convert between ID -> Date -> ID returns the original result
154
154
  ✓ toDateId: Brasilia time zone  > January 1st, 2024
155
- ✓ toDateId: Brasilia time zone  > January 31th, 2024
155
+ ✓ toDateId: Brasilia time zone  > January 31th, 2024 [0.01ms]
156
156
  ✓ toDateId: Brasilia time zone  > February 1st, 2024 [0.02ms]
157
157
  ✓ toDateId: Brasilia time zone  > February 10th, 2024
158
158
  ✓ toDateId: Brasilia time zone  > February 29th, 2024 [0.01ms]
159
159
  ✓ toDateId: Brasilia time zone  > convert between ID -> Date -> ID returns the original result [0.02ms]
160
- ✓ fromDateId: UTC time zone > parse Jan 1st [0.02ms]
161
- ✓ fromDateId: UTC time zone > parses March 1st [0.01ms]
162
- ✓ fromDateId: Brasilia time zone > parse Jan 1st
163
- ✓ fromDateId: Brasilia time zone > parses March 1st
164
- ✓ startOfMonth > January [0.01ms]
160
+ ✓ fromDateId: UTC time zone > parse Jan 1st [0.03ms]
161
+ ✓ fromDateId: UTC time zone > parses March 1st
162
+ ✓ fromDateId: Brasilia time zone > parse Jan 1st [0.01ms]
163
+ ✓ fromDateId: Brasilia time zone > parses March 1st [0.09ms]
164
+ ✓ startOfMonth > January
165
165
  ✓ startOfMonth > February
166
- ✓ startOfMonth > matches date-fns [1.44ms]
166
+ ✓ startOfMonth > matches date-fns [1.34ms]
167
167
  ✓ endOfMonth > January [0.03ms]
168
168
  ✓ endOfMonth > February [0.02ms]
169
- ✓ endOfMonth > matches date-fns [1.25ms]
170
- ✓ startOfWeek > sunday: week of February 17th [0.01ms]
171
- ✓ startOfWeek > sunday: week of February 11th [0.03ms]
172
- ✓ startOfWeek > monday: week of February 17th
169
+ ✓ endOfMonth > matches date-fns [1.48ms]
170
+ ✓ startOfWeek > sunday: week of February 17th [0.02ms]
171
+ ✓ startOfWeek > sunday: week of February 11th [0.02ms]
172
+ ✓ startOfWeek > monday: week of February 17th [0.01ms]
173
173
  ✓ startOfWeek > monday: week of February 11th
174
- ✓ startOfWeek > matches date-fns [1.19ms]
175
- ✓ addMonths > add 1 month [0.02ms]
174
+ ✓ startOfWeek > matches date-fns [1.16ms]
175
+ ✓ addMonths > add 1 month [0.03ms]
176
176
  ✓ addMonths > add 10 months
177
- ✓ addMonths > matches date-fns [0.19ms]
178
- ✓ subMonths > sub 1 month [0.02ms]
177
+ ✓ addMonths > matches date-fns [0.18ms]
178
+ ✓ subMonths > sub 1 month
179
179
  ✓ subMonths > sub 10 months
180
- ✓ subMonths > matches date-fns [0.13ms]
181
- ✓ addDays > add 1 day [0.02ms]
180
+ ✓ subMonths > matches date-fns [0.17ms]
181
+ ✓ addDays > add 1 day [0.09ms]
182
182
  ✓ addDays > add 10 days [0.01ms]
183
183
  ✓ addDays > matches date-fns [0.08ms]
184
- ✓ subDays > sub 1 day [0.03ms]
185
- ✓ subDays > sub 10 days [0.02ms]
186
- ✓ subDays > matches date-fns [0.08ms]
187
- ✓ isWeekend > Friday [0.03ms]
188
- ✓ isWeekend > Saturday
184
+ ✓ subDays > sub 1 day [0.04ms]
185
+ ✓ subDays > sub 10 days [0.01ms]
186
+ ✓ subDays > matches date-fns [0.13ms]
187
+ ✓ isWeekend > Friday [0.01ms]
188
+ ✓ isWeekend > Saturday [0.01ms]
189
189
  ✓ isWeekend > Sunday
190
190
  ✓ isWeekend > Monday
191
191
  ✓ differenceInMonths  > edge cases > it returns diff of 1 month between Feb 28 2021 and Jan 30 2021 [0.01ms]
192
- ✓ differenceInMonths  > edge cases > it returns diff of 1 month between Feb 28 2021 and Jan 31 2021
192
+ ✓ differenceInMonths  > edge cases > it returns diff of 1 month between Feb 28 2021 and Jan 31 2021 [0.01ms]
193
193
  ✓ differenceInMonths  > edge cases > it returns diff of 1 month between Nov, 30 2021 and Oct, 31 2021
194
194
  ✓ differenceInMonths  > edge cases > it returns diff of 1 month between Oct, 31 2021 and Sep, 30 2021
195
195
  ✓ differenceInMonths  > edge cases > it returns diff of 6 month between Oct, 31 2021 and Apr, 30 2021
196
196
  ✓ differenceInMonths  > edge cases > it returns diff of -1 month between Sep, 30 2021 and Oct, 31 2021
197
197
  ✓ differenceInMonths  > edge cases > the days of months of the given dates are the same
198
198
  ✓ differenceInMonths  > edge cases > the given dates are the same
199
- ✓ differenceInMonths  > edge cases > does not return -0 when the given dates are the same [0.01ms]
199
+ ✓ differenceInMonths  > edge cases > does not return -0 when the given dates are the same [0.02ms]
200
200
  ✓ differenceInMonths  > edge cases > returns the number of full months between the given dates - end of Feb [0.02ms]
201
- ✓ differenceInMonths  > returns the number of full months between the given dates
201
+ ✓ differenceInMonths  > returns the number of full months between the given dates [0.01ms]
202
202
  ✓ differenceInMonths  > returns a negative number if the time value of the first date is smaller
203
- ✓ differenceInMonths  > returns NaN if the first date is `Invalid Date` [0.21ms]
203
+ ✓ differenceInMonths  > returns NaN if the first date is `Invalid Date` [0.20ms]
204
204
  ✓ differenceInMonths  > returns NaN if the second date is `Invalid Date` [0.02ms]
205
205
  ✓ differenceInMonths  > returns NaN if the both dates are `Invalid Date`
206
- ✓ getWeeksInMonth > sunday: Month with 5 weeks [0.03ms]
207
- ✓ getWeeksInMonth > sunday: Month with 6 weeks [0.01ms]
208
- ✓ getWeeksInMonth > monday: Month with 5 weeks [0.03ms]
209
- ✓ getWeeksInMonth > matches date-fns [2.46ms]
210
- ✓ getWeekOfMonth > sunday: June [0.09ms]
206
+ ✓ getWeeksInMonth > sunday: Month with 5 weeks [0.02ms]
207
+ ✓ getWeeksInMonth > sunday: Month with 6 weeks [0.02ms]
208
+ ✓ getWeeksInMonth > monday: Month with 5 weeks [0.02ms]
209
+ ✓ getWeeksInMonth > matches date-fns [1.97ms]
210
+ ✓ getWeekOfMonth > sunday: June [0.07ms]
211
211
  ✓ getWeekOfMonth > monday: June [0.04ms]
212
- ✓ getWeekOfMonth > matches date-fns [0.38ms]
212
+ ✓ getWeekOfMonth > matches date-fns [0.68ms]
213
213
 
214
214
   116 pass
215
215
   0 fail
216
216
  8696 expect() calls
217
- Ran 116 tests across 5 files. [193.00ms]
217
+ Ran 116 tests across 5 files. [186.00ms]
package/dist/index.d.mts CHANGED
@@ -515,6 +515,19 @@ interface CalendarListProps extends Omit<CalendarProps, "calendarMonthId">, Omit
515
515
  * **Tip**: To convert to date ID, use `toDateId(date)`.
516
516
  */
517
517
  calendarInitialMonthId?: string;
518
+ /**
519
+ * When enabled, automatically scrolls to the month containing the start date
520
+ * of the first active range on mount. Only applies when
521
+ * `calendarActiveDateRanges` has at least one range with a `startId`.
522
+ *
523
+ * Takes precedence over `calendarInitialMonthId` when enabled and a valid
524
+ * range exists.
525
+ *
526
+ * Uses `initialScrollIndex` internally, so scrolling only happens on mount.
527
+ *
528
+ * @defaultValue true
529
+ */
530
+ calendarInitialScrollToActiveRange?: boolean;
518
531
  /**
519
532
  * Overwrites the default `Calendar` component.
520
533
  *
package/dist/index.d.ts CHANGED
@@ -515,6 +515,19 @@ interface CalendarListProps extends Omit<CalendarProps, "calendarMonthId">, Omit
515
515
  * **Tip**: To convert to date ID, use `toDateId(date)`.
516
516
  */
517
517
  calendarInitialMonthId?: string;
518
+ /**
519
+ * When enabled, automatically scrolls to the month containing the start date
520
+ * of the first active range on mount. Only applies when
521
+ * `calendarActiveDateRanges` has at least one range with a `startId`.
522
+ *
523
+ * Takes precedence over `calendarInitialMonthId` when enabled and a valid
524
+ * range exists.
525
+ *
526
+ * Uses `initialScrollIndex` internally, so scrolling only happens on mount.
527
+ *
528
+ * @defaultValue true
529
+ */
530
+ calendarInitialScrollToActiveRange?: boolean;
518
531
  /**
519
532
  * Overwrites the default `Calendar` component.
520
533
  *