@lotte-innovate/ui-component-test 0.1.56 → 0.1.57

Sign up to get free protection for your applications and to get access to all the features.
Files changed (326) hide show
  1. package/dist/lib/Typography/Header/index.mjs +1 -1
  2. package/dist/lib/Typography/Header/index.mjs.map +1 -1
  3. package/dist/lib/Typography/Text/index.mjs +1 -1
  4. package/dist/lib/Typography/Text/index.mjs.map +1 -1
  5. package/dist/lib/components/Accordion/index.d.ts +1 -1
  6. package/dist/lib/components/Accordion/index.mjs +1 -1
  7. package/dist/lib/components/Accordion/index.mjs.map +1 -1
  8. package/dist/lib/components/AlertDialog/AlertDialogAction.mjs +1 -1
  9. package/dist/lib/components/AlertDialog/AlertDialogAction.mjs.map +1 -1
  10. package/dist/lib/components/AlertDialog/AlertDialogCancel.mjs +1 -1
  11. package/dist/lib/components/AlertDialog/AlertDialogCancel.mjs.map +1 -1
  12. package/dist/lib/components/AlertDialog/AlertDialogContent.mjs +1 -1
  13. package/dist/lib/components/AlertDialog/AlertDialogContent.mjs.map +1 -1
  14. package/dist/lib/components/AlertDialog/AlertDialogDescription.mjs +1 -1
  15. package/dist/lib/components/AlertDialog/AlertDialogDescription.mjs.map +1 -1
  16. package/dist/lib/components/AlertDialog/AlertDialogTitle.mjs +1 -1
  17. package/dist/lib/components/AlertDialog/AlertDialogTitle.mjs.map +1 -1
  18. package/dist/lib/components/AlertDialog/AlertDialogTrigger.mjs +1 -1
  19. package/dist/lib/components/AlertDialog/AlertDialogTrigger.mjs.map +1 -1
  20. package/dist/lib/components/AspectRatio/index.mjs +1 -1
  21. package/dist/lib/components/AspectRatio/index.mjs.map +1 -1
  22. package/dist/lib/components/Avatar/index.mjs +1 -1
  23. package/dist/lib/components/Avatar/index.mjs.map +1 -1
  24. package/dist/lib/components/Badge/index.mjs +1 -1
  25. package/dist/lib/components/Badge/index.mjs.map +1 -1
  26. package/dist/lib/components/BarChart/index.d.ts +1 -5
  27. package/dist/lib/components/BarChart/index.mjs +1 -1
  28. package/dist/lib/components/BarChart/index.mjs.map +1 -1
  29. package/dist/lib/components/BubbleChart/index.mjs +1 -1
  30. package/dist/lib/components/BubbleChart/index.mjs.map +1 -1
  31. package/dist/lib/components/Button/index.mjs +1 -1
  32. package/dist/lib/components/Button/index.mjs.map +1 -1
  33. package/dist/lib/components/Callout/CalloutIcon.mjs +1 -1
  34. package/dist/lib/components/Callout/CalloutIcon.mjs.map +1 -1
  35. package/dist/lib/components/Callout/CalloutRoot.mjs +1 -1
  36. package/dist/lib/components/Callout/CalloutRoot.mjs.map +1 -1
  37. package/dist/lib/components/Callout/CalloutText.mjs +1 -1
  38. package/dist/lib/components/Callout/CalloutText.mjs.map +1 -1
  39. package/dist/lib/components/Card/index.mjs +1 -1
  40. package/dist/lib/components/Card/index.mjs.map +1 -1
  41. package/dist/lib/components/Checkbox/index.mjs +1 -1
  42. package/dist/lib/components/Checkbox/index.mjs.map +1 -1
  43. package/dist/lib/components/CheckboxCard/index.mjs +1 -1
  44. package/dist/lib/components/CheckboxCard/index.mjs.map +1 -1
  45. package/dist/lib/components/CheckboxGroup/CheckboxGroupRoot.mjs +1 -1
  46. package/dist/lib/components/CheckboxGroup/CheckboxGroupRoot.mjs.map +1 -1
  47. package/dist/lib/components/ContextMenu/ContextMenuContent.mjs +1 -1
  48. package/dist/lib/components/ContextMenu/ContextMenuContent.mjs.map +1 -1
  49. package/dist/lib/components/ContextMenu/ContextMenuItem.mjs +1 -1
  50. package/dist/lib/components/ContextMenu/ContextMenuItem.mjs.map +1 -1
  51. package/dist/lib/components/ContextMenu/ContextMenuItemIndicator.mjs +1 -1
  52. package/dist/lib/components/ContextMenu/ContextMenuItemIndicator.mjs.map +1 -1
  53. package/dist/lib/components/ContextMenu/ContextMenuLabel.mjs +1 -1
  54. package/dist/lib/components/ContextMenu/ContextMenuLabel.mjs.map +1 -1
  55. package/dist/lib/components/ContextMenu/ContextMenuSubContent.mjs +1 -1
  56. package/dist/lib/components/ContextMenu/ContextMenuSubContent.mjs.map +1 -1
  57. package/dist/lib/components/DataList/DataListItem.mjs +1 -1
  58. package/dist/lib/components/DataList/DataListItem.mjs.map +1 -1
  59. package/dist/lib/components/DataList/DataListLabel.mjs +1 -1
  60. package/dist/lib/components/DataList/DataListLabel.mjs.map +1 -1
  61. package/dist/lib/components/DataList/DataListRoot.mjs +1 -1
  62. package/dist/lib/components/DataList/DataListRoot.mjs.map +1 -1
  63. package/dist/lib/components/DataList/DataListValue.mjs +1 -1
  64. package/dist/lib/components/DataList/DataListValue.mjs.map +1 -1
  65. package/dist/lib/components/Dialog/DialogAction.mjs +1 -1
  66. package/dist/lib/components/Dialog/DialogAction.mjs.map +1 -1
  67. package/dist/lib/components/Dialog/DialogCancel.mjs +1 -1
  68. package/dist/lib/components/Dialog/DialogCancel.mjs.map +1 -1
  69. package/dist/lib/components/Dialog/DialogContent.mjs +1 -1
  70. package/dist/lib/components/Dialog/DialogContent.mjs.map +1 -1
  71. package/dist/lib/components/Dialog/DialogDescription.mjs +1 -1
  72. package/dist/lib/components/Dialog/DialogDescription.mjs.map +1 -1
  73. package/dist/lib/components/Dialog/DialogRoot.d.ts +1 -4
  74. package/dist/lib/components/Dialog/DialogSlot.mjs +1 -1
  75. package/dist/lib/components/Dialog/DialogSlot.mjs.map +1 -1
  76. package/dist/lib/components/Dialog/DialogTitle.mjs +1 -1
  77. package/dist/lib/components/Dialog/DialogTitle.mjs.map +1 -1
  78. package/dist/lib/components/DoughnutChart/index.mjs +1 -1
  79. package/dist/lib/components/DoughnutChart/index.mjs.map +1 -1
  80. package/dist/lib/components/DropdownMenu/DropdonMenuSubContent.mjs +1 -1
  81. package/dist/lib/components/DropdownMenu/DropdonMenuSubContent.mjs.map +1 -1
  82. package/dist/lib/components/DropdownMenu/DropdownMenuContent.mjs +1 -1
  83. package/dist/lib/components/DropdownMenu/DropdownMenuContent.mjs.map +1 -1
  84. package/dist/lib/components/DropdownMenu/DropdownMenuItem.mjs +1 -1
  85. package/dist/lib/components/DropdownMenu/DropdownMenuItem.mjs.map +1 -1
  86. package/dist/lib/components/DropdownMenu/DropdownMenuItemIndicator.mjs +1 -1
  87. package/dist/lib/components/DropdownMenu/DropdownMenuItemIndicator.mjs.map +1 -1
  88. package/dist/lib/components/DropdownMenu/DropdownMenuLable.mjs +1 -1
  89. package/dist/lib/components/DropdownMenu/DropdownMenuLable.mjs.map +1 -1
  90. package/dist/lib/components/DropdownMenu/DropdownMenuRoot.d.ts +1 -2
  91. package/dist/lib/components/DropdownMenu/DropdownMenuTrigger.mjs +1 -1
  92. package/dist/lib/components/DropdownMenu/DropdownMenuTrigger.mjs.map +1 -1
  93. package/dist/lib/components/HoverCard/HoverCardContent.mjs +1 -1
  94. package/dist/lib/components/HoverCard/HoverCardContent.mjs.map +1 -1
  95. package/dist/lib/components/IconButton/index.d.ts +2 -2
  96. package/dist/lib/components/IconButton/index.mjs +1 -1
  97. package/dist/lib/components/IconButton/index.mjs.map +1 -1
  98. package/dist/lib/components/Inset/index.mjs +1 -1
  99. package/dist/lib/components/Inset/index.mjs.map +1 -1
  100. package/dist/lib/components/Label/index.mjs +1 -1
  101. package/dist/lib/components/Label/index.mjs.map +1 -1
  102. package/dist/lib/components/LineChart/index.mjs +1 -1
  103. package/dist/lib/components/LineChart/index.mjs.map +1 -1
  104. package/dist/lib/components/Menubar/MenubarContent.mjs +1 -1
  105. package/dist/lib/components/Menubar/MenubarContent.mjs.map +1 -1
  106. package/dist/lib/components/Menubar/MenubarItem.mjs +1 -1
  107. package/dist/lib/components/Menubar/MenubarItem.mjs.map +1 -1
  108. package/dist/lib/components/Menubar/MenubarItemIndicator.mjs +1 -1
  109. package/dist/lib/components/Menubar/MenubarItemIndicator.mjs.map +1 -1
  110. package/dist/lib/components/Menubar/MenubarRoot.mjs +1 -1
  111. package/dist/lib/components/Menubar/MenubarRoot.mjs.map +1 -1
  112. package/dist/lib/components/Menubar/MenubarSubContent.mjs +1 -1
  113. package/dist/lib/components/Menubar/MenubarSubContent.mjs.map +1 -1
  114. package/dist/lib/components/Menubar/MenubarTrigger.mjs +1 -1
  115. package/dist/lib/components/Menubar/MenubarTrigger.mjs.map +1 -1
  116. package/dist/lib/components/NavigationMenu/NavigationMenuContent.mjs +1 -1
  117. package/dist/lib/components/NavigationMenu/NavigationMenuContent.mjs.map +1 -1
  118. package/dist/lib/components/NavigationMenu/NavigationMenuLink.mjs +1 -1
  119. package/dist/lib/components/NavigationMenu/NavigationMenuLink.mjs.map +1 -1
  120. package/dist/lib/components/NavigationMenu/NavigationMenuList.mjs +1 -1
  121. package/dist/lib/components/NavigationMenu/NavigationMenuList.mjs.map +1 -1
  122. package/dist/lib/components/NavigationMenu/NavigationMenuTrigger.mjs +1 -1
  123. package/dist/lib/components/NavigationMenu/NavigationMenuTrigger.mjs.map +1 -1
  124. package/dist/lib/components/NavigationMenu/NavigationMenuViewport.mjs +1 -1
  125. package/dist/lib/components/NavigationMenu/NavigationMenuViewport.mjs.map +1 -1
  126. package/dist/lib/components/PieChart/index.mjs +1 -1
  127. package/dist/lib/components/PieChart/index.mjs.map +1 -1
  128. package/dist/lib/components/Popover/PopoverClose.mjs +1 -1
  129. package/dist/lib/components/Popover/PopoverClose.mjs.map +1 -1
  130. package/dist/lib/components/Popover/PopoverContent.mjs +1 -1
  131. package/dist/lib/components/Popover/PopoverContent.mjs.map +1 -1
  132. package/dist/lib/components/Popover/PopoverRoot.d.ts +1 -2
  133. package/dist/lib/components/Progress/index.mjs +1 -1
  134. package/dist/lib/components/Progress/index.mjs.map +1 -1
  135. package/dist/lib/components/RadarChart/index.mjs +1 -1
  136. package/dist/lib/components/RadarChart/index.mjs.map +1 -1
  137. package/dist/lib/components/Radio/index.mjs +1 -1
  138. package/dist/lib/components/Radio/index.mjs.map +1 -1
  139. package/dist/lib/components/RadioCards/RadioCardsItem.mjs +1 -1
  140. package/dist/lib/components/RadioCards/RadioCardsItem.mjs.map +1 -1
  141. package/dist/lib/components/RadioCards/RadioCardsRoot.mjs +1 -1
  142. package/dist/lib/components/RadioCards/RadioCardsRoot.mjs.map +1 -1
  143. package/dist/lib/components/RadioGroup/RadioGroupItem.mjs +1 -1
  144. package/dist/lib/components/RadioGroup/RadioGroupItem.mjs.map +1 -1
  145. package/dist/lib/components/RadioGroup/RadioGroupRoot.mjs +1 -1
  146. package/dist/lib/components/RadioGroup/RadioGroupRoot.mjs.map +1 -1
  147. package/dist/lib/components/SegmentedControl/SegmentedControlRoot.mjs +1 -1
  148. package/dist/lib/components/SegmentedControl/SegmentedControlRoot.mjs.map +1 -1
  149. package/dist/lib/components/Select/index.mjs +1 -1
  150. package/dist/lib/components/Select/index.mjs.map +1 -1
  151. package/dist/lib/components/Separator/index.mjs +1 -1
  152. package/dist/lib/components/Separator/index.mjs.map +1 -1
  153. package/dist/lib/components/Skeleton/index.mjs +1 -1
  154. package/dist/lib/components/Skeleton/index.mjs.map +1 -1
  155. package/dist/lib/components/Slider/index.mjs +1 -1
  156. package/dist/lib/components/Slider/index.mjs.map +1 -1
  157. package/dist/lib/components/Spinner/index.mjs +1 -1
  158. package/dist/lib/components/Spinner/index.mjs.map +1 -1
  159. package/dist/lib/components/TabNav/index.mjs +1 -1
  160. package/dist/lib/components/TabNav/index.mjs.map +1 -1
  161. package/dist/lib/components/Table/index.mjs +1 -1
  162. package/dist/lib/components/Table/index.mjs.map +1 -1
  163. package/dist/lib/components/Tabs/index.mjs +1 -1
  164. package/dist/lib/components/Tabs/index.mjs.map +1 -1
  165. package/dist/lib/components/TextArea/index.mjs +1 -1
  166. package/dist/lib/components/TextArea/index.mjs.map +1 -1
  167. package/dist/lib/components/TextField/index.mjs +1 -1
  168. package/dist/lib/components/TextField/index.mjs.map +1 -1
  169. package/dist/lib/components/Toast/ToastActionButton.mjs +1 -1
  170. package/dist/lib/components/Toast/ToastActionButton.mjs.map +1 -1
  171. package/dist/lib/components/Toast/ToastDescription.mjs +1 -1
  172. package/dist/lib/components/Toast/ToastDescription.mjs.map +1 -1
  173. package/dist/lib/components/Toast/ToastRoot.mjs +1 -1
  174. package/dist/lib/components/Toast/ToastRoot.mjs.map +1 -1
  175. package/dist/lib/components/Toast/ToastTitle.mjs +1 -1
  176. package/dist/lib/components/Toast/ToastTitle.mjs.map +1 -1
  177. package/dist/lib/components/Toggle/ToggleWithText.mjs +1 -1
  178. package/dist/lib/components/Toggle/ToggleWithText.mjs.map +1 -1
  179. package/dist/lib/components/Toggle/index.mjs +1 -1
  180. package/dist/lib/components/Toggle/index.mjs.map +1 -1
  181. package/dist/lib/components/ToggleGroup/ToggleGroupItem.mjs +1 -1
  182. package/dist/lib/components/ToggleGroup/ToggleGroupItem.mjs.map +1 -1
  183. package/dist/lib/components/ToggleGroup/ToggleGroupRoot.mjs +1 -1
  184. package/dist/lib/components/ToggleGroup/ToggleGroupRoot.mjs.map +1 -1
  185. package/dist/lib/components/ToggleSwitch/index.mjs +1 -1
  186. package/dist/lib/components/ToggleSwitch/index.mjs.map +1 -1
  187. package/dist/lib/components/Tooltip/index.mjs +1 -1
  188. package/dist/lib/components/Tooltip/index.mjs.map +1 -1
  189. package/dist/lib/utils/utils.mjs +1 -1
  190. package/dist/lib/utils/utils.mjs.map +1 -1
  191. package/dist/node_modules/@radix-ui/react-dialog/dist/index.mjs +1 -1
  192. package/dist/node_modules/@radix-ui/react-dialog/dist/index.mjs.map +1 -1
  193. package/dist/node_modules/@radix-ui/react-menu/dist/index.mjs +1 -1
  194. package/dist/node_modules/@radix-ui/react-menu/dist/index.mjs.map +1 -1
  195. package/dist/node_modules/@radix-ui/react-select/dist/index.mjs +1 -1
  196. package/dist/node_modules/@radix-ui/react-select/dist/index.mjs.map +1 -1
  197. package/dist/node_modules/@radix-ui/themes/dist/esm/components/callout.mjs +1 -1
  198. package/dist/node_modules/@radix-ui/themes/dist/esm/components/callout.mjs.map +1 -1
  199. package/dist/node_modules/@radix-ui/themes/dist/esm/components/checkbox-group.mjs +1 -1
  200. package/dist/node_modules/@radix-ui/themes/dist/esm/components/checkbox-group.mjs.map +1 -1
  201. package/dist/node_modules/@radix-ui/themes/dist/esm/components/data-list.mjs +1 -1
  202. package/dist/node_modules/@radix-ui/themes/dist/esm/components/data-list.mjs.map +1 -1
  203. package/dist/node_modules/@radix-ui/themes/dist/esm/components/dialog.mjs +1 -1
  204. package/dist/node_modules/@radix-ui/themes/dist/esm/components/dialog.mjs.map +1 -1
  205. package/dist/node_modules/@radix-ui/themes/dist/esm/components/flex.mjs +1 -1
  206. package/dist/node_modules/@radix-ui/themes/dist/esm/components/flex.mjs.map +1 -1
  207. package/dist/node_modules/@radix-ui/themes/dist/esm/components/grid.mjs +1 -1
  208. package/dist/node_modules/@radix-ui/themes/dist/esm/components/grid.mjs.map +1 -1
  209. package/dist/node_modules/@radix-ui/themes/dist/esm/components/heading.mjs +1 -1
  210. package/dist/node_modules/@radix-ui/themes/dist/esm/components/heading.mjs.map +1 -1
  211. package/dist/node_modules/@radix-ui/themes/dist/esm/components/hover-card.mjs +1 -1
  212. package/dist/node_modules/@radix-ui/themes/dist/esm/components/hover-card.mjs.map +1 -1
  213. package/dist/node_modules/@radix-ui/themes/dist/esm/components/inset.mjs +1 -1
  214. package/dist/node_modules/@radix-ui/themes/dist/esm/components/inset.mjs.map +1 -1
  215. package/dist/node_modules/@radix-ui/themes/dist/esm/components/popover.mjs +1 -1
  216. package/dist/node_modules/@radix-ui/themes/dist/esm/components/popover.mjs.map +1 -1
  217. package/dist/node_modules/@radix-ui/themes/dist/esm/components/progress.mjs +1 -1
  218. package/dist/node_modules/@radix-ui/themes/dist/esm/components/progress.mjs.map +1 -1
  219. package/dist/node_modules/@radix-ui/themes/dist/esm/components/radio-cards.mjs +1 -1
  220. package/dist/node_modules/@radix-ui/themes/dist/esm/components/radio-cards.mjs.map +1 -1
  221. package/dist/node_modules/@radix-ui/themes/dist/esm/components/radio-group.mjs +1 -1
  222. package/dist/node_modules/@radix-ui/themes/dist/esm/components/radio-group.mjs.map +1 -1
  223. package/dist/node_modules/@radix-ui/themes/dist/esm/components/radio.mjs +1 -1
  224. package/dist/node_modules/@radix-ui/themes/dist/esm/components/radio.mjs.map +1 -1
  225. package/dist/node_modules/@radix-ui/themes/dist/esm/components/scroll-area.mjs +1 -1
  226. package/dist/node_modules/@radix-ui/themes/dist/esm/components/scroll-area.mjs.map +1 -1
  227. package/dist/node_modules/@radix-ui/themes/dist/esm/components/segmented-control.mjs +1 -1
  228. package/dist/node_modules/@radix-ui/themes/dist/esm/components/segmented-control.mjs.map +1 -1
  229. package/dist/node_modules/@radix-ui/themes/dist/esm/components/select.mjs +1 -1
  230. package/dist/node_modules/@radix-ui/themes/dist/esm/components/select.mjs.map +1 -1
  231. package/dist/node_modules/@radix-ui/themes/dist/esm/components/separator.mjs +1 -1
  232. package/dist/node_modules/@radix-ui/themes/dist/esm/components/separator.mjs.map +1 -1
  233. package/dist/node_modules/@radix-ui/themes/dist/esm/components/skeleton.mjs +1 -1
  234. package/dist/node_modules/@radix-ui/themes/dist/esm/components/skeleton.mjs.map +1 -1
  235. package/dist/node_modules/@radix-ui/themes/dist/esm/components/slider.mjs +1 -1
  236. package/dist/node_modules/@radix-ui/themes/dist/esm/components/slider.mjs.map +1 -1
  237. package/dist/node_modules/@radix-ui/themes/dist/esm/components/spinner.mjs +1 -1
  238. package/dist/node_modules/@radix-ui/themes/dist/esm/components/spinner.mjs.map +1 -1
  239. package/dist/node_modules/@radix-ui/themes/dist/esm/components/switch.mjs +1 -1
  240. package/dist/node_modules/@radix-ui/themes/dist/esm/components/switch.mjs.map +1 -1
  241. package/dist/node_modules/@radix-ui/themes/dist/esm/components/tab-nav.mjs +1 -1
  242. package/dist/node_modules/@radix-ui/themes/dist/esm/components/tab-nav.mjs.map +1 -1
  243. package/dist/node_modules/@radix-ui/themes/dist/esm/components/table.mjs +1 -1
  244. package/dist/node_modules/@radix-ui/themes/dist/esm/components/table.mjs.map +1 -1
  245. package/dist/node_modules/@radix-ui/themes/dist/esm/components/tabs.mjs +1 -1
  246. package/dist/node_modules/@radix-ui/themes/dist/esm/components/tabs.mjs.map +1 -1
  247. package/dist/node_modules/@radix-ui/themes/dist/esm/components/text-area.mjs +1 -1
  248. package/dist/node_modules/@radix-ui/themes/dist/esm/components/text-area.mjs.map +1 -1
  249. package/dist/node_modules/@radix-ui/themes/dist/esm/components/text-field.mjs +1 -1
  250. package/dist/node_modules/@radix-ui/themes/dist/esm/components/text-field.mjs.map +1 -1
  251. package/dist/node_modules/@radix-ui/themes/dist/esm/components/text.mjs +1 -1
  252. package/dist/node_modules/@radix-ui/themes/dist/esm/components/text.mjs.map +1 -1
  253. package/dist/node_modules/@radix-ui/themes/dist/esm/components/theme.mjs +1 -1
  254. package/dist/node_modules/@radix-ui/themes/dist/esm/components/theme.mjs.map +1 -1
  255. package/dist/node_modules/@radix-ui/themes/dist/esm/helpers/extract-props.mjs +1 -1
  256. package/dist/node_modules/@radix-ui/themes/dist/esm/helpers/extract-props.mjs.map +1 -1
  257. package/dist/node_modules/@radix-ui/themes/dist/esm/helpers/get-margin-styles.mjs +1 -1
  258. package/dist/node_modules/@radix-ui/themes/dist/esm/helpers/get-margin-styles.mjs.map +1 -1
  259. package/dist/node_modules/@radix-ui/themes/node_modules/@radix-ui/react-popover/dist/index.mjs +1 -1
  260. package/dist/node_modules/@radix-ui/themes/node_modules/@radix-ui/react-popover/dist/index.mjs.map +1 -1
  261. package/dist/node_modules/chart.js/dist/chart.mjs +2 -2
  262. package/dist/node_modules/chart.js/dist/chart.mjs.map +1 -1
  263. package/dist/tsconfig.tsbuildinfo +1 -1
  264. package/package.json +1 -1
  265. package/dist/_virtual/_commonjsHelpers.mjs +0 -2
  266. package/dist/_virtual/_commonjsHelpers.mjs.map +0 -1
  267. package/dist/_virtual/index.mjs +0 -2
  268. package/dist/_virtual/index.mjs.map +0 -1
  269. package/dist/_virtual/index2.mjs +0 -2
  270. package/dist/_virtual/index2.mjs.map +0 -1
  271. package/dist/node_modules/aria-hidden/dist/es2015/index.mjs +0 -2
  272. package/dist/node_modules/aria-hidden/dist/es2015/index.mjs.map +0 -1
  273. package/dist/node_modules/chartjs-plugin-datalabels/dist/chartjs-plugin-datalabels.esm.mjs +0 -8
  274. package/dist/node_modules/chartjs-plugin-datalabels/dist/chartjs-plugin-datalabels.esm.mjs.map +0 -1
  275. package/dist/node_modules/class-variance-authority/dist/index.mjs +0 -2
  276. package/dist/node_modules/class-variance-authority/dist/index.mjs.map +0 -1
  277. package/dist/node_modules/class-variance-authority/node_modules/clsx/dist/clsx.mjs +0 -2
  278. package/dist/node_modules/class-variance-authority/node_modules/clsx/dist/clsx.mjs.map +0 -1
  279. package/dist/node_modules/classnames/index.mjs +0 -7
  280. package/dist/node_modules/classnames/index.mjs.map +0 -1
  281. package/dist/node_modules/clsx/dist/clsx.mjs +0 -2
  282. package/dist/node_modules/clsx/dist/clsx.mjs.map +0 -1
  283. package/dist/node_modules/get-nonce/dist/es2015/index.mjs +0 -2
  284. package/dist/node_modules/get-nonce/dist/es2015/index.mjs.map +0 -1
  285. package/dist/node_modules/react-chartjs-2/dist/index.mjs +0 -2
  286. package/dist/node_modules/react-chartjs-2/dist/index.mjs.map +0 -1
  287. package/dist/node_modules/react-remove-scroll/dist/es2015/Combination.mjs +0 -2
  288. package/dist/node_modules/react-remove-scroll/dist/es2015/Combination.mjs.map +0 -1
  289. package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.mjs +0 -2
  290. package/dist/node_modules/react-remove-scroll/dist/es2015/SideEffect.mjs.map +0 -1
  291. package/dist/node_modules/react-remove-scroll/dist/es2015/UI.mjs +0 -2
  292. package/dist/node_modules/react-remove-scroll/dist/es2015/UI.mjs.map +0 -1
  293. package/dist/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.mjs +0 -2
  294. package/dist/node_modules/react-remove-scroll/dist/es2015/aggresiveCapture.mjs.map +0 -1
  295. package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.mjs +0 -2
  296. package/dist/node_modules/react-remove-scroll/dist/es2015/handleScroll.mjs.map +0 -1
  297. package/dist/node_modules/react-remove-scroll/dist/es2015/medium.mjs +0 -2
  298. package/dist/node_modules/react-remove-scroll/dist/es2015/medium.mjs.map +0 -1
  299. package/dist/node_modules/react-remove-scroll/dist/es2015/sidecar.mjs +0 -2
  300. package/dist/node_modules/react-remove-scroll/dist/es2015/sidecar.mjs.map +0 -1
  301. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.mjs +0 -2
  302. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/component.mjs.map +0 -1
  303. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/constants.mjs +0 -2
  304. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/constants.mjs.map +0 -1
  305. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/utils.mjs +0 -2
  306. package/dist/node_modules/react-remove-scroll-bar/dist/es2015/utils.mjs.map +0 -1
  307. package/dist/node_modules/react-style-singleton/dist/es2015/component.mjs +0 -2
  308. package/dist/node_modules/react-style-singleton/dist/es2015/component.mjs.map +0 -1
  309. package/dist/node_modules/react-style-singleton/dist/es2015/hook.mjs +0 -2
  310. package/dist/node_modules/react-style-singleton/dist/es2015/hook.mjs.map +0 -1
  311. package/dist/node_modules/react-style-singleton/dist/es2015/singleton.mjs +0 -2
  312. package/dist/node_modules/react-style-singleton/dist/es2015/singleton.mjs.map +0 -1
  313. package/dist/node_modules/tailwind-merge/dist/bundle-mjs.mjs +0 -2
  314. package/dist/node_modules/tailwind-merge/dist/bundle-mjs.mjs.map +0 -1
  315. package/dist/node_modules/tslib/tslib.es6.mjs +0 -2
  316. package/dist/node_modules/tslib/tslib.es6.mjs.map +0 -1
  317. package/dist/node_modules/use-callback-ref/dist/es2015/assignRef.mjs +0 -2
  318. package/dist/node_modules/use-callback-ref/dist/es2015/assignRef.mjs.map +0 -1
  319. package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.mjs +0 -2
  320. package/dist/node_modules/use-callback-ref/dist/es2015/useMergeRef.mjs.map +0 -1
  321. package/dist/node_modules/use-callback-ref/dist/es2015/useRef.mjs +0 -2
  322. package/dist/node_modules/use-callback-ref/dist/es2015/useRef.mjs.map +0 -1
  323. package/dist/node_modules/use-sidecar/dist/es2015/exports.mjs +0 -2
  324. package/dist/node_modules/use-sidecar/dist/es2015/exports.mjs.map +0 -1
  325. package/dist/node_modules/use-sidecar/dist/es2015/medium.mjs +0 -2
  326. package/dist/node_modules/use-sidecar/dist/es2015/medium.mjs.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","sources":["../../../../../node_modules/@radix-ui/react-menu/dist/index.mjs"],"sourcesContent":["\"use client\";\n\n// packages/react/menu/src/Menu.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { createCollection } from \"@radix-ui/react-collection\";\nimport { useComposedRefs, composeRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useDirection } from \"@radix-ui/react-direction\";\nimport { DismissableLayer } from \"@radix-ui/react-dismissable-layer\";\nimport { useFocusGuards } from \"@radix-ui/react-focus-guards\";\nimport { FocusScope } from \"@radix-ui/react-focus-scope\";\nimport { useId } from \"@radix-ui/react-id\";\nimport * as PopperPrimitive from \"@radix-ui/react-popper\";\nimport { createPopperScope } from \"@radix-ui/react-popper\";\nimport { Portal as PortalPrimitive } from \"@radix-ui/react-portal\";\nimport { Presence } from \"@radix-ui/react-presence\";\nimport { Primitive, dispatchDiscreteCustomEvent } from \"@radix-ui/react-primitive\";\nimport * as RovingFocusGroup from \"@radix-ui/react-roving-focus\";\nimport { createRovingFocusGroupScope } from \"@radix-ui/react-roving-focus\";\nimport { Slot } from \"@radix-ui/react-slot\";\nimport { useCallbackRef } from \"@radix-ui/react-use-callback-ref\";\nimport { hideOthers } from \"aria-hidden\";\nimport { RemoveScroll } from \"react-remove-scroll\";\nimport { jsx } from \"react/jsx-runtime\";\nvar SELECTION_KEYS = [\"Enter\", \" \"];\nvar FIRST_KEYS = [\"ArrowDown\", \"PageUp\", \"Home\"];\nvar LAST_KEYS = [\"ArrowUp\", \"PageDown\", \"End\"];\nvar FIRST_LAST_KEYS = [...FIRST_KEYS, ...LAST_KEYS];\nvar SUB_OPEN_KEYS = {\n ltr: [...SELECTION_KEYS, \"ArrowRight\"],\n rtl: [...SELECTION_KEYS, \"ArrowLeft\"]\n};\nvar SUB_CLOSE_KEYS = {\n ltr: [\"ArrowLeft\"],\n rtl: [\"ArrowRight\"]\n};\nvar MENU_NAME = \"Menu\";\nvar [Collection, useCollection, createCollectionScope] = createCollection(MENU_NAME);\nvar [createMenuContext, createMenuScope] = createContextScope(MENU_NAME, [\n createCollectionScope,\n createPopperScope,\n createRovingFocusGroupScope\n]);\nvar usePopperScope = createPopperScope();\nvar useRovingFocusGroupScope = createRovingFocusGroupScope();\nvar [MenuProvider, useMenuContext] = createMenuContext(MENU_NAME);\nvar [MenuRootProvider, useMenuRootContext] = createMenuContext(MENU_NAME);\nvar Menu = (props) => {\n const { __scopeMenu, open = false, children, dir, onOpenChange, modal = true } = props;\n const popperScope = usePopperScope(__scopeMenu);\n const [content, setContent] = React.useState(null);\n const isUsingKeyboardRef = React.useRef(false);\n const handleOpenChange = useCallbackRef(onOpenChange);\n const direction = useDirection(dir);\n React.useEffect(() => {\n const handleKeyDown = () => {\n isUsingKeyboardRef.current = true;\n document.addEventListener(\"pointerdown\", handlePointer, { capture: true, once: true });\n document.addEventListener(\"pointermove\", handlePointer, { capture: true, once: true });\n };\n const handlePointer = () => isUsingKeyboardRef.current = false;\n document.addEventListener(\"keydown\", handleKeyDown, { capture: true });\n return () => {\n document.removeEventListener(\"keydown\", handleKeyDown, { capture: true });\n document.removeEventListener(\"pointerdown\", handlePointer, { capture: true });\n document.removeEventListener(\"pointermove\", handlePointer, { capture: true });\n };\n }, []);\n return /* @__PURE__ */ jsx(PopperPrimitive.Root, { ...popperScope, children: /* @__PURE__ */ jsx(\n MenuProvider,\n {\n scope: __scopeMenu,\n open,\n onOpenChange: handleOpenChange,\n content,\n onContentChange: setContent,\n children: /* @__PURE__ */ jsx(\n MenuRootProvider,\n {\n scope: __scopeMenu,\n onClose: React.useCallback(() => handleOpenChange(false), [handleOpenChange]),\n isUsingKeyboardRef,\n dir: direction,\n modal,\n children\n }\n )\n }\n ) });\n};\nMenu.displayName = MENU_NAME;\nvar ANCHOR_NAME = \"MenuAnchor\";\nvar MenuAnchor = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...anchorProps } = props;\n const popperScope = usePopperScope(__scopeMenu);\n return /* @__PURE__ */ jsx(PopperPrimitive.Anchor, { ...popperScope, ...anchorProps, ref: forwardedRef });\n }\n);\nMenuAnchor.displayName = ANCHOR_NAME;\nvar PORTAL_NAME = \"MenuPortal\";\nvar [PortalProvider, usePortalContext] = createMenuContext(PORTAL_NAME, {\n forceMount: void 0\n});\nvar MenuPortal = (props) => {\n const { __scopeMenu, forceMount, children, container } = props;\n const context = useMenuContext(PORTAL_NAME, __scopeMenu);\n return /* @__PURE__ */ jsx(PortalProvider, { scope: __scopeMenu, forceMount, children: /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(PortalPrimitive, { asChild: true, container, children }) }) });\n};\nMenuPortal.displayName = PORTAL_NAME;\nvar CONTENT_NAME = \"MenuContent\";\nvar [MenuContentProvider, useMenuContentContext] = createMenuContext(CONTENT_NAME);\nvar MenuContent = React.forwardRef(\n (props, forwardedRef) => {\n const portalContext = usePortalContext(CONTENT_NAME, props.__scopeMenu);\n const { forceMount = portalContext.forceMount, ...contentProps } = props;\n const context = useMenuContext(CONTENT_NAME, props.__scopeMenu);\n const rootContext = useMenuRootContext(CONTENT_NAME, props.__scopeMenu);\n return /* @__PURE__ */ jsx(Collection.Provider, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(Collection.Slot, { scope: props.__scopeMenu, children: rootContext.modal ? /* @__PURE__ */ jsx(MenuRootContentModal, { ...contentProps, ref: forwardedRef }) : /* @__PURE__ */ jsx(MenuRootContentNonModal, { ...contentProps, ref: forwardedRef }) }) }) });\n }\n);\nvar MenuRootContentModal = React.forwardRef(\n (props, forwardedRef) => {\n const context = useMenuContext(CONTENT_NAME, props.__scopeMenu);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n React.useEffect(() => {\n const content = ref.current;\n if (content) return hideOthers(content);\n }, []);\n return /* @__PURE__ */ jsx(\n MenuContentImpl,\n {\n ...props,\n ref: composedRefs,\n trapFocus: context.open,\n disableOutsidePointerEvents: context.open,\n disableOutsideScroll: true,\n onFocusOutside: composeEventHandlers(\n props.onFocusOutside,\n (event) => event.preventDefault(),\n { checkForDefaultPrevented: false }\n ),\n onDismiss: () => context.onOpenChange(false)\n }\n );\n }\n);\nvar MenuRootContentNonModal = React.forwardRef((props, forwardedRef) => {\n const context = useMenuContext(CONTENT_NAME, props.__scopeMenu);\n return /* @__PURE__ */ jsx(\n MenuContentImpl,\n {\n ...props,\n ref: forwardedRef,\n trapFocus: false,\n disableOutsidePointerEvents: false,\n disableOutsideScroll: false,\n onDismiss: () => context.onOpenChange(false)\n }\n );\n});\nvar MenuContentImpl = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeMenu,\n loop = false,\n trapFocus,\n onOpenAutoFocus,\n onCloseAutoFocus,\n disableOutsidePointerEvents,\n onEntryFocus,\n onEscapeKeyDown,\n onPointerDownOutside,\n onFocusOutside,\n onInteractOutside,\n onDismiss,\n disableOutsideScroll,\n ...contentProps\n } = props;\n const context = useMenuContext(CONTENT_NAME, __scopeMenu);\n const rootContext = useMenuRootContext(CONTENT_NAME, __scopeMenu);\n const popperScope = usePopperScope(__scopeMenu);\n const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeMenu);\n const getItems = useCollection(__scopeMenu);\n const [currentItemId, setCurrentItemId] = React.useState(null);\n const contentRef = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, contentRef, context.onContentChange);\n const timerRef = React.useRef(0);\n const searchRef = React.useRef(\"\");\n const pointerGraceTimerRef = React.useRef(0);\n const pointerGraceIntentRef = React.useRef(null);\n const pointerDirRef = React.useRef(\"right\");\n const lastPointerXRef = React.useRef(0);\n const ScrollLockWrapper = disableOutsideScroll ? RemoveScroll : React.Fragment;\n const scrollLockWrapperProps = disableOutsideScroll ? { as: Slot, allowPinchZoom: true } : void 0;\n const handleTypeaheadSearch = (key) => {\n const search = searchRef.current + key;\n const items = getItems().filter((item) => !item.disabled);\n const currentItem = document.activeElement;\n const currentMatch = items.find((item) => item.ref.current === currentItem)?.textValue;\n const values = items.map((item) => item.textValue);\n const nextMatch = getNextMatch(values, search, currentMatch);\n const newItem = items.find((item) => item.textValue === nextMatch)?.ref.current;\n (function updateSearch(value) {\n searchRef.current = value;\n window.clearTimeout(timerRef.current);\n if (value !== \"\") timerRef.current = window.setTimeout(() => updateSearch(\"\"), 1e3);\n })(search);\n if (newItem) {\n setTimeout(() => newItem.focus());\n }\n };\n React.useEffect(() => {\n return () => window.clearTimeout(timerRef.current);\n }, []);\n useFocusGuards();\n const isPointerMovingToSubmenu = React.useCallback((event) => {\n const isMovingTowards = pointerDirRef.current === pointerGraceIntentRef.current?.side;\n return isMovingTowards && isPointerInGraceArea(event, pointerGraceIntentRef.current?.area);\n }, []);\n return /* @__PURE__ */ jsx(\n MenuContentProvider,\n {\n scope: __scopeMenu,\n searchRef,\n onItemEnter: React.useCallback(\n (event) => {\n if (isPointerMovingToSubmenu(event)) event.preventDefault();\n },\n [isPointerMovingToSubmenu]\n ),\n onItemLeave: React.useCallback(\n (event) => {\n if (isPointerMovingToSubmenu(event)) return;\n contentRef.current?.focus();\n setCurrentItemId(null);\n },\n [isPointerMovingToSubmenu]\n ),\n onTriggerLeave: React.useCallback(\n (event) => {\n if (isPointerMovingToSubmenu(event)) event.preventDefault();\n },\n [isPointerMovingToSubmenu]\n ),\n pointerGraceTimerRef,\n onPointerGraceIntentChange: React.useCallback((intent) => {\n pointerGraceIntentRef.current = intent;\n }, []),\n children: /* @__PURE__ */ jsx(ScrollLockWrapper, { ...scrollLockWrapperProps, children: /* @__PURE__ */ jsx(\n FocusScope,\n {\n asChild: true,\n trapped: trapFocus,\n onMountAutoFocus: composeEventHandlers(onOpenAutoFocus, (event) => {\n event.preventDefault();\n contentRef.current?.focus({ preventScroll: true });\n }),\n onUnmountAutoFocus: onCloseAutoFocus,\n children: /* @__PURE__ */ jsx(\n DismissableLayer,\n {\n asChild: true,\n disableOutsidePointerEvents,\n onEscapeKeyDown,\n onPointerDownOutside,\n onFocusOutside,\n onInteractOutside,\n onDismiss,\n children: /* @__PURE__ */ jsx(\n RovingFocusGroup.Root,\n {\n asChild: true,\n ...rovingFocusGroupScope,\n dir: rootContext.dir,\n orientation: \"vertical\",\n loop,\n currentTabStopId: currentItemId,\n onCurrentTabStopIdChange: setCurrentItemId,\n onEntryFocus: composeEventHandlers(onEntryFocus, (event) => {\n if (!rootContext.isUsingKeyboardRef.current) event.preventDefault();\n }),\n preventScrollOnEntryFocus: true,\n children: /* @__PURE__ */ jsx(\n PopperPrimitive.Content,\n {\n role: \"menu\",\n \"aria-orientation\": \"vertical\",\n \"data-state\": getOpenState(context.open),\n \"data-radix-menu-content\": \"\",\n dir: rootContext.dir,\n ...popperScope,\n ...contentProps,\n ref: composedRefs,\n style: { outline: \"none\", ...contentProps.style },\n onKeyDown: composeEventHandlers(contentProps.onKeyDown, (event) => {\n const target = event.target;\n const isKeyDownInside = target.closest(\"[data-radix-menu-content]\") === event.currentTarget;\n const isModifierKey = event.ctrlKey || event.altKey || event.metaKey;\n const isCharacterKey = event.key.length === 1;\n if (isKeyDownInside) {\n if (event.key === \"Tab\") event.preventDefault();\n if (!isModifierKey && isCharacterKey) handleTypeaheadSearch(event.key);\n }\n const content = contentRef.current;\n if (event.target !== content) return;\n if (!FIRST_LAST_KEYS.includes(event.key)) return;\n event.preventDefault();\n const items = getItems().filter((item) => !item.disabled);\n const candidateNodes = items.map((item) => item.ref.current);\n if (LAST_KEYS.includes(event.key)) candidateNodes.reverse();\n focusFirst(candidateNodes);\n }),\n onBlur: composeEventHandlers(props.onBlur, (event) => {\n if (!event.currentTarget.contains(event.target)) {\n window.clearTimeout(timerRef.current);\n searchRef.current = \"\";\n }\n }),\n onPointerMove: composeEventHandlers(\n props.onPointerMove,\n whenMouse((event) => {\n const target = event.target;\n const pointerXHasChanged = lastPointerXRef.current !== event.clientX;\n if (event.currentTarget.contains(target) && pointerXHasChanged) {\n const newDir = event.clientX > lastPointerXRef.current ? \"right\" : \"left\";\n pointerDirRef.current = newDir;\n lastPointerXRef.current = event.clientX;\n }\n })\n )\n }\n )\n }\n )\n }\n )\n }\n ) })\n }\n );\n }\n);\nMenuContent.displayName = CONTENT_NAME;\nvar GROUP_NAME = \"MenuGroup\";\nvar MenuGroup = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...groupProps } = props;\n return /* @__PURE__ */ jsx(Primitive.div, { role: \"group\", ...groupProps, ref: forwardedRef });\n }\n);\nMenuGroup.displayName = GROUP_NAME;\nvar LABEL_NAME = \"MenuLabel\";\nvar MenuLabel = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...labelProps } = props;\n return /* @__PURE__ */ jsx(Primitive.div, { ...labelProps, ref: forwardedRef });\n }\n);\nMenuLabel.displayName = LABEL_NAME;\nvar ITEM_NAME = \"MenuItem\";\nvar ITEM_SELECT = \"menu.itemSelect\";\nvar MenuItem = React.forwardRef(\n (props, forwardedRef) => {\n const { disabled = false, onSelect, ...itemProps } = props;\n const ref = React.useRef(null);\n const rootContext = useMenuRootContext(ITEM_NAME, props.__scopeMenu);\n const contentContext = useMenuContentContext(ITEM_NAME, props.__scopeMenu);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const isPointerDownRef = React.useRef(false);\n const handleSelect = () => {\n const menuItem = ref.current;\n if (!disabled && menuItem) {\n const itemSelectEvent = new CustomEvent(ITEM_SELECT, { bubbles: true, cancelable: true });\n menuItem.addEventListener(ITEM_SELECT, (event) => onSelect?.(event), { once: true });\n dispatchDiscreteCustomEvent(menuItem, itemSelectEvent);\n if (itemSelectEvent.defaultPrevented) {\n isPointerDownRef.current = false;\n } else {\n rootContext.onClose();\n }\n }\n };\n return /* @__PURE__ */ jsx(\n MenuItemImpl,\n {\n ...itemProps,\n ref: composedRefs,\n disabled,\n onClick: composeEventHandlers(props.onClick, handleSelect),\n onPointerDown: (event) => {\n props.onPointerDown?.(event);\n isPointerDownRef.current = true;\n },\n onPointerUp: composeEventHandlers(props.onPointerUp, (event) => {\n if (!isPointerDownRef.current) event.currentTarget?.click();\n }),\n onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {\n const isTypingAhead = contentContext.searchRef.current !== \"\";\n if (disabled || isTypingAhead && event.key === \" \") return;\n if (SELECTION_KEYS.includes(event.key)) {\n event.currentTarget.click();\n event.preventDefault();\n }\n })\n }\n );\n }\n);\nMenuItem.displayName = ITEM_NAME;\nvar MenuItemImpl = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, disabled = false, textValue, ...itemProps } = props;\n const contentContext = useMenuContentContext(ITEM_NAME, __scopeMenu);\n const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeMenu);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const [isFocused, setIsFocused] = React.useState(false);\n const [textContent, setTextContent] = React.useState(\"\");\n React.useEffect(() => {\n const menuItem = ref.current;\n if (menuItem) {\n setTextContent((menuItem.textContent ?? \"\").trim());\n }\n }, [itemProps.children]);\n return /* @__PURE__ */ jsx(\n Collection.ItemSlot,\n {\n scope: __scopeMenu,\n disabled,\n textValue: textValue ?? textContent,\n children: /* @__PURE__ */ jsx(RovingFocusGroup.Item, { asChild: true, ...rovingFocusGroupScope, focusable: !disabled, children: /* @__PURE__ */ jsx(\n Primitive.div,\n {\n role: \"menuitem\",\n \"data-highlighted\": isFocused ? \"\" : void 0,\n \"aria-disabled\": disabled || void 0,\n \"data-disabled\": disabled ? \"\" : void 0,\n ...itemProps,\n ref: composedRefs,\n onPointerMove: composeEventHandlers(\n props.onPointerMove,\n whenMouse((event) => {\n if (disabled) {\n contentContext.onItemLeave(event);\n } else {\n contentContext.onItemEnter(event);\n if (!event.defaultPrevented) {\n const item = event.currentTarget;\n item.focus({ preventScroll: true });\n }\n }\n })\n ),\n onPointerLeave: composeEventHandlers(\n props.onPointerLeave,\n whenMouse((event) => contentContext.onItemLeave(event))\n ),\n onFocus: composeEventHandlers(props.onFocus, () => setIsFocused(true)),\n onBlur: composeEventHandlers(props.onBlur, () => setIsFocused(false))\n }\n ) })\n }\n );\n }\n);\nvar CHECKBOX_ITEM_NAME = \"MenuCheckboxItem\";\nvar MenuCheckboxItem = React.forwardRef(\n (props, forwardedRef) => {\n const { checked = false, onCheckedChange, ...checkboxItemProps } = props;\n return /* @__PURE__ */ jsx(ItemIndicatorProvider, { scope: props.__scopeMenu, checked, children: /* @__PURE__ */ jsx(\n MenuItem,\n {\n role: \"menuitemcheckbox\",\n \"aria-checked\": isIndeterminate(checked) ? \"mixed\" : checked,\n ...checkboxItemProps,\n ref: forwardedRef,\n \"data-state\": getCheckedState(checked),\n onSelect: composeEventHandlers(\n checkboxItemProps.onSelect,\n () => onCheckedChange?.(isIndeterminate(checked) ? true : !checked),\n { checkForDefaultPrevented: false }\n )\n }\n ) });\n }\n);\nMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME;\nvar RADIO_GROUP_NAME = \"MenuRadioGroup\";\nvar [RadioGroupProvider, useRadioGroupContext] = createMenuContext(\n RADIO_GROUP_NAME,\n { value: void 0, onValueChange: () => {\n } }\n);\nvar MenuRadioGroup = React.forwardRef(\n (props, forwardedRef) => {\n const { value, onValueChange, ...groupProps } = props;\n const handleValueChange = useCallbackRef(onValueChange);\n return /* @__PURE__ */ jsx(RadioGroupProvider, { scope: props.__scopeMenu, value, onValueChange: handleValueChange, children: /* @__PURE__ */ jsx(MenuGroup, { ...groupProps, ref: forwardedRef }) });\n }\n);\nMenuRadioGroup.displayName = RADIO_GROUP_NAME;\nvar RADIO_ITEM_NAME = \"MenuRadioItem\";\nvar MenuRadioItem = React.forwardRef(\n (props, forwardedRef) => {\n const { value, ...radioItemProps } = props;\n const context = useRadioGroupContext(RADIO_ITEM_NAME, props.__scopeMenu);\n const checked = value === context.value;\n return /* @__PURE__ */ jsx(ItemIndicatorProvider, { scope: props.__scopeMenu, checked, children: /* @__PURE__ */ jsx(\n MenuItem,\n {\n role: \"menuitemradio\",\n \"aria-checked\": checked,\n ...radioItemProps,\n ref: forwardedRef,\n \"data-state\": getCheckedState(checked),\n onSelect: composeEventHandlers(\n radioItemProps.onSelect,\n () => context.onValueChange?.(value),\n { checkForDefaultPrevented: false }\n )\n }\n ) });\n }\n);\nMenuRadioItem.displayName = RADIO_ITEM_NAME;\nvar ITEM_INDICATOR_NAME = \"MenuItemIndicator\";\nvar [ItemIndicatorProvider, useItemIndicatorContext] = createMenuContext(\n ITEM_INDICATOR_NAME,\n { checked: false }\n);\nvar MenuItemIndicator = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, forceMount, ...itemIndicatorProps } = props;\n const indicatorContext = useItemIndicatorContext(ITEM_INDICATOR_NAME, __scopeMenu);\n return /* @__PURE__ */ jsx(\n Presence,\n {\n present: forceMount || isIndeterminate(indicatorContext.checked) || indicatorContext.checked === true,\n children: /* @__PURE__ */ jsx(\n Primitive.span,\n {\n ...itemIndicatorProps,\n ref: forwardedRef,\n \"data-state\": getCheckedState(indicatorContext.checked)\n }\n )\n }\n );\n }\n);\nMenuItemIndicator.displayName = ITEM_INDICATOR_NAME;\nvar SEPARATOR_NAME = \"MenuSeparator\";\nvar MenuSeparator = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...separatorProps } = props;\n return /* @__PURE__ */ jsx(\n Primitive.div,\n {\n role: \"separator\",\n \"aria-orientation\": \"horizontal\",\n ...separatorProps,\n ref: forwardedRef\n }\n );\n }\n);\nMenuSeparator.displayName = SEPARATOR_NAME;\nvar ARROW_NAME = \"MenuArrow\";\nvar MenuArrow = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...arrowProps } = props;\n const popperScope = usePopperScope(__scopeMenu);\n return /* @__PURE__ */ jsx(PopperPrimitive.Arrow, { ...popperScope, ...arrowProps, ref: forwardedRef });\n }\n);\nMenuArrow.displayName = ARROW_NAME;\nvar SUB_NAME = \"MenuSub\";\nvar [MenuSubProvider, useMenuSubContext] = createMenuContext(SUB_NAME);\nvar MenuSub = (props) => {\n const { __scopeMenu, children, open = false, onOpenChange } = props;\n const parentMenuContext = useMenuContext(SUB_NAME, __scopeMenu);\n const popperScope = usePopperScope(__scopeMenu);\n const [trigger, setTrigger] = React.useState(null);\n const [content, setContent] = React.useState(null);\n const handleOpenChange = useCallbackRef(onOpenChange);\n React.useEffect(() => {\n if (parentMenuContext.open === false) handleOpenChange(false);\n return () => handleOpenChange(false);\n }, [parentMenuContext.open, handleOpenChange]);\n return /* @__PURE__ */ jsx(PopperPrimitive.Root, { ...popperScope, children: /* @__PURE__ */ jsx(\n MenuProvider,\n {\n scope: __scopeMenu,\n open,\n onOpenChange: handleOpenChange,\n content,\n onContentChange: setContent,\n children: /* @__PURE__ */ jsx(\n MenuSubProvider,\n {\n scope: __scopeMenu,\n contentId: useId(),\n triggerId: useId(),\n trigger,\n onTriggerChange: setTrigger,\n children\n }\n )\n }\n ) });\n};\nMenuSub.displayName = SUB_NAME;\nvar SUB_TRIGGER_NAME = \"MenuSubTrigger\";\nvar MenuSubTrigger = React.forwardRef(\n (props, forwardedRef) => {\n const context = useMenuContext(SUB_TRIGGER_NAME, props.__scopeMenu);\n const rootContext = useMenuRootContext(SUB_TRIGGER_NAME, props.__scopeMenu);\n const subContext = useMenuSubContext(SUB_TRIGGER_NAME, props.__scopeMenu);\n const contentContext = useMenuContentContext(SUB_TRIGGER_NAME, props.__scopeMenu);\n const openTimerRef = React.useRef(null);\n const { pointerGraceTimerRef, onPointerGraceIntentChange } = contentContext;\n const scope = { __scopeMenu: props.__scopeMenu };\n const clearOpenTimer = React.useCallback(() => {\n if (openTimerRef.current) window.clearTimeout(openTimerRef.current);\n openTimerRef.current = null;\n }, []);\n React.useEffect(() => clearOpenTimer, [clearOpenTimer]);\n React.useEffect(() => {\n const pointerGraceTimer = pointerGraceTimerRef.current;\n return () => {\n window.clearTimeout(pointerGraceTimer);\n onPointerGraceIntentChange(null);\n };\n }, [pointerGraceTimerRef, onPointerGraceIntentChange]);\n return /* @__PURE__ */ jsx(MenuAnchor, { asChild: true, ...scope, children: /* @__PURE__ */ jsx(\n MenuItemImpl,\n {\n id: subContext.triggerId,\n \"aria-haspopup\": \"menu\",\n \"aria-expanded\": context.open,\n \"aria-controls\": subContext.contentId,\n \"data-state\": getOpenState(context.open),\n ...props,\n ref: composeRefs(forwardedRef, subContext.onTriggerChange),\n onClick: (event) => {\n props.onClick?.(event);\n if (props.disabled || event.defaultPrevented) return;\n event.currentTarget.focus();\n if (!context.open) context.onOpenChange(true);\n },\n onPointerMove: composeEventHandlers(\n props.onPointerMove,\n whenMouse((event) => {\n contentContext.onItemEnter(event);\n if (event.defaultPrevented) return;\n if (!props.disabled && !context.open && !openTimerRef.current) {\n contentContext.onPointerGraceIntentChange(null);\n openTimerRef.current = window.setTimeout(() => {\n context.onOpenChange(true);\n clearOpenTimer();\n }, 100);\n }\n })\n ),\n onPointerLeave: composeEventHandlers(\n props.onPointerLeave,\n whenMouse((event) => {\n clearOpenTimer();\n const contentRect = context.content?.getBoundingClientRect();\n if (contentRect) {\n const side = context.content?.dataset.side;\n const rightSide = side === \"right\";\n const bleed = rightSide ? -5 : 5;\n const contentNearEdge = contentRect[rightSide ? \"left\" : \"right\"];\n const contentFarEdge = contentRect[rightSide ? \"right\" : \"left\"];\n contentContext.onPointerGraceIntentChange({\n area: [\n // Apply a bleed on clientX to ensure that our exit point is\n // consistently within polygon bounds\n { x: event.clientX + bleed, y: event.clientY },\n { x: contentNearEdge, y: contentRect.top },\n { x: contentFarEdge, y: contentRect.top },\n { x: contentFarEdge, y: contentRect.bottom },\n { x: contentNearEdge, y: contentRect.bottom }\n ],\n side\n });\n window.clearTimeout(pointerGraceTimerRef.current);\n pointerGraceTimerRef.current = window.setTimeout(\n () => contentContext.onPointerGraceIntentChange(null),\n 300\n );\n } else {\n contentContext.onTriggerLeave(event);\n if (event.defaultPrevented) return;\n contentContext.onPointerGraceIntentChange(null);\n }\n })\n ),\n onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {\n const isTypingAhead = contentContext.searchRef.current !== \"\";\n if (props.disabled || isTypingAhead && event.key === \" \") return;\n if (SUB_OPEN_KEYS[rootContext.dir].includes(event.key)) {\n context.onOpenChange(true);\n context.content?.focus();\n event.preventDefault();\n }\n })\n }\n ) });\n }\n);\nMenuSubTrigger.displayName = SUB_TRIGGER_NAME;\nvar SUB_CONTENT_NAME = \"MenuSubContent\";\nvar MenuSubContent = React.forwardRef(\n (props, forwardedRef) => {\n const portalContext = usePortalContext(CONTENT_NAME, props.__scopeMenu);\n const { forceMount = portalContext.forceMount, ...subContentProps } = props;\n const context = useMenuContext(CONTENT_NAME, props.__scopeMenu);\n const rootContext = useMenuRootContext(CONTENT_NAME, props.__scopeMenu);\n const subContext = useMenuSubContext(SUB_CONTENT_NAME, props.__scopeMenu);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n return /* @__PURE__ */ jsx(Collection.Provider, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(Collection.Slot, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsx(\n MenuContentImpl,\n {\n id: subContext.contentId,\n \"aria-labelledby\": subContext.triggerId,\n ...subContentProps,\n ref: composedRefs,\n align: \"start\",\n side: rootContext.dir === \"rtl\" ? \"left\" : \"right\",\n disableOutsidePointerEvents: false,\n disableOutsideScroll: false,\n trapFocus: false,\n onOpenAutoFocus: (event) => {\n if (rootContext.isUsingKeyboardRef.current) ref.current?.focus();\n event.preventDefault();\n },\n onCloseAutoFocus: (event) => event.preventDefault(),\n onFocusOutside: composeEventHandlers(props.onFocusOutside, (event) => {\n if (event.target !== subContext.trigger) context.onOpenChange(false);\n }),\n onEscapeKeyDown: composeEventHandlers(props.onEscapeKeyDown, (event) => {\n rootContext.onClose();\n event.preventDefault();\n }),\n onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {\n const isKeyDownInside = event.currentTarget.contains(event.target);\n const isCloseKey = SUB_CLOSE_KEYS[rootContext.dir].includes(event.key);\n if (isKeyDownInside && isCloseKey) {\n context.onOpenChange(false);\n subContext.trigger?.focus();\n event.preventDefault();\n }\n })\n }\n ) }) }) });\n }\n);\nMenuSubContent.displayName = SUB_CONTENT_NAME;\nfunction getOpenState(open) {\n return open ? \"open\" : \"closed\";\n}\nfunction isIndeterminate(checked) {\n return checked === \"indeterminate\";\n}\nfunction getCheckedState(checked) {\n return isIndeterminate(checked) ? \"indeterminate\" : checked ? \"checked\" : \"unchecked\";\n}\nfunction focusFirst(candidates) {\n const PREVIOUSLY_FOCUSED_ELEMENT = document.activeElement;\n for (const candidate of candidates) {\n if (candidate === PREVIOUSLY_FOCUSED_ELEMENT) return;\n candidate.focus();\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}\nfunction getNextMatch(values, search, currentMatch) {\n const isRepeated = search.length > 1 && Array.from(search).every((char) => char === search[0]);\n const normalizedSearch = isRepeated ? search[0] : search;\n const currentMatchIndex = currentMatch ? values.indexOf(currentMatch) : -1;\n let wrappedValues = wrapArray(values, Math.max(currentMatchIndex, 0));\n const excludeCurrentMatch = normalizedSearch.length === 1;\n if (excludeCurrentMatch) wrappedValues = wrappedValues.filter((v) => v !== currentMatch);\n const nextMatch = wrappedValues.find(\n (value) => value.toLowerCase().startsWith(normalizedSearch.toLowerCase())\n );\n return nextMatch !== currentMatch ? nextMatch : void 0;\n}\nfunction isPointInPolygon(point, polygon) {\n const { x, y } = point;\n let inside = false;\n for (let i = 0, j = polygon.length - 1; i < polygon.length; j = i++) {\n const xi = polygon[i].x;\n const yi = polygon[i].y;\n const xj = polygon[j].x;\n const yj = polygon[j].y;\n const intersect = yi > y !== yj > y && x < (xj - xi) * (y - yi) / (yj - yi) + xi;\n if (intersect) inside = !inside;\n }\n return inside;\n}\nfunction isPointerInGraceArea(event, area) {\n if (!area) return false;\n const cursorPos = { x: event.clientX, y: event.clientY };\n return isPointInPolygon(cursorPos, area);\n}\nfunction whenMouse(handler) {\n return (event) => event.pointerType === \"mouse\" ? handler(event) : void 0;\n}\nvar Root3 = Menu;\nvar Anchor2 = MenuAnchor;\nvar Portal = MenuPortal;\nvar Content2 = MenuContent;\nvar Group = MenuGroup;\nvar Label = MenuLabel;\nvar Item2 = MenuItem;\nvar CheckboxItem = MenuCheckboxItem;\nvar RadioGroup = MenuRadioGroup;\nvar RadioItem = MenuRadioItem;\nvar ItemIndicator = MenuItemIndicator;\nvar Separator = MenuSeparator;\nvar Arrow2 = MenuArrow;\nvar Sub = MenuSub;\nvar SubTrigger = MenuSubTrigger;\nvar SubContent = MenuSubContent;\nexport {\n Anchor2 as Anchor,\n Arrow2 as Arrow,\n CheckboxItem,\n Content2 as Content,\n Group,\n Item2 as Item,\n ItemIndicator,\n Label,\n Menu,\n MenuAnchor,\n MenuArrow,\n MenuCheckboxItem,\n MenuContent,\n MenuGroup,\n MenuItem,\n MenuItemIndicator,\n MenuLabel,\n MenuPortal,\n MenuRadioGroup,\n MenuRadioItem,\n MenuSeparator,\n MenuSub,\n MenuSubContent,\n MenuSubTrigger,\n Portal,\n RadioGroup,\n RadioItem,\n Root3 as Root,\n Separator,\n Sub,\n SubContent,\n SubTrigger,\n createMenuScope\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["SELECTION_KEYS","LAST_KEYS","FIRST_LAST_KEYS","SUB_OPEN_KEYS","ltr","rtl","SUB_CLOSE_KEYS","MENU_NAME","Collection","useCollection","createCollectionScope","createCollection","createMenuContext","createMenuScope","createContextScope","createPopperScope","createRovingFocusGroupScope","usePopperScope","useRovingFocusGroupScope","MenuProvider","useMenuContext","MenuRootProvider","useMenuRootContext","Menu","props","__scopeMenu","open","children","dir","onOpenChange","modal","popperScope","content","setContent","React","useState","isUsingKeyboardRef","useRef","handleOpenChange","useCallbackRef","direction","useDirection","useEffect","handleKeyDown","current","document","addEventListener","handlePointer","capture","once","removeEventListener","jsx","PopperPrimitive.Root","scope","onContentChange","onClose","useCallback","displayName","MenuAnchor","forwardRef","forwardedRef","anchorProps","PopperPrimitive.Anchor","ref","PORTAL_NAME","PortalProvider","usePortalContext","forceMount","MenuPortal","container","context","Presence","present","PortalPrimitive","asChild","CONTENT_NAME","MenuContentProvider","useMenuContentContext","MenuContent","portalContext","contentProps","rootContext","Provider","Slot","MenuRootContentModal","MenuRootContentNonModal","composedRefs","useComposedRefs","hideOthers","MenuContentImpl","trapFocus","disableOutsidePointerEvents","disableOutsideScroll","onFocusOutside","composeEventHandlers","event","preventDefault","checkForDefaultPrevented","onDismiss","loop","onOpenAutoFocus","onCloseAutoFocus","onEntryFocus","onEscapeKeyDown","onPointerDownOutside","onInteractOutside","rovingFocusGroupScope","getItems","currentItemId","setCurrentItemId","contentRef","timerRef","searchRef","pointerGraceTimerRef","pointerGraceIntentRef","pointerDirRef","lastPointerXRef","ScrollLockWrapper","RemoveScroll","Fragment","scrollLockWrapperProps","as","allowPinchZoom","handleTypeaheadSearch","key","search","items","filter","item","disabled","currentItem","activeElement","currentMatch","find","textValue","nextMatch","values","isRepeated","length","Array","from","every","char","normalizedSearch","currentMatchIndex","indexOf","wrappedValues","array","startIndex","Math","max","map","_","index","v","value","toLowerCase","startsWith","getNextMatch","newItem","updateSearch","window","clearTimeout","setTimeout","focus","useFocusGuards","isPointerMovingToSubmenu","side","area","cursorPos","x","clientX","y","clientY","point","polygon","inside","i","j","xi","yi","xj","yj","isPointInPolygon","isPointerInGraceArea","onItemEnter","onItemLeave","onTriggerLeave","onPointerGraceIntentChange","intent","FocusScope","trapped","onMountAutoFocus","preventScroll","onUnmountAutoFocus","DismissableLayer","RovingFocusGroup.Root","orientation","currentTabStopId","onCurrentTabStopIdChange","preventScrollOnEntryFocus","PopperPrimitive.Content","role","getOpenState","style","outline","onKeyDown","isKeyDownInside","target","closest","currentTarget","isModifierKey","ctrlKey","altKey","metaKey","isCharacterKey","includes","candidateNodes","reverse","candidates","PREVIOUSLY_FOCUSED_ELEMENT","candidate","focusFirst","onBlur","contains","onPointerMove","whenMouse","pointerXHasChanged","newDir","MenuGroup","groupProps","Primitive","div","MenuLabel","labelProps","ITEM_NAME","ITEM_SELECT","MenuItem","onSelect","itemProps","contentContext","isPointerDownRef","MenuItemImpl","onClick","menuItem","itemSelectEvent","CustomEvent","bubbles","cancelable","dispatchDiscreteCustomEvent","defaultPrevented","onPointerDown","onPointerUp","click","isTypingAhead","isFocused","setIsFocused","textContent","setTextContent","trim","ItemSlot","RovingFocusGroup.Item","focusable","onPointerLeave","onFocus","MenuCheckboxItem","checked","onCheckedChange","checkboxItemProps","ItemIndicatorProvider","isIndeterminate","getCheckedState","RADIO_GROUP_NAME","RadioGroupProvider","useRadioGroupContext","onValueChange","MenuRadioGroup","handleValueChange","RADIO_ITEM_NAME","MenuRadioItem","radioItemProps","ITEM_INDICATOR_NAME","useItemIndicatorContext","MenuItemIndicator","itemIndicatorProps","indicatorContext","span","MenuSeparator","separatorProps","MenuArrow","arrowProps","PopperPrimitive.Arrow","SUB_NAME","MenuSubProvider","useMenuSubContext","MenuSub","parentMenuContext","trigger","setTrigger","contentId","useId","triggerId","onTriggerChange","SUB_TRIGGER_NAME","MenuSubTrigger","subContext","openTimerRef","clearOpenTimer","pointerGraceTimer","id","composeRefs","contentRect","getBoundingClientRect","dataset","rightSide","bleed","contentNearEdge","contentFarEdge","top","bottom","SUB_CONTENT_NAME","MenuSubContent","subContentProps","align","isCloseKey","handler","pointerType","Root3","Anchor2","Portal","Content2","Group","Label","Item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,GACb4D,GAAYzD,GACZ0D,GAAgBtD,GAChBuD,GAAYnD,GACZoD,GAASlD,GACTmD,GAAM7C,GACN8C,GAAarC,GACbsC,GAAarB"}
1
+ {"version":3,"file":"index.mjs","sources":["../../../../../node_modules/@radix-ui/react-menu/dist/index.mjs"],"sourcesContent":["\"use client\";\n\n// packages/react/menu/src/Menu.tsx\nimport * as React from \"react\";\nimport { composeEventHandlers } from \"@radix-ui/primitive\";\nimport { createCollection } from \"@radix-ui/react-collection\";\nimport { useComposedRefs, composeRefs } from \"@radix-ui/react-compose-refs\";\nimport { createContextScope } from \"@radix-ui/react-context\";\nimport { useDirection } from \"@radix-ui/react-direction\";\nimport { DismissableLayer } from \"@radix-ui/react-dismissable-layer\";\nimport { useFocusGuards } from \"@radix-ui/react-focus-guards\";\nimport { FocusScope } from \"@radix-ui/react-focus-scope\";\nimport { useId } from \"@radix-ui/react-id\";\nimport * as PopperPrimitive from \"@radix-ui/react-popper\";\nimport { createPopperScope } from \"@radix-ui/react-popper\";\nimport { Portal as PortalPrimitive } from \"@radix-ui/react-portal\";\nimport { Presence } from \"@radix-ui/react-presence\";\nimport { Primitive, dispatchDiscreteCustomEvent } from \"@radix-ui/react-primitive\";\nimport * as RovingFocusGroup from \"@radix-ui/react-roving-focus\";\nimport { createRovingFocusGroupScope } from \"@radix-ui/react-roving-focus\";\nimport { Slot } from \"@radix-ui/react-slot\";\nimport { useCallbackRef } from \"@radix-ui/react-use-callback-ref\";\nimport { hideOthers } from \"aria-hidden\";\nimport { RemoveScroll } from \"react-remove-scroll\";\nimport { jsx } from \"react/jsx-runtime\";\nvar SELECTION_KEYS = [\"Enter\", \" \"];\nvar FIRST_KEYS = [\"ArrowDown\", \"PageUp\", \"Home\"];\nvar LAST_KEYS = [\"ArrowUp\", \"PageDown\", \"End\"];\nvar FIRST_LAST_KEYS = [...FIRST_KEYS, ...LAST_KEYS];\nvar SUB_OPEN_KEYS = {\n ltr: [...SELECTION_KEYS, \"ArrowRight\"],\n rtl: [...SELECTION_KEYS, \"ArrowLeft\"]\n};\nvar SUB_CLOSE_KEYS = {\n ltr: [\"ArrowLeft\"],\n rtl: [\"ArrowRight\"]\n};\nvar MENU_NAME = \"Menu\";\nvar [Collection, useCollection, createCollectionScope] = createCollection(MENU_NAME);\nvar [createMenuContext, createMenuScope] = createContextScope(MENU_NAME, [\n createCollectionScope,\n createPopperScope,\n createRovingFocusGroupScope\n]);\nvar usePopperScope = createPopperScope();\nvar useRovingFocusGroupScope = createRovingFocusGroupScope();\nvar [MenuProvider, useMenuContext] = createMenuContext(MENU_NAME);\nvar [MenuRootProvider, useMenuRootContext] = createMenuContext(MENU_NAME);\nvar Menu = (props) => {\n const { __scopeMenu, open = false, children, dir, onOpenChange, modal = true } = props;\n const popperScope = usePopperScope(__scopeMenu);\n const [content, setContent] = React.useState(null);\n const isUsingKeyboardRef = React.useRef(false);\n const handleOpenChange = useCallbackRef(onOpenChange);\n const direction = useDirection(dir);\n React.useEffect(() => {\n const handleKeyDown = () => {\n isUsingKeyboardRef.current = true;\n document.addEventListener(\"pointerdown\", handlePointer, { capture: true, once: true });\n document.addEventListener(\"pointermove\", handlePointer, { capture: true, once: true });\n };\n const handlePointer = () => isUsingKeyboardRef.current = false;\n document.addEventListener(\"keydown\", handleKeyDown, { capture: true });\n return () => {\n document.removeEventListener(\"keydown\", handleKeyDown, { capture: true });\n document.removeEventListener(\"pointerdown\", handlePointer, { capture: true });\n document.removeEventListener(\"pointermove\", handlePointer, { capture: true });\n };\n }, []);\n return /* @__PURE__ */ jsx(PopperPrimitive.Root, { ...popperScope, children: /* @__PURE__ */ jsx(\n MenuProvider,\n {\n scope: __scopeMenu,\n open,\n onOpenChange: handleOpenChange,\n content,\n onContentChange: setContent,\n children: /* @__PURE__ */ jsx(\n MenuRootProvider,\n {\n scope: __scopeMenu,\n onClose: React.useCallback(() => handleOpenChange(false), [handleOpenChange]),\n isUsingKeyboardRef,\n dir: direction,\n modal,\n children\n }\n )\n }\n ) });\n};\nMenu.displayName = MENU_NAME;\nvar ANCHOR_NAME = \"MenuAnchor\";\nvar MenuAnchor = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...anchorProps } = props;\n const popperScope = usePopperScope(__scopeMenu);\n return /* @__PURE__ */ jsx(PopperPrimitive.Anchor, { ...popperScope, ...anchorProps, ref: forwardedRef });\n }\n);\nMenuAnchor.displayName = ANCHOR_NAME;\nvar PORTAL_NAME = \"MenuPortal\";\nvar [PortalProvider, usePortalContext] = createMenuContext(PORTAL_NAME, {\n forceMount: void 0\n});\nvar MenuPortal = (props) => {\n const { __scopeMenu, forceMount, children, container } = props;\n const context = useMenuContext(PORTAL_NAME, __scopeMenu);\n return /* @__PURE__ */ jsx(PortalProvider, { scope: __scopeMenu, forceMount, children: /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(PortalPrimitive, { asChild: true, container, children }) }) });\n};\nMenuPortal.displayName = PORTAL_NAME;\nvar CONTENT_NAME = \"MenuContent\";\nvar [MenuContentProvider, useMenuContentContext] = createMenuContext(CONTENT_NAME);\nvar MenuContent = React.forwardRef(\n (props, forwardedRef) => {\n const portalContext = usePortalContext(CONTENT_NAME, props.__scopeMenu);\n const { forceMount = portalContext.forceMount, ...contentProps } = props;\n const context = useMenuContext(CONTENT_NAME, props.__scopeMenu);\n const rootContext = useMenuRootContext(CONTENT_NAME, props.__scopeMenu);\n return /* @__PURE__ */ jsx(Collection.Provider, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(Collection.Slot, { scope: props.__scopeMenu, children: rootContext.modal ? /* @__PURE__ */ jsx(MenuRootContentModal, { ...contentProps, ref: forwardedRef }) : /* @__PURE__ */ jsx(MenuRootContentNonModal, { ...contentProps, ref: forwardedRef }) }) }) });\n }\n);\nvar MenuRootContentModal = React.forwardRef(\n (props, forwardedRef) => {\n const context = useMenuContext(CONTENT_NAME, props.__scopeMenu);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n React.useEffect(() => {\n const content = ref.current;\n if (content) return hideOthers(content);\n }, []);\n return /* @__PURE__ */ jsx(\n MenuContentImpl,\n {\n ...props,\n ref: composedRefs,\n trapFocus: context.open,\n disableOutsidePointerEvents: context.open,\n disableOutsideScroll: true,\n onFocusOutside: composeEventHandlers(\n props.onFocusOutside,\n (event) => event.preventDefault(),\n { checkForDefaultPrevented: false }\n ),\n onDismiss: () => context.onOpenChange(false)\n }\n );\n }\n);\nvar MenuRootContentNonModal = React.forwardRef((props, forwardedRef) => {\n const context = useMenuContext(CONTENT_NAME, props.__scopeMenu);\n return /* @__PURE__ */ jsx(\n MenuContentImpl,\n {\n ...props,\n ref: forwardedRef,\n trapFocus: false,\n disableOutsidePointerEvents: false,\n disableOutsideScroll: false,\n onDismiss: () => context.onOpenChange(false)\n }\n );\n});\nvar MenuContentImpl = React.forwardRef(\n (props, forwardedRef) => {\n const {\n __scopeMenu,\n loop = false,\n trapFocus,\n onOpenAutoFocus,\n onCloseAutoFocus,\n disableOutsidePointerEvents,\n onEntryFocus,\n onEscapeKeyDown,\n onPointerDownOutside,\n onFocusOutside,\n onInteractOutside,\n onDismiss,\n disableOutsideScroll,\n ...contentProps\n } = props;\n const context = useMenuContext(CONTENT_NAME, __scopeMenu);\n const rootContext = useMenuRootContext(CONTENT_NAME, __scopeMenu);\n const popperScope = usePopperScope(__scopeMenu);\n const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeMenu);\n const getItems = useCollection(__scopeMenu);\n const [currentItemId, setCurrentItemId] = React.useState(null);\n const contentRef = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, contentRef, context.onContentChange);\n const timerRef = React.useRef(0);\n const searchRef = React.useRef(\"\");\n const pointerGraceTimerRef = React.useRef(0);\n const pointerGraceIntentRef = React.useRef(null);\n const pointerDirRef = React.useRef(\"right\");\n const lastPointerXRef = React.useRef(0);\n const ScrollLockWrapper = disableOutsideScroll ? RemoveScroll : React.Fragment;\n const scrollLockWrapperProps = disableOutsideScroll ? { as: Slot, allowPinchZoom: true } : void 0;\n const handleTypeaheadSearch = (key) => {\n const search = searchRef.current + key;\n const items = getItems().filter((item) => !item.disabled);\n const currentItem = document.activeElement;\n const currentMatch = items.find((item) => item.ref.current === currentItem)?.textValue;\n const values = items.map((item) => item.textValue);\n const nextMatch = getNextMatch(values, search, currentMatch);\n const newItem = items.find((item) => item.textValue === nextMatch)?.ref.current;\n (function updateSearch(value) {\n searchRef.current = value;\n window.clearTimeout(timerRef.current);\n if (value !== \"\") timerRef.current = window.setTimeout(() => updateSearch(\"\"), 1e3);\n })(search);\n if (newItem) {\n setTimeout(() => newItem.focus());\n }\n };\n React.useEffect(() => {\n return () => window.clearTimeout(timerRef.current);\n }, []);\n useFocusGuards();\n const isPointerMovingToSubmenu = React.useCallback((event) => {\n const isMovingTowards = pointerDirRef.current === pointerGraceIntentRef.current?.side;\n return isMovingTowards && isPointerInGraceArea(event, pointerGraceIntentRef.current?.area);\n }, []);\n return /* @__PURE__ */ jsx(\n MenuContentProvider,\n {\n scope: __scopeMenu,\n searchRef,\n onItemEnter: React.useCallback(\n (event) => {\n if (isPointerMovingToSubmenu(event)) event.preventDefault();\n },\n [isPointerMovingToSubmenu]\n ),\n onItemLeave: React.useCallback(\n (event) => {\n if (isPointerMovingToSubmenu(event)) return;\n contentRef.current?.focus();\n setCurrentItemId(null);\n },\n [isPointerMovingToSubmenu]\n ),\n onTriggerLeave: React.useCallback(\n (event) => {\n if (isPointerMovingToSubmenu(event)) event.preventDefault();\n },\n [isPointerMovingToSubmenu]\n ),\n pointerGraceTimerRef,\n onPointerGraceIntentChange: React.useCallback((intent) => {\n pointerGraceIntentRef.current = intent;\n }, []),\n children: /* @__PURE__ */ jsx(ScrollLockWrapper, { ...scrollLockWrapperProps, children: /* @__PURE__ */ jsx(\n FocusScope,\n {\n asChild: true,\n trapped: trapFocus,\n onMountAutoFocus: composeEventHandlers(onOpenAutoFocus, (event) => {\n event.preventDefault();\n contentRef.current?.focus({ preventScroll: true });\n }),\n onUnmountAutoFocus: onCloseAutoFocus,\n children: /* @__PURE__ */ jsx(\n DismissableLayer,\n {\n asChild: true,\n disableOutsidePointerEvents,\n onEscapeKeyDown,\n onPointerDownOutside,\n onFocusOutside,\n onInteractOutside,\n onDismiss,\n children: /* @__PURE__ */ jsx(\n RovingFocusGroup.Root,\n {\n asChild: true,\n ...rovingFocusGroupScope,\n dir: rootContext.dir,\n orientation: \"vertical\",\n loop,\n currentTabStopId: currentItemId,\n onCurrentTabStopIdChange: setCurrentItemId,\n onEntryFocus: composeEventHandlers(onEntryFocus, (event) => {\n if (!rootContext.isUsingKeyboardRef.current) event.preventDefault();\n }),\n preventScrollOnEntryFocus: true,\n children: /* @__PURE__ */ jsx(\n PopperPrimitive.Content,\n {\n role: \"menu\",\n \"aria-orientation\": \"vertical\",\n \"data-state\": getOpenState(context.open),\n \"data-radix-menu-content\": \"\",\n dir: rootContext.dir,\n ...popperScope,\n ...contentProps,\n ref: composedRefs,\n style: { outline: \"none\", ...contentProps.style },\n onKeyDown: composeEventHandlers(contentProps.onKeyDown, (event) => {\n const target = event.target;\n const isKeyDownInside = target.closest(\"[data-radix-menu-content]\") === event.currentTarget;\n const isModifierKey = event.ctrlKey || event.altKey || event.metaKey;\n const isCharacterKey = event.key.length === 1;\n if (isKeyDownInside) {\n if (event.key === \"Tab\") event.preventDefault();\n if (!isModifierKey && isCharacterKey) handleTypeaheadSearch(event.key);\n }\n const content = contentRef.current;\n if (event.target !== content) return;\n if (!FIRST_LAST_KEYS.includes(event.key)) return;\n event.preventDefault();\n const items = getItems().filter((item) => !item.disabled);\n const candidateNodes = items.map((item) => item.ref.current);\n if (LAST_KEYS.includes(event.key)) candidateNodes.reverse();\n focusFirst(candidateNodes);\n }),\n onBlur: composeEventHandlers(props.onBlur, (event) => {\n if (!event.currentTarget.contains(event.target)) {\n window.clearTimeout(timerRef.current);\n searchRef.current = \"\";\n }\n }),\n onPointerMove: composeEventHandlers(\n props.onPointerMove,\n whenMouse((event) => {\n const target = event.target;\n const pointerXHasChanged = lastPointerXRef.current !== event.clientX;\n if (event.currentTarget.contains(target) && pointerXHasChanged) {\n const newDir = event.clientX > lastPointerXRef.current ? \"right\" : \"left\";\n pointerDirRef.current = newDir;\n lastPointerXRef.current = event.clientX;\n }\n })\n )\n }\n )\n }\n )\n }\n )\n }\n ) })\n }\n );\n }\n);\nMenuContent.displayName = CONTENT_NAME;\nvar GROUP_NAME = \"MenuGroup\";\nvar MenuGroup = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...groupProps } = props;\n return /* @__PURE__ */ jsx(Primitive.div, { role: \"group\", ...groupProps, ref: forwardedRef });\n }\n);\nMenuGroup.displayName = GROUP_NAME;\nvar LABEL_NAME = \"MenuLabel\";\nvar MenuLabel = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...labelProps } = props;\n return /* @__PURE__ */ jsx(Primitive.div, { ...labelProps, ref: forwardedRef });\n }\n);\nMenuLabel.displayName = LABEL_NAME;\nvar ITEM_NAME = \"MenuItem\";\nvar ITEM_SELECT = \"menu.itemSelect\";\nvar MenuItem = React.forwardRef(\n (props, forwardedRef) => {\n const { disabled = false, onSelect, ...itemProps } = props;\n const ref = React.useRef(null);\n const rootContext = useMenuRootContext(ITEM_NAME, props.__scopeMenu);\n const contentContext = useMenuContentContext(ITEM_NAME, props.__scopeMenu);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const isPointerDownRef = React.useRef(false);\n const handleSelect = () => {\n const menuItem = ref.current;\n if (!disabled && menuItem) {\n const itemSelectEvent = new CustomEvent(ITEM_SELECT, { bubbles: true, cancelable: true });\n menuItem.addEventListener(ITEM_SELECT, (event) => onSelect?.(event), { once: true });\n dispatchDiscreteCustomEvent(menuItem, itemSelectEvent);\n if (itemSelectEvent.defaultPrevented) {\n isPointerDownRef.current = false;\n } else {\n rootContext.onClose();\n }\n }\n };\n return /* @__PURE__ */ jsx(\n MenuItemImpl,\n {\n ...itemProps,\n ref: composedRefs,\n disabled,\n onClick: composeEventHandlers(props.onClick, handleSelect),\n onPointerDown: (event) => {\n props.onPointerDown?.(event);\n isPointerDownRef.current = true;\n },\n onPointerUp: composeEventHandlers(props.onPointerUp, (event) => {\n if (!isPointerDownRef.current) event.currentTarget?.click();\n }),\n onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {\n const isTypingAhead = contentContext.searchRef.current !== \"\";\n if (disabled || isTypingAhead && event.key === \" \") return;\n if (SELECTION_KEYS.includes(event.key)) {\n event.currentTarget.click();\n event.preventDefault();\n }\n })\n }\n );\n }\n);\nMenuItem.displayName = ITEM_NAME;\nvar MenuItemImpl = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, disabled = false, textValue, ...itemProps } = props;\n const contentContext = useMenuContentContext(ITEM_NAME, __scopeMenu);\n const rovingFocusGroupScope = useRovingFocusGroupScope(__scopeMenu);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n const [isFocused, setIsFocused] = React.useState(false);\n const [textContent, setTextContent] = React.useState(\"\");\n React.useEffect(() => {\n const menuItem = ref.current;\n if (menuItem) {\n setTextContent((menuItem.textContent ?? \"\").trim());\n }\n }, [itemProps.children]);\n return /* @__PURE__ */ jsx(\n Collection.ItemSlot,\n {\n scope: __scopeMenu,\n disabled,\n textValue: textValue ?? textContent,\n children: /* @__PURE__ */ jsx(RovingFocusGroup.Item, { asChild: true, ...rovingFocusGroupScope, focusable: !disabled, children: /* @__PURE__ */ jsx(\n Primitive.div,\n {\n role: \"menuitem\",\n \"data-highlighted\": isFocused ? \"\" : void 0,\n \"aria-disabled\": disabled || void 0,\n \"data-disabled\": disabled ? \"\" : void 0,\n ...itemProps,\n ref: composedRefs,\n onPointerMove: composeEventHandlers(\n props.onPointerMove,\n whenMouse((event) => {\n if (disabled) {\n contentContext.onItemLeave(event);\n } else {\n contentContext.onItemEnter(event);\n if (!event.defaultPrevented) {\n const item = event.currentTarget;\n item.focus({ preventScroll: true });\n }\n }\n })\n ),\n onPointerLeave: composeEventHandlers(\n props.onPointerLeave,\n whenMouse((event) => contentContext.onItemLeave(event))\n ),\n onFocus: composeEventHandlers(props.onFocus, () => setIsFocused(true)),\n onBlur: composeEventHandlers(props.onBlur, () => setIsFocused(false))\n }\n ) })\n }\n );\n }\n);\nvar CHECKBOX_ITEM_NAME = \"MenuCheckboxItem\";\nvar MenuCheckboxItem = React.forwardRef(\n (props, forwardedRef) => {\n const { checked = false, onCheckedChange, ...checkboxItemProps } = props;\n return /* @__PURE__ */ jsx(ItemIndicatorProvider, { scope: props.__scopeMenu, checked, children: /* @__PURE__ */ jsx(\n MenuItem,\n {\n role: \"menuitemcheckbox\",\n \"aria-checked\": isIndeterminate(checked) ? \"mixed\" : checked,\n ...checkboxItemProps,\n ref: forwardedRef,\n \"data-state\": getCheckedState(checked),\n onSelect: composeEventHandlers(\n checkboxItemProps.onSelect,\n () => onCheckedChange?.(isIndeterminate(checked) ? true : !checked),\n { checkForDefaultPrevented: false }\n )\n }\n ) });\n }\n);\nMenuCheckboxItem.displayName = CHECKBOX_ITEM_NAME;\nvar RADIO_GROUP_NAME = \"MenuRadioGroup\";\nvar [RadioGroupProvider, useRadioGroupContext] = createMenuContext(\n RADIO_GROUP_NAME,\n { value: void 0, onValueChange: () => {\n } }\n);\nvar MenuRadioGroup = React.forwardRef(\n (props, forwardedRef) => {\n const { value, onValueChange, ...groupProps } = props;\n const handleValueChange = useCallbackRef(onValueChange);\n return /* @__PURE__ */ jsx(RadioGroupProvider, { scope: props.__scopeMenu, value, onValueChange: handleValueChange, children: /* @__PURE__ */ jsx(MenuGroup, { ...groupProps, ref: forwardedRef }) });\n }\n);\nMenuRadioGroup.displayName = RADIO_GROUP_NAME;\nvar RADIO_ITEM_NAME = \"MenuRadioItem\";\nvar MenuRadioItem = React.forwardRef(\n (props, forwardedRef) => {\n const { value, ...radioItemProps } = props;\n const context = useRadioGroupContext(RADIO_ITEM_NAME, props.__scopeMenu);\n const checked = value === context.value;\n return /* @__PURE__ */ jsx(ItemIndicatorProvider, { scope: props.__scopeMenu, checked, children: /* @__PURE__ */ jsx(\n MenuItem,\n {\n role: \"menuitemradio\",\n \"aria-checked\": checked,\n ...radioItemProps,\n ref: forwardedRef,\n \"data-state\": getCheckedState(checked),\n onSelect: composeEventHandlers(\n radioItemProps.onSelect,\n () => context.onValueChange?.(value),\n { checkForDefaultPrevented: false }\n )\n }\n ) });\n }\n);\nMenuRadioItem.displayName = RADIO_ITEM_NAME;\nvar ITEM_INDICATOR_NAME = \"MenuItemIndicator\";\nvar [ItemIndicatorProvider, useItemIndicatorContext] = createMenuContext(\n ITEM_INDICATOR_NAME,\n { checked: false }\n);\nvar MenuItemIndicator = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, forceMount, ...itemIndicatorProps } = props;\n const indicatorContext = useItemIndicatorContext(ITEM_INDICATOR_NAME, __scopeMenu);\n return /* @__PURE__ */ jsx(\n Presence,\n {\n present: forceMount || isIndeterminate(indicatorContext.checked) || indicatorContext.checked === true,\n children: /* @__PURE__ */ jsx(\n Primitive.span,\n {\n ...itemIndicatorProps,\n ref: forwardedRef,\n \"data-state\": getCheckedState(indicatorContext.checked)\n }\n )\n }\n );\n }\n);\nMenuItemIndicator.displayName = ITEM_INDICATOR_NAME;\nvar SEPARATOR_NAME = \"MenuSeparator\";\nvar MenuSeparator = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...separatorProps } = props;\n return /* @__PURE__ */ jsx(\n Primitive.div,\n {\n role: \"separator\",\n \"aria-orientation\": \"horizontal\",\n ...separatorProps,\n ref: forwardedRef\n }\n );\n }\n);\nMenuSeparator.displayName = SEPARATOR_NAME;\nvar ARROW_NAME = \"MenuArrow\";\nvar MenuArrow = React.forwardRef(\n (props, forwardedRef) => {\n const { __scopeMenu, ...arrowProps } = props;\n const popperScope = usePopperScope(__scopeMenu);\n return /* @__PURE__ */ jsx(PopperPrimitive.Arrow, { ...popperScope, ...arrowProps, ref: forwardedRef });\n }\n);\nMenuArrow.displayName = ARROW_NAME;\nvar SUB_NAME = \"MenuSub\";\nvar [MenuSubProvider, useMenuSubContext] = createMenuContext(SUB_NAME);\nvar MenuSub = (props) => {\n const { __scopeMenu, children, open = false, onOpenChange } = props;\n const parentMenuContext = useMenuContext(SUB_NAME, __scopeMenu);\n const popperScope = usePopperScope(__scopeMenu);\n const [trigger, setTrigger] = React.useState(null);\n const [content, setContent] = React.useState(null);\n const handleOpenChange = useCallbackRef(onOpenChange);\n React.useEffect(() => {\n if (parentMenuContext.open === false) handleOpenChange(false);\n return () => handleOpenChange(false);\n }, [parentMenuContext.open, handleOpenChange]);\n return /* @__PURE__ */ jsx(PopperPrimitive.Root, { ...popperScope, children: /* @__PURE__ */ jsx(\n MenuProvider,\n {\n scope: __scopeMenu,\n open,\n onOpenChange: handleOpenChange,\n content,\n onContentChange: setContent,\n children: /* @__PURE__ */ jsx(\n MenuSubProvider,\n {\n scope: __scopeMenu,\n contentId: useId(),\n triggerId: useId(),\n trigger,\n onTriggerChange: setTrigger,\n children\n }\n )\n }\n ) });\n};\nMenuSub.displayName = SUB_NAME;\nvar SUB_TRIGGER_NAME = \"MenuSubTrigger\";\nvar MenuSubTrigger = React.forwardRef(\n (props, forwardedRef) => {\n const context = useMenuContext(SUB_TRIGGER_NAME, props.__scopeMenu);\n const rootContext = useMenuRootContext(SUB_TRIGGER_NAME, props.__scopeMenu);\n const subContext = useMenuSubContext(SUB_TRIGGER_NAME, props.__scopeMenu);\n const contentContext = useMenuContentContext(SUB_TRIGGER_NAME, props.__scopeMenu);\n const openTimerRef = React.useRef(null);\n const { pointerGraceTimerRef, onPointerGraceIntentChange } = contentContext;\n const scope = { __scopeMenu: props.__scopeMenu };\n const clearOpenTimer = React.useCallback(() => {\n if (openTimerRef.current) window.clearTimeout(openTimerRef.current);\n openTimerRef.current = null;\n }, []);\n React.useEffect(() => clearOpenTimer, [clearOpenTimer]);\n React.useEffect(() => {\n const pointerGraceTimer = pointerGraceTimerRef.current;\n return () => {\n window.clearTimeout(pointerGraceTimer);\n onPointerGraceIntentChange(null);\n };\n }, [pointerGraceTimerRef, onPointerGraceIntentChange]);\n return /* @__PURE__ */ jsx(MenuAnchor, { asChild: true, ...scope, children: /* @__PURE__ */ jsx(\n MenuItemImpl,\n {\n id: subContext.triggerId,\n \"aria-haspopup\": \"menu\",\n \"aria-expanded\": context.open,\n \"aria-controls\": subContext.contentId,\n \"data-state\": getOpenState(context.open),\n ...props,\n ref: composeRefs(forwardedRef, subContext.onTriggerChange),\n onClick: (event) => {\n props.onClick?.(event);\n if (props.disabled || event.defaultPrevented) return;\n event.currentTarget.focus();\n if (!context.open) context.onOpenChange(true);\n },\n onPointerMove: composeEventHandlers(\n props.onPointerMove,\n whenMouse((event) => {\n contentContext.onItemEnter(event);\n if (event.defaultPrevented) return;\n if (!props.disabled && !context.open && !openTimerRef.current) {\n contentContext.onPointerGraceIntentChange(null);\n openTimerRef.current = window.setTimeout(() => {\n context.onOpenChange(true);\n clearOpenTimer();\n }, 100);\n }\n })\n ),\n onPointerLeave: composeEventHandlers(\n props.onPointerLeave,\n whenMouse((event) => {\n clearOpenTimer();\n const contentRect = context.content?.getBoundingClientRect();\n if (contentRect) {\n const side = context.content?.dataset.side;\n const rightSide = side === \"right\";\n const bleed = rightSide ? -5 : 5;\n const contentNearEdge = contentRect[rightSide ? \"left\" : \"right\"];\n const contentFarEdge = contentRect[rightSide ? \"right\" : \"left\"];\n contentContext.onPointerGraceIntentChange({\n area: [\n // Apply a bleed on clientX to ensure that our exit point is\n // consistently within polygon bounds\n { x: event.clientX + bleed, y: event.clientY },\n { x: contentNearEdge, y: contentRect.top },\n { x: contentFarEdge, y: contentRect.top },\n { x: contentFarEdge, y: contentRect.bottom },\n { x: contentNearEdge, y: contentRect.bottom }\n ],\n side\n });\n window.clearTimeout(pointerGraceTimerRef.current);\n pointerGraceTimerRef.current = window.setTimeout(\n () => contentContext.onPointerGraceIntentChange(null),\n 300\n );\n } else {\n contentContext.onTriggerLeave(event);\n if (event.defaultPrevented) return;\n contentContext.onPointerGraceIntentChange(null);\n }\n })\n ),\n onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {\n const isTypingAhead = contentContext.searchRef.current !== \"\";\n if (props.disabled || isTypingAhead && event.key === \" \") return;\n if (SUB_OPEN_KEYS[rootContext.dir].includes(event.key)) {\n context.onOpenChange(true);\n context.content?.focus();\n event.preventDefault();\n }\n })\n }\n ) });\n }\n);\nMenuSubTrigger.displayName = SUB_TRIGGER_NAME;\nvar SUB_CONTENT_NAME = \"MenuSubContent\";\nvar MenuSubContent = React.forwardRef(\n (props, forwardedRef) => {\n const portalContext = usePortalContext(CONTENT_NAME, props.__scopeMenu);\n const { forceMount = portalContext.forceMount, ...subContentProps } = props;\n const context = useMenuContext(CONTENT_NAME, props.__scopeMenu);\n const rootContext = useMenuRootContext(CONTENT_NAME, props.__scopeMenu);\n const subContext = useMenuSubContext(SUB_CONTENT_NAME, props.__scopeMenu);\n const ref = React.useRef(null);\n const composedRefs = useComposedRefs(forwardedRef, ref);\n return /* @__PURE__ */ jsx(Collection.Provider, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsx(Presence, { present: forceMount || context.open, children: /* @__PURE__ */ jsx(Collection.Slot, { scope: props.__scopeMenu, children: /* @__PURE__ */ jsx(\n MenuContentImpl,\n {\n id: subContext.contentId,\n \"aria-labelledby\": subContext.triggerId,\n ...subContentProps,\n ref: composedRefs,\n align: \"start\",\n side: rootContext.dir === \"rtl\" ? \"left\" : \"right\",\n disableOutsidePointerEvents: false,\n disableOutsideScroll: false,\n trapFocus: false,\n onOpenAutoFocus: (event) => {\n if (rootContext.isUsingKeyboardRef.current) ref.current?.focus();\n event.preventDefault();\n },\n onCloseAutoFocus: (event) => event.preventDefault(),\n onFocusOutside: composeEventHandlers(props.onFocusOutside, (event) => {\n if (event.target !== subContext.trigger) context.onOpenChange(false);\n }),\n onEscapeKeyDown: composeEventHandlers(props.onEscapeKeyDown, (event) => {\n rootContext.onClose();\n event.preventDefault();\n }),\n onKeyDown: composeEventHandlers(props.onKeyDown, (event) => {\n const isKeyDownInside = event.currentTarget.contains(event.target);\n const isCloseKey = SUB_CLOSE_KEYS[rootContext.dir].includes(event.key);\n if (isKeyDownInside && isCloseKey) {\n context.onOpenChange(false);\n subContext.trigger?.focus();\n event.preventDefault();\n }\n })\n }\n ) }) }) });\n }\n);\nMenuSubContent.displayName = SUB_CONTENT_NAME;\nfunction getOpenState(open) {\n return open ? \"open\" : \"closed\";\n}\nfunction isIndeterminate(checked) {\n return checked === \"indeterminate\";\n}\nfunction getCheckedState(checked) {\n return isIndeterminate(checked) ? \"indeterminate\" : checked ? \"checked\" : \"unchecked\";\n}\nfunction focusFirst(candidates) {\n const PREVIOUSLY_FOCUSED_ELEMENT = document.activeElement;\n for (const candidate of candidates) {\n if (candidate === PREVIOUSLY_FOCUSED_ELEMENT) return;\n candidate.focus();\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}\nfunction getNextMatch(values, search, currentMatch) {\n const isRepeated = search.length > 1 && Array.from(search).every((char) => char === search[0]);\n const normalizedSearch = isRepeated ? search[0] : search;\n const currentMatchIndex = currentMatch ? values.indexOf(currentMatch) : -1;\n let wrappedValues = wrapArray(values, Math.max(currentMatchIndex, 0));\n const excludeCurrentMatch = normalizedSearch.length === 1;\n if (excludeCurrentMatch) wrappedValues = wrappedValues.filter((v) => v !== currentMatch);\n const nextMatch = wrappedValues.find(\n (value) => value.toLowerCase().startsWith(normalizedSearch.toLowerCase())\n );\n return nextMatch !== currentMatch ? nextMatch : void 0;\n}\nfunction isPointInPolygon(point, polygon) {\n const { x, y } = point;\n let inside = false;\n for (let i = 0, j = polygon.length - 1; i < polygon.length; j = i++) {\n const xi = polygon[i].x;\n const yi = polygon[i].y;\n const xj = polygon[j].x;\n const yj = polygon[j].y;\n const intersect = yi > y !== yj > y && x < (xj - xi) * (y - yi) / (yj - yi) + xi;\n if (intersect) inside = !inside;\n }\n return inside;\n}\nfunction isPointerInGraceArea(event, area) {\n if (!area) return false;\n const cursorPos = { x: event.clientX, y: event.clientY };\n return isPointInPolygon(cursorPos, area);\n}\nfunction whenMouse(handler) {\n return (event) => event.pointerType === \"mouse\" ? handler(event) : void 0;\n}\nvar Root3 = Menu;\nvar Anchor2 = MenuAnchor;\nvar Portal = MenuPortal;\nvar Content2 = MenuContent;\nvar Group = MenuGroup;\nvar Label = MenuLabel;\nvar Item2 = MenuItem;\nvar CheckboxItem = MenuCheckboxItem;\nvar RadioGroup = MenuRadioGroup;\nvar RadioItem = MenuRadioItem;\nvar ItemIndicator = MenuItemIndicator;\nvar Separator = MenuSeparator;\nvar Arrow2 = MenuArrow;\nvar Sub = MenuSub;\nvar SubTrigger = MenuSubTrigger;\nvar SubContent = MenuSubContent;\nexport {\n Anchor2 as Anchor,\n Arrow2 as Arrow,\n CheckboxItem,\n Content2 as Content,\n Group,\n Item2 as Item,\n ItemIndicator,\n Label,\n Menu,\n MenuAnchor,\n MenuArrow,\n MenuCheckboxItem,\n MenuContent,\n MenuGroup,\n MenuItem,\n MenuItemIndicator,\n MenuLabel,\n MenuPortal,\n MenuRadioGroup,\n MenuRadioItem,\n MenuSeparator,\n MenuSub,\n MenuSubContent,\n MenuSubTrigger,\n Portal,\n RadioGroup,\n RadioItem,\n Root3 as Root,\n Separator,\n Sub,\n SubContent,\n SubTrigger,\n createMenuScope\n};\n//# sourceMappingURL=index.mjs.map\n"],"names":["SELECTION_KEYS","LAST_KEYS","FIRST_LAST_KEYS","SUB_OPEN_KEYS","ltr","rtl","SUB_CLOSE_KEYS","MENU_NAME","Collection","useCollection","createCollectionScope","createCollection","createMenuContext","createMenuScope","createContextScope","createPopperScope","createRovingFocusGroupScope","usePopperScope","useRovingFocusGroupScope","MenuProvider","useMenuContext","MenuRootProvider","useMenuRootContext","Menu","props","__scopeMenu","open","children","dir","onOpenChange","modal","popperScope","content","setContent","React","useState","isUsingKeyboardRef","useRef","handleOpenChange","useCallbackRef","direction","useDirection","useEffect","handleKeyDown","current","document","addEventListener","handlePointer","capture","once","removeEventListener","jsx","PopperPrimitive.Root","scope","onContentChange","onClose","useCallback","displayName","MenuAnchor","forwardRef","forwardedRef","anchorProps","PopperPrimitive.Anchor","ref","PORTAL_NAME","PortalProvider","usePortalContext","forceMount","MenuPortal","container","context","Presence","present","PortalPrimitive","asChild","CONTENT_NAME","MenuContentProvider","useMenuContentContext","MenuContent","portalContext","contentProps","rootContext","Provider","Slot","MenuRootContentModal","MenuRootContentNonModal","composedRefs","useComposedRefs","hideOthers","MenuContentImpl","trapFocus","disableOutsidePointerEvents","disableOutsideScroll","onFocusOutside","composeEventHandlers","event","preventDefault","checkForDefaultPrevented","onDismiss","loop","onOpenAutoFocus","onCloseAutoFocus","onEntryFocus","onEscapeKeyDown","onPointerDownOutside","onInteractOutside","rovingFocusGroupScope","getItems","currentItemId","setCurrentItemId","contentRef","timerRef","searchRef","pointerGraceTimerRef","pointerGraceIntentRef","pointerDirRef","lastPointerXRef","ScrollLockWrapper","RemoveScroll","Fragment","scrollLockWrapperProps","as","allowPinchZoom","handleTypeaheadSearch","key","search","items","filter","item","disabled","currentItem","activeElement","currentMatch","find","textValue","nextMatch","values","isRepeated","length","Array","from","every","char","normalizedSearch","currentMatchIndex","indexOf","wrappedValues","array","startIndex","Math","max","map","_","index","v","value","toLowerCase","startsWith","getNextMatch","newItem","updateSearch","window","clearTimeout","setTimeout","focus","useFocusGuards","isPointerMovingToSubmenu","side","area","cursorPos","x","clientX","y","clientY","point","polygon","inside","i","j","xi","yi","xj","yj","isPointInPolygon","isPointerInGraceArea","onItemEnter","onItemLeave","onTriggerLeave","onPointerGraceIntentChange","intent","FocusScope","trapped","onMountAutoFocus","preventScroll","onUnmountAutoFocus","DismissableLayer","RovingFocusGroup.Root","orientation","currentTabStopId","onCurrentTabStopIdChange","preventScrollOnEntryFocus","PopperPrimitive.Content","role","getOpenState","style","outline","onKeyDown","isKeyDownInside","target","closest","currentTarget","isModifierKey","ctrlKey","altKey","metaKey","isCharacterKey","includes","candidateNodes","reverse","candidates","PREVIOUSLY_FOCUSED_ELEMENT","candidate","focusFirst","onBlur","contains","onPointerMove","whenMouse","pointerXHasChanged","newDir","MenuGroup","groupProps","Primitive","div","MenuLabel","labelProps","ITEM_NAME","ITEM_SELECT","MenuItem","onSelect","itemProps","contentContext","isPointerDownRef","MenuItemImpl","onClick","menuItem","itemSelectEvent","CustomEvent","bubbles","cancelable","dispatchDiscreteCustomEvent","defaultPrevented","onPointerDown","onPointerUp","click","isTypingAhead","isFocused","setIsFocused","textContent","setTextContent","trim","ItemSlot","RovingFocusGroup.Item","focusable","onPointerLeave","onFocus","MenuCheckboxItem","checked","onCheckedChange","checkboxItemProps","ItemIndicatorProvider","isIndeterminate","getCheckedState","RADIO_GROUP_NAME","RadioGroupProvider","useRadioGroupContext","onValueChange","MenuRadioGroup","handleValueChange","RADIO_ITEM_NAME","MenuRadioItem","radioItemProps","ITEM_INDICATOR_NAME","useItemIndicatorContext","MenuItemIndicator","itemIndicatorProps","indicatorContext","span","MenuSeparator","separatorProps","MenuArrow","arrowProps","PopperPrimitive.Arrow","SUB_NAME","MenuSubProvider","useMenuSubContext","MenuSub","parentMenuContext","trigger","setTrigger","contentId","useId","triggerId","onTriggerChange","SUB_TRIGGER_NAME","MenuSubTrigger","subContext","openTimerRef","clearOpenTimer","pointerGraceTimer","id","composeRefs","contentRect","getBoundingClientRect","dataset","rightSide","bleed","contentNearEdge","contentFarEdge","top","bottom","SUB_CONTENT_NAME","MenuSubContent","subContentProps","align","isCloseKey","handler","pointerType","Root3","Anchor2","Portal","Content2","Group","Label","Item2","CheckboxItem","RadioGroup","RadioItem","ItemIndicator","Separator","Arrow2","Sub","SubTrigger","SubContent"],"mappings":"o3CAyBA,IAAIA,EAAiB,CAAC,QAAS,K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@ -1,2 +1,2 @@
1
- import*as e from"react";import*as t from"react-dom";import{clamp as o}from"../../number/dist/index.mjs";import{composeEventHandlers as n}from"../../primitive/dist/index.mjs";import{createCollection as r}from"../../react-collection/dist/index.mjs";import{useComposedRefs as i}from"../../react-compose-refs/dist/index.mjs";import{createContextScope as l}from"../../react-context/dist/index.mjs";import{useDirection as a}from"../../react-direction/dist/index.mjs";import{DismissableLayer as s}from"../../react-dismissable-layer/dist/index.mjs";import{useFocusGuards as c}from"../../react-focus-guards/dist/index.mjs";import{FocusScope as d}from"../../react-focus-scope/dist/index.mjs";import{useId as u}from"../../react-id/dist/index.mjs";import{createPopperScope as p,Anchor as f,Content as m,Arrow as h,Root as v}from"../../react-popper/dist/index.mjs";import{Portal as g}from"../../react-portal/dist/index.mjs";import{Primitive as x}from"../../react-primitive/dist/index.mjs";import{Slot as w}from"../../react-slot/dist/index.mjs";import{useCallbackRef as y}from"../../react-use-callback-ref/dist/index.mjs";import{useControllableState as S}from"../../react-use-controllable-state/dist/index.mjs";import{useLayoutEffect as b}from"../../react-use-layout-effect/dist/index.mjs";import{usePrevious as C}from"../../react-use-previous/dist/index.mjs";import{VisuallyHidden as j}from"../../react-visually-hidden/dist/index.mjs";import{hideOthers as _}from"../../../aria-hidden/dist/es2015/index.mjs";import P from"../../../react-remove-scroll/dist/es2015/Combination.mjs";import{j as R}from"../../../../_virtual/jsx-runtime.mjs";var I=[" ","Enter","ArrowUp","ArrowDown"],T=[" ","Enter"],k="Select",[E,D,N]=r(k),[L,M]=l(k,[N,p]),O=p(),[H,A]=L(k),[B,V]=L(k),K=t=>{const{__scopeSelect:o,children:n,open:r,defaultOpen:i,onOpenChange:l,value:s,defaultValue:c,onValueChange:d,dir:p,name:f,autoComplete:m,disabled:h,required:g}=t,x=O(o),[w,y]=e.useState(null),[b,C]=e.useState(null),[j,_]=e.useState(!1),P=a(p),[I=!1,T]=S({prop:r,defaultProp:i,onChange:l}),[k,D]=S({prop:s,defaultProp:c,onChange:d}),N=e.useRef(null),L=!w||Boolean(w.closest("form")),[M,A]=e.useState(new Set),V=Array.from(M).map((e=>e.props.value)).join(";");return R.jsx(v,{...x,children:R.jsxs(H,{required:g,scope:o,trigger:w,onTriggerChange:y,valueNode:b,onValueNodeChange:C,valueNodeHasChildren:j,onValueNodeHasChildrenChange:_,contentId:u(),value:k,onValueChange:D,open:I,onOpenChange:T,dir:P,triggerPointerDownPosRef:N,disabled:h,children:[R.jsx(E.Provider,{scope:o,children:R.jsx(B,{scope:t.__scopeSelect,onNativeOptionAdd:e.useCallback((e=>{A((t=>new Set(t).add(e)))}),[]),onNativeOptionRemove:e.useCallback((e=>{A((t=>{const o=new Set(t);return o.delete(e),o}))}),[]),children:n})}),L?R.jsxs(Te,{"aria-hidden":!0,required:g,tabIndex:-1,name:f,autoComplete:m,value:k,onChange:e=>D(e.target.value),disabled:h,children:[void 0===k?R.jsx("option",{value:""}):null,Array.from(M)]},V):null]})})};K.displayName=k;var F="SelectTrigger",W=e.forwardRef(((e,t)=>{const{__scopeSelect:o,disabled:r=!1,...l}=e,a=O(o),s=A(F,o),c=s.disabled||r,d=i(t,s.onTriggerChange),u=D(o),[p,m,h]=ke((e=>{const t=u().filter((e=>!e.disabled)),o=t.find((e=>e.value===s.value)),n=Ee(t,e,o);void 0!==n&&s.onValueChange(n.value)})),v=()=>{c||(s.onOpenChange(!0),h())};return R.jsx(f,{asChild:!0,...a,children:R.jsx(x.button,{type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:c,"data-disabled":c?"":void 0,"data-placeholder":Ie(s.value)?"":void 0,...l,ref:d,onClick:n(l.onClick,(e=>{e.currentTarget.focus()})),onPointerDown:n(l.onPointerDown,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&(v(),s.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)},e.preventDefault())})),onKeyDown:n(l.onKeyDown,(e=>{const t=""!==p.current;e.ctrlKey||e.altKey||e.metaKey||1!==e.key.length||m(e.key),t&&" "===e.key||I.includes(e.key)&&(v(),e.preventDefault())}))})})}));W.displayName=F;var U="SelectValue",q=e.forwardRef(((e,t)=>{const{__scopeSelect:o,className:n,style:r,children:l,placeholder:a="",...s}=e,c=A(U,o),{onValueNodeHasChildrenChange:d}=c,u=void 0!==l,p=i(t,c.onValueNodeChange);return b((()=>{d(u)}),[d,u]),R.jsx(x.span,{...s,ref:p,style:{pointerEvents:"none"},children:Ie(c.value)?R.jsx(R.Fragment,{children:a}):l})}));q.displayName=U;var z=e.forwardRef(((e,t)=>{const{__scopeSelect:o,children:n,...r}=e;return R.jsx(x.span,{"aria-hidden":!0,...r,ref:t,children:n||"▼"})}));z.displayName="SelectIcon";var X=e=>R.jsx(g,{asChild:!0,...e});X.displayName="SelectPortal";var Y="SelectContent",G=e.forwardRef(((o,n)=>{const r=A(Y,o.__scopeSelect),[i,l]=e.useState();if(b((()=>{l(new DocumentFragment)}),[]),!r.open){const e=i;return e?t.createPortal(R.jsx($,{scope:o.__scopeSelect,children:R.jsx(E.Slot,{scope:o.__scopeSelect,children:R.jsx("div",{children:o.children})})}),e):null}return R.jsx(Q,{...o,ref:n})}));G.displayName=Y;var Z=10,[$,J]=L(Y),Q=e.forwardRef(((t,o)=>{const{__scopeSelect:r,position:l="item-aligned",onCloseAutoFocus:a,onEscapeKeyDown:u,onPointerDownOutside:p,side:f,sideOffset:m,align:h,alignOffset:v,arrowPadding:g,collisionBoundary:x,collisionPadding:y,sticky:S,hideWhenDetached:b,avoidCollisions:C,...j}=t,I=A(Y,r),[T,k]=e.useState(null),[E,N]=e.useState(null),L=i(o,(e=>k(e))),[M,O]=e.useState(null),[H,B]=e.useState(null),V=D(r),[K,F]=e.useState(!1),W=e.useRef(!1);e.useEffect((()=>{if(T)return _(T)}),[T]),c();const U=e.useCallback((e=>{const[t,...o]=V().map((e=>e.ref.current)),[n]=o.slice(-1),r=document.activeElement;for(const o of e){if(o===r)return;if(o?.scrollIntoView({block:"nearest"}),o===t&&E&&(E.scrollTop=0),o===n&&E&&(E.scrollTop=E.scrollHeight),o?.focus(),document.activeElement!==r)return}}),[V,E]),q=e.useCallback((()=>U([M,T])),[U,M,T]);e.useEffect((()=>{K&&q()}),[K,q]);const{onOpenChange:z,triggerPointerDownPosRef:X}=I;e.useEffect((()=>{if(T){let e={x:0,y:0};const t=t=>{e={x:Math.abs(Math.round(t.pageX)-(X.current?.x??0)),y:Math.abs(Math.round(t.pageY)-(X.current?.y??0))}},o=o=>{e.x<=10&&e.y<=10?o.preventDefault():T.contains(o.target)||z(!1),document.removeEventListener("pointermove",t),X.current=null};return null!==X.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",o,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",o,{capture:!0})}}}),[T,z,X]),e.useEffect((()=>{const e=()=>z(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}}),[z]);const[G,Z]=ke((e=>{const t=V().filter((e=>!e.disabled)),o=t.find((e=>e.ref.current===document.activeElement)),n=Ee(t,e,o);n&&setTimeout((()=>n.ref.current.focus()))})),J=e.useCallback(((e,t,o)=>{const n=!W.current&&!o;(void 0!==I.value&&I.value===t||n)&&(O(e),n&&(W.current=!0))}),[I.value]),Q=e.useCallback((()=>T?.focus()),[T]),oe=e.useCallback(((e,t,o)=>{const n=!W.current&&!o;(void 0!==I.value&&I.value===t||n)&&B(e)}),[I.value]),ne="popper"===l?te:ee,re=ne===te?{side:f,sideOffset:m,align:h,alignOffset:v,arrowPadding:g,collisionBoundary:x,collisionPadding:y,sticky:S,hideWhenDetached:b,avoidCollisions:C}:{};return R.jsx($,{scope:r,content:T,viewport:E,onViewportChange:N,itemRefCallback:J,selectedItem:M,onItemLeave:Q,itemTextRefCallback:oe,focusSelectedItem:q,selectedItemText:H,position:l,isPositioned:K,searchRef:G,children:R.jsx(P,{as:w,allowPinchZoom:!0,children:R.jsx(d,{asChild:!0,trapped:I.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:n(a,(e=>{I.trigger?.focus({preventScroll:!0}),e.preventDefault()})),children:R.jsx(s,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:u,onPointerDownOutside:p,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>I.onOpenChange(!1),children:R.jsx(ne,{role:"listbox",id:I.contentId,"data-state":I.open?"open":"closed",dir:I.dir,onContextMenu:e=>e.preventDefault(),...j,...re,onPlaced:()=>F(!0),ref:L,style:{display:"flex",flexDirection:"column",outline:"none",...j.style},onKeyDown:n(j.onKeyDown,(e=>{const t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),t||1!==e.key.length||Z(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=V().filter((e=>!e.disabled)).map((e=>e.ref.current));if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){const o=e.target,n=t.indexOf(o);t=t.slice(n+1)}setTimeout((()=>U(t))),e.preventDefault()}}))})})})})})}));Q.displayName="SelectContentImpl";var ee=e.forwardRef(((t,n)=>{const{__scopeSelect:r,onPlaced:l,...a}=t,s=A(Y,r),c=J(Y,r),[d,u]=e.useState(null),[p,f]=e.useState(null),m=i(n,(e=>f(e))),h=D(r),v=e.useRef(!1),g=e.useRef(!0),{viewport:w,selectedItem:y,selectedItemText:S,focusSelectedItem:C}=c,j=e.useCallback((()=>{if(s.trigger&&s.valueNode&&d&&p&&w&&y&&S){const e=s.trigger.getBoundingClientRect(),t=p.getBoundingClientRect(),n=s.valueNode.getBoundingClientRect(),r=S.getBoundingClientRect();if("rtl"!==s.dir){const i=r.left-t.left,l=n.left-i,a=e.left-l,s=e.width+a,c=Math.max(s,t.width),u=window.innerWidth-Z,p=o(l,[Z,u-c]);d.style.minWidth=s+"px",d.style.left=p+"px"}else{const i=t.right-r.right,l=window.innerWidth-n.right-i,a=window.innerWidth-e.right-l,s=e.width+a,c=Math.max(s,t.width),u=window.innerWidth-Z,p=o(l,[Z,u-c]);d.style.minWidth=s+"px",d.style.right=p+"px"}const i=h(),a=window.innerHeight-2*Z,c=w.scrollHeight,u=window.getComputedStyle(p),f=parseInt(u.borderTopWidth,10),m=parseInt(u.paddingTop,10),g=parseInt(u.borderBottomWidth,10),x=f+m+c+parseInt(u.paddingBottom,10)+g,b=Math.min(5*y.offsetHeight,x),C=window.getComputedStyle(w),j=parseInt(C.paddingTop,10),_=parseInt(C.paddingBottom,10),P=e.top+e.height/2-Z,R=a-P,I=y.offsetHeight/2,T=f+m+(y.offsetTop+I),k=x-T;if(T<=P){const e=y===i[i.length-1].ref.current;d.style.bottom="0px";const t=p.clientHeight-w.offsetTop-w.offsetHeight,o=T+Math.max(R,I+(e?_:0)+t+g);d.style.height=o+"px"}else{const e=y===i[0].ref.current;d.style.top="0px";const t=Math.max(P,f+w.offsetTop+(e?j:0)+I)+k;d.style.height=t+"px",w.scrollTop=T-P+w.offsetTop}d.style.margin=`${Z}px 0`,d.style.minHeight=b+"px",d.style.maxHeight=a+"px",l?.(),requestAnimationFrame((()=>v.current=!0))}}),[h,s.trigger,s.valueNode,d,p,w,y,S,s.dir,l]);b((()=>j()),[j]);const[_,P]=e.useState();b((()=>{p&&P(window.getComputedStyle(p).zIndex)}),[p]);const I=e.useCallback((e=>{e&&!0===g.current&&(j(),C?.(),g.current=!1)}),[j,C]);return R.jsx(oe,{scope:r,contentWrapper:d,shouldExpandOnScrollRef:v,onScrollButtonChange:I,children:R.jsx("div",{ref:u,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:_},children:R.jsx(x.div,{...a,ref:m,style:{boxSizing:"border-box",maxHeight:"100%",...a.style}})})})}));ee.displayName="SelectItemAlignedPosition";var te=e.forwardRef(((e,t)=>{const{__scopeSelect:o,align:n="start",collisionPadding:r=Z,...i}=e,l=O(o);return R.jsx(m,{...l,...i,ref:t,align:n,collisionPadding:r,style:{boxSizing:"border-box",...i.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})}));te.displayName="SelectPopperPosition";var[oe,ne]=L(Y,{}),re="SelectViewport",ie=e.forwardRef(((t,o)=>{const{__scopeSelect:r,nonce:l,...a}=t,s=J(re,r),c=ne(re,r),d=i(o,s.onViewportChange),u=e.useRef(0);return R.jsxs(R.Fragment,{children:[R.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:l}),R.jsx(E.Slot,{scope:r,children:R.jsx(x.div,{"data-radix-select-viewport":"",role:"presentation",...a,ref:d,style:{position:"relative",flex:1,overflow:"auto",...a.style},onScroll:n(a.onScroll,(e=>{const t=e.currentTarget,{contentWrapper:o,shouldExpandOnScrollRef:n}=c;if(n?.current&&o){const e=Math.abs(u.current-t.scrollTop);if(e>0){const n=window.innerHeight-2*Z,r=parseFloat(o.style.minHeight),i=parseFloat(o.style.height),l=Math.max(r,i);if(l<n){const r=l+e,i=Math.min(n,r),a=r-i;o.style.height=i+"px","0px"===o.style.bottom&&(t.scrollTop=a>0?a:0,o.style.justifyContent="flex-end")}}}u.current=t.scrollTop}))})})]})}));ie.displayName=re;var le="SelectGroup",[ae,se]=L(le),ce=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e,r=u();return R.jsx(ae,{scope:o,id:r,children:R.jsx(x.div,{role:"group","aria-labelledby":r,...n,ref:t})})}));ce.displayName=le;var de="SelectLabel",ue=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e,r=se(de,o);return R.jsx(x.div,{id:r.id,...n,ref:t})}));ue.displayName=de;var pe="SelectItem",[fe,me]=L(pe),he=e.forwardRef(((t,o)=>{const{__scopeSelect:r,value:l,disabled:a=!1,textValue:s,...c}=t,d=A(pe,r),p=J(pe,r),f=d.value===l,[m,h]=e.useState(s??""),[v,g]=e.useState(!1),w=i(o,(e=>p.itemRefCallback?.(e,l,a))),y=u(),S=()=>{a||(d.onValueChange(l),d.onOpenChange(!1))};if(""===l)throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return R.jsx(fe,{scope:r,value:l,disabled:a,textId:y,isSelected:f,onItemTextChange:e.useCallback((e=>{h((t=>t||(e?.textContent??"").trim()))}),[]),children:R.jsx(E.ItemSlot,{scope:r,value:l,disabled:a,textValue:m,children:R.jsx(x.div,{role:"option","aria-labelledby":y,"data-highlighted":v?"":void 0,"aria-selected":f&&v,"data-state":f?"checked":"unchecked","aria-disabled":a||void 0,"data-disabled":a?"":void 0,tabIndex:a?void 0:-1,...c,ref:w,onFocus:n(c.onFocus,(()=>g(!0))),onBlur:n(c.onBlur,(()=>g(!1))),onPointerUp:n(c.onPointerUp,S),onPointerMove:n(c.onPointerMove,(e=>{a?p.onItemLeave?.():e.currentTarget.focus({preventScroll:!0})})),onPointerLeave:n(c.onPointerLeave,(e=>{e.currentTarget===document.activeElement&&p.onItemLeave?.()})),onKeyDown:n(c.onKeyDown,(e=>{""!==p.searchRef?.current&&" "===e.key||(T.includes(e.key)&&S()," "===e.key&&e.preventDefault())}))})})})}));he.displayName=pe;var ve="SelectItemText",ge=e.forwardRef(((o,n)=>{const{__scopeSelect:r,className:l,style:a,...s}=o,c=A(ve,r),d=J(ve,r),u=me(ve,r),p=V(ve,r),[f,m]=e.useState(null),h=i(n,(e=>m(e)),u.onItemTextChange,(e=>d.itemTextRefCallback?.(e,u.value,u.disabled))),v=f?.textContent,g=e.useMemo((()=>R.jsx("option",{value:u.value,disabled:u.disabled,children:v},u.value)),[u.disabled,u.value,v]),{onNativeOptionAdd:w,onNativeOptionRemove:y}=p;return b((()=>(w(g),()=>y(g))),[w,y,g]),R.jsxs(R.Fragment,{children:[R.jsx(x.span,{id:u.textId,...s,ref:h}),u.isSelected&&c.valueNode&&!c.valueNodeHasChildren?t.createPortal(s.children,c.valueNode):null]})}));ge.displayName=ve;var xe="SelectItemIndicator",we=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e;return me(xe,o).isSelected?R.jsx(x.span,{"aria-hidden":!0,...n,ref:t}):null}));we.displayName=xe;var ye="SelectScrollUpButton",Se=e.forwardRef(((t,o)=>{const n=J(ye,t.__scopeSelect),r=ne(ye,t.__scopeSelect),[l,a]=e.useState(!1),s=i(o,r.onScrollButtonChange);return b((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollTop>0;a(e)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),l?R.jsx(je,{...t,ref:s,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}}):null}));Se.displayName=ye;var be="SelectScrollDownButton",Ce=e.forwardRef(((t,o)=>{const n=J(be,t.__scopeSelect),r=ne(be,t.__scopeSelect),[l,a]=e.useState(!1),s=i(o,r.onScrollButtonChange);return b((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollHeight-t.clientHeight,o=Math.ceil(t.scrollTop)<e;a(o)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),l?R.jsx(je,{...t,ref:s,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}}):null}));Ce.displayName=be;var je=e.forwardRef(((t,o)=>{const{__scopeSelect:r,onAutoScroll:i,...l}=t,a=J("SelectScrollButton",r),s=e.useRef(null),c=D(r),d=e.useCallback((()=>{null!==s.current&&(window.clearInterval(s.current),s.current=null)}),[]);return e.useEffect((()=>()=>d()),[d]),b((()=>{const e=c().find((e=>e.ref.current===document.activeElement));e?.ref.current?.scrollIntoView({block:"nearest"})}),[c]),R.jsx(x.div,{"aria-hidden":!0,...l,ref:o,style:{flexShrink:0,...l.style},onPointerDown:n(l.onPointerDown,(()=>{null===s.current&&(s.current=window.setInterval(i,50))})),onPointerMove:n(l.onPointerMove,(()=>{a.onItemLeave?.(),null===s.current&&(s.current=window.setInterval(i,50))})),onPointerLeave:n(l.onPointerLeave,(()=>{d()}))})})),_e=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e;return R.jsx(x.div,{"aria-hidden":!0,...n,ref:t})}));_e.displayName="SelectSeparator";var Pe="SelectArrow",Re=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e,r=O(o),i=A(Pe,o),l=J(Pe,o);return i.open&&"popper"===l.position?R.jsx(h,{...r,...n,ref:t}):null}));function Ie(e){return""===e||void 0===e}Re.displayName=Pe;var Te=e.forwardRef(((t,o)=>{const{value:n,...r}=t,l=e.useRef(null),a=i(o,l),s=C(n);return e.useEffect((()=>{const e=l.current,t=window.HTMLSelectElement.prototype,o=Object.getOwnPropertyDescriptor(t,"value").set;if(s!==n&&o){const t=new Event("change",{bubbles:!0});o.call(e,n),e.dispatchEvent(t)}}),[s,n]),R.jsx(j,{asChild:!0,children:R.jsx("select",{...r,ref:a,defaultValue:n})})}));function ke(t){const o=y(t),n=e.useRef(""),r=e.useRef(0),i=e.useCallback((e=>{const t=n.current+e;o(t),function e(t){n.current=t,window.clearTimeout(r.current),""!==t&&(r.current=window.setTimeout((()=>e("")),1e3))}(t)}),[o]),l=e.useCallback((()=>{n.current="",window.clearTimeout(r.current)}),[]);return e.useEffect((()=>()=>window.clearTimeout(r.current)),[]),[n,i,l]}function Ee(e,t,o){const n=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,r=o?e.indexOf(o):-1;let i=(l=e,a=Math.max(r,0),l.map(((e,t)=>l[(a+t)%l.length])));var l,a;1===n.length&&(i=i.filter((e=>e!==o)));const s=i.find((e=>e.textValue.toLowerCase().startsWith(n.toLowerCase())));return s!==o?s:void 0}Te.displayName="BubbleSelect";var De=K,Ne=W,Le=q,Me=z,Oe=X,He=G,Ae=ie,Be=ce,Ve=ue,Ke=he,Fe=ge,We=we,Ue=_e;export{He as Content,Be as Group,Me as Icon,Ke as Item,We as ItemIndicator,Fe as ItemText,Ve as Label,Oe as Portal,De as Root,K as Select,Re as SelectArrow,G as SelectContent,ce as SelectGroup,z as SelectIcon,he as SelectItem,we as SelectItemIndicator,ge as SelectItemText,ue as SelectLabel,X as SelectPortal,Ce as SelectScrollDownButton,Se as SelectScrollUpButton,_e as SelectSeparator,W as SelectTrigger,q as SelectValue,ie as SelectViewport,Ue as Separator,Ne as Trigger,Le as Value,Ae as Viewport,M as createSelectScope};
1
+ import*as e from"react";import*as t from"react-dom";import{clamp as o}from"../../number/dist/index.mjs";import{composeEventHandlers as n}from"../../primitive/dist/index.mjs";import{createCollection as r}from"../../react-collection/dist/index.mjs";import{useComposedRefs as l}from"../../react-compose-refs/dist/index.mjs";import{createContextScope as i}from"../../react-context/dist/index.mjs";import{useDirection as a}from"../../react-direction/dist/index.mjs";import{DismissableLayer as s}from"../../react-dismissable-layer/dist/index.mjs";import{useFocusGuards as c}from"../../react-focus-guards/dist/index.mjs";import{FocusScope as d}from"../../react-focus-scope/dist/index.mjs";import{useId as u}from"../../react-id/dist/index.mjs";import{createPopperScope as p,Anchor as f,Content as m,Arrow as h,Root as v}from"../../react-popper/dist/index.mjs";import{Portal as g}from"../../react-portal/dist/index.mjs";import{Primitive as x}from"../../react-primitive/dist/index.mjs";import{Slot as w}from"../../react-slot/dist/index.mjs";import{useCallbackRef as y}from"../../react-use-callback-ref/dist/index.mjs";import{useControllableState as S}from"../../react-use-controllable-state/dist/index.mjs";import{useLayoutEffect as b}from"../../react-use-layout-effect/dist/index.mjs";import{usePrevious as C}from"../../react-use-previous/dist/index.mjs";import{VisuallyHidden as j}from"../../react-visually-hidden/dist/index.mjs";import{hideOthers as _}from"aria-hidden";import{RemoveScroll as P}from"react-remove-scroll";import{j as R}from"../../../../_virtual/jsx-runtime.mjs";var I=[" ","Enter","ArrowUp","ArrowDown"],T=[" ","Enter"],k="Select",[E,D,N]=r(k),[L,M]=i(k,[N,p]),O=p(),[H,A]=L(k),[B,V]=L(k),K=t=>{const{__scopeSelect:o,children:n,open:r,defaultOpen:l,onOpenChange:i,value:s,defaultValue:c,onValueChange:d,dir:p,name:f,autoComplete:m,disabled:h,required:g}=t,x=O(o),[w,y]=e.useState(null),[b,C]=e.useState(null),[j,_]=e.useState(!1),P=a(p),[I=!1,T]=S({prop:r,defaultProp:l,onChange:i}),[k,D]=S({prop:s,defaultProp:c,onChange:d}),N=e.useRef(null),L=!w||Boolean(w.closest("form")),[M,A]=e.useState(new Set),V=Array.from(M).map((e=>e.props.value)).join(";");return R.jsx(v,{...x,children:R.jsxs(H,{required:g,scope:o,trigger:w,onTriggerChange:y,valueNode:b,onValueNodeChange:C,valueNodeHasChildren:j,onValueNodeHasChildrenChange:_,contentId:u(),value:k,onValueChange:D,open:I,onOpenChange:T,dir:P,triggerPointerDownPosRef:N,disabled:h,children:[R.jsx(E.Provider,{scope:o,children:R.jsx(B,{scope:t.__scopeSelect,onNativeOptionAdd:e.useCallback((e=>{A((t=>new Set(t).add(e)))}),[]),onNativeOptionRemove:e.useCallback((e=>{A((t=>{const o=new Set(t);return o.delete(e),o}))}),[]),children:n})}),L?R.jsxs(Te,{"aria-hidden":!0,required:g,tabIndex:-1,name:f,autoComplete:m,value:k,onChange:e=>D(e.target.value),disabled:h,children:[void 0===k?R.jsx("option",{value:""}):null,Array.from(M)]},V):null]})})};K.displayName=k;var F="SelectTrigger",W=e.forwardRef(((e,t)=>{const{__scopeSelect:o,disabled:r=!1,...i}=e,a=O(o),s=A(F,o),c=s.disabled||r,d=l(t,s.onTriggerChange),u=D(o),[p,m,h]=ke((e=>{const t=u().filter((e=>!e.disabled)),o=t.find((e=>e.value===s.value)),n=Ee(t,e,o);void 0!==n&&s.onValueChange(n.value)})),v=()=>{c||(s.onOpenChange(!0),h())};return R.jsx(f,{asChild:!0,...a,children:R.jsx(x.button,{type:"button",role:"combobox","aria-controls":s.contentId,"aria-expanded":s.open,"aria-required":s.required,"aria-autocomplete":"none",dir:s.dir,"data-state":s.open?"open":"closed",disabled:c,"data-disabled":c?"":void 0,"data-placeholder":Ie(s.value)?"":void 0,...i,ref:d,onClick:n(i.onClick,(e=>{e.currentTarget.focus()})),onPointerDown:n(i.onPointerDown,(e=>{const t=e.target;t.hasPointerCapture(e.pointerId)&&t.releasePointerCapture(e.pointerId),0===e.button&&!1===e.ctrlKey&&(v(),s.triggerPointerDownPosRef.current={x:Math.round(e.pageX),y:Math.round(e.pageY)},e.preventDefault())})),onKeyDown:n(i.onKeyDown,(e=>{const t=""!==p.current;e.ctrlKey||e.altKey||e.metaKey||1!==e.key.length||m(e.key),t&&" "===e.key||I.includes(e.key)&&(v(),e.preventDefault())}))})})}));W.displayName=F;var U="SelectValue",q=e.forwardRef(((e,t)=>{const{__scopeSelect:o,className:n,style:r,children:i,placeholder:a="",...s}=e,c=A(U,o),{onValueNodeHasChildrenChange:d}=c,u=void 0!==i,p=l(t,c.onValueNodeChange);return b((()=>{d(u)}),[d,u]),R.jsx(x.span,{...s,ref:p,style:{pointerEvents:"none"},children:Ie(c.value)?R.jsx(R.Fragment,{children:a}):i})}));q.displayName=U;var z=e.forwardRef(((e,t)=>{const{__scopeSelect:o,children:n,...r}=e;return R.jsx(x.span,{"aria-hidden":!0,...r,ref:t,children:n||"▼"})}));z.displayName="SelectIcon";var X=e=>R.jsx(g,{asChild:!0,...e});X.displayName="SelectPortal";var Y="SelectContent",G=e.forwardRef(((o,n)=>{const r=A(Y,o.__scopeSelect),[l,i]=e.useState();if(b((()=>{i(new DocumentFragment)}),[]),!r.open){const e=l;return e?t.createPortal(R.jsx($,{scope:o.__scopeSelect,children:R.jsx(E.Slot,{scope:o.__scopeSelect,children:R.jsx("div",{children:o.children})})}),e):null}return R.jsx(Q,{...o,ref:n})}));G.displayName=Y;var Z=10,[$,J]=L(Y),Q=e.forwardRef(((t,o)=>{const{__scopeSelect:r,position:i="item-aligned",onCloseAutoFocus:a,onEscapeKeyDown:u,onPointerDownOutside:p,side:f,sideOffset:m,align:h,alignOffset:v,arrowPadding:g,collisionBoundary:x,collisionPadding:y,sticky:S,hideWhenDetached:b,avoidCollisions:C,...j}=t,I=A(Y,r),[T,k]=e.useState(null),[E,N]=e.useState(null),L=l(o,(e=>k(e))),[M,O]=e.useState(null),[H,B]=e.useState(null),V=D(r),[K,F]=e.useState(!1),W=e.useRef(!1);e.useEffect((()=>{if(T)return _(T)}),[T]),c();const U=e.useCallback((e=>{const[t,...o]=V().map((e=>e.ref.current)),[n]=o.slice(-1),r=document.activeElement;for(const o of e){if(o===r)return;if(o?.scrollIntoView({block:"nearest"}),o===t&&E&&(E.scrollTop=0),o===n&&E&&(E.scrollTop=E.scrollHeight),o?.focus(),document.activeElement!==r)return}}),[V,E]),q=e.useCallback((()=>U([M,T])),[U,M,T]);e.useEffect((()=>{K&&q()}),[K,q]);const{onOpenChange:z,triggerPointerDownPosRef:X}=I;e.useEffect((()=>{if(T){let e={x:0,y:0};const t=t=>{e={x:Math.abs(Math.round(t.pageX)-(X.current?.x??0)),y:Math.abs(Math.round(t.pageY)-(X.current?.y??0))}},o=o=>{e.x<=10&&e.y<=10?o.preventDefault():T.contains(o.target)||z(!1),document.removeEventListener("pointermove",t),X.current=null};return null!==X.current&&(document.addEventListener("pointermove",t),document.addEventListener("pointerup",o,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",t),document.removeEventListener("pointerup",o,{capture:!0})}}}),[T,z,X]),e.useEffect((()=>{const e=()=>z(!1);return window.addEventListener("blur",e),window.addEventListener("resize",e),()=>{window.removeEventListener("blur",e),window.removeEventListener("resize",e)}}),[z]);const[G,Z]=ke((e=>{const t=V().filter((e=>!e.disabled)),o=t.find((e=>e.ref.current===document.activeElement)),n=Ee(t,e,o);n&&setTimeout((()=>n.ref.current.focus()))})),J=e.useCallback(((e,t,o)=>{const n=!W.current&&!o;(void 0!==I.value&&I.value===t||n)&&(O(e),n&&(W.current=!0))}),[I.value]),Q=e.useCallback((()=>T?.focus()),[T]),oe=e.useCallback(((e,t,o)=>{const n=!W.current&&!o;(void 0!==I.value&&I.value===t||n)&&B(e)}),[I.value]),ne="popper"===i?te:ee,re=ne===te?{side:f,sideOffset:m,align:h,alignOffset:v,arrowPadding:g,collisionBoundary:x,collisionPadding:y,sticky:S,hideWhenDetached:b,avoidCollisions:C}:{};return R.jsx($,{scope:r,content:T,viewport:E,onViewportChange:N,itemRefCallback:J,selectedItem:M,onItemLeave:Q,itemTextRefCallback:oe,focusSelectedItem:q,selectedItemText:H,position:i,isPositioned:K,searchRef:G,children:R.jsx(P,{as:w,allowPinchZoom:!0,children:R.jsx(d,{asChild:!0,trapped:I.open,onMountAutoFocus:e=>{e.preventDefault()},onUnmountAutoFocus:n(a,(e=>{I.trigger?.focus({preventScroll:!0}),e.preventDefault()})),children:R.jsx(s,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:u,onPointerDownOutside:p,onFocusOutside:e=>e.preventDefault(),onDismiss:()=>I.onOpenChange(!1),children:R.jsx(ne,{role:"listbox",id:I.contentId,"data-state":I.open?"open":"closed",dir:I.dir,onContextMenu:e=>e.preventDefault(),...j,...re,onPlaced:()=>F(!0),ref:L,style:{display:"flex",flexDirection:"column",outline:"none",...j.style},onKeyDown:n(j.onKeyDown,(e=>{const t=e.ctrlKey||e.altKey||e.metaKey;if("Tab"===e.key&&e.preventDefault(),t||1!==e.key.length||Z(e.key),["ArrowUp","ArrowDown","Home","End"].includes(e.key)){let t=V().filter((e=>!e.disabled)).map((e=>e.ref.current));if(["ArrowUp","End"].includes(e.key)&&(t=t.slice().reverse()),["ArrowUp","ArrowDown"].includes(e.key)){const o=e.target,n=t.indexOf(o);t=t.slice(n+1)}setTimeout((()=>U(t))),e.preventDefault()}}))})})})})})}));Q.displayName="SelectContentImpl";var ee=e.forwardRef(((t,n)=>{const{__scopeSelect:r,onPlaced:i,...a}=t,s=A(Y,r),c=J(Y,r),[d,u]=e.useState(null),[p,f]=e.useState(null),m=l(n,(e=>f(e))),h=D(r),v=e.useRef(!1),g=e.useRef(!0),{viewport:w,selectedItem:y,selectedItemText:S,focusSelectedItem:C}=c,j=e.useCallback((()=>{if(s.trigger&&s.valueNode&&d&&p&&w&&y&&S){const e=s.trigger.getBoundingClientRect(),t=p.getBoundingClientRect(),n=s.valueNode.getBoundingClientRect(),r=S.getBoundingClientRect();if("rtl"!==s.dir){const l=r.left-t.left,i=n.left-l,a=e.left-i,s=e.width+a,c=Math.max(s,t.width),u=window.innerWidth-Z,p=o(i,[Z,u-c]);d.style.minWidth=s+"px",d.style.left=p+"px"}else{const l=t.right-r.right,i=window.innerWidth-n.right-l,a=window.innerWidth-e.right-i,s=e.width+a,c=Math.max(s,t.width),u=window.innerWidth-Z,p=o(i,[Z,u-c]);d.style.minWidth=s+"px",d.style.right=p+"px"}const l=h(),a=window.innerHeight-2*Z,c=w.scrollHeight,u=window.getComputedStyle(p),f=parseInt(u.borderTopWidth,10),m=parseInt(u.paddingTop,10),g=parseInt(u.borderBottomWidth,10),x=f+m+c+parseInt(u.paddingBottom,10)+g,b=Math.min(5*y.offsetHeight,x),C=window.getComputedStyle(w),j=parseInt(C.paddingTop,10),_=parseInt(C.paddingBottom,10),P=e.top+e.height/2-Z,R=a-P,I=y.offsetHeight/2,T=f+m+(y.offsetTop+I),k=x-T;if(T<=P){const e=y===l[l.length-1].ref.current;d.style.bottom="0px";const t=p.clientHeight-w.offsetTop-w.offsetHeight,o=T+Math.max(R,I+(e?_:0)+t+g);d.style.height=o+"px"}else{const e=y===l[0].ref.current;d.style.top="0px";const t=Math.max(P,f+w.offsetTop+(e?j:0)+I)+k;d.style.height=t+"px",w.scrollTop=T-P+w.offsetTop}d.style.margin=`${Z}px 0`,d.style.minHeight=b+"px",d.style.maxHeight=a+"px",i?.(),requestAnimationFrame((()=>v.current=!0))}}),[h,s.trigger,s.valueNode,d,p,w,y,S,s.dir,i]);b((()=>j()),[j]);const[_,P]=e.useState();b((()=>{p&&P(window.getComputedStyle(p).zIndex)}),[p]);const I=e.useCallback((e=>{e&&!0===g.current&&(j(),C?.(),g.current=!1)}),[j,C]);return R.jsx(oe,{scope:r,contentWrapper:d,shouldExpandOnScrollRef:v,onScrollButtonChange:I,children:R.jsx("div",{ref:u,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:_},children:R.jsx(x.div,{...a,ref:m,style:{boxSizing:"border-box",maxHeight:"100%",...a.style}})})})}));ee.displayName="SelectItemAlignedPosition";var te=e.forwardRef(((e,t)=>{const{__scopeSelect:o,align:n="start",collisionPadding:r=Z,...l}=e,i=O(o);return R.jsx(m,{...i,...l,ref:t,align:n,collisionPadding:r,style:{boxSizing:"border-box",...l.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})}));te.displayName="SelectPopperPosition";var[oe,ne]=L(Y,{}),re="SelectViewport",le=e.forwardRef(((t,o)=>{const{__scopeSelect:r,nonce:i,...a}=t,s=J(re,r),c=ne(re,r),d=l(o,s.onViewportChange),u=e.useRef(0);return R.jsxs(R.Fragment,{children:[R.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:i}),R.jsx(E.Slot,{scope:r,children:R.jsx(x.div,{"data-radix-select-viewport":"",role:"presentation",...a,ref:d,style:{position:"relative",flex:1,overflow:"auto",...a.style},onScroll:n(a.onScroll,(e=>{const t=e.currentTarget,{contentWrapper:o,shouldExpandOnScrollRef:n}=c;if(n?.current&&o){const e=Math.abs(u.current-t.scrollTop);if(e>0){const n=window.innerHeight-2*Z,r=parseFloat(o.style.minHeight),l=parseFloat(o.style.height),i=Math.max(r,l);if(i<n){const r=i+e,l=Math.min(n,r),a=r-l;o.style.height=l+"px","0px"===o.style.bottom&&(t.scrollTop=a>0?a:0,o.style.justifyContent="flex-end")}}}u.current=t.scrollTop}))})})]})}));le.displayName=re;var ie="SelectGroup",[ae,se]=L(ie),ce=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e,r=u();return R.jsx(ae,{scope:o,id:r,children:R.jsx(x.div,{role:"group","aria-labelledby":r,...n,ref:t})})}));ce.displayName=ie;var de="SelectLabel",ue=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e,r=se(de,o);return R.jsx(x.div,{id:r.id,...n,ref:t})}));ue.displayName=de;var pe="SelectItem",[fe,me]=L(pe),he=e.forwardRef(((t,o)=>{const{__scopeSelect:r,value:i,disabled:a=!1,textValue:s,...c}=t,d=A(pe,r),p=J(pe,r),f=d.value===i,[m,h]=e.useState(s??""),[v,g]=e.useState(!1),w=l(o,(e=>p.itemRefCallback?.(e,i,a))),y=u(),S=()=>{a||(d.onValueChange(i),d.onOpenChange(!1))};if(""===i)throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return R.jsx(fe,{scope:r,value:i,disabled:a,textId:y,isSelected:f,onItemTextChange:e.useCallback((e=>{h((t=>t||(e?.textContent??"").trim()))}),[]),children:R.jsx(E.ItemSlot,{scope:r,value:i,disabled:a,textValue:m,children:R.jsx(x.div,{role:"option","aria-labelledby":y,"data-highlighted":v?"":void 0,"aria-selected":f&&v,"data-state":f?"checked":"unchecked","aria-disabled":a||void 0,"data-disabled":a?"":void 0,tabIndex:a?void 0:-1,...c,ref:w,onFocus:n(c.onFocus,(()=>g(!0))),onBlur:n(c.onBlur,(()=>g(!1))),onPointerUp:n(c.onPointerUp,S),onPointerMove:n(c.onPointerMove,(e=>{a?p.onItemLeave?.():e.currentTarget.focus({preventScroll:!0})})),onPointerLeave:n(c.onPointerLeave,(e=>{e.currentTarget===document.activeElement&&p.onItemLeave?.()})),onKeyDown:n(c.onKeyDown,(e=>{""!==p.searchRef?.current&&" "===e.key||(T.includes(e.key)&&S()," "===e.key&&e.preventDefault())}))})})})}));he.displayName=pe;var ve="SelectItemText",ge=e.forwardRef(((o,n)=>{const{__scopeSelect:r,className:i,style:a,...s}=o,c=A(ve,r),d=J(ve,r),u=me(ve,r),p=V(ve,r),[f,m]=e.useState(null),h=l(n,(e=>m(e)),u.onItemTextChange,(e=>d.itemTextRefCallback?.(e,u.value,u.disabled))),v=f?.textContent,g=e.useMemo((()=>R.jsx("option",{value:u.value,disabled:u.disabled,children:v},u.value)),[u.disabled,u.value,v]),{onNativeOptionAdd:w,onNativeOptionRemove:y}=p;return b((()=>(w(g),()=>y(g))),[w,y,g]),R.jsxs(R.Fragment,{children:[R.jsx(x.span,{id:u.textId,...s,ref:h}),u.isSelected&&c.valueNode&&!c.valueNodeHasChildren?t.createPortal(s.children,c.valueNode):null]})}));ge.displayName=ve;var xe="SelectItemIndicator",we=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e;return me(xe,o).isSelected?R.jsx(x.span,{"aria-hidden":!0,...n,ref:t}):null}));we.displayName=xe;var ye="SelectScrollUpButton",Se=e.forwardRef(((t,o)=>{const n=J(ye,t.__scopeSelect),r=ne(ye,t.__scopeSelect),[i,a]=e.useState(!1),s=l(o,r.onScrollButtonChange);return b((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollTop>0;a(e)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),i?R.jsx(je,{...t,ref:s,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop-t.offsetHeight)}}):null}));Se.displayName=ye;var be="SelectScrollDownButton",Ce=e.forwardRef(((t,o)=>{const n=J(be,t.__scopeSelect),r=ne(be,t.__scopeSelect),[i,a]=e.useState(!1),s=l(o,r.onScrollButtonChange);return b((()=>{if(n.viewport&&n.isPositioned){let e=function(){const e=t.scrollHeight-t.clientHeight,o=Math.ceil(t.scrollTop)<e;a(o)};const t=n.viewport;return e(),t.addEventListener("scroll",e),()=>t.removeEventListener("scroll",e)}}),[n.viewport,n.isPositioned]),i?R.jsx(je,{...t,ref:s,onAutoScroll:()=>{const{viewport:e,selectedItem:t}=n;e&&t&&(e.scrollTop=e.scrollTop+t.offsetHeight)}}):null}));Ce.displayName=be;var je=e.forwardRef(((t,o)=>{const{__scopeSelect:r,onAutoScroll:l,...i}=t,a=J("SelectScrollButton",r),s=e.useRef(null),c=D(r),d=e.useCallback((()=>{null!==s.current&&(window.clearInterval(s.current),s.current=null)}),[]);return e.useEffect((()=>()=>d()),[d]),b((()=>{const e=c().find((e=>e.ref.current===document.activeElement));e?.ref.current?.scrollIntoView({block:"nearest"})}),[c]),R.jsx(x.div,{"aria-hidden":!0,...i,ref:o,style:{flexShrink:0,...i.style},onPointerDown:n(i.onPointerDown,(()=>{null===s.current&&(s.current=window.setInterval(l,50))})),onPointerMove:n(i.onPointerMove,(()=>{a.onItemLeave?.(),null===s.current&&(s.current=window.setInterval(l,50))})),onPointerLeave:n(i.onPointerLeave,(()=>{d()}))})})),_e=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e;return R.jsx(x.div,{"aria-hidden":!0,...n,ref:t})}));_e.displayName="SelectSeparator";var Pe="SelectArrow",Re=e.forwardRef(((e,t)=>{const{__scopeSelect:o,...n}=e,r=O(o),l=A(Pe,o),i=J(Pe,o);return l.open&&"popper"===i.position?R.jsx(h,{...r,...n,ref:t}):null}));function Ie(e){return""===e||void 0===e}Re.displayName=Pe;var Te=e.forwardRef(((t,o)=>{const{value:n,...r}=t,i=e.useRef(null),a=l(o,i),s=C(n);return e.useEffect((()=>{const e=i.current,t=window.HTMLSelectElement.prototype,o=Object.getOwnPropertyDescriptor(t,"value").set;if(s!==n&&o){const t=new Event("change",{bubbles:!0});o.call(e,n),e.dispatchEvent(t)}}),[s,n]),R.jsx(j,{asChild:!0,children:R.jsx("select",{...r,ref:a,defaultValue:n})})}));function ke(t){const o=y(t),n=e.useRef(""),r=e.useRef(0),l=e.useCallback((e=>{const t=n.current+e;o(t),function e(t){n.current=t,window.clearTimeout(r.current),""!==t&&(r.current=window.setTimeout((()=>e("")),1e3))}(t)}),[o]),i=e.useCallback((()=>{n.current="",window.clearTimeout(r.current)}),[]);return e.useEffect((()=>()=>window.clearTimeout(r.current)),[]),[n,l,i]}function Ee(e,t,o){const n=t.length>1&&Array.from(t).every((e=>e===t[0]))?t[0]:t,r=o?e.indexOf(o):-1;let l=(i=e,a=Math.max(r,0),i.map(((e,t)=>i[(a+t)%i.length])));var i,a;1===n.length&&(l=l.filter((e=>e!==o)));const s=l.find((e=>e.textValue.toLowerCase().startsWith(n.toLowerCase())));return s!==o?s:void 0}Te.displayName="BubbleSelect";var De=K,Ne=W,Le=q,Me=z,Oe=X,He=G,Ae=le,Be=ce,Ve=ue,Ke=he,Fe=ge,We=we,Ue=_e;export{He as Content,Be as Group,Me as Icon,Ke as Item,We as ItemIndicator,Fe as ItemText,Ve as Label,Oe as Portal,De as Root,K as Select,Re as SelectArrow,G as SelectContent,ce as SelectGroup,z as SelectIcon,he as SelectItem,we as SelectItemIndicator,ge as SelectItemText,ue as SelectLabel,X as SelectPortal,Ce as SelectScrollDownButton,Se as SelectScrollUpButton,_e as SelectSeparator,W as SelectTrigger,q as SelectValue,le as SelectViewport,Ue as Separator,Ne as Trigger,Le as Value,Ae as Viewport,M as createSelectScope};
2
2
  //# sourceMappingURL=index.mjs.map