@react-aria/calendar 3.5.7 → 3.5.9

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.
Files changed (60) hide show
  1. package/dist/ar-AE.mjs +1 -1
  2. package/dist/bg-BG.mjs +1 -1
  3. package/dist/cs-CZ.mjs +1 -1
  4. package/dist/da-DK.mjs +1 -1
  5. package/dist/de-DE.mjs +1 -1
  6. package/dist/el-GR.mjs +1 -1
  7. package/dist/en-US.mjs +1 -1
  8. package/dist/es-ES.mjs +1 -1
  9. package/dist/et-EE.mjs +1 -1
  10. package/dist/fi-FI.mjs +1 -1
  11. package/dist/fr-FR.mjs +1 -1
  12. package/dist/he-IL.mjs +1 -1
  13. package/dist/hr-HR.mjs +1 -1
  14. package/dist/hu-HU.mjs +1 -1
  15. package/dist/intlStrings.mjs +1 -1
  16. package/dist/it-IT.mjs +1 -1
  17. package/dist/ja-JP.mjs +1 -1
  18. package/dist/ko-KR.mjs +1 -1
  19. package/dist/lt-LT.mjs +1 -1
  20. package/dist/lv-LV.mjs +1 -1
  21. package/dist/nb-NO.mjs +1 -1
  22. package/dist/nl-NL.mjs +1 -1
  23. package/dist/pl-PL.mjs +1 -1
  24. package/dist/pt-BR.mjs +1 -1
  25. package/dist/pt-PT.mjs +1 -1
  26. package/dist/ro-RO.mjs +1 -1
  27. package/dist/ru-RU.mjs +1 -1
  28. package/dist/sk-SK.mjs +1 -1
  29. package/dist/sl-SI.mjs +1 -1
  30. package/dist/sr-SP.mjs +1 -1
  31. package/dist/sv-SE.mjs +1 -1
  32. package/dist/tr-TR.mjs +1 -1
  33. package/dist/types.d.ts +3 -4
  34. package/dist/types.d.ts.map +1 -1
  35. package/dist/uk-UA.mjs +1 -1
  36. package/dist/useCalendar.mjs +1 -1
  37. package/dist/useCalendarBase.main.js +13 -13
  38. package/dist/useCalendarBase.mjs +14 -14
  39. package/dist/useCalendarBase.module.js +13 -13
  40. package/dist/useCalendarCell.main.js +41 -41
  41. package/dist/useCalendarCell.main.js.map +1 -1
  42. package/dist/useCalendarCell.mjs +42 -42
  43. package/dist/useCalendarCell.module.js +41 -41
  44. package/dist/useCalendarCell.module.js.map +1 -1
  45. package/dist/useCalendarGrid.main.js +23 -23
  46. package/dist/useCalendarGrid.mjs +24 -24
  47. package/dist/useCalendarGrid.module.js +23 -23
  48. package/dist/useRangeCalendar.main.js +5 -5
  49. package/dist/useRangeCalendar.main.js.map +1 -1
  50. package/dist/useRangeCalendar.mjs +6 -6
  51. package/dist/useRangeCalendar.module.js +5 -5
  52. package/dist/useRangeCalendar.module.js.map +1 -1
  53. package/dist/utils.main.js +22 -22
  54. package/dist/utils.mjs +23 -23
  55. package/dist/utils.module.js +22 -22
  56. package/dist/zh-CN.mjs +1 -1
  57. package/dist/zh-TW.mjs +1 -1
  58. package/package.json +13 -13
  59. package/src/useCalendarCell.ts +3 -3
  60. package/src/useRangeCalendar.ts +3 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@react-aria/calendar",
3
- "version": "3.5.7",
3
+ "version": "3.5.9",
4
4
  "description": "Spectrum UI components in React",
5
5
  "license": "Apache-2.0",
6
6
  "main": "dist/main.js",
@@ -22,23 +22,23 @@
22
22
  "url": "https://github.com/adobe/react-spectrum"
23
23
  },
24
24
  "dependencies": {
25
- "@internationalized/date": "^3.5.3",
26
- "@react-aria/i18n": "^3.11.0",
27
- "@react-aria/interactions": "^3.21.2",
28
- "@react-aria/live-announcer": "^3.3.3",
29
- "@react-aria/utils": "^3.24.0",
30
- "@react-stately/calendar": "^3.5.0",
31
- "@react-types/button": "^3.9.3",
32
- "@react-types/calendar": "^3.4.5",
33
- "@react-types/shared": "^3.23.0",
25
+ "@internationalized/date": "^3.5.5",
26
+ "@react-aria/i18n": "^3.12.0",
27
+ "@react-aria/interactions": "^3.22.0",
28
+ "@react-aria/live-announcer": "^3.3.4",
29
+ "@react-aria/utils": "^3.25.0",
30
+ "@react-stately/calendar": "^3.5.2",
31
+ "@react-types/button": "^3.9.5",
32
+ "@react-types/calendar": "^3.4.7",
33
+ "@react-types/shared": "^3.24.0",
34
34
  "@swc/helpers": "^0.5.0"
35
35
  },
36
36
  "peerDependencies": {
37
- "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0",
38
- "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0"
37
+ "react": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0",
38
+ "react-dom": "^16.8.0 || ^17.0.0-rc.1 || ^18.0.0 || ^19.0.0"
39
39
  },
40
40
  "publishConfig": {
41
41
  "access": "public"
42
42
  },
43
- "gitHead": "f645f29edc1322153fd60af4640cbcab1d992dbd"
43
+ "gitHead": "86d80e3216bc32e75108831cf3a5a720bc849206"
44
44
  }
@@ -12,14 +12,14 @@
12
12
 
13
13
  import {CalendarDate, isEqualDay, isSameDay, isToday} from '@internationalized/date';
14
14
  import {CalendarState, RangeCalendarState} from '@react-stately/calendar';
15
- import {DOMAttributes} from '@react-types/shared';
15
+ import {DOMAttributes, RefObject} from '@react-types/shared';
16
16
  import {focusWithoutScrolling, getScrollParent, mergeProps, scrollIntoViewport, useDeepMemo, useDescription} from '@react-aria/utils';
17
17
  import {getEraFormat, hookData} from './utils';
18
18
  import {getInteractionModality, usePress} from '@react-aria/interactions';
19
19
  // @ts-ignore
20
20
  import intlMessages from '../intl/*.json';
21
- import {RefObject, useEffect, useMemo, useRef} from 'react';
22
21
  import {useDateFormatter, useLocalizedStringFormatter} from '@react-aria/i18n';
22
+ import {useEffect, useMemo, useRef} from 'react';
23
23
 
24
24
  export interface AriaCalendarCellProps {
25
25
  /** The date that this cell represents. */
@@ -72,7 +72,7 @@ export interface CalendarCellAria {
72
72
  * Provides the behavior and accessibility implementation for a calendar cell component.
73
73
  * A calendar cell displays a date cell within a calendar grid which can be selected by the user.
74
74
  */
75
- export function useCalendarCell(props: AriaCalendarCellProps, state: CalendarState | RangeCalendarState, ref: RefObject<HTMLElement>): CalendarCellAria {
75
+ export function useCalendarCell(props: AriaCalendarCellProps, state: CalendarState | RangeCalendarState, ref: RefObject<HTMLElement | null>): CalendarCellAria {
76
76
  let {date, isDisabled} = props;
77
77
  let {errorMessageId, selectedDateDescription} = hookData.get(state);
78
78
  let stringFormatter = useLocalizedStringFormatter(intlMessages, '@react-aria/calendar');
@@ -12,16 +12,16 @@
12
12
 
13
13
  import {AriaRangeCalendarProps, DateValue} from '@react-types/calendar';
14
14
  import {CalendarAria, useCalendarBase} from './useCalendarBase';
15
- import {FocusableElement} from '@react-types/shared';
15
+ import {FocusableElement, RefObject} from '@react-types/shared';
16
16
  import {RangeCalendarState} from '@react-stately/calendar';
17
- import {RefObject, useRef} from 'react';
18
17
  import {useEvent} from '@react-aria/utils';
18
+ import {useRef} from 'react';
19
19
 
20
20
  /**
21
21
  * Provides the behavior and accessibility implementation for a range calendar component.
22
22
  * A range calendar displays one or more date grids and allows users to select a contiguous range of dates.
23
23
  */
24
- export function useRangeCalendar<T extends DateValue>(props: AriaRangeCalendarProps<T>, state: RangeCalendarState, ref: RefObject<FocusableElement>): CalendarAria {
24
+ export function useRangeCalendar<T extends DateValue>(props: AriaRangeCalendarProps<T>, state: RangeCalendarState, ref: RefObject<FocusableElement | null>): CalendarAria {
25
25
  let res = useCalendarBase(props, state);
26
26
 
27
27
  // We need to ignore virtual pointer events from VoiceOver due to these bugs.