@quantinuum/quantinuum-ui 4.0.1-fix-update-radix.1 → 4.0.2

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 (247) hide show
  1. package/dist/node_modules/@babel/runtime/helpers/esm/extends.js +12 -0
  2. package/dist/node_modules/@babel/runtime/helpers/esm/extends.js.map +1 -0
  3. package/dist/node_modules/@radix-ui/number/dist/index.mjs.js +3 -4
  4. package/dist/node_modules/@radix-ui/number/dist/index.mjs.js.map +1 -1
  5. package/dist/node_modules/@radix-ui/primitive/dist/index.mjs.js +6 -9
  6. package/dist/node_modules/@radix-ui/primitive/dist/index.mjs.js.map +1 -1
  7. package/dist/node_modules/@radix-ui/react-accordion/dist/index.mjs.js +267 -279
  8. package/dist/node_modules/@radix-ui/react-accordion/dist/index.mjs.js.map +1 -1
  9. package/dist/node_modules/@radix-ui/react-avatar/dist/index.mjs.js +92 -114
  10. package/dist/node_modules/@radix-ui/react-avatar/dist/index.mjs.js.map +1 -1
  11. package/dist/node_modules/@radix-ui/react-checkbox/dist/index.mjs.js +138 -255
  12. package/dist/node_modules/@radix-ui/react-checkbox/dist/index.mjs.js.map +1 -1
  13. package/dist/node_modules/@radix-ui/react-collapsible/dist/index.mjs.js +130 -135
  14. package/dist/node_modules/@radix-ui/react-collapsible/dist/index.mjs.js.map +1 -1
  15. package/dist/node_modules/@radix-ui/react-collection/dist/index.mjs.js +88 -66
  16. package/dist/node_modules/@radix-ui/react-collection/dist/index.mjs.js.map +1 -1
  17. package/dist/node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-slot/dist/index.mjs.js +73 -81
  18. package/dist/node_modules/@radix-ui/react-collection/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
  19. package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js +21 -34
  20. package/dist/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js.map +1 -1
  21. package/dist/node_modules/@radix-ui/react-context/dist/index.mjs.js +93 -72
  22. package/dist/node_modules/@radix-ui/react-context/dist/index.mjs.js.map +1 -1
  23. package/dist/node_modules/@radix-ui/react-dialog/dist/index.mjs.js +254 -297
  24. package/dist/node_modules/@radix-ui/react-dialog/dist/index.mjs.js.map +1 -1
  25. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.mjs.js +73 -81
  26. package/dist/node_modules/@radix-ui/react-dialog/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
  27. package/dist/node_modules/@radix-ui/react-direction/dist/index.mjs.js +6 -8
  28. package/dist/node_modules/@radix-ui/react-direction/dist/index.mjs.js.map +1 -1
  29. package/dist/node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs.js +217 -190
  30. package/dist/node_modules/@radix-ui/react-dismissable-layer/dist/index.mjs.js.map +1 -1
  31. package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.mjs.js +217 -243
  32. package/dist/node_modules/@radix-ui/react-dropdown-menu/dist/index.mjs.js.map +1 -1
  33. package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.mjs.js +25 -26
  34. package/dist/node_modules/@radix-ui/react-focus-guards/dist/index.mjs.js.map +1 -1
  35. package/dist/node_modules/@radix-ui/react-focus-scope/dist/index.mjs.js +259 -191
  36. package/dist/node_modules/@radix-ui/react-focus-scope/dist/index.mjs.js.map +1 -1
  37. package/dist/node_modules/@radix-ui/react-hover-card/dist/index.mjs.js +205 -224
  38. package/dist/node_modules/@radix-ui/react-hover-card/dist/index.mjs.js.map +1 -1
  39. package/dist/node_modules/@radix-ui/react-id/dist/index.mjs.js +14 -11
  40. package/dist/node_modules/@radix-ui/react-id/dist/index.mjs.js.map +1 -1
  41. package/dist/node_modules/@radix-ui/react-label/dist/index.mjs.js +14 -22
  42. package/dist/node_modules/@radix-ui/react-label/dist/index.mjs.js.map +1 -1
  43. package/dist/node_modules/@radix-ui/react-menu/dist/index.mjs.js +820 -765
  44. package/dist/node_modules/@radix-ui/react-menu/dist/index.mjs.js.map +1 -1
  45. package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.mjs.js +73 -81
  46. package/dist/node_modules/@radix-ui/react-menu/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
  47. package/dist/node_modules/@radix-ui/react-navigation-menu/dist/index.mjs.js +730 -717
  48. package/dist/node_modules/@radix-ui/react-navigation-menu/dist/index.mjs.js.map +1 -1
  49. package/dist/node_modules/@radix-ui/react-popover/dist/index.mjs.js +199 -268
  50. package/dist/node_modules/@radix-ui/react-popover/dist/index.mjs.js.map +1 -1
  51. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.mjs.js +73 -81
  52. package/dist/node_modules/@radix-ui/react-popover/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
  53. package/dist/node_modules/@radix-ui/react-popper/dist/index.mjs.js +223 -267
  54. package/dist/node_modules/@radix-ui/react-popper/dist/index.mjs.js.map +1 -1
  55. package/dist/node_modules/@radix-ui/react-portal/dist/index.mjs.js +10 -14
  56. package/dist/node_modules/@radix-ui/react-portal/dist/index.mjs.js.map +1 -1
  57. package/dist/node_modules/@radix-ui/react-presence/dist/index.mjs.js +121 -122
  58. package/dist/node_modules/@radix-ui/react-presence/dist/index.mjs.js.map +1 -1
  59. package/dist/node_modules/@radix-ui/react-primitive/dist/index.mjs.js +83 -39
  60. package/dist/node_modules/@radix-ui/react-primitive/dist/index.mjs.js.map +1 -1
  61. package/dist/node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.mjs.js +73 -81
  62. package/dist/node_modules/@radix-ui/react-primitive/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
  63. package/dist/node_modules/@radix-ui/react-progress/dist/index.mjs.js +78 -77
  64. package/dist/node_modules/@radix-ui/react-progress/dist/index.mjs.js.map +1 -1
  65. package/dist/node_modules/@radix-ui/react-radio-group/dist/index.mjs.js +217 -264
  66. package/dist/node_modules/@radix-ui/react-radio-group/dist/index.mjs.js.map +1 -1
  67. package/dist/node_modules/@radix-ui/react-roving-focus/dist/index.mjs.js +216 -204
  68. package/dist/node_modules/@radix-ui/react-roving-focus/dist/index.mjs.js.map +1 -1
  69. package/dist/node_modules/@radix-ui/react-scroll-area/dist/index.mjs.js +9 -9
  70. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/number/dist/index.mjs.js +7 -0
  71. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/number/dist/index.mjs.js.map +1 -0
  72. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/primitive/dist/index.mjs.js +12 -0
  73. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/primitive/dist/index.mjs.js.map +1 -0
  74. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js +40 -0
  75. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js.map +1 -0
  76. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-context/dist/index.mjs.js +64 -0
  77. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-context/dist/index.mjs.js.map +1 -0
  78. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-direction/dist/index.mjs.js +12 -0
  79. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-direction/dist/index.mjs.js.map +1 -0
  80. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-presence/dist/index.mjs.js +132 -0
  81. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-presence/dist/index.mjs.js.map +1 -0
  82. package/dist/node_modules/{cmdk → @radix-ui/react-scroll-area}/node_modules/@radix-ui/react-primitive/dist/index.mjs.js +1 -1
  83. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-primitive/dist/index.mjs.js.map +1 -0
  84. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-slot/dist/index.mjs.js +90 -0
  85. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -0
  86. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js +13 -0
  87. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js.map +1 -0
  88. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js +8 -0
  89. package/dist/node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js.map +1 -0
  90. package/dist/node_modules/@radix-ui/react-select/dist/index.mjs.js +1079 -1080
  91. package/dist/node_modules/@radix-ui/react-select/dist/index.mjs.js.map +1 -1
  92. package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-slot/dist/index.mjs.js +73 -81
  93. package/dist/node_modules/@radix-ui/react-select/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
  94. package/dist/node_modules/@radix-ui/react-separator/dist/index.mjs.js +43 -26
  95. package/dist/node_modules/@radix-ui/react-separator/dist/index.mjs.js.map +1 -1
  96. package/dist/node_modules/@radix-ui/react-slot/dist/index.mjs.js +1 -1
  97. package/dist/node_modules/@radix-ui/react-slot/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js +37 -0
  98. package/dist/node_modules/@radix-ui/react-slot/node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js.map +1 -0
  99. package/dist/node_modules/@radix-ui/react-switch/dist/index.mjs.js +112 -140
  100. package/dist/node_modules/@radix-ui/react-switch/dist/index.mjs.js.map +1 -1
  101. package/dist/node_modules/@radix-ui/react-tabs/dist/index.mjs.js +141 -173
  102. package/dist/node_modules/@radix-ui/react-tabs/dist/index.mjs.js.map +1 -1
  103. package/dist/node_modules/@radix-ui/react-toggle/dist/index.mjs.js +25 -34
  104. package/dist/node_modules/@radix-ui/react-toggle/dist/index.mjs.js.map +1 -1
  105. package/dist/node_modules/@radix-ui/react-toggle-group/dist/index.mjs.js +145 -154
  106. package/dist/node_modules/@radix-ui/react-toggle-group/dist/index.mjs.js.map +1 -1
  107. package/dist/node_modules/@radix-ui/react-tooltip/dist/index.mjs.js +491 -462
  108. package/dist/node_modules/@radix-ui/react-tooltip/dist/index.mjs.js.map +1 -1
  109. package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.mjs.js +78 -13
  110. package/dist/node_modules/@radix-ui/react-tooltip/node_modules/@radix-ui/react-slot/dist/index.mjs.js.map +1 -1
  111. package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js +15 -9
  112. package/dist/node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js.map +1 -1
  113. package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs.js +43 -66
  114. package/dist/node_modules/@radix-ui/react-use-controllable-state/dist/index.mjs.js.map +1 -1
  115. package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.mjs.js +18 -15
  116. package/dist/node_modules/@radix-ui/react-use-escape-keydown/dist/index.mjs.js.map +1 -1
  117. package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js +9 -5
  118. package/dist/node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js.map +1 -1
  119. package/dist/node_modules/@radix-ui/react-use-previous/dist/index.mjs.js +18 -12
  120. package/dist/node_modules/@radix-ui/react-use-previous/dist/index.mjs.js.map +1 -1
  121. package/dist/node_modules/@radix-ui/react-use-size/dist/index.mjs.js +48 -37
  122. package/dist/node_modules/@radix-ui/react-use-size/dist/index.mjs.js.map +1 -1
  123. package/dist/node_modules/@radix-ui/react-visually-hidden/dist/index.mjs.js +23 -32
  124. package/dist/node_modules/@radix-ui/react-visually-hidden/dist/index.mjs.js.map +1 -1
  125. package/dist/node_modules/aria-hidden/dist/es2015/index.js +16 -22
  126. package/dist/node_modules/aria-hidden/dist/es2015/index.js.map +1 -1
  127. package/dist/node_modules/class-variance-authority/dist/index.mjs.js +9 -7
  128. package/dist/node_modules/class-variance-authority/dist/index.mjs.js.map +1 -1
  129. package/dist/node_modules/class-variance-authority/node_modules/clsx/dist/clsx.mjs.js +4 -0
  130. package/dist/node_modules/class-variance-authority/node_modules/clsx/dist/clsx.mjs.js.map +1 -0
  131. package/dist/node_modules/cmdk/dist/index.mjs.js +4 -8
  132. package/dist/node_modules/cmdk/dist/index.mjs.js.map +1 -1
  133. package/dist/node_modules/cmdk/node_modules/@radix-ui/primitive/dist/index.module.js +9 -0
  134. package/dist/node_modules/cmdk/node_modules/@radix-ui/primitive/dist/index.module.js.map +1 -0
  135. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-compose-refs/dist/index.module.js +27 -0
  136. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-compose-refs/dist/index.module.js.map +1 -0
  137. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-context/dist/index.module.js +101 -0
  138. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-context/dist/index.module.js.map +1 -0
  139. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-dialog/dist/index.module.js +214 -0
  140. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-dialog/dist/index.module.js.map +1 -0
  141. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-dismissable-layer/dist/index.module.js +233 -0
  142. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-dismissable-layer/dist/index.module.js.map +1 -0
  143. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-focus-guards/dist/index.module.js +30 -0
  144. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-focus-guards/dist/index.module.js.map +1 -0
  145. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-focus-scope/dist/index.module.js +252 -0
  146. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-focus-scope/dist/index.module.js.map +1 -0
  147. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-id/dist/index.module.js +19 -0
  148. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-id/dist/index.module.js.map +1 -0
  149. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-portal/dist/index.module.js +15 -0
  150. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-portal/dist/index.module.js.map +1 -0
  151. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-presence/dist/index.module.js +131 -0
  152. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-presence/dist/index.module.js.map +1 -0
  153. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-primitive/dist/index.module.js +85 -0
  154. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-primitive/dist/index.module.js.map +1 -0
  155. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-slot/dist/index.module.js +79 -0
  156. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-slot/dist/index.module.js.map +1 -0
  157. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-callback-ref/dist/index.module.js +19 -0
  158. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-callback-ref/dist/index.module.js.map +1 -0
  159. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-controllable-state/dist/index.module.js +48 -0
  160. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-controllable-state/dist/index.module.js.map +1 -0
  161. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-escape-keydown/dist/index.module.js +21 -0
  162. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-escape-keydown/dist/index.module.js.map +1 -0
  163. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-layout-effect/dist/index.module.js +12 -0
  164. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-use-layout-effect/dist/index.module.js.map +1 -0
  165. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/Combination.js +10 -0
  166. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/Combination.js.map +1 -0
  167. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +146 -0
  168. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/SideEffect.js.map +1 -0
  169. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/UI.js +39 -0
  170. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/UI.js.map +1 -0
  171. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js +22 -0
  172. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.js.map +1 -0
  173. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +97 -0
  174. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/handleScroll.js.map +1 -0
  175. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/medium.js +9 -0
  176. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/medium.js.map +1 -0
  177. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/sidecar.js +10 -0
  178. package/dist/node_modules/cmdk/node_modules/react-remove-scroll/dist/es2015/sidecar.js.map +1 -0
  179. package/dist/node_modules/command-score/index.js +138 -0
  180. package/dist/node_modules/command-score/index.js.map +1 -0
  181. package/dist/node_modules/input-otp/dist/index.mjs.js +1 -1
  182. package/dist/node_modules/input-otp/dist/index.mjs.js.map +1 -1
  183. package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js +5 -23
  184. package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.js.map +1 -1
  185. package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js +2 -2
  186. package/dist/node_modules/react-remove-scroll/dist/es2015/UI.js.map +1 -1
  187. package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js +6 -18
  188. package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.js.map +1 -1
  189. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js +5 -25
  190. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.js.map +1 -1
  191. package/dist/node_modules/sonner/dist/index.mjs.js +26 -46
  192. package/dist/node_modules/sonner/dist/index.mjs.js.map +1 -1
  193. package/dist/node_modules/tailwind-merge/dist/bundle-mjs.mjs.js +1 -1
  194. package/dist/node_modules/tailwind-merge/dist/bundle-mjs.mjs.js.map +1 -1
  195. package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js +1 -27
  196. package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.js.map +1 -1
  197. package/dist/src/index.js +1 -1
  198. package/dist/src/shadcn/ui/accordion.js +7 -7
  199. package/dist/src/shadcn/ui/avatar.js +7 -7
  200. package/dist/src/shadcn/ui/checkbox.js +3 -3
  201. package/dist/src/shadcn/ui/command.js +15 -15
  202. package/dist/src/shadcn/ui/dialog.js +14 -14
  203. package/dist/src/shadcn/ui/dropdown-menu.js +23 -23
  204. package/dist/src/shadcn/ui/hover-card.js +5 -5
  205. package/dist/src/shadcn/ui/label.js +3 -3
  206. package/dist/src/shadcn/ui/navigation-menu.js +15 -15
  207. package/dist/src/shadcn/ui/navigation-menu.js.map +1 -1
  208. package/dist/src/shadcn/ui/popover.js +6 -32
  209. package/dist/src/shadcn/ui/popover.js.map +1 -1
  210. package/dist/src/shadcn/ui/progress.js +3 -3
  211. package/dist/src/shadcn/ui/radio-group.js +5 -5
  212. package/dist/src/shadcn/ui/select.js +19 -19
  213. package/dist/src/shadcn/ui/separator.js +3 -3
  214. package/dist/src/shadcn/ui/sheet.js +14 -14
  215. package/dist/src/shadcn/ui/switch.js +3 -3
  216. package/dist/src/shadcn/ui/tabs.js +8 -8
  217. package/dist/src/shadcn/ui/toggle-group.js +5 -5
  218. package/dist/src/shadcn/ui/toggle.js +3 -3
  219. package/dist/src/shadcn/ui/tooltip.js +7 -7
  220. package/dist/src/tailwindTheme.js +12 -12
  221. package/dist/src/tailwindTheme.js.map +1 -1
  222. package/dist/tailwind-manifest.js +10979 -9483
  223. package/dist/types/src/shadcn/ui/command.d.ts +8 -44
  224. package/dist/types/src/shadcn/ui/popover.d.ts +4 -8
  225. package/dist/types/src/shadcn/ui/sheet.d.ts +1 -1
  226. package/dist/types/src/tailwindTheme.d.ts +4 -6
  227. package/dist/types/tailwind.config.d.ts +4 -6
  228. package/package.json +32 -12
  229. package/dist/_virtual/index.js +0 -4
  230. package/dist/_virtual/index.js.map +0 -1
  231. package/dist/_virtual/use-sync-external-store-shim.development.js +0 -4
  232. package/dist/_virtual/use-sync-external-store-shim.development.js.map +0 -1
  233. package/dist/_virtual/use-sync-external-store-shim.production.js +0 -4
  234. package/dist/_virtual/use-sync-external-store-shim.production.js.map +0 -1
  235. package/dist/node_modules/@radix-ui/react-arrow/dist/index.mjs.js +0 -26
  236. package/dist/node_modules/@radix-ui/react-arrow/dist/index.mjs.js.map +0 -1
  237. package/dist/node_modules/@radix-ui/react-use-is-hydrated/dist/index.mjs.js +0 -18
  238. package/dist/node_modules/@radix-ui/react-use-is-hydrated/dist/index.mjs.js.map +0 -1
  239. package/dist/node_modules/cmdk/dist/chunk-NZJY6EH4.mjs.js +0 -4
  240. package/dist/node_modules/cmdk/dist/chunk-NZJY6EH4.mjs.js.map +0 -1
  241. package/dist/node_modules/cmdk/node_modules/@radix-ui/react-primitive/dist/index.mjs.js.map +0 -1
  242. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js +0 -107
  243. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js.map +0 -1
  244. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js +0 -78
  245. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js.map +0 -1
  246. package/dist/node_modules/use-sync-external-store/shim/index.js +0 -13
  247. package/dist/node_modules/use-sync-external-store/shim/index.js.map +0 -1
@@ -1,225 +1,237 @@
1
- 'use client';
2
- import * as React from 'react';
3
- import { composeEventHandlers } from '../../primitive/dist/index.mjs.js';
4
- import { createCollection } from '../../react-collection/dist/index.mjs.js';
5
- import { useComposedRefs } from '../../react-compose-refs/dist/index.mjs.js';
6
- import { createContextScope } from '../../react-context/dist/index.mjs.js';
7
- import { useId } from '../../react-id/dist/index.mjs.js';
8
- import { Primitive } from '../../react-primitive/dist/index.mjs.js';
9
- import { useCallbackRef } from '../../react-use-callback-ref/dist/index.mjs.js';
10
- import { useControllableState } from '../../react-use-controllable-state/dist/index.mjs.js';
11
- import { useDirection } from '../../react-direction/dist/index.mjs.js';
12
- import { jsx } from 'react/jsx-runtime';
1
+ import _extends from '../../../@babel/runtime/helpers/esm/extends.js';
2
+ import { forwardRef, createElement, useRef, useState, useEffect, useCallback } from 'react';
3
+ import { composeEventHandlers as $e42e1063c40fb3ef$export$b9ecd428b558ff10 } from '../../primitive/dist/index.mjs.js';
4
+ import { createCollection as $e02a7d9cb1dc128c$export$c74125a8e3af6bb2 } from '../../react-collection/dist/index.mjs.js';
5
+ import { useComposedRefs as $6ed0406888f73fc4$export$c7b2cbe3552a0d05 } from '../../react-compose-refs/dist/index.mjs.js';
6
+ import { createContextScope as $c512c27ab02ef895$export$50c7b4e9d9f19c1 } from '../../react-context/dist/index.mjs.js';
7
+ import { useId as $1746a345f3d73bb7$export$f680877a34711e37 } from '../../react-id/dist/index.mjs.js';
8
+ import { Primitive as $8927f6f2acc4f386$export$250ffa63cdc0d034 } from '../../react-primitive/dist/index.mjs.js';
9
+ import { useCallbackRef as $b1b2314f5f9a1d84$export$25bec8c6f54ee79a } from '../../react-use-callback-ref/dist/index.mjs.js';
10
+ import { useControllableState as $71cd76cc60e0454e$export$6f32135080cb4c3 } from '../../react-use-controllable-state/dist/index.mjs.js';
11
+ import { useDirection as $f631663db3294ace$export$b39126d51d94e6f3 } from '../../react-direction/dist/index.mjs.js';
13
12
 
14
- var ENTRY_FOCUS = "rovingFocusGroup.onEntryFocus";
15
- var EVENT_OPTIONS = { bubbles: false, cancelable: true };
16
- var GROUP_NAME = "RovingFocusGroup";
17
- var [Collection, useCollection, createCollectionScope] = createCollection(GROUP_NAME);
18
- var [createRovingFocusGroupContext, createRovingFocusGroupScope] = createContextScope(
19
- GROUP_NAME,
20
- [createCollectionScope]
21
- );
22
- var [RovingFocusProvider, useRovingFocusContext] = createRovingFocusGroupContext(GROUP_NAME);
23
- var RovingFocusGroup = React.forwardRef(
24
- (props, forwardedRef) => {
25
- return /* @__PURE__ */ jsx(Collection.Provider, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ jsx(Collection.Slot, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ jsx(RovingFocusGroupImpl, { ...props, ref: forwardedRef }) }) });
26
- }
27
- );
28
- RovingFocusGroup.displayName = GROUP_NAME;
29
- var RovingFocusGroupImpl = React.forwardRef((props, forwardedRef) => {
30
- const {
31
- __scopeRovingFocusGroup,
32
- orientation,
33
- loop = false,
34
- dir,
35
- currentTabStopId: currentTabStopIdProp,
36
- defaultCurrentTabStopId,
37
- onCurrentTabStopIdChange,
38
- onEntryFocus,
39
- preventScrollOnEntryFocus = false,
40
- ...groupProps
41
- } = props;
42
- const ref = React.useRef(null);
43
- const composedRefs = useComposedRefs(forwardedRef, ref);
44
- const direction = useDirection(dir);
45
- const [currentTabStopId, setCurrentTabStopId] = useControllableState({
46
- prop: currentTabStopIdProp,
47
- defaultProp: defaultCurrentTabStopId ?? null,
48
- onChange: onCurrentTabStopIdChange,
49
- caller: GROUP_NAME
50
- });
51
- const [isTabbingBackOut, setIsTabbingBackOut] = React.useState(false);
52
- const handleEntryFocus = useCallbackRef(onEntryFocus);
53
- const getItems = useCollection(__scopeRovingFocusGroup);
54
- const isClickFocusRef = React.useRef(false);
55
- const [focusableItemsCount, setFocusableItemsCount] = React.useState(0);
56
- React.useEffect(() => {
57
- const node = ref.current;
58
- if (node) {
59
- node.addEventListener(ENTRY_FOCUS, handleEntryFocus);
60
- return () => node.removeEventListener(ENTRY_FOCUS, handleEntryFocus);
61
- }
62
- }, [handleEntryFocus]);
63
- return /* @__PURE__ */ jsx(
64
- RovingFocusProvider,
65
- {
66
- scope: __scopeRovingFocusGroup,
67
- orientation,
68
- dir: direction,
69
- loop,
70
- currentTabStopId,
71
- onItemFocus: React.useCallback(
72
- (tabStopId) => setCurrentTabStopId(tabStopId),
73
- [setCurrentTabStopId]
74
- ),
75
- onItemShiftTab: React.useCallback(() => setIsTabbingBackOut(true), []),
76
- onFocusableItemAdd: React.useCallback(
77
- () => setFocusableItemsCount((prevCount) => prevCount + 1),
78
- []
79
- ),
80
- onFocusableItemRemove: React.useCallback(
81
- () => setFocusableItemsCount((prevCount) => prevCount - 1),
82
- []
83
- ),
84
- children: /* @__PURE__ */ jsx(
85
- Primitive.div,
86
- {
87
- tabIndex: isTabbingBackOut || focusableItemsCount === 0 ? -1 : 0,
88
- "data-orientation": orientation,
89
- ...groupProps,
90
- ref: composedRefs,
91
- style: { outline: "none", ...props.style },
92
- onMouseDown: composeEventHandlers(props.onMouseDown, () => {
13
+ const $d7bdfb9eb0fdf311$var$ENTRY_FOCUS = 'rovingFocusGroup.onEntryFocus';
14
+ const $d7bdfb9eb0fdf311$var$EVENT_OPTIONS = {
15
+ bubbles: false,
16
+ cancelable: true
17
+ };
18
+ /* -------------------------------------------------------------------------------------------------
19
+ * RovingFocusGroup
20
+ * -----------------------------------------------------------------------------------------------*/ const $d7bdfb9eb0fdf311$var$GROUP_NAME = 'RovingFocusGroup';
21
+ const [$d7bdfb9eb0fdf311$var$Collection, $d7bdfb9eb0fdf311$var$useCollection, $d7bdfb9eb0fdf311$var$createCollectionScope] = $e02a7d9cb1dc128c$export$c74125a8e3af6bb2($d7bdfb9eb0fdf311$var$GROUP_NAME);
22
+ const [$d7bdfb9eb0fdf311$var$createRovingFocusGroupContext, $d7bdfb9eb0fdf311$export$c7109489551a4f4] = $c512c27ab02ef895$export$50c7b4e9d9f19c1($d7bdfb9eb0fdf311$var$GROUP_NAME, [
23
+ $d7bdfb9eb0fdf311$var$createCollectionScope
24
+ ]);
25
+ const [$d7bdfb9eb0fdf311$var$RovingFocusProvider, $d7bdfb9eb0fdf311$var$useRovingFocusContext] = $d7bdfb9eb0fdf311$var$createRovingFocusGroupContext($d7bdfb9eb0fdf311$var$GROUP_NAME);
26
+ const $d7bdfb9eb0fdf311$export$8699f7c8af148338 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
27
+ return /*#__PURE__*/ createElement($d7bdfb9eb0fdf311$var$Collection.Provider, {
28
+ scope: props.__scopeRovingFocusGroup
29
+ }, /*#__PURE__*/ createElement($d7bdfb9eb0fdf311$var$Collection.Slot, {
30
+ scope: props.__scopeRovingFocusGroup
31
+ }, /*#__PURE__*/ createElement($d7bdfb9eb0fdf311$var$RovingFocusGroupImpl, _extends({}, props, {
32
+ ref: forwardedRef
33
+ }))));
34
+ });
35
+ /* -----------------------------------------------------------------------------------------------*/ const $d7bdfb9eb0fdf311$var$RovingFocusGroupImpl = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
36
+ const { __scopeRovingFocusGroup: __scopeRovingFocusGroup , orientation: orientation , loop: loop = false , dir: dir , currentTabStopId: currentTabStopIdProp , defaultCurrentTabStopId: defaultCurrentTabStopId , onCurrentTabStopIdChange: onCurrentTabStopIdChange , onEntryFocus: onEntryFocus , ...groupProps } = props;
37
+ const ref = useRef(null);
38
+ const composedRefs = $6ed0406888f73fc4$export$c7b2cbe3552a0d05(forwardedRef, ref);
39
+ const direction = $f631663db3294ace$export$b39126d51d94e6f3(dir);
40
+ const [currentTabStopId = null, setCurrentTabStopId] = $71cd76cc60e0454e$export$6f32135080cb4c3({
41
+ prop: currentTabStopIdProp,
42
+ defaultProp: defaultCurrentTabStopId,
43
+ onChange: onCurrentTabStopIdChange
44
+ });
45
+ const [isTabbingBackOut, setIsTabbingBackOut] = useState(false);
46
+ const handleEntryFocus = $b1b2314f5f9a1d84$export$25bec8c6f54ee79a(onEntryFocus);
47
+ const getItems = $d7bdfb9eb0fdf311$var$useCollection(__scopeRovingFocusGroup);
48
+ const isClickFocusRef = useRef(false);
49
+ const [focusableItemsCount, setFocusableItemsCount] = useState(0);
50
+ useEffect(()=>{
51
+ const node = ref.current;
52
+ if (node) {
53
+ node.addEventListener($d7bdfb9eb0fdf311$var$ENTRY_FOCUS, handleEntryFocus);
54
+ return ()=>node.removeEventListener($d7bdfb9eb0fdf311$var$ENTRY_FOCUS, handleEntryFocus)
55
+ ;
56
+ }
57
+ }, [
58
+ handleEntryFocus
59
+ ]);
60
+ return /*#__PURE__*/ createElement($d7bdfb9eb0fdf311$var$RovingFocusProvider, {
61
+ scope: __scopeRovingFocusGroup,
62
+ orientation: orientation,
63
+ dir: direction,
64
+ loop: loop,
65
+ currentTabStopId: currentTabStopId,
66
+ onItemFocus: useCallback((tabStopId)=>setCurrentTabStopId(tabStopId)
67
+ , [
68
+ setCurrentTabStopId
69
+ ]),
70
+ onItemShiftTab: useCallback(()=>setIsTabbingBackOut(true)
71
+ , []),
72
+ onFocusableItemAdd: useCallback(()=>setFocusableItemsCount((prevCount)=>prevCount + 1
73
+ )
74
+ , []),
75
+ onFocusableItemRemove: useCallback(()=>setFocusableItemsCount((prevCount)=>prevCount - 1
76
+ )
77
+ , [])
78
+ }, /*#__PURE__*/ createElement($8927f6f2acc4f386$export$250ffa63cdc0d034.div, _extends({
79
+ tabIndex: isTabbingBackOut || focusableItemsCount === 0 ? -1 : 0,
80
+ "data-orientation": orientation
81
+ }, groupProps, {
82
+ ref: composedRefs,
83
+ style: {
84
+ outline: 'none',
85
+ ...props.style
86
+ },
87
+ onMouseDown: $e42e1063c40fb3ef$export$b9ecd428b558ff10(props.onMouseDown, ()=>{
93
88
  isClickFocusRef.current = true;
94
- }),
95
- onFocus: composeEventHandlers(props.onFocus, (event) => {
89
+ }),
90
+ onFocus: $e42e1063c40fb3ef$export$b9ecd428b558ff10(props.onFocus, (event)=>{
91
+ // We normally wouldn't need this check, because we already check
92
+ // that the focus is on the current target and not bubbling to it.
93
+ // We do this because Safari doesn't focus buttons when clicked, and
94
+ // instead, the wrapper will get focused and not through a bubbling event.
96
95
  const isKeyboardFocus = !isClickFocusRef.current;
97
96
  if (event.target === event.currentTarget && isKeyboardFocus && !isTabbingBackOut) {
98
- const entryFocusEvent = new CustomEvent(ENTRY_FOCUS, EVENT_OPTIONS);
99
- event.currentTarget.dispatchEvent(entryFocusEvent);
100
- if (!entryFocusEvent.defaultPrevented) {
101
- const items = getItems().filter((item) => item.focusable);
102
- const activeItem = items.find((item) => item.active);
103
- const currentItem = items.find((item) => item.id === currentTabStopId);
104
- const candidateItems = [activeItem, currentItem, ...items].filter(
105
- Boolean
106
- );
107
- const candidateNodes = candidateItems.map((item) => item.ref.current);
108
- focusFirst(candidateNodes, preventScrollOnEntryFocus);
109
- }
97
+ const entryFocusEvent = new CustomEvent($d7bdfb9eb0fdf311$var$ENTRY_FOCUS, $d7bdfb9eb0fdf311$var$EVENT_OPTIONS);
98
+ event.currentTarget.dispatchEvent(entryFocusEvent);
99
+ if (!entryFocusEvent.defaultPrevented) {
100
+ const items = getItems().filter((item)=>item.focusable
101
+ );
102
+ const activeItem = items.find((item)=>item.active
103
+ );
104
+ const currentItem = items.find((item)=>item.id === currentTabStopId
105
+ );
106
+ const candidateItems = [
107
+ activeItem,
108
+ currentItem,
109
+ ...items
110
+ ].filter(Boolean);
111
+ const candidateNodes = candidateItems.map((item)=>item.ref.current
112
+ );
113
+ $d7bdfb9eb0fdf311$var$focusFirst(candidateNodes);
114
+ }
110
115
  }
111
116
  isClickFocusRef.current = false;
112
- }),
113
- onBlur: composeEventHandlers(props.onBlur, () => setIsTabbingBackOut(false))
114
- }
115
- )
116
- }
117
- );
117
+ }),
118
+ onBlur: $e42e1063c40fb3ef$export$b9ecd428b558ff10(props.onBlur, ()=>setIsTabbingBackOut(false)
119
+ )
120
+ })));
118
121
  });
119
- var ITEM_NAME = "RovingFocusGroupItem";
120
- var RovingFocusGroupItem = React.forwardRef(
121
- (props, forwardedRef) => {
122
- const {
123
- __scopeRovingFocusGroup,
124
- focusable = true,
125
- active = false,
126
- tabStopId,
127
- children,
128
- ...itemProps
129
- } = props;
130
- const autoId = useId();
122
+ /* -------------------------------------------------------------------------------------------------
123
+ * RovingFocusGroupItem
124
+ * -----------------------------------------------------------------------------------------------*/ const $d7bdfb9eb0fdf311$var$ITEM_NAME = 'RovingFocusGroupItem';
125
+ const $d7bdfb9eb0fdf311$export$ab9df7c53fe8454 = /*#__PURE__*/ forwardRef((props, forwardedRef)=>{
126
+ const { __scopeRovingFocusGroup: __scopeRovingFocusGroup , focusable: focusable = true , active: active = false , tabStopId: tabStopId , ...itemProps } = props;
127
+ const autoId = $1746a345f3d73bb7$export$f680877a34711e37();
131
128
  const id = tabStopId || autoId;
132
- const context = useRovingFocusContext(ITEM_NAME, __scopeRovingFocusGroup);
129
+ const context = $d7bdfb9eb0fdf311$var$useRovingFocusContext($d7bdfb9eb0fdf311$var$ITEM_NAME, __scopeRovingFocusGroup);
133
130
  const isCurrentTabStop = context.currentTabStopId === id;
134
- const getItems = useCollection(__scopeRovingFocusGroup);
135
- const { onFocusableItemAdd, onFocusableItemRemove, currentTabStopId } = context;
136
- React.useEffect(() => {
137
- if (focusable) {
138
- onFocusableItemAdd();
139
- return () => onFocusableItemRemove();
140
- }
141
- }, [focusable, onFocusableItemAdd, onFocusableItemRemove]);
142
- return /* @__PURE__ */ jsx(
143
- Collection.ItemSlot,
144
- {
145
- scope: __scopeRovingFocusGroup,
146
- id,
131
+ const getItems = $d7bdfb9eb0fdf311$var$useCollection(__scopeRovingFocusGroup);
132
+ const { onFocusableItemAdd: onFocusableItemAdd , onFocusableItemRemove: onFocusableItemRemove } = context;
133
+ useEffect(()=>{
134
+ if (focusable) {
135
+ onFocusableItemAdd();
136
+ return ()=>onFocusableItemRemove()
137
+ ;
138
+ }
139
+ }, [
147
140
  focusable,
148
- active,
149
- children: /* @__PURE__ */ jsx(
150
- Primitive.span,
151
- {
152
- tabIndex: isCurrentTabStop ? 0 : -1,
153
- "data-orientation": context.orientation,
154
- ...itemProps,
155
- ref: forwardedRef,
156
- onMouseDown: composeEventHandlers(props.onMouseDown, (event) => {
157
- if (!focusable) event.preventDefault();
158
- else context.onItemFocus(id);
159
- }),
160
- onFocus: composeEventHandlers(props.onFocus, () => context.onItemFocus(id)),
161
- onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {
162
- if (event.key === "Tab" && event.shiftKey) {
141
+ onFocusableItemAdd,
142
+ onFocusableItemRemove
143
+ ]);
144
+ return /*#__PURE__*/ createElement($d7bdfb9eb0fdf311$var$Collection.ItemSlot, {
145
+ scope: __scopeRovingFocusGroup,
146
+ id: id,
147
+ focusable: focusable,
148
+ active: active
149
+ }, /*#__PURE__*/ createElement($8927f6f2acc4f386$export$250ffa63cdc0d034.span, _extends({
150
+ tabIndex: isCurrentTabStop ? 0 : -1,
151
+ "data-orientation": context.orientation
152
+ }, itemProps, {
153
+ ref: forwardedRef,
154
+ onMouseDown: $e42e1063c40fb3ef$export$b9ecd428b558ff10(props.onMouseDown, (event)=>{
155
+ // We prevent focusing non-focusable items on `mousedown`.
156
+ // Even though the item has tabIndex={-1}, that only means take it out of the tab order.
157
+ if (!focusable) event.preventDefault(); // Safari doesn't focus a button when clicked so we run our logic on mousedown also
158
+ else context.onItemFocus(id);
159
+ }),
160
+ onFocus: $e42e1063c40fb3ef$export$b9ecd428b558ff10(props.onFocus, ()=>context.onItemFocus(id)
161
+ ),
162
+ onKeyDown: $e42e1063c40fb3ef$export$b9ecd428b558ff10(props.onKeyDown, (event)=>{
163
+ if (event.key === 'Tab' && event.shiftKey) {
163
164
  context.onItemShiftTab();
164
165
  return;
165
- }
166
- if (event.target !== event.currentTarget) return;
167
- const focusIntent = getFocusIntent(event, context.orientation, context.dir);
168
- if (focusIntent !== void 0) {
169
- if (event.metaKey || event.ctrlKey || event.altKey || event.shiftKey) return;
166
+ }
167
+ if (event.target !== event.currentTarget) return;
168
+ const focusIntent = $d7bdfb9eb0fdf311$var$getFocusIntent(event, context.orientation, context.dir);
169
+ if (focusIntent !== undefined) {
170
170
  event.preventDefault();
171
- const items = getItems().filter((item) => item.focusable);
172
- let candidateNodes = items.map((item) => item.ref.current);
173
- if (focusIntent === "last") candidateNodes.reverse();
174
- else if (focusIntent === "prev" || focusIntent === "next") {
175
- if (focusIntent === "prev") candidateNodes.reverse();
176
- const currentIndex = candidateNodes.indexOf(event.currentTarget);
177
- candidateNodes = context.loop ? wrapArray(candidateNodes, currentIndex + 1) : candidateNodes.slice(currentIndex + 1);
171
+ const items = getItems().filter((item)=>item.focusable
172
+ );
173
+ let candidateNodes = items.map((item)=>item.ref.current
174
+ );
175
+ if (focusIntent === 'last') candidateNodes.reverse();
176
+ else if (focusIntent === 'prev' || focusIntent === 'next') {
177
+ if (focusIntent === 'prev') candidateNodes.reverse();
178
+ const currentIndex = candidateNodes.indexOf(event.currentTarget);
179
+ candidateNodes = context.loop ? $d7bdfb9eb0fdf311$var$wrapArray(candidateNodes, currentIndex + 1) : candidateNodes.slice(currentIndex + 1);
178
180
  }
179
- setTimeout(() => focusFirst(candidateNodes));
180
- }
181
- }),
182
- children: typeof children === "function" ? children({ isCurrentTabStop, hasTabStop: currentTabStopId != null }) : children
183
- }
184
- )
185
- }
186
- );
187
- }
188
- );
189
- RovingFocusGroupItem.displayName = ITEM_NAME;
190
- var MAP_KEY_TO_FOCUS_INTENT = {
191
- ArrowLeft: "prev",
192
- ArrowUp: "prev",
193
- ArrowRight: "next",
194
- ArrowDown: "next",
195
- PageUp: "first",
196
- Home: "first",
197
- PageDown: "last",
198
- End: "last"
181
+ /**
182
+ * Imperative focus during keydown is risky so we prevent React's batching updates
183
+ * to avoid potential bugs. See: https://github.com/facebook/react/issues/20332
184
+ */ setTimeout(()=>$d7bdfb9eb0fdf311$var$focusFirst(candidateNodes)
185
+ );
186
+ }
187
+ })
188
+ })));
189
+ });
190
+ /* -----------------------------------------------------------------------------------------------*/ // prettier-ignore
191
+ const $d7bdfb9eb0fdf311$var$MAP_KEY_TO_FOCUS_INTENT = {
192
+ ArrowLeft: 'prev',
193
+ ArrowUp: 'prev',
194
+ ArrowRight: 'next',
195
+ ArrowDown: 'next',
196
+ PageUp: 'first',
197
+ Home: 'first',
198
+ PageDown: 'last',
199
+ End: 'last'
199
200
  };
200
- function getDirectionAwareKey(key, dir) {
201
- if (dir !== "rtl") return key;
202
- return key === "ArrowLeft" ? "ArrowRight" : key === "ArrowRight" ? "ArrowLeft" : key;
201
+ function $d7bdfb9eb0fdf311$var$getDirectionAwareKey(key, dir) {
202
+ if (dir !== 'rtl') return key;
203
+ return key === 'ArrowLeft' ? 'ArrowRight' : key === 'ArrowRight' ? 'ArrowLeft' : key;
203
204
  }
204
- function getFocusIntent(event, orientation, dir) {
205
- const key = getDirectionAwareKey(event.key, dir);
206
- if (orientation === "vertical" && ["ArrowLeft", "ArrowRight"].includes(key)) return void 0;
207
- if (orientation === "horizontal" && ["ArrowUp", "ArrowDown"].includes(key)) return void 0;
208
- return MAP_KEY_TO_FOCUS_INTENT[key];
205
+ function $d7bdfb9eb0fdf311$var$getFocusIntent(event, orientation, dir) {
206
+ const key = $d7bdfb9eb0fdf311$var$getDirectionAwareKey(event.key, dir);
207
+ if (orientation === 'vertical' && [
208
+ 'ArrowLeft',
209
+ 'ArrowRight'
210
+ ].includes(key)) return undefined;
211
+ if (orientation === 'horizontal' && [
212
+ 'ArrowUp',
213
+ 'ArrowDown'
214
+ ].includes(key)) return undefined;
215
+ return $d7bdfb9eb0fdf311$var$MAP_KEY_TO_FOCUS_INTENT[key];
209
216
  }
210
- function focusFirst(candidates, preventScroll = false) {
211
- const PREVIOUSLY_FOCUSED_ELEMENT = document.activeElement;
212
- for (const candidate of candidates) {
213
- if (candidate === PREVIOUSLY_FOCUSED_ELEMENT) return;
214
- candidate.focus({ preventScroll });
215
- if (document.activeElement !== PREVIOUSLY_FOCUSED_ELEMENT) return;
216
- }
217
+ function $d7bdfb9eb0fdf311$var$focusFirst(candidates) {
218
+ const PREVIOUSLY_FOCUSED_ELEMENT = document.activeElement;
219
+ for (const candidate of candidates){
220
+ // if focus is already where we want to go, we don't want to keep going through the candidates
221
+ if (candidate === PREVIOUSLY_FOCUSED_ELEMENT) return;
222
+ candidate.focus();
223
+ if (document.activeElement !== PREVIOUSLY_FOCUSED_ELEMENT) return;
224
+ }
217
225
  }
218
- function wrapArray(array, startIndex) {
219
- return array.map((_, index) => array[(startIndex + index) % array.length]);
226
+ /**
227
+ * Wraps an array around itself at a given start index
228
+ * Example: `wrapArray(['a', 'b', 'c', 'd'], 2) === ['c', 'd', 'a', 'b']`
229
+ */ function $d7bdfb9eb0fdf311$var$wrapArray(array, startIndex) {
230
+ return array.map((_, index)=>array[(startIndex + index) % array.length]
231
+ );
220
232
  }
221
- var Root = RovingFocusGroup;
222
- var Item = RovingFocusGroupItem;
233
+ const $d7bdfb9eb0fdf311$export$be92b6f5f03c0fe9 = $d7bdfb9eb0fdf311$export$8699f7c8af148338;
234
+ const $d7bdfb9eb0fdf311$export$6d08773d2e66f8f2 = $d7bdfb9eb0fdf311$export$ab9df7c53fe8454;
223
235
 
224
- export { Item, Root, RovingFocusGroup, RovingFocusGroupItem, createRovingFocusGroupScope };
236
+ export { $d7bdfb9eb0fdf311$export$6d08773d2e66f8f2 as Item, $d7bdfb9eb0fdf311$export$be92b6f5f03c0fe9 as Root, $d7bdfb9eb0fdf311$export$8699f7c8af148338 as RovingFocusGroup, $d7bdfb9eb0fdf311$export$ab9df7c53fe8454 as RovingFocusGroupItem, $d7bdfb9eb0fdf311$export$c7109489551a4f4 as createRovingFocusGroupScope };
225
237
  //# sourceMappingURL=index.mjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs.js","sources":["../../../../../node_modules/@radix-ui/react-roving-focus/dist/index.mjs"],"sourcesContent":["\"use client\";\n\n// src/roving-focus-group.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { createCollection } from \"@radix-ui/react-collection\";\nimport { useComposedRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useId } from \"@radix-ui/react-id\";\nimport { Primitive } from \"@radix-ui/react-primitive\";\nimport { useCallbackRef } from \"@radix-ui/react-use-callback-ref\";\nimport { useControllableState } from \"@radix-ui/react-use-controllable-state\";\nimport { useDirection } from \"@radix-ui/react-direction\";\nimport { jsx } from \"react/jsx-runtime\";\nvar ENTRY_FOCUS = \"rovingFocusGroup.onEntryFocus\";\nvar EVENT_OPTIONS = { bubbles: false, cancelable: true };\nvar GROUP_NAME = \"RovingFocusGroup\";\nvar [Collection, useCollection, createCollectionScope] = createCollection(GROUP_NAME);\nvar [createRovingFocusGroupContext, createRovingFocusGroupScope] = createContextScope(\n GROUP_NAME,\n [createCollectionScope]\n);\nvar [RovingFocusProvider, useRovingFocusContext] = createRovingFocusGroupContext(GROUP_NAME);\nvar RovingFocusGroup = React.forwardRef(\n (props, forwardedRef) => {\n return /* @__PURE__ */ jsx(Collection.Provider, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ jsx(Collection.Slot, { scope: props.__scopeRovingFocusGroup, children: /* @__PURE__ */ jsx(RovingFocusGroupImpl, { ...props, ref: forwardedRef }) }) });\n }\n);\nRovingFocusGroup.displayName = GROUP_NAME;\nvar RovingFocusGroupImpl = React.forwardRef((props, forwardedRef) => {\n const {\n __scopeRovingFocusGroup,\n orientation,\n loop = false,\n dir,\n currentTabStopId: currentTabStopIdProp,\n defaultCurrentTabStopId,\n onCurrentTabStopIdChange,\n onEntryFocus,\n preventScrollOnEntryFocus = false,\n ...groupProps\n } = props;\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const direction = useDirection(dir);\n const [currentTabStopId, setCurrentTabStopId] = useControllableState({\n prop: currentTabStopIdProp,\n defaultProp: defaultCurrentTabStopId ?? null,\n onChange: onCurrentTabStopIdChange,\n caller: GROUP_NAME\n });\n const [isTabbingBackOut, setIsTabbingBackOut] = React.useState(false);\n const handleEntryFocus = useCallbackRef(onEntryFocus);\n const getItems = useCollection(__scopeRovingFocusGroup);\n const isClickFocusRef = React.useRef(false);\n const [focusableItemsCount, setFocusableItemsCount] = React.useState(0);\n React.useEffect(() => {\n const node = ref.current;\n if (node) {\n node.addEventListener(ENTRY_FOCUS, handleEntryFocus);\n return () => node.removeEventListener(ENTRY_FOCUS, handleEntryFocus);\n }\n }, [handleEntryFocus]);\n return /* @__PURE__ */ jsx(\n RovingFocusProvider,\n {\n scope: __scopeRovingFocusGroup,\n orientation,\n dir: direction,\n loop,\n currentTabStopId,\n onItemFocus: React.useCallback(\n (tabStopId) => setCurrentTabStopId(tabStopId),\n [setCurrentTabStopId]\n ),\n onItemShiftTab: React.useCallback(() => setIsTabbingBackOut(true), []),\n onFocusableItemAdd: React.useCallback(\n () => setFocusableItemsCount((prevCount) => prevCount + 1),\n []\n ),\n onFocusableItemRemove: React.useCallback(\n () => setFocusableItemsCount((prevCount) => prevCount - 1),\n []\n ),\n children: /* @__PURE__ */ jsx(\n Primitive.div,\n {\n tabIndex: isTabbingBackOut || focusableItemsCount === 0 ? -1 : 0,\n \"data-orientation\": orientation,\n ...groupProps,\n ref: composedRefs,\n style: { outline: \"none\", ...props.style },\n onMouseDown: composeEventHandlers(props.onMouseDown, () => {\n isClickFocusRef.current = true;\n }),\n onFocus: composeEventHandlers(props.onFocus, (event) => {\n const isKeyboardFocus = !isClickFocusRef.current;\n if (event.target === event.currentTarget && isKeyboardFocus && !isTabbingBackOut) {\n const entryFocusEvent = new CustomEvent(ENTRY_FOCUS, EVENT_OPTIONS);\n event.currentTarget.dispatchEvent(entryFocusEvent);\n if (!entryFocusEvent.defaultPrevented) {\n const items = getItems().filter((item) => item.focusable);\n const activeItem = items.find((item) => item.active);\n const currentItem = items.find((item) => item.id === currentTabStopId);\n const candidateItems = [activeItem, currentItem, ...items].filter(\n Boolean\n );\n const candidateNodes = candidateItems.map((item) => item.ref.current);\n focusFirst(candidateNodes, preventScrollOnEntryFocus);\n }\n }\n isClickFocusRef.current = false;\n }),\n onBlur: composeEventHandlers(props.onBlur, () => setIsTabbingBackOut(false))\n }\n )\n }\n );\n});\nvar ITEM_NAME = \"RovingFocusGroupItem\";\nvar RovingFocusGroupItem = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeRovingFocusGroup,\n focusable = true,\n active = false,\n tabStopId,\n children,\n ...itemProps\n } = props;\n const autoId = useId();\n const id = tabStopId || autoId;\n const context = useRovingFocusContext(ITEM_NAME, __scopeRovingFocusGroup);\n const isCurrentTabStop = context.currentTabStopId === id;\n const getItems = useCollection(__scopeRovingFocusGroup);\n const { onFocusableItemAdd, onFocusableItemRemove, currentTabStopId } = context;\n React.useEffect(() => {\n if (focusable) {\n onFocusableItemAdd();\n return () => onFocusableItemRemove();\n }\n }, [focusable, onFocusableItemAdd, onFocusableItemRemove]);\n return /* @__PURE__ */ jsx(\n Collection.ItemSlot,\n {\n scope: __scopeRovingFocusGroup,\n id,\n focusable,\n active,\n children: /* @__PURE__ */ jsx(\n Primitive.span,\n {\n tabIndex: isCurrentTabStop ? 0 : -1,\n \"data-orientation\": context.orientation,\n ...itemProps,\n ref: forwardedRef,\n onMouseDown: composeEventHandlers(props.onMouseDown, (event) => {\n if (!focusable) event.preventDefault();\n else context.onItemFocus(id);\n }),\n onFocus: composeEventHandlers(props.onFocus, () => context.onItemFocus(id)),\n onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {\n if (event.key === \"Tab\" && event.shiftKey) {\n context.onItemShiftTab();\n return;\n }\n if (event.target !== event.currentTarget) return;\n const focusIntent = getFocusIntent(event, context.orientation, context.dir);\n if (focusIntent !== void 0) {\n if (event.metaKey || event.ctrlKey || event.altKey || event.shiftKey) return;\n event.preventDefault();\n const items = getItems().filter((item) => item.focusable);\n let candidateNodes = items.map((item) => item.ref.current);\n if (focusIntent === \"last\") candidateNodes.reverse();\n else if (focusIntent === \"prev\" || focusIntent === \"next\") {\n if (focusIntent === \"prev\") candidateNodes.reverse();\n const currentIndex = candidateNodes.indexOf(event.currentTarget);\n candidateNodes = context.loop ? wrapArray(candidateNodes, currentIndex + 1) : candidateNodes.slice(currentIndex + 1);\n }\n setTimeout(() => focusFirst(candidateNodes));\n }\n }),\n children: typeof children === \"function\" ? children({ isCurrentTabStop, hasTabStop: currentTabStopId != null }) : children\n }\n )\n }\n );\n }\n);\nRovingFocusGroupItem.displayName = ITEM_NAME;\nvar MAP_KEY_TO_FOCUS_INTENT = {\n ArrowLeft: \"prev\",\n ArrowUp: \"prev\",\n ArrowRight: \"next\",\n ArrowDown: \"next\",\n PageUp: \"first\",\n Home: \"first\",\n PageDown: \"last\",\n End: \"last\"\n};\nfunction getDirectionAwareKey(key, dir) {\n if (dir !== \"rtl\") return key;\n return key === \"ArrowLeft\" ? \"ArrowRight\" : key === \"ArrowRight\" ? \"ArrowLeft\" : key;\n}\nfunction getFocusIntent(event, orientation, dir) {\n const key = getDirectionAwareKey(event.key, dir);\n if (orientation === \"vertical\" && [\"ArrowLeft\", \"ArrowRight\"].includes(key)) return void 0;\n if (orientation === \"horizontal\" && [\"ArrowUp\", \"ArrowDown\"].includes(key)) return void 0;\n return MAP_KEY_TO_FOCUS_INTENT[key];\n}\nfunction focusFirst(candidates, preventScroll = false) {\n const PREVIOUSLY_FOCUSED_ELEMENT = document.activeElement;\n for (const candidate of candidates) {\n if (candidate === PREVIOUSLY_FOCUSED_ELEMENT) return;\n candidate.focus({ preventScroll });\n if (document.activeElement !== PREVIOUSLY_FOCUSED_ELEMENT) return;\n }\n}\nfunction wrapArray(array, startIndex) {\n return array.map((_, index) => array[(startIndex + index) % array.length]);\n}\nvar Root = RovingFocusGroup;\nvar Item = RovingFocusGroupItem;\nexport {\n Item,\n Root,\n RovingFocusGroup,\n RovingFocusGroupItem,\n createRovingFocusGroupScope\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":[],"mappings":";;;;;;;;;;;;;AAcA;AACA;AACA;AACA;AACG;AACH;AACA;AACA;AACA;AACG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACG;AACH;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACG;AACA;;"}
1
+ {"version":3,"file":"index.mjs.js","sources":["../../../../../node_modules/@radix-ui/react-roving-focus/dist/index.mjs"],"sourcesContent":["import $98Iye$babelruntimehelpersesmextends from \"@babel/runtime/helpers/esm/extends\";\nimport {forwardRef as $98Iye$forwardRef, createElement as $98Iye$createElement, useRef as $98Iye$useRef, useState as $98Iye$useState, useEffect as $98Iye$useEffect, useCallback as $98Iye$useCallback} from \"react\";\nimport {composeEventHandlers as $98Iye$composeEventHandlers} from \"@radix-ui/primitive\";\nimport {createCollection as $98Iye$createCollection} from \"@radix-ui/react-collection\";\nimport {useComposedRefs as $98Iye$useComposedRefs} from \"@radix-ui/react-compose-refs\";\nimport {createContextScope as $98Iye$createContextScope} from \"@radix-ui/react-context\";\nimport {useId as $98Iye$useId} from \"@radix-ui/react-id\";\nimport {Primitive as $98Iye$Primitive} from \"@radix-ui/react-primitive\";\nimport {useCallbackRef as $98Iye$useCallbackRef} from \"@radix-ui/react-use-callback-ref\";\nimport {useControllableState as $98Iye$useControllableState} from \"@radix-ui/react-use-controllable-state\";\nimport {useDirection as $98Iye$useDirection} from \"@radix-ui/react-direction\";\n\n\n\n\n\n\n\n\n\n\n\n\nconst $d7bdfb9eb0fdf311$var$ENTRY_FOCUS = 'rovingFocusGroup.onEntryFocus';\nconst $d7bdfb9eb0fdf311$var$EVENT_OPTIONS = {\n bubbles: false,\n cancelable: true\n};\n/* -------------------------------------------------------------------------------------------------\n * RovingFocusGroup\n * -----------------------------------------------------------------------------------------------*/ const $d7bdfb9eb0fdf311$var$GROUP_NAME = 'RovingFocusGroup';\nconst [$d7bdfb9eb0fdf311$var$Collection, $d7bdfb9eb0fdf311$var$useCollection, $d7bdfb9eb0fdf311$var$createCollectionScope] = $98Iye$createCollection($d7bdfb9eb0fdf311$var$GROUP_NAME);\nconst [$d7bdfb9eb0fdf311$var$createRovingFocusGroupContext, $d7bdfb9eb0fdf311$export$c7109489551a4f4] = $98Iye$createContextScope($d7bdfb9eb0fdf311$var$GROUP_NAME, [\n $d7bdfb9eb0fdf311$var$createCollectionScope\n]);\nconst [$d7bdfb9eb0fdf311$var$RovingFocusProvider, $d7bdfb9eb0fdf311$var$useRovingFocusContext] = $d7bdfb9eb0fdf311$var$createRovingFocusGroupContext($d7bdfb9eb0fdf311$var$GROUP_NAME);\nconst $d7bdfb9eb0fdf311$export$8699f7c8af148338 = /*#__PURE__*/ $98Iye$forwardRef((props, forwardedRef)=>{\n return /*#__PURE__*/ $98Iye$createElement($d7bdfb9eb0fdf311$var$Collection.Provider, {\n scope: props.__scopeRovingFocusGroup\n }, /*#__PURE__*/ $98Iye$createElement($d7bdfb9eb0fdf311$var$Collection.Slot, {\n scope: props.__scopeRovingFocusGroup\n }, /*#__PURE__*/ $98Iye$createElement($d7bdfb9eb0fdf311$var$RovingFocusGroupImpl, $98Iye$babelruntimehelpersesmextends({}, props, {\n ref: forwardedRef\n }))));\n});\n/*#__PURE__*/ Object.assign($d7bdfb9eb0fdf311$export$8699f7c8af148338, {\n displayName: $d7bdfb9eb0fdf311$var$GROUP_NAME\n});\n/* -----------------------------------------------------------------------------------------------*/ const $d7bdfb9eb0fdf311$var$RovingFocusGroupImpl = /*#__PURE__*/ $98Iye$forwardRef((props, forwardedRef)=>{\n const { __scopeRovingFocusGroup: __scopeRovingFocusGroup , orientation: orientation , loop: loop = false , dir: dir , currentTabStopId: currentTabStopIdProp , defaultCurrentTabStopId: defaultCurrentTabStopId , onCurrentTabStopIdChange: onCurrentTabStopIdChange , onEntryFocus: onEntryFocus , ...groupProps } = props;\n const ref = $98Iye$useRef(null);\n const composedRefs = $98Iye$useComposedRefs(forwardedRef, ref);\n const direction = $98Iye$useDirection(dir);\n const [currentTabStopId = null, setCurrentTabStopId] = $98Iye$useControllableState({\n prop: currentTabStopIdProp,\n defaultProp: defaultCurrentTabStopId,\n onChange: onCurrentTabStopIdChange\n });\n const [isTabbingBackOut, setIsTabbingBackOut] = $98Iye$useState(false);\n const handleEntryFocus = $98Iye$useCallbackRef(onEntryFocus);\n const getItems = $d7bdfb9eb0fdf311$var$useCollection(__scopeRovingFocusGroup);\n const isClickFocusRef = $98Iye$useRef(false);\n const [focusableItemsCount, setFocusableItemsCount] = $98Iye$useState(0);\n $98Iye$useEffect(()=>{\n const node = ref.current;\n if (node) {\n node.addEventListener($d7bdfb9eb0fdf311$var$ENTRY_FOCUS, handleEntryFocus);\n return ()=>node.removeEventListener($d7bdfb9eb0fdf311$var$ENTRY_FOCUS, handleEntryFocus)\n ;\n }\n }, [\n handleEntryFocus\n ]);\n return /*#__PURE__*/ $98Iye$createElement($d7bdfb9eb0fdf311$var$RovingFocusProvider, {\n scope: __scopeRovingFocusGroup,\n orientation: orientation,\n dir: direction,\n loop: loop,\n currentTabStopId: currentTabStopId,\n onItemFocus: $98Iye$useCallback((tabStopId)=>setCurrentTabStopId(tabStopId)\n , [\n setCurrentTabStopId\n ]),\n onItemShiftTab: $98Iye$useCallback(()=>setIsTabbingBackOut(true)\n , []),\n onFocusableItemAdd: $98Iye$useCallback(()=>setFocusableItemsCount((prevCount)=>prevCount + 1\n )\n , []),\n onFocusableItemRemove: $98Iye$useCallback(()=>setFocusableItemsCount((prevCount)=>prevCount - 1\n )\n , [])\n }, /*#__PURE__*/ $98Iye$createElement($98Iye$Primitive.div, $98Iye$babelruntimehelpersesmextends({\n tabIndex: isTabbingBackOut || focusableItemsCount === 0 ? -1 : 0,\n \"data-orientation\": orientation\n }, groupProps, {\n ref: composedRefs,\n style: {\n outline: 'none',\n ...props.style\n },\n onMouseDown: $98Iye$composeEventHandlers(props.onMouseDown, ()=>{\n isClickFocusRef.current = true;\n }),\n onFocus: $98Iye$composeEventHandlers(props.onFocus, (event)=>{\n // We normally wouldn't need this check, because we already check\n // that the focus is on the current target and not bubbling to it.\n // We do this because Safari doesn't focus buttons when clicked, and\n // instead, the wrapper will get focused and not through a bubbling event.\n const isKeyboardFocus = !isClickFocusRef.current;\n if (event.target === event.currentTarget && isKeyboardFocus && !isTabbingBackOut) {\n const entryFocusEvent = new CustomEvent($d7bdfb9eb0fdf311$var$ENTRY_FOCUS, $d7bdfb9eb0fdf311$var$EVENT_OPTIONS);\n event.currentTarget.dispatchEvent(entryFocusEvent);\n if (!entryFocusEvent.defaultPrevented) {\n const items = getItems().filter((item)=>item.focusable\n );\n const activeItem = items.find((item)=>item.active\n );\n const currentItem = items.find((item)=>item.id === currentTabStopId\n );\n const candidateItems = [\n activeItem,\n currentItem,\n ...items\n ].filter(Boolean);\n const candidateNodes = candidateItems.map((item)=>item.ref.current\n );\n $d7bdfb9eb0fdf311$var$focusFirst(candidateNodes);\n }\n }\n isClickFocusRef.current = false;\n }),\n onBlur: $98Iye$composeEventHandlers(props.onBlur, ()=>setIsTabbingBackOut(false)\n )\n })));\n});\n/* -------------------------------------------------------------------------------------------------\n * RovingFocusGroupItem\n * -----------------------------------------------------------------------------------------------*/ const $d7bdfb9eb0fdf311$var$ITEM_NAME = 'RovingFocusGroupItem';\nconst $d7bdfb9eb0fdf311$export$ab9df7c53fe8454 = /*#__PURE__*/ $98Iye$forwardRef((props, forwardedRef)=>{\n const { __scopeRovingFocusGroup: __scopeRovingFocusGroup , focusable: focusable = true , active: active = false , tabStopId: tabStopId , ...itemProps } = props;\n const autoId = $98Iye$useId();\n const id = tabStopId || autoId;\n const context = $d7bdfb9eb0fdf311$var$useRovingFocusContext($d7bdfb9eb0fdf311$var$ITEM_NAME, __scopeRovingFocusGroup);\n const isCurrentTabStop = context.currentTabStopId === id;\n const getItems = $d7bdfb9eb0fdf311$var$useCollection(__scopeRovingFocusGroup);\n const { onFocusableItemAdd: onFocusableItemAdd , onFocusableItemRemove: onFocusableItemRemove } = context;\n $98Iye$useEffect(()=>{\n if (focusable) {\n onFocusableItemAdd();\n return ()=>onFocusableItemRemove()\n ;\n }\n }, [\n focusable,\n onFocusableItemAdd,\n onFocusableItemRemove\n ]);\n return /*#__PURE__*/ $98Iye$createElement($d7bdfb9eb0fdf311$var$Collection.ItemSlot, {\n scope: __scopeRovingFocusGroup,\n id: id,\n focusable: focusable,\n active: active\n }, /*#__PURE__*/ $98Iye$createElement($98Iye$Primitive.span, $98Iye$babelruntimehelpersesmextends({\n tabIndex: isCurrentTabStop ? 0 : -1,\n \"data-orientation\": context.orientation\n }, itemProps, {\n ref: forwardedRef,\n onMouseDown: $98Iye$composeEventHandlers(props.onMouseDown, (event)=>{\n // We prevent focusing non-focusable items on `mousedown`.\n // Even though the item has tabIndex={-1}, that only means take it out of the tab order.\n if (!focusable) event.preventDefault(); // Safari doesn't focus a button when clicked so we run our logic on mousedown also\n else context.onItemFocus(id);\n }),\n onFocus: $98Iye$composeEventHandlers(props.onFocus, ()=>context.onItemFocus(id)\n ),\n onKeyDown: $98Iye$composeEventHandlers(props.onKeyDown, (event)=>{\n if (event.key === 'Tab' && event.shiftKey) {\n context.onItemShiftTab();\n return;\n }\n if (event.target !== event.currentTarget) return;\n const focusIntent = $d7bdfb9eb0fdf311$var$getFocusIntent(event, context.orientation, context.dir);\n if (focusIntent !== undefined) {\n event.preventDefault();\n const items = getItems().filter((item)=>item.focusable\n );\n let candidateNodes = items.map((item)=>item.ref.current\n );\n if (focusIntent === 'last') candidateNodes.reverse();\n else if (focusIntent === 'prev' || focusIntent === 'next') {\n if (focusIntent === 'prev') candidateNodes.reverse();\n const currentIndex = candidateNodes.indexOf(event.currentTarget);\n candidateNodes = context.loop ? $d7bdfb9eb0fdf311$var$wrapArray(candidateNodes, currentIndex + 1) : candidateNodes.slice(currentIndex + 1);\n }\n /**\n * Imperative focus during keydown is risky so we prevent React's batching updates\n * to avoid potential bugs. See: https://github.com/facebook/react/issues/20332\n */ setTimeout(()=>$d7bdfb9eb0fdf311$var$focusFirst(candidateNodes)\n );\n }\n })\n })));\n});\n/*#__PURE__*/ Object.assign($d7bdfb9eb0fdf311$export$ab9df7c53fe8454, {\n displayName: $d7bdfb9eb0fdf311$var$ITEM_NAME\n});\n/* -----------------------------------------------------------------------------------------------*/ // prettier-ignore\nconst $d7bdfb9eb0fdf311$var$MAP_KEY_TO_FOCUS_INTENT = {\n ArrowLeft: 'prev',\n ArrowUp: 'prev',\n ArrowRight: 'next',\n ArrowDown: 'next',\n PageUp: 'first',\n Home: 'first',\n PageDown: 'last',\n End: 'last'\n};\nfunction $d7bdfb9eb0fdf311$var$getDirectionAwareKey(key, dir) {\n if (dir !== 'rtl') return key;\n return key === 'ArrowLeft' ? 'ArrowRight' : key === 'ArrowRight' ? 'ArrowLeft' : key;\n}\nfunction $d7bdfb9eb0fdf311$var$getFocusIntent(event, orientation, dir) {\n const key = $d7bdfb9eb0fdf311$var$getDirectionAwareKey(event.key, dir);\n if (orientation === 'vertical' && [\n 'ArrowLeft',\n 'ArrowRight'\n ].includes(key)) return undefined;\n if (orientation === 'horizontal' && [\n 'ArrowUp',\n 'ArrowDown'\n ].includes(key)) return undefined;\n return $d7bdfb9eb0fdf311$var$MAP_KEY_TO_FOCUS_INTENT[key];\n}\nfunction $d7bdfb9eb0fdf311$var$focusFirst(candidates) {\n const PREVIOUSLY_FOCUSED_ELEMENT = document.activeElement;\n for (const candidate of candidates){\n // if focus is already where we want to go, we don't want to keep going through the candidates\n if (candidate === PREVIOUSLY_FOCUSED_ELEMENT) return;\n candidate.focus();\n if (document.activeElement !== PREVIOUSLY_FOCUSED_ELEMENT) return;\n }\n}\n/**\n * Wraps an array around itself at a given start index\n * Example: `wrapArray(['a', 'b', 'c', 'd'], 2) === ['c', 'd', 'a', 'b']`\n */ function $d7bdfb9eb0fdf311$var$wrapArray(array, startIndex) {\n return array.map((_, index)=>array[(startIndex + index) % array.length]\n );\n}\nconst $d7bdfb9eb0fdf311$export$be92b6f5f03c0fe9 = $d7bdfb9eb0fdf311$export$8699f7c8af148338;\nconst $d7bdfb9eb0fdf311$export$6d08773d2e66f8f2 = $d7bdfb9eb0fdf311$export$ab9df7c53fe8454;\n\n\n\n\nexport {$d7bdfb9eb0fdf311$export$c7109489551a4f4 as createRovingFocusGroupScope, $d7bdfb9eb0fdf311$export$8699f7c8af148338 as RovingFocusGroup, $d7bdfb9eb0fdf311$export$ab9df7c53fe8454 as RovingFocusGroupItem, $d7bdfb9eb0fdf311$export$be92b6f5f03c0fe9 as Root, $d7bdfb9eb0fdf311$export$6d08773d2e66f8f2 as Item};\n//# sourceMappingURL=index.mjs.map\n"],"names":["$98Iye$createCollection","$98Iye$createContextScope","$98Iye$forwardRef","$98Iye$createElement","$98Iye$babelruntimehelpersesmextends","$98Iye$useRef","$98Iye$useComposedRefs","$98Iye$useDirection","$98Iye$useControllableState","$98Iye$useState","$98Iye$useCallbackRef","$98Iye$useEffect","$98Iye$useCallback","$98Iye$Primitive","$98Iye$composeEventHandlers","$98Iye$useId"],"mappings":";;;;;;;;;;;;AAuBA,MAAM,iCAAiC,GAAG,+BAA+B,CAAC;AAC1E,MAAM,mCAAmC,GAAG;AAC5C,IAAI,OAAO,EAAE,KAAK;AAClB,IAAI,UAAU,EAAE,IAAI;AACpB,CAAC,CAAC;AACF;AACA;AACA,qGAAqG,MAAM,gCAAgC,GAAG,kBAAkB,CAAC;AACjK,MAAM,CAAC,gCAAgC,EAAE,mCAAmC,EAAE,2CAA2C,CAAC,GAAGA,yCAAuB,CAAC,gCAAgC,CAAC,CAAC;AAClL,MAAC,CAAC,mDAAmD,EAAE,wCAAwC,CAAC,GAAGC,wCAAyB,CAAC,gCAAgC,EAAE;AACpK,IAAI,2CAA2C;AAC/C,CAAC,EAAE;AACH,MAAM,CAAC,yCAAyC,EAAE,2CAA2C,CAAC,GAAG,mDAAmD,CAAC,gCAAgC,CAAC,CAAC;AAClL,MAAC,yCAAyC,iBAAiBC,UAAiB,CAAC,CAAC,KAAK,EAAE,YAAY,GAAG;AACzG,IAAI,qBAAqBC,aAAoB,CAAC,gCAAgC,CAAC,QAAQ,EAAE;AACzF,QAAQ,KAAK,EAAE,KAAK,CAAC,uBAAuB;AAC5C,KAAK,gBAAgBA,aAAoB,CAAC,gCAAgC,CAAC,IAAI,EAAE;AACjF,QAAQ,KAAK,EAAE,KAAK,CAAC,uBAAuB;AAC5C,KAAK,gBAAgBA,aAAoB,CAAC,0CAA0C,EAAEC,QAAoC,CAAC,EAAE,EAAE,KAAK,EAAE;AACtI,QAAQ,GAAG,EAAE,YAAY;AACzB,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC;AACV,CAAC,EAAE;AAIH,qGAAqG,M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AQ,CAAC,aAAa,KAAK,0BAA0B,EAAE,OAAO;AAC1E,KAAK;AACL,CAAC;AACD;AACA;AACA;AACA,IAAI,SAAS,+BAA+B,CAAC,KAAK,EAAE,UAAU,EAAE;AAChE,IAAI,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,EAAE,KAAK,GAAG,KAAK,CAAC,CAAC,UAAU,GAAG,KAAK,IAAI,KAAK,CAAC,MAAM,CAAC;AAC3E,KAAK,CAAC;AACN,CAAC;AACI,MAAC,yCAAyC,GAAG,0CAA0C;AACvF,MAAC,yCAAyC,GAAG;;;;"}
@@ -1,14 +1,14 @@
1
1
  'use client';
2
2
  import * as React from 'react';
3
- import { Primitive } from '../../react-primitive/dist/index.mjs.js';
4
- import { Presence } from '../../react-presence/dist/index.mjs.js';
5
- import { createContextScope } from '../../react-context/dist/index.mjs.js';
6
- import { useComposedRefs } from '../../react-compose-refs/dist/index.mjs.js';
7
- import { useCallbackRef } from '../../react-use-callback-ref/dist/index.mjs.js';
8
- import { useDirection } from '../../react-direction/dist/index.mjs.js';
9
- import { useLayoutEffect as useLayoutEffect2 } from '../../react-use-layout-effect/dist/index.mjs.js';
10
- import { clamp } from '../../number/dist/index.mjs.js';
11
- import { composeEventHandlers } from '../../primitive/dist/index.mjs.js';
3
+ import { Primitive } from '../node_modules/@radix-ui/react-primitive/dist/index.mjs.js';
4
+ import { Presence } from '../node_modules/@radix-ui/react-presence/dist/index.mjs.js';
5
+ import { createContextScope } from '../node_modules/@radix-ui/react-context/dist/index.mjs.js';
6
+ import { useComposedRefs } from '../node_modules/@radix-ui/react-compose-refs/dist/index.mjs.js';
7
+ import { useCallbackRef } from '../node_modules/@radix-ui/react-use-callback-ref/dist/index.mjs.js';
8
+ import { useDirection } from '../node_modules/@radix-ui/react-direction/dist/index.mjs.js';
9
+ import { useLayoutEffect as useLayoutEffect2 } from '../node_modules/@radix-ui/react-use-layout-effect/dist/index.mjs.js';
10
+ import { clamp } from '../node_modules/@radix-ui/number/dist/index.mjs.js';
11
+ import { composeEventHandlers } from '../node_modules/@radix-ui/primitive/dist/index.mjs.js';
12
12
  import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
13
13
 
14
14
  function useStateMachine(initialState, machine) {
@@ -0,0 +1,7 @@
1
+ // packages/core/number/src/number.ts
2
+ function clamp(value, [min, max]) {
3
+ return Math.min(max, Math.max(min, value));
4
+ }
5
+
6
+ export { clamp };
7
+ //# sourceMappingURL=index.mjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.mjs.js","sources":["../../../../../../../../node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/number/dist/index.mjs"],"sourcesContent":["// packages/core/number/src/number.ts\nfunction clamp(value, [min, max]) {\n return Math.min(max, Math.max(min, value));\n}\nexport {\n clamp\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":[],"mappings":"AAAA;AACA,SAAS,KAAK,CAAC,KAAK,EAAE,CAAC,GAAG,EAAE,GAAG,CAAC,EAAE;AAClC,EAAE,OAAO,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,IAAI,CAAC,GAAG,CAAC,GAAG,EAAE,KAAK,CAAC,CAAC,CAAC;AAC7C;;;;"}
@@ -0,0 +1,12 @@
1
+ // src/primitive.tsx
2
+ function composeEventHandlers(originalEventHandler, ourEventHandler, { checkForDefaultPrevented = true } = {}) {
3
+ return function handleEvent(event) {
4
+ originalEventHandler?.(event);
5
+ if (checkForDefaultPrevented === false || !event.defaultPrevented) {
6
+ return ourEventHandler?.(event);
7
+ }
8
+ };
9
+ }
10
+
11
+ export { composeEventHandlers };
12
+ //# sourceMappingURL=index.mjs.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.mjs.js","sources":["../../../../../../../../node_modules/@radix-ui/react-scroll-area/node_modules/@radix-ui/primitive/dist/index.mjs"],"sourcesContent":["// src/primitive.tsx\nvar canUseDOM = !!(typeof window !== \"undefined\" && window.document && window.document.createElement);\nfunction composeEventHandlers(originalEventHandler, ourEventHandler, { checkForDefaultPrevented = true } = {}) {\n return function handleEvent(event) {\n originalEventHandler?.(event);\n if (checkForDefaultPrevented === false || !event.defaultPrevented) {\n return ourEventHandler?.(event);\n }\n };\n}\nfunction getOwnerWindow(element) {\n if (!canUseDOM) {\n throw new Error(\"Cannot access window outside of the DOM\");\n }\n return element?.ownerDocument?.defaultView ?? window;\n}\nfunction getOwnerDocument(element) {\n if (!canUseDOM) {\n throw new Error(\"Cannot access document outside of the DOM\");\n }\n return element?.ownerDocument ?? document;\n}\nfunction getActiveElement(node, activeDescendant = false) {\n const { activeElement } = getOwnerDocument(node);\n if (!activeElement?.nodeName) {\n return null;\n }\n if (isFrame(activeElement) && activeElement.contentDocument) {\n return getActiveElement(activeElement.contentDocument.body, activeDescendant);\n }\n if (activeDescendant) {\n const id = activeElement.getAttribute(\"aria-activedescendant\");\n if (id) {\n const element = getOwnerDocument(activeElement).getElementById(id);\n if (element) {\n return element;\n }\n }\n }\n return activeElement;\n}\nfunction isFrame(element) {\n return element.tagName === \"IFRAME\";\n}\nexport {\n canUseDOM,\n composeEventHandlers,\n getActiveElement,\n getOwnerDocument,\n getOwnerWindow,\n isFrame\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":[],"mappings":"AAAA;AAEA,SAAS,oBAAoB,CAAC,oBAAoB,EAAE,eAAe,EAAE,EAAE,wBAAwB,GAAG,IAAI,EAAE,GAAG,EAAE,EAAE;AAC/G,EAAE,OAAO,SAAS,WAAW,CAAC,KAAK,EAAE;AACrC,IAAI,oBAAoB,GAAG,KAAK,CAAC,CAAC;AAClC,IAAI,IAAI,wBAAwB,KAAK,KAAK,IAAI,CAAC,KAAK,CAAC,gBAAgB,EAAE;AACvE,MAAM,OAAO,eAAe,GAAG,KAAK,CAAC,CAAC;AACtC,KAAK;AACL,GAAG,CAAC;AACJ;;;;"}