@ariakit/react 0.4.28 → 0.4.29

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 (91) hide show
  1. package/{CHANGELOG-035.md → CHANGELOG-0314.md} +205 -0
  2. package/CHANGELOG.md +48 -202
  3. package/cjs/__chunks/{SXAPGTJ4.cjs → 2ENQD3AS.cjs} +6 -6
  4. package/cjs/__chunks/{L2IFVMDU.cjs → 2WBRQ3I7.cjs} +7 -6
  5. package/cjs/__chunks/{N3DLR7OL.cjs → 3B6TF7HK.cjs} +6 -6
  6. package/cjs/__chunks/{XPQIHUQ7.cjs → 42GL4LKI.cjs} +20 -20
  7. package/cjs/__chunks/{VXUZM542.cjs → 53Q7HWXL.cjs} +165 -165
  8. package/cjs/__chunks/{3FIXGHZ2.cjs → 5QRVCRDI.cjs} +5 -5
  9. package/cjs/__chunks/{7MXJT4IN.cjs → 5XICU34X.cjs} +3 -3
  10. package/cjs/__chunks/{334WKW6I.cjs → 5ZX5ACFH.cjs} +4 -4
  11. package/cjs/__chunks/{2MDC3Z3V.cjs → 6BNWLCHF.cjs} +10 -10
  12. package/cjs/__chunks/{IFZV5LA3.cjs → 6XKLGFUO.cjs} +17 -17
  13. package/cjs/__chunks/{PZXRBFZF.cjs → 7SEEXNY6.cjs} +7 -7
  14. package/cjs/__chunks/{VXDLN5CP.cjs → 7XB4QE2H.cjs} +29 -29
  15. package/cjs/__chunks/{RVXPEX7O.cjs → AI3BA27G.cjs} +18 -18
  16. package/cjs/__chunks/{NG34QRI6.cjs → BTARPES4.cjs} +79 -32
  17. package/cjs/__chunks/{LCX235VJ.cjs → CKHOJYDQ.cjs} +6 -6
  18. package/cjs/__chunks/{C4NVIV6V.cjs → CRPG37KH.cjs} +104 -84
  19. package/cjs/__chunks/{4RKQMGBK.cjs → CYTUSXPR.cjs} +236 -222
  20. package/cjs/__chunks/{IHVFJGGN.cjs → D6USTXKA.cjs} +4 -4
  21. package/cjs/__chunks/{NFZWL7LE.cjs → DDV252ZY.cjs} +4 -4
  22. package/cjs/__chunks/DVB2WSHD.cjs +41 -0
  23. package/cjs/__chunks/{YEXJT4IL.cjs → EF57ZMJN.cjs} +10 -10
  24. package/cjs/__chunks/{RR46KI45.cjs → EQYJ6RA7.cjs} +3 -3
  25. package/cjs/__chunks/{D4HCGWOU.cjs → FHPV2Q7C.cjs} +182 -78
  26. package/cjs/__chunks/{FHQ5DVYQ.cjs → FNYFMCD7.cjs} +4 -4
  27. package/cjs/__chunks/{FELYQPO5.cjs → FWVWDDOL.cjs} +182 -173
  28. package/cjs/__chunks/{GUY4MKX2.cjs → G2JI2Z7U.cjs} +12 -12
  29. package/cjs/__chunks/{Z5PDS46M.cjs → GI27TVAM.cjs} +159 -159
  30. package/cjs/__chunks/{PTE2IJM5.cjs → GQZ5DRPC.cjs} +32 -30
  31. package/cjs/__chunks/{XH4GE3VE.cjs → GV4SR2CM.cjs} +7 -7
  32. package/cjs/__chunks/{PU63IQFD.cjs → HCYQ5Z7Z.cjs} +58 -58
  33. package/cjs/__chunks/{ASOIXRUN.cjs → HGV6FCZP.cjs} +61 -61
  34. package/cjs/__chunks/{OOFUBC32.cjs → I4JS2KAF.cjs} +17 -19
  35. package/cjs/__chunks/{DVWS2XPY.cjs → I6N3772N.cjs} +21 -21
  36. package/cjs/__chunks/{7POA4244.cjs → IEVLYJJP.cjs} +22 -22
  37. package/cjs/__chunks/{ZNW2LLWJ.cjs → IGWSYIUY.cjs} +15 -15
  38. package/cjs/__chunks/{QAUJZR6Y.cjs → JBOLBTVU.cjs} +15 -4
  39. package/cjs/__chunks/{MN5TONXW.cjs → JXYV7OWF.cjs} +33 -36
  40. package/cjs/__chunks/{FIPBE5IX.cjs → KDVG735H.cjs} +3 -3
  41. package/cjs/__chunks/{TSBEWPNT.cjs → KFUU3G3B.cjs} +39 -39
  42. package/cjs/__chunks/{ZYPARRXG.cjs → LGUAIO4Q.cjs} +4 -4
  43. package/cjs/__chunks/{5NTEPQ2U.cjs → M6YHODMV.cjs} +20 -20
  44. package/cjs/__chunks/{SIF7IN4L.cjs → MWZS5XD4.cjs} +12 -12
  45. package/cjs/__chunks/{UUEFM3TG.cjs → NBAYASRC.cjs} +17 -17
  46. package/cjs/__chunks/{RXZPZPJX.cjs → OFFSDIY3.cjs} +21 -21
  47. package/cjs/__chunks/{RGH2H3WL.cjs → OP2QHIHD.cjs} +4 -4
  48. package/cjs/__chunks/{2HXQHKBC.cjs → P6Y2DILA.cjs} +17 -17
  49. package/cjs/__chunks/{LMCBLO3G.cjs → P7AY4KL3.cjs} +10 -10
  50. package/cjs/__chunks/{PDPE2VAZ.cjs → QJQWEU4Q.cjs} +134 -120
  51. package/cjs/__chunks/{UV7CXZEM.cjs → RZJLQJQM.cjs} +9 -9
  52. package/cjs/__chunks/{34UJGLOZ.cjs → SAFZBKT3.cjs} +61 -48
  53. package/cjs/__chunks/{LVHC4DSB.cjs → TMY4OIYC.cjs} +19 -19
  54. package/cjs/__chunks/{LS5VO6AA.cjs → ULDO57DJ.cjs} +12 -12
  55. package/cjs/__chunks/{NMUCJYMR.cjs → US2XYAXE.cjs} +83 -83
  56. package/cjs/__chunks/{GUB6WHB6.cjs → VUISVT3V.cjs} +9 -9
  57. package/cjs/__chunks/{RLKC7JVT.cjs → WHUT2PFL.cjs} +4 -4
  58. package/cjs/__chunks/WLHP5OM6.cjs +37 -0
  59. package/cjs/__chunks/{7M4GY5DS.cjs → WYI5CKPV.cjs} +38 -38
  60. package/cjs/__chunks/{SQ72MZ63.cjs → ZPWE3FTF.cjs} +39 -39
  61. package/cjs/button.cjs +5 -5
  62. package/cjs/checkbox.cjs +8 -8
  63. package/cjs/collection.cjs +6 -6
  64. package/cjs/combobox.cjs +30 -30
  65. package/cjs/command.cjs +4 -4
  66. package/cjs/composite.cjs +17 -17
  67. package/cjs/dialog.cjs +18 -18
  68. package/cjs/disclosure.cjs +9 -9
  69. package/cjs/focus-trap.cjs +5 -5
  70. package/cjs/focusable.cjs +3 -3
  71. package/cjs/form.cjs +14 -14
  72. package/cjs/group.cjs +3 -3
  73. package/cjs/heading.cjs +3 -3
  74. package/cjs/hovercard.cjs +25 -25
  75. package/cjs/index.cjs +59 -59
  76. package/cjs/menu.cjs +42 -42
  77. package/cjs/menubar.cjs +8 -8
  78. package/cjs/popover.cjs +25 -25
  79. package/cjs/portal.cjs +5 -5
  80. package/cjs/radio.cjs +12 -12
  81. package/cjs/role.cjs +3 -3
  82. package/cjs/select.cjs +36 -36
  83. package/cjs/separator.cjs +3 -3
  84. package/cjs/store.cjs +3 -3
  85. package/cjs/tab.cjs +15 -15
  86. package/cjs/toolbar.cjs +13 -13
  87. package/cjs/tooltip.cjs +15 -15
  88. package/cjs/visually-hidden.cjs +3 -3
  89. package/package.json +4 -4
  90. package/cjs/__chunks/FVIS5BFZ.cjs +0 -41
  91. package/cjs/__chunks/TLUFYZC7.cjs +0 -37
@@ -6,11 +6,11 @@
6
6
 
7
7
 
8
8
 
9
- var _L2IFVMDUcjs = require('./L2IFVMDU.cjs');
9
+ var _2WBRQ3I7cjs = require('./2WBRQ3I7.cjs');
10
10
 
11
11
 
12
12
 
13
- var _XPQIHUQ7cjs = require('./XPQIHUQ7.cjs');
13
+ var _42GL4LKIcjs = require('./42GL4LKI.cjs');
14
14
 
15
15
 
16
16
 
@@ -18,10 +18,10 @@ var _XPQIHUQ7cjs = require('./XPQIHUQ7.cjs');
18
18
 
19
19
 
20
20
 
21
- var _D4HCGWOUcjs = require('./D4HCGWOU.cjs');
21
+ var _FHPV2Q7Ccjs = require('./FHPV2Q7C.cjs');
22
22
 
23
23
 
24
- var _NG34QRI6cjs = require('./NG34QRI6.cjs');
24
+ var _BTARPES4cjs = require('./BTARPES4.cjs');
25
25
 
26
26
 
27
27
 
@@ -44,7 +44,7 @@ var _NG34QRI6cjs = require('./NG34QRI6.cjs');
44
44
 
45
45
 
46
46
 
47
- var _QAUJZR6Ycjs = require('./QAUJZR6Y.cjs');
47
+ var _JBOLBTVUcjs = require('./JBOLBTVU.cjs');
48
48
 
49
49
  // ../ariakit-react-components/dist/composite/composite.js
50
50
  var _react = require('react');
@@ -55,35 +55,35 @@ function isGrid(items) {
55
55
  }
56
56
  function isPrintableKey(event) {
57
57
  const target = event.target;
58
- if (target && !_QAUJZR6Ycjs.isTextField.call(void 0, target)) return false;
58
+ if (target && !_JBOLBTVUcjs.isTextField.call(void 0, target)) return false;
59
59
  return event.key.length === 1 && !event.ctrlKey && !event.metaKey;
60
60
  }
61
61
  function isModifierKey(event) {
62
62
  return event.key === "Shift" || event.key === "Control" || event.key === "Alt" || event.key === "Meta";
63
63
  }
64
64
  function useKeyboardEventProxy(store, onKeyboardEvent, previousElementRef) {
65
- return _QAUJZR6Ycjs.useEvent.call(void 0, (event) => {
65
+ return _JBOLBTVUcjs.useEvent.call(void 0, (event) => {
66
66
  var _a;
67
67
  onKeyboardEvent == null ? void 0 : onKeyboardEvent(event);
68
68
  if (event.defaultPrevented) return;
69
69
  if (event.isPropagationStopped()) return;
70
- if (!_QAUJZR6Ycjs.isSelfTarget.call(void 0, event)) return;
70
+ if (!_JBOLBTVUcjs.isSelfTarget.call(void 0, event)) return;
71
71
  if (isModifierKey(event)) return;
72
72
  if (isPrintableKey(event)) return;
73
- const activeElement = (_a = _L2IFVMDUcjs.getEnabledItem.call(void 0, store, store.getState().activeId)) == null ? void 0 : _a.element;
73
+ const activeElement = (_a = _2WBRQ3I7cjs.getEnabledItem.call(void 0, store, store.getState().activeId)) == null ? void 0 : _a.element;
74
74
  if (!activeElement) return;
75
75
  const { view, ...eventInit } = event;
76
76
  if (activeElement !== (previousElementRef == null ? void 0 : previousElementRef.current)) activeElement.focus();
77
- if (!_QAUJZR6Ycjs.fireKeyboardEvent.call(void 0, activeElement, event.type, eventInit)) event.preventDefault();
77
+ if (!_JBOLBTVUcjs.fireKeyboardEvent.call(void 0, activeElement, event.type, eventInit)) event.preventDefault();
78
78
  if (event.currentTarget.contains(activeElement)) event.stopPropagation();
79
79
  });
80
80
  }
81
81
  function findFirstEnabledItemInTheLastRow(items) {
82
- return _L2IFVMDUcjs.findFirstEnabledItem.call(void 0, _QAUJZR6Ycjs.flatten2DArray.call(void 0, _QAUJZR6Ycjs.reverseArray.call(void 0, _L2IFVMDUcjs.groupItemsByRows.call(void 0, items))));
82
+ return _2WBRQ3I7cjs.findFirstEnabledItem.call(void 0, _JBOLBTVUcjs.flatten2DArray.call(void 0, _JBOLBTVUcjs.reverseArray.call(void 0, _2WBRQ3I7cjs.groupItemsByRows.call(void 0, items))));
83
83
  }
84
84
  function withBaseScrollPreserved(store, callback) {
85
85
  const { virtualFocus, baseElement } = store.getState();
86
- if (!virtualFocus || !baseElement || !_QAUJZR6Ycjs.isTextField.call(void 0, baseElement)) {
86
+ if (!virtualFocus || !baseElement || !_JBOLBTVUcjs.isTextField.call(void 0, baseElement)) {
87
87
  callback();
88
88
  return;
89
89
  }
@@ -96,7 +96,7 @@ function withBaseScrollPreserved(store, callback) {
96
96
  function useScheduleFocus(store) {
97
97
  const [scheduled, setScheduled] = _react.useState.call(void 0, false);
98
98
  const schedule = _react.useCallback.call(void 0, () => setScheduled(true), []);
99
- const activeItem = _D4HCGWOUcjs.useStoreState.call(void 0, store, (state) => _L2IFVMDUcjs.getEnabledItem.call(void 0, store, state.activeId));
99
+ const activeItem = _FHPV2Q7Ccjs.useStoreState.call(void 0, store, (state) => _2WBRQ3I7cjs.getEnabledItem.call(void 0, store, state.activeId));
100
100
  _react.useEffect.call(void 0, () => {
101
101
  const activeElement = activeItem == null ? void 0 : activeItem.element;
102
102
  if (!scheduled) return;
@@ -112,15 +112,15 @@ function useScheduleFocus(store) {
112
112
  ]);
113
113
  return schedule;
114
114
  }
115
- var useComposite = _QAUJZR6Ycjs.createHook.call(void 0, function useComposite2({ store, composite = true, focusOnMove = composite, moveOnKeyPress = true, ...props }) {
116
- const context = _L2IFVMDUcjs.useCompositeProviderContext.call(void 0, );
115
+ var useComposite = _JBOLBTVUcjs.createHook.call(void 0, function useComposite2({ store, composite = true, focusOnMove = composite, moveOnKeyPress = true, ...props }) {
116
+ const context = _2WBRQ3I7cjs.useCompositeProviderContext.call(void 0, );
117
117
  store = store || context;
118
- _QAUJZR6Ycjs.invariant.call(void 0, store, "Composite must receive a `store` prop or be wrapped in a CompositeProvider component.");
118
+ _JBOLBTVUcjs.invariant.call(void 0, store, process.env.NODE_ENV !== "production" && "Composite must receive a `store` prop or be wrapped in a CompositeProvider component.");
119
119
  const ref = _react.useRef.call(void 0, null);
120
120
  const previousElementRef = _react.useRef.call(void 0, null);
121
121
  const scheduleFocus = useScheduleFocus(store);
122
- const moves = _D4HCGWOUcjs.useStoreState.call(void 0, store, "moves");
123
- const [, setBaseElement] = _QAUJZR6Ycjs.useTransactionState.call(void 0, composite ? store.setBaseElement : null);
122
+ const moves = _FHPV2Q7Ccjs.useStoreState.call(void 0, store, "moves");
123
+ const [, setBaseElement] = _JBOLBTVUcjs.useTransactionState.call(void 0, composite ? store.setBaseElement : null);
124
124
  _react.useEffect.call(void 0, () => {
125
125
  var _a;
126
126
  if (!store) return;
@@ -128,16 +128,16 @@ var useComposite = _QAUJZR6Ycjs.createHook.call(void 0, function useComposite2({
128
128
  if (!composite) return;
129
129
  if (!focusOnMove) return;
130
130
  const { activeId: activeId2 } = store.getState();
131
- const itemElement = (_a = _L2IFVMDUcjs.getEnabledItem.call(void 0, store, activeId2)) == null ? void 0 : _a.element;
131
+ const itemElement = (_a = _2WBRQ3I7cjs.getEnabledItem.call(void 0, store, activeId2)) == null ? void 0 : _a.element;
132
132
  if (!itemElement) return;
133
- withBaseScrollPreserved(store, () => _QAUJZR6Ycjs.focusIntoView.call(void 0, itemElement));
133
+ withBaseScrollPreserved(store, () => _JBOLBTVUcjs.focusIntoView.call(void 0, itemElement));
134
134
  }, [
135
135
  store,
136
136
  moves,
137
137
  composite,
138
138
  focusOnMove
139
139
  ]);
140
- _QAUJZR6Ycjs.useSafeLayoutEffect.call(void 0, () => {
140
+ _JBOLBTVUcjs.useSafeLayoutEffect.call(void 0, () => {
141
141
  if (!store) return;
142
142
  if (!moves) return;
143
143
  if (!composite) return;
@@ -146,16 +146,16 @@ var useComposite = _QAUJZR6Ycjs.createHook.call(void 0, function useComposite2({
146
146
  if (!baseElement) return;
147
147
  const previousElement = previousElementRef.current;
148
148
  previousElementRef.current = null;
149
- if (previousElement) _QAUJZR6Ycjs.fireBlurEvent.call(void 0, previousElement, { relatedTarget: baseElement });
150
- if (!_QAUJZR6Ycjs.hasFocus.call(void 0, baseElement)) baseElement.focus();
149
+ if (previousElement) _JBOLBTVUcjs.fireBlurEvent.call(void 0, previousElement, { relatedTarget: baseElement });
150
+ if (!_JBOLBTVUcjs.hasFocus.call(void 0, baseElement)) baseElement.focus();
151
151
  }, [
152
152
  store,
153
153
  moves,
154
154
  composite
155
155
  ]);
156
- const activeId = _D4HCGWOUcjs.useStoreState.call(void 0, store, "activeId");
157
- const virtualFocus = _D4HCGWOUcjs.useStoreState.call(void 0, store, "virtualFocus");
158
- _QAUJZR6Ycjs.useSafeLayoutEffect.call(void 0, () => {
156
+ const activeId = _FHPV2Q7Ccjs.useStoreState.call(void 0, store, "activeId");
157
+ const virtualFocus = _FHPV2Q7Ccjs.useStoreState.call(void 0, store, "virtualFocus");
158
+ _JBOLBTVUcjs.useSafeLayoutEffect.call(void 0, () => {
159
159
  var _a;
160
160
  if (!store) return;
161
161
  if (!composite) return;
@@ -163,9 +163,9 @@ var useComposite = _QAUJZR6Ycjs.createHook.call(void 0, function useComposite2({
163
163
  const previousElement = previousElementRef.current;
164
164
  previousElementRef.current = null;
165
165
  if (!previousElement) return;
166
- const relatedTarget = ((_a = _L2IFVMDUcjs.getEnabledItem.call(void 0, store, activeId)) == null ? void 0 : _a.element) || _QAUJZR6Ycjs.getActiveElement.call(void 0, previousElement);
166
+ const relatedTarget = ((_a = _2WBRQ3I7cjs.getEnabledItem.call(void 0, store, activeId)) == null ? void 0 : _a.element) || _JBOLBTVUcjs.getActiveElement.call(void 0, previousElement);
167
167
  if (relatedTarget === previousElement) return;
168
- _QAUJZR6Ycjs.fireBlurEvent.call(void 0, previousElement, { relatedTarget });
168
+ _JBOLBTVUcjs.fireBlurEvent.call(void 0, previousElement, { relatedTarget });
169
169
  }, [
170
170
  store,
171
171
  activeId,
@@ -175,21 +175,21 @@ var useComposite = _QAUJZR6Ycjs.createHook.call(void 0, function useComposite2({
175
175
  const onKeyDownCapture = useKeyboardEventProxy(store, props.onKeyDownCapture, previousElementRef);
176
176
  const onKeyUpCapture = useKeyboardEventProxy(store, props.onKeyUpCapture, previousElementRef);
177
177
  const onFocusCaptureProp = props.onFocusCapture;
178
- const onFocusCapture = _QAUJZR6Ycjs.useEvent.call(void 0, (event) => {
178
+ const onFocusCapture = _JBOLBTVUcjs.useEvent.call(void 0, (event) => {
179
179
  onFocusCaptureProp == null ? void 0 : onFocusCaptureProp(event);
180
180
  if (event.defaultPrevented) return;
181
181
  if (!store) return;
182
182
  const { virtualFocus: virtualFocus2 } = store.getState();
183
183
  if (!virtualFocus2) return;
184
184
  const previousActiveElement = event.relatedTarget;
185
- const isSilentlyFocused = _L2IFVMDUcjs.silentlyFocused.call(void 0, event.currentTarget);
186
- if (_QAUJZR6Ycjs.isSelfTarget.call(void 0, event) && isSilentlyFocused) {
185
+ const isSilentlyFocused = _2WBRQ3I7cjs.silentlyFocused.call(void 0, event.currentTarget);
186
+ if (_JBOLBTVUcjs.isSelfTarget.call(void 0, event) && isSilentlyFocused) {
187
187
  event.stopPropagation();
188
188
  previousElementRef.current = previousActiveElement;
189
189
  }
190
190
  });
191
191
  const onFocusProp = props.onFocus;
192
- const onFocus = _QAUJZR6Ycjs.useEvent.call(void 0, (event) => {
192
+ const onFocus = _JBOLBTVUcjs.useEvent.call(void 0, (event) => {
193
193
  onFocusProp == null ? void 0 : onFocusProp(event);
194
194
  if (event.defaultPrevented) return;
195
195
  if (!composite) return;
@@ -197,45 +197,45 @@ var useComposite = _QAUJZR6Ycjs.createHook.call(void 0, function useComposite2({
197
197
  const { relatedTarget } = event;
198
198
  const { virtualFocus: virtualFocus2 } = store.getState();
199
199
  if (virtualFocus2) {
200
- if (_QAUJZR6Ycjs.isSelfTarget.call(void 0, event) && !_L2IFVMDUcjs.isItem.call(void 0, store, relatedTarget)) queueMicrotask(scheduleFocus);
201
- } else if (_QAUJZR6Ycjs.isSelfTarget.call(void 0, event)) store.setActiveId(null);
200
+ if (_JBOLBTVUcjs.isSelfTarget.call(void 0, event) && !_2WBRQ3I7cjs.isItem.call(void 0, store, relatedTarget)) queueMicrotask(scheduleFocus);
201
+ } else if (_JBOLBTVUcjs.isSelfTarget.call(void 0, event)) store.setActiveId(null);
202
202
  });
203
203
  const onBlurCaptureProp = props.onBlurCapture;
204
- const onBlurCapture = _QAUJZR6Ycjs.useEvent.call(void 0, (event) => {
204
+ const onBlurCapture = _JBOLBTVUcjs.useEvent.call(void 0, (event) => {
205
205
  var _a;
206
206
  onBlurCaptureProp == null ? void 0 : onBlurCaptureProp(event);
207
207
  if (event.defaultPrevented) return;
208
208
  if (!store) return;
209
209
  const { virtualFocus: virtualFocus2, activeId: activeId2 } = store.getState();
210
210
  if (!virtualFocus2) return;
211
- const activeElement = (_a = _L2IFVMDUcjs.getEnabledItem.call(void 0, store, activeId2)) == null ? void 0 : _a.element;
211
+ const activeElement = (_a = _2WBRQ3I7cjs.getEnabledItem.call(void 0, store, activeId2)) == null ? void 0 : _a.element;
212
212
  const nextActiveElement = event.relatedTarget;
213
- const nextActiveElementIsItem = _L2IFVMDUcjs.isItem.call(void 0, store, nextActiveElement);
213
+ const nextActiveElementIsItem = _2WBRQ3I7cjs.isItem.call(void 0, store, nextActiveElement);
214
214
  const previousElement = previousElementRef.current;
215
215
  previousElementRef.current = null;
216
- if (_QAUJZR6Ycjs.isSelfTarget.call(void 0, event) && nextActiveElementIsItem) {
216
+ if (_JBOLBTVUcjs.isSelfTarget.call(void 0, event) && nextActiveElementIsItem) {
217
217
  if (nextActiveElement === activeElement) {
218
- if (previousElement && previousElement !== nextActiveElement) _QAUJZR6Ycjs.fireBlurEvent.call(void 0, previousElement, event);
219
- } else if (activeElement) _QAUJZR6Ycjs.fireBlurEvent.call(void 0, activeElement, event);
220
- else if (previousElement) _QAUJZR6Ycjs.fireBlurEvent.call(void 0, previousElement, event);
218
+ if (previousElement && previousElement !== nextActiveElement) _JBOLBTVUcjs.fireBlurEvent.call(void 0, previousElement, event);
219
+ } else if (activeElement) _JBOLBTVUcjs.fireBlurEvent.call(void 0, activeElement, event);
220
+ else if (previousElement) _JBOLBTVUcjs.fireBlurEvent.call(void 0, previousElement, event);
221
221
  event.stopPropagation();
222
- } else if (!_L2IFVMDUcjs.isItem.call(void 0, store, event.target) && activeElement) _QAUJZR6Ycjs.fireBlurEvent.call(void 0, activeElement, event);
222
+ } else if (!_2WBRQ3I7cjs.isItem.call(void 0, store, event.target) && activeElement) _JBOLBTVUcjs.fireBlurEvent.call(void 0, activeElement, event);
223
223
  });
224
224
  const onKeyDownProp = props.onKeyDown;
225
- const moveOnKeyPressProp = _QAUJZR6Ycjs.useBooleanEvent.call(void 0, moveOnKeyPress);
226
- const onKeyDown = _QAUJZR6Ycjs.useEvent.call(void 0, (event) => {
225
+ const moveOnKeyPressProp = _JBOLBTVUcjs.useBooleanEvent.call(void 0, moveOnKeyPress);
226
+ const onKeyDown = _JBOLBTVUcjs.useEvent.call(void 0, (event) => {
227
227
  var _a, _b;
228
228
  onKeyDownProp == null ? void 0 : onKeyDownProp(event);
229
229
  if (event.nativeEvent.isComposing) return;
230
230
  if (event.defaultPrevented) return;
231
231
  if (!store) return;
232
- if (!_QAUJZR6Ycjs.isSelfTarget.call(void 0, event)) return;
232
+ if (!_JBOLBTVUcjs.isSelfTarget.call(void 0, event)) return;
233
233
  const { orientation, renderedItems, activeId: activeId2 } = store.getState();
234
- if ((_b = (_a = _L2IFVMDUcjs.getEnabledItem.call(void 0, store, activeId2)) == null ? void 0 : _a.element) == null ? void 0 : _b.isConnected) return;
234
+ if ((_b = (_a = _2WBRQ3I7cjs.getEnabledItem.call(void 0, store, activeId2)) == null ? void 0 : _a.element) == null ? void 0 : _b.isConnected) return;
235
235
  const isVertical = orientation !== "horizontal";
236
236
  const isHorizontal = orientation !== "vertical";
237
237
  const grid = isGrid(renderedItems);
238
- if ((event.key === "ArrowLeft" || event.key === "ArrowRight" || event.key === "Home" || event.key === "End") && _QAUJZR6Ycjs.isTextField.call(void 0, event.currentTarget)) return;
238
+ if ((event.key === "ArrowLeft" || event.key === "ArrowRight" || event.key === "Home" || event.key === "End") && _JBOLBTVUcjs.isTextField.call(void 0, event.currentTarget)) return;
239
239
  const up = () => {
240
240
  var _a2;
241
241
  if (grid) return (_a2 = findFirstEnabledItemInTheLastRow(renderedItems)) == null ? void 0 : _a2.id;
@@ -260,20 +260,20 @@ var useComposite = _QAUJZR6Ycjs.createHook.call(void 0, function useComposite2({
260
260
  }
261
261
  }
262
262
  });
263
- props = _QAUJZR6Ycjs.useWrapElement.call(void 0, props, (element) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _L2IFVMDUcjs.CompositeContextProvider, {
263
+ props = _JBOLBTVUcjs.useWrapElement.call(void 0, props, (element) => /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _2WBRQ3I7cjs.CompositeScopedContextProvider, {
264
264
  value: store,
265
265
  children: element
266
266
  }), [store]);
267
267
  props = {
268
- "aria-activedescendant": _D4HCGWOUcjs.useStoreState.call(void 0, store, (state) => {
268
+ "aria-activedescendant": _FHPV2Q7Ccjs.useStoreState.call(void 0, store, (state) => {
269
269
  var _a;
270
270
  if (!store) return;
271
271
  if (!composite) return;
272
272
  if (!state.virtualFocus) return;
273
- return (_a = _L2IFVMDUcjs.getEnabledItem.call(void 0, store, state.activeId)) == null ? void 0 : _a.id;
273
+ return (_a = _2WBRQ3I7cjs.getEnabledItem.call(void 0, store, state.activeId)) == null ? void 0 : _a.id;
274
274
  }),
275
275
  ...props,
276
- ref: _QAUJZR6Ycjs.useMergeRefs.call(void 0, ref, setBaseElement, props.ref),
276
+ ref: _JBOLBTVUcjs.useMergeRefs.call(void 0, ref, setBaseElement, props.ref),
277
277
  onKeyDownCapture,
278
278
  onKeyUpCapture,
279
279
  onFocusCapture,
@@ -281,14 +281,14 @@ var useComposite = _QAUJZR6Ycjs.createHook.call(void 0, function useComposite2({
281
281
  onBlurCapture,
282
282
  onKeyDown
283
283
  };
284
- props = _NG34QRI6cjs.useFocusable.call(void 0, {
285
- focusable: _D4HCGWOUcjs.useStoreState.call(void 0, store, (state) => composite && (state.virtualFocus || state.activeId === null)),
284
+ props = _BTARPES4cjs.useFocusable.call(void 0, {
285
+ focusable: _FHPV2Q7Ccjs.useStoreState.call(void 0, store, (state) => composite && (state.virtualFocus || state.activeId === null)),
286
286
  ...props
287
287
  });
288
288
  return props;
289
289
  });
290
- var Composite = _QAUJZR6Ycjs.forwardRef.call(void 0, function Composite2(props) {
291
- return _QAUJZR6Ycjs.createElement.call(void 0, TagName, useComposite(props));
290
+ var Composite = _JBOLBTVUcjs.forwardRef.call(void 0, function Composite2(props) {
291
+ return _JBOLBTVUcjs.createElement.call(void 0, TagName, useComposite(props));
292
292
  });
293
293
 
294
294
  // ../ariakit-components/dist/composite/composite-store.js
@@ -367,23 +367,23 @@ function verticalizeItems(items) {
367
367
  function createCompositeStore(props = {}) {
368
368
  var _a, _b;
369
369
  const syncState = (_a = props.store) == null ? void 0 : _a.getState();
370
- const collection = _XPQIHUQ7cjs.createCollectionStore.call(void 0, props);
371
- const activeId = _QAUJZR6Ycjs.defaultValue.call(void 0, props.activeId, syncState == null ? void 0 : syncState.activeId, props.defaultActiveId);
372
- const composite = _D4HCGWOUcjs.createStore.call(void 0, {
370
+ const collection = _42GL4LKIcjs.createCollectionStore.call(void 0, props);
371
+ const activeId = _JBOLBTVUcjs.defaultValue.call(void 0, props.activeId, syncState == null ? void 0 : syncState.activeId, props.defaultActiveId);
372
+ const composite = _FHPV2Q7Ccjs.createStore.call(void 0, {
373
373
  ...collection.getState(),
374
- id: (_b = _QAUJZR6Ycjs.defaultValue.call(void 0, props.id, syncState == null ? void 0 : syncState.id)) != null ? _b : `id-${Math.random().toString(36).slice(2, 8)}`,
374
+ id: (_b = _JBOLBTVUcjs.defaultValue.call(void 0, props.id, syncState == null ? void 0 : syncState.id)) != null ? _b : `id-${Math.random().toString(36).slice(2, 8)}`,
375
375
  activeId,
376
- baseElement: _QAUJZR6Ycjs.defaultValue.call(void 0, syncState == null ? void 0 : syncState.baseElement, null),
377
- includesBaseElement: _QAUJZR6Ycjs.defaultValue.call(void 0, props.includesBaseElement, syncState == null ? void 0 : syncState.includesBaseElement, activeId === null),
378
- moves: _QAUJZR6Ycjs.defaultValue.call(void 0, syncState == null ? void 0 : syncState.moves, 0),
379
- orientation: _QAUJZR6Ycjs.defaultValue.call(void 0, props.orientation, syncState == null ? void 0 : syncState.orientation, "both"),
380
- rtl: _QAUJZR6Ycjs.defaultValue.call(void 0, props.rtl, syncState == null ? void 0 : syncState.rtl, false),
381
- virtualFocus: _QAUJZR6Ycjs.defaultValue.call(void 0, props.virtualFocus, syncState == null ? void 0 : syncState.virtualFocus, false),
382
- focusLoop: _QAUJZR6Ycjs.defaultValue.call(void 0, props.focusLoop, syncState == null ? void 0 : syncState.focusLoop, false),
383
- focusWrap: _QAUJZR6Ycjs.defaultValue.call(void 0, props.focusWrap, syncState == null ? void 0 : syncState.focusWrap, false),
384
- focusShift: _QAUJZR6Ycjs.defaultValue.call(void 0, props.focusShift, syncState == null ? void 0 : syncState.focusShift, false)
376
+ baseElement: _JBOLBTVUcjs.defaultValue.call(void 0, syncState == null ? void 0 : syncState.baseElement, null),
377
+ includesBaseElement: _JBOLBTVUcjs.defaultValue.call(void 0, props.includesBaseElement, syncState == null ? void 0 : syncState.includesBaseElement, activeId === null),
378
+ moves: _JBOLBTVUcjs.defaultValue.call(void 0, syncState == null ? void 0 : syncState.moves, 0),
379
+ orientation: _JBOLBTVUcjs.defaultValue.call(void 0, props.orientation, syncState == null ? void 0 : syncState.orientation, "both"),
380
+ rtl: _JBOLBTVUcjs.defaultValue.call(void 0, props.rtl, syncState == null ? void 0 : syncState.rtl, false),
381
+ virtualFocus: _JBOLBTVUcjs.defaultValue.call(void 0, props.virtualFocus, syncState == null ? void 0 : syncState.virtualFocus, false),
382
+ focusLoop: _JBOLBTVUcjs.defaultValue.call(void 0, props.focusLoop, syncState == null ? void 0 : syncState.focusLoop, false),
383
+ focusWrap: _JBOLBTVUcjs.defaultValue.call(void 0, props.focusWrap, syncState == null ? void 0 : syncState.focusWrap, false),
384
+ focusShift: _JBOLBTVUcjs.defaultValue.call(void 0, props.focusShift, syncState == null ? void 0 : syncState.focusShift, false)
385
385
  }, collection, props.store);
386
- _D4HCGWOUcjs.setup.call(void 0, composite, () => _D4HCGWOUcjs.sync.call(void 0, composite, ["renderedItems", "activeId"], (state) => {
386
+ _FHPV2Q7Ccjs.setup.call(void 0, composite, () => _FHPV2Q7Ccjs.sync.call(void 0, composite, ["renderedItems", "activeId"], (state) => {
387
387
  composite.setState("activeId", (activeId2) => {
388
388
  var _a2;
389
389
  if (activeId2 !== void 0) return activeId2;
@@ -398,8 +398,8 @@ function createCompositeStore(props = {}) {
398
398
  const isNextDirection = direction === "next" || direction === "down";
399
399
  const canReverse = isNextDirection ? rtl && !isVerticalDirection : !rtl || isVerticalDirection;
400
400
  const canShift = focusShift && !skip;
401
- let items = !isVerticalDirection ? renderedItems : _QAUJZR6Ycjs.flatten2DArray.call(void 0, normalizeRows(groupItemsByRows2(renderedItems), activeId2, canShift));
402
- items = canReverse ? _QAUJZR6Ycjs.reverseArray.call(void 0, items) : items;
401
+ let items = !isVerticalDirection ? renderedItems : _JBOLBTVUcjs.flatten2DArray.call(void 0, normalizeRows(groupItemsByRows2(renderedItems), activeId2, canShift));
402
+ items = canReverse ? _JBOLBTVUcjs.reverseArray.call(void 0, items) : items;
403
403
  items = isVerticalDirection ? verticalizeItems(items) : items;
404
404
  if (activeId2 == null) return (_a2 = findFirstEnabledItem2(items)) == null ? void 0 : _a2.id;
405
405
  const activeItem = items.find((item) => item.id === activeId2);
@@ -440,7 +440,7 @@ function createCompositeStore(props = {}) {
440
440
  },
441
441
  last: () => {
442
442
  var _a2;
443
- return (_a2 = findFirstEnabledItem2(_QAUJZR6Ycjs.reverseArray.call(void 0, composite.getState().renderedItems))) == null ? void 0 : _a2.id;
443
+ return (_a2 = findFirstEnabledItem2(_JBOLBTVUcjs.reverseArray.call(void 0, composite.getState().renderedItems))) == null ? void 0 : _a2.id;
444
444
  },
445
445
  next: (options) => {
446
446
  if (options !== void 0 && typeof options === "number") options = { skip: options };
@@ -464,25 +464,25 @@ function createCompositeStore(props = {}) {
464
464
  // ../ariakit-react-components/dist/composite/composite-store.js
465
465
  function useCompositeStoreOptions(props) {
466
466
  return {
467
- id: _QAUJZR6Ycjs.useId.call(void 0, props.id),
467
+ id: _JBOLBTVUcjs.useId.call(void 0, props.id),
468
468
  ...props
469
469
  };
470
470
  }
471
471
  function useCompositeStoreProps(store, update, props) {
472
- store = _XPQIHUQ7cjs.useCollectionStoreProps.call(void 0, store, update, props);
473
- _D4HCGWOUcjs.useStoreProps.call(void 0, store, props, "activeId", "setActiveId");
474
- _D4HCGWOUcjs.useStoreProps.call(void 0, store, props, "includesBaseElement");
475
- _D4HCGWOUcjs.useStoreProps.call(void 0, store, props, "virtualFocus");
476
- _D4HCGWOUcjs.useStoreProps.call(void 0, store, props, "orientation");
477
- _D4HCGWOUcjs.useStoreProps.call(void 0, store, props, "rtl");
478
- _D4HCGWOUcjs.useStoreProps.call(void 0, store, props, "focusLoop");
479
- _D4HCGWOUcjs.useStoreProps.call(void 0, store, props, "focusWrap");
480
- _D4HCGWOUcjs.useStoreProps.call(void 0, store, props, "focusShift");
472
+ store = _42GL4LKIcjs.useCollectionStoreProps.call(void 0, store, update, props);
473
+ _FHPV2Q7Ccjs.useStoreProps.call(void 0, store, props, "activeId", "setActiveId");
474
+ _FHPV2Q7Ccjs.useStoreProps.call(void 0, store, props, "includesBaseElement");
475
+ _FHPV2Q7Ccjs.useStoreProps.call(void 0, store, props, "virtualFocus");
476
+ _FHPV2Q7Ccjs.useStoreProps.call(void 0, store, props, "orientation");
477
+ _FHPV2Q7Ccjs.useStoreProps.call(void 0, store, props, "rtl");
478
+ _FHPV2Q7Ccjs.useStoreProps.call(void 0, store, props, "focusLoop");
479
+ _FHPV2Q7Ccjs.useStoreProps.call(void 0, store, props, "focusWrap");
480
+ _FHPV2Q7Ccjs.useStoreProps.call(void 0, store, props, "focusShift");
481
481
  return store;
482
482
  }
483
483
  function useCompositeStore(props = {}) {
484
484
  props = useCompositeStoreOptions(props);
485
- const [store, update] = _D4HCGWOUcjs.useStore.call(void 0, createCompositeStore, props);
485
+ const [store, update] = _FHPV2Q7Ccjs.useStore.call(void 0, createCompositeStore, props);
486
486
  return useCompositeStoreProps(store, update, props);
487
487
  }
488
488
 
@@ -1,6 +1,6 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _XPQIHUQ7cjs = require('./XPQIHUQ7.cjs');
3
+ var _42GL4LKIcjs = require('./42GL4LKI.cjs');
4
4
 
5
5
 
6
6
 
@@ -9,15 +9,15 @@ var _XPQIHUQ7cjs = require('./XPQIHUQ7.cjs');
9
9
 
10
10
 
11
11
 
12
- var _QAUJZR6Ycjs = require('./QAUJZR6Y.cjs');
12
+ var _JBOLBTVUcjs = require('./JBOLBTVU.cjs');
13
13
 
14
14
  // ../ariakit-react-components/dist/collection/collection-item.js
15
15
  var _react = require('react');
16
16
  var TagName = "div";
17
- var useCollectionItem = _QAUJZR6Ycjs.createHook.call(void 0, function useCollectionItem2({ store, shouldRegisterItem = true, getItem = _QAUJZR6Ycjs.identity, element, ...props }) {
18
- const context = _XPQIHUQ7cjs.useCollectionContext.call(void 0, );
17
+ var useCollectionItem = _JBOLBTVUcjs.createHook.call(void 0, function useCollectionItem2({ store, shouldRegisterItem = true, getItem = _JBOLBTVUcjs.identity, element, ...props }) {
18
+ const context = _42GL4LKIcjs.useCollectionContext.call(void 0, );
19
19
  store = store || context;
20
- const id = _QAUJZR6Ycjs.useId.call(void 0, props.id);
20
+ const id = _JBOLBTVUcjs.useId.call(void 0, props.id);
21
21
  const ref = _react.useRef.call(void 0, element);
22
22
  _react.useEffect.call(void 0, () => {
23
23
  const element2 = ref.current;
@@ -37,12 +37,12 @@ var useCollectionItem = _QAUJZR6Ycjs.createHook.call(void 0, function useCollect
37
37
  ]);
38
38
  props = {
39
39
  ...props,
40
- ref: _QAUJZR6Ycjs.useMergeRefs.call(void 0, ref, props.ref)
40
+ ref: _JBOLBTVUcjs.useMergeRefs.call(void 0, ref, props.ref)
41
41
  };
42
- return _QAUJZR6Ycjs.removeUndefinedValues.call(void 0, props);
42
+ return _JBOLBTVUcjs.removeUndefinedValues.call(void 0, props);
43
43
  });
44
- var CollectionItem = _QAUJZR6Ycjs.forwardRef.call(void 0, function CollectionItem2(props) {
45
- return _QAUJZR6Ycjs.createElement.call(void 0, TagName, useCollectionItem(props));
44
+ var CollectionItem = _JBOLBTVUcjs.forwardRef.call(void 0, function CollectionItem2(props) {
45
+ return _JBOLBTVUcjs.createElement.call(void 0, TagName, useCollectionItem(props));
46
46
  });
47
47
 
48
48
 
@@ -1,15 +1,15 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
2
 
3
- var _NMUCJYMRcjs = require('./NMUCJYMR.cjs');
3
+ var _US2XYAXEcjs = require('./US2XYAXE.cjs');
4
4
 
5
5
 
6
- var _L2IFVMDUcjs = require('./L2IFVMDU.cjs');
6
+ var _2WBRQ3I7cjs = require('./2WBRQ3I7.cjs');
7
7
 
8
8
  // ../ariakit-react-components/dist/composite/composite-provider.js
9
9
  var _jsxruntime = require('react/jsx-runtime');
10
10
  function CompositeProvider(props = {}) {
11
- return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _L2IFVMDUcjs.CompositeContextProvider, {
12
- value: _NMUCJYMRcjs.useCompositeStore.call(void 0, props),
11
+ return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _2WBRQ3I7cjs.CompositeContextProvider, {
12
+ value: _US2XYAXEcjs.useCompositeStore.call(void 0, props),
13
13
  children: props.children
14
14
  });
15
15
  }
@@ -0,0 +1,37 @@
1
+ "use strict";Object.defineProperty(exports, "__esModule", {value: true});
2
+
3
+ var _DDV252ZYcjs = require('./DDV252ZY.cjs');
4
+
5
+
6
+ var _2WBRQ3I7cjs = require('./2WBRQ3I7.cjs');
7
+
8
+
9
+ var _FHPV2Q7Ccjs = require('./FHPV2Q7C.cjs');
10
+
11
+
12
+
13
+
14
+
15
+ var _JBOLBTVUcjs = require('./JBOLBTVU.cjs');
16
+
17
+ // ../ariakit-react-components/dist/composite/composite-separator.js
18
+ var TagName = "hr";
19
+ var useCompositeSeparator = _JBOLBTVUcjs.createHook.call(void 0, function useCompositeSeparator2({ store, ...props }) {
20
+ const context = _2WBRQ3I7cjs.useCompositeScopedContext.call(void 0, );
21
+ store = store || context;
22
+ _JBOLBTVUcjs.invariant.call(void 0, store, process.env.NODE_ENV !== "production" && "CompositeSeparator must be wrapped in a Composite component.");
23
+ const orientation = _FHPV2Q7Ccjs.useStoreState.call(void 0, store, (state) => state.orientation === "horizontal" ? "vertical" : "horizontal");
24
+ props = _DDV252ZYcjs.useSeparator.call(void 0, {
25
+ ...props,
26
+ orientation
27
+ });
28
+ return props;
29
+ });
30
+ var CompositeSeparator = _JBOLBTVUcjs.forwardRef.call(void 0, function CompositeSeparator2(props) {
31
+ return _JBOLBTVUcjs.createElement.call(void 0, TagName, useCompositeSeparator(props));
32
+ });
33
+
34
+
35
+
36
+
37
+ exports.useCompositeSeparator = useCompositeSeparator; exports.CompositeSeparator = CompositeSeparator;