@vritti/quantum-ui 0.2.9 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (976) hide show
  1. package/dist/Alert.js +8 -31
  2. package/dist/Alert.js.map +1 -1
  3. package/dist/AppSelector.js +37 -0
  4. package/dist/AppSelector.js.map +1 -0
  5. package/dist/Avatar.js +5 -5
  6. package/dist/Avatar.js.map +1 -1
  7. package/dist/Badge.js +2 -28
  8. package/dist/Badge.js.map +1 -1
  9. package/dist/Badge2.js +30 -0
  10. package/dist/Badge2.js.map +1 -0
  11. package/dist/Breadcrumb.js +125 -0
  12. package/dist/Breadcrumb.js.map +1 -0
  13. package/dist/Button.js +8 -4
  14. package/dist/Button.js.map +1 -1
  15. package/dist/Button2.js +34 -15
  16. package/dist/Button2.js.map +1 -1
  17. package/dist/CardSkeleton.js +17 -0
  18. package/dist/CardSkeleton.js.map +1 -0
  19. package/dist/Chart.js +6195 -6401
  20. package/dist/Chart.js.map +1 -1
  21. package/dist/Checkbox.js +2 -289
  22. package/dist/Checkbox.js.map +1 -1
  23. package/dist/Checkbox2.js +293 -0
  24. package/dist/Checkbox2.js.map +1 -0
  25. package/dist/CheckboxGroup.js +74 -0
  26. package/dist/CheckboxGroup.js.map +1 -0
  27. package/dist/CloudProviderSelector.js +37 -0
  28. package/dist/CloudProviderSelector.js.map +1 -0
  29. package/dist/Collapsible.js +8 -0
  30. package/dist/Collapsible.js.map +1 -0
  31. package/dist/Combination.js +10 -2509
  32. package/dist/Combination.js.map +1 -1
  33. package/dist/ConfirmContext.js +75 -0
  34. package/dist/ConfirmContext.js.map +1 -0
  35. package/dist/CurrencySelector.js +194 -0
  36. package/dist/CurrencySelector.js.map +1 -0
  37. package/dist/DangerZoneSkeleton.js +52 -0
  38. package/dist/DangerZoneSkeleton.js.map +1 -0
  39. package/dist/DatePicker.js +36 -340
  40. package/dist/DatePicker.js.map +1 -1
  41. package/dist/DeploymentSelector.js +37 -0
  42. package/dist/DeploymentSelector.js.map +1 -0
  43. package/dist/Dialog.js +159 -0
  44. package/dist/Dialog.js.map +1 -0
  45. package/dist/DropdownMenu.js +66 -1423
  46. package/dist/DropdownMenu.js.map +1 -1
  47. package/dist/Empty.js +49 -0
  48. package/dist/Empty.js.map +1 -0
  49. package/dist/ErrorBoundary.js +255 -0
  50. package/dist/ErrorBoundary.js.map +1 -0
  51. package/dist/FeatureSelector.js +37 -0
  52. package/dist/FeatureSelector.js.map +1 -0
  53. package/dist/FilePreview.js +194 -0
  54. package/dist/FilePreview.js.map +1 -0
  55. package/dist/Form.js +1938 -19
  56. package/dist/Form.js.map +1 -1
  57. package/dist/HierarchyGraph.js +10729 -0
  58. package/dist/HierarchyGraph.js.map +1 -0
  59. package/dist/IndustrySelector.js +37 -0
  60. package/dist/IndustrySelector.js.map +1 -0
  61. package/dist/Input.js +22 -0
  62. package/dist/Input.js.map +1 -0
  63. package/dist/Label.js +1 -21
  64. package/dist/Label.js.map +1 -1
  65. package/dist/LocaleSelector.js +111 -0
  66. package/dist/LocaleSelector.js.map +1 -0
  67. package/dist/MicrofrontendSelector.js +19 -0
  68. package/dist/MicrofrontendSelector.js.map +1 -0
  69. package/dist/OTPField.js +28 -26
  70. package/dist/OTPField.js.map +1 -1
  71. package/dist/PageHeaderSkeleton.js +35 -0
  72. package/dist/PageHeaderSkeleton.js.map +1 -0
  73. package/dist/PasswordField.js +1 -49
  74. package/dist/PasswordField.js.map +1 -1
  75. package/dist/PhoneField.js +11 -16
  76. package/dist/PhoneField.js.map +1 -1
  77. package/dist/PlanSelector.js +37 -0
  78. package/dist/PlanSelector.js.map +1 -0
  79. package/dist/Progress.js +4 -3
  80. package/dist/Progress.js.map +1 -1
  81. package/dist/RadioGroup.js +392 -0
  82. package/dist/RadioGroup.js.map +1 -0
  83. package/dist/RegionSelector.js +37 -0
  84. package/dist/RegionSelector.js.map +1 -0
  85. package/dist/Select.js +780 -0
  86. package/dist/Select.js.map +1 -0
  87. package/dist/SelectFilter.js +387 -0
  88. package/dist/SelectFilter.js.map +1 -0
  89. package/dist/Sidebar.js +616 -0
  90. package/dist/Sidebar.js.map +1 -0
  91. package/dist/SingleSelect.js +429 -0
  92. package/dist/SingleSelect.js.map +1 -0
  93. package/dist/Sonner.js +6 -1135
  94. package/dist/Sonner.js.map +1 -1
  95. package/dist/Sortable.js +4517 -0
  96. package/dist/Sortable.js.map +1 -0
  97. package/dist/StepProgressIndicator.js +42 -0
  98. package/dist/StepProgressIndicator.js.map +1 -0
  99. package/dist/Switch.js +15 -15
  100. package/dist/Switch.js.map +1 -1
  101. package/dist/TabsSkeleton.js +188 -0
  102. package/dist/TabsSkeleton.js.map +1 -0
  103. package/dist/TextArea.js +16 -19
  104. package/dist/TextArea.js.map +1 -1
  105. package/dist/TextField.js +5 -20
  106. package/dist/TextField.js.map +1 -1
  107. package/dist/ThemeContext.js +2 -8
  108. package/dist/ThemeContext.js.map +1 -1
  109. package/dist/TimezoneSelector.js +144 -0
  110. package/dist/TimezoneSelector.js.map +1 -0
  111. package/dist/Toggle.js +2 -32
  112. package/dist/Toggle.js.map +1 -1
  113. package/dist/UploadFile.js +232 -0
  114. package/dist/UploadFile.js.map +1 -0
  115. package/dist/ValueFilter.js +123 -0
  116. package/dist/ValueFilter.js.map +1 -0
  117. package/dist/ViewTabs.js +218 -0
  118. package/dist/ViewTabs.js.map +1 -0
  119. package/dist/_commonjsHelpers.js +3 -1
  120. package/dist/_commonjsHelpers.js.map +1 -1
  121. package/dist/assets/quantum-ui.css +827 -57
  122. package/dist/axios.js +1239 -892
  123. package/dist/axios.js.map +1 -1
  124. package/dist/{chevron-down.js → chevron-left.js} +4 -4
  125. package/dist/chevron-left.js.map +1 -0
  126. package/dist/circle-alert.js +19 -0
  127. package/dist/circle-alert.js.map +1 -0
  128. package/dist/circle-check.js +18 -0
  129. package/dist/circle-check.js.map +1 -0
  130. package/dist/collapsible2.js +154 -0
  131. package/dist/collapsible2.js.map +1 -0
  132. package/dist/components/Badge.js +2 -1
  133. package/dist/components/Badge.js.map +1 -1
  134. package/dist/components/Breadcrumb.js +2 -0
  135. package/dist/components/Breadcrumb.js.map +1 -0
  136. package/dist/components/Card.js +1 -0
  137. package/dist/components/Card.js.map +1 -1
  138. package/dist/components/CheckboxGroup.js +2 -0
  139. package/dist/components/CheckboxGroup.js.map +1 -0
  140. package/dist/components/Collapsible.js +2 -0
  141. package/dist/components/Collapsible.js.map +1 -0
  142. package/dist/components/DangerZone.js +2 -0
  143. package/dist/components/DangerZone.js.map +1 -0
  144. package/dist/components/DataTable.js +2 -0
  145. package/dist/components/DataTable.js.map +1 -0
  146. package/dist/components/Dialog.js +2 -0
  147. package/dist/components/Dialog.js.map +1 -0
  148. package/dist/components/DropdownMenu.js +1 -1
  149. package/dist/components/Empty.js +2 -0
  150. package/dist/components/Empty.js.map +1 -0
  151. package/dist/components/ErrorBoundary.js +2 -0
  152. package/dist/components/ErrorBoundary.js.map +1 -0
  153. package/dist/components/FilePreview.js +2 -0
  154. package/dist/components/FilePreview.js.map +1 -0
  155. package/dist/components/HierarchyGraph.js +2 -0
  156. package/dist/components/HierarchyGraph.js.map +1 -0
  157. package/dist/components/PageHeader.js +2 -0
  158. package/dist/components/PageHeader.js.map +1 -0
  159. package/dist/components/RadioGroup.js +2 -0
  160. package/dist/components/RadioGroup.js.map +1 -0
  161. package/dist/components/RichTextEditor.js +4 -0
  162. package/dist/components/RichTextEditor.js.map +1 -0
  163. package/dist/components/Select.js +29 -0
  164. package/dist/components/Select.js.map +1 -0
  165. package/dist/components/Sidebar.js +2 -0
  166. package/dist/components/Sidebar.js.map +1 -0
  167. package/dist/components/Sortable.js +2 -0
  168. package/dist/components/Sortable.js.map +1 -0
  169. package/dist/components/StepProgressIndicator.js +2 -0
  170. package/dist/components/StepProgressIndicator.js.map +1 -0
  171. package/dist/components/Tabs.js +2 -0
  172. package/dist/components/Tabs.js.map +1 -0
  173. package/dist/components/UploadFile.js +2 -0
  174. package/dist/components/UploadFile.js.map +1 -0
  175. package/dist/components/ValueFilter.js +2 -0
  176. package/dist/components/ValueFilter.js.map +1 -0
  177. package/dist/components/ViewTabs.js +2 -0
  178. package/dist/components/ViewTabs.js.map +1 -0
  179. package/dist/context/index.js +1 -0
  180. package/dist/context/index.js.map +1 -1
  181. package/dist/dropdown-menu.js +1209 -0
  182. package/dist/dropdown-menu.js.map +1 -0
  183. package/dist/ellipsis.js +19 -0
  184. package/dist/ellipsis.js.map +1 -0
  185. package/dist/eye.js +52 -0
  186. package/dist/eye.js.map +1 -0
  187. package/dist/field.js +1 -1
  188. package/dist/file-text.js +27 -0
  189. package/dist/file-text.js.map +1 -0
  190. package/dist/grip-vertical.js +22 -0
  191. package/dist/grip-vertical.js.map +1 -0
  192. package/dist/hooks/index.js +3 -0
  193. package/dist/hooks/index.js.map +1 -1
  194. package/dist/image-component.js +614 -0
  195. package/dist/image-component.js.map +1 -0
  196. package/dist/index.js +49 -9
  197. package/dist/index.js.map +1 -1
  198. package/dist/index10.js +175 -94
  199. package/dist/index10.js.map +1 -1
  200. package/dist/index11.js +202 -67
  201. package/dist/index11.js.map +1 -1
  202. package/dist/index12.js +17 -38
  203. package/dist/index12.js.map +1 -1
  204. package/dist/index13.js +204 -188
  205. package/dist/index13.js.map +1 -1
  206. package/dist/index14.js +124 -192
  207. package/dist/index14.js.map +1 -1
  208. package/dist/index15.js +79 -0
  209. package/dist/index15.js.map +1 -0
  210. package/dist/index16.js +16 -0
  211. package/dist/index16.js.map +1 -0
  212. package/dist/index17.js +1137 -0
  213. package/dist/index17.js.map +1 -0
  214. package/dist/index18.js +41 -0
  215. package/dist/index18.js.map +1 -0
  216. package/dist/index19.js +314 -0
  217. package/dist/index19.js.map +1 -0
  218. package/dist/index2.js +54033 -55
  219. package/dist/index2.js.map +1 -1
  220. package/dist/index20.js +488 -0
  221. package/dist/index20.js.map +1 -0
  222. package/dist/index21.js +2540 -0
  223. package/dist/index21.js.map +1 -0
  224. package/dist/index22.js +36 -0
  225. package/dist/index22.js.map +1 -0
  226. package/dist/index23.js +13 -0
  227. package/dist/index23.js.map +1 -0
  228. package/dist/index24.js +8 -0
  229. package/dist/index24.js.map +1 -0
  230. package/dist/index25.js +35 -0
  231. package/dist/index25.js.map +1 -0
  232. package/dist/index26.js +65 -0
  233. package/dist/index26.js.map +1 -0
  234. package/dist/index27.js +16 -0
  235. package/dist/index27.js.map +1 -0
  236. package/dist/index28.js +41 -0
  237. package/dist/index28.js.map +1 -0
  238. package/dist/index29.js +84 -0
  239. package/dist/index29.js.map +1 -0
  240. package/dist/index3.js +42 -10
  241. package/dist/index3.js.map +1 -1
  242. package/dist/index30.js +199 -0
  243. package/dist/index30.js.map +1 -0
  244. package/dist/index4.js +290 -118
  245. package/dist/index4.js.map +1 -1
  246. package/dist/index5.js +96 -31
  247. package/dist/index5.js.map +1 -1
  248. package/dist/index6.js +36 -4
  249. package/dist/index6.js.map +1 -1
  250. package/dist/index7.js +1157 -11
  251. package/dist/index7.js.map +1 -1
  252. package/dist/index8.js +22 -42
  253. package/dist/index8.js.map +1 -1
  254. package/dist/index9.js +25 -35
  255. package/dist/index9.js.map +1 -1
  256. package/dist/lib/components/Alert/Alert.d.ts +2 -1
  257. package/dist/lib/components/Alert/Alert.d.ts.map +1 -1
  258. package/dist/lib/components/Breadcrumb/Breadcrumb.d.ts +17 -0
  259. package/dist/lib/components/Breadcrumb/Breadcrumb.d.ts.map +1 -0
  260. package/dist/lib/components/Breadcrumb/index.d.ts +4 -0
  261. package/dist/lib/components/Breadcrumb/index.d.ts.map +1 -0
  262. package/dist/lib/components/Button/Button.d.ts +3 -1
  263. package/dist/lib/components/Button/Button.d.ts.map +1 -1
  264. package/dist/lib/components/Card/CardSkeleton.d.ts +9 -0
  265. package/dist/lib/components/Card/CardSkeleton.d.ts.map +1 -0
  266. package/dist/lib/components/Card/index.d.ts +1 -0
  267. package/dist/lib/components/Card/index.d.ts.map +1 -1
  268. package/dist/lib/components/Chart/Chart.d.ts +1 -1
  269. package/dist/lib/components/Chart/Chart.d.ts.map +1 -1
  270. package/dist/lib/components/CheckboxGroup/CheckboxGroup.d.ts +24 -0
  271. package/dist/lib/components/CheckboxGroup/CheckboxGroup.d.ts.map +1 -0
  272. package/dist/lib/components/CheckboxGroup/index.d.ts +3 -0
  273. package/dist/lib/components/CheckboxGroup/index.d.ts.map +1 -0
  274. package/dist/lib/components/Collapsible/Collapsible.d.ts +5 -0
  275. package/dist/lib/components/Collapsible/Collapsible.d.ts.map +1 -0
  276. package/dist/lib/components/Collapsible/index.d.ts +2 -0
  277. package/dist/lib/components/Collapsible/index.d.ts.map +1 -0
  278. package/dist/lib/components/DangerZone/DangerZone.d.ts +13 -0
  279. package/dist/lib/components/DangerZone/DangerZone.d.ts.map +1 -0
  280. package/dist/lib/components/DangerZone/DangerZoneSkeleton.d.ts +9 -0
  281. package/dist/lib/components/DangerZone/DangerZoneSkeleton.d.ts.map +1 -0
  282. package/dist/lib/components/DangerZone/index.d.ts +4 -0
  283. package/dist/lib/components/DangerZone/index.d.ts.map +1 -0
  284. package/dist/lib/components/DataTable/DataTable.d.ts +6 -0
  285. package/dist/lib/components/DataTable/DataTable.d.ts.map +1 -0
  286. package/dist/lib/components/DataTable/components/DataTableColumnHeader.d.ts +12 -0
  287. package/dist/lib/components/DataTable/components/DataTableColumnHeader.d.ts.map +1 -0
  288. package/dist/lib/components/DataTable/components/DataTableEmpty.d.ts +13 -0
  289. package/dist/lib/components/DataTable/components/DataTableEmpty.d.ts.map +1 -0
  290. package/dist/lib/components/DataTable/components/DataTableFilters.d.ts +11 -0
  291. package/dist/lib/components/DataTable/components/DataTableFilters.d.ts.map +1 -0
  292. package/dist/lib/components/DataTable/components/DataTableImportDialog.d.ts +16 -0
  293. package/dist/lib/components/DataTable/components/DataTableImportDialog.d.ts.map +1 -0
  294. package/dist/lib/components/DataTable/components/DataTablePagination.d.ts +12 -0
  295. package/dist/lib/components/DataTable/components/DataTablePagination.d.ts.map +1 -0
  296. package/dist/lib/components/DataTable/components/DataTableRowDensity.d.ts +11 -0
  297. package/dist/lib/components/DataTable/components/DataTableRowDensity.d.ts.map +1 -0
  298. package/dist/lib/components/DataTable/components/DataTableSearch.d.ts +14 -0
  299. package/dist/lib/components/DataTable/components/DataTableSearch.d.ts.map +1 -0
  300. package/dist/lib/components/DataTable/components/DataTableSelectionBar.d.ts +14 -0
  301. package/dist/lib/components/DataTable/components/DataTableSelectionBar.d.ts.map +1 -0
  302. package/dist/lib/components/DataTable/components/DataTableViewOptions.d.ts +11 -0
  303. package/dist/lib/components/DataTable/components/DataTableViewOptions.d.ts.map +1 -0
  304. package/dist/lib/components/DataTable/components/DataTableViewTabs.d.ts +7 -0
  305. package/dist/lib/components/DataTable/components/DataTableViewTabs.d.ts.map +1 -0
  306. package/dist/lib/components/DataTable/components/DataTableViewsMenu.d.ts +14 -0
  307. package/dist/lib/components/DataTable/components/DataTableViewsMenu.d.ts.map +1 -0
  308. package/dist/lib/components/DataTable/components/FilterWrapper.d.ts +21 -0
  309. package/dist/lib/components/DataTable/components/FilterWrapper.d.ts.map +1 -0
  310. package/dist/lib/components/DataTable/components/RowActions.d.ts +20 -0
  311. package/dist/lib/components/DataTable/components/RowActions.d.ts.map +1 -0
  312. package/dist/lib/components/DataTable/hooks/useAutoUpsert.d.ts +3 -0
  313. package/dist/lib/components/DataTable/hooks/useAutoUpsert.d.ts.map +1 -0
  314. package/dist/lib/components/DataTable/hooks/useDataTable.d.ts +25 -0
  315. package/dist/lib/components/DataTable/hooks/useDataTable.d.ts.map +1 -0
  316. package/dist/lib/components/DataTable/index.d.ts +18 -0
  317. package/dist/lib/components/DataTable/index.d.ts.map +1 -0
  318. package/dist/lib/components/DataTable/store/store.d.ts +28 -0
  319. package/dist/lib/components/DataTable/store/store.d.ts.map +1 -0
  320. package/dist/lib/components/DataTable/store/useTableSlice.d.ts +18 -0
  321. package/dist/lib/components/DataTable/store/useTableSlice.d.ts.map +1 -0
  322. package/dist/lib/components/DataTable/types.d.ts +66 -0
  323. package/dist/lib/components/DataTable/types.d.ts.map +1 -0
  324. package/dist/lib/components/DataTable/utils.d.ts +10 -0
  325. package/dist/lib/components/DataTable/utils.d.ts.map +1 -0
  326. package/dist/lib/components/DatePicker/DatePicker.d.ts +1 -1
  327. package/dist/lib/components/DatePicker/DatePicker.d.ts.map +1 -1
  328. package/dist/lib/components/Dialog/Dialog.d.ts +31 -0
  329. package/dist/lib/components/Dialog/Dialog.d.ts.map +1 -0
  330. package/dist/lib/components/Dialog/index.d.ts +3 -0
  331. package/dist/lib/components/Dialog/index.d.ts.map +1 -0
  332. package/dist/lib/components/DropdownMenu/DropdownMenu.d.ts +1 -1
  333. package/dist/lib/components/DropdownMenu/DropdownMenu.d.ts.map +1 -1
  334. package/dist/lib/components/DropdownMenu/types.d.ts +10 -1
  335. package/dist/lib/components/DropdownMenu/types.d.ts.map +1 -1
  336. package/dist/lib/components/Editor/context/editor-config-context.d.ts +9 -0
  337. package/dist/lib/components/Editor/context/editor-config-context.d.ts.map +1 -0
  338. package/dist/lib/components/Editor/context/toolbar-context.d.ts +18 -0
  339. package/dist/lib/components/Editor/context/toolbar-context.d.ts.map +1 -0
  340. package/dist/lib/components/Editor/editor-hooks/use-debounce.d.ts +2 -0
  341. package/dist/lib/components/Editor/editor-hooks/use-debounce.d.ts.map +1 -0
  342. package/dist/lib/components/Editor/editor-hooks/use-modal.d.ts +6 -0
  343. package/dist/lib/components/Editor/editor-hooks/use-modal.d.ts.map +1 -0
  344. package/dist/lib/components/Editor/editor-hooks/use-report.d.ts +2 -0
  345. package/dist/lib/components/Editor/editor-hooks/use-report.d.ts.map +1 -0
  346. package/dist/lib/components/Editor/editor-hooks/use-update-toolbar.d.ts +3 -0
  347. package/dist/lib/components/Editor/editor-hooks/use-update-toolbar.d.ts.map +1 -0
  348. package/dist/lib/components/Editor/editor-ui/button-group.d.ts +12 -0
  349. package/dist/lib/components/Editor/editor-ui/button-group.d.ts.map +1 -0
  350. package/dist/lib/components/Editor/editor-ui/button.d.ts +11 -0
  351. package/dist/lib/components/Editor/editor-ui/button.d.ts.map +1 -0
  352. package/dist/lib/components/Editor/editor-ui/code-button.d.ts +8 -0
  353. package/dist/lib/components/Editor/editor-ui/code-button.d.ts.map +1 -0
  354. package/dist/lib/components/Editor/editor-ui/color-picker.d.ts +92 -0
  355. package/dist/lib/components/Editor/editor-ui/color-picker.d.ts.map +1 -0
  356. package/dist/lib/components/Editor/editor-ui/command.d.ts +19 -0
  357. package/dist/lib/components/Editor/editor-ui/command.d.ts.map +1 -0
  358. package/dist/lib/components/Editor/editor-ui/content-editable.d.ts +9 -0
  359. package/dist/lib/components/Editor/editor-ui/content-editable.d.ts.map +1 -0
  360. package/dist/lib/components/Editor/editor-ui/dialog.d.ts +16 -0
  361. package/dist/lib/components/Editor/editor-ui/dialog.d.ts.map +1 -0
  362. package/dist/lib/components/Editor/editor-ui/image-component.d.ts +16 -0
  363. package/dist/lib/components/Editor/editor-ui/image-component.d.ts.map +1 -0
  364. package/dist/lib/components/Editor/editor-ui/image-resizer.d.ts +18 -0
  365. package/dist/lib/components/Editor/editor-ui/image-resizer.d.ts.map +1 -0
  366. package/dist/lib/components/Editor/editor-ui/input.d.ts +4 -0
  367. package/dist/lib/components/Editor/editor-ui/input.d.ts.map +1 -0
  368. package/dist/lib/components/Editor/editor-ui/label.d.ts +5 -0
  369. package/dist/lib/components/Editor/editor-ui/label.d.ts.map +1 -0
  370. package/dist/lib/components/Editor/editor-ui/popover.d.ts +8 -0
  371. package/dist/lib/components/Editor/editor-ui/popover.d.ts.map +1 -0
  372. package/dist/lib/components/Editor/editor-ui/scroll-area.d.ts +6 -0
  373. package/dist/lib/components/Editor/editor-ui/scroll-area.d.ts.map +1 -0
  374. package/dist/lib/components/Editor/editor-ui/select.d.ts +16 -0
  375. package/dist/lib/components/Editor/editor-ui/select.d.ts.map +1 -0
  376. package/dist/lib/components/Editor/editor-ui/separator.d.ts +5 -0
  377. package/dist/lib/components/Editor/editor-ui/separator.d.ts.map +1 -0
  378. package/dist/lib/components/Editor/editor-ui/tabs.d.ts +8 -0
  379. package/dist/lib/components/Editor/editor-ui/tabs.d.ts.map +1 -0
  380. package/dist/lib/components/Editor/editor-ui/toggle-group.d.ts +8 -0
  381. package/dist/lib/components/Editor/editor-ui/toggle-group.d.ts.map +1 -0
  382. package/dist/lib/components/Editor/editor-ui/toggle.d.ts +10 -0
  383. package/dist/lib/components/Editor/editor-ui/toggle.d.ts.map +1 -0
  384. package/dist/lib/components/Editor/editor-ui/tooltip.d.ts +8 -0
  385. package/dist/lib/components/Editor/editor-ui/tooltip.d.ts.map +1 -0
  386. package/dist/lib/components/Editor/index.d.ts +4 -0
  387. package/dist/lib/components/Editor/index.d.ts.map +1 -0
  388. package/dist/lib/components/Editor/nodes/autocomplete-node.d.ts +19 -0
  389. package/dist/lib/components/Editor/nodes/autocomplete-node.d.ts.map +1 -0
  390. package/dist/lib/components/Editor/nodes/embeds/tweet-node.d.ts +22 -0
  391. package/dist/lib/components/Editor/nodes/embeds/tweet-node.d.ts.map +1 -0
  392. package/dist/lib/components/Editor/nodes/embeds/youtube-node.d.ts +23 -0
  393. package/dist/lib/components/Editor/nodes/embeds/youtube-node.d.ts.map +1 -0
  394. package/dist/lib/components/Editor/nodes/emoji-node.d.ts +18 -0
  395. package/dist/lib/components/Editor/nodes/emoji-node.d.ts.map +1 -0
  396. package/dist/lib/components/Editor/nodes/image-node.d.ts +49 -0
  397. package/dist/lib/components/Editor/nodes/image-node.d.ts.map +1 -0
  398. package/dist/lib/components/Editor/nodes/keyword-node.d.ts +15 -0
  399. package/dist/lib/components/Editor/nodes/keyword-node.d.ts.map +1 -0
  400. package/dist/lib/components/Editor/nodes/layout-container-node.d.ts +23 -0
  401. package/dist/lib/components/Editor/nodes/layout-container-node.d.ts.map +1 -0
  402. package/dist/lib/components/Editor/nodes/layout-item-node.d.ts +15 -0
  403. package/dist/lib/components/Editor/nodes/layout-item-node.d.ts.map +1 -0
  404. package/dist/lib/components/Editor/nodes/mention-node.d.ts +21 -0
  405. package/dist/lib/components/Editor/nodes/mention-node.d.ts.map +1 -0
  406. package/dist/lib/components/Editor/nodes/nodes.d.ts +3 -0
  407. package/dist/lib/components/Editor/nodes/nodes.d.ts.map +1 -0
  408. package/dist/lib/components/Editor/nodes.d.ts +2 -0
  409. package/dist/lib/components/Editor/nodes.d.ts.map +1 -0
  410. package/dist/lib/components/Editor/plugins/actions/actions-plugin.d.ts +4 -0
  411. package/dist/lib/components/Editor/plugins/actions/actions-plugin.d.ts.map +1 -0
  412. package/dist/lib/components/Editor/plugins/actions/character-limit-plugin.d.ts +5 -0
  413. package/dist/lib/components/Editor/plugins/actions/character-limit-plugin.d.ts.map +1 -0
  414. package/dist/lib/components/Editor/plugins/actions/clear-editor-plugin.d.ts +2 -0
  415. package/dist/lib/components/Editor/plugins/actions/clear-editor-plugin.d.ts.map +1 -0
  416. package/dist/lib/components/Editor/plugins/actions/counter-character-plugin.d.ts +6 -0
  417. package/dist/lib/components/Editor/plugins/actions/counter-character-plugin.d.ts.map +1 -0
  418. package/dist/lib/components/Editor/plugins/actions/edit-mode-toggle-plugin.d.ts +2 -0
  419. package/dist/lib/components/Editor/plugins/actions/edit-mode-toggle-plugin.d.ts.map +1 -0
  420. package/dist/lib/components/Editor/plugins/actions/import-export-plugin.d.ts +2 -0
  421. package/dist/lib/components/Editor/plugins/actions/import-export-plugin.d.ts.map +1 -0
  422. package/dist/lib/components/Editor/plugins/actions/markdown-toggle-plugin.d.ts +6 -0
  423. package/dist/lib/components/Editor/plugins/actions/markdown-toggle-plugin.d.ts.map +1 -0
  424. package/dist/lib/components/Editor/plugins/actions/max-length-plugin.d.ts +4 -0
  425. package/dist/lib/components/Editor/plugins/actions/max-length-plugin.d.ts.map +1 -0
  426. package/dist/lib/components/Editor/plugins/actions/share-content-plugin.d.ts +2 -0
  427. package/dist/lib/components/Editor/plugins/actions/share-content-plugin.d.ts.map +1 -0
  428. package/dist/lib/components/Editor/plugins/actions/speech-to-text-plugin.d.ts +7 -0
  429. package/dist/lib/components/Editor/plugins/actions/speech-to-text-plugin.d.ts.map +1 -0
  430. package/dist/lib/components/Editor/plugins/actions/tree-view-plugin.d.ts +3 -0
  431. package/dist/lib/components/Editor/plugins/actions/tree-view-plugin.d.ts.map +1 -0
  432. package/dist/lib/components/Editor/plugins/auto-link-plugin.d.ts +3 -0
  433. package/dist/lib/components/Editor/plugins/auto-link-plugin.d.ts.map +1 -0
  434. package/dist/lib/components/Editor/plugins/autocomplete-plugin.d.ts +11 -0
  435. package/dist/lib/components/Editor/plugins/autocomplete-plugin.d.ts.map +1 -0
  436. package/dist/lib/components/Editor/plugins/code-action-menu-plugin.d.ts +4 -0
  437. package/dist/lib/components/Editor/plugins/code-action-menu-plugin.d.ts.map +1 -0
  438. package/dist/lib/components/Editor/plugins/code-highlight-plugin.d.ts +3 -0
  439. package/dist/lib/components/Editor/plugins/code-highlight-plugin.d.ts.map +1 -0
  440. package/dist/lib/components/Editor/plugins/component-picker-menu-plugin.d.ts +9 -0
  441. package/dist/lib/components/Editor/plugins/component-picker-menu-plugin.d.ts.map +1 -0
  442. package/dist/lib/components/Editor/plugins/context-menu-plugin.d.ts +3 -0
  443. package/dist/lib/components/Editor/plugins/context-menu-plugin.d.ts.map +1 -0
  444. package/dist/lib/components/Editor/plugins/drag-drop-paste-plugin.d.ts +2 -0
  445. package/dist/lib/components/Editor/plugins/drag-drop-paste-plugin.d.ts.map +1 -0
  446. package/dist/lib/components/Editor/plugins/draggable-block-plugin.d.ts +5 -0
  447. package/dist/lib/components/Editor/plugins/draggable-block-plugin.d.ts.map +1 -0
  448. package/dist/lib/components/Editor/plugins/embeds/auto-embed-plugin.d.ts +18 -0
  449. package/dist/lib/components/Editor/plugins/embeds/auto-embed-plugin.d.ts.map +1 -0
  450. package/dist/lib/components/Editor/plugins/embeds/twitter-plugin.d.ts +5 -0
  451. package/dist/lib/components/Editor/plugins/embeds/twitter-plugin.d.ts.map +1 -0
  452. package/dist/lib/components/Editor/plugins/embeds/youtube-plugin.d.ts +5 -0
  453. package/dist/lib/components/Editor/plugins/embeds/youtube-plugin.d.ts.map +1 -0
  454. package/dist/lib/components/Editor/plugins/emoji-picker-plugin.d.ts +2 -0
  455. package/dist/lib/components/Editor/plugins/emoji-picker-plugin.d.ts.map +1 -0
  456. package/dist/lib/components/Editor/plugins/emojis-plugin.d.ts +3 -0
  457. package/dist/lib/components/Editor/plugins/emojis-plugin.d.ts.map +1 -0
  458. package/dist/lib/components/Editor/plugins/floating-link-editor-plugin.d.ts +7 -0
  459. package/dist/lib/components/Editor/plugins/floating-link-editor-plugin.d.ts.map +1 -0
  460. package/dist/lib/components/Editor/plugins/floating-text-format-plugin.d.ts +7 -0
  461. package/dist/lib/components/Editor/plugins/floating-text-format-plugin.d.ts.map +1 -0
  462. package/dist/lib/components/Editor/plugins/images-plugin.d.ts +25 -0
  463. package/dist/lib/components/Editor/plugins/images-plugin.d.ts.map +1 -0
  464. package/dist/lib/components/Editor/plugins/keywords-plugin.d.ts +3 -0
  465. package/dist/lib/components/Editor/plugins/keywords-plugin.d.ts.map +1 -0
  466. package/dist/lib/components/Editor/plugins/layout-plugin.d.ts +13 -0
  467. package/dist/lib/components/Editor/plugins/layout-plugin.d.ts.map +1 -0
  468. package/dist/lib/components/Editor/plugins/link-plugin.d.ts +3 -0
  469. package/dist/lib/components/Editor/plugins/link-plugin.d.ts.map +1 -0
  470. package/dist/lib/components/Editor/plugins/list-max-indent-level-plugin.d.ts +4 -0
  471. package/dist/lib/components/Editor/plugins/list-max-indent-level-plugin.d.ts.map +1 -0
  472. package/dist/lib/components/Editor/plugins/mentions-plugin.d.ts +3 -0
  473. package/dist/lib/components/Editor/plugins/mentions-plugin.d.ts.map +1 -0
  474. package/dist/lib/components/Editor/plugins/picker/alignment-picker-plugin.d.ts +5 -0
  475. package/dist/lib/components/Editor/plugins/picker/alignment-picker-plugin.d.ts.map +1 -0
  476. package/dist/lib/components/Editor/plugins/picker/bulleted-list-picker-plugin.d.ts +3 -0
  477. package/dist/lib/components/Editor/plugins/picker/bulleted-list-picker-plugin.d.ts.map +1 -0
  478. package/dist/lib/components/Editor/plugins/picker/check-list-picker-plugin.d.ts +3 -0
  479. package/dist/lib/components/Editor/plugins/picker/check-list-picker-plugin.d.ts.map +1 -0
  480. package/dist/lib/components/Editor/plugins/picker/code-picker-plugin.d.ts +3 -0
  481. package/dist/lib/components/Editor/plugins/picker/code-picker-plugin.d.ts.map +1 -0
  482. package/dist/lib/components/Editor/plugins/picker/columns-layout-picker-plugin.d.ts +3 -0
  483. package/dist/lib/components/Editor/plugins/picker/columns-layout-picker-plugin.d.ts.map +1 -0
  484. package/dist/lib/components/Editor/plugins/picker/component-picker-menu-plugin.d.ts +2 -0
  485. package/dist/lib/components/Editor/plugins/picker/component-picker-menu-plugin.d.ts.map +1 -0
  486. package/dist/lib/components/Editor/plugins/picker/component-picker-option.d.ts +17 -0
  487. package/dist/lib/components/Editor/plugins/picker/component-picker-option.d.ts.map +1 -0
  488. package/dist/lib/components/Editor/plugins/picker/divider-picker-plugin.d.ts +3 -0
  489. package/dist/lib/components/Editor/plugins/picker/divider-picker-plugin.d.ts.map +1 -0
  490. package/dist/lib/components/Editor/plugins/picker/embeds-picker-plugin.d.ts +5 -0
  491. package/dist/lib/components/Editor/plugins/picker/embeds-picker-plugin.d.ts.map +1 -0
  492. package/dist/lib/components/Editor/plugins/picker/heading-picker-plugin.d.ts +5 -0
  493. package/dist/lib/components/Editor/plugins/picker/heading-picker-plugin.d.ts.map +1 -0
  494. package/dist/lib/components/Editor/plugins/picker/image-picker-plugin.d.ts +3 -0
  495. package/dist/lib/components/Editor/plugins/picker/image-picker-plugin.d.ts.map +1 -0
  496. package/dist/lib/components/Editor/plugins/picker/numbered-list-picker-plugin.d.ts +3 -0
  497. package/dist/lib/components/Editor/plugins/picker/numbered-list-picker-plugin.d.ts.map +1 -0
  498. package/dist/lib/components/Editor/plugins/picker/paragraph-picker-plugin.d.ts +3 -0
  499. package/dist/lib/components/Editor/plugins/picker/paragraph-picker-plugin.d.ts.map +1 -0
  500. package/dist/lib/components/Editor/plugins/picker/quote-picker-plugin.d.ts +3 -0
  501. package/dist/lib/components/Editor/plugins/picker/quote-picker-plugin.d.ts.map +1 -0
  502. package/dist/lib/components/Editor/plugins/picker/table-picker-plugin.d.ts +6 -0
  503. package/dist/lib/components/Editor/plugins/picker/table-picker-plugin.d.ts.map +1 -0
  504. package/dist/lib/components/Editor/plugins/plugins.d.ts +2 -0
  505. package/dist/lib/components/Editor/plugins/plugins.d.ts.map +1 -0
  506. package/dist/lib/components/Editor/plugins/tab-focus-plugin.d.ts +2 -0
  507. package/dist/lib/components/Editor/plugins/tab-focus-plugin.d.ts.map +1 -0
  508. package/dist/lib/components/Editor/plugins/table-plugin.d.ts +34 -0
  509. package/dist/lib/components/Editor/plugins/table-plugin.d.ts.map +1 -0
  510. package/dist/lib/components/Editor/plugins/toolbar/block-format/block-format-data.d.ts +5 -0
  511. package/dist/lib/components/Editor/plugins/toolbar/block-format/block-format-data.d.ts.map +1 -0
  512. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-bulleted-list.d.ts +2 -0
  513. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-bulleted-list.d.ts.map +1 -0
  514. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-check-list.d.ts +2 -0
  515. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-check-list.d.ts.map +1 -0
  516. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-code-block.d.ts +2 -0
  517. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-code-block.d.ts.map +1 -0
  518. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-heading.d.ts +5 -0
  519. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-heading.d.ts.map +1 -0
  520. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-numbered-list.d.ts +2 -0
  521. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-numbered-list.d.ts.map +1 -0
  522. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-paragraph.d.ts +2 -0
  523. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-paragraph.d.ts.map +1 -0
  524. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-quote.d.ts +2 -0
  525. package/dist/lib/components/Editor/plugins/toolbar/block-format/format-quote.d.ts.map +1 -0
  526. package/dist/lib/components/Editor/plugins/toolbar/block-format-toolbar-plugin.d.ts +4 -0
  527. package/dist/lib/components/Editor/plugins/toolbar/block-format-toolbar-plugin.d.ts.map +1 -0
  528. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-columns-layout.d.ts +2 -0
  529. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-columns-layout.d.ts.map +1 -0
  530. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-embeds.d.ts +2 -0
  531. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-embeds.d.ts.map +1 -0
  532. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-horizontal-rule.d.ts +2 -0
  533. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-horizontal-rule.d.ts.map +1 -0
  534. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-image.d.ts +2 -0
  535. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-image.d.ts.map +1 -0
  536. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-table.d.ts +2 -0
  537. package/dist/lib/components/Editor/plugins/toolbar/block-insert/insert-table.d.ts.map +1 -0
  538. package/dist/lib/components/Editor/plugins/toolbar/block-insert-plugin.d.ts +4 -0
  539. package/dist/lib/components/Editor/plugins/toolbar/block-insert-plugin.d.ts.map +1 -0
  540. package/dist/lib/components/Editor/plugins/toolbar/clear-formatting-toolbar-plugin.d.ts +2 -0
  541. package/dist/lib/components/Editor/plugins/toolbar/clear-formatting-toolbar-plugin.d.ts.map +1 -0
  542. package/dist/lib/components/Editor/plugins/toolbar/code-language-toolbar-plugin.d.ts +2 -0
  543. package/dist/lib/components/Editor/plugins/toolbar/code-language-toolbar-plugin.d.ts.map +1 -0
  544. package/dist/lib/components/Editor/plugins/toolbar/element-format-toolbar-plugin.d.ts +4 -0
  545. package/dist/lib/components/Editor/plugins/toolbar/element-format-toolbar-plugin.d.ts.map +1 -0
  546. package/dist/lib/components/Editor/plugins/toolbar/font-background-toolbar-plugin.d.ts +2 -0
  547. package/dist/lib/components/Editor/plugins/toolbar/font-background-toolbar-plugin.d.ts.map +1 -0
  548. package/dist/lib/components/Editor/plugins/toolbar/font-color-toolbar-plugin.d.ts +2 -0
  549. package/dist/lib/components/Editor/plugins/toolbar/font-color-toolbar-plugin.d.ts.map +1 -0
  550. package/dist/lib/components/Editor/plugins/toolbar/font-family-toolbar-plugin.d.ts +2 -0
  551. package/dist/lib/components/Editor/plugins/toolbar/font-family-toolbar-plugin.d.ts.map +1 -0
  552. package/dist/lib/components/Editor/plugins/toolbar/font-format-toolbar-plugin.d.ts +2 -0
  553. package/dist/lib/components/Editor/plugins/toolbar/font-format-toolbar-plugin.d.ts.map +1 -0
  554. package/dist/lib/components/Editor/plugins/toolbar/font-size-toolbar-plugin.d.ts +2 -0
  555. package/dist/lib/components/Editor/plugins/toolbar/font-size-toolbar-plugin.d.ts.map +1 -0
  556. package/dist/lib/components/Editor/plugins/toolbar/history-toolbar-plugin.d.ts +2 -0
  557. package/dist/lib/components/Editor/plugins/toolbar/history-toolbar-plugin.d.ts.map +1 -0
  558. package/dist/lib/components/Editor/plugins/toolbar/horizontal-rule-toolbar-plugin.d.ts +2 -0
  559. package/dist/lib/components/Editor/plugins/toolbar/horizontal-rule-toolbar-plugin.d.ts.map +1 -0
  560. package/dist/lib/components/Editor/plugins/toolbar/image-toolbar-plugin.d.ts +2 -0
  561. package/dist/lib/components/Editor/plugins/toolbar/image-toolbar-plugin.d.ts.map +1 -0
  562. package/dist/lib/components/Editor/plugins/toolbar/link-toolbar-plugin.d.ts +4 -0
  563. package/dist/lib/components/Editor/plugins/toolbar/link-toolbar-plugin.d.ts.map +1 -0
  564. package/dist/lib/components/Editor/plugins/toolbar/subsuper-toolbar-plugin.d.ts +2 -0
  565. package/dist/lib/components/Editor/plugins/toolbar/subsuper-toolbar-plugin.d.ts.map +1 -0
  566. package/dist/lib/components/Editor/plugins/toolbar/table-toolbar-plugin.d.ts +2 -0
  567. package/dist/lib/components/Editor/plugins/toolbar/table-toolbar-plugin.d.ts.map +1 -0
  568. package/dist/lib/components/Editor/plugins/toolbar/toolbar-plugin.d.ts +6 -0
  569. package/dist/lib/components/Editor/plugins/toolbar/toolbar-plugin.d.ts.map +1 -0
  570. package/dist/lib/components/Editor/plugins/typing-pref-plugin.d.ts +4 -0
  571. package/dist/lib/components/Editor/plugins/typing-pref-plugin.d.ts.map +1 -0
  572. package/dist/lib/components/Editor/plugins.d.ts +2 -0
  573. package/dist/lib/components/Editor/plugins.d.ts.map +1 -0
  574. package/dist/lib/components/Editor/shared/can-use-dom.d.ts +2 -0
  575. package/dist/lib/components/Editor/shared/can-use-dom.d.ts.map +1 -0
  576. package/dist/lib/components/Editor/shared/caret-from-point.d.ts +5 -0
  577. package/dist/lib/components/Editor/shared/caret-from-point.d.ts.map +1 -0
  578. package/dist/lib/components/Editor/shared/environment.d.ts +18 -0
  579. package/dist/lib/components/Editor/shared/environment.d.ts.map +1 -0
  580. package/dist/lib/components/Editor/shared/invariant.d.ts +2 -0
  581. package/dist/lib/components/Editor/shared/invariant.d.ts.map +1 -0
  582. package/dist/lib/components/Editor/shared/normalize-class-names.d.ts +2 -0
  583. package/dist/lib/components/Editor/shared/normalize-class-names.d.ts.map +1 -0
  584. package/dist/lib/components/Editor/shared/react-patches.d.ts +2 -0
  585. package/dist/lib/components/Editor/shared/react-patches.d.ts.map +1 -0
  586. package/dist/lib/components/Editor/shared/react-test-utils.d.ts +3 -0
  587. package/dist/lib/components/Editor/shared/react-test-utils.d.ts.map +1 -0
  588. package/dist/lib/components/Editor/shared/simple-diff-with-cursor.d.ts +6 -0
  589. package/dist/lib/components/Editor/shared/simple-diff-with-cursor.d.ts.map +1 -0
  590. package/dist/lib/components/Editor/shared/use-layout-effect.d.ts +4 -0
  591. package/dist/lib/components/Editor/shared/use-layout-effect.d.ts.map +1 -0
  592. package/dist/lib/components/Editor/shared/warn-only-once.d.ts +2 -0
  593. package/dist/lib/components/Editor/shared/warn-only-once.d.ts.map +1 -0
  594. package/dist/lib/components/Editor/themes/editor-theme.d.ts +3 -0
  595. package/dist/lib/components/Editor/themes/editor-theme.d.ts.map +1 -0
  596. package/dist/lib/components/Editor/transformers/index.d.ts +16 -0
  597. package/dist/lib/components/Editor/transformers/index.d.ts.map +1 -0
  598. package/dist/lib/components/Editor/transformers/markdown-emoji-transformer.d.ts +3 -0
  599. package/dist/lib/components/Editor/transformers/markdown-emoji-transformer.d.ts.map +1 -0
  600. package/dist/lib/components/Editor/transformers/markdown-hr-transformer.d.ts +3 -0
  601. package/dist/lib/components/Editor/transformers/markdown-hr-transformer.d.ts.map +1 -0
  602. package/dist/lib/components/Editor/transformers/markdown-image-transformer.d.ts +3 -0
  603. package/dist/lib/components/Editor/transformers/markdown-image-transformer.d.ts.map +1 -0
  604. package/dist/lib/components/Editor/transformers/markdown-table-transformer.d.ts +3 -0
  605. package/dist/lib/components/Editor/transformers/markdown-table-transformer.d.ts.map +1 -0
  606. package/dist/lib/components/Editor/transformers/markdown-tweet-transformer.d.ts +3 -0
  607. package/dist/lib/components/Editor/transformers/markdown-tweet-transformer.d.ts.map +1 -0
  608. package/dist/lib/components/Editor/types.d.ts +23 -0
  609. package/dist/lib/components/Editor/types.d.ts.map +1 -0
  610. package/dist/lib/components/Editor/utils/can-use-dom.d.ts +2 -0
  611. package/dist/lib/components/Editor/utils/can-use-dom.d.ts.map +1 -0
  612. package/dist/lib/components/Editor/utils/collapsible.d.ts +3 -0
  613. package/dist/lib/components/Editor/utils/collapsible.d.ts.map +1 -0
  614. package/dist/lib/components/Editor/utils/doc-serialization.d.ts +4 -0
  615. package/dist/lib/components/Editor/utils/doc-serialization.d.ts.map +1 -0
  616. package/dist/lib/components/Editor/utils/emoji-list.d.ts +21 -0
  617. package/dist/lib/components/Editor/utils/emoji-list.d.ts.map +1 -0
  618. package/dist/lib/components/Editor/utils/get-dom-range-rect.d.ts +2 -0
  619. package/dist/lib/components/Editor/utils/get-dom-range-rect.d.ts.map +1 -0
  620. package/dist/lib/components/Editor/utils/get-selected-node.d.ts +3 -0
  621. package/dist/lib/components/Editor/utils/get-selected-node.d.ts.map +1 -0
  622. package/dist/lib/components/Editor/utils/guard.d.ts +2 -0
  623. package/dist/lib/components/Editor/utils/guard.d.ts.map +1 -0
  624. package/dist/lib/components/Editor/utils/is-mobile-width.d.ts +2 -0
  625. package/dist/lib/components/Editor/utils/is-mobile-width.d.ts.map +1 -0
  626. package/dist/lib/components/Editor/utils/set-floating-elem-position-for-link-editor.d.ts +2 -0
  627. package/dist/lib/components/Editor/utils/set-floating-elem-position-for-link-editor.d.ts.map +1 -0
  628. package/dist/lib/components/Editor/utils/set-floating-elem-position.d.ts +2 -0
  629. package/dist/lib/components/Editor/utils/set-floating-elem-position.d.ts.map +1 -0
  630. package/dist/lib/components/Editor/utils/swipe.d.ts +5 -0
  631. package/dist/lib/components/Editor/utils/swipe.d.ts.map +1 -0
  632. package/dist/lib/components/Editor/utils/url.d.ts +3 -0
  633. package/dist/lib/components/Editor/utils/url.d.ts.map +1 -0
  634. package/dist/lib/components/Empty/Empty.d.ts +12 -0
  635. package/dist/lib/components/Empty/Empty.d.ts.map +1 -0
  636. package/dist/lib/components/Empty/index.d.ts +3 -0
  637. package/dist/lib/components/Empty/index.d.ts.map +1 -0
  638. package/dist/lib/components/ErrorBoundary/ErrorBoundary.d.ts +7 -0
  639. package/dist/lib/components/ErrorBoundary/ErrorBoundary.d.ts.map +1 -0
  640. package/dist/lib/components/ErrorBoundary/ErrorPage.d.ts +38 -0
  641. package/dist/lib/components/ErrorBoundary/ErrorPage.d.ts.map +1 -0
  642. package/dist/lib/components/ErrorBoundary/index.d.ts +3 -0
  643. package/dist/lib/components/ErrorBoundary/index.d.ts.map +1 -0
  644. package/dist/lib/components/FilePreview/FilePreview.d.ts +8 -0
  645. package/dist/lib/components/FilePreview/FilePreview.d.ts.map +1 -0
  646. package/dist/lib/components/FilePreview/index.d.ts +2 -0
  647. package/dist/lib/components/FilePreview/index.d.ts.map +1 -0
  648. package/dist/lib/components/Form/Form.d.ts +6 -3
  649. package/dist/lib/components/Form/Form.d.ts.map +1 -1
  650. package/dist/lib/components/HierarchyGraph/HierarchyGraph.d.ts +24 -0
  651. package/dist/lib/components/HierarchyGraph/HierarchyGraph.d.ts.map +1 -0
  652. package/dist/lib/components/HierarchyGraph/index.d.ts +5 -0
  653. package/dist/lib/components/HierarchyGraph/index.d.ts.map +1 -0
  654. package/dist/lib/components/PageHeader/PageHeader.d.ts +8 -0
  655. package/dist/lib/components/PageHeader/PageHeader.d.ts.map +1 -0
  656. package/dist/lib/components/PageHeader/PageHeaderSkeleton.d.ts +10 -0
  657. package/dist/lib/components/PageHeader/PageHeaderSkeleton.d.ts.map +1 -0
  658. package/dist/lib/components/PageHeader/index.d.ts +3 -0
  659. package/dist/lib/components/PageHeader/index.d.ts.map +1 -0
  660. package/dist/lib/components/PhoneField/PhoneField.d.ts +1 -0
  661. package/dist/lib/components/PhoneField/PhoneField.d.ts.map +1 -1
  662. package/dist/lib/components/RadioGroup/RadioGroup.d.ts +23 -0
  663. package/dist/lib/components/RadioGroup/RadioGroup.d.ts.map +1 -0
  664. package/dist/lib/components/RadioGroup/index.d.ts +3 -0
  665. package/dist/lib/components/RadioGroup/index.d.ts.map +1 -0
  666. package/dist/lib/components/Select/Select.d.ts +21 -0
  667. package/dist/lib/components/Select/Select.d.ts.map +1 -0
  668. package/dist/lib/components/Select/SelectFilter.d.ts +20 -0
  669. package/dist/lib/components/Select/SelectFilter.d.ts.map +1 -0
  670. package/dist/lib/components/Select/components/MultiSelect/MultiSelect.d.ts +27 -0
  671. package/dist/lib/components/Select/components/MultiSelect/MultiSelect.d.ts.map +1 -0
  672. package/dist/lib/components/Select/components/MultiSelect/MultiSelectFilter.d.ts +28 -0
  673. package/dist/lib/components/Select/components/MultiSelect/MultiSelectFilter.d.ts.map +1 -0
  674. package/dist/lib/components/Select/components/SingleSelect/SingleSelect.d.ts +41 -0
  675. package/dist/lib/components/Select/components/SingleSelect/SingleSelect.d.ts.map +1 -0
  676. package/dist/lib/components/Select/components/SingleSelect/SingleSelectFilter.d.ts +28 -0
  677. package/dist/lib/components/Select/components/SingleSelect/SingleSelectFilter.d.ts.map +1 -0
  678. package/dist/lib/components/Select/hooks/useMultiSelect.d.ts +33 -0
  679. package/dist/lib/components/Select/hooks/useMultiSelect.d.ts.map +1 -0
  680. package/dist/lib/components/Select/hooks/useSelect.d.ts +25 -0
  681. package/dist/lib/components/Select/hooks/useSelect.d.ts.map +1 -0
  682. package/dist/lib/components/Select/hooks/useSingleSelect.d.ts +31 -0
  683. package/dist/lib/components/Select/hooks/useSingleSelect.d.ts.map +1 -0
  684. package/dist/lib/components/Select/index.d.ts +40 -0
  685. package/dist/lib/components/Select/index.d.ts.map +1 -0
  686. package/dist/lib/components/Select/types.d.ts +38 -0
  687. package/dist/lib/components/Select/types.d.ts.map +1 -0
  688. package/dist/lib/components/Sidebar/Sidebar.d.ts +24 -0
  689. package/dist/lib/components/Sidebar/Sidebar.d.ts.map +1 -0
  690. package/dist/lib/components/Sidebar/index.d.ts +2 -0
  691. package/dist/lib/components/Sidebar/index.d.ts.map +1 -0
  692. package/dist/lib/components/Sortable/Sortable.d.ts +39 -0
  693. package/dist/lib/components/Sortable/Sortable.d.ts.map +1 -0
  694. package/dist/lib/components/Sortable/index.d.ts +3 -0
  695. package/dist/lib/components/Sortable/index.d.ts.map +1 -0
  696. package/dist/lib/components/StepProgressIndicator/StepProgressIndicator.d.ts +12 -0
  697. package/dist/lib/components/StepProgressIndicator/StepProgressIndicator.d.ts.map +1 -0
  698. package/dist/lib/components/StepProgressIndicator/index.d.ts +3 -0
  699. package/dist/lib/components/StepProgressIndicator/index.d.ts.map +1 -0
  700. package/dist/lib/components/Switch/Switch.d.ts.map +1 -1
  701. package/dist/lib/components/Tabs/Tabs.d.ts +27 -0
  702. package/dist/lib/components/Tabs/Tabs.d.ts.map +1 -0
  703. package/dist/lib/components/Tabs/TabsSkeleton.d.ts +11 -0
  704. package/dist/lib/components/Tabs/TabsSkeleton.d.ts.map +1 -0
  705. package/dist/lib/components/Tabs/index.d.ts +3 -0
  706. package/dist/lib/components/Tabs/index.d.ts.map +1 -0
  707. package/dist/lib/components/TextArea/TextArea.d.ts.map +1 -1
  708. package/dist/lib/components/TextField/TextField.d.ts.map +1 -1
  709. package/dist/lib/components/UploadFile/UploadFile.d.ts +26 -0
  710. package/dist/lib/components/UploadFile/UploadFile.d.ts.map +1 -0
  711. package/dist/lib/components/UploadFile/index.d.ts +2 -0
  712. package/dist/lib/components/UploadFile/index.d.ts.map +1 -0
  713. package/dist/lib/components/ValueFilter/ValueFilter.d.ts +11 -0
  714. package/dist/lib/components/ValueFilter/ValueFilter.d.ts.map +1 -0
  715. package/dist/lib/components/ValueFilter/index.d.ts +3 -0
  716. package/dist/lib/components/ValueFilter/index.d.ts.map +1 -0
  717. package/dist/lib/components/ViewTabs/ViewTabs.d.ts +23 -0
  718. package/dist/lib/components/ViewTabs/ViewTabs.d.ts.map +1 -0
  719. package/dist/lib/components/ViewTabs/index.d.ts +3 -0
  720. package/dist/lib/components/ViewTabs/index.d.ts.map +1 -0
  721. package/dist/lib/components/index.d.ts +21 -1
  722. package/dist/lib/components/index.d.ts.map +1 -1
  723. package/dist/lib/config/index.d.ts +6 -0
  724. package/dist/lib/config/index.d.ts.map +1 -1
  725. package/dist/lib/context/ConfirmContext.d.ts +21 -0
  726. package/dist/lib/context/ConfirmContext.d.ts.map +1 -0
  727. package/dist/lib/context/ThemeContext.d.ts +1 -1
  728. package/dist/lib/context/ThemeContext.d.ts.map +1 -1
  729. package/dist/lib/context/index.d.ts +2 -1
  730. package/dist/lib/context/index.d.ts.map +1 -1
  731. package/dist/lib/hooks/index.d.ts +7 -1
  732. package/dist/lib/hooks/index.d.ts.map +1 -1
  733. package/dist/lib/hooks/useConfirm.d.ts +4 -0
  734. package/dist/lib/hooks/useConfirm.d.ts.map +1 -0
  735. package/dist/lib/hooks/useDialog.d.ts +11 -0
  736. package/dist/lib/hooks/useDialog.d.ts.map +1 -0
  737. package/dist/lib/hooks/useIsMobile.d.ts +2 -0
  738. package/dist/lib/hooks/useIsMobile.d.ts.map +1 -0
  739. package/dist/lib/hooks/useSSE.d.ts +21 -0
  740. package/dist/lib/hooks/useSSE.d.ts.map +1 -0
  741. package/dist/lib/hooks/useSlugParams.d.ts +12 -0
  742. package/dist/lib/hooks/useSlugParams.d.ts.map +1 -0
  743. package/dist/lib/hooks/useTimer.d.ts +6 -0
  744. package/dist/lib/hooks/useTimer.d.ts.map +1 -0
  745. package/dist/lib/index.d.ts +3 -2
  746. package/dist/lib/index.d.ts.map +1 -1
  747. package/dist/lib/selects/app/AppFilter.d.ts +11 -0
  748. package/dist/lib/selects/app/AppFilter.d.ts.map +1 -0
  749. package/dist/lib/selects/app/AppSelector.d.ts +4 -0
  750. package/dist/lib/selects/app/AppSelector.d.ts.map +1 -0
  751. package/dist/lib/selects/app/index.d.ts +3 -0
  752. package/dist/lib/selects/app/index.d.ts.map +1 -0
  753. package/dist/lib/selects/app-code/AppCodeFilter.d.ts +11 -0
  754. package/dist/lib/selects/app-code/AppCodeFilter.d.ts.map +1 -0
  755. package/dist/lib/selects/app-code/AppCodeSelector.d.ts +4 -0
  756. package/dist/lib/selects/app-code/AppCodeSelector.d.ts.map +1 -0
  757. package/dist/lib/selects/app-code/index.d.ts +3 -0
  758. package/dist/lib/selects/app-code/index.d.ts.map +1 -0
  759. package/dist/lib/selects/cloud-provider/CloudProviderFilter.d.ts +11 -0
  760. package/dist/lib/selects/cloud-provider/CloudProviderFilter.d.ts.map +1 -0
  761. package/dist/lib/selects/cloud-provider/CloudProviderSelector.d.ts +4 -0
  762. package/dist/lib/selects/cloud-provider/CloudProviderSelector.d.ts.map +1 -0
  763. package/dist/lib/selects/cloud-provider/index.d.ts +3 -0
  764. package/dist/lib/selects/cloud-provider/index.d.ts.map +1 -0
  765. package/dist/lib/selects/currency/CurrencyFilter.d.ts +11 -0
  766. package/dist/lib/selects/currency/CurrencyFilter.d.ts.map +1 -0
  767. package/dist/lib/selects/currency/CurrencySelector.d.ts +4 -0
  768. package/dist/lib/selects/currency/CurrencySelector.d.ts.map +1 -0
  769. package/dist/lib/selects/currency/currencies.d.ts +3 -0
  770. package/dist/lib/selects/currency/currencies.d.ts.map +1 -0
  771. package/dist/lib/selects/currency/index.d.ts +3 -0
  772. package/dist/lib/selects/currency/index.d.ts.map +1 -0
  773. package/dist/lib/selects/deployment/DeploymentFilter.d.ts +11 -0
  774. package/dist/lib/selects/deployment/DeploymentFilter.d.ts.map +1 -0
  775. package/dist/lib/selects/deployment/DeploymentSelector.d.ts +4 -0
  776. package/dist/lib/selects/deployment/DeploymentSelector.d.ts.map +1 -0
  777. package/dist/lib/selects/deployment/index.d.ts +3 -0
  778. package/dist/lib/selects/deployment/index.d.ts.map +1 -0
  779. package/dist/lib/selects/feature/FeatureFilter.d.ts +11 -0
  780. package/dist/lib/selects/feature/FeatureFilter.d.ts.map +1 -0
  781. package/dist/lib/selects/feature/FeatureSelector.d.ts +4 -0
  782. package/dist/lib/selects/feature/FeatureSelector.d.ts.map +1 -0
  783. package/dist/lib/selects/feature/index.d.ts +3 -0
  784. package/dist/lib/selects/feature/index.d.ts.map +1 -0
  785. package/dist/lib/selects/index.d.ts +12 -0
  786. package/dist/lib/selects/index.d.ts.map +1 -0
  787. package/dist/lib/selects/industry/IndustryFilter.d.ts +11 -0
  788. package/dist/lib/selects/industry/IndustryFilter.d.ts.map +1 -0
  789. package/dist/lib/selects/industry/IndustrySelector.d.ts +4 -0
  790. package/dist/lib/selects/industry/IndustrySelector.d.ts.map +1 -0
  791. package/dist/lib/selects/industry/index.d.ts +3 -0
  792. package/dist/lib/selects/industry/index.d.ts.map +1 -0
  793. package/dist/lib/selects/locale/LocaleFilter.d.ts +11 -0
  794. package/dist/lib/selects/locale/LocaleFilter.d.ts.map +1 -0
  795. package/dist/lib/selects/locale/LocaleSelector.d.ts +4 -0
  796. package/dist/lib/selects/locale/LocaleSelector.d.ts.map +1 -0
  797. package/dist/lib/selects/locale/index.d.ts +3 -0
  798. package/dist/lib/selects/locale/index.d.ts.map +1 -0
  799. package/dist/lib/selects/locale/locales.d.ts +3 -0
  800. package/dist/lib/selects/locale/locales.d.ts.map +1 -0
  801. package/dist/lib/selects/microfrontend/MicrofrontendSelector.d.ts +4 -0
  802. package/dist/lib/selects/microfrontend/MicrofrontendSelector.d.ts.map +1 -0
  803. package/dist/lib/selects/microfrontend/index.d.ts +2 -0
  804. package/dist/lib/selects/microfrontend/index.d.ts.map +1 -0
  805. package/dist/lib/selects/plan/PlanFilter.d.ts +11 -0
  806. package/dist/lib/selects/plan/PlanFilter.d.ts.map +1 -0
  807. package/dist/lib/selects/plan/PlanSelector.d.ts +4 -0
  808. package/dist/lib/selects/plan/PlanSelector.d.ts.map +1 -0
  809. package/dist/lib/selects/plan/index.d.ts +3 -0
  810. package/dist/lib/selects/plan/index.d.ts.map +1 -0
  811. package/dist/lib/selects/region/RegionFilter.d.ts +11 -0
  812. package/dist/lib/selects/region/RegionFilter.d.ts.map +1 -0
  813. package/dist/lib/selects/region/RegionSelector.d.ts +4 -0
  814. package/dist/lib/selects/region/RegionSelector.d.ts.map +1 -0
  815. package/dist/lib/selects/region/index.d.ts +3 -0
  816. package/dist/lib/selects/region/index.d.ts.map +1 -0
  817. package/dist/lib/selects/timezone/TimezoneFilter.d.ts +11 -0
  818. package/dist/lib/selects/timezone/TimezoneFilter.d.ts.map +1 -0
  819. package/dist/lib/selects/timezone/TimezoneSelector.d.ts +4 -0
  820. package/dist/lib/selects/timezone/TimezoneSelector.d.ts.map +1 -0
  821. package/dist/lib/selects/timezone/index.d.ts +3 -0
  822. package/dist/lib/selects/timezone/index.d.ts.map +1 -0
  823. package/dist/lib/selects/timezone/timezones.d.ts +3 -0
  824. package/dist/lib/selects/timezone/timezones.d.ts.map +1 -0
  825. package/dist/lib/services/table-views.service.d.ts +25 -0
  826. package/dist/lib/services/table-views.service.d.ts.map +1 -0
  827. package/dist/lib/types/api-response.d.ts +21 -0
  828. package/dist/lib/types/api-response.d.ts.map +1 -0
  829. package/dist/lib/types/table-filter.d.ts +41 -0
  830. package/dist/lib/types/table-filter.d.ts.map +1 -0
  831. package/dist/lib/utils/axios.d.ts.map +1 -1
  832. package/dist/lib/utils/index.d.ts +1 -0
  833. package/dist/lib/utils/index.d.ts.map +1 -1
  834. package/dist/lib/utils/motion.d.ts +2 -0
  835. package/dist/lib/utils/motion.d.ts.map +1 -0
  836. package/dist/lib/utils/slug.d.ts +7 -0
  837. package/dist/lib/utils/slug.d.ts.map +1 -0
  838. package/dist/plus.js +18 -0
  839. package/dist/plus.js.map +1 -0
  840. package/dist/popover.js +33 -0
  841. package/dist/popover.js.map +1 -0
  842. package/dist/proxy.js +11392 -0
  843. package/dist/proxy.js.map +1 -0
  844. package/dist/react-error-boundary.js +67 -0
  845. package/dist/react-error-boundary.js.map +1 -0
  846. package/dist/select2.js +116 -0
  847. package/dist/select2.js.map +1 -0
  848. package/dist/selects/app-code.js +37 -0
  849. package/dist/selects/app-code.js.map +1 -0
  850. package/dist/selects/app.js +2 -0
  851. package/dist/selects/app.js.map +1 -0
  852. package/dist/selects/cloud-provider.js +2 -0
  853. package/dist/selects/cloud-provider.js.map +1 -0
  854. package/dist/selects/currency.js +2 -0
  855. package/dist/selects/currency.js.map +1 -0
  856. package/dist/selects/deployment.js +2 -0
  857. package/dist/selects/deployment.js.map +1 -0
  858. package/dist/selects/feature.js +2 -0
  859. package/dist/selects/feature.js.map +1 -0
  860. package/dist/selects/industry.js +2 -0
  861. package/dist/selects/industry.js.map +1 -0
  862. package/dist/selects/locale.js +2 -0
  863. package/dist/selects/locale.js.map +1 -0
  864. package/dist/selects/microfrontend.js +2 -0
  865. package/dist/selects/microfrontend.js.map +1 -0
  866. package/dist/selects/plan.js +2 -0
  867. package/dist/selects/plan.js.map +1 -0
  868. package/dist/selects/region.js +2 -0
  869. package/dist/selects/region.js.map +1 -0
  870. package/dist/selects/timezone.js +2 -0
  871. package/dist/selects/timezone.js.map +1 -0
  872. package/dist/separator2.js +1 -27
  873. package/dist/separator2.js.map +1 -1
  874. package/dist/shadcn/index.d.ts +2 -0
  875. package/dist/shadcn/index.d.ts.map +1 -1
  876. package/dist/shadcn/shadcnAlert/alert.d.ts.map +1 -1
  877. package/dist/shadcn/shadcnAlert/index.d.ts +1 -1
  878. package/dist/shadcn/shadcnAlert/index.d.ts.map +1 -1
  879. package/dist/shadcn/shadcnBadge/Badge.d.ts +1 -1
  880. package/dist/shadcn/shadcnBreadcrumb/breadcrumb.d.ts +18 -0
  881. package/dist/shadcn/shadcnBreadcrumb/breadcrumb.d.ts.map +1 -0
  882. package/dist/shadcn/shadcnBreadcrumb/index.d.ts +2 -0
  883. package/dist/shadcn/shadcnBreadcrumb/index.d.ts.map +1 -0
  884. package/dist/shadcn/shadcnButton/Button.d.ts +2 -2
  885. package/dist/shadcn/shadcnButton/Button.d.ts.map +1 -1
  886. package/dist/shadcn/shadcnCalendar/calendar.d.ts +1 -1
  887. package/dist/shadcn/shadcnCalendar/calendar.d.ts.map +1 -1
  888. package/dist/shadcn/shadcnChart/Chart.d.ts +2 -2
  889. package/dist/shadcn/shadcnChart/Chart.d.ts.map +1 -1
  890. package/dist/shadcn/shadcnCollapsible/collapsible.d.ts +7 -0
  891. package/dist/shadcn/shadcnCollapsible/collapsible.d.ts.map +1 -0
  892. package/dist/shadcn/shadcnCollapsible/index.d.ts +2 -0
  893. package/dist/shadcn/shadcnCollapsible/index.d.ts.map +1 -0
  894. package/dist/shadcn/shadcnDialog/dialog.d.ts +20 -0
  895. package/dist/shadcn/shadcnDialog/dialog.d.ts.map +1 -0
  896. package/dist/shadcn/shadcnDialog/index.d.ts +2 -0
  897. package/dist/shadcn/shadcnDialog/index.d.ts.map +1 -0
  898. package/dist/shadcn/shadcnDropdownMenu/dropdown-menu.d.ts +1 -1
  899. package/dist/shadcn/shadcnDropdownMenu/dropdown-menu.d.ts.map +1 -1
  900. package/dist/shadcn/shadcnForm/form.d.ts +1 -1
  901. package/dist/shadcn/shadcnForm/form.d.ts.map +1 -1
  902. package/dist/shadcn/shadcnInputOTP/InputOTP.d.ts +3 -3
  903. package/dist/shadcn/shadcnInputOTP/InputOTP.d.ts.map +1 -1
  904. package/dist/shadcn/shadcnMultiSelect/index.d.ts +3 -0
  905. package/dist/shadcn/shadcnMultiSelect/index.d.ts.map +1 -0
  906. package/dist/shadcn/shadcnMultiSelect/multi-select.d.ts +61 -0
  907. package/dist/shadcn/shadcnMultiSelect/multi-select.d.ts.map +1 -0
  908. package/dist/shadcn/shadcnProgress/Progress.d.ts +1 -1
  909. package/dist/shadcn/shadcnProgress/Progress.d.ts.map +1 -1
  910. package/dist/shadcn/shadcnRadioGroup/RadioGroup.d.ts +6 -0
  911. package/dist/shadcn/shadcnRadioGroup/RadioGroup.d.ts.map +1 -0
  912. package/dist/shadcn/shadcnRadioGroup/index.d.ts +2 -0
  913. package/dist/shadcn/shadcnRadioGroup/index.d.ts.map +1 -0
  914. package/dist/shadcn/shadcnSheet/sheet.d.ts +1 -1
  915. package/dist/shadcn/shadcnSheet/sheet.d.ts.map +1 -1
  916. package/dist/shadcn/shadcnSidebar/index.d.ts +2 -0
  917. package/dist/shadcn/shadcnSidebar/index.d.ts.map +1 -0
  918. package/dist/shadcn/shadcnSidebar/sidebar.d.ts +86 -0
  919. package/dist/shadcn/shadcnSidebar/sidebar.d.ts.map +1 -0
  920. package/dist/shadcn/shadcnSingleSelect/index.d.ts +3 -0
  921. package/dist/shadcn/shadcnSingleSelect/index.d.ts.map +1 -0
  922. package/dist/shadcn/shadcnSingleSelect/single-select.d.ts +61 -0
  923. package/dist/shadcn/shadcnSingleSelect/single-select.d.ts.map +1 -0
  924. package/dist/shadcn/shadcnSonner/sonner.d.ts +1 -1
  925. package/dist/shadcn/shadcnSonner/sonner.d.ts.map +1 -1
  926. package/dist/shadcn/shadcnSwitch/Switch.d.ts.map +1 -1
  927. package/dist/shadcn/shadcnTable/table.d.ts +1 -1
  928. package/dist/shadcn/shadcnTable/table.d.ts.map +1 -1
  929. package/dist/shadcn/shadcnTabs/index.d.ts +2 -0
  930. package/dist/shadcn/shadcnTabs/index.d.ts.map +1 -0
  931. package/dist/shadcn/shadcnTabs/tabs.d.ts +8 -0
  932. package/dist/shadcn/shadcnTabs/tabs.d.ts.map +1 -0
  933. package/dist/shadcn/shadcnTooltip/tooltip.d.ts +1 -1
  934. package/dist/shadcn/shadcnTooltip/tooltip.d.ts.map +1 -1
  935. package/dist/share-2.js +42 -0
  936. package/dist/share-2.js.map +1 -0
  937. package/dist/text-align-justify.js +34 -0
  938. package/dist/text-align-justify.js.map +1 -0
  939. package/dist/trash-2.js +55 -0
  940. package/dist/trash-2.js.map +1 -0
  941. package/dist/types/api-response.js +2 -0
  942. package/dist/types/api-response.js.map +1 -0
  943. package/dist/types/table-filter.js +17 -0
  944. package/dist/types/table-filter.js.map +1 -0
  945. package/dist/upload.js +19 -0
  946. package/dist/upload.js.map +1 -0
  947. package/dist/useConfirm.js +37 -0
  948. package/dist/useConfirm.js.map +1 -0
  949. package/dist/useDataTable.js +26545 -0
  950. package/dist/useDataTable.js.map +1 -0
  951. package/dist/useIsMobile.js +19 -0
  952. package/dist/useIsMobile.js.map +1 -0
  953. package/dist/useTheme.js.map +1 -1
  954. package/dist/useTimer.js +112 -0
  955. package/dist/useTimer.js.map +1 -0
  956. package/dist/utils/axios.js +1 -1
  957. package/dist/utils/motion.js +4425 -0
  958. package/dist/utils/motion.js.map +1 -0
  959. package/dist/utils/slug.js +15 -0
  960. package/dist/utils/slug.js.map +1 -0
  961. package/dist/utils.js +204 -39
  962. package/dist/utils.js.map +1 -1
  963. package/dist/value.js +820 -0
  964. package/dist/value.js.map +1 -0
  965. package/dist/x.js +18 -0
  966. package/dist/x.js.map +1 -0
  967. package/package.json +196 -7
  968. package/dist/SelectField.js +0 -1351
  969. package/dist/SelectField.js.map +0 -1
  970. package/dist/chevron-down.js.map +0 -1
  971. package/dist/components/SelectField.js +0 -2
  972. package/dist/components/SelectField.js.map +0 -1
  973. package/dist/lib/components/SelectField/SelectField.d.ts +0 -24
  974. package/dist/lib/components/SelectField/SelectField.d.ts.map +0 -1
  975. package/dist/lib/components/SelectField/index.d.ts +0 -3
  976. package/dist/lib/components/SelectField/index.d.ts.map +0 -1
@@ -1,13 +1,11 @@
1
1
  import * as React from 'react';
2
- import { useLayoutEffect, useState } from 'react';
3
- import { P as Primitive, a as composeEventHandlers, d as dispatchDiscreteCustomEvent } from './index13.js';
4
- import { u as useComposedRefs } from './index5.js';
5
- import { u as useCallbackRef$1 } from './index3.js';
2
+ import { useState } from 'react';
3
+ import { P as Primitive, c as composeEventHandlers, d as dispatchDiscreteCustomEvent } from './index11.js';
4
+ import { u as useComposedRefs } from './index6.js';
5
+ import { u as useCallbackRef$1 } from './index23.js';
6
6
  import { jsx } from 'react/jsx-runtime';
7
- import { u as useLayoutEffect2 } from './index6.js';
8
- import * as ReactDOM from 'react-dom';
9
7
  import ReactDOM__default from 'react-dom';
10
- import { c as createContextScope, u as useSize } from './index12.js';
8
+ import { u as useLayoutEffect2 } from './index24.js';
11
9
 
12
10
  // packages/react/use-escape-keydown/src/use-escape-keydown.tsx
13
11
  function useEscapeKeydown(onEscapeKeyDownProp, ownerDocument = globalThis?.document) {
@@ -225,18 +223,18 @@ function handleAndDispatchCustomEvent(name, handler, detail, { discrete }) {
225
223
  }
226
224
  }
227
225
 
228
- var count$1 = 0;
226
+ var count = 0;
229
227
  function useFocusGuards() {
230
228
  React.useEffect(() => {
231
229
  const edgeGuards = document.querySelectorAll("[data-radix-focus-guard]");
232
230
  document.body.insertAdjacentElement("afterbegin", edgeGuards[0] ?? createFocusGuard());
233
231
  document.body.insertAdjacentElement("beforeend", edgeGuards[1] ?? createFocusGuard());
234
- count$1++;
232
+ count++;
235
233
  return () => {
236
- if (count$1 === 1) {
234
+ if (count === 1) {
237
235
  document.querySelectorAll("[data-radix-focus-guard]").forEach((node) => node.remove());
238
236
  }
239
- count$1--;
237
+ count--;
240
238
  };
241
239
  }, []);
242
240
  }
@@ -451,2503 +449,6 @@ function removeLinks(items) {
451
449
  return items.filter((item) => item.tagName !== "A");
452
450
  }
453
451
 
454
- // packages/react/id/src/id.tsx
455
- var useReactId = React[" useId ".trim().toString()] || (() => void 0);
456
- var count = 0;
457
- function useId(deterministicId) {
458
- const [id, setId] = React.useState(useReactId());
459
- useLayoutEffect2(() => {
460
- setId((reactId) => reactId ?? String(count++));
461
- }, [deterministicId]);
462
- return deterministicId || (id ? `radix-${id}` : "");
463
- }
464
-
465
- /**
466
- * Custom positioning reference element.
467
- * @see https://floating-ui.com/docs/virtual-elements
468
- */
469
-
470
- const sides = ['top', 'right', 'bottom', 'left'];
471
- const min = Math.min;
472
- const max = Math.max;
473
- const round = Math.round;
474
- const floor = Math.floor;
475
- const createCoords = v => ({
476
- x: v,
477
- y: v
478
- });
479
- const oppositeSideMap = {
480
- left: 'right',
481
- right: 'left',
482
- bottom: 'top',
483
- top: 'bottom'
484
- };
485
- const oppositeAlignmentMap = {
486
- start: 'end',
487
- end: 'start'
488
- };
489
- function clamp(start, value, end) {
490
- return max(start, min(value, end));
491
- }
492
- function evaluate(value, param) {
493
- return typeof value === 'function' ? value(param) : value;
494
- }
495
- function getSide(placement) {
496
- return placement.split('-')[0];
497
- }
498
- function getAlignment(placement) {
499
- return placement.split('-')[1];
500
- }
501
- function getOppositeAxis(axis) {
502
- return axis === 'x' ? 'y' : 'x';
503
- }
504
- function getAxisLength(axis) {
505
- return axis === 'y' ? 'height' : 'width';
506
- }
507
- const yAxisSides = /*#__PURE__*/new Set(['top', 'bottom']);
508
- function getSideAxis(placement) {
509
- return yAxisSides.has(getSide(placement)) ? 'y' : 'x';
510
- }
511
- function getAlignmentAxis(placement) {
512
- return getOppositeAxis(getSideAxis(placement));
513
- }
514
- function getAlignmentSides(placement, rects, rtl) {
515
- if (rtl === void 0) {
516
- rtl = false;
517
- }
518
- const alignment = getAlignment(placement);
519
- const alignmentAxis = getAlignmentAxis(placement);
520
- const length = getAxisLength(alignmentAxis);
521
- let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';
522
- if (rects.reference[length] > rects.floating[length]) {
523
- mainAlignmentSide = getOppositePlacement(mainAlignmentSide);
524
- }
525
- return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];
526
- }
527
- function getExpandedPlacements(placement) {
528
- const oppositePlacement = getOppositePlacement(placement);
529
- return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
530
- }
531
- function getOppositeAlignmentPlacement(placement) {
532
- return placement.replace(/start|end/g, alignment => oppositeAlignmentMap[alignment]);
533
- }
534
- const lrPlacement = ['left', 'right'];
535
- const rlPlacement = ['right', 'left'];
536
- const tbPlacement = ['top', 'bottom'];
537
- const btPlacement = ['bottom', 'top'];
538
- function getSideList(side, isStart, rtl) {
539
- switch (side) {
540
- case 'top':
541
- case 'bottom':
542
- if (rtl) return isStart ? rlPlacement : lrPlacement;
543
- return isStart ? lrPlacement : rlPlacement;
544
- case 'left':
545
- case 'right':
546
- return isStart ? tbPlacement : btPlacement;
547
- default:
548
- return [];
549
- }
550
- }
551
- function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
552
- const alignment = getAlignment(placement);
553
- let list = getSideList(getSide(placement), direction === 'start', rtl);
554
- if (alignment) {
555
- list = list.map(side => side + "-" + alignment);
556
- if (flipAlignment) {
557
- list = list.concat(list.map(getOppositeAlignmentPlacement));
558
- }
559
- }
560
- return list;
561
- }
562
- function getOppositePlacement(placement) {
563
- return placement.replace(/left|right|bottom|top/g, side => oppositeSideMap[side]);
564
- }
565
- function expandPaddingObject(padding) {
566
- return {
567
- top: 0,
568
- right: 0,
569
- bottom: 0,
570
- left: 0,
571
- ...padding
572
- };
573
- }
574
- function getPaddingObject(padding) {
575
- return typeof padding !== 'number' ? expandPaddingObject(padding) : {
576
- top: padding,
577
- right: padding,
578
- bottom: padding,
579
- left: padding
580
- };
581
- }
582
- function rectToClientRect(rect) {
583
- const {
584
- x,
585
- y,
586
- width,
587
- height
588
- } = rect;
589
- return {
590
- width,
591
- height,
592
- top: y,
593
- left: x,
594
- right: x + width,
595
- bottom: y + height,
596
- x,
597
- y
598
- };
599
- }
600
-
601
- function computeCoordsFromPlacement(_ref, placement, rtl) {
602
- let {
603
- reference,
604
- floating
605
- } = _ref;
606
- const sideAxis = getSideAxis(placement);
607
- const alignmentAxis = getAlignmentAxis(placement);
608
- const alignLength = getAxisLength(alignmentAxis);
609
- const side = getSide(placement);
610
- const isVertical = sideAxis === 'y';
611
- const commonX = reference.x + reference.width / 2 - floating.width / 2;
612
- const commonY = reference.y + reference.height / 2 - floating.height / 2;
613
- const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;
614
- let coords;
615
- switch (side) {
616
- case 'top':
617
- coords = {
618
- x: commonX,
619
- y: reference.y - floating.height
620
- };
621
- break;
622
- case 'bottom':
623
- coords = {
624
- x: commonX,
625
- y: reference.y + reference.height
626
- };
627
- break;
628
- case 'right':
629
- coords = {
630
- x: reference.x + reference.width,
631
- y: commonY
632
- };
633
- break;
634
- case 'left':
635
- coords = {
636
- x: reference.x - floating.width,
637
- y: commonY
638
- };
639
- break;
640
- default:
641
- coords = {
642
- x: reference.x,
643
- y: reference.y
644
- };
645
- }
646
- switch (getAlignment(placement)) {
647
- case 'start':
648
- coords[alignmentAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);
649
- break;
650
- case 'end':
651
- coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);
652
- break;
653
- }
654
- return coords;
655
- }
656
-
657
- /**
658
- * Computes the `x` and `y` coordinates that will place the floating element
659
- * next to a given reference element.
660
- *
661
- * This export does not have any `platform` interface logic. You will need to
662
- * write one for the platform you are using Floating UI with.
663
- */
664
- const computePosition$1 = async (reference, floating, config) => {
665
- const {
666
- placement = 'bottom',
667
- strategy = 'absolute',
668
- middleware = [],
669
- platform
670
- } = config;
671
- const validMiddleware = middleware.filter(Boolean);
672
- const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(floating));
673
- let rects = await platform.getElementRects({
674
- reference,
675
- floating,
676
- strategy
677
- });
678
- let {
679
- x,
680
- y
681
- } = computeCoordsFromPlacement(rects, placement, rtl);
682
- let statefulPlacement = placement;
683
- let middlewareData = {};
684
- let resetCount = 0;
685
- for (let i = 0; i < validMiddleware.length; i++) {
686
- const {
687
- name,
688
- fn
689
- } = validMiddleware[i];
690
- const {
691
- x: nextX,
692
- y: nextY,
693
- data,
694
- reset
695
- } = await fn({
696
- x,
697
- y,
698
- initialPlacement: placement,
699
- placement: statefulPlacement,
700
- strategy,
701
- middlewareData,
702
- rects,
703
- platform,
704
- elements: {
705
- reference,
706
- floating
707
- }
708
- });
709
- x = nextX != null ? nextX : x;
710
- y = nextY != null ? nextY : y;
711
- middlewareData = {
712
- ...middlewareData,
713
- [name]: {
714
- ...middlewareData[name],
715
- ...data
716
- }
717
- };
718
- if (reset && resetCount <= 50) {
719
- resetCount++;
720
- if (typeof reset === 'object') {
721
- if (reset.placement) {
722
- statefulPlacement = reset.placement;
723
- }
724
- if (reset.rects) {
725
- rects = reset.rects === true ? await platform.getElementRects({
726
- reference,
727
- floating,
728
- strategy
729
- }) : reset.rects;
730
- }
731
- ({
732
- x,
733
- y
734
- } = computeCoordsFromPlacement(rects, statefulPlacement, rtl));
735
- }
736
- i = -1;
737
- }
738
- }
739
- return {
740
- x,
741
- y,
742
- placement: statefulPlacement,
743
- strategy,
744
- middlewareData
745
- };
746
- };
747
-
748
- /**
749
- * Resolves with an object of overflow side offsets that determine how much the
750
- * element is overflowing a given clipping boundary on each side.
751
- * - positive = overflowing the boundary by that number of pixels
752
- * - negative = how many pixels left before it will overflow
753
- * - 0 = lies flush with the boundary
754
- * @see https://floating-ui.com/docs/detectOverflow
755
- */
756
- async function detectOverflow(state, options) {
757
- var _await$platform$isEle;
758
- if (options === void 0) {
759
- options = {};
760
- }
761
- const {
762
- x,
763
- y,
764
- platform,
765
- rects,
766
- elements,
767
- strategy
768
- } = state;
769
- const {
770
- boundary = 'clippingAncestors',
771
- rootBoundary = 'viewport',
772
- elementContext = 'floating',
773
- altBoundary = false,
774
- padding = 0
775
- } = evaluate(options, state);
776
- const paddingObject = getPaddingObject(padding);
777
- const altContext = elementContext === 'floating' ? 'reference' : 'floating';
778
- const element = elements[altBoundary ? altContext : elementContext];
779
- const clippingClientRect = rectToClientRect(await platform.getClippingRect({
780
- element: ((_await$platform$isEle = await (platform.isElement == null ? void 0 : platform.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || (await (platform.getDocumentElement == null ? void 0 : platform.getDocumentElement(elements.floating))),
781
- boundary,
782
- rootBoundary,
783
- strategy
784
- }));
785
- const rect = elementContext === 'floating' ? {
786
- x,
787
- y,
788
- width: rects.floating.width,
789
- height: rects.floating.height
790
- } : rects.reference;
791
- const offsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(elements.floating));
792
- const offsetScale = (await (platform.isElement == null ? void 0 : platform.isElement(offsetParent))) ? (await (platform.getScale == null ? void 0 : platform.getScale(offsetParent))) || {
793
- x: 1,
794
- y: 1
795
- } : {
796
- x: 1,
797
- y: 1
798
- };
799
- const elementClientRect = rectToClientRect(platform.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform.convertOffsetParentRelativeRectToViewportRelativeRect({
800
- elements,
801
- rect,
802
- offsetParent,
803
- strategy
804
- }) : rect);
805
- return {
806
- top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,
807
- bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,
808
- left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,
809
- right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x
810
- };
811
- }
812
-
813
- /**
814
- * Provides data to position an inner element of the floating element so that it
815
- * appears centered to the reference element.
816
- * @see https://floating-ui.com/docs/arrow
817
- */
818
- const arrow$3 = options => ({
819
- name: 'arrow',
820
- options,
821
- async fn(state) {
822
- const {
823
- x,
824
- y,
825
- placement,
826
- rects,
827
- platform,
828
- elements,
829
- middlewareData
830
- } = state;
831
- // Since `element` is required, we don't Partial<> the type.
832
- const {
833
- element,
834
- padding = 0
835
- } = evaluate(options, state) || {};
836
- if (element == null) {
837
- return {};
838
- }
839
- const paddingObject = getPaddingObject(padding);
840
- const coords = {
841
- x,
842
- y
843
- };
844
- const axis = getAlignmentAxis(placement);
845
- const length = getAxisLength(axis);
846
- const arrowDimensions = await platform.getDimensions(element);
847
- const isYAxis = axis === 'y';
848
- const minProp = isYAxis ? 'top' : 'left';
849
- const maxProp = isYAxis ? 'bottom' : 'right';
850
- const clientProp = isYAxis ? 'clientHeight' : 'clientWidth';
851
- const endDiff = rects.reference[length] + rects.reference[axis] - coords[axis] - rects.floating[length];
852
- const startDiff = coords[axis] - rects.reference[axis];
853
- const arrowOffsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(element));
854
- let clientSize = arrowOffsetParent ? arrowOffsetParent[clientProp] : 0;
855
-
856
- // DOM platform can return `window` as the `offsetParent`.
857
- if (!clientSize || !(await (platform.isElement == null ? void 0 : platform.isElement(arrowOffsetParent)))) {
858
- clientSize = elements.floating[clientProp] || rects.floating[length];
859
- }
860
- const centerToReference = endDiff / 2 - startDiff / 2;
861
-
862
- // If the padding is large enough that it causes the arrow to no longer be
863
- // centered, modify the padding so that it is centered.
864
- const largestPossiblePadding = clientSize / 2 - arrowDimensions[length] / 2 - 1;
865
- const minPadding = min(paddingObject[minProp], largestPossiblePadding);
866
- const maxPadding = min(paddingObject[maxProp], largestPossiblePadding);
867
-
868
- // Make sure the arrow doesn't overflow the floating element if the center
869
- // point is outside the floating element's bounds.
870
- const min$1 = minPadding;
871
- const max = clientSize - arrowDimensions[length] - maxPadding;
872
- const center = clientSize / 2 - arrowDimensions[length] / 2 + centerToReference;
873
- const offset = clamp(min$1, center, max);
874
-
875
- // If the reference is small enough that the arrow's padding causes it to
876
- // to point to nothing for an aligned placement, adjust the offset of the
877
- // floating element itself. To ensure `shift()` continues to take action,
878
- // a single reset is performed when this is true.
879
- const shouldAddOffset = !middlewareData.arrow && getAlignment(placement) != null && center !== offset && rects.reference[length] / 2 - (center < min$1 ? minPadding : maxPadding) - arrowDimensions[length] / 2 < 0;
880
- const alignmentOffset = shouldAddOffset ? center < min$1 ? center - min$1 : center - max : 0;
881
- return {
882
- [axis]: coords[axis] + alignmentOffset,
883
- data: {
884
- [axis]: offset,
885
- centerOffset: center - offset - alignmentOffset,
886
- ...(shouldAddOffset && {
887
- alignmentOffset
888
- })
889
- },
890
- reset: shouldAddOffset
891
- };
892
- }
893
- });
894
-
895
- /**
896
- * Optimizes the visibility of the floating element by flipping the `placement`
897
- * in order to keep it in view when the preferred placement(s) will overflow the
898
- * clipping boundary. Alternative to `autoPlacement`.
899
- * @see https://floating-ui.com/docs/flip
900
- */
901
- const flip$2 = function (options) {
902
- if (options === void 0) {
903
- options = {};
904
- }
905
- return {
906
- name: 'flip',
907
- options,
908
- async fn(state) {
909
- var _middlewareData$arrow, _middlewareData$flip;
910
- const {
911
- placement,
912
- middlewareData,
913
- rects,
914
- initialPlacement,
915
- platform,
916
- elements
917
- } = state;
918
- const {
919
- mainAxis: checkMainAxis = true,
920
- crossAxis: checkCrossAxis = true,
921
- fallbackPlacements: specifiedFallbackPlacements,
922
- fallbackStrategy = 'bestFit',
923
- fallbackAxisSideDirection = 'none',
924
- flipAlignment = true,
925
- ...detectOverflowOptions
926
- } = evaluate(options, state);
927
-
928
- // If a reset by the arrow was caused due to an alignment offset being
929
- // added, we should skip any logic now since `flip()` has already done its
930
- // work.
931
- // https://github.com/floating-ui/floating-ui/issues/2549#issuecomment-1719601643
932
- if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
933
- return {};
934
- }
935
- const side = getSide(placement);
936
- const initialSideAxis = getSideAxis(initialPlacement);
937
- const isBasePlacement = getSide(initialPlacement) === initialPlacement;
938
- const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
939
- const fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipAlignment ? [getOppositePlacement(initialPlacement)] : getExpandedPlacements(initialPlacement));
940
- const hasFallbackAxisSideDirection = fallbackAxisSideDirection !== 'none';
941
- if (!specifiedFallbackPlacements && hasFallbackAxisSideDirection) {
942
- fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));
943
- }
944
- const placements = [initialPlacement, ...fallbackPlacements];
945
- const overflow = await detectOverflow(state, detectOverflowOptions);
946
- const overflows = [];
947
- let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];
948
- if (checkMainAxis) {
949
- overflows.push(overflow[side]);
950
- }
951
- if (checkCrossAxis) {
952
- const sides = getAlignmentSides(placement, rects, rtl);
953
- overflows.push(overflow[sides[0]], overflow[sides[1]]);
954
- }
955
- overflowsData = [...overflowsData, {
956
- placement,
957
- overflows
958
- }];
959
-
960
- // One or more sides is overflowing.
961
- if (!overflows.every(side => side <= 0)) {
962
- var _middlewareData$flip2, _overflowsData$filter;
963
- const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
964
- const nextPlacement = placements[nextIndex];
965
- if (nextPlacement) {
966
- const ignoreCrossAxisOverflow = checkCrossAxis === 'alignment' ? initialSideAxis !== getSideAxis(nextPlacement) : false;
967
- if (!ignoreCrossAxisOverflow ||
968
- // We leave the current main axis only if every placement on that axis
969
- // overflows the main axis.
970
- overflowsData.every(d => getSideAxis(d.placement) === initialSideAxis ? d.overflows[0] > 0 : true)) {
971
- // Try next placement and re-run the lifecycle.
972
- return {
973
- data: {
974
- index: nextIndex,
975
- overflows: overflowsData
976
- },
977
- reset: {
978
- placement: nextPlacement
979
- }
980
- };
981
- }
982
- }
983
-
984
- // First, find the candidates that fit on the mainAxis side of overflow,
985
- // then find the placement that fits the best on the main crossAxis side.
986
- let resetPlacement = (_overflowsData$filter = overflowsData.filter(d => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
987
-
988
- // Otherwise fallback.
989
- if (!resetPlacement) {
990
- switch (fallbackStrategy) {
991
- case 'bestFit':
992
- {
993
- var _overflowsData$filter2;
994
- const placement = (_overflowsData$filter2 = overflowsData.filter(d => {
995
- if (hasFallbackAxisSideDirection) {
996
- const currentSideAxis = getSideAxis(d.placement);
997
- return currentSideAxis === initialSideAxis ||
998
- // Create a bias to the `y` side axis due to horizontal
999
- // reading directions favoring greater width.
1000
- currentSideAxis === 'y';
1001
- }
1002
- return true;
1003
- }).map(d => [d.placement, d.overflows.filter(overflow => overflow > 0).reduce((acc, overflow) => acc + overflow, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$filter2[0];
1004
- if (placement) {
1005
- resetPlacement = placement;
1006
- }
1007
- break;
1008
- }
1009
- case 'initialPlacement':
1010
- resetPlacement = initialPlacement;
1011
- break;
1012
- }
1013
- }
1014
- if (placement !== resetPlacement) {
1015
- return {
1016
- reset: {
1017
- placement: resetPlacement
1018
- }
1019
- };
1020
- }
1021
- }
1022
- return {};
1023
- }
1024
- };
1025
- };
1026
-
1027
- function getSideOffsets(overflow, rect) {
1028
- return {
1029
- top: overflow.top - rect.height,
1030
- right: overflow.right - rect.width,
1031
- bottom: overflow.bottom - rect.height,
1032
- left: overflow.left - rect.width
1033
- };
1034
- }
1035
- function isAnySideFullyClipped(overflow) {
1036
- return sides.some(side => overflow[side] >= 0);
1037
- }
1038
- /**
1039
- * Provides data to hide the floating element in applicable situations, such as
1040
- * when it is not in the same clipping context as the reference element.
1041
- * @see https://floating-ui.com/docs/hide
1042
- */
1043
- const hide$2 = function (options) {
1044
- if (options === void 0) {
1045
- options = {};
1046
- }
1047
- return {
1048
- name: 'hide',
1049
- options,
1050
- async fn(state) {
1051
- const {
1052
- rects
1053
- } = state;
1054
- const {
1055
- strategy = 'referenceHidden',
1056
- ...detectOverflowOptions
1057
- } = evaluate(options, state);
1058
- switch (strategy) {
1059
- case 'referenceHidden':
1060
- {
1061
- const overflow = await detectOverflow(state, {
1062
- ...detectOverflowOptions,
1063
- elementContext: 'reference'
1064
- });
1065
- const offsets = getSideOffsets(overflow, rects.reference);
1066
- return {
1067
- data: {
1068
- referenceHiddenOffsets: offsets,
1069
- referenceHidden: isAnySideFullyClipped(offsets)
1070
- }
1071
- };
1072
- }
1073
- case 'escaped':
1074
- {
1075
- const overflow = await detectOverflow(state, {
1076
- ...detectOverflowOptions,
1077
- altBoundary: true
1078
- });
1079
- const offsets = getSideOffsets(overflow, rects.floating);
1080
- return {
1081
- data: {
1082
- escapedOffsets: offsets,
1083
- escaped: isAnySideFullyClipped(offsets)
1084
- }
1085
- };
1086
- }
1087
- default:
1088
- {
1089
- return {};
1090
- }
1091
- }
1092
- }
1093
- };
1094
- };
1095
-
1096
- const originSides = /*#__PURE__*/new Set(['left', 'top']);
1097
-
1098
- // For type backwards-compatibility, the `OffsetOptions` type was also
1099
- // Derivable.
1100
-
1101
- async function convertValueToCoords(state, options) {
1102
- const {
1103
- placement,
1104
- platform,
1105
- elements
1106
- } = state;
1107
- const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
1108
- const side = getSide(placement);
1109
- const alignment = getAlignment(placement);
1110
- const isVertical = getSideAxis(placement) === 'y';
1111
- const mainAxisMulti = originSides.has(side) ? -1 : 1;
1112
- const crossAxisMulti = rtl && isVertical ? -1 : 1;
1113
- const rawValue = evaluate(options, state);
1114
-
1115
- // eslint-disable-next-line prefer-const
1116
- let {
1117
- mainAxis,
1118
- crossAxis,
1119
- alignmentAxis
1120
- } = typeof rawValue === 'number' ? {
1121
- mainAxis: rawValue,
1122
- crossAxis: 0,
1123
- alignmentAxis: null
1124
- } : {
1125
- mainAxis: rawValue.mainAxis || 0,
1126
- crossAxis: rawValue.crossAxis || 0,
1127
- alignmentAxis: rawValue.alignmentAxis
1128
- };
1129
- if (alignment && typeof alignmentAxis === 'number') {
1130
- crossAxis = alignment === 'end' ? alignmentAxis * -1 : alignmentAxis;
1131
- }
1132
- return isVertical ? {
1133
- x: crossAxis * crossAxisMulti,
1134
- y: mainAxis * mainAxisMulti
1135
- } : {
1136
- x: mainAxis * mainAxisMulti,
1137
- y: crossAxis * crossAxisMulti
1138
- };
1139
- }
1140
-
1141
- /**
1142
- * Modifies the placement by translating the floating element along the
1143
- * specified axes.
1144
- * A number (shorthand for `mainAxis` or distance), or an axes configuration
1145
- * object may be passed.
1146
- * @see https://floating-ui.com/docs/offset
1147
- */
1148
- const offset$2 = function (options) {
1149
- if (options === void 0) {
1150
- options = 0;
1151
- }
1152
- return {
1153
- name: 'offset',
1154
- options,
1155
- async fn(state) {
1156
- var _middlewareData$offse, _middlewareData$arrow;
1157
- const {
1158
- x,
1159
- y,
1160
- placement,
1161
- middlewareData
1162
- } = state;
1163
- const diffCoords = await convertValueToCoords(state, options);
1164
-
1165
- // If the placement is the same and the arrow caused an alignment offset
1166
- // then we don't need to change the positioning coordinates.
1167
- if (placement === ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse.placement) && (_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
1168
- return {};
1169
- }
1170
- return {
1171
- x: x + diffCoords.x,
1172
- y: y + diffCoords.y,
1173
- data: {
1174
- ...diffCoords,
1175
- placement
1176
- }
1177
- };
1178
- }
1179
- };
1180
- };
1181
-
1182
- /**
1183
- * Optimizes the visibility of the floating element by shifting it in order to
1184
- * keep it in view when it will overflow the clipping boundary.
1185
- * @see https://floating-ui.com/docs/shift
1186
- */
1187
- const shift$2 = function (options) {
1188
- if (options === void 0) {
1189
- options = {};
1190
- }
1191
- return {
1192
- name: 'shift',
1193
- options,
1194
- async fn(state) {
1195
- const {
1196
- x,
1197
- y,
1198
- placement
1199
- } = state;
1200
- const {
1201
- mainAxis: checkMainAxis = true,
1202
- crossAxis: checkCrossAxis = false,
1203
- limiter = {
1204
- fn: _ref => {
1205
- let {
1206
- x,
1207
- y
1208
- } = _ref;
1209
- return {
1210
- x,
1211
- y
1212
- };
1213
- }
1214
- },
1215
- ...detectOverflowOptions
1216
- } = evaluate(options, state);
1217
- const coords = {
1218
- x,
1219
- y
1220
- };
1221
- const overflow = await detectOverflow(state, detectOverflowOptions);
1222
- const crossAxis = getSideAxis(getSide(placement));
1223
- const mainAxis = getOppositeAxis(crossAxis);
1224
- let mainAxisCoord = coords[mainAxis];
1225
- let crossAxisCoord = coords[crossAxis];
1226
- if (checkMainAxis) {
1227
- const minSide = mainAxis === 'y' ? 'top' : 'left';
1228
- const maxSide = mainAxis === 'y' ? 'bottom' : 'right';
1229
- const min = mainAxisCoord + overflow[minSide];
1230
- const max = mainAxisCoord - overflow[maxSide];
1231
- mainAxisCoord = clamp(min, mainAxisCoord, max);
1232
- }
1233
- if (checkCrossAxis) {
1234
- const minSide = crossAxis === 'y' ? 'top' : 'left';
1235
- const maxSide = crossAxis === 'y' ? 'bottom' : 'right';
1236
- const min = crossAxisCoord + overflow[minSide];
1237
- const max = crossAxisCoord - overflow[maxSide];
1238
- crossAxisCoord = clamp(min, crossAxisCoord, max);
1239
- }
1240
- const limitedCoords = limiter.fn({
1241
- ...state,
1242
- [mainAxis]: mainAxisCoord,
1243
- [crossAxis]: crossAxisCoord
1244
- });
1245
- return {
1246
- ...limitedCoords,
1247
- data: {
1248
- x: limitedCoords.x - x,
1249
- y: limitedCoords.y - y,
1250
- enabled: {
1251
- [mainAxis]: checkMainAxis,
1252
- [crossAxis]: checkCrossAxis
1253
- }
1254
- }
1255
- };
1256
- }
1257
- };
1258
- };
1259
- /**
1260
- * Built-in `limiter` that will stop `shift()` at a certain point.
1261
- */
1262
- const limitShift$2 = function (options) {
1263
- if (options === void 0) {
1264
- options = {};
1265
- }
1266
- return {
1267
- options,
1268
- fn(state) {
1269
- const {
1270
- x,
1271
- y,
1272
- placement,
1273
- rects,
1274
- middlewareData
1275
- } = state;
1276
- const {
1277
- offset = 0,
1278
- mainAxis: checkMainAxis = true,
1279
- crossAxis: checkCrossAxis = true
1280
- } = evaluate(options, state);
1281
- const coords = {
1282
- x,
1283
- y
1284
- };
1285
- const crossAxis = getSideAxis(placement);
1286
- const mainAxis = getOppositeAxis(crossAxis);
1287
- let mainAxisCoord = coords[mainAxis];
1288
- let crossAxisCoord = coords[crossAxis];
1289
- const rawOffset = evaluate(offset, state);
1290
- const computedOffset = typeof rawOffset === 'number' ? {
1291
- mainAxis: rawOffset,
1292
- crossAxis: 0
1293
- } : {
1294
- mainAxis: 0,
1295
- crossAxis: 0,
1296
- ...rawOffset
1297
- };
1298
- if (checkMainAxis) {
1299
- const len = mainAxis === 'y' ? 'height' : 'width';
1300
- const limitMin = rects.reference[mainAxis] - rects.floating[len] + computedOffset.mainAxis;
1301
- const limitMax = rects.reference[mainAxis] + rects.reference[len] - computedOffset.mainAxis;
1302
- if (mainAxisCoord < limitMin) {
1303
- mainAxisCoord = limitMin;
1304
- } else if (mainAxisCoord > limitMax) {
1305
- mainAxisCoord = limitMax;
1306
- }
1307
- }
1308
- if (checkCrossAxis) {
1309
- var _middlewareData$offse, _middlewareData$offse2;
1310
- const len = mainAxis === 'y' ? 'width' : 'height';
1311
- const isOriginSide = originSides.has(getSide(placement));
1312
- const limitMin = rects.reference[crossAxis] - rects.floating[len] + (isOriginSide ? ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse[crossAxis]) || 0 : 0) + (isOriginSide ? 0 : computedOffset.crossAxis);
1313
- const limitMax = rects.reference[crossAxis] + rects.reference[len] + (isOriginSide ? 0 : ((_middlewareData$offse2 = middlewareData.offset) == null ? void 0 : _middlewareData$offse2[crossAxis]) || 0) - (isOriginSide ? computedOffset.crossAxis : 0);
1314
- if (crossAxisCoord < limitMin) {
1315
- crossAxisCoord = limitMin;
1316
- } else if (crossAxisCoord > limitMax) {
1317
- crossAxisCoord = limitMax;
1318
- }
1319
- }
1320
- return {
1321
- [mainAxis]: mainAxisCoord,
1322
- [crossAxis]: crossAxisCoord
1323
- };
1324
- }
1325
- };
1326
- };
1327
-
1328
- /**
1329
- * Provides data that allows you to change the size of the floating element —
1330
- * for instance, prevent it from overflowing the clipping boundary or match the
1331
- * width of the reference element.
1332
- * @see https://floating-ui.com/docs/size
1333
- */
1334
- const size$2 = function (options) {
1335
- if (options === void 0) {
1336
- options = {};
1337
- }
1338
- return {
1339
- name: 'size',
1340
- options,
1341
- async fn(state) {
1342
- var _state$middlewareData, _state$middlewareData2;
1343
- const {
1344
- placement,
1345
- rects,
1346
- platform,
1347
- elements
1348
- } = state;
1349
- const {
1350
- apply = () => {},
1351
- ...detectOverflowOptions
1352
- } = evaluate(options, state);
1353
- const overflow = await detectOverflow(state, detectOverflowOptions);
1354
- const side = getSide(placement);
1355
- const alignment = getAlignment(placement);
1356
- const isYAxis = getSideAxis(placement) === 'y';
1357
- const {
1358
- width,
1359
- height
1360
- } = rects.floating;
1361
- let heightSide;
1362
- let widthSide;
1363
- if (side === 'top' || side === 'bottom') {
1364
- heightSide = side;
1365
- widthSide = alignment === ((await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating))) ? 'start' : 'end') ? 'left' : 'right';
1366
- } else {
1367
- widthSide = side;
1368
- heightSide = alignment === 'end' ? 'top' : 'bottom';
1369
- }
1370
- const maximumClippingHeight = height - overflow.top - overflow.bottom;
1371
- const maximumClippingWidth = width - overflow.left - overflow.right;
1372
- const overflowAvailableHeight = min(height - overflow[heightSide], maximumClippingHeight);
1373
- const overflowAvailableWidth = min(width - overflow[widthSide], maximumClippingWidth);
1374
- const noShift = !state.middlewareData.shift;
1375
- let availableHeight = overflowAvailableHeight;
1376
- let availableWidth = overflowAvailableWidth;
1377
- if ((_state$middlewareData = state.middlewareData.shift) != null && _state$middlewareData.enabled.x) {
1378
- availableWidth = maximumClippingWidth;
1379
- }
1380
- if ((_state$middlewareData2 = state.middlewareData.shift) != null && _state$middlewareData2.enabled.y) {
1381
- availableHeight = maximumClippingHeight;
1382
- }
1383
- if (noShift && !alignment) {
1384
- const xMin = max(overflow.left, 0);
1385
- const xMax = max(overflow.right, 0);
1386
- const yMin = max(overflow.top, 0);
1387
- const yMax = max(overflow.bottom, 0);
1388
- if (isYAxis) {
1389
- availableWidth = width - 2 * (xMin !== 0 || xMax !== 0 ? xMin + xMax : max(overflow.left, overflow.right));
1390
- } else {
1391
- availableHeight = height - 2 * (yMin !== 0 || yMax !== 0 ? yMin + yMax : max(overflow.top, overflow.bottom));
1392
- }
1393
- }
1394
- await apply({
1395
- ...state,
1396
- availableWidth,
1397
- availableHeight
1398
- });
1399
- const nextDimensions = await platform.getDimensions(elements.floating);
1400
- if (width !== nextDimensions.width || height !== nextDimensions.height) {
1401
- return {
1402
- reset: {
1403
- rects: true
1404
- }
1405
- };
1406
- }
1407
- return {};
1408
- }
1409
- };
1410
- };
1411
-
1412
- function hasWindow() {
1413
- return typeof window !== 'undefined';
1414
- }
1415
- function getNodeName(node) {
1416
- if (isNode(node)) {
1417
- return (node.nodeName || '').toLowerCase();
1418
- }
1419
- // Mocked nodes in testing environments may not be instances of Node. By
1420
- // returning `#document` an infinite loop won't occur.
1421
- // https://github.com/floating-ui/floating-ui/issues/2317
1422
- return '#document';
1423
- }
1424
- function getWindow(node) {
1425
- var _node$ownerDocument;
1426
- return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
1427
- }
1428
- function getDocumentElement(node) {
1429
- var _ref;
1430
- return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
1431
- }
1432
- function isNode(value) {
1433
- if (!hasWindow()) {
1434
- return false;
1435
- }
1436
- return value instanceof Node || value instanceof getWindow(value).Node;
1437
- }
1438
- function isElement(value) {
1439
- if (!hasWindow()) {
1440
- return false;
1441
- }
1442
- return value instanceof Element || value instanceof getWindow(value).Element;
1443
- }
1444
- function isHTMLElement(value) {
1445
- if (!hasWindow()) {
1446
- return false;
1447
- }
1448
- return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;
1449
- }
1450
- function isShadowRoot(value) {
1451
- if (!hasWindow() || typeof ShadowRoot === 'undefined') {
1452
- return false;
1453
- }
1454
- return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
1455
- }
1456
- const invalidOverflowDisplayValues = /*#__PURE__*/new Set(['inline', 'contents']);
1457
- function isOverflowElement(element) {
1458
- const {
1459
- overflow,
1460
- overflowX,
1461
- overflowY,
1462
- display
1463
- } = getComputedStyle$1(element);
1464
- return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && !invalidOverflowDisplayValues.has(display);
1465
- }
1466
- const tableElements = /*#__PURE__*/new Set(['table', 'td', 'th']);
1467
- function isTableElement(element) {
1468
- return tableElements.has(getNodeName(element));
1469
- }
1470
- const topLayerSelectors = [':popover-open', ':modal'];
1471
- function isTopLayer(element) {
1472
- return topLayerSelectors.some(selector => {
1473
- try {
1474
- return element.matches(selector);
1475
- } catch (_e) {
1476
- return false;
1477
- }
1478
- });
1479
- }
1480
- const transformProperties = ['transform', 'translate', 'scale', 'rotate', 'perspective'];
1481
- const willChangeValues = ['transform', 'translate', 'scale', 'rotate', 'perspective', 'filter'];
1482
- const containValues = ['paint', 'layout', 'strict', 'content'];
1483
- function isContainingBlock(elementOrCss) {
1484
- const webkit = isWebKit();
1485
- const css = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
1486
-
1487
- // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
1488
- // https://drafts.csswg.org/css-transforms-2/#individual-transforms
1489
- return transformProperties.some(value => css[value] ? css[value] !== 'none' : false) || (css.containerType ? css.containerType !== 'normal' : false) || !webkit && (css.backdropFilter ? css.backdropFilter !== 'none' : false) || !webkit && (css.filter ? css.filter !== 'none' : false) || willChangeValues.some(value => (css.willChange || '').includes(value)) || containValues.some(value => (css.contain || '').includes(value));
1490
- }
1491
- function getContainingBlock(element) {
1492
- let currentNode = getParentNode(element);
1493
- while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
1494
- if (isContainingBlock(currentNode)) {
1495
- return currentNode;
1496
- } else if (isTopLayer(currentNode)) {
1497
- return null;
1498
- }
1499
- currentNode = getParentNode(currentNode);
1500
- }
1501
- return null;
1502
- }
1503
- function isWebKit() {
1504
- if (typeof CSS === 'undefined' || !CSS.supports) return false;
1505
- return CSS.supports('-webkit-backdrop-filter', 'none');
1506
- }
1507
- const lastTraversableNodeNames = /*#__PURE__*/new Set(['html', 'body', '#document']);
1508
- function isLastTraversableNode(node) {
1509
- return lastTraversableNodeNames.has(getNodeName(node));
1510
- }
1511
- function getComputedStyle$1(element) {
1512
- return getWindow(element).getComputedStyle(element);
1513
- }
1514
- function getNodeScroll(element) {
1515
- if (isElement(element)) {
1516
- return {
1517
- scrollLeft: element.scrollLeft,
1518
- scrollTop: element.scrollTop
1519
- };
1520
- }
1521
- return {
1522
- scrollLeft: element.scrollX,
1523
- scrollTop: element.scrollY
1524
- };
1525
- }
1526
- function getParentNode(node) {
1527
- if (getNodeName(node) === 'html') {
1528
- return node;
1529
- }
1530
- const result =
1531
- // Step into the shadow DOM of the parent of a slotted node.
1532
- node.assignedSlot ||
1533
- // DOM Element detected.
1534
- node.parentNode ||
1535
- // ShadowRoot detected.
1536
- isShadowRoot(node) && node.host ||
1537
- // Fallback.
1538
- getDocumentElement(node);
1539
- return isShadowRoot(result) ? result.host : result;
1540
- }
1541
- function getNearestOverflowAncestor(node) {
1542
- const parentNode = getParentNode(node);
1543
- if (isLastTraversableNode(parentNode)) {
1544
- return node.ownerDocument ? node.ownerDocument.body : node.body;
1545
- }
1546
- if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
1547
- return parentNode;
1548
- }
1549
- return getNearestOverflowAncestor(parentNode);
1550
- }
1551
- function getOverflowAncestors(node, list, traverseIframes) {
1552
- var _node$ownerDocument2;
1553
- if (list === void 0) {
1554
- list = [];
1555
- }
1556
- if (traverseIframes === void 0) {
1557
- traverseIframes = true;
1558
- }
1559
- const scrollableAncestor = getNearestOverflowAncestor(node);
1560
- const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
1561
- const win = getWindow(scrollableAncestor);
1562
- if (isBody) {
1563
- const frameElement = getFrameElement(win);
1564
- return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
1565
- }
1566
- return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
1567
- }
1568
- function getFrameElement(win) {
1569
- return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
1570
- }
1571
-
1572
- function getCssDimensions(element) {
1573
- const css = getComputedStyle$1(element);
1574
- // In testing environments, the `width` and `height` properties are empty
1575
- // strings for SVG elements, returning NaN. Fallback to `0` in this case.
1576
- let width = parseFloat(css.width) || 0;
1577
- let height = parseFloat(css.height) || 0;
1578
- const hasOffset = isHTMLElement(element);
1579
- const offsetWidth = hasOffset ? element.offsetWidth : width;
1580
- const offsetHeight = hasOffset ? element.offsetHeight : height;
1581
- const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;
1582
- if (shouldFallback) {
1583
- width = offsetWidth;
1584
- height = offsetHeight;
1585
- }
1586
- return {
1587
- width,
1588
- height,
1589
- $: shouldFallback
1590
- };
1591
- }
1592
-
1593
- function unwrapElement(element) {
1594
- return !isElement(element) ? element.contextElement : element;
1595
- }
1596
-
1597
- function getScale(element) {
1598
- const domElement = unwrapElement(element);
1599
- if (!isHTMLElement(domElement)) {
1600
- return createCoords(1);
1601
- }
1602
- const rect = domElement.getBoundingClientRect();
1603
- const {
1604
- width,
1605
- height,
1606
- $
1607
- } = getCssDimensions(domElement);
1608
- let x = ($ ? round(rect.width) : rect.width) / width;
1609
- let y = ($ ? round(rect.height) : rect.height) / height;
1610
-
1611
- // 0, NaN, or Infinity should always fallback to 1.
1612
-
1613
- if (!x || !Number.isFinite(x)) {
1614
- x = 1;
1615
- }
1616
- if (!y || !Number.isFinite(y)) {
1617
- y = 1;
1618
- }
1619
- return {
1620
- x,
1621
- y
1622
- };
1623
- }
1624
-
1625
- const noOffsets = /*#__PURE__*/createCoords(0);
1626
- function getVisualOffsets(element) {
1627
- const win = getWindow(element);
1628
- if (!isWebKit() || !win.visualViewport) {
1629
- return noOffsets;
1630
- }
1631
- return {
1632
- x: win.visualViewport.offsetLeft,
1633
- y: win.visualViewport.offsetTop
1634
- };
1635
- }
1636
- function shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {
1637
- if (isFixed === void 0) {
1638
- isFixed = false;
1639
- }
1640
- if (!floatingOffsetParent || isFixed && floatingOffsetParent !== getWindow(element)) {
1641
- return false;
1642
- }
1643
- return isFixed;
1644
- }
1645
-
1646
- function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {
1647
- if (includeScale === void 0) {
1648
- includeScale = false;
1649
- }
1650
- if (isFixedStrategy === void 0) {
1651
- isFixedStrategy = false;
1652
- }
1653
- const clientRect = element.getBoundingClientRect();
1654
- const domElement = unwrapElement(element);
1655
- let scale = createCoords(1);
1656
- if (includeScale) {
1657
- if (offsetParent) {
1658
- if (isElement(offsetParent)) {
1659
- scale = getScale(offsetParent);
1660
- }
1661
- } else {
1662
- scale = getScale(element);
1663
- }
1664
- }
1665
- const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);
1666
- let x = (clientRect.left + visualOffsets.x) / scale.x;
1667
- let y = (clientRect.top + visualOffsets.y) / scale.y;
1668
- let width = clientRect.width / scale.x;
1669
- let height = clientRect.height / scale.y;
1670
- if (domElement) {
1671
- const win = getWindow(domElement);
1672
- const offsetWin = offsetParent && isElement(offsetParent) ? getWindow(offsetParent) : offsetParent;
1673
- let currentWin = win;
1674
- let currentIFrame = getFrameElement(currentWin);
1675
- while (currentIFrame && offsetParent && offsetWin !== currentWin) {
1676
- const iframeScale = getScale(currentIFrame);
1677
- const iframeRect = currentIFrame.getBoundingClientRect();
1678
- const css = getComputedStyle$1(currentIFrame);
1679
- const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;
1680
- const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;
1681
- x *= iframeScale.x;
1682
- y *= iframeScale.y;
1683
- width *= iframeScale.x;
1684
- height *= iframeScale.y;
1685
- x += left;
1686
- y += top;
1687
- currentWin = getWindow(currentIFrame);
1688
- currentIFrame = getFrameElement(currentWin);
1689
- }
1690
- }
1691
- return rectToClientRect({
1692
- width,
1693
- height,
1694
- x,
1695
- y
1696
- });
1697
- }
1698
-
1699
- // If <html> has a CSS width greater than the viewport, then this will be
1700
- // incorrect for RTL.
1701
- function getWindowScrollBarX(element, rect) {
1702
- const leftScroll = getNodeScroll(element).scrollLeft;
1703
- if (!rect) {
1704
- return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;
1705
- }
1706
- return rect.left + leftScroll;
1707
- }
1708
-
1709
- function getHTMLOffset(documentElement, scroll) {
1710
- const htmlRect = documentElement.getBoundingClientRect();
1711
- const x = htmlRect.left + scroll.scrollLeft - getWindowScrollBarX(documentElement, htmlRect);
1712
- const y = htmlRect.top + scroll.scrollTop;
1713
- return {
1714
- x,
1715
- y
1716
- };
1717
- }
1718
-
1719
- function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
1720
- let {
1721
- elements,
1722
- rect,
1723
- offsetParent,
1724
- strategy
1725
- } = _ref;
1726
- const isFixed = strategy === 'fixed';
1727
- const documentElement = getDocumentElement(offsetParent);
1728
- const topLayer = elements ? isTopLayer(elements.floating) : false;
1729
- if (offsetParent === documentElement || topLayer && isFixed) {
1730
- return rect;
1731
- }
1732
- let scroll = {
1733
- scrollLeft: 0,
1734
- scrollTop: 0
1735
- };
1736
- let scale = createCoords(1);
1737
- const offsets = createCoords(0);
1738
- const isOffsetParentAnElement = isHTMLElement(offsetParent);
1739
- if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
1740
- if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
1741
- scroll = getNodeScroll(offsetParent);
1742
- }
1743
- if (isHTMLElement(offsetParent)) {
1744
- const offsetRect = getBoundingClientRect(offsetParent);
1745
- scale = getScale(offsetParent);
1746
- offsets.x = offsetRect.x + offsetParent.clientLeft;
1747
- offsets.y = offsetRect.y + offsetParent.clientTop;
1748
- }
1749
- }
1750
- const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
1751
- return {
1752
- width: rect.width * scale.x,
1753
- height: rect.height * scale.y,
1754
- x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,
1755
- y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y
1756
- };
1757
- }
1758
-
1759
- function getClientRects(element) {
1760
- return Array.from(element.getClientRects());
1761
- }
1762
-
1763
- // Gets the entire size of the scrollable document area, even extending outside
1764
- // of the `<html>` and `<body>` rect bounds if horizontally scrollable.
1765
- function getDocumentRect(element) {
1766
- const html = getDocumentElement(element);
1767
- const scroll = getNodeScroll(element);
1768
- const body = element.ownerDocument.body;
1769
- const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
1770
- const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
1771
- let x = -scroll.scrollLeft + getWindowScrollBarX(element);
1772
- const y = -scroll.scrollTop;
1773
- if (getComputedStyle$1(body).direction === 'rtl') {
1774
- x += max(html.clientWidth, body.clientWidth) - width;
1775
- }
1776
- return {
1777
- width,
1778
- height,
1779
- x,
1780
- y
1781
- };
1782
- }
1783
-
1784
- // Safety check: ensure the scrollbar space is reasonable in case this
1785
- // calculation is affected by unusual styles.
1786
- // Most scrollbars leave 15-18px of space.
1787
- const SCROLLBAR_MAX = 25;
1788
- function getViewportRect(element, strategy) {
1789
- const win = getWindow(element);
1790
- const html = getDocumentElement(element);
1791
- const visualViewport = win.visualViewport;
1792
- let width = html.clientWidth;
1793
- let height = html.clientHeight;
1794
- let x = 0;
1795
- let y = 0;
1796
- if (visualViewport) {
1797
- width = visualViewport.width;
1798
- height = visualViewport.height;
1799
- const visualViewportBased = isWebKit();
1800
- if (!visualViewportBased || visualViewportBased && strategy === 'fixed') {
1801
- x = visualViewport.offsetLeft;
1802
- y = visualViewport.offsetTop;
1803
- }
1804
- }
1805
- const windowScrollbarX = getWindowScrollBarX(html);
1806
- // <html> `overflow: hidden` + `scrollbar-gutter: stable` reduces the
1807
- // visual width of the <html> but this is not considered in the size
1808
- // of `html.clientWidth`.
1809
- if (windowScrollbarX <= 0) {
1810
- const doc = html.ownerDocument;
1811
- const body = doc.body;
1812
- const bodyStyles = getComputedStyle(body);
1813
- const bodyMarginInline = doc.compatMode === 'CSS1Compat' ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;
1814
- const clippingStableScrollbarWidth = Math.abs(html.clientWidth - body.clientWidth - bodyMarginInline);
1815
- if (clippingStableScrollbarWidth <= SCROLLBAR_MAX) {
1816
- width -= clippingStableScrollbarWidth;
1817
- }
1818
- } else if (windowScrollbarX <= SCROLLBAR_MAX) {
1819
- // If the <body> scrollbar is on the left, the width needs to be extended
1820
- // by the scrollbar amount so there isn't extra space on the right.
1821
- width += windowScrollbarX;
1822
- }
1823
- return {
1824
- width,
1825
- height,
1826
- x,
1827
- y
1828
- };
1829
- }
1830
-
1831
- const absoluteOrFixed = /*#__PURE__*/new Set(['absolute', 'fixed']);
1832
- // Returns the inner client rect, subtracting scrollbars if present.
1833
- function getInnerBoundingClientRect(element, strategy) {
1834
- const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');
1835
- const top = clientRect.top + element.clientTop;
1836
- const left = clientRect.left + element.clientLeft;
1837
- const scale = isHTMLElement(element) ? getScale(element) : createCoords(1);
1838
- const width = element.clientWidth * scale.x;
1839
- const height = element.clientHeight * scale.y;
1840
- const x = left * scale.x;
1841
- const y = top * scale.y;
1842
- return {
1843
- width,
1844
- height,
1845
- x,
1846
- y
1847
- };
1848
- }
1849
- function getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {
1850
- let rect;
1851
- if (clippingAncestor === 'viewport') {
1852
- rect = getViewportRect(element, strategy);
1853
- } else if (clippingAncestor === 'document') {
1854
- rect = getDocumentRect(getDocumentElement(element));
1855
- } else if (isElement(clippingAncestor)) {
1856
- rect = getInnerBoundingClientRect(clippingAncestor, strategy);
1857
- } else {
1858
- const visualOffsets = getVisualOffsets(element);
1859
- rect = {
1860
- x: clippingAncestor.x - visualOffsets.x,
1861
- y: clippingAncestor.y - visualOffsets.y,
1862
- width: clippingAncestor.width,
1863
- height: clippingAncestor.height
1864
- };
1865
- }
1866
- return rectToClientRect(rect);
1867
- }
1868
- function hasFixedPositionAncestor(element, stopNode) {
1869
- const parentNode = getParentNode(element);
1870
- if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {
1871
- return false;
1872
- }
1873
- return getComputedStyle$1(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);
1874
- }
1875
-
1876
- // A "clipping ancestor" is an `overflow` element with the characteristic of
1877
- // clipping (or hiding) child elements. This returns all clipping ancestors
1878
- // of the given element up the tree.
1879
- function getClippingElementAncestors(element, cache) {
1880
- const cachedResult = cache.get(element);
1881
- if (cachedResult) {
1882
- return cachedResult;
1883
- }
1884
- let result = getOverflowAncestors(element, [], false).filter(el => isElement(el) && getNodeName(el) !== 'body');
1885
- let currentContainingBlockComputedStyle = null;
1886
- const elementIsFixed = getComputedStyle$1(element).position === 'fixed';
1887
- let currentNode = elementIsFixed ? getParentNode(element) : element;
1888
-
1889
- // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
1890
- while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {
1891
- const computedStyle = getComputedStyle$1(currentNode);
1892
- const currentNodeIsContaining = isContainingBlock(currentNode);
1893
- if (!currentNodeIsContaining && computedStyle.position === 'fixed') {
1894
- currentContainingBlockComputedStyle = null;
1895
- }
1896
- const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && absoluteOrFixed.has(currentContainingBlockComputedStyle.position) || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
1897
- if (shouldDropCurrentNode) {
1898
- // Drop non-containing blocks.
1899
- result = result.filter(ancestor => ancestor !== currentNode);
1900
- } else {
1901
- // Record last containing block for next iteration.
1902
- currentContainingBlockComputedStyle = computedStyle;
1903
- }
1904
- currentNode = getParentNode(currentNode);
1905
- }
1906
- cache.set(element, result);
1907
- return result;
1908
- }
1909
-
1910
- // Gets the maximum area that the element is visible in due to any number of
1911
- // clipping ancestors.
1912
- function getClippingRect(_ref) {
1913
- let {
1914
- element,
1915
- boundary,
1916
- rootBoundary,
1917
- strategy
1918
- } = _ref;
1919
- const elementClippingAncestors = boundary === 'clippingAncestors' ? isTopLayer(element) ? [] : getClippingElementAncestors(element, this._c) : [].concat(boundary);
1920
- const clippingAncestors = [...elementClippingAncestors, rootBoundary];
1921
- const firstClippingAncestor = clippingAncestors[0];
1922
- const clippingRect = clippingAncestors.reduce((accRect, clippingAncestor) => {
1923
- const rect = getClientRectFromClippingAncestor(element, clippingAncestor, strategy);
1924
- accRect.top = max(rect.top, accRect.top);
1925
- accRect.right = min(rect.right, accRect.right);
1926
- accRect.bottom = min(rect.bottom, accRect.bottom);
1927
- accRect.left = max(rect.left, accRect.left);
1928
- return accRect;
1929
- }, getClientRectFromClippingAncestor(element, firstClippingAncestor, strategy));
1930
- return {
1931
- width: clippingRect.right - clippingRect.left,
1932
- height: clippingRect.bottom - clippingRect.top,
1933
- x: clippingRect.left,
1934
- y: clippingRect.top
1935
- };
1936
- }
1937
-
1938
- function getDimensions(element) {
1939
- const {
1940
- width,
1941
- height
1942
- } = getCssDimensions(element);
1943
- return {
1944
- width,
1945
- height
1946
- };
1947
- }
1948
-
1949
- function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
1950
- const isOffsetParentAnElement = isHTMLElement(offsetParent);
1951
- const documentElement = getDocumentElement(offsetParent);
1952
- const isFixed = strategy === 'fixed';
1953
- const rect = getBoundingClientRect(element, true, isFixed, offsetParent);
1954
- let scroll = {
1955
- scrollLeft: 0,
1956
- scrollTop: 0
1957
- };
1958
- const offsets = createCoords(0);
1959
-
1960
- // If the <body> scrollbar appears on the left (e.g. RTL systems). Use
1961
- // Firefox with layout.scrollbar.side = 3 in about:config to test this.
1962
- function setLeftRTLScrollbarOffset() {
1963
- offsets.x = getWindowScrollBarX(documentElement);
1964
- }
1965
- if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
1966
- if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
1967
- scroll = getNodeScroll(offsetParent);
1968
- }
1969
- if (isOffsetParentAnElement) {
1970
- const offsetRect = getBoundingClientRect(offsetParent, true, isFixed, offsetParent);
1971
- offsets.x = offsetRect.x + offsetParent.clientLeft;
1972
- offsets.y = offsetRect.y + offsetParent.clientTop;
1973
- } else if (documentElement) {
1974
- setLeftRTLScrollbarOffset();
1975
- }
1976
- }
1977
- if (isFixed && !isOffsetParentAnElement && documentElement) {
1978
- setLeftRTLScrollbarOffset();
1979
- }
1980
- const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
1981
- const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
1982
- const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
1983
- return {
1984
- x,
1985
- y,
1986
- width: rect.width,
1987
- height: rect.height
1988
- };
1989
- }
1990
-
1991
- function isStaticPositioned(element) {
1992
- return getComputedStyle$1(element).position === 'static';
1993
- }
1994
-
1995
- function getTrueOffsetParent(element, polyfill) {
1996
- if (!isHTMLElement(element) || getComputedStyle$1(element).position === 'fixed') {
1997
- return null;
1998
- }
1999
- if (polyfill) {
2000
- return polyfill(element);
2001
- }
2002
- let rawOffsetParent = element.offsetParent;
2003
-
2004
- // Firefox returns the <html> element as the offsetParent if it's non-static,
2005
- // while Chrome and Safari return the <body> element. The <body> element must
2006
- // be used to perform the correct calculations even if the <html> element is
2007
- // non-static.
2008
- if (getDocumentElement(element) === rawOffsetParent) {
2009
- rawOffsetParent = rawOffsetParent.ownerDocument.body;
2010
- }
2011
- return rawOffsetParent;
2012
- }
2013
-
2014
- // Gets the closest ancestor positioned element. Handles some edge cases,
2015
- // such as table ancestors and cross browser bugs.
2016
- function getOffsetParent(element, polyfill) {
2017
- const win = getWindow(element);
2018
- if (isTopLayer(element)) {
2019
- return win;
2020
- }
2021
- if (!isHTMLElement(element)) {
2022
- let svgOffsetParent = getParentNode(element);
2023
- while (svgOffsetParent && !isLastTraversableNode(svgOffsetParent)) {
2024
- if (isElement(svgOffsetParent) && !isStaticPositioned(svgOffsetParent)) {
2025
- return svgOffsetParent;
2026
- }
2027
- svgOffsetParent = getParentNode(svgOffsetParent);
2028
- }
2029
- return win;
2030
- }
2031
- let offsetParent = getTrueOffsetParent(element, polyfill);
2032
- while (offsetParent && isTableElement(offsetParent) && isStaticPositioned(offsetParent)) {
2033
- offsetParent = getTrueOffsetParent(offsetParent, polyfill);
2034
- }
2035
- if (offsetParent && isLastTraversableNode(offsetParent) && isStaticPositioned(offsetParent) && !isContainingBlock(offsetParent)) {
2036
- return win;
2037
- }
2038
- return offsetParent || getContainingBlock(element) || win;
2039
- }
2040
-
2041
- const getElementRects = async function (data) {
2042
- const getOffsetParentFn = this.getOffsetParent || getOffsetParent;
2043
- const getDimensionsFn = this.getDimensions;
2044
- const floatingDimensions = await getDimensionsFn(data.floating);
2045
- return {
2046
- reference: getRectRelativeToOffsetParent(data.reference, await getOffsetParentFn(data.floating), data.strategy),
2047
- floating: {
2048
- x: 0,
2049
- y: 0,
2050
- width: floatingDimensions.width,
2051
- height: floatingDimensions.height
2052
- }
2053
- };
2054
- };
2055
-
2056
- function isRTL(element) {
2057
- return getComputedStyle$1(element).direction === 'rtl';
2058
- }
2059
-
2060
- const platform = {
2061
- convertOffsetParentRelativeRectToViewportRelativeRect,
2062
- getDocumentElement,
2063
- getClippingRect,
2064
- getOffsetParent,
2065
- getElementRects,
2066
- getClientRects,
2067
- getDimensions,
2068
- getScale,
2069
- isElement,
2070
- isRTL
2071
- };
2072
-
2073
- function rectsAreEqual(a, b) {
2074
- return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;
2075
- }
2076
-
2077
- // https://samthor.au/2021/observing-dom/
2078
- function observeMove(element, onMove) {
2079
- let io = null;
2080
- let timeoutId;
2081
- const root = getDocumentElement(element);
2082
- function cleanup() {
2083
- var _io;
2084
- clearTimeout(timeoutId);
2085
- (_io = io) == null || _io.disconnect();
2086
- io = null;
2087
- }
2088
- function refresh(skip, threshold) {
2089
- if (skip === void 0) {
2090
- skip = false;
2091
- }
2092
- if (threshold === void 0) {
2093
- threshold = 1;
2094
- }
2095
- cleanup();
2096
- const elementRectForRootMargin = element.getBoundingClientRect();
2097
- const {
2098
- left,
2099
- top,
2100
- width,
2101
- height
2102
- } = elementRectForRootMargin;
2103
- if (!skip) {
2104
- onMove();
2105
- }
2106
- if (!width || !height) {
2107
- return;
2108
- }
2109
- const insetTop = floor(top);
2110
- const insetRight = floor(root.clientWidth - (left + width));
2111
- const insetBottom = floor(root.clientHeight - (top + height));
2112
- const insetLeft = floor(left);
2113
- const rootMargin = -insetTop + "px " + -insetRight + "px " + -insetBottom + "px " + -insetLeft + "px";
2114
- const options = {
2115
- rootMargin,
2116
- threshold: max(0, min(1, threshold)) || 1
2117
- };
2118
- let isFirstUpdate = true;
2119
- function handleObserve(entries) {
2120
- const ratio = entries[0].intersectionRatio;
2121
- if (ratio !== threshold) {
2122
- if (!isFirstUpdate) {
2123
- return refresh();
2124
- }
2125
- if (!ratio) {
2126
- // If the reference is clipped, the ratio is 0. Throttle the refresh
2127
- // to prevent an infinite loop of updates.
2128
- timeoutId = setTimeout(() => {
2129
- refresh(false, 1e-7);
2130
- }, 1000);
2131
- } else {
2132
- refresh(false, ratio);
2133
- }
2134
- }
2135
- if (ratio === 1 && !rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) {
2136
- // It's possible that even though the ratio is reported as 1, the
2137
- // element is not actually fully within the IntersectionObserver's root
2138
- // area anymore. This can happen under performance constraints. This may
2139
- // be a bug in the browser's IntersectionObserver implementation. To
2140
- // work around this, we compare the element's bounding rect now with
2141
- // what it was at the time we created the IntersectionObserver. If they
2142
- // are not equal then the element moved, so we refresh.
2143
- refresh();
2144
- }
2145
- isFirstUpdate = false;
2146
- }
2147
-
2148
- // Older browsers don't support a `document` as the root and will throw an
2149
- // error.
2150
- try {
2151
- io = new IntersectionObserver(handleObserve, {
2152
- ...options,
2153
- // Handle <iframe>s
2154
- root: root.ownerDocument
2155
- });
2156
- } catch (_e) {
2157
- io = new IntersectionObserver(handleObserve, options);
2158
- }
2159
- io.observe(element);
2160
- }
2161
- refresh(true);
2162
- return cleanup;
2163
- }
2164
-
2165
- /**
2166
- * Automatically updates the position of the floating element when necessary.
2167
- * Should only be called when the floating element is mounted on the DOM or
2168
- * visible on the screen.
2169
- * @returns cleanup function that should be invoked when the floating element is
2170
- * removed from the DOM or hidden from the screen.
2171
- * @see https://floating-ui.com/docs/autoUpdate
2172
- */
2173
- function autoUpdate(reference, floating, update, options) {
2174
- if (options === void 0) {
2175
- options = {};
2176
- }
2177
- const {
2178
- ancestorScroll = true,
2179
- ancestorResize = true,
2180
- elementResize = typeof ResizeObserver === 'function',
2181
- layoutShift = typeof IntersectionObserver === 'function',
2182
- animationFrame = false
2183
- } = options;
2184
- const referenceEl = unwrapElement(reference);
2185
- const ancestors = ancestorScroll || ancestorResize ? [...(referenceEl ? getOverflowAncestors(referenceEl) : []), ...getOverflowAncestors(floating)] : [];
2186
- ancestors.forEach(ancestor => {
2187
- ancestorScroll && ancestor.addEventListener('scroll', update, {
2188
- passive: true
2189
- });
2190
- ancestorResize && ancestor.addEventListener('resize', update);
2191
- });
2192
- const cleanupIo = referenceEl && layoutShift ? observeMove(referenceEl, update) : null;
2193
- let reobserveFrame = -1;
2194
- let resizeObserver = null;
2195
- if (elementResize) {
2196
- resizeObserver = new ResizeObserver(_ref => {
2197
- let [firstEntry] = _ref;
2198
- if (firstEntry && firstEntry.target === referenceEl && resizeObserver) {
2199
- // Prevent update loops when using the `size` middleware.
2200
- // https://github.com/floating-ui/floating-ui/issues/1740
2201
- resizeObserver.unobserve(floating);
2202
- cancelAnimationFrame(reobserveFrame);
2203
- reobserveFrame = requestAnimationFrame(() => {
2204
- var _resizeObserver;
2205
- (_resizeObserver = resizeObserver) == null || _resizeObserver.observe(floating);
2206
- });
2207
- }
2208
- update();
2209
- });
2210
- if (referenceEl && !animationFrame) {
2211
- resizeObserver.observe(referenceEl);
2212
- }
2213
- resizeObserver.observe(floating);
2214
- }
2215
- let frameId;
2216
- let prevRefRect = animationFrame ? getBoundingClientRect(reference) : null;
2217
- if (animationFrame) {
2218
- frameLoop();
2219
- }
2220
- function frameLoop() {
2221
- const nextRefRect = getBoundingClientRect(reference);
2222
- if (prevRefRect && !rectsAreEqual(prevRefRect, nextRefRect)) {
2223
- update();
2224
- }
2225
- prevRefRect = nextRefRect;
2226
- frameId = requestAnimationFrame(frameLoop);
2227
- }
2228
- update();
2229
- return () => {
2230
- var _resizeObserver2;
2231
- ancestors.forEach(ancestor => {
2232
- ancestorScroll && ancestor.removeEventListener('scroll', update);
2233
- ancestorResize && ancestor.removeEventListener('resize', update);
2234
- });
2235
- cleanupIo == null || cleanupIo();
2236
- (_resizeObserver2 = resizeObserver) == null || _resizeObserver2.disconnect();
2237
- resizeObserver = null;
2238
- if (animationFrame) {
2239
- cancelAnimationFrame(frameId);
2240
- }
2241
- };
2242
- }
2243
-
2244
- /**
2245
- * Modifies the placement by translating the floating element along the
2246
- * specified axes.
2247
- * A number (shorthand for `mainAxis` or distance), or an axes configuration
2248
- * object may be passed.
2249
- * @see https://floating-ui.com/docs/offset
2250
- */
2251
- const offset$1 = offset$2;
2252
-
2253
- /**
2254
- * Optimizes the visibility of the floating element by shifting it in order to
2255
- * keep it in view when it will overflow the clipping boundary.
2256
- * @see https://floating-ui.com/docs/shift
2257
- */
2258
- const shift$1 = shift$2;
2259
-
2260
- /**
2261
- * Optimizes the visibility of the floating element by flipping the `placement`
2262
- * in order to keep it in view when the preferred placement(s) will overflow the
2263
- * clipping boundary. Alternative to `autoPlacement`.
2264
- * @see https://floating-ui.com/docs/flip
2265
- */
2266
- const flip$1 = flip$2;
2267
-
2268
- /**
2269
- * Provides data that allows you to change the size of the floating element —
2270
- * for instance, prevent it from overflowing the clipping boundary or match the
2271
- * width of the reference element.
2272
- * @see https://floating-ui.com/docs/size
2273
- */
2274
- const size$1 = size$2;
2275
-
2276
- /**
2277
- * Provides data to hide the floating element in applicable situations, such as
2278
- * when it is not in the same clipping context as the reference element.
2279
- * @see https://floating-ui.com/docs/hide
2280
- */
2281
- const hide$1 = hide$2;
2282
-
2283
- /**
2284
- * Provides data to position an inner element of the floating element so that it
2285
- * appears centered to the reference element.
2286
- * @see https://floating-ui.com/docs/arrow
2287
- */
2288
- const arrow$2 = arrow$3;
2289
-
2290
- /**
2291
- * Built-in `limiter` that will stop `shift()` at a certain point.
2292
- */
2293
- const limitShift$1 = limitShift$2;
2294
-
2295
- /**
2296
- * Computes the `x` and `y` coordinates that will place the floating element
2297
- * next to a given reference element.
2298
- */
2299
- const computePosition = (reference, floating, options) => {
2300
- // This caches the expensive `getClippingElementAncestors` function so that
2301
- // multiple lifecycle resets re-use the same result. It only lives for a
2302
- // single call. If other functions become expensive, we can add them as well.
2303
- const cache = new Map();
2304
- const mergedOptions = {
2305
- platform,
2306
- ...options
2307
- };
2308
- const platformWithCache = {
2309
- ...mergedOptions.platform,
2310
- _c: cache
2311
- };
2312
- return computePosition$1(reference, floating, {
2313
- ...mergedOptions,
2314
- platform: platformWithCache
2315
- });
2316
- };
2317
-
2318
- var isClient = typeof document !== 'undefined';
2319
-
2320
- var noop = function noop() {};
2321
- var index = isClient ? useLayoutEffect : noop;
2322
-
2323
- // Fork of `fast-deep-equal` that only does the comparisons we need and compares
2324
- // functions
2325
- function deepEqual(a, b) {
2326
- if (a === b) {
2327
- return true;
2328
- }
2329
- if (typeof a !== typeof b) {
2330
- return false;
2331
- }
2332
- if (typeof a === 'function' && a.toString() === b.toString()) {
2333
- return true;
2334
- }
2335
- let length;
2336
- let i;
2337
- let keys;
2338
- if (a && b && typeof a === 'object') {
2339
- if (Array.isArray(a)) {
2340
- length = a.length;
2341
- if (length !== b.length) return false;
2342
- for (i = length; i-- !== 0;) {
2343
- if (!deepEqual(a[i], b[i])) {
2344
- return false;
2345
- }
2346
- }
2347
- return true;
2348
- }
2349
- keys = Object.keys(a);
2350
- length = keys.length;
2351
- if (length !== Object.keys(b).length) {
2352
- return false;
2353
- }
2354
- for (i = length; i-- !== 0;) {
2355
- if (!{}.hasOwnProperty.call(b, keys[i])) {
2356
- return false;
2357
- }
2358
- }
2359
- for (i = length; i-- !== 0;) {
2360
- const key = keys[i];
2361
- if (key === '_owner' && a.$$typeof) {
2362
- continue;
2363
- }
2364
- if (!deepEqual(a[key], b[key])) {
2365
- return false;
2366
- }
2367
- }
2368
- return true;
2369
- }
2370
- return a !== a && b !== b;
2371
- }
2372
-
2373
- function getDPR(element) {
2374
- if (typeof window === 'undefined') {
2375
- return 1;
2376
- }
2377
- const win = element.ownerDocument.defaultView || window;
2378
- return win.devicePixelRatio || 1;
2379
- }
2380
-
2381
- function roundByDPR(element, value) {
2382
- const dpr = getDPR(element);
2383
- return Math.round(value * dpr) / dpr;
2384
- }
2385
-
2386
- function useLatestRef(value) {
2387
- const ref = React.useRef(value);
2388
- index(() => {
2389
- ref.current = value;
2390
- });
2391
- return ref;
2392
- }
2393
-
2394
- /**
2395
- * Provides data to position a floating element.
2396
- * @see https://floating-ui.com/docs/useFloating
2397
- */
2398
- function useFloating(options) {
2399
- if (options === void 0) {
2400
- options = {};
2401
- }
2402
- const {
2403
- placement = 'bottom',
2404
- strategy = 'absolute',
2405
- middleware = [],
2406
- platform,
2407
- elements: {
2408
- reference: externalReference,
2409
- floating: externalFloating
2410
- } = {},
2411
- transform = true,
2412
- whileElementsMounted,
2413
- open
2414
- } = options;
2415
- const [data, setData] = React.useState({
2416
- x: 0,
2417
- y: 0,
2418
- strategy,
2419
- placement,
2420
- middlewareData: {},
2421
- isPositioned: false
2422
- });
2423
- const [latestMiddleware, setLatestMiddleware] = React.useState(middleware);
2424
- if (!deepEqual(latestMiddleware, middleware)) {
2425
- setLatestMiddleware(middleware);
2426
- }
2427
- const [_reference, _setReference] = React.useState(null);
2428
- const [_floating, _setFloating] = React.useState(null);
2429
- const setReference = React.useCallback(node => {
2430
- if (node !== referenceRef.current) {
2431
- referenceRef.current = node;
2432
- _setReference(node);
2433
- }
2434
- }, []);
2435
- const setFloating = React.useCallback(node => {
2436
- if (node !== floatingRef.current) {
2437
- floatingRef.current = node;
2438
- _setFloating(node);
2439
- }
2440
- }, []);
2441
- const referenceEl = externalReference || _reference;
2442
- const floatingEl = externalFloating || _floating;
2443
- const referenceRef = React.useRef(null);
2444
- const floatingRef = React.useRef(null);
2445
- const dataRef = React.useRef(data);
2446
- const hasWhileElementsMounted = whileElementsMounted != null;
2447
- const whileElementsMountedRef = useLatestRef(whileElementsMounted);
2448
- const platformRef = useLatestRef(platform);
2449
- const openRef = useLatestRef(open);
2450
- const update = React.useCallback(() => {
2451
- if (!referenceRef.current || !floatingRef.current) {
2452
- return;
2453
- }
2454
- const config = {
2455
- placement,
2456
- strategy,
2457
- middleware: latestMiddleware
2458
- };
2459
- if (platformRef.current) {
2460
- config.platform = platformRef.current;
2461
- }
2462
- computePosition(referenceRef.current, floatingRef.current, config).then(data => {
2463
- const fullData = {
2464
- ...data,
2465
- // The floating element's position may be recomputed while it's closed
2466
- // but still mounted (such as when transitioning out). To ensure
2467
- // `isPositioned` will be `false` initially on the next open, avoid
2468
- // setting it to `true` when `open === false` (must be specified).
2469
- isPositioned: openRef.current !== false
2470
- };
2471
- if (isMountedRef.current && !deepEqual(dataRef.current, fullData)) {
2472
- dataRef.current = fullData;
2473
- ReactDOM.flushSync(() => {
2474
- setData(fullData);
2475
- });
2476
- }
2477
- });
2478
- }, [latestMiddleware, placement, strategy, platformRef, openRef]);
2479
- index(() => {
2480
- if (open === false && dataRef.current.isPositioned) {
2481
- dataRef.current.isPositioned = false;
2482
- setData(data => ({
2483
- ...data,
2484
- isPositioned: false
2485
- }));
2486
- }
2487
- }, [open]);
2488
- const isMountedRef = React.useRef(false);
2489
- index(() => {
2490
- isMountedRef.current = true;
2491
- return () => {
2492
- isMountedRef.current = false;
2493
- };
2494
- }, []);
2495
- index(() => {
2496
- if (referenceEl) referenceRef.current = referenceEl;
2497
- if (floatingEl) floatingRef.current = floatingEl;
2498
- if (referenceEl && floatingEl) {
2499
- if (whileElementsMountedRef.current) {
2500
- return whileElementsMountedRef.current(referenceEl, floatingEl, update);
2501
- }
2502
- update();
2503
- }
2504
- }, [referenceEl, floatingEl, update, whileElementsMountedRef, hasWhileElementsMounted]);
2505
- const refs = React.useMemo(() => ({
2506
- reference: referenceRef,
2507
- floating: floatingRef,
2508
- setReference,
2509
- setFloating
2510
- }), [setReference, setFloating]);
2511
- const elements = React.useMemo(() => ({
2512
- reference: referenceEl,
2513
- floating: floatingEl
2514
- }), [referenceEl, floatingEl]);
2515
- const floatingStyles = React.useMemo(() => {
2516
- const initialStyles = {
2517
- position: strategy,
2518
- left: 0,
2519
- top: 0
2520
- };
2521
- if (!elements.floating) {
2522
- return initialStyles;
2523
- }
2524
- const x = roundByDPR(elements.floating, data.x);
2525
- const y = roundByDPR(elements.floating, data.y);
2526
- if (transform) {
2527
- return {
2528
- ...initialStyles,
2529
- transform: "translate(" + x + "px, " + y + "px)",
2530
- ...(getDPR(elements.floating) >= 1.5 && {
2531
- willChange: 'transform'
2532
- })
2533
- };
2534
- }
2535
- return {
2536
- position: strategy,
2537
- left: x,
2538
- top: y
2539
- };
2540
- }, [strategy, transform, elements.floating, data.x, data.y]);
2541
- return React.useMemo(() => ({
2542
- ...data,
2543
- update,
2544
- refs,
2545
- elements,
2546
- floatingStyles
2547
- }), [data, update, refs, elements, floatingStyles]);
2548
- }
2549
-
2550
- /**
2551
- * Provides data to position an inner element of the floating element so that it
2552
- * appears centered to the reference element.
2553
- * This wraps the core `arrow` middleware to allow React refs as the element.
2554
- * @see https://floating-ui.com/docs/arrow
2555
- */
2556
- const arrow$1 = options => {
2557
- function isRef(value) {
2558
- return {}.hasOwnProperty.call(value, 'current');
2559
- }
2560
- return {
2561
- name: 'arrow',
2562
- options,
2563
- fn(state) {
2564
- const {
2565
- element,
2566
- padding
2567
- } = typeof options === 'function' ? options(state) : options;
2568
- if (element && isRef(element)) {
2569
- if (element.current != null) {
2570
- return arrow$2({
2571
- element: element.current,
2572
- padding
2573
- }).fn(state);
2574
- }
2575
- return {};
2576
- }
2577
- if (element) {
2578
- return arrow$2({
2579
- element,
2580
- padding
2581
- }).fn(state);
2582
- }
2583
- return {};
2584
- }
2585
- };
2586
- };
2587
-
2588
- /**
2589
- * Modifies the placement by translating the floating element along the
2590
- * specified axes.
2591
- * A number (shorthand for `mainAxis` or distance), or an axes configuration
2592
- * object may be passed.
2593
- * @see https://floating-ui.com/docs/offset
2594
- */
2595
- const offset = (options, deps) => ({
2596
- ...offset$1(options),
2597
- options: [options, deps]
2598
- });
2599
-
2600
- /**
2601
- * Optimizes the visibility of the floating element by shifting it in order to
2602
- * keep it in view when it will overflow the clipping boundary.
2603
- * @see https://floating-ui.com/docs/shift
2604
- */
2605
- const shift = (options, deps) => ({
2606
- ...shift$1(options),
2607
- options: [options, deps]
2608
- });
2609
-
2610
- /**
2611
- * Built-in `limiter` that will stop `shift()` at a certain point.
2612
- */
2613
- const limitShift = (options, deps) => ({
2614
- ...limitShift$1(options),
2615
- options: [options, deps]
2616
- });
2617
-
2618
- /**
2619
- * Optimizes the visibility of the floating element by flipping the `placement`
2620
- * in order to keep it in view when the preferred placement(s) will overflow the
2621
- * clipping boundary. Alternative to `autoPlacement`.
2622
- * @see https://floating-ui.com/docs/flip
2623
- */
2624
- const flip = (options, deps) => ({
2625
- ...flip$1(options),
2626
- options: [options, deps]
2627
- });
2628
-
2629
- /**
2630
- * Provides data that allows you to change the size of the floating element —
2631
- * for instance, prevent it from overflowing the clipping boundary or match the
2632
- * width of the reference element.
2633
- * @see https://floating-ui.com/docs/size
2634
- */
2635
- const size = (options, deps) => ({
2636
- ...size$1(options),
2637
- options: [options, deps]
2638
- });
2639
-
2640
- /**
2641
- * Provides data to hide the floating element in applicable situations, such as
2642
- * when it is not in the same clipping context as the reference element.
2643
- * @see https://floating-ui.com/docs/hide
2644
- */
2645
- const hide = (options, deps) => ({
2646
- ...hide$1(options),
2647
- options: [options, deps]
2648
- });
2649
-
2650
- /**
2651
- * Provides data to position an inner element of the floating element so that it
2652
- * appears centered to the reference element.
2653
- * This wraps the core `arrow` middleware to allow React refs as the element.
2654
- * @see https://floating-ui.com/docs/arrow
2655
- */
2656
- const arrow = (options, deps) => ({
2657
- ...arrow$1(options),
2658
- options: [options, deps]
2659
- });
2660
-
2661
- // src/arrow.tsx
2662
- var NAME = "Arrow";
2663
- var Arrow$1 = React.forwardRef((props, forwardedRef) => {
2664
- const { children, width = 10, height = 5, ...arrowProps } = props;
2665
- return /* @__PURE__ */ jsx(
2666
- Primitive.svg,
2667
- {
2668
- ...arrowProps,
2669
- ref: forwardedRef,
2670
- width,
2671
- height,
2672
- viewBox: "0 0 30 10",
2673
- preserveAspectRatio: "none",
2674
- children: props.asChild ? children : /* @__PURE__ */ jsx("polygon", { points: "0,0 30,0 15,10" })
2675
- }
2676
- );
2677
- });
2678
- Arrow$1.displayName = NAME;
2679
- var Root = Arrow$1;
2680
-
2681
- var POPPER_NAME = "Popper";
2682
- var [createPopperContext, createPopperScope] = createContextScope(POPPER_NAME);
2683
- var [PopperProvider, usePopperContext] = createPopperContext(POPPER_NAME);
2684
- var Popper = (props) => {
2685
- const { __scopePopper, children } = props;
2686
- const [anchor, setAnchor] = React.useState(null);
2687
- return /* @__PURE__ */ jsx(PopperProvider, { scope: __scopePopper, anchor, onAnchorChange: setAnchor, children });
2688
- };
2689
- Popper.displayName = POPPER_NAME;
2690
- var ANCHOR_NAME = "PopperAnchor";
2691
- var PopperAnchor = React.forwardRef(
2692
- (props, forwardedRef) => {
2693
- const { __scopePopper, virtualRef, ...anchorProps } = props;
2694
- const context = usePopperContext(ANCHOR_NAME, __scopePopper);
2695
- const ref = React.useRef(null);
2696
- const composedRefs = useComposedRefs(forwardedRef, ref);
2697
- const anchorRef = React.useRef(null);
2698
- React.useEffect(() => {
2699
- const previousAnchor = anchorRef.current;
2700
- anchorRef.current = virtualRef?.current || ref.current;
2701
- if (previousAnchor !== anchorRef.current) {
2702
- context.onAnchorChange(anchorRef.current);
2703
- }
2704
- });
2705
- return virtualRef ? null : /* @__PURE__ */ jsx(Primitive.div, { ...anchorProps, ref: composedRefs });
2706
- }
2707
- );
2708
- PopperAnchor.displayName = ANCHOR_NAME;
2709
- var CONTENT_NAME = "PopperContent";
2710
- var [PopperContentProvider, useContentContext] = createPopperContext(CONTENT_NAME);
2711
- var PopperContent = React.forwardRef(
2712
- (props, forwardedRef) => {
2713
- const {
2714
- __scopePopper,
2715
- side = "bottom",
2716
- sideOffset = 0,
2717
- align = "center",
2718
- alignOffset = 0,
2719
- arrowPadding = 0,
2720
- avoidCollisions = true,
2721
- collisionBoundary = [],
2722
- collisionPadding: collisionPaddingProp = 0,
2723
- sticky = "partial",
2724
- hideWhenDetached = false,
2725
- updatePositionStrategy = "optimized",
2726
- onPlaced,
2727
- ...contentProps
2728
- } = props;
2729
- const context = usePopperContext(CONTENT_NAME, __scopePopper);
2730
- const [content, setContent] = React.useState(null);
2731
- const composedRefs = useComposedRefs(forwardedRef, (node) => setContent(node));
2732
- const [arrow$1, setArrow] = React.useState(null);
2733
- const arrowSize = useSize(arrow$1);
2734
- const arrowWidth = arrowSize?.width ?? 0;
2735
- const arrowHeight = arrowSize?.height ?? 0;
2736
- const desiredPlacement = side + (align !== "center" ? "-" + align : "");
2737
- const collisionPadding = typeof collisionPaddingProp === "number" ? collisionPaddingProp : { top: 0, right: 0, bottom: 0, left: 0, ...collisionPaddingProp };
2738
- const boundary = Array.isArray(collisionBoundary) ? collisionBoundary : [collisionBoundary];
2739
- const hasExplicitBoundaries = boundary.length > 0;
2740
- const detectOverflowOptions = {
2741
- padding: collisionPadding,
2742
- boundary: boundary.filter(isNotNull),
2743
- // with `strategy: 'fixed'`, this is the only way to get it to respect boundaries
2744
- altBoundary: hasExplicitBoundaries
2745
- };
2746
- const { refs, floatingStyles, placement, isPositioned, middlewareData } = useFloating({
2747
- // default to `fixed` strategy so users don't have to pick and we also avoid focus scroll issues
2748
- strategy: "fixed",
2749
- placement: desiredPlacement,
2750
- whileElementsMounted: (...args) => {
2751
- const cleanup = autoUpdate(...args, {
2752
- animationFrame: updatePositionStrategy === "always"
2753
- });
2754
- return cleanup;
2755
- },
2756
- elements: {
2757
- reference: context.anchor
2758
- },
2759
- middleware: [
2760
- offset({ mainAxis: sideOffset + arrowHeight, alignmentAxis: alignOffset }),
2761
- avoidCollisions && shift({
2762
- mainAxis: true,
2763
- crossAxis: false,
2764
- limiter: sticky === "partial" ? limitShift() : void 0,
2765
- ...detectOverflowOptions
2766
- }),
2767
- avoidCollisions && flip({ ...detectOverflowOptions }),
2768
- size({
2769
- ...detectOverflowOptions,
2770
- apply: ({ elements, rects, availableWidth, availableHeight }) => {
2771
- const { width: anchorWidth, height: anchorHeight } = rects.reference;
2772
- const contentStyle = elements.floating.style;
2773
- contentStyle.setProperty("--radix-popper-available-width", `${availableWidth}px`);
2774
- contentStyle.setProperty("--radix-popper-available-height", `${availableHeight}px`);
2775
- contentStyle.setProperty("--radix-popper-anchor-width", `${anchorWidth}px`);
2776
- contentStyle.setProperty("--radix-popper-anchor-height", `${anchorHeight}px`);
2777
- }
2778
- }),
2779
- arrow$1 && arrow({ element: arrow$1, padding: arrowPadding }),
2780
- transformOrigin({ arrowWidth, arrowHeight }),
2781
- hideWhenDetached && hide({ strategy: "referenceHidden", ...detectOverflowOptions })
2782
- ]
2783
- });
2784
- const [placedSide, placedAlign] = getSideAndAlignFromPlacement(placement);
2785
- const handlePlaced = useCallbackRef$1(onPlaced);
2786
- useLayoutEffect2(() => {
2787
- if (isPositioned) {
2788
- handlePlaced?.();
2789
- }
2790
- }, [isPositioned, handlePlaced]);
2791
- const arrowX = middlewareData.arrow?.x;
2792
- const arrowY = middlewareData.arrow?.y;
2793
- const cannotCenterArrow = middlewareData.arrow?.centerOffset !== 0;
2794
- const [contentZIndex, setContentZIndex] = React.useState();
2795
- useLayoutEffect2(() => {
2796
- if (content) setContentZIndex(window.getComputedStyle(content).zIndex);
2797
- }, [content]);
2798
- return /* @__PURE__ */ jsx(
2799
- "div",
2800
- {
2801
- ref: refs.setFloating,
2802
- "data-radix-popper-content-wrapper": "",
2803
- style: {
2804
- ...floatingStyles,
2805
- transform: isPositioned ? floatingStyles.transform : "translate(0, -200%)",
2806
- // keep off the page when measuring
2807
- minWidth: "max-content",
2808
- zIndex: contentZIndex,
2809
- ["--radix-popper-transform-origin"]: [
2810
- middlewareData.transformOrigin?.x,
2811
- middlewareData.transformOrigin?.y
2812
- ].join(" "),
2813
- // hide the content if using the hide middleware and should be hidden
2814
- // set visibility to hidden and disable pointer events so the UI behaves
2815
- // as if the PopperContent isn't there at all
2816
- ...middlewareData.hide?.referenceHidden && {
2817
- visibility: "hidden",
2818
- pointerEvents: "none"
2819
- }
2820
- },
2821
- dir: props.dir,
2822
- children: /* @__PURE__ */ jsx(
2823
- PopperContentProvider,
2824
- {
2825
- scope: __scopePopper,
2826
- placedSide,
2827
- onArrowChange: setArrow,
2828
- arrowX,
2829
- arrowY,
2830
- shouldHideArrow: cannotCenterArrow,
2831
- children: /* @__PURE__ */ jsx(
2832
- Primitive.div,
2833
- {
2834
- "data-side": placedSide,
2835
- "data-align": placedAlign,
2836
- ...contentProps,
2837
- ref: composedRefs,
2838
- style: {
2839
- ...contentProps.style,
2840
- // if the PopperContent hasn't been placed yet (not all measurements done)
2841
- // we prevent animations so that users's animation don't kick in too early referring wrong sides
2842
- animation: !isPositioned ? "none" : void 0
2843
- }
2844
- }
2845
- )
2846
- }
2847
- )
2848
- }
2849
- );
2850
- }
2851
- );
2852
- PopperContent.displayName = CONTENT_NAME;
2853
- var ARROW_NAME = "PopperArrow";
2854
- var OPPOSITE_SIDE = {
2855
- top: "bottom",
2856
- right: "left",
2857
- bottom: "top",
2858
- left: "right"
2859
- };
2860
- var PopperArrow = React.forwardRef(function PopperArrow2(props, forwardedRef) {
2861
- const { __scopePopper, ...arrowProps } = props;
2862
- const contentContext = useContentContext(ARROW_NAME, __scopePopper);
2863
- const baseSide = OPPOSITE_SIDE[contentContext.placedSide];
2864
- return (
2865
- // we have to use an extra wrapper because `ResizeObserver` (used by `useSize`)
2866
- // doesn't report size as we'd expect on SVG elements.
2867
- // it reports their bounding box which is effectively the largest path inside the SVG.
2868
- /* @__PURE__ */ jsx(
2869
- "span",
2870
- {
2871
- ref: contentContext.onArrowChange,
2872
- style: {
2873
- position: "absolute",
2874
- left: contentContext.arrowX,
2875
- top: contentContext.arrowY,
2876
- [baseSide]: 0,
2877
- transformOrigin: {
2878
- top: "",
2879
- right: "0 0",
2880
- bottom: "center 0",
2881
- left: "100% 0"
2882
- }[contentContext.placedSide],
2883
- transform: {
2884
- top: "translateY(100%)",
2885
- right: "translateY(50%) rotate(90deg) translateX(-50%)",
2886
- bottom: `rotate(180deg)`,
2887
- left: "translateY(50%) rotate(-90deg) translateX(50%)"
2888
- }[contentContext.placedSide],
2889
- visibility: contentContext.shouldHideArrow ? "hidden" : void 0
2890
- },
2891
- children: /* @__PURE__ */ jsx(
2892
- Root,
2893
- {
2894
- ...arrowProps,
2895
- ref: forwardedRef,
2896
- style: {
2897
- ...arrowProps.style,
2898
- // ensures the element can be measured correctly (mostly for if SVG)
2899
- display: "block"
2900
- }
2901
- }
2902
- )
2903
- }
2904
- )
2905
- );
2906
- });
2907
- PopperArrow.displayName = ARROW_NAME;
2908
- function isNotNull(value) {
2909
- return value !== null;
2910
- }
2911
- var transformOrigin = (options) => ({
2912
- name: "transformOrigin",
2913
- options,
2914
- fn(data) {
2915
- const { placement, rects, middlewareData } = data;
2916
- const cannotCenterArrow = middlewareData.arrow?.centerOffset !== 0;
2917
- const isArrowHidden = cannotCenterArrow;
2918
- const arrowWidth = isArrowHidden ? 0 : options.arrowWidth;
2919
- const arrowHeight = isArrowHidden ? 0 : options.arrowHeight;
2920
- const [placedSide, placedAlign] = getSideAndAlignFromPlacement(placement);
2921
- const noArrowAlign = { start: "0%", center: "50%", end: "100%" }[placedAlign];
2922
- const arrowXCenter = (middlewareData.arrow?.x ?? 0) + arrowWidth / 2;
2923
- const arrowYCenter = (middlewareData.arrow?.y ?? 0) + arrowHeight / 2;
2924
- let x = "";
2925
- let y = "";
2926
- if (placedSide === "bottom") {
2927
- x = isArrowHidden ? noArrowAlign : `${arrowXCenter}px`;
2928
- y = `${-arrowHeight}px`;
2929
- } else if (placedSide === "top") {
2930
- x = isArrowHidden ? noArrowAlign : `${arrowXCenter}px`;
2931
- y = `${rects.floating.height + arrowHeight}px`;
2932
- } else if (placedSide === "right") {
2933
- x = `${-arrowHeight}px`;
2934
- y = isArrowHidden ? noArrowAlign : `${arrowYCenter}px`;
2935
- } else if (placedSide === "left") {
2936
- x = `${rects.floating.width + arrowHeight}px`;
2937
- y = isArrowHidden ? noArrowAlign : `${arrowYCenter}px`;
2938
- }
2939
- return { data: { x, y } };
2940
- }
2941
- });
2942
- function getSideAndAlignFromPlacement(placement) {
2943
- const [side, align = "center"] = placement.split("-");
2944
- return [side, align];
2945
- }
2946
- var Root2 = Popper;
2947
- var Anchor = PopperAnchor;
2948
- var Content = PopperContent;
2949
- var Arrow = PopperArrow;
2950
-
2951
452
  var PORTAL_NAME = "Portal";
2952
453
  var Portal = React.forwardRef((props, forwardedRef) => {
2953
454
  const { container: containerProp, ...portalProps } = props;
@@ -3852,5 +1353,5 @@ const SideCar = exportSidecar(effectCar, RemoveScrollSideCar);
3852
1353
  var ReactRemoveScroll = React.forwardRef(function (props, ref) { return (React.createElement(RemoveScroll, __assign({}, props, { ref: ref, sideCar: SideCar }))); });
3853
1354
  ReactRemoveScroll.classNames = RemoveScroll.classNames;
3854
1355
 
3855
- export { Anchor as A, Content as C, DismissableLayer as D, FocusScope as F, Portal as P, Root2 as R, useFocusGuards as a, ReactRemoveScroll as b, createPopperScope as c, Arrow as d, hideOthers as h, useId as u };
1356
+ export { DismissableLayer as D, FocusScope as F, Portal as P, ReactRemoveScroll as R, hideOthers as h, useFocusGuards as u };
3856
1357
  //# sourceMappingURL=Combination.js.map