@baseline-ui/core 2.1.0 → 2.4.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 (525) hide show
  1. package/dist/Accordion.css +10 -0
  2. package/dist/Accordion.mjs +1 -0
  3. package/dist/ActionButton.css +10 -0
  4. package/dist/ActionButton.mjs +1 -0
  5. package/dist/ActionGroup.css +10 -0
  6. package/dist/ActionGroup.mjs +1 -0
  7. package/dist/ActionIconButton.css +10 -0
  8. package/dist/ActionIconButton.mjs +1 -0
  9. package/dist/Actionable.css +10 -0
  10. package/dist/Actionable.mjs +1 -0
  11. package/dist/AlertDialog.css +10 -0
  12. package/dist/AlertDialog.mjs +1 -0
  13. package/dist/AudioPlayer.css +10 -0
  14. package/dist/AudioPlayer.mjs +1 -0
  15. package/dist/Avatar.css +10 -0
  16. package/dist/Avatar.mjs +1 -0
  17. package/dist/Box.mjs +1 -0
  18. package/dist/ButtonSelect.css +10 -0
  19. package/dist/ButtonSelect.mjs +1 -0
  20. package/dist/Calendar.css +10 -0
  21. package/dist/Calendar.mjs +1 -0
  22. package/dist/Checkbox.css +10 -0
  23. package/dist/Checkbox.mjs +1 -0
  24. package/dist/Code.css +10 -0
  25. package/dist/Code.mjs +1 -0
  26. package/dist/ColorInput.css +10 -0
  27. package/dist/ColorInput.mjs +1 -0
  28. package/dist/ColorSwatch.css +10 -0
  29. package/dist/ColorSwatch.mjs +1 -0
  30. package/dist/ColorSwatchPicker.css +10 -0
  31. package/dist/ColorSwatchPicker.mjs +1 -0
  32. package/dist/ComboBox.css +10 -0
  33. package/dist/ComboBox.mjs +1 -0
  34. package/dist/DateField.css +10 -0
  35. package/dist/DateField.mjs +1 -0
  36. package/dist/DateFormat.mjs +1 -0
  37. package/dist/DeviceProvider.mjs +1 -0
  38. package/dist/Dialog.css +10 -0
  39. package/dist/Dialog.mjs +1 -0
  40. package/dist/Disclosure.css +10 -0
  41. package/dist/Disclosure.mjs +1 -0
  42. package/dist/DomNodeRenderer.mjs +1 -0
  43. package/dist/Drawer.css +10 -0
  44. package/dist/Drawer.mjs +1 -0
  45. package/dist/Editor.css +10 -0
  46. package/dist/Editor.mjs +1 -0
  47. package/dist/FileInput.css +10 -0
  48. package/dist/FileInput.mjs +1 -0
  49. package/dist/FileList.css +10 -0
  50. package/dist/FileList.mjs +1 -0
  51. package/dist/FileUploader.css +10 -0
  52. package/dist/FileUploader.mjs +1 -0
  53. package/dist/FrameProvider.mjs +1 -0
  54. package/dist/FreehandCanvas.css +10 -0
  55. package/dist/FreehandCanvas.mjs +1 -0
  56. package/dist/GridList.css +10 -0
  57. package/dist/GridList.mjs +1 -0
  58. package/dist/Group.mjs +1 -0
  59. package/dist/I18nProvider.mjs +1 -0
  60. package/dist/Icon.mjs +1 -0
  61. package/dist/ImageDropZone.css +10 -0
  62. package/dist/ImageDropZone.mjs +1 -0
  63. package/dist/ImageGallery.css +10 -0
  64. package/dist/ImageGallery.mjs +1 -0
  65. package/dist/InlineAlert.css +10 -0
  66. package/dist/InlineAlert.mjs +1 -0
  67. package/dist/InlineToolbar.css +10 -0
  68. package/dist/InlineToolbar.mjs +10 -0
  69. package/dist/Kbd.css +10 -0
  70. package/dist/Kbd.mjs +1 -0
  71. package/dist/Link.css +10 -0
  72. package/dist/Link.mjs +1 -0
  73. package/dist/ListBox.css +10 -0
  74. package/dist/ListBox.mjs +1 -0
  75. package/dist/Markdown.css +10 -0
  76. package/dist/Markdown.mjs +1 -0
  77. package/dist/Menu.css +10 -0
  78. package/dist/Menu.mjs +1 -0
  79. package/dist/MessageFormat.mjs +1 -0
  80. package/dist/Modal.css +10 -0
  81. package/dist/Modal.mjs +1 -0
  82. package/dist/NumberFormat.mjs +1 -0
  83. package/dist/NumberInput.css +10 -0
  84. package/dist/NumberInput.mjs +1 -0
  85. package/dist/Pagination.css +10 -0
  86. package/dist/Pagination.mjs +1 -0
  87. package/dist/Panel.css +10 -0
  88. package/dist/Panel.mjs +1 -0
  89. package/dist/PointPicker.css +10 -0
  90. package/dist/PointPicker.mjs +1 -0
  91. package/dist/Popover.css +10 -0
  92. package/dist/Popover.mjs +1 -0
  93. package/dist/Portal.css +10 -0
  94. package/dist/Portal.mjs +1 -0
  95. package/dist/PortalContainerProvider.mjs +1 -0
  96. package/dist/Preview.css +10 -0
  97. package/dist/Preview.mjs +1 -0
  98. package/dist/ProgressBar.css +10 -0
  99. package/dist/ProgressBar.mjs +1 -0
  100. package/dist/ProgressSpinner.css +10 -0
  101. package/dist/ProgressSpinner.mjs +1 -0
  102. package/dist/RadioGroup.css +10 -0
  103. package/dist/RadioGroup.mjs +1 -0
  104. package/dist/Reaction.css +10 -0
  105. package/dist/Reaction.mjs +1 -0
  106. package/dist/ScrollControlButton.css +10 -0
  107. package/dist/ScrollControlButton.mjs +1 -0
  108. package/dist/SearchInput.css +10 -0
  109. package/dist/SearchInput.mjs +1 -0
  110. package/dist/Select.css +10 -0
  111. package/dist/Select.mjs +1 -0
  112. package/dist/Separator.css +10 -0
  113. package/dist/Separator.mjs +1 -0
  114. package/dist/Skeleton.css +10 -0
  115. package/dist/Skeleton.mjs +1 -0
  116. package/dist/Slider.css +10 -0
  117. package/dist/Slider.mjs +1 -0
  118. package/dist/StatusCard.css +10 -0
  119. package/dist/StatusCard.mjs +1 -0
  120. package/dist/Stepper.css +10 -0
  121. package/dist/Stepper.mjs +1 -0
  122. package/dist/Switch.css +10 -0
  123. package/dist/Switch.mjs +1 -0
  124. package/dist/Table.css +10 -0
  125. package/dist/Table.mjs +1 -0
  126. package/dist/Tabs.css +10 -0
  127. package/dist/Tabs.mjs +1 -0
  128. package/dist/Tag.css +10 -0
  129. package/dist/Tag.mjs +1 -0
  130. package/dist/TagGroup.css +10 -0
  131. package/dist/TagGroup.mjs +1 -0
  132. package/dist/TaggedPagination.css +10 -0
  133. package/dist/TaggedPagination.mjs +1 -0
  134. package/dist/Text.css +10 -0
  135. package/dist/Text.mjs +1 -0
  136. package/dist/TextInput.css +10 -0
  137. package/dist/TextInput.mjs +1 -0
  138. package/dist/ThemeProvider.css +10 -0
  139. package/dist/ThemeProvider.mjs +1 -0
  140. package/dist/TimeField.css +10 -0
  141. package/dist/TimeField.mjs +1 -0
  142. package/dist/Toast.css +10 -0
  143. package/dist/Toast.mjs +1 -0
  144. package/dist/ToggleButton.css +10 -0
  145. package/dist/ToggleButton.mjs +1 -0
  146. package/dist/ToggleIconButton.css +10 -0
  147. package/dist/ToggleIconButton.mjs +1 -0
  148. package/dist/Toolbar.css +10 -0
  149. package/dist/Toolbar.mjs +1 -0
  150. package/dist/Tooltip.css +10 -0
  151. package/dist/Tooltip.mjs +1 -0
  152. package/dist/TreeView.css +10 -0
  153. package/dist/TreeView.mjs +1 -0
  154. package/dist/UNSAFE_ListBox.css +10 -0
  155. package/dist/UNSAFE_ListBox.mjs +1 -0
  156. package/dist/Virtualizer.mjs +1 -0
  157. package/dist/chunk-22BJMDCA.mjs +10 -0
  158. package/dist/chunk-246VHB32.mjs +10 -0
  159. package/dist/chunk-2CZ3OV4X.mjs +10 -0
  160. package/dist/chunk-2JANDORZ.mjs +11 -0
  161. package/dist/chunk-2MS356Q7.mjs +10 -0
  162. package/dist/chunk-2PH5GN2S.mjs +0 -0
  163. package/dist/chunk-2RCST7ET.mjs +10 -0
  164. package/dist/chunk-2UUKKXBD.mjs +10 -0
  165. package/dist/chunk-2VY4FAOY.mjs +10 -0
  166. package/dist/chunk-2WAKHFPS.mjs +10 -0
  167. package/dist/chunk-34TYNTXM.mjs +10 -0
  168. package/dist/chunk-3CWP2VCB.mjs +10 -0
  169. package/dist/chunk-3FYY26ED.mjs +10 -0
  170. package/dist/chunk-3HKG74G4.mjs +0 -0
  171. package/dist/chunk-3UH5CQQF.mjs +10 -0
  172. package/dist/chunk-3W6RWDIE.mjs +10 -0
  173. package/dist/chunk-44OUOGJ4.mjs +10 -0
  174. package/dist/chunk-4N6CLPAY.mjs +10 -0
  175. package/dist/chunk-4NYPVKDO.mjs +10 -0
  176. package/dist/chunk-4PYEGHW5.mjs +10 -0
  177. package/dist/chunk-4QEH5CGK.mjs +10 -0
  178. package/dist/chunk-4SW77SGW.mjs +10 -0
  179. package/dist/chunk-4WW2MVQN.mjs +0 -0
  180. package/dist/chunk-4ZJMZB5B.mjs +10 -0
  181. package/dist/chunk-545KDVGI.mjs +10 -0
  182. package/dist/chunk-54IAJ3RI.mjs +0 -0
  183. package/dist/chunk-566SP7NE.mjs +10 -0
  184. package/dist/chunk-5ANNWMLJ.mjs +0 -0
  185. package/dist/chunk-5BAHJXOI.mjs +10 -0
  186. package/dist/chunk-5HXTXIE5.mjs +10 -0
  187. package/dist/chunk-5IC46G5J.mjs +10 -0
  188. package/dist/chunk-5KD2MNNX.mjs +10 -0
  189. package/dist/chunk-5ODZPQL2.mjs +10 -0
  190. package/dist/chunk-5PQHOVGX.mjs +0 -0
  191. package/dist/chunk-5ULL6IBX.mjs +10 -0
  192. package/dist/chunk-5YHNHEDK.mjs +0 -0
  193. package/dist/chunk-63KRQW56.mjs +10 -0
  194. package/dist/chunk-66CUIXA6.mjs +10 -0
  195. package/dist/chunk-66NJ7EYY.mjs +10 -0
  196. package/dist/chunk-6F66XVOA.mjs +0 -0
  197. package/dist/chunk-6IRWW75G.mjs +10 -0
  198. package/dist/chunk-6IX6BM7C.mjs +0 -0
  199. package/dist/chunk-6XARU7F2.mjs +0 -0
  200. package/dist/chunk-6YQHZ5RZ.mjs +0 -0
  201. package/dist/chunk-6Z6HOW6T.mjs +10 -0
  202. package/dist/chunk-6ZFBX7C7.mjs +10 -0
  203. package/dist/chunk-6ZQE5SHE.mjs +10 -0
  204. package/dist/chunk-6ZV4UYEG.mjs +10 -0
  205. package/dist/chunk-77BAFSDX.mjs +10 -0
  206. package/dist/chunk-7AQAC6QK.mjs +10 -0
  207. package/dist/chunk-7AY6C5M5.mjs +10 -0
  208. package/dist/chunk-7PRJIPFA.mjs +10 -0
  209. package/dist/chunk-7ZYMMUDM.mjs +10 -0
  210. package/dist/chunk-A24DWFQ2.mjs +10 -0
  211. package/dist/chunk-A6ZQQSAX.mjs +10 -0
  212. package/dist/chunk-AC7OXVHA.mjs +10 -0
  213. package/dist/chunk-AGUSZG6K.mjs +0 -0
  214. package/dist/chunk-AGYQLGBZ.mjs +10 -0
  215. package/dist/chunk-AKES5B6C.mjs +10 -0
  216. package/dist/chunk-AMQX3KZR.mjs +10 -0
  217. package/dist/chunk-AMW7LGCF.mjs +10 -0
  218. package/dist/chunk-AMYRLAIC.mjs +10 -0
  219. package/dist/chunk-AQYBKDT2.mjs +16 -0
  220. package/dist/chunk-AUOQSTS5.mjs +10 -0
  221. package/dist/chunk-AV4ZP5SY.mjs +10 -0
  222. package/dist/chunk-AZRPXTYJ.mjs +10 -0
  223. package/dist/chunk-B7PSE5KC.mjs +10 -0
  224. package/dist/chunk-BED7T5CL.mjs +10 -0
  225. package/dist/chunk-BGMVPFYK.mjs +10 -0
  226. package/dist/chunk-BJVFZYUV.mjs +10 -0
  227. package/dist/chunk-BKDQLDOK.mjs +10 -0
  228. package/dist/chunk-BLHN7I5Z.mjs +0 -0
  229. package/dist/chunk-BTVDMO5C.mjs +10 -0
  230. package/dist/chunk-BU5H25MV.mjs +10 -0
  231. package/dist/chunk-C342HL26.mjs +0 -0
  232. package/dist/chunk-C5P23FUW.mjs +10 -0
  233. package/dist/chunk-C6OMLVIQ.mjs +0 -0
  234. package/dist/chunk-CAWUDHAE.mjs +10 -0
  235. package/dist/chunk-CFDKFUTO.mjs +10 -0
  236. package/dist/chunk-CFLEBB5T.mjs +10 -0
  237. package/dist/chunk-CFRTAJP2.mjs +0 -0
  238. package/dist/chunk-CGFLGZL4.mjs +10 -0
  239. package/dist/chunk-CHTLOFCT.mjs +10 -0
  240. package/dist/chunk-CPSUI4IW.mjs +10 -0
  241. package/dist/chunk-CSPZMYVG.mjs +10 -0
  242. package/dist/chunk-CV6JQGJ3.mjs +10 -0
  243. package/dist/chunk-CWPFUB7B.mjs +10 -0
  244. package/dist/chunk-D3IZ4HBL.mjs +10 -0
  245. package/dist/chunk-D5EEZT5J.mjs +10 -0
  246. package/dist/chunk-DD5FWULD.mjs +10 -0
  247. package/dist/chunk-DECHIERQ.mjs +10 -0
  248. package/dist/chunk-DIHILOKU.mjs +10 -0
  249. package/dist/chunk-DOL6RDMF.mjs +10 -0
  250. package/dist/chunk-DRYSJSKA.mjs +10 -0
  251. package/dist/chunk-DY6WY36N.mjs +0 -0
  252. package/dist/chunk-E3PFPOHX.mjs +0 -0
  253. package/dist/chunk-E6VOSF6Z.mjs +10 -0
  254. package/dist/chunk-EA6GA4WC.mjs +10 -0
  255. package/dist/chunk-EK3RIYMV.mjs +10 -0
  256. package/dist/chunk-ELXWR5TS.mjs +10 -0
  257. package/dist/chunk-EMCEJKBJ.mjs +10 -0
  258. package/dist/chunk-ENDOKA57.mjs +10 -0
  259. package/dist/chunk-EU75HMPG.mjs +10 -0
  260. package/dist/chunk-EX2LI2CV.mjs +10 -0
  261. package/dist/chunk-EZXMEGV7.mjs +0 -0
  262. package/dist/chunk-F2HESRBD.mjs +10 -0
  263. package/dist/chunk-F2X474RV.mjs +10 -0
  264. package/dist/chunk-F7PGMOQF.mjs +10 -0
  265. package/dist/chunk-FJ2JRD3H.mjs +10 -0
  266. package/dist/chunk-FKYHERP4.mjs +0 -0
  267. package/dist/chunk-FP5EWPOF.mjs +10 -0
  268. package/dist/chunk-FRZTJBLY.mjs +10 -0
  269. package/dist/chunk-FTYXFTJV.mjs +10 -0
  270. package/dist/chunk-FXCHST4Z.mjs +10 -0
  271. package/dist/chunk-GCZFXILF.mjs +10 -0
  272. package/dist/chunk-GEZGEZAP.mjs +10 -0
  273. package/dist/chunk-GFLVN5JQ.mjs +10 -0
  274. package/dist/chunk-GKODQS6E.mjs +10 -0
  275. package/dist/chunk-GOSLHCDP.mjs +0 -0
  276. package/dist/chunk-GXOXYPQQ.mjs +10 -0
  277. package/dist/chunk-H44PBNVX.mjs +10 -0
  278. package/dist/chunk-H7OUUCSA.mjs +10 -0
  279. package/dist/chunk-HBBRMEES.mjs +10 -0
  280. package/dist/chunk-HHI7CEUP.mjs +10 -0
  281. package/dist/chunk-HI44JQA7.mjs +10 -0
  282. package/dist/chunk-HLDCVJXD.mjs +10 -0
  283. package/dist/chunk-HONWMHMX.mjs +10 -0
  284. package/dist/chunk-HT55YHTN.mjs +10 -0
  285. package/dist/chunk-HWOMGFBL.mjs +10 -0
  286. package/dist/chunk-HXTAOYOD.mjs +10 -0
  287. package/dist/chunk-I3RGYL4B.mjs +10 -0
  288. package/dist/chunk-I3YGB2BE.mjs +10 -0
  289. package/dist/chunk-IB23KCIW.mjs +10 -0
  290. package/dist/chunk-IHLJTHGQ.mjs +10 -0
  291. package/dist/chunk-ILBAZFBL.mjs +0 -0
  292. package/dist/chunk-INDVRI57.mjs +10 -0
  293. package/dist/chunk-IUQOFRI3.mjs +10 -0
  294. package/dist/chunk-IVVZSESM.mjs +10 -0
  295. package/dist/chunk-IW4GXU75.mjs +10 -0
  296. package/dist/chunk-IYFTU6IC.mjs +10 -0
  297. package/dist/chunk-J3MJZQUJ.mjs +10 -0
  298. package/dist/chunk-J4NO4WYU.mjs +0 -0
  299. package/dist/chunk-J5YWAPLN.mjs +10 -0
  300. package/dist/chunk-J7EAQSKX.mjs +10 -0
  301. package/dist/chunk-J7K7I5U2.mjs +10 -0
  302. package/dist/chunk-JBXZ6ZHP.mjs +10 -0
  303. package/dist/chunk-JDLUGVXG.mjs +10 -0
  304. package/dist/chunk-JI4SJ53O.mjs +11 -0
  305. package/dist/chunk-JJG67M2S.mjs +10 -0
  306. package/dist/chunk-JJPCZOOI.mjs +10 -0
  307. package/dist/chunk-JQ4ZGZPV.mjs +15 -0
  308. package/dist/chunk-JUXBZ2ZN.mjs +10 -0
  309. package/dist/chunk-K6IQ4ALU.mjs +0 -0
  310. package/dist/chunk-K6X2BHPP.mjs +10 -0
  311. package/dist/chunk-KCHAWPUN.mjs +10 -0
  312. package/dist/chunk-KEVERVHK.mjs +10 -0
  313. package/dist/chunk-KG5PDPBK.mjs +10 -0
  314. package/dist/chunk-KKJ6XIU3.mjs +10 -0
  315. package/dist/chunk-KPEONVLU.mjs +10 -0
  316. package/dist/chunk-KUEDQO7P.mjs +10 -0
  317. package/dist/chunk-KY3JKXSX.mjs +10 -0
  318. package/dist/chunk-LQMEFFFM.mjs +10 -0
  319. package/dist/chunk-LZFTBNPW.mjs +10 -0
  320. package/dist/chunk-M5M3EPG5.mjs +10 -0
  321. package/dist/chunk-MEYMETYC.mjs +11 -0
  322. package/dist/chunk-MEZNZ5W6.mjs +10 -0
  323. package/dist/chunk-MFH2E2GU.mjs +10 -0
  324. package/dist/chunk-MI7DCFP2.mjs +10 -0
  325. package/dist/chunk-MIHIAPBG.mjs +10 -0
  326. package/dist/chunk-MLNPTVVX.mjs +10 -0
  327. package/dist/chunk-MRJFGHFW.mjs +10 -0
  328. package/dist/chunk-MUNFBB7D.mjs +0 -0
  329. package/dist/chunk-MVK5CB64.mjs +10 -0
  330. package/dist/chunk-MXKP7NQ4.mjs +10 -0
  331. package/dist/chunk-MZ4O6LWG.mjs +0 -0
  332. package/dist/chunk-N2XGJKZG.mjs +10 -0
  333. package/dist/chunk-N5RZGO7Y.mjs +10 -0
  334. package/dist/chunk-N7MTFSWR.mjs +10 -0
  335. package/dist/chunk-NA3IF43N.mjs +10 -0
  336. package/dist/chunk-NGZRN4SF.mjs +10 -0
  337. package/dist/chunk-NHM3H5JU.mjs +0 -0
  338. package/dist/chunk-NO55UIGK.mjs +0 -0
  339. package/dist/chunk-NRKHWSOP.mjs +0 -0
  340. package/dist/chunk-NSC53QWT.mjs +10 -0
  341. package/dist/chunk-NV7KQVPE.mjs +10 -0
  342. package/dist/chunk-O4VZ6XEP.mjs +10 -0
  343. package/dist/chunk-O57ZEY3V.mjs +0 -0
  344. package/dist/chunk-O66FNQSB.mjs +10 -0
  345. package/dist/chunk-O7XK2WIX.mjs +10 -0
  346. package/dist/chunk-OAY74XPB.mjs +10 -0
  347. package/dist/chunk-OC42IZG2.mjs +10 -0
  348. package/dist/chunk-OLJWK3LS.mjs +10 -0
  349. package/dist/chunk-OMT6ZWSV.mjs +11 -0
  350. package/dist/chunk-OO7BXL2N.mjs +10 -0
  351. package/dist/chunk-P44XZ4PV.mjs +10 -0
  352. package/dist/chunk-P5GO3XIS.mjs +10 -0
  353. package/dist/chunk-PAQQ7MQG.mjs +10 -0
  354. package/dist/chunk-PBFIKNYZ.mjs +10 -0
  355. package/dist/chunk-PBO4SFGS.mjs +10 -0
  356. package/dist/chunk-PF3OQKXP.mjs +10 -0
  357. package/dist/chunk-PHZZLBH3.mjs +10 -0
  358. package/dist/chunk-PZTVDABF.mjs +0 -0
  359. package/dist/chunk-Q5UMLFN3.mjs +10 -0
  360. package/dist/chunk-QAUEG3EX.mjs +0 -0
  361. package/dist/chunk-QBJDGBTU.mjs +0 -0
  362. package/dist/chunk-QMDDCVAF.mjs +10 -0
  363. package/dist/chunk-QNBBJ5HC.mjs +11 -0
  364. package/dist/chunk-R32OJDN2.mjs +10 -0
  365. package/dist/chunk-RC7QITNV.mjs +10 -0
  366. package/dist/chunk-RCBUNCHV.mjs +10 -0
  367. package/dist/chunk-RFTDIXEG.mjs +10 -0
  368. package/dist/chunk-RJC3HQDZ.mjs +10 -0
  369. package/dist/chunk-RJWPSJX2.mjs +10 -0
  370. package/dist/chunk-RMUV6NJJ.mjs +10 -0
  371. package/dist/chunk-ROHLZINC.mjs +10 -0
  372. package/dist/chunk-RSKKEGJZ.mjs +10 -0
  373. package/dist/chunk-RT4LMB6X.mjs +10 -0
  374. package/dist/chunk-RXSYDMT6.mjs +10 -0
  375. package/dist/chunk-S3V4OOC3.mjs +10 -0
  376. package/dist/chunk-SAZLJ66W.mjs +10 -0
  377. package/dist/chunk-SMAYNDQQ.mjs +10 -0
  378. package/dist/chunk-TAROK7TO.mjs +10 -0
  379. package/dist/chunk-TAYP2OGC.mjs +10 -0
  380. package/dist/chunk-TBSQUJ67.mjs +10 -0
  381. package/dist/chunk-TDXALNX3.mjs +10 -0
  382. package/dist/chunk-TEQE6WCH.mjs +10 -0
  383. package/dist/chunk-THRAJMLX.mjs +10 -0
  384. package/dist/chunk-TI5RR7KX.mjs +10 -0
  385. package/dist/chunk-TIHKHXTS.mjs +10 -0
  386. package/dist/chunk-TJEK54BW.mjs +10 -0
  387. package/dist/chunk-TK4QXU3W.mjs +10 -0
  388. package/dist/chunk-TKQOQVZD.mjs +10 -0
  389. package/dist/chunk-TO2TQ2LE.mjs +10 -0
  390. package/dist/chunk-TO6OQF2Y.mjs +10 -0
  391. package/dist/chunk-TZ4MVY4E.mjs +10 -0
  392. package/dist/chunk-U2ODAIZG.mjs +10 -0
  393. package/dist/chunk-U4K44ZHN.mjs +10 -0
  394. package/dist/chunk-UCNHDT36.mjs +10 -0
  395. package/dist/chunk-UCZZLAPB.mjs +10 -0
  396. package/dist/chunk-UQJGSVXP.mjs +10 -0
  397. package/dist/chunk-USMC34OO.mjs +10 -0
  398. package/dist/chunk-UTQ7AIPM.mjs +0 -0
  399. package/dist/chunk-UUBOEBYZ.mjs +10 -0
  400. package/dist/chunk-V3L4SVVF.mjs +10 -0
  401. package/dist/chunk-VCIX4HG7.mjs +0 -0
  402. package/dist/chunk-VDUFLHKK.mjs +10 -0
  403. package/dist/chunk-VG7J427T.mjs +10 -0
  404. package/dist/chunk-VHDXSFQC.mjs +10 -0
  405. package/dist/chunk-VLQ4S7XC.mjs +10 -0
  406. package/dist/chunk-VTX6R6KM.mjs +10 -0
  407. package/dist/chunk-VXB5SVQC.mjs +10 -0
  408. package/dist/chunk-W6QO7FPZ.mjs +10 -0
  409. package/dist/chunk-WAFYFWH4.mjs +0 -0
  410. package/dist/chunk-WAOWR7MR.mjs +10 -0
  411. package/dist/chunk-WL27JGVG.mjs +10 -0
  412. package/dist/chunk-WOVAT6U4.mjs +10 -0
  413. package/dist/chunk-WSCZ34XO.mjs +10 -0
  414. package/dist/chunk-WSQGB4ZE.mjs +0 -0
  415. package/dist/chunk-WWSGOGLA.mjs +10 -0
  416. package/dist/chunk-X3AXUU3H.mjs +10 -0
  417. package/dist/chunk-X3OCHEQM.mjs +12 -0
  418. package/dist/chunk-X7DI4I2U.mjs +10 -0
  419. package/dist/chunk-XB657BXX.mjs +10 -0
  420. package/dist/chunk-XBBPWSJI.mjs +0 -0
  421. package/dist/chunk-XJGQXVMR.mjs +10 -0
  422. package/dist/chunk-XPISSX5R.mjs +10 -0
  423. package/dist/chunk-XTH6B5FE.mjs +10 -0
  424. package/dist/chunk-XVBOKL6D.mjs +10 -0
  425. package/dist/chunk-XWLESSHN.mjs +10 -0
  426. package/dist/chunk-XXANV3FM.mjs +10 -0
  427. package/dist/chunk-XZ2VSOJD.mjs +29 -0
  428. package/dist/chunk-Y4DRSGEJ.mjs +10 -0
  429. package/dist/chunk-Y6XQJ4X2.mjs +10 -0
  430. package/dist/chunk-YB3KW7JC.mjs +10 -0
  431. package/dist/chunk-YCI6BEXQ.mjs +10 -0
  432. package/dist/chunk-YGSCHWU3.mjs +10 -0
  433. package/dist/chunk-YIGT3OP2.mjs +10 -0
  434. package/dist/chunk-YOBESAXG.mjs +10 -0
  435. package/dist/chunk-YS3Y5KGV.mjs +10 -0
  436. package/dist/chunk-YT36W3OS.mjs +10 -0
  437. package/dist/chunk-YV3WI6OV.mjs +10 -0
  438. package/dist/chunk-YV5CNDCW.mjs +0 -0
  439. package/dist/chunk-YVYMYKYN.mjs +10 -0
  440. package/dist/chunk-ZANUFNOL.mjs +0 -0
  441. package/dist/chunk-ZGRRD3TU.mjs +10 -0
  442. package/dist/chunk-ZLAY7NNY.mjs +10 -0
  443. package/dist/chunk-ZLDT2KDZ.mjs +10 -0
  444. package/dist/chunk-ZNN43VZV.mjs +10 -0
  445. package/dist/chunk-ZREX7XOO.mjs +10 -0
  446. package/dist/chunk-ZRWDMNNY.mjs +10 -0
  447. package/dist/chunk-ZVODDLGL.mjs +10 -0
  448. package/dist/hooks/useDevice.mjs +1 -0
  449. package/dist/hooks/useI18n.mjs +1 -0
  450. package/dist/hooks/useImage.mjs +1 -0
  451. package/dist/hooks/useIntersectionObserver.mjs +1 -0
  452. package/dist/hooks/useIsFirstRender.mjs +1 -0
  453. package/dist/hooks/useIsTouchDevice.mjs +1 -0
  454. package/dist/hooks/useLiveInteractionModality.mjs +1 -0
  455. package/dist/hooks/useLocalStorage.mjs +1 -0
  456. package/dist/hooks/useMedia.mjs +1 -0
  457. package/dist/hooks/useMutationObserver.mjs +1 -0
  458. package/dist/hooks/usePortalContainer.mjs +1 -0
  459. package/dist/hooks/usePreventFocus.mjs +1 -0
  460. package/dist/hooks/useResizeObserver.mjs +1 -0
  461. package/dist/hooks/useTextSelection.mjs +1 -0
  462. package/dist/hooks/useUndoRedo.mjs +1 -0
  463. package/dist/index.d.ts +811 -70
  464. package/dist/index.js +21 -21
  465. package/dist/index.mjs +1 -43
  466. package/dist/messageIds.mjs +1 -0
  467. package/dist/react-aria.d.ts +133 -133
  468. package/dist/react-aria.mjs +1 -0
  469. package/dist/react-stately.d.ts +82 -82
  470. package/dist/react-stately.mjs +1 -0
  471. package/dist/utils/a11y.mjs +1 -0
  472. package/dist/utils/classNames.mjs +1 -0
  473. package/dist/utils/colors.mjs +1 -0
  474. package/dist/utils/constants.mjs +10 -0
  475. package/dist/utils/devWarn.mjs +1 -0
  476. package/dist/utils/dom.mjs +1 -0
  477. package/dist/utils/invariant.mjs +1 -0
  478. package/dist/utils/isInIframe.mjs +1 -0
  479. package/dist/utils/isInShadowDOM.mjs +1 -0
  480. package/dist/utils/isRect.mjs +1 -0
  481. package/dist/utils/keyboards.mjs +1 -0
  482. package/dist/utils/math.mjs +1 -0
  483. package/dist/utils/objects.mjs +1 -0
  484. package/dist/utils/onDropOrPaste.mjs +1 -0
  485. package/dist/utils/overlays.mjs +1 -0
  486. package/dist/utils/reactAriaCompat.mjs +1 -0
  487. package/dist/utils/reactAriaComponentsCompat.mjs +1 -0
  488. package/dist/utils/resolveAriaLabelAttrs.mjs +1 -0
  489. package/dist/utils/resolvePublicUrl.mjs +10 -0
  490. package/dist/utils/strings.mjs +1 -0
  491. package/dist/utils/style.mjs +1 -0
  492. package/dist/utils/svgs.mjs +1 -0
  493. package/dist/utils/validations.mjs +1 -0
  494. package/intl/ar.json +2 -2
  495. package/intl/cs.json +2 -2
  496. package/intl/cy.json +4 -4
  497. package/intl/da.json +3 -3
  498. package/intl/de.json +3 -3
  499. package/intl/el.json +2 -2
  500. package/intl/en-GB.json +2 -2
  501. package/intl/en.json +2 -2
  502. package/intl/fi.json +3 -3
  503. package/intl/fr-CA.json +1 -1
  504. package/intl/fr.json +2 -2
  505. package/intl/he.json +3 -3
  506. package/intl/hr.json +3 -3
  507. package/intl/id.json +3 -3
  508. package/intl/ja.json +2 -2
  509. package/intl/ko.json +1 -1
  510. package/intl/ms.json +2 -2
  511. package/intl/nb-NO.json +3 -3
  512. package/intl/nl.json +4 -4
  513. package/intl/pt-PT.json +1 -1
  514. package/intl/pt.json +3 -3
  515. package/intl/ru.json +2 -2
  516. package/intl/sk.json +2 -2
  517. package/intl/sl.json +4 -4
  518. package/intl/sv.json +3 -3
  519. package/intl/th.json +1 -1
  520. package/intl/tr.json +3 -3
  521. package/intl/uk.json +1 -1
  522. package/intl/zh-Hant.json +2 -2
  523. package/messages.json +2 -2
  524. package/package.json +8 -5
  525. package/sbom.json +6 -6
@@ -0,0 +1,11 @@
1
+ import {a as a$e}from'./chunk-JBXZ6ZHP.mjs';import {a as a$6}from'./chunk-63KRQW56.mjs';import {a as a$2}from'./chunk-UCNHDT36.mjs';import {a as a$b}from'./chunk-HI44JQA7.mjs';import {a as a$d}from'./chunk-2WAKHFPS.mjs';import {a as a$c}from'./chunk-O7XK2WIX.mjs';import {a as a$a}from'./chunk-THRAJMLX.mjs';import {a as a$4}from'./chunk-MLNPTVVX.mjs';import {a as a$8}from'./chunk-TDXALNX3.mjs';import {a as a$9,b as b$2}from'./chunk-RSKKEGJZ.mjs';import {a as a$5}from'./chunk-K6X2BHPP.mjs';import {a as a$f}from'./chunk-BGMVPFYK.mjs';import {a as a$7}from'./chunk-YB3KW7JC.mjs';import {d}from'./chunk-AQYBKDT2.mjs';import {b,c}from'./chunk-TZ4MVY4E.mjs';import {c as c$1}from'./chunk-JDLUGVXG.mjs';import {a as a$3,b as b$1}from'./chunk-AUOQSTS5.mjs';import {a}from'./chunk-FXCHST4Z.mjs';import {a as a$1}from'./chunk-4QEH5CGK.mjs';import _,{useContext,useMemo,useRef,useCallback,useEffect,useImperativeHandle,useState}from'react';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {PlusIcon}from'@baseline-ui/icons/12';import {themeVars}from'@baseline-ui/tokens';import {useGranularEffect}from'granular-hooks';import Ze from'just-camel-case';import*as st from'comlink';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var bt={node:null,setNode:()=>{},coordinates:null,setCoordinates:()=>{},displayId:void 0,setDisplayId:()=>{},boundsRef:{current:null},isDisabled:false,cursorNode:null,setCursorNode:()=>{},children:null,setChildren:()=>{}},p=_.createContext(bt),ke=_.memo(({children:e,isDisabled:t=false})=>{let[n,r]=_.useState(null),[a,i]=_.useState(null),[o,d]=_.useState(null),s=_.useRef(null),[l,g]=_.useState(null),[f,k]=_.useState(),c=_.useMemo(()=>({node:n,setNode:r,coordinates:l,setCoordinates:g,displayId:f,setDisplayId:k,boundsRef:s,isDisabled:t,cursorNode:a,setCursorNode:i,children:o,setChildren:d}),[n,l,f,g,r,s,t,a,i,o,d]);return jsx(p.Provider,{value:c,children:e})});ke.displayName="PointPicker";var ze="m0xg2me";var Ee="m0xg2md _1yep5z6ig _1yep5z6ih _1yep5z6ii _1yep5z6m1 _1yep5z6m0 _1yep5z6hc",_e="m0xg2mj",Re="_1yep5z6f6",Ie="m0xg2mk m0xg2mj",De=a({defaultClassName:"m0xg2m0",variantClassNames:{isDisabled:{true:"m0xg2m1",false:"m0xg2m2"},isIndicatorVisible:{true:"m0xg2m3",false:"m0xg2m4"}},defaultVariants:{},compoundVariants:[[{isDisabled:false,isIndicatorVisible:true},"m0xg2m5"],[{isDisabled:false,isIndicatorVisible:false},"m0xg2m6"]]}),Me="m0xg2m8",Ne="m0xg2mb",X="m0xg2ma _1yep5z6hd _1yep5z6lz",Ae="m0xg2m9 _1yep5z6iy _1yep5z6iz _1yep5z6j0 _1yep5z6h4 _1yep5z6lz _1yep5z6id _1yep5z6ie _1yep5z6if",Te="m0xg2m7",Le="m0xg2mc",Se="m0xg2mf";var W=a$1(Ee,"BaselineUI-PointPicker-GridLine"),zt=({coordinates:e})=>jsxs(Fragment,{children:[jsx("div",{className:W,"data-grid-line-type":"vertical",style:{height:e.y-5,transform:`translate(${e.x}px, 0) translate(-1px, 0) scaleX(0.5)`}}),jsx("div",{className:W,"data-grid-line-type":"vertical",style:{height:`calc(100% - ${e.y+4}px)`,transform:`translate(${e.x}px, ${e.y+5}px) translate(-1px, 0) scaleX(0.5)`}})]}),Et=({coordinates:e})=>jsxs(Fragment,{children:[jsx("div",{className:W,"data-grid-line-type":"horizontal",style:{width:e.x-5,transform:`translate(0, ${e.y}px) translate(0, -1px) scaleY(0.5)`}}),jsx("div",{className:W,"data-grid-line-type":"horizontal",style:{width:`calc(100% - ${e.x+4}px)`,transform:`translate(${e.x+5}px, ${e.y}px) translate(0, -1px) scaleY(0.5)`}})]}),Oe=({gridLines:e})=>{let{isDisabled:t,boundsRef:n,coordinates:r}=useContext(p),a=useMemo(()=>{let i=typeof e=="function"?e({coordinates:r,boundingRect:n.current}):e;return typeof i=="boolean"?i?r:void 0:i?.coordinates},[e,r,n]);return a&&!t?jsxs(Fragment,{children:[jsx(zt,{coordinates:a}),jsx(Et,{coordinates:a})]}):null};function He({coordinates:e,setCoordinates:t,boundsRef:n,onKeyDown:r,onKeyUp:a}){let{isDisabled:i}=useContext(p);return a$f({isDisabled:i,onKeyDown:o=>{r?.(o);let d=o.shiftKey?10:1,s=n.current;if(!s||!e)return;let l;switch(o.key){case "ArrowRight":{o.preventDefault(),l={x:a$e(e.x+d,0,s.width),y:a$e(e.y,0,s.height)};break}case "ArrowLeft":{o.preventDefault(),l={x:a$e(e.x-d,0,s.width),y:a$e(e.y,0,s.height)};break}case "ArrowDown":{o.preventDefault(),l={x:a$e(e.x,0,s.width),y:a$e(e.y+d,0,s.height)};break}case "ArrowUp":{o.preventDefault(),l={x:a$e(e.x,0,s.width),y:a$e(e.y-d,0,s.height)};break}case "Home":{o.preventDefault(),l={x:0,y:a$e(e.y,0,s.height)};break}case "End":{o.preventDefault(),l={x:s.width,y:a$e(e.y,0,s.height)};break}case "PageUp":{o.preventDefault(),l={x:a$e(e.x,0,s.width),y:0};break}case "PageDown":{o.preventDefault(),l={x:a$e(e.x,0,s.width),y:s.height};break}default:{o.continuePropagation();return}}l&&t(l);},onKeyUp:a})}function Ue(){let{node:e,coordinates:t}=useContext(p);return useMemo(()=>{if(!e||!t)return {x:0,y:0};let{left:n,top:r}=e.getBoundingClientRect();return {x:t.x+n,y:t.y+r}},[t,e])}var{color:Be}=themeVars,$e=_.forwardRef(({modality:e},t)=>e==="keyboard"?jsxs("svg",{width:92,height:92,viewBox:"0 0 92 92",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,className:_e,children:[jsxs("g",{filter:"url(#filter0_d_11407_457970)",children:[jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M49 43V4h-6v39H4v6h39v39h6V49h39v-6H49zm38 5H48v39h-4V48H5v-4h39V5h4v39h39v4zm-5 28v6h-6v6h12V76h-6zm5 11H77v-4h6v-6h4v10zm-77-5v-6H4v12h12v-6h-6zm5 5H5V77h4v6h6v4zM76 4v6h6v6h6V4H76zm11 11h-4V9h-6V5h10v10zM4 4v12h6v-6h6V4H4zm11 5H9v6H5V5h10v4z",fill:Be.background.positive.subtle}),jsx("path",{d:"M48 44v4h39v-4H48zm-4 4v39h4V48h-4zM5 44v4h39v-4H5zM44 5v39h4V5h-4zm39 72v6h-6v4h10V77h-4zM9 83v-6H5v10h10v-4H9zM77 5v4h6v6h4V5H77zM5 5v10h4V9h6V5H5z",fill:Be.background.positive.interactive.enabled})]}),jsx("defs",{children:jsxs("filter",{id:"filter0_d_11407_457970",x:0,y:0,width:92,height:92,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB",children:[jsx("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),jsx("feColorMatrix",{in:"SourceAlpha",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),jsx("feOffset",{}),jsx("feGaussianBlur",{stdDeviation:2}),jsx("feComposite",{in2:"hardAlpha",operator:"out"}),jsx("feColorMatrix",{values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.4 0"}),jsx("feBlend",{in2:"BackgroundImageFix",result:"effect1_dropShadow_11407_457970"}),jsx("feBlend",{in:"SourceGraphic",in2:"effect1_dropShadow_11407_457970",result:"shape"})]})})]}):jsx(PlusIcon,{className:Ie,ref:t}));$e.displayName="PointPickerIndicatorIcon";var Tt=({trailingElement:e})=>{let{cursorNode:t}=useContext(p),[n,r]=useState({width:0,height:0});return useEffect(()=>{if(!t)return;let a=t.getBoundingClientRect();r(a);let i=new ResizeObserver(o=>{r({width:o[0].contentRect.width,height:o[0].contentRect.height});});return i.observe(t),()=>{i.disconnect();}},[t]),e?jsx(a$c,{position:"absolute",style:{left:0,top:0,zIndex:0,transform:`translate(${n.width/2}px, ${n.height/2}px)`},className:"BaselineUI-PointPickerContent-TrailingElement",children:e}):null},J=_.forwardRef(({renderTrailingElement:e,renderCursor:t},n)=>{let{coordinates:r,isDisabled:a,node:i}=useContext(p),o=a$2({ownerDocument:a$3(i)}),d=!!(r&&!a),s=useMemo(()=>e?.(),[e]),l=Ue(),g=useMemo(()=>{if(!r)return null;let f=t?.({coordinates:r,modality:o});return f===void 0?jsx($e,{modality:o}):f},[t,r,o]);return d?jsxs(a$4,{style:{left:l.x,top:l.y},className:a$1(Te,"BaselineUI-PointPickerContent-Cursor"),ref:n,children:[g,s?jsx(Tt,{trailingElement:s}):null]}):null});J.displayName="PointPickerIndicator";var Ke=_.forwardRef(({children:e,className:t,style:n,"data-block-id":r,"data-block-class":a,onFocusChange:i,onBlur:o,onFocus:d$1,onKeyDown:s,onKeyUp:l,gridLines:g=true,elementHandle:f,onMove:k,onPress:c$1,onPressStart:P,onPressEnd:b$1,renderTrailingElement:C,renderCursor:z},M)=>{let{setNode:w,node:E,coordinates:x,setCoordinates:R,displayId:G,boundsRef:I,isDisabled:h,setCursorNode:at,setChildren:j}=useContext(p),S=useRef(null),ae=useRef(null),le=a$2({ownerDocument:a$3(E)}),N=useCallback(u=>{R(u??null),k?.({coordinates:u,boundingRect:I.current});},[R,k,I]);useEffect(()=>{if(!h)return j(e),()=>{j(null);}},[e,h,j]),useEffect(()=>{let u=S.current;if(!u||h)return;let ce=()=>{let D=u.getBoundingClientRect();I.current=D;},H=D=>{let O=I.current;if(!O)return;let xt="clientX"in D?D.clientX:D.touches[0].clientX,vt="clientY"in D?D.clientY:D.touches[0].clientY,Pt={x:a$e(xt-O.left,0,O.width),y:a$e(vt-O.top,0,O.height)};N(Pt);},ue=()=>{N(null);};return u.addEventListener("mousemove",H),u.addEventListener("touchmove",H),u.addEventListener("mouseenter",ce),u.addEventListener("mouseleave",ue),()=>{u.removeEventListener("mousemove",H),u.removeEventListener("touchmove",H),u.removeEventListener("mouseenter",ce),u.removeEventListener("mouseleave",ue);}},[I,h,N]);let{pressProps:lt}=d({isDisabled:h,onPress:u=>{u.pointerType==="keyboard"?x&&c$1?.({...u,x:x.x,y:x.y}):c$1?.(u);},onPressStart:P,onPressEnd:b$1}),{focusProps:ct,isFocusVisible:ut,isFocused:dt}=a$5();a$6({ref:ae,isDisabled:h}),useImperativeHandle(f,()=>({focus:()=>{h||S.current?.focus();}}));let{focusProps:mt}=a$7({isDisabled:h,onFocusChange:i,onFocus:d$1,onBlur:o});function pt(){le==="keyboard"&&setTimeout(()=>{let u=S.current?.getBoundingClientRect();u&&(I.current=u,N({x:a$e(u.width/2,0,u.width),y:a$e(u.height/2,0,u.height)}));},0);}function ft(){N(null);}let{keyboardProps:ht}=He({coordinates:x,setCoordinates:N,boundsRef:I,onKeyDown:s,onKeyUp:l});a$8({isDisabled:h,ref:S,onInteractOutside:()=>{N(null);}});let yt=!!(x&&!h),gt=a$9({"data-focus-visible":ut,"data-focused":dt,"data-disabled":h,"data-block-id":r,"data-block-class":a,"data-active":x&&!h,"data-modality":le});return jsxs(Fragment,{children:[jsx(J,{renderTrailingElement:C,renderCursor:z,ref:at}),jsxs("div",{...c(ct,mt,{onFocus:pt,onBlur:ft},h?{}:c(ht,lt)),ref:b(M,S,w),className:a$1(De({isDisabled:!!h,isIndicatorVisible:!!yt}),"BaselineUI-PointPicker-Content",t),tabIndex:h?void 0:0,style:n,"aria-controls":G,"data-testid":"point-picker-content",...gt,children:[jsx(Oe,{gridLines:g}),jsx("div",{className:ze,ref:ae,children:e})]})]})});Ke.displayName="PointPickerContent";function Xe(e,t,n){let[r,a]=useState(0),i=o=>{a(o),n();};return useGranularEffect(()=>{if(!e||t==="trailing")return;let o=new ResizeObserver(d=>{i(d[0].contentRect.width);});return i(e.getBoundingClientRect().width),o.observe(e),()=>{o.disconnect();}},[e,t],[n]),r}function jt(e,t){return t==="indicator"?e:e?.querySelector(".BaselineUI-PointPickerContent-TrailingElement")??null}var ee=_.forwardRef(({children:e,className:t,crossOffset:n,offset:r,placement:a="bottom start",anchorElement:i="indicator"},o)=>{let d=useRef(null),{cursorNode:s,coordinates:l}=useContext(p),g=Xe(s,i,()=>{c();}),f=jt(s,i),{overlayProps:k,updatePosition:c}=a$a({overlayRef:d,placement:a,targetRef:{get current(){return f}},crossOffset:n??g,offset:r});return useGranularEffect(()=>{c();},[l,n,r],[c]),l?jsx(a$4,{className:a$1(Se,t),ref:o,children:jsx("div",{ref:d,...k,children:e})}):null});ee.displayName="Floater";var tt=8,Xt=7,qt=7,te=_.memo(({children:e,scale:t,renderMagnifierContent:n})=>{let r=useRef(null),{coordinates:a,boundsRef:i,node:o}=useContext(p),d=useRef([]);a$6({ref:r}),useEffect(()=>{if(!r.current||n)return;let g=r.current.querySelectorAll("canvas"),f=[],k=r.current.ownerDocument;for(let c of g){let P=c.getContext("2d");if(!P)continue;let b=c.clientWidth,C=c.clientHeight,z=c.width,M=c.height,w=P.getImageData(0,0,z,M);f.push({el:c,width:z,height:M,image:w});let E=k.createElement("canvas");E.width=z,E.height=M;let x=E.getContext("2d");x&&x.drawImage(c,0,0),c.width=b*t,c.height=C*t,c.style.width=`${b}px`,c.style.height=`${C}px`,P.scale(t,t),P.drawImage(E,0,0,b,C);}return d.current=f,()=>{for(let{el:c,width:P,height:b,image:C}of d.current)c.width=P,c.height=b,c.getContext("2d")?.putImageData(C,0,0);}},[o,t,n]);let s=useMemo(()=>n?n({coordinates:a,boundingRect:i.current,children:e}):e?_.cloneElement(e,{key:"magnifier-content"}):null,[n,a,i,e]),l=useMemo(()=>!i.current||!a?null:{x:a.x/i.current.width,y:a.y/i.current.height},[i,a]);return l?jsx("div",{style:{left:0,transform:`scale(${t}) translate(calc(-${l.x*100}% + ${tt*Xt/(2*t)}px), calc(-${l.y*100}% + ${tt*qt/(2*t)}px))`},className:a$1(Le,"BaselineUI-PointPickerDisplay-Magnifier"),children:jsx("div",{style:Jt(o),ref:r,inert:"true",children:s})}):null});te.displayName="Magnifier";function Zt(e){let t=[];for(let n=0;n<e.length;n++){let r=e[n],a=e.getPropertyValue(r);a&&t.push([r,a]);}for(let n of e)if(n.startsWith("--")){let r=e.getPropertyValue(n);r&&t.push([n,r]);}return Object.fromEntries(t)}function Jt(e){if(!e)return {};let n=b$1(e).getComputedStyle(e),r=e.getBoundingClientRect(),a={...Zt(n),position:"static",margin:"0px",left:"0px",top:"0px",transform:"none","-webkit-text-fill-color":"inherit","-webkit-text-stroke-color":"inherit",width:`${r.width}px`,height:`${r.height}px`,interactivity:"inert"};return Object.fromEntries(Object.entries(a).map(([i,o])=>i.startsWith("--")?[i,o]:i.startsWith("-")?[a$b(Ze(i)),o]:[Ze(i),o]))}var nn=7,rn=7,on={scale:2},sn={crossOffset:void 0,offset:void 0,placement:"bottom start",anchorElement:"indicator"},rt=_.forwardRef(({className:e,style:t,description:n,magnifier:r=true,"data-block-id":a,"data-block-class":i,floating:o=false,renderMagnifierContent:d},s)=>{let{coordinates:l,boundsRef:g,setDisplayId:f,isDisabled:k,children:c,cursorNode:P}=useContext(p),b=c$1(),C=useMemo(()=>b$2(r,on),[r]),z=useMemo(()=>typeof n=="function"?n({coordinates:l?{x:l.x,y:l.y}:null,boundingRect:g.current}):n,[n,l,g]),M=!k&&!!C&&l,w=useMemo(()=>b$2(o,sn),[o]);useEffect(()=>((!w||w&&P)&&f(b),()=>{f(void 0);}),[P,b,f,w]);let E=jsxs(a$c,{ref:w?void 0:s,className:a$1(Me,"BaselineUI-PointPicker-Display",e),backgroundColor:"background.primary.subtle",boxShadow:"medium",borderRadius:"sm",outlineWidth:1,outlineColor:"border.medium",outlineOffset:-1,outlineStyle:"solid",paddingY:"md",paddingLeft:"md",paddingRight:z?.length?"xl":"md",display:"flex",flexDirection:"row",gap:"lg",alignItems:"center",style:t,id:b,"data-block-id":a,"data-block-class":i,"data-variant":w?"floating":"auto","data-testid":"point-picker-display",children:[C?jsxs("div",{className:Ae,children:[M?jsx(te,{scale:C.scale,renderMagnifierContent:d,children:c}):null,Array.from({length:nn*rn}).map((x,R)=>R===24?jsx("div",{className:a$1(X,Ne)},R):jsx("div",{className:X},R))]}):null,z?.length?jsx(a$c,{display:"flex",gap:"lg",flexDirection:"column",children:z?.map(({label:x,icon:R},G)=>jsxs(a$c,{display:"flex",gap:"md",flexDirection:"row",color:"text.secondary",alignItems:"center",children:[jsx(R,{size:12,className:Re}),jsx(a$d,{type:"label",size:"sm",children:x})]},x+G))}):null]});return w?jsx(ee,{ref:s,...w,className:"BaselineUI-PointPicker-Floater",children:E}):E});rt.displayName="PointPickerDisplay";function ie(e){let t=new Blob([e],{type:"text/javascript"}),n=URL.createObjectURL(t),r=new Worker(n);return URL.revokeObjectURL(n),r}function oe(){return ie('var Y=Object.defineProperty;var Z=(n,t,e)=>t in n?Y(n,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):n[t]=e;var M=(n,t,e)=>Z(n,typeof t!="symbol"?t+"":t,e);var F=Symbol("Comlink.proxy"),J=Symbol("Comlink.endpoint"),Q=Symbol("Comlink.releaseProxy"),z=Symbol("Comlink.finalizer"),T=Symbol("Comlink.thrown"),B=n=>typeof n=="object"&&n!==null||typeof n=="function",q={canHandle:n=>B(n)&&n[F],serialize(n){let{port1:t,port2:e}=new MessageChannel;return U(n,t),[e,[e]]},deserialize(n){return n.start(),et(n)}},X={canHandle:n=>B(n)&&T in n,serialize({value:n}){let t;return n instanceof Error?t={isError:!0,value:{message:n.message,name:n.name,stack:n.stack}}:t={isError:!1,value:n},[t,[]]},deserialize(n){throw n.isError?Object.assign(new Error(n.value.message),n.value):n.value}},H=new Map([["proxy",q],["throw",X]]);function tt(n,t){for(let e of n)if(t===e||e==="*"||e instanceof RegExp&&e.test(t))return!0;return!1}function U(n,t=globalThis,e=["*"]){t.addEventListener("message",function r(s){if(!s||!s.data)return;if(!tt(e,s.origin)){console.warn(`Invalid origin \'${s.origin}\' for comlink proxy`);return}let{id:o,type:c,path:u}=Object.assign({path:[]},s.data),i=(s.data.argumentList||[]).map(m),a;try{let l=u.slice(0,-1).reduce((f,y)=>f[y],n),h=u.reduce((f,y)=>f[y],n);switch(c){case"GET":a=h;break;case"SET":l[u.slice(-1)[0]]=m(s.data.value),a=!0;break;case"APPLY":a=h.apply(l,i);break;case"CONSTRUCT":{let f=new h(...i);a=at(f)}break;case"ENDPOINT":{let{port1:f,port2:y}=new MessageChannel;U(n,y),a=ot(f,[f])}break;case"RELEASE":a=void 0;break;default:return}}catch(l){a={value:l,[T]:0}}Promise.resolve(a).catch(l=>({value:l,[T]:0})).then(l=>{let[h,f]=_(l);t.postMessage(Object.assign(Object.assign({},h),{id:o}),f),c==="RELEASE"&&(t.removeEventListener("message",r),V(t),z in n&&typeof n[z]=="function"&&n[z]())}).catch(l=>{let[h,f]=_({value:new TypeError("Unserializable return value"),[T]:0});t.postMessage(Object.assign(Object.assign({},h),{id:o}),f)})}),t.start&&t.start()}function nt(n){return n.constructor.name==="MessagePort"}function V(n){nt(n)&&n.close()}function et(n,t){let e=new Map;return n.addEventListener("message",function(s){let{data:o}=s;if(!o||!o.id)return;let c=e.get(o.id);if(c)try{c(o)}finally{e.delete(o.id)}}),I(n,e,[],t)}function S(n){if(n)throw new Error("Proxy has been released and is not useable")}function $(n){return A(n,new Map,{type:"RELEASE"}).then(()=>{V(n)})}var P=new WeakMap,R="FinalizationRegistry"in globalThis&&new FinalizationRegistry(n=>{let t=(P.get(n)||0)-1;P.set(n,t),t===0&&$(n)});function rt(n,t){let e=(P.get(t)||0)+1;P.set(t,e),R&&R.register(n,t,n)}function st(n){R&&R.unregister(n)}function I(n,t,e=[],r=function(){}){let s=!1,o=new Proxy(r,{get(c,u){if(S(s),u===Q)return()=>{st(o),$(n),t.clear(),s=!0};if(u==="then"){if(e.length===0)return{then:()=>o};let i=A(n,t,{type:"GET",path:e.map(a=>a.toString())}).then(m);return i.then.bind(i)}return I(n,t,[...e,u])},set(c,u,i){S(s);let[a,l]=_(i);return A(n,t,{type:"SET",path:[...e,u].map(h=>h.toString()),value:a},l).then(m)},apply(c,u,i){S(s);let a=e[e.length-1];if(a===J)return A(n,t,{type:"ENDPOINT"}).then(m);if(a==="bind")return I(n,t,e.slice(0,-1));let[l,h]=D(i);return A(n,t,{type:"APPLY",path:e.map(f=>f.toString()),argumentList:l},h).then(m)},construct(c,u){S(s);let[i,a]=D(u);return A(n,t,{type:"CONSTRUCT",path:e.map(l=>l.toString()),argumentList:i},a).then(m)}});return rt(o,n),o}function it(n){return Array.prototype.concat.apply([],n)}function D(n){let t=n.map(_);return[t.map(e=>e[0]),it(t.map(e=>e[1]))]}var W=new WeakMap;function ot(n,t){return W.set(n,t),n}function at(n){return Object.assign(n,{[F]:!0})}function _(n){for(let[t,e]of H)if(e.canHandle(n)){let[r,s]=e.serialize(n);return[{type:"HANDLER",name:t,value:r},s]}return[{type:"RAW",value:n},W.get(n)||[]]}function m(n){switch(n.type){case"HANDLER":return H.get(n.name).deserialize(n.value);case"RAW":return n.value}}function A(n,t,e,r){return new Promise(s=>{let o=ct();t.set(o,s),n.start&&n.start(),n.postMessage(Object.assign({id:o},e),r)})}function ct(){return new Array(4).fill(0).map(()=>Math.floor(Math.random()*Number.MAX_SAFE_INTEGER).toString(16)).join("-")}var G=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],L=1,x=8,d=new Uint32Array(96),C=class n{static from(t){if(!t||t.byteLength===void 0||t.buffer)throw new Error("Data must be an instance of ArrayBuffer or SharedArrayBuffer.");let[e,r]=new Uint8Array(t,0,2);if(e!==219)throw new Error("Data does not appear to be in a KDBush format.");let s=r>>4;if(s!==L)throw new Error(`Got v${s} data when expected v${L}.`);let o=G[r&15];if(!o)throw new Error("Unrecognized array type.");let[c]=new Uint16Array(t,2,1),[u]=new Uint32Array(t,4,1);return new n(u,c,o,void 0,t)}constructor(t,e=64,r=Float64Array,s=ArrayBuffer,o){if(isNaN(t)||t<0)throw new Error(`Unexpected numItems value: ${t}.`);this.numItems=+t,this.nodeSize=Math.min(Math.max(+e,2),65535),this.ArrayType=r,this.IndexArrayType=t<65536?Uint16Array:Uint32Array;let c=G.indexOf(this.ArrayType),u=t*2*this.ArrayType.BYTES_PER_ELEMENT,i=t*this.IndexArrayType.BYTES_PER_ELEMENT,a=(8-i%8)%8;if(c<0)throw new Error(`Unexpected typed array class: ${r}.`);if(o)this.data=o,this.ids=new this.IndexArrayType(o,x,t),this.coords=new r(o,x+i+a,t*2),this._pos=t*2,this._finished=!0;else{let l=this.data=new s(x+u+i+a);this.ids=new this.IndexArrayType(l,x,t),this.coords=new r(l,x+i+a,t*2),this._pos=0,this._finished=!1,new Uint8Array(l,0,2).set([219,(L<<4)+c]),new Uint16Array(l,2,1)[0]=e,new Uint32Array(l,4,1)[0]=t}}add(t,e){let r=this._pos>>1;return this.ids[r]=r,this.coords[this._pos++]=t,this.coords[this._pos++]=e,r}finish(){let t=this._pos>>1;if(t!==this.numItems)throw new Error(`Added ${t} items when expected ${this.numItems}.`);return N(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(t,e,r,s){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");let{ids:o,coords:c,nodeSize:u}=this;d[0]=0,d[1]=o.length-1,d[2]=0;let i=3,a=[];for(;i>0;){let l=d[--i],h=d[--i],f=d[--i];if(h-f<=u){for(let g=f;g<=h;g++){let E=c[2*g],k=c[2*g+1];E>=t&&E<=r&&k>=e&&k<=s&&a.push(o[g])}continue}let y=f+h>>1,w=c[2*y],p=c[2*y+1];w>=t&&w<=r&&p>=e&&p<=s&&a.push(o[y]),(l===0?t<=w:e<=p)&&(d[i++]=f,d[i++]=y-1,d[i++]=1-l),(l===0?r>=w:s>=p)&&(d[i++]=y+1,d[i++]=h,d[i++]=1-l)}return a}within(t,e,r){let s=[];return this.withinInto(t,e,r,s),s}withinInto(t,e,r,s){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");let{ids:o,coords:c,nodeSize:u}=this;d[0]=0,d[1]=o.length-1,d[2]=0;let i=3,a=0,l=r*r;for(;i>0;){let h=d[--i],f=d[--i],y=d[--i];if(f-y<=u){for(let E=y;E<=f;E++)j(c[2*E],c[2*E+1],t,e)<=l&&(s[a++]=o[E]);continue}let w=y+f>>1,p=c[2*w],g=c[2*w+1];j(p,g,t,e)<=l&&(s[a++]=o[w]),(h===0?t-r<=p:e-r<=g)&&(d[i++]=y,d[i++]=w-1,d[i++]=1-h),(h===0?t+r>=p:e+r>=g)&&(d[i++]=w+1,d[i++]=f,d[i++]=1-h)}return a}};function N(n,t,e,r,s,o){if(s-r<=e)return;let c=r+s>>1;K(n,t,c,r,s,o),N(n,t,e,r,c-1,1-o),N(n,t,e,c+1,s,1-o)}function K(n,t,e,r,s,o){for(;s>r;){if(s-r>600){let a=s-r+1,l=e-r+1,h=Math.log(a),f=.5*Math.exp(2*h/3),y=.5*Math.sqrt(h*f*(a-f)/a)*(l-a/2<0?-1:1),w=Math.max(r,Math.floor(e-l*f/a+y)),p=Math.min(s,Math.floor(e+(a-l)*f/a+y));K(n,t,e,w,p,o)}let c=t[2*e+o],u=r,i=s;for(b(n,t,r,e),t[2*s+o]>c&&b(n,t,r,s);u<i;){for(b(n,t,u,i),u++,i--;t[2*u+o]<c;)u++;for(;t[2*i+o]>c;)i--}t[2*r+o]===c?b(n,t,r,i):(i++,b(n,t,i,s)),i<=e&&(r=i+1),e<=i&&(s=i-1)}}function b(n,t,e,r){O(n,e,r),O(t,2*e,2*r),O(t,2*e+1,2*r+1)}function O(n,t,e){let r=n[t];n[t]=n[e],n[e]=r}function j(n,t,e,r){let s=n-e,o=t-r;return s*s+o*o}var v=class{constructor(){M(this,"index",null);M(this,"xCoords",null);M(this,"yCoords",null)}buildIndex(t){this.clear(),this.xCoords=new Float64Array(t.length),this.yCoords=new Float64Array(t.length);for(let[r,s]of t.entries())this.xCoords[r]=s.x,this.yCoords[r]=s.y;let e=new C(t.length);for(let r=0;r<t.length;r++)e.add(this.xCoords[r],this.yCoords[r]);return e.finish(),this.index=e,e.data}clear(){this.index=null,this.xCoords=null,this.yCoords=null}findNearestPoint(t,e,r){if(!this.index||!this.xCoords||!this.yCoords)return null;let s=this.index.within(t,e,r);if(s.length===0)return null;let o=s[0],c=1/0;for(let u of s){let i=t-this.xCoords[u],a=e-this.yCoords[u],l=i*i+a*a;l<c&&(c=l,o=u)}return{x:this.xCoords[o],y:this.yCoords[o]}}findPointsInRadius(t,e,r){if(!this.index||!this.xCoords||!this.yCoords)return[];let s=this.index.within(t,e,r),o=Array.from({length:s.length});for(let[c,u]of s.entries())o[c]={x:this.xCoords[u],y:this.yCoords[u]};return o}};U(new v);\n/*! Bundled license information:\n\ncomlink/dist/esm/comlink.mjs:\n (**\n * @license\n * Copyright 2019 Google LLC\n * SPDX-License-Identifier: Apache-2.0\n *)\n*/\n')}function ln({snapPoints:e,snapRadius:t=50}){let n=useRef(null),r=useRef(null),a=useMemo(()=>{let s=new oe;return r.current=s,st.wrap(s)},[]);useEffect(()=>()=>{r.current&&(r.current.terminate(),r.current=null);},[]);let i=useCallback(async()=>{e&&(n.current=await a.buildIndex(e));},[e,a]);useEffect(()=>{e&&e.length>0&&i();},[e,i]);let o=useCallback(async s=>e?(n.current||await i(),a.findNearestPoint(s.x,s.y,t)):null,[e,t,i,a]),d=useCallback(async s=>e?(n.current||await i(),a.findPointsInRadius(s.x,s.y,t)):[],[e,t,i,a]);return {findNearestPoint:o,findPointsInRadius:d}}
11
+ export{ke as a,Ke as b,rt as c,ln as d};
@@ -0,0 +1,10 @@
1
+ import {a as a$9}from'./chunk-TEQE6WCH.mjs';import {a as a$3}from'./chunk-GXOXYPQQ.mjs';import {a as a$b,b as b$3}from'./chunk-ZNN43VZV.mjs';import {b as b$6,c as c$5}from'./chunk-EK3RIYMV.mjs';import {a as a$2}from'./chunk-AMYRLAIC.mjs';import {i,l,p,r,s,w,u,v,j,n,k,h as h$1,x,d as d$1,g,a as a$f}from'./chunk-SMAYNDQQ.mjs';import {b as b$1}from'./chunk-246VHB32.mjs';import {a as a$k}from'./chunk-RJWPSJX2.mjs';import {a as a$i}from'./chunk-YOBESAXG.mjs';import {a as a$l}from'./chunk-2WAKHFPS.mjs';import {c as c$4,b as b$8}from'./chunk-X3OCHEQM.mjs';import {a as a$h}from'./chunk-O7XK2WIX.mjs';import {a as a$j}from'./chunk-GCZFXILF.mjs';import {a as a$6}from'./chunk-KUEDQO7P.mjs';import {a}from'./chunk-USMC34OO.mjs';import {b as b$7}from'./chunk-WL27JGVG.mjs';import {b}from'./chunk-N2XGJKZG.mjs';import {a as a$a}from'./chunk-4ZJMZB5B.mjs';import {d}from'./chunk-RCBUNCHV.mjs';import {e,c,h,b as b$2,a as a$c}from'./chunk-B7PSE5KC.mjs';import {b as b$4,c as c$3}from'./chunk-PF3OQKXP.mjs';import {a as a$g}from'./chunk-D3IZ4HBL.mjs';import {a as a$1}from'./chunk-X3AXUU3H.mjs';import {a as a$4}from'./chunk-K6X2BHPP.mjs';import {a as a$8}from'./chunk-3FYY26ED.mjs';import {a as a$7}from'./chunk-RT4LMB6X.mjs';import {c as c$1,b as b$5}from'./chunk-TZ4MVY4E.mjs';import {a as a$5}from'./chunk-KEVERVHK.mjs';import {c as c$2}from'./chunk-JDLUGVXG.mjs';import {a as a$d}from'./chunk-FXCHST4Z.mjs';import {a as a$e}from'./chunk-4QEH5CGK.mjs';import Kt,{createContext,forwardRef,useRef,useEffect,useContext,useState,useMemo,useCallback,isValidElement}from'react';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {ChevronRightIcon}from'@baseline-ui/icons/8';import {themeVars,sprinkles}from'@baseline-ui/tokens';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function ve(r,o,e){let{gridProps:t}=b$6(r,o,e);return t.role="treegrid",{gridProps:t}}var gt={"ar-AE":{collapse:"\u0637\u064A",expand:"\u062A\u0645\u062F\u064A\u062F"},"bg-BG":{collapse:"\u0421\u0432\u0438\u0432\u0430\u043D\u0435",expand:"\u0420\u0430\u0437\u0448\u0438\u0440\u044F\u0432\u0430\u043D\u0435"},"cs-CZ":{collapse:"Sbalit",expand:"Rozt\xE1hnout"},"da-DK":{collapse:"Skjul",expand:"Udvid"},"de-DE":{collapse:"Reduzieren",expand:"Erweitern"},"el-GR":{collapse:"\u03A3\u03CD\u03BC\u03C0\u03C4\u03C5\u03BE\u03B7",expand:"\u0391\u03BD\u03AC\u03C0\u03C4\u03C5\u03BE\u03B7"},"en-US":{expand:"Expand",collapse:"Collapse"},"es-ES":{collapse:"Contraer",expand:"Ampliar"},"et-EE":{collapse:"Ahenda",expand:"Laienda"},"fi-FI":{collapse:"Pienenn\xE4",expand:"Laajenna"},"fr-FR":{collapse:"R\xE9duire",expand:"D\xE9velopper"},"he-IL":{collapse:"\u05DB\u05D5\u05D5\u05E5",expand:"\u05D4\u05E8\u05D7\u05D1"},"hr-HR":{collapse:"Sa\u017Emi",expand:"Pro\u0161iri"},"hu-HU":{collapse:"\xD6sszecsuk\xE1s",expand:"Kibont\xE1s"},"it-IT":{collapse:"Comprimi",expand:"Espandi"},"ja-JP":{collapse:"\u6298\u308A\u305F\u305F\u3080",expand:"\u5C55\u958B"},"ko-KR":{collapse:"\uC811\uAE30",expand:"\uD3BC\uCE58\uAE30"},"lt-LT":{collapse:"Sutraukti",expand:"I\u0161skleisti"},"lv-LV":{collapse:"Sak\u013Caut",expand:"Izv\u0113rst"},"nb-NO":{collapse:"Skjul",expand:"Utvid"},"nl-NL":{collapse:"Samenvouwen",expand:"Uitvouwen"},"pl-PL":{collapse:"Zwi\u0144",expand:"Rozwi\u0144"},"pt-BR":{collapse:"Recolher",expand:"Expandir"},"pt-PT":{collapse:"Colapsar",expand:"Expandir"},"ro-RO":{collapse:"Restr\xE2nge\u021Bi",expand:"Extinde\u021Bi"},"ru-RU":{collapse:"\u0421\u0432\u0435\u0440\u043D\u0443\u0442\u044C",expand:"\u0420\u0430\u0437\u0432\u0435\u0440\u043D\u0443\u0442\u044C"},"sk-SK":{collapse:"Zbali\u0165",expand:"Rozbali\u0165"},"sl-SI":{collapse:"Strni",expand:"Raz\u0161iri"},"sr-SP":{collapse:" Skupi",expand:"Pro\u0161iri"},"sv-SE":{collapse:"D\xF6lj",expand:"Expandera"},"tr-TR":{collapse:"Daralt",expand:"Geni\u015Flet"},"uk-UA":{collapse:"\u0417\u0433\u043E\u0440\u043D\u0443\u0442\u0438",expand:"\u0420\u043E\u0437\u0433\u043E\u0440\u043D\u0443\u0442\u0438"},"zh-CN":{collapse:"\u6298\u53E0",expand:"\u6269\u5C55"},"zh-TW":{collapse:"\u6536\u5408",expand:"\u5C55\u958B"}};function se(r,o,e){let{node:t}=r,n=c$5(r,o,e),a=n.rowProps["aria-expanded"]===true,s=b$7(gt,"@react-aria/tree"),c=a$g({"aria-label":a?s.format("collapse"):s.format("expand"),"aria-labelledby":n.rowProps.id}),d={onPress:()=>{n.isDisabled||(o.toggleKey(t.key),o.selectionManager.setFocused(true),o.selectionManager.setFocusedKey(t.key));},excludeFromTabOrder:true,preventFocusOnPress:true,"data-react-aria-prevent-focus":true,...c};return {...n,expandButtonProps:d}}var be=class r extends g{expandedKeys=new Set;withExpandedKeys(o,e){let t=this.clone();return t.expandedKeys=e,r.cloneAncestorSections(e,o,t),r.cloneAncestorSections(o,e,t),t.frozen=this.frozen,t}static cloneAncestorSections(o,e,t){for(let n of o)if(!e.has(n)){let a=n;for(;a!=null;){let s=t.getItem(a);if(s?.type==="section"){t.keyMap.set(a,s.clone());break}else a=s?.parentKey??null;}}}*[Symbol.iterator](){let o=this.getFirstKey(),e=o!=null?this.getItem(o):null;for(;e;)if(yield e,e.type==="section")e=e.nextKey!=null?this.getItem(e.nextKey):null;else {let t=this.getKeyAfter(e.key);e=t!=null?this.getItem(t):null;}}getLastKey(){let o=this.lastKey;if(o==null)return null;let e=this.getItem(o);for(;e?.lastChildKey!=null&&(e.type!=="item"||this.expandedKeys.has(e.key));)e=this.getItem(e.lastChildKey);return e?.key}getKeyAfter(o){let e=this.getItem(o);if(!e)return null;if((this.expandedKeys.has(e.key)||e.type!=="item")&&e.firstChildKey!=null)return e.firstChildKey;for(;e;){if(e.nextKey!=null)return e.nextKey;if(e.parentKey!=null)e=this.getItem(e.parentKey);else return null}return null}getKeyBefore(o){let e=this.getItem(o);if(!e)return null;if(e.prevKey!=null){for(e=this.getItem(e.prevKey);e&&(e.type!=="item"||this.expandedKeys.has(e.key))&&e.lastChildKey!=null;)e=this.getItem(e.lastChildKey);return e?.key??null}return e.parentKey}getChildren(o){let e=this;return {*[Symbol.iterator](){let t=e.getItem(o),n=t?.firstChildKey!=null?e.getItem(t.firstChildKey):null;if(t&&t.type==="section"&&n)for(;n&&n.key!==t.nextKey;){yield e.getItem(n.key);let a=e.getKeyAfter(n.key);n=a!=null?e.getItem(a):null;}else for(;n;)yield n,n=n.nextKey!=null?e.getItem(n.nextKey):null;}}}getTextValue(o){let e=this.getItem(o);return e?e.textValue:""}},bt=createContext(null),ue=createContext(null),Ie=forwardRef(function(o,e$1){return [o,e$1]=e(o,e$1,bt),jsx(i,{content:jsx(l,{...o}),createCollection:()=>new be,children:t=>jsx(Ht,{props:o,collection:t,treeRef:e$1})})}),xt={expand:{ltr:"ArrowRight",rtl:"ArrowLeft"},collapse:{ltr:"ArrowLeft",rtl:"ArrowRight"}};function Ht({props:r$1,collection:o,treeRef:e}){let{dragAndDropHooks:t}=r$1,{direction:n}=b(),a$7=a({usage:"search",sensitivity:"base"}),s$1=!!t?.useDraggableCollectionState,c$2=!!t?.useDroppableCollectionState,d=useRef(s$1),C=useRef(c$2);useEffect(()=>{d.current!==s$1&&console.warn("Drag hooks were provided during one render, but not another. This should be avoided as it may produce unexpected behavior."),C.current!==c$2&&console.warn("Drop hooks were provided during one render, but not another. This should be avoided as it may produce unexpected behavior.");},[s$1,c$2]);let{selectionMode:T="none",expandedKeys:g,defaultExpandedKeys:u$1,onExpandedChange:b$3,disabledBehavior:m="all"}=r$1,{CollectionRoot:I,isVirtualized:f,layoutDelegate:y,dropTargetDelegate:x}=useContext(p),[v$1,K]=a$1(g?new Set(g):void 0,u$1?new Set(u$1):new Set,b$3),[R,M]=useState(o),[w$1,P]=useState(v$1),[i,h$1]=useState(()=>o.withExpandedKeys(w$1,v$1));(!Ft(w$1,v$1)||o!==R)&&(h$1(o.withExpandedKeys(w$1,v$1)),M(o),P(v$1));let l=a$2({...r$1,selectionMode:T,expandedKeys:v$1,onExpandedChange:K,collection:i,children:void 0,disabledBehavior:m}),{gridProps:H}=ve({...r$1,isVirtualized:f,layoutDelegate:y},l,e),S,E,j,V=false,U=null,Z=useRef(null);if(s$1&&t){S=t.useDraggableCollectionState({collection:l.collection,selectionManager:l.selectionManager,preview:t.renderDragPreview?Z:void 0}),t.useDraggableCollection({},S,e);let ee=t.DragPreview;U=t.renderDragPreview?jsx(ee,{ref:Z,children:t.renderDragPreview}):null;}let[q]=useState(()=>new a$3);if(c$2&&t){E=t.useDroppableCollectionState({collection:l.collection,selectionManager:l.selectionManager});let ee=t.dropTargetDelegate||x||new t.ListDropTargetDelegate(l.collection,e,{direction:n});q.setup(ee,l,n);let me=new b$1({collection:l.collection,collator:a$7,ref:e,disabledKeys:l.selectionManager.disabledKeys,disabledBehavior:l.selectionManager.disabledBehavior,direction:n,layoutDelegate:y});j=t.useDroppableCollection({keyboardDelegate:me,dropTargetDelegate:q,onDropActivate:N=>{if(N.target.type==="item"){let D=N.target.key,W=l.collection.getItem(D),kt=v$1.has(D);W&&W.hasChildNodes&&(!kt||t?.isVirtualDragging?.())&&l.toggleKey(D);}},onKeyDown:N=>{let D=E?.target;if(D&&D.type==="item"&&D.dropPosition==="on"){let W=l.collection.getItem(D.key);(N.key===xt.expand[n]&&W?.hasChildNodes&&!l.expandedKeys.has(D.key)||N.key===xt.collapse[n]&&W?.hasChildNodes&&l.expandedKeys.has(D.key))&&l.toggleKey(D.key);}}},E,e),V=E.isDropTarget({type:"root"});}let Y=!!(s$1&&!S?.isDisabled),{focusProps:Q,isFocused:z,isFocusVisible:O}=a$4(),Me={isEmpty:l.collection.size===0,isFocused:z,isFocusVisible:O,isDropTarget:V,selectionMode:l.selectionManager.selectionMode,allowsDragging:!!Y,state:l},Lt=c({...r$1,children:void 0,defaultClassName:"react-aria-Tree",values:Me}),ke=null;if(l.collection.size===0&&r$1.renderEmptyState){let{isEmpty:ee,...me}=Me,N=r$1.renderEmptyState({...me});ke=jsx("div",{role:"row",style:{display:"contents"},...{"aria-level":1},children:jsx("div",{role:"gridcell",style:{display:"contents"},children:N})});}let Mt=a$5(r$1,{global:true});return jsxs(Fragment,{children:[jsx(a$6,{children:jsxs(h.div,{...c$1(Mt,Lt,H,Q,j?.collectionProps),ref:e,slot:r$1.slot||void 0,"data-empty":l.collection.size===0||void 0,"data-focused":z||void 0,"data-drop-target":V||void 0,"data-focus-visible":O||void 0,"data-selection-mode":l.selectionManager.selectionMode==="none"?void 0:l.selectionManager.selectionMode,"data-allows-dragging":!!Y||void 0,children:[jsxs(b$2,{values:[[ue,l],[r,{dragAndDropHooks:t,dragState:S,dropState:E}],[s,{render:Nt}]],children:[c$2&&jsx(zt,{}),jsx(w,{children:jsx(I,{collection:l.collection,persistedKeys:v(l.selectionManager,t,E),scrollRef:e,renderDropIndicator:u(t,E)})})]}),ke]})}),U]})}var Pe=class extends a$f{static type="content"},Ce=j(Pe,function(o){let e=useContext(Pt),t=c({children:o.children,values:e});return jsx(p.Provider,{value:n,children:t.children})}),Pt=createContext(null),he=class extends a$f{static type="item"},Re=k(he,(r$1,o,e)=>{let t=useContext(ue);o=a$7(o);let{dragAndDropHooks:n,dragState:a,dropState:s}=useContext(r),c$3=a&&!(a.isDisabled||a.selectionManager.isDisabled(e.key)),{rowProps:d$1,gridCellProps:C,expandButtonProps:T,descriptionProps:g,...u}=se({node:e,shouldSelectOnPressUp:!!a},t,o),b=d$1["aria-expanded"]===true,m=r$1.hasChildItems||[...t.collection.getChildren(e.key)].length>1,I=d$1["aria-level"]||1,{hoverProps:f,isHovered:y}=a$8({isDisabled:!u.allowsSelection&&!u.hasAction&&!c$3,onHoverStart:r$1.onHoverStart,onHoverChange:r$1.onHoverChange,onHoverEnd:r$1.onHoverEnd}),{isFocusVisible:x$1,focusProps:v}=a$4(),{isFocusVisible:K,focusProps:R}=a$4({within:true}),{checkboxProps:M}=a$9({key:e.key},t),w=null;a&&n&&(w=n.useDraggableItem({key:e.key,hasDragButton:true},a,o));let P=null,i=useRef(null),h$2=useRef(null),l=useRef(null),{visuallyHiddenProps:H}=a$a();s&&n&&(P=n.useDropIndicator({target:{type:"item",key:e.key,dropPosition:"on"},activateButtonRef:l},s,h$2));let S=a&&a.isDragging(e.key),E=P?.isDropTarget,j=t.selectionManager.selectionMode,V=t.selectionManager.selectionBehavior,U=Kt.useMemo(()=>({...u,isHovered:y,isFocusVisible:x$1,isExpanded:b,hasChildItems:m,level:I,selectionMode:j,selectionBehavior:V,isFocusVisibleWithin:K,state:t,id:e.key,allowsDragging:!!a,isDragging:S,isDropTarget:E}),[u,y,x$1,b,m,I,K,t,e.key,a,S,E,V,j]),Z=c({...r$1,id:void 0,children:e.rendered,defaultClassName:"react-aria-TreeItem",defaultStyle:{"--tree-item-level":I},values:U});useEffect(()=>{!e.textValue&&process.env.NODE_ENV!=="production"&&console.warn("A `textValue` prop is required for <TreeItem> elements in order to support accessibility features such as type to select.");},[e.textValue]),useEffect(()=>{m&&!i.current&&process.env.NODE_ENV!=="production"&&console.warn("Expandable tree items must contain a expand button so screen reader users can expand/collapse the item.");},[]);let q=useRef(null);useEffect(()=>{a&&!q.current&&process.env.NODE_ENV!=="production"&&console.warn('Draggable items in a Tree must contain a <Button slot="drag"> element so that keyboard and screen reader users can drag them.');},[]);let Y=h$1({items:t.collection.getChildren(e.key),children:O=>{switch(O.type){case "content":return O.render(O);case "loader":case "item":return jsx(Fragment,{});default:throw new Error("Unsupported element type in TreeRow: "+O.type)}}}),Q=c$2(),z=a$5(r$1,{global:true});return delete z.id,delete z.onClick,jsxs(Fragment,{children:[P&&!P.isHidden&&jsx("div",{role:"row","aria-level":d$1["aria-level"],"aria-expanded":d$1["aria-expanded"],"aria-label":P.dropIndicatorProps["aria-label"],children:jsxs("div",{role:"gridcell","aria-colindex":1,style:{display:"contents"},children:[jsx("div",{role:"button",...H,...P.dropIndicatorProps,ref:h$2}),d$1["aria-expanded"]!=null?jsx("div",{role:"button",...H,id:Q,"aria-label":T["aria-label"],"aria-labelledby":`${Q} ${d$1.id}`,tabIndex:-1,ref:l}):null]})}),jsx(h.div,{...c$1(z,d$1,v,f,R,w?.dragProps),...Z,ref:o,"data-expanded":m&&b||void 0,"data-has-child-items":m||void 0,"data-level":I,"data-selected":u.isSelected||void 0,"data-disabled":u.isDisabled||void 0,"data-hovered":y||void 0,"data-focused":u.isFocused||void 0,"data-focus-visible":x$1||void 0,"data-pressed":u.isPressed||void 0,"data-selection-mode":t.selectionManager.selectionMode==="none"?void 0:t.selectionManager.selectionMode,"data-allows-dragging":!!a||void 0,"data-dragging":S||void 0,"data-drop-target":E||void 0,children:jsx("div",{...C,style:{display:"contents"},children:jsx(b$2,{values:[[a$b,{slots:{selection:M}}],[b$3,{slots:{selection:M}}],[d,{slots:{[a$c]:{},chevron:{...T,ref:i},drag:{...w?.dragButtonProps,ref:q,style:{pointerEvents:"none"}}}}],[Pt,{...U}],[x,{isSelected:u.isSelected}]],children:Y})})})]})});j(d$1,function(o,e,t){let{isVirtualized:n}=useContext(p),a=useContext(ue),{isLoading:s,onLoadMore:c$2,scrollOffset:d,...C}=o,T=useRef(null),g=useMemo(()=>({onLoadMore:c$2,collection:a?.collection,sentinelRef:T,scrollOffset:d}),[c$2,d,a?.collection]);b$4(g,T),e=a$7(e);let{rowProps:u,gridCellProps:b}=se({node:t},a,e),m=u["aria-level"]||1,I={role:"row","aria-level":u["aria-level"]},f=c({...C,id:void 0,children:t.rendered,defaultClassName:"react-aria-TreeLoader",values:{level:m}}),y={};return n&&(y={display:"contents"}),jsxs(Fragment,{children:[jsx("div",{style:{position:"relative",width:0,height:0},inert:c$3(true),children:jsx("div",{"data-testid":"loadMoreSentinel",ref:T,style:{position:"absolute",height:1,width:1}})}),s&&f.children&&jsx(h.div,{ref:e,...c$1(a$5(o),I),...f,"data-level":m,children:jsx("div",{...b,style:y,children:f.children})})]})});function Nt(r$1,o){o=a$7(o);let{dragAndDropHooks:e,dropState:t}=useContext(r),n=useRef(null),{dropIndicatorProps:a,isHidden:s,isDropTarget:c}=e.useDropIndicator(r$1,t,n);if(s)return null;let d=t&&r$1.target.type==="item"?(t.collection.getItem(r$1.target.key)?.level||0)+1:1;return jsx(Vt,{...r$1,dropIndicatorProps:a,isDropTarget:c,ref:o,buttonRef:n,level:d})}function Bt(r,o){let{dropIndicatorProps:e,isDropTarget:t,buttonRef:n,level:a,...s}=r,{visuallyHiddenProps:c$1}=a$a(),d=c({...s,defaultClassName:"react-aria-DropIndicator",defaultStyle:{position:"relative","--tree-item-level":a},values:{isDropTarget:t}});return jsx(h.div,{...d,role:"row","aria-level":a,ref:o,"data-drop-target":t||void 0,children:jsxs("div",{role:"gridcell",children:[jsx("div",{...c$1,role:"button",...e,ref:n}),d.children]})})}var Vt=forwardRef(Bt);function zt(){let{dragAndDropHooks:r$1,dropState:o}=useContext(r),e=useRef(null),{dropIndicatorProps:t}=r$1.useDropIndicator({target:{type:"root"}},o,e),n=o.isDropTarget({type:"root"}),{visuallyHiddenProps:a}=a$a();return !n&&t["aria-hidden"]?null:jsx("div",{role:"row","aria-hidden":t["aria-hidden"],style:{position:"absolute"},children:jsx("div",{role:"gridcell",children:jsx("div",{role:"button",...a,...t,ref:e})})})}function Ft(r,o){if(r.size!==o.size)return false;for(let e of r)if(!o.has(e))return false;return true}var ht=({actionsPosition:r,onPrimaryAction:o,onSecondaryAction:e,primaryActionIcon:t,secondaryActionIcon:n,primaryActionAriaLabel:a,secondaryActionAriaLabel:s,expandLabel:c,collapseLabel:d,onRename:C,renameLabel:T,renderItemTitle:g})=>Object.values({actionsPosition:r,onPrimaryAction:o,onSecondaryAction:e,primaryActionIcon:t,secondaryActionIcon:n,primaryActionAriaLabel:a,secondaryActionAriaLabel:s,expandLabel:c,collapseLabel:d,onRename:C,renameLabel:T,renderItemTitle:g});var Dt="_10dw1p96",It="_10dw1p95",Ct=a$d({defaultClassName:"_10dw1p90 _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z69f _1yep5z69g _1yep5z69h _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6lq _1yep5z6ld _1yep5z6la",variantClassNames:{isSelected:{true:"_1yep5z6126"},isHovered:{true:"_10dw1p92"},isRenaming:{true:"_10dw1p93"},isFocusVisible:{true:"_1yep5z6140 _1yep5z617w _1yep5z617u _1yep5z617x"}},defaultVariants:{},compoundVariants:[[{isHovered:true,isSelected:false,isRenaming:false},"_1yep5z61o8 _1yep5z61q9 _1yep5z61ty _1yep5z61tx _1yep5z61u1"]]});function St(r,o){if(typeof r=="function"&&!r.prototype?.isReactComponent){let e=r(o);return isValidElement(e)?r:e}return r}var Se=({item:r,...o})=>{let{onPrimaryAction:e,onSecondaryAction:t,actionsPosition:n,primaryActionIcon:a,secondaryActionIcon:s,primaryActionAriaLabel:c,secondaryActionAriaLabel:d,expandLabel:C,collapseLabel:T,onRename:g,renameLabel:u,renderItemTitle:b}=o,{formatMessage:m}=b$8(),{renamingKey:I,setRenamingKey:f}=useContext(Ee),y=I===r.id,x=!!r.children?.length,v=r.icon,K=!!g,R=useRef(false),M=useMemo(()=>{let i=St(a,r.id),h=St(s,r.id),l=typeof c=="function"?c(r.id):c,H=typeof d=="function"?d(r.id):d;return i||h?jsxs(a$h,{display:"flex",flexDirection:"row",children:[i?jsx(a$i,{icon:i,"aria-label":l,size:"sm",excludeFromTabOrder:true,variant:"secondary",onPress:()=>{e?.(r.id);},tooltip:true}):null,h?jsx(a$i,{icon:h,"aria-label":H,size:"sm",excludeFromTabOrder:true,variant:"secondary",onPress:()=>{t?.(r.id);},tooltip:true}):null]}):null},[a,r.id,s,c,d,e,t]),w=useCallback(i=>{i.key==="Enter"?(R.current=true,g?.({key:r.id,value:i.target.value}),f(null)):i.key==="Escape"&&(R.current=true,f(null));},[r.id,g,f]),P=useCallback(()=>b?b(r):r.label,[b,r]);return jsxs(Re,{id:r.id,textValue:r.label,"data-key":r.id,className:i=>a$e(It,Ct({isHovered:i.isHovered,isSelected:i.isSelected,isFocusVisible:i.isFocusVisible,isRenaming:y}),"BaselineUI-TreeView-Row"),style:{justifyContent:n==="end"?"space-between":void 0},children:[jsx(Ce,{children:i=>{let h=i.level-1;return jsxs(Fragment,{children:[n==="start"?M:null,jsxs(a$h,{display:"flex",flexDirection:"row",alignItems:"center",children:[jsxs(a$h,{display:"flex",padding:"sm",flexDirection:"row",alignItems:"center",gap:"md",style:{marginInlineStart:`calc(${h*2} * ${themeVars.spacing.lg})`},children:[jsx(a$j,{icon:ChevronRightIcon,size:"xxs",variant:"secondary",onPress:()=>{i.state.toggleKey(i.id);},"aria-label":i.isExpanded?T??m(we.collapse):C??m(we.expand),style:{visibility:x?"visible":"hidden"},className:a$e(Dt,"BaselineUI-TreeView-ExpansionToggle")}),v?jsx(v,{size:16,style:{color:themeVars.color.icon.interactive.disabled}}):null]}),jsxs(a$h,{paddingLeft:"sm",paddingY:y?"none":"md",display:"flex",flexDirection:"column",gap:"xs",onDoubleClick:l=>{K&&(l.stopPropagation(),l.preventDefault(),f(r.id));},children:[y?jsx("div",{onClick:l=>{l.stopPropagation();},children:jsx(a$k,{defaultValue:r.label,autoFocus:true,onBlur:l=>{if(R.current){R.current=false;return}g?.({key:r.id,value:l.target.value}),f(null);},"aria-label":u??m(we.rename),onKeyDown:w,className:"BaselineUI-TreeView-RenameInput"})}):jsx(a$l,{type:"label",size:"sm",className:a$e(sprinkles.compoundVariants({color:"text.primary"}),"BaselineUI-TreeView-Title"),children:P()}),r.description?jsx(a$l,{type:"helper",size:"sm",className:"BaselineUI-TreeView-Description",children:r.description}):null]})]}),n==="end"?M:null]})}}),jsx(l,{items:r.children,children:i=>jsx(Se,{item:i,...o})})]})},we=c$4({expand:{id:"bui.treeView.expand",defaultMessage:"Expand"},collapse:{id:"bui.treeView.collapse",defaultMessage:"Collapse"},rename:{id:"bui.treeView.rename",defaultMessage:"Rename"}});var Ee=createContext({renamingKey:null,setRenamingKey:()=>{}}),Et=Kt.forwardRef(({className:r,style:o,"data-block-id":e,"data-block-class":t,items:n,onPrimaryAction:a,onSecondaryAction:s,primaryActionIcon:c,secondaryActionIcon:d,primaryActionAriaLabel:C,secondaryActionAriaLabel:T,actionsPosition:g="start",expandLabel:u,collapseLabel:b,onRename:m,renameLabel:I,onAction:f,renderItemTitle:y,...x},v)=>{let K=useRef(null),[R,M]=useState(null);useEffect(()=>{let i=K.current;if(!i||!m)return;let h=l=>{if(l.key==="F2"){let S=i.querySelector("[data-focused='true']")?.dataset.key;S&&(l.preventDefault(),l.stopPropagation(),M(S));}};return i.addEventListener("keydown",h),()=>{i.removeEventListener("keydown",h);}},[m]);let w=useMemo(()=>({renamingKey:R,setRenamingKey:M}),[R]),P={actionsPosition:g,onPrimaryAction:a,onSecondaryAction:s,primaryActionIcon:c,secondaryActionIcon:d,primaryActionAriaLabel:C,secondaryActionAriaLabel:T,expandLabel:u,collapseLabel:b,onRename:m,renameLabel:I,renderItemTitle:y};return jsx(Ee.Provider,{value:w,children:jsx(Ie,{ref:b$5(v,K),items:n.children||[],selectionMode:"multiple",expandedKeys:x.expandedKeys,defaultExpandedKeys:x.defaultExpandedKeys,onExpandedChange:x.onExpandedChange,selectedKeys:x.selectedKeys,onAction:f,"aria-label":x["aria-label"],"aria-labelledby":x["aria-labelledby"],"data-block-id":e,"data-block-class":t,style:o,className:a$e(r,"BaselineUI-TreeView"),dependencies:ht(P),children:i=>jsx(Se,{item:i,...P})})})});Et.displayName="TreeView";export{Et as a};
@@ -0,0 +1,10 @@
1
+ import {a as a$1,r,d}from'./chunk-7AY6C5M5.mjs';import {i,l}from'./chunk-SMAYNDQQ.mjs';import {a}from'./chunk-FXCHST4Z.mjs';import {createElement,useMemo}from'react';import {jsx}from'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var f=({children:_,listBoxProps:r$1,...e})=>jsx(a$1.Provider,{value:useMemo(()=>({items:e.items}),[e.items]),children:jsx(i,{content:jsx(l,{items:e.items,dependencies:[e.items?.[0]?.id,...d(r$1)],children:i=>createElement(r,{...r$1,key:i.id,item:i,isFirstCollectionItem:e.items?.[0]?.id===i.id})}),children:_})});var R="_1mdhlqvd _1yep5z6k4 _1yep5z6k5 _1yep5z6k6 _1yep5z6kd _1yep5z6ke _1yep5z6kf",N=a({defaultClassName:"_1mdhlqv9",variantClassNames:{isOpen:{true:"_1mdhlqva"}},defaultVariants:{},compoundVariants:[]}),V="_1mdhlqvi",F=a({defaultClassName:"_1mdhlqve _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6k4 _1yep5z6k5 _1yep5z6k6",variantClassNames:{isVirtualized:{true:"_1mdhlqvf"}},defaultVariants:{},compoundVariants:[]}),S="_1mdhlqvc cjv3et1 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6g1 _1yep5z6lz _1yep5z6m1 _1yep5z6137 cjv3et5",U="_1mdhlqvg",O="_1mdhlqvh _1yep5z64x _1yep5z64y _1yep5z64z _1yep5z679 _1yep5z67a _1yep5z67b _1yep5z68f _1yep5z68g _1yep5z68h _1yep5z663 _1yep5z664 _1yep5z665",D=a({defaultClassName:"_1mdhlqv0 _1yep5z66 _1yep5z67 _1yep5z68 _1yep5z62i _1yep5z62j _1yep5z62k _1yep5z63o _1yep5z63p _1yep5z63q _1yep5z61c _1yep5z61d _1yep5z61e _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k _1yep5z6eu _1yep5z6kj _1yep5z6kk _1yep5z6kl _1yep5z6dy",variantClassNames:{isFocused:{false:"_1mdhlqv1"},isOpen:{true:"_1mdhlqv2"},isDisabled:{true:"z9nup82 _1yep5z6ey"},isHovered:{true:"_1mdhlqv4"},variant:{primary:"_1mdhlqv5",ghost:"_1mdhlqv6"},isReadOnly:{true:"_1mdhlqv7"},areTagsVisible:{true:"_1mdhlqv8 _1yep5z613 _1yep5z614 _1yep5z615 _1yep5z63f _1yep5z63g _1yep5z63h _1yep5z6k4 _1yep5z6k5 _1yep5z6k6"}},defaultVariants:{},compoundVariants:[[{variant:"primary",isHovered:true,isReadOnly:false,isDisabled:false},"_1yep5z6h5"],[{isHovered:true,isReadOnly:false,isDisabled:false},"_1yep5z6la"]]}),P="_1yep5z66x _1yep5z66y _1yep5z66z",H="_1mdhlqvb _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6j1 _1yep5z6j2 _1yep5z6j3 _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z69i _1yep5z69j _1yep5z69k";export{f as a,R as b,N as c,V as d,F as e,S as f,U as g,O as h,D as i,P as j,H as k};
@@ -0,0 +1,10 @@
1
+ import {createContext,useContext,forwardRef}from'react';import {jsx,Fragment}from'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ typeof HTMLTemplateElement<"u"&&(Object.defineProperty(HTMLTemplateElement.prototype,"firstChild",{configurable:true,enumerable:true,get:function(){return this.content.firstChild}}),Object.defineProperty(HTMLTemplateElement.prototype,"appendChild",{configurable:true,enumerable:true,value:function(e){return this.content.appendChild(e)}}),Object.defineProperty(HTMLTemplateElement.prototype,"removeChild",{configurable:true,enumerable:true,value:function(e){return this.content.removeChild(e)}}),Object.defineProperty(HTMLTemplateElement.prototype,"insertBefore",{configurable:true,enumerable:true,value:function(e,t){return this.content.insertBefore(e,t)}}));var n=createContext(false);function h(e){if(useContext(n))return jsx(Fragment,{children:e.children});let o=jsx(n.Provider,{value:true,children:e.children});return jsx("template",{children:o})}function d(e){let t=(o,s)=>useContext(n)?null:e(o,s);return t.displayName=e.displayName||e.name,forwardRef(t)}function u(){return useContext(n)}var D=createContext({});export{h as a,d as b,u as c,D as d};
@@ -0,0 +1,10 @@
1
+ import {b}from'./chunk-WL27JGVG.mjs';import {b as b$1,a}from'./chunk-JJG67M2S.mjs';import {t}from'./chunk-MRJFGHFW.mjs';import {a as a$1}from'./chunk-6ZQE5SHE.mjs';import {useRef,useCallback,useEffect,useState}from'react';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var K={"ar-AE":{Empty:"\u0641\u0627\u0631\u063A"},"bg-BG":{Empty:"\u0418\u0437\u043F\u0440\u0430\u0437\u043D\u0438"},"cs-CZ":{Empty:"Pr\xE1zdn\xE9"},"da-DK":{Empty:"Tom"},"de-DE":{Empty:"Leer"},"el-GR":{Empty:"\u0386\u03B4\u03B5\u03B9\u03BF"},"en-US":{Empty:"Empty"},"es-ES":{Empty:"Vac\xEDo"},"et-EE":{Empty:"T\xFChjenda"},"fi-FI":{Empty:"Tyhj\xE4"},"fr-FR":{Empty:"Vide"},"he-IL":{Empty:"\u05E8\u05D9\u05E7"},"hr-HR":{Empty:"Prazno"},"hu-HU":{Empty:"\xDCres"},"it-IT":{Empty:"Vuoto"},"ja-JP":{Empty:"\u7A7A"},"ko-KR":{Empty:"\uBE44\uC5B4 \uC788\uC74C"},"lt-LT":{Empty:"Tu\u0161\u010Dias"},"lv-LV":{Empty:"Tuk\u0161s"},"nb-NO":{Empty:"Tom"},"nl-NL":{Empty:"Leeg"},"pl-PL":{Empty:"Pusty"},"pt-BR":{Empty:"Vazio"},"pt-PT":{Empty:"Vazio"},"ro-RO":{Empty:"Gol"},"ru-RU":{Empty:"\u041D\u0435 \u0437\u0430\u043F\u043E\u043B\u043D\u0435\u043D\u043E"},"sk-SK":{Empty:"Pr\xE1zdne"},"sl-SI":{Empty:"Prazen"},"sr-SP":{Empty:"Prazno"},"sv-SE":{Empty:"Tomt"},"tr-TR":{Empty:"Bo\u015F"},"uk-UA":{Empty:"\u041F\u0443\u0441\u0442\u043E"},"zh-CN":{Empty:"\u7A7A"},"zh-TW":{Empty:"\u7A7A\u767D"}};var F=()=>{};function oe(G){let P=useRef(void 0),{value:t$1,textValue:w,minValue:p,maxValue:c,isDisabled:O,isReadOnly:S,isRequired:j,onIncrement:s,onIncrementPage:g,onDecrement:a$2,onDecrementPage:x,onDecrementToMin:A,onIncrementToMax:V}=G,H=b(K,"@react-aria/spinbutton"),i=useRef(false),n=useCallback(()=>{clearTimeout(P.current),i.current=false;},[]),u=t(()=>{n();});useEffect(()=>()=>u(),[]);let q=e=>{if(!(e.ctrlKey||e.metaKey||e.shiftKey||e.altKey||S||e.nativeEvent.isComposing))switch(e.key){case "PageUp":if(g){e.preventDefault(),g?.();break}case "ArrowUp":case "Up":s&&(e.preventDefault(),s?.());break;case "PageDown":if(x){e.preventDefault(),x?.();break}case "ArrowDown":case "Down":a$2&&(e.preventDefault(),a$2?.());break;case "Home":A&&(e.preventDefault(),A?.());break;case "End":V&&(e.preventDefault(),V?.());break}},v=useRef(false),D=()=>{v.current=true;},b$2=()=>{v.current=false;},T=w===""?H.format("Empty"):(w||`${t$1}`).replace("-","\u2212");useEffect(()=>{v.current&&(b$1("assertive"),a(T,"assertive"));},[T]);let N=useCallback(()=>{n();},[n]),J=t(s??F),W=t(a$2??F),Z=t(()=>{(c===void 0||isNaN(c)||t$1===void 0||isNaN(t$1)||t$1<c)&&(J(),B(60));}),B=t(e=>{u(),i.current=true,P.current=window.setTimeout(Z,e);}),_=t(()=>{(p===void 0||isNaN(p)||t$1===void 0||isNaN(t$1)||t$1>p)&&(W(),h(60));}),h=t(e=>{u(),i.current=true,P.current=window.setTimeout(_,e);}),$=e=>{e.preventDefault();},{addGlobalListener:I,removeAllGlobalListeners:R}=a$1(),r=useRef(false),[m,l]=useState(null);useEffect(()=>{m==="touch"?B(600):m?B(400):m||u();},[m]);let[f,d]=useState(null);return useEffect(()=>{f==="touch"?h(600):f?h(400):f||u();},[f]),{spinButtonProps:{role:"spinbutton","aria-valuenow":t$1!==void 0&&!isNaN(t$1)?t$1:void 0,"aria-valuetext":T,"aria-valuemin":p,"aria-valuemax":c,"aria-disabled":O||void 0,"aria-readonly":S||void 0,"aria-required":j||void 0,onKeyDown:q,onFocus:D,onBlur:b$2},incrementButtonProps:{onPressStart:e=>{n(),e.pointerType!=="touch"?(s?.(),l("mouse")):(I(window,"pointercancel",N,{capture:true}),r.current=false,l("touch")),I(window,"contextmenu",$);},onPressUp:e=>{n(),e.pointerType==="touch"&&(r.current=true),R(),l(null);},onPressEnd:e=>{n(),e.pointerType==="touch"&&!i.current&&r.current&&s?.(),r.current=false,l(null);},onFocus:D,onBlur:b$2},decrementButtonProps:{onPressStart:e=>{n(),e.pointerType!=="touch"?(a$2?.(),d("mouse")):(I(window,"pointercancel",N,{capture:true}),r.current=false,d("touch"));},onPressUp:e=>{n(),e.pointerType==="touch"&&(r.current=true),R(),d(null);},onPressEnd:e=>{n(),e.pointerType==="touch"&&!i.current&&r.current&&a$2?.(),r.current=false,d(null);},onFocus:D,onBlur:b$2}}}export{oe as a};
@@ -0,0 +1,10 @@
1
+ import {b as b$4,a as a$7,c as c$4}from'./chunk-WOVAT6U4.mjs';import {c,d,b as b$5,e as e$1,f as f$2}from'./chunk-FJ2JRD3H.mjs';import {e,c as c$2,f as f$1}from'./chunk-O66FNQSB.mjs';import {a as a$9}from'./chunk-AZRPXTYJ.mjs';import {f,d as d$1}from'./chunk-YVYMYKYN.mjs';import {b as b$3}from'./chunk-246VHB32.mjs';import {a as a$1,c as c$3,b as b$7}from'./chunk-6ZV4UYEG.mjs';import {b as b$6}from'./chunk-PAQQ7MQG.mjs';import {a as a$6,b as b$1}from'./chunk-KCHAWPUN.mjs';import {a as a$a}from'./chunk-NSC53QWT.mjs';import {a as a$4}from'./chunk-O7XK2WIX.mjs';import {b as b$2}from'./chunk-N2XGJKZG.mjs';import {a}from'./chunk-66CUIXA6.mjs';import {a as a$3}from'./chunk-RSKKEGJZ.mjs';import {a as a$8}from'./chunk-K6X2BHPP.mjs';import {a as a$2}from'./chunk-3FYY26ED.mjs';import {b,c as c$1}from'./chunk-TZ4MVY4E.mjs';import {a as a$5}from'./chunk-4QEH5CGK.mjs';import B,{useRef,createElement,useContext,useEffect}from'react';import {CheckmarkIcon}from'@baseline-ui/icons/24';import {jsxs,jsx,Fragment}from'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var D=B.forwardRef(({item:e,isDisabled:i,isFocusVisible:o,isSelected:s,liProps:a$6,showSelectedIcon:p,description:m,descriptionProps:u,labelProps:d$1,isFocused:f,isPressed:S,_state:r},n)=>{a(e.value&&a$1(e.value),"Item cannot be a section");let t=useRef(null),{icon:l,label:L}=e.value,{hoverProps:y,isHovered:c$2}=a$2({isDisabled:i},t),M=a$3({"data-selected":s,"data-disabled":i,"data-focused":f,"data-hovered":c$2,"data-pressed":S,"data-focus-visible":o,"data-selection-mode":r.selectionManager.selectionMode});return jsxs("li",{...c$1(a$6,y,M),className:a$5(d({isHovered:c$2,isFocused:o,isFirstChild:r.collection.getFirstKey()===e.key,isLastChild:r.collection.getLastKey()===e.key,isDisabled:i}),a$6.className,"BaselineUI-ListBox-Option"),style:a$6.style,ref:b(n,t),children:[jsxs(a$4,{display:"flex",alignItems:"center",gap:"lg",children:[p?jsx("span",{"aria-hidden":true,style:{height:24,width:24},children:s?jsx(CheckmarkIcon,{size:24}):null}):null,l?jsx(l,{size:24}):null,jsx("span",{...d$1,children:L})]}),m?jsx("span",{className:c({isDisabled:i}),...u,children:m}):null]})});D.displayName="DefaultListOption";var le=({item:e,children:i,state:o,dragState:s,elementRef:a,...p})=>{let{dragProps:m}=d$1({key:e.key},s,a);return jsxs(Fragment,{children:[jsx(c$4,{target:{type:"item",key:e.key,dropPosition:"before"},...p}),i(m),o.collection.getKeyAfter(e.key)==null&&jsx(c$4,{target:{type:"item",key:e.key,dropPosition:"after"},...p})]})};le.displayName="DraggableListOption";var R=B.forwardRef(({item:e$1,renderOption:i=(n,t,l)=>jsx(D,{item:n,liProps:t.optionProps,...t,ref:l}),showSelectedIcon:o,state:s,dragState:a$2,dropState:p,orientation:m,dropIndicatorStyle:u,dropIndicatorClassName:d,optionStyle:f,optionClassName:S},r)=>{let n=B.useRef(null),t=e({key:e$1.key},s,n),{value:l}=e$1;a(l&&a$1(l),"ListSection should not be passed to ListOption");let L={isFocusVisible:t.isFocusVisible,isSelected:t.isSelected,isFocused:t.isFocused,isDisabled:t.isDisabled,isPressed:t.isPressed},y={style:b$1(f,l,L),className:a$6(S,l,L)};return a$2&&p?jsx(le,{orientation:m,state:s,item:e$1,dropState:p,dragState:a$2,elementRef:n,dropIndicatorStyle:u,dropIndicatorClassName:d,children:c=>i(e$1,{...t,showSelectedIcon:o,_state:s,optionProps:{...c$1(t.optionProps,c),...y}},b(n,r))}):i(e$1,{...t,showSelectedIcon:o,_state:s,optionProps:{...t.optionProps,...y}},b(n,r))});R.displayName="Option";var me=({section:e,state:i,sectionClassName:o,sectionStyle:s,showSectionHeader:a$1,renderSectionHeader:p,withSectionHeaderPadding:m=false,...u})=>{let d=B.useRef(null),{itemProps:f,groupProps:S,headingProps:r}=f$1({heading:a$1?p?.(e,d)||e.rendered:void 0,"aria-label":e["aria-label"]}),n=i.collection.getChildren?.(e.key);a(n,"children must be defined");let{value:t}=e;a(t&&b$7(t),"section must be a ListSection");let l=typeof s=="function"?s(t):s,L=typeof o=="function"?o(t):o;return jsxs(Fragment,{children:[e.key===i.collection.getFirstKey()?null:jsx(a$a,{UNSAFE_omitRole:true}),jsxs("li",{...f,style:{...f.style,...l},className:a$5(f$2,L,"BaselineUI-ListBox-Section"),children:[e.rendered&&a$1?p?.(e,d,r)||jsx(a$4,{...r,className:a$5("BaselineUI-ListBox-SectionHeader",e$1),ref:d,paddingX:"lg",typography:"label.md.medium",color:"text.primary",paddingInlineStart:m?"5xl":"lg",paddingInlineEnd:"lg",children:e.rendered}):null,jsx("ul",{...S,children:[...n].map(y=>jsx(R,{item:y,state:i,...u},y.key))})]})]})};var Oe=B.createContext(null),T=B.forwardRef(({className:e,layout:i="stack",orientation:o="vertical",showSelectedIcon:s=true,style:a,renderOption:p,enableReorder:m=false,"data-block-id":u,"data-block-class":d,renderDragPreview:f$1,onReorder:S,state:r,listBoxHandle:n,...t},l)=>{let L=B.useRef(null),{direction:y}=b$2(),c=B.useRef(null),{listBoxProps:M}=c$2({...t,shouldSelectOnPressUp:m,keyboardDelegate:new b$3({collection:r.collection,ref:c,layout:i,orientation:o,direction:y,disabledKeys:r.disabledKeys})},r,c);b$4({handle:n},r,c);let{collectionProps:Le,dragState:ye,dropState:ue}=a$7({...t,onReorder:S,layout:i,orientation:o,enableReorder:m,preview:L},r,c),{isFocusVisible:Se,isFocused:ge,focusProps:xe}=a$8(),Pe=a$3({"data-block-id":u,"data-block-class":d,"data-layout":i,"data-empty":r.collection.size===0,"data-focused":ge,"data-focus-visible":Se,"data-orientation":o});return a$9({ref:c,isDisabled:!m}),jsxs("ul",{...c$1(M,xe,Pe,Le),className:a$5(b$5,"BaselineUI-ListBox",e),style:a,ref:b(l,c),children:[[...r.collection].map(I=>{let E={key:I.key,state:r,dragState:ye,dropState:ue,renderOption:p,renderDropIndicator:t.renderDropIndicator,renderSectionHeader:t.renderSectionHeader,showSelectedIcon:s,orientation:o,dropIndicatorStyle:t.dropIndicatorStyle,dropIndicatorClassName:t.dropIndicatorClassName,optionStyle:t.optionStyle,optionClassName:t.optionClassName,sectionClassName:t.sectionClassName,sectionStyle:t.sectionStyle,showSectionHeader:t.showSectionHeader,withSectionHeaderPadding:t.withSectionHeaderPadding};return I.type==="section"?createElement(me,{...E,key:I.key,section:I}):createElement(R,{...E,key:I.key,item:I})}),f$1?jsx(f,{ref:L,children:f$1}):null]})});T.displayName="ListBoxCore";var de=B.forwardRef((e,i)=>{let o=c$3(),s=b$6({...e,children:o});return jsx(T,{...e,ref:i,state:s})});de.displayName="ListBoxStandalone";var fe=B.forwardRef((e,i)=>{let o=useContext(Oe);return useEffect(()=>{if(!e.items&&!o)throw new Error("ListBox: You must provide a `state` or `items` prop to render the listbox.")},[e.items,o]),o?jsx(T,{...e,ref:i,state:o}):jsx(de,{...e,ref:i})});fe.displayName="ListBox";export{D as a,Oe as b,fe as c};
@@ -0,0 +1,10 @@
1
+ import {a as a$4}from'./chunk-2JANDORZ.mjs';import {b}from'./chunk-J7EAQSKX.mjs';import {c}from'./chunk-IW4GXU75.mjs';import {a}from'./chunk-EX2LI2CV.mjs';import {a as a$2}from'./chunk-RSKKEGJZ.mjs';import {a as a$1}from'./chunk-K6X2BHPP.mjs';import {c as c$1}from'./chunk-TZ4MVY4E.mjs';import {a as a$3}from'./chunk-4QEH5CGK.mjs';import g from'react';import {jsx}from'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var M=g.forwardRef(({className:R,validationState:t,variant:E="primary",labelPosition:s="top",inputStyle:i,inputClassName:F,isMultiLine:r=false,rows:H,"data-block-id":A,"data-block-class":N,...e},L)=>{let a$5=g.useRef(null),{inputProps:l,labelProps:k,descriptionProps:v,errorMessageProps:h,validationErrors:D}=a({...e,inputElementType:r?"textarea":"input",validationState:t?t==="error"?"invalid":"valid":void 0},a$5),m=e.errorMessage||D.join(" "),O=b({...e,errorMessage:m,descriptionProps:v,errorMessageProps:h,labelPosition:s});m&&(t="error");let{isFocused:u,focusProps:d,isFocusVisible:j}=a$1(),c$2=a$2({"data-readonly":e.isReadOnly,"data-disabled":e.isDisabled,"data-validation-state":t,"data-focused":u,"data-focus-visible":j}),f=a$3(c({isDisabled:e.isDisabled,labelPosition:s,isMultiLine:r}),"BaselineUI-TextInput-Input",F);return jsx(a$4,{variant:E,labelProps:k,isFocused:u,message:O,ref:L,labelPosition:s,className:a$3("BaselineUI-TextInput",R),validationState:t,isMultiLine:r,"data-block-id":A,"data-block-class":N,...e,children:r?jsx("textarea",{...c$1(l,d,c$2),className:f,style:i,rows:H,ref:a$5}):jsx("input",{...c$1(l,d,c$2),className:f,style:i,ref:a$5})})});M.displayName="TextInput";export{M as a};
@@ -0,0 +1,10 @@
1
+ import o,{useState,useContext,useRef}from'react';import'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var u={prefix:String(Math.round(Math.random()*1e10)),current:0},s=o.createContext(u),f=o.createContext(false);var l=!!(typeof window<"u"&&window.document&&window.document.createElement),a=new WeakMap;function p(r=false){let t=useContext(s),n=useRef(null);if(n.current===null&&!r){let e=o.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED?.ReactCurrentOwner?.current;if(e){let i=a.get(e);i==null?a.set(e,{id:t.current,state:e.memoizedState}):e.memoizedState!==i.state&&(t.current=i.id,a.delete(e));}n.current=++t.current;}return n.current}function R(r){let t=useContext(s);t===u&&!l&&process.env.NODE_ENV!=="production"&&console.warn("When server rendering, you must wrap your application in an <SSRProvider> to ensure consistent ids are generated between the client and server.");let n=p(!!r),e=t===u&&process.env.NODE_ENV==="test"?"react-aria":`react-aria${t.prefix}`;return r||`${e}-${n}`}function v(r){let t=o.useId(),[n]=useState(y()),e=n||process.env.NODE_ENV==="test"?"react-aria":`react-aria${u.prefix}`;return r||`${e}-${t}`}var P=typeof o.useId=="function"?v:R;function x(){return false}function E(){return true}function m(r){return ()=>{}}function y(){return typeof o.useSyncExternalStore=="function"?o.useSyncExternalStore(m,x,E):useContext(f)}export{P as a,y as b};
@@ -0,0 +1,10 @@
1
+ import {a}from'./chunk-FXCHST4Z.mjs';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var o=a({defaultClassName:"mnnh5s1 _1yep5z6id _1yep5z6ie _1yep5z6if _1yep5z6la _1yep5z6ld _1yep5z6lp _1yep5z6lo _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6kd _1yep5z6ke _1yep5z6kf _1yep5z6ln",variantClassNames:{isInline:{true:"mnnh5s2 _1yep5z6wo _1yep5z6wp _1yep5z6wq _1yep5z6xc _1yep5z6xd _1yep5z6xe _1yep5z6y0 _1yep5z6y1 _1yep5z6y2 _1yep5z6yo _1yep5z6yp _1yep5z6yq _1yep5z6138 _1yep5z6183 _1yep5z6184",false:"_1yep5z617q _1yep5z6127"},isHovered:{true:"mnnh5s4"},hasLoadedImage:{true:"_1yep5z6126"},includeCheckeredBackground:{true:"mnnh5s6"},showFocusRing:{true:"_1yep5z613j _1yep5z617w _1yep5z617u _1yep5z6140 _1yep5z617x"},isDisabled:{true:"mnnh5s8 _1yep5z6zd"}},defaultVariants:{},compoundVariants:[[{isHovered:true,hasLoadedImage:false},"_1yep5z61oh"],[{isHovered:true,hasLoadedImage:true},"mnnh5s9"],[{isInline:true,isDisabled:true},"_1yep5z61pb"],[{hasLoadedImage:true,includeCheckeredBackground:true},"_1yep5z61o9"]]}),p="_1yep5z6d8",t=a({defaultClassName:"mnnh5sa",variantClassNames:{isInline:{true:"mnnh5sb",false:"mnnh5sc"},isDisabled:{true:"mnnh5sd"},hasLoadedImage:{true:"mnnh5s0"}},defaultVariants:{},compoundVariants:[]});export{o as a,p as b,t as c};
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function r(n){return Object.fromEntries(Object.entries(n).filter(([,e])=>!!e))}function t(n,e){return typeof n=="boolean"?n?e:void 0:{...e,...n}}export{r as a,t as b};
@@ -0,0 +1,10 @@
1
+ import {useRef,useCallback,useMemo}from'react';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function a(e){let u=useRef(null),t=useRef(void 0),l=useCallback(n=>{if(typeof e=="function"){let r=e,c=r(n);return ()=>{typeof c=="function"?c():r(null);}}else if(e)return e.current=n,()=>{e.current=null;}},[e]);return useMemo(()=>({get current(){return u.current},set current(n){u.current=n,t.current&&(t.current(),t.current=void 0),n!=null&&(t.current=l(n));}}),[l])}export{a};
@@ -0,0 +1,10 @@
1
+ import {t}from'./chunk-MRJFGHFW.mjs';import {useEffect}from'react';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function u(e,t$1,r,n){let l=t(r),s=r==null;useEffect(()=>{if(s||!e.current)return;let E=e.current;return E.addEventListener(t$1,l,n),()=>{E.removeEventListener(t$1,l,n);}},[e,t$1,n,s]);}export{u as a};
@@ -0,0 +1,10 @@
1
+ import {a as a$3}from'./chunk-N5RZGO7Y.mjs';import {c}from'./chunk-PHZZLBH3.mjs';import {a as a$2}from'./chunk-OAY74XPB.mjs';import {b}from'./chunk-QMDDCVAF.mjs';import {a as a$1}from'./chunk-K6X2BHPP.mjs';import {b as b$1,c as c$1}from'./chunk-TZ4MVY4E.mjs';import {a as a$5}from'./chunk-AUOQSTS5.mjs';import {a}from'./chunk-FXCHST4Z.mjs';import {a as a$4}from'./chunk-4QEH5CGK.mjs';import {assignInlineVars}from'@vanilla-extract/dynamic';import f,{useContext,useMemo,useState,useEffect}from'react';import {jsx}from'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var h="var(--cjv3et0)",k=a({defaultClassName:"cjv3et1 _1yep5z6al _1yep5z6am _1yep5z6an _1yep5z6b9 _1yep5z6ba _1yep5z6bb _1yep5z6bx _1yep5z6by _1yep5z6bz _1yep5z6cl _1yep5z6cm _1yep5z6cn _1yep5z6g1 _1yep5z6lz _1yep5z6m1",variantClassNames:{size:{sm:"cjv3et2",md:"cjv3et3",lg:"cjv3et4",content:"cjv3et5"},variant:{primary:"_1yep5z6137",ghost:"cjv3et7"},overlayType:{modal:"cjv3et8",popover:"cjv3et9"},isDrawer:{true:"cjv3eta _1yep5z6yi _1yep5z6yj _1yep5z6yk _1yep5z6z6 _1yep5z6z7 _1yep5z6z8 _1yep5z617q"},isFocusVisible:{true:"_1yep5z61q3 _1yep5z61tx _1yep5z61tz _1yep5z61u1"}},defaultVariants:{},compoundVariants:[]});function H(e,o){let t=e["aria-label"],r=e["aria-labelledby"],[s,i]=useState(()=>t||"");return useEffect(()=>{if(t){i(t);return}if(!r){i("");return}let a=o?.current?.getRootNode()??a$5(null),p=r.replaceAll(":",String.raw`\:`),m=a.querySelector(`#${p}`);if(m?.textContent){i(m.textContent);return}let l=a$5(null),y=a===l?l.body:a,n=new MutationObserver(()=>{let c=a.querySelector(`#${p}`);c?.textContent&&(i(c.textContent),n.disconnect());});return n.observe(y,{childList:true,subtree:true}),()=>{n.disconnect();}},[t,r,o]),s}var v=f.createContext({titleProps:{}}),F=f.forwardRef(({children:e,className:o,style:t,inheritDrawer:r,size:s="md",variant:i="primary","data-block-id":a,"data-block-class":p,drawerBackground:m,...l},y)=>{let n=f.useRef(null),c$2=f.useRef(null),{containerWidth:x,shouldContainOverlays:W}=useContext(b),{isDrawer:d,closeDrawer:U,dialogStyle:C,setDialogElement:R,isWithinModal:w}=useContext(c),$=H(l,c$2),{focusProps:A,isFocusVisible:P}=a$1(),{dialogProps:I,titleProps:T}=a$2(l,n),B=useMemo(()=>({titleProps:T}),[T]);return d&&r?jsx(a$3,{title:$,onCloseRequest:U,className:o,style:C,...l,"data-drawer":true,"data-block-id":a,"data-block-class":p,ref:b$1(y,c$2,g=>{R(g);}),background:m,children:e}):jsx(v.Provider,{value:B,children:jsx("section",{...c$1(I,A),"data-block-id":a,"data-block-class":p,"data-focus-visible":P,"data-overlay-type":w?"modal":"popover",ref:b$1(n,y,g=>{R(g);}),style:{...C,...t,...assignInlineVars({[h]:x&&W?`${x}px`:"100vw"})},className:a$4(k({size:d?"content":s,variant:i,isDrawer:d,isFocusVisible:P,overlayType:w?"modal":"popover"}),"BaselineUI-Dialog",o),children:e})})});F.displayName="Dialog";var O=f.forwardRef(({children:e,className:o,style:t},r)=>{let{titleProps:s}=useContext(v);return f.isValidElement(e)?f.cloneElement(e,{...s,ref:r,className:a$4(e.props.className,o),style:{...e.props.style,...t}}):jsx("h3",{...s,ref:r,className:o,style:t,children:e})});O.displayName="DialogTitle";export{F as a,O as b};
@@ -0,0 +1,10 @@
1
+ import {a}from'./chunk-CGFLGZL4.mjs';import {c}from'./chunk-TZ4MVY4E.mjs';import {e}from'./chunk-JDLUGVXG.mjs';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function M(e$1){let{description:o,errorMessage:t,isInvalid:a$1,validationState:s,ref:l}=e$1,{labelProps:f,fieldProps:r}=a(e$1),d=e([!!o,!!t,a$1,s],l),n=e([!!o,!!t,a$1,s],l);return r=c(r,{"aria-describedby":[d,n,e$1["aria-describedby"]].filter(Boolean).join(" ")||void 0}),{labelProps:f,fieldProps:r,descriptionProps:{id:d},errorMessageProps:{id:n}}}export{M as a};
@@ -0,0 +1,10 @@
1
+ import {a as a$2}from'./chunk-RCBUNCHV.mjs';import {c,h,e}from'./chunk-B7PSE5KC.mjs';import {b as b$2}from'./chunk-BGMVPFYK.mjs';import {a}from'./chunk-RT4LMB6X.mjs';import {a as a$1}from'./chunk-JDLUGVXG.mjs';import {b as b$1}from'./chunk-RMUV6NJJ.mjs';import Y,{createContext,forwardRef,useContext,useState,useRef,useCallback,useMemo,cloneElement,isValidElement}from'react';import {flushSync,createPortal}from'react-dom';import {useSyncExternalStore}from'use-sync-external-store/shim/index.js';import {jsx,Fragment,jsxs}from'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var y=class{static type;type;key;value=null;level=0;hasChildNodes=false;rendered=null;textValue="";"aria-label"=void 0;index=0;parentKey=null;prevKey=null;nextKey=null;firstChildKey=null;lastChildKey=null;props={};render;colSpan=null;colIndex=null;constructor(e){this.type=this.constructor.type,this.key=e;}get childNodes(){throw new Error("childNodes is not supported")}clone(){let e=new this.constructor(this.key);return e.value=this.value,e.level=this.level,e.hasChildNodes=this.hasChildNodes,e.rendered=this.rendered,e.textValue=this.textValue,e["aria-label"]=this["aria-label"],e.index=this.index,e.parentKey=this.parentKey,e.prevKey=this.prevKey,e.nextKey=this.nextKey,e.firstChildKey=this.firstChildKey,e.lastChildKey=this.lastChildKey,e.props=this.props,e.render=this.render,e.colSpan=this.colSpan,e.colIndex=this.colIndex,e}filter(e,t,i){let n=this.clone();return t.addDescendants(n,e),n}},b=class extends y{filter(e,t,i){let[n,o]=G(e,t,this.firstChildKey,i),r=this.clone();return r.firstChildKey=n,r.lastChildKey=o,r}},V=class extends y{static type="header"},A=class extends y{static type="loader"},H=class extends b{static type="item";filter(e,t,i){if(i(this.textValue,this)){let n=this.clone();return t.addDescendants(n,e),n}return null}},L=class extends b{static type="section";filter(e,t,i){let n=super.filter(e,t,i);if(n&&n.lastChildKey!==null){let o=e.getItem(n.lastChildKey);if(o&&o.type!=="header")return n}return null}},N=class{keyMap=new Map;firstKey=null;lastKey=null;frozen=false;itemCount=0;get size(){return this.itemCount}getKeys(){return this.keyMap.keys()}*[Symbol.iterator](){let e=this.firstKey!=null?this.keyMap.get(this.firstKey):void 0;for(;e;)yield e,e=e.nextKey!=null?this.keyMap.get(e.nextKey):void 0;}getChildren(e){let t=this.keyMap;return {*[Symbol.iterator](){let i=t.get(e),n=i?.firstChildKey!=null?t.get(i.firstChildKey):null;for(;n;)yield n,n=n.nextKey!=null?t.get(n.nextKey):void 0;}}}getKeyBefore(e){let t=this.keyMap.get(e);if(!t)return null;if(t.prevKey!=null){for(t=this.keyMap.get(t.prevKey);t&&t.type!=="item"&&t.lastChildKey!=null;)t=this.keyMap.get(t.lastChildKey);return t?.key??null}return t.parentKey}getKeyAfter(e){let t=this.keyMap.get(e);if(!t)return null;if(t.type!=="item"&&t.firstChildKey!=null)return t.firstChildKey;for(;t;){if(t.nextKey!=null)return t.nextKey;if(t.parentKey!=null)t=this.keyMap.get(t.parentKey);else return null}return null}getFirstKey(){return this.firstKey}getLastKey(){let e=this.lastKey!=null?this.keyMap.get(this.lastKey):null;for(;e?.lastChildKey!=null;)e=this.keyMap.get(e.lastChildKey);return e?.key??null}getItem(e){return this.keyMap.get(e)??null}at(){throw new Error("Not implemented")}clone(){let e=this.constructor,t=new e;return t.keyMap=new Map(this.keyMap),t.firstKey=this.firstKey,t.lastKey=this.lastKey,t.itemCount=this.itemCount,t}addNode(e){if(this.frozen)throw new Error("Cannot add a node to a frozen collection");e.type==="item"&&this.keyMap.get(e.key)==null&&this.itemCount++,this.keyMap.set(e.key,e);}addDescendants(e,t){this.addNode(e);let i=t.getChildren(e.key);for(let n of i)this.addDescendants(n,t);}removeNode(e){if(this.frozen)throw new Error("Cannot remove a node to a frozen collection");let t=this.keyMap.get(e);t!=null&&t.type==="item"&&this.itemCount--,this.keyMap.delete(e);}commit(e,t,i=false){if(this.frozen)throw new Error("Cannot commit a frozen collection");this.firstKey=e,this.lastKey=t,this.frozen=!i;}filter(e){let t=new this.constructor,[i,n]=G(this,t,this.firstKey,e);return t?.commit(i,n),t}};function G(l,e,t,i){if(t==null)return [null,null];let n=null,o=null,r=l.getItem(t);for(;r!=null;){let s=r.filter(l,e,i);s!=null&&(s.nextKey=null,o&&(s.prevKey=o.key,o.nextKey=s.key),n==null&&(n=s),e.addNode(s),o=s),r=r.nextKey!=null?l.getItem(r.nextKey):null;}if(o&&o.type==="separator"){let s=o.prevKey;e.removeNode(o.key),s!=null?(o=e.getItem(s),o.nextKey=null):o=null;}return [n?.key??null,o?.key??null]}var w=class{_firstChild=null;_lastChild=null;_previousSibling=null;_nextSibling=null;_parentNode=null;_minInvalidChildIndex=null;ownerDocument;constructor(e){this.ownerDocument=e;}*[Symbol.iterator](){let e=this.firstChild;for(;e;)yield e,e=e.nextSibling;}get firstChild(){return this._firstChild}set firstChild(e){this._firstChild=e,this.ownerDocument.markDirty(this);}get lastChild(){return this._lastChild}set lastChild(e){this._lastChild=e,this.ownerDocument.markDirty(this);}get previousSibling(){return this._previousSibling}set previousSibling(e){this._previousSibling=e,this.ownerDocument.markDirty(this);}get nextSibling(){return this._nextSibling}set nextSibling(e){this._nextSibling=e,this.ownerDocument.markDirty(this);}get parentNode(){return this._parentNode}set parentNode(e){this._parentNode=e,this.ownerDocument.markDirty(this);}get isConnected(){return this.parentNode?.isConnected||false}invalidateChildIndices(e){(this._minInvalidChildIndex==null||!this._minInvalidChildIndex.isConnected||e.index<this._minInvalidChildIndex.index)&&(this._minInvalidChildIndex=e,this.ownerDocument.markDirty(this));}updateChildIndices(){let e=this._minInvalidChildIndex;for(;e;)e.index=e.previousSibling?e.previousSibling.index+1:0,e=e.nextSibling;this._minInvalidChildIndex=null;}appendChild(e){e.parentNode&&e.parentNode.removeChild(e),this.firstChild==null&&(this.firstChild=e),this.lastChild?(this.lastChild.nextSibling=e,e.index=this.lastChild.index+1,e.previousSibling=this.lastChild):(e.previousSibling=null,e.index=0),e.parentNode=this,e.nextSibling=null,this.lastChild=e,this.ownerDocument.markDirty(this),this.isConnected&&this.ownerDocument.queueUpdate();}insertBefore(e,t){if(t==null)return this.appendChild(e);e.parentNode&&e.parentNode.removeChild(e),e.nextSibling=t,e.previousSibling=t.previousSibling,e.index=t.index-1,this.firstChild===t?this.firstChild=e:t.previousSibling&&(t.previousSibling.nextSibling=e),t.previousSibling=e,e.parentNode=t.parentNode,this.invalidateChildIndices(e),this.isConnected&&this.ownerDocument.queueUpdate();}removeChild(e){e.parentNode===this&&(this._minInvalidChildIndex===e&&(this._minInvalidChildIndex=null),e.nextSibling&&(this.invalidateChildIndices(e.nextSibling),e.nextSibling.previousSibling=e.previousSibling),e.previousSibling&&(e.previousSibling.nextSibling=e.nextSibling),this.firstChild===e&&(this.firstChild=e.nextSibling),this.lastChild===e&&(this.lastChild=e.previousSibling),e.parentNode=null,e.nextSibling=null,e.previousSibling=null,e.index=0,this.ownerDocument.markDirty(e),this.isConnected&&this.ownerDocument.queueUpdate());}addEventListener(){}removeEventListener(){}get previousVisibleSibling(){let e=this.previousSibling;for(;e&&e.isHidden;)e=e.previousSibling;return e}get nextVisibleSibling(){let e=this.nextSibling;for(;e&&e.isHidden;)e=e.nextSibling;return e}get firstVisibleChild(){let e=this.firstChild;for(;e&&e.isHidden;)e=e.nextSibling;return e}get lastVisibleChild(){let e=this.lastChild;for(;e&&e.isHidden;)e=e.previousSibling;return e}},T=class l extends w{nodeType=8;node;isMutated=true;_index=0;isHidden=false;constructor(e,t){super(t),this.node=null;}get index(){return this._index}set index(e){this._index=e,this.ownerDocument.markDirty(this);}get level(){return this.parentNode instanceof l?this.parentNode.level+(this.parentNode.node?.type==="item"?1:0):0}getMutableNode(){return this.node==null?null:(this.isMutated||(this.node=this.node.clone(),this.isMutated=true),this.ownerDocument.markDirty(this),this.node)}updateNode(){let e=this.nextVisibleSibling,t=this.getMutableNode();if(t!=null&&(t.index=this.index,t.level=this.level,t.parentKey=this.parentNode instanceof l?this.parentNode.node?.key??null:null,t.prevKey=this.previousVisibleSibling?.node?.key??null,t.nextKey=e?.node?.key??null,t.hasChildNodes=!!this.firstChild,t.firstChildKey=this.firstVisibleChild?.node?.key??null,t.lastChildKey=this.lastVisibleChild?.node?.key??null,(t.colSpan!=null||t.colIndex!=null)&&e)){let i=(t.colIndex??t.index)+(t.colSpan??1);if(e.node!=null&&i!==e.node.colIndex){let n=e.getMutableNode();n.colIndex=i;}}}setProps(e,t,i,n,o){let r,{value:s,textValue:a,id:p,...d}=e;if(this.node==null?(r=new i(p??`react-aria-${++this.ownerDocument.nodeId}`),this.node=r):r=this.getMutableNode(),d.ref=t,r.props=d,r.rendered=n,r.render=o,r.value=s,e["aria-label"]&&(r["aria-label"]=e["aria-label"]),r.textValue=a||(typeof d.children=="string"?d.children:"")||e["aria-label"]||"",p!=null&&p!==r.key)throw new Error("Cannot change the id of an item");d.colSpan!=null&&(r.colSpan=d.colSpan),this.isConnected&&this.ownerDocument.queueUpdate();}get style(){let e=this;return {get display(){return e.isHidden?"none":""},set display(t){let i=t==="none";if(e.isHidden!==i){(e.parentNode?.firstVisibleChild===e||e.parentNode?.lastVisibleChild===e)&&e.ownerDocument.markDirty(e.parentNode);let n=e.previousVisibleSibling,o=e.nextVisibleSibling;n&&e.ownerDocument.markDirty(n),o&&e.ownerDocument.markDirty(o),e.isHidden=i,e.ownerDocument.markDirty(e);}}}}hasAttribute(){}setAttribute(){}setAttributeNS(){}removeAttribute(){}},I=class extends w{nodeType=11;ownerDocument=this;dirtyNodes=new Set;isSSR=false;nodeId=0;nodesByProps=new WeakMap;collection;nextCollection=null;subscriptions=new Set;queuedRender=false;inSubscription=false;constructor(e){super(null),this.collection=e,this.nextCollection=e;}get isConnected(){return true}createElement(e){return new T(e,this)}getMutableCollection(){return this.nextCollection||(this.nextCollection=this.collection.clone()),this.nextCollection}markDirty(e){this.dirtyNodes.add(e);}addNode(e){if(e.isHidden||e.node==null)return;let t=this.getMutableCollection();if(!t.getItem(e.node.key))for(let i of e)this.addNode(i);t.addNode(e.node);}removeNode(e){for(let t of e)this.removeNode(t);e.node&&this.getMutableCollection().removeNode(e.node.key);}getCollection(){return this.inSubscription?this.collection:(this.queuedRender=false,this.updateCollection(),this.collection)}updateCollection(){for(let e of this.dirtyNodes)e instanceof T&&(!e.isConnected||e.isHidden)?this.removeNode(e):e.updateChildIndices();for(let e of this.dirtyNodes)e instanceof T?(e.isConnected&&!e.isHidden&&(e.updateNode(),this.addNode(e)),e.node&&this.dirtyNodes.delete(e),e.isMutated=false):this.dirtyNodes.delete(e);this.nextCollection&&(this.nextCollection.commit(this.firstVisibleChild?.node?.key??null,this.lastVisibleChild?.node?.key??null,this.isSSR),this.isSSR||(this.collection=this.nextCollection,this.nextCollection=null));}queueUpdate(){if(!(this.dirtyNodes.size===0||this.queuedRender)){this.queuedRender=true,this.inSubscription=true,this.isSSR||(this.collection=this.collection.clone());for(let e of this.subscriptions)e();this.inSubscription=false;}}subscribe(e){return this.subscriptions.add(e),()=>this.subscriptions.delete(e)}resetAfterSSR(){this.isSSR&&(this.isSSR=false,this.firstChild=null,this.lastChild=null,this.nodeId=0);}};function v(l){let{children:e,items:t,idScope:i,addIdAndValue:n,dependencies:o=[]}=l,r=useMemo(()=>process.env.NODE_ENV!=="production"&&typeof e=="function"?e.toString():void 0,[e]),s=useMemo(()=>new WeakMap,[...o,r]);return useMemo(()=>{if(t&&typeof e=="function"){let a=[];for(let p of t){let d=xe(p)?p:null,u=d?s.get(d):null;if(!u){u=e(p);let f=u.props.id??p?.key??p?.id;i!=null&&u.props.id==null&&f!=null&&(f=i+":"+f);let K=f??a.length;u=cloneElement(u,n?{key:K,id:f,value:p}:{key:K}),d&&s.set(d,u);}a.push(u);}return a}else if(typeof e!="function")return e},[e,t,s,i,n])}function xe(l){switch(typeof l){case "object":return l!=null;case "function":case "symbol":return true;default:return false}}var te=createContext(false),D=createContext(null);function Te(l){if(useContext(D))return l.content;let{collection:t,document:i}=Ke(l.createCollection);return jsxs(Fragment,{children:[jsx(a$2,{children:jsx(D.Provider,{value:i,children:l.content})}),jsx(ve,{render:l.children,collection:t})]})}function ve({collection:l,render:e}){return e(l)}function Re(l,e,t){let i=b$1(),n=useRef(i);n.current=i;let o=useCallback(()=>n.current?t():e(),[e,t]);return useSyncExternalStore(l,o)}var De=typeof Y.useSyncExternalStore=="function"?Y.useSyncExternalStore:Re;function Ke(l){let[e]=useState(()=>new I(l?.()||new N)),t=useCallback(r=>e.subscribe(r),[e]),i=useCallback(()=>{let r=e.getCollection();return e.isSSR&&e.resetAfterSSR(),r},[e]),n=useCallback(()=>(e.isSSR=true,e.getCollection()),[e]);return {collection:De(t,i,n),document:e}}var O=createContext(null);function Ee(l){return class extends y{static type=l}}function ne(l,e,t,i,n,o){typeof l=="string"&&(l=Ee(l));let r=useCallback(a=>{a?.setProps(e,t,l,i,o);},[e,t,i,o,l]),s=useContext(O);if(s){let a=s.ownerDocument.nodesByProps.get(e);return a||(a=s.ownerDocument.createElement(l.type),a.setProps(e,t,l,i,o),s.appendChild(a),s.ownerDocument.updateCollection(),s.ownerDocument.nodesByProps.set(e,a)),n?jsx(O.Provider,{value:a,children:n}):null}return jsx(l.type,{ref:r,children:n})}function we(l,e){let t=({node:n})=>e(n.props,n.props.ref,n),i=forwardRef((n,o)=>{let r=useContext(b$2);if(!useContext(te)){if(e.length>=3)throw new Error(e.name+" cannot be rendered outside a collection.");return e(n,o)}return ne(l,n,o,"children"in n?n.children:null,null,a=>jsx(b$2.Provider,{value:r,children:jsx(t,{node:a})}))});return i.displayName=e.name,i}function Ie(l,e,t=le){let i=({node:o})=>e(o.props,o.props.ref,o),n=forwardRef((o,r)=>{let s=t(o);return ne(l,o,r,null,s,a=>jsx(i,{node:a}))??jsx(Fragment,{})});return n.displayName=e.name,n}function le(l){return v({...l,addIdAndValue:true})}var Q=createContext(null);function Pe(l){let e=useContext(Q),t=(e?.dependencies||[]).concat(l.dependencies),i=l.idScope??e?.idScope,n=le({...l,idScope:i,dependencies:t});return useContext(D)&&(n=jsx(ke,{children:n})),e=useMemo(()=>({dependencies:t,idScope:i}),[i,...t]),jsx(Q.Provider,{value:e,children:n})}function ke({children:l}){let e=useContext(D),t=useMemo(()=>jsx(D.Provider,{value:null,children:jsx(te.Provider,{value:true,children:l})}),[l]);return b$1()?jsx(O.Provider,{value:e,children:t}):createPortal(t,e)}var Ot=createContext(null);var Ae={CollectionRoot({collection:l,renderDropIndicator:e}){return oe(l,null,e)},CollectionBranch({collection:l,parent:e,renderDropIndicator:t}){return oe(l,e,t)}};function oe(l,e,t){return v({items:e?l.getChildren(e.key):l,dependencies:[t],children(i){if(i.type==="content")return jsx(Fragment,{});let n=i.render(i);return !t||i.type!=="item"?n:jsxs(Fragment,{children:[t({type:"item",key:i.key,dropPosition:"before"}),n,He(l,i,t)]})}})}function He(l,e,t){let i=e.key,n=l.getKeyAfter(i),o=n!=null?l.getItem(n):null;for(;o!=null&&o.type!=="item";)n=l.getKeyAfter(o.key),o=n!=null?l.getItem(n):null;let r=e.nextKey!=null?l.getItem(e.nextKey):null;for(;r!=null&&r.type!=="item";)r=r.nextKey!=null?l.getItem(r.nextKey):null;let s=[];if(r==null){let a=e;for(;a?.type==="item"&&(!o||a.parentKey!==o.parentKey&&o.level<a.level);){let p=t({type:"item",key:a.key,dropPosition:"after"});isValidElement(p)&&s.push(cloneElement(p,{key:`${a.key}-after`})),a=a.parentKey!=null?l.getItem(a.parentKey):null;}}return s}var qt=createContext(Ae);function zt(l){return useMemo(()=>l!=null?new Set([l]):null,[l])}var Zt=createContext({}),Je=createContext(null),We=forwardRef(function(e,t){let{render:i}=useContext(Je);return jsx(Fragment,{children:i(e,t)})});function en(l,e){let t=l?.renderDropIndicator,i=l?.isVirtualDragging?.(),n=useCallback(o=>{if(i||e?.isDropTarget(o))return t?t(o):jsx(We,{target:o})},[e?.target,i,t]);return l?.useDropIndicator?n:void 0}function tn(l,e,t){let i=l.focusedKey,n=null;if(e?.isVirtualDragging?.()&&t?.target?.type==="item"&&(n=t.target.key,t.target.dropPosition==="after")){let o=t.collection.getKeyAfter(n),r=null;if(o!=null){let s=t.collection.getItem(n)?.level??0;for(;o!=null;){let a=t.collection.getItem(o);if(!a)break;if(a.type!=="item"){o=t.collection.getKeyAfter(o);continue}if((a.level??0)<=s)break;r=o,o=t.collection.getKeyAfter(o);}}n=o??r??n;}return useMemo(()=>new Set([i,n].filter(o=>o!=null)),[i,n])}var ce=createContext(null);function xn(l){let e=useRef({});return jsx(ce.Provider,{value:e,children:l.children})}var pe=forwardRef(function(e,t){let{name:i,isVisible:n=true,children:o,className:r,style:s,render:a$2,...p}=e,[d,u]=useState(n?"visible":"hidden"),f=useContext(ce);if(!f)throw new Error("<SharedElement> must be rendered inside a <SharedElementTransition>");n&&d==="hidden"&&u("visible"),t=a(t),a$1(()=>{let c=t.current,S=f.current,E=S?.[i],g=null;if(c&&n&&E){u("visible");let C=c.getAnimations(),k=E.style.map(([m,M])=>{let me=c.style[m];if(m==="translate"){let q=E.rect,z=c.getBoundingClientRect(),fe=q.left-z?.left,ye=q.top-z?.top;c.style.translate=`${fe}px ${ye}px`;}else c.style[m]=M;return [m,me]});for(let m of c.getAnimations())C.includes(m)||m.cancel();g=requestAnimationFrame(()=>{g=null;for(let[m,M]of k)c.style[m]=M;}),delete S?.[i];}else c&&n&&!E?(queueMicrotask(()=>flushSync(()=>u("entering"))),g=requestAnimationFrame(()=>{g=null,u("visible");})):c&&!n&&queueMicrotask(()=>{S?.[i]?(delete S?.[i],flushSync(()=>u("exiting")),Promise.all(c.getAnimations().map(C=>C.finished)).then(()=>u("hidden")).catch(()=>{})):u("hidden");});return ()=>{if(g!=null&&cancelAnimationFrame(g),c&&c.isConnected&&!c.hasAttribute("data-exiting")){let C=window.getComputedStyle(c);if(C.transitionProperty!=="none"){let k=C.transitionProperty.split(/\s*,\s*/);S[i]={rect:c.getBoundingClientRect(),style:k.map(m=>[m,C[m]])};}}}},[t,f,i,n]);let K=c({children:o,className:r,style:s,render:a$2,values:{isEntering:d==="entering",isExiting:d==="exiting"}});return d==="hidden"?null:jsx(h.div,{...p,...K,ref:t,"data-entering":d==="entering"||void 0,"data-exiting":d==="exiting"||void 0})});var tt=createContext({isSelected:false});forwardRef(function(e$1,t){[e$1,t]=e(e$1,t,tt);let{isSelected:i,...n}=e$1;return jsx(pe,{...n,ref:t,className:e$1.className||"react-aria-SelectionIndicator",name:"SelectionIndicator",isVisible:i})});export{y as a,b,V as c,A as d,H as e,L as f,N as g,v as h,Te as i,we as j,Ie as k,Pe as l,Ot as m,Ae as n,He as o,qt as p,zt as q,Zt as r,Je as s,We as t,en as u,tn as v,xn as w,tt as x};
@@ -0,0 +1,10 @@
1
+ import {a as a$2}from'./chunk-TEQE6WCH.mjs';import {i}from'./chunk-AMQX3KZR.mjs';import {c,b as b$2}from'./chunk-EK3RIYMV.mjs';import {c as c$1,b as b$3,a as a$3}from'./chunk-WOVAT6U4.mjs';import {d,f}from'./chunk-YVYMYKYN.mjs';import {c as c$2}from'./chunk-6ZV4UYEG.mjs';import {b as b$1}from'./chunk-PAQQ7MQG.mjs';import {a as a$4}from'./chunk-66CUIXA6.mjs';import {a as a$1}from'./chunk-RT4LMB6X.mjs';import {c as c$3}from'./chunk-TZ4MVY4E.mjs';import {a}from'./chunk-FXCHST4Z.mjs';import {a as a$5}from'./chunk-4QEH5CGK.mjs';import b from'react';import {jsx,jsxs}from'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var T=a({defaultClassName:"byycd01 _1yep5z6d6 _1yep5z6is _1yep5z6it _1yep5z6iu _1yep5z6jj _1yep5z6jk _1yep5z6jl _1yep5z6id _1yep5z6ie _1yep5z6if",variantClassNames:{},defaultVariants:{},compoundVariants:[]});var P=b.forwardRef(({enableReorder:e,...t},r)=>e?jsx(A,{ref:r,...t}):jsx(k,{ref:r,...t}));P.displayName="GridListItem";var k=b.forwardRef(({item:e,state:t,dropState:r,renderGridItem:i,dragHandleProps:s},n)=>{let m=a$1(n),p=c({node:e},t,m),y=t.selectionManager.selectionMode!=="none"&&t.selectionManager.selectionBehavior==="toggle",{checkboxProps:f}=a$2({key:e.key},t),g={...p,checkBoxProps:y?f:void 0,dragHandleProps:s};return jsxs("div",{"data-grid-list-item-key":e.key,children:[r?jsx(c$1,{target:{type:"item",key:e.key,dropPosition:"before"},dropState:r}):null,i?i(e,g,m):null,r&&t.collection.getKeyAfter(e.key)==null?jsx(c$1,{target:{type:"item",key:e.key,dropPosition:"after"},dropState:r}):null]},e.key)});k.displayName="BaseGridListItem";var A=b.forwardRef(({dragState:e,item:t,...r},i)=>{let s=a$1(i),n=d({key:t.key,hasDragButton:true},e,s);return jsx(k,{item:t,dragHandleProps:n,ref:s,...r})});A.displayName="DraggableGridListItem";var Z=e=>{e.key==="Enter"||e.key==="Escape"||e.stopPropagation();},j=b.forwardRef(({className:e,style:t,isEditing:r=false,"data-block-id":i$1,"data-block-class":s,gridListHandle:n,onReorder:m,enableReorder:p=false,layout:y="stack",orientation:f$1="vertical",renderGridItem:g,...L},U)=>{let V=c$2(),o=b$1({...L,children:V}),I=b.useRef(null),c=a$1(U),{gridProps:v}=b$2(L,o,c);b$3({handle:n,type:"gridlist"},o,c);let{collectionProps:F,dragState:q,dropState:J}=a$3({...L,onReorder:m,enableReorder:p,layout:y,orientation:f$1,preview:I,getItems:a=>[...a].map(X=>{let C=o.collection.getItem(X);return a$4(C,"Expected item to be defined."),{key:C.key.toString()}})},o,c),Q=r?Z:v.onKeyDownCapture,W={state:o,dragState:q,dropState:J,enableReorder:p,renderGridItem:g};return jsxs("ul",{...c$3(v,F),className:a$5("BaselineUI-GridList",e),"data-block-id":i$1,"data-block-class":s,style:t,ref:c,"aria-rowcount":o.collection.size,onKeyDownCapture:Q,children:[[...o.collection].map(a=>jsx(P,{item:a,...W},a.key)),p?jsx(f,{ref:I,children:a=>jsx(i,{items:a,containerClassName:".BaselineUI-GridList",previewClassName:T(),itemDataAttribute:"data-grid-list-item-key"})}):null]})});j.displayName="GridList";export{j as a};
@@ -0,0 +1,10 @@
1
+ /**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function a(r,s,i){let e=i.split(",").map(t=>t.trim().toLowerCase()).filter(Boolean);if(!e.length)return true;let o=r.toLowerCase(),l=s.toLowerCase();return e.some(t=>t.startsWith(".")?o.endsWith(t):t.endsWith("/*")?l.startsWith(t.slice(0,-1)):l===t)}async function n({items:r,accept:s}){return (await Promise.allSettled(r.filter(e=>e.kind==="file"&&(!s||a(e.name,e.type,s))).map(async e=>e.getFile()))).filter(e=>e.status==="fulfilled").map(e=>e.value)}export{n as a};
@@ -0,0 +1,10 @@
1
+ import {a as a$6}from'./chunk-VLQ4S7XC.mjs';import {a as a$e}from'./chunk-VG7J427T.mjs';import {k,j as j$1,g,c,i,f as f$1,h as h$1,e as e$1,d as d$1,b as b$5,a as a$h}from'./chunk-RC7QITNV.mjs';import {b as b$3,a as a$g,q as q$1,n,c as c$4}from'./chunk-7AY6C5M5.mjs';import {p}from'./chunk-SMAYNDQQ.mjs';import {a as a$b}from'./chunk-AMW7LGCF.mjs';import {a as a$9}from'./chunk-KKJ6XIU3.mjs';import {b as b$6}from'./chunk-246VHB32.mjs';import {b as b$7}from'./chunk-OC42IZG2.mjs';import {b as b$8}from'./chunk-PAQQ7MQG.mjs';import {a as a$3}from'./chunk-2MS356Q7.mjs';import {a as a$k}from'./chunk-Y6XQJ4X2.mjs';import {a as a$d}from'./chunk-MEYMETYC.mjs';import {a as a$c,b as b$2}from'./chunk-J7EAQSKX.mjs';import {d,h,e,f,g as g$1}from'./chunk-IW4GXU75.mjs';import {a as a$f}from'./chunk-NSC53QWT.mjs';import {a as a$m}from'./chunk-SAZLJ66W.mjs';import {b,c as c$2}from'./chunk-X3OCHEQM.mjs';import {a as a$t}from'./chunk-M5M3EPG5.mjs';import {d as d$3}from'./chunk-W6QO7FPZ.mjs';import {b as b$4}from'./chunk-J3MJZQUJ.mjs';import {a as a$7}from'./chunk-O7XK2WIX.mjs';import {a as a$j}from'./chunk-MEZNZ5W6.mjs';import {a as a$a}from'./chunk-YV3WI6OV.mjs';import {a as a$l}from'./chunk-USMC34OO.mjs';import {a as a$r}from'./chunk-4ZJMZB5B.mjs';import {a as a$i}from'./chunk-VDUFLHKK.mjs';import {a as a$p}from'./chunk-4PYEGHW5.mjs';import {a as a$5}from'./chunk-66CUIXA6.mjs';import {a as a$q}from'./chunk-X3AXUU3H.mjs';import {a as a$s}from'./chunk-545KDVGI.mjs';import {a}from'./chunk-YS3Y5KGV.mjs';import {a as a$4}from'./chunk-RSKKEGJZ.mjs';import {a as a$2}from'./chunk-K6X2BHPP.mjs';import {d as d$2}from'./chunk-Y4DRSGEJ.mjs';import {a as a$1}from'./chunk-3FYY26ED.mjs';import {c as c$1,b as b$1,a as a$o}from'./chunk-TZ4MVY4E.mjs';import {a as a$n}from'./chunk-KEVERVHK.mjs';import {c as c$3}from'./chunk-JDLUGVXG.mjs';import {e as e$2,g as g$2}from'./chunk-AUOQSTS5.mjs';import {a as a$8}from'./chunk-4QEH5CGK.mjs';import q,{useCallback,useContext,useEffect,useMemo,useRef,useState}from'react';import {jsx,jsxs,Fragment}from'react/jsx-runtime';import {CaretDownIcon}from'@baseline-ui/icons/8';import {sprinkles}from'@baseline-ui/tokens';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var $=new WeakMap;function de(t,e,a){let{keyboardDelegate:n,isDisabled:p,isRequired:S,name:c,form:s,validationBehavior:y="aria"}=t,x=a$l({usage:"search",sensitivity:"base"}),l=useMemo(()=>n||new b$6(e.collection,e.disabledKeys,a,x),[n,e.collection,e.disabledKeys,x,a]),{menuTriggerProps:u,menuProps:r}=c$4({isDisabled:p,type:"listbox"},e,a),d=m=>{if(e.selectionManager.selectionMode!=="multiple")switch(m.key){case "ArrowLeft":{m.preventDefault();let T=e.selectedKey!=null?l.getKeyAbove?.(e.selectedKey):l.getFirstKey?.();T!=null&&e.setSelectedKey(T);break}case "ArrowRight":{m.preventDefault();let T=e.selectedKey!=null?l.getKeyBelow?.(e.selectedKey):l.getFirstKey?.();T!=null&&e.setSelectedKey(T);break}}},{typeSelectProps:o}=b$7({keyboardDelegate:l,selectionManager:e.selectionManager,onTypeSelect(m){e.setSelectedKey(m);}}),{isInvalid:g,validationErrors:b,validationDetails:C}=e.displayValidation,{labelProps:O,fieldProps:i,descriptionProps:M,errorMessageProps:f}=a$m({...t,labelElementType:"span",isInvalid:g,errorMessage:t.errorMessage||b,ref:a});e.selectionManager.selectionMode==="multiple"&&(o={});let B=a$n(t,{labelable:true}),P=c$1(o,u,i),h=c$3();return $.set(e,{isDisabled:p,isRequired:S,name:c,form:s,validationBehavior:y}),{labelProps:{...O,onClick:()=>{t.isDisabled||(a.current?.focus(),d$2("keyboard"));}},triggerProps:c$1(B,{...P,isDisabled:p,onKeyDown:a$o(P.onKeyDown,d,t.onKeyDown),onKeyUp:t.onKeyUp,"aria-labelledby":[h,P["aria-labelledby"],P["aria-label"]&&!P["aria-labelledby"]?P.id:null].filter(Boolean).join(" "),onFocus(m){e.isFocused||(t.onFocus&&t.onFocus(m),t.onFocusChange&&t.onFocusChange(true),e.setFocused(true));},onBlur(m){e.isOpen||(t.onBlur&&t.onBlur(m),t.onFocusChange&&t.onFocusChange(false),e.setFocused(false));}}),valueProps:{id:h},menuProps:{...r,onAction:void 0,autoFocus:e.focusStrategy||true,shouldSelectOnPressUp:true,shouldFocusOnHover:true,disallowEmptySelection:true,linkBehavior:"selection",onBlur:m=>{e$2(m.currentTarget,m.relatedTarget)||(t.onBlur&&t.onBlur(m),t.onFocusChange&&t.onFocusChange(false),e.setFocused(false));},"aria-labelledby":[i["aria-labelledby"],P["aria-label"]&&!i["aria-labelledby"]?P.id:null].filter(Boolean).join(" ")},descriptionProps:M,errorMessageProps:f,isInvalid:g,validationErrors:b,validationDetails:C,hiddenSelectProps:{isDisabled:p,name:c,label:t.label,state:e,triggerRef:a,form:s}}}function bt(t,e,a){let n=$.get(e)||{},{autoComplete:p,name:S=n.name,form:c=n.form,isDisabled:s=n.isDisabled}=t,{validationBehavior:y,isRequired:x}=n,{visuallyHiddenProps:l}=a$r({style:{position:"fixed",top:0,left:0}});a$s(t.selectRef,e.defaultValue,e.setValue),a$t({validationBehavior:y,focus:()=>a.current?.focus()},e,t.selectRef);let u=e.setValue,r=useCallback(d=>{let o=g$2(d);o.multiple?u(Array.from(o.selectedOptions,g=>g.value)):u(d.currentTarget.value);},[u]);return {containerProps:{...l,"aria-hidden":true,"data-react-aria-prevent-focus":true,"data-a11y-ignore":"aria-hidden-focus"},inputProps:{style:{display:"none"}},selectProps:{tabIndex:-1,autoComplete:p,disabled:s,multiple:e.selectionManager.selectionMode==="multiple",required:y==="native"&&x,name:S,form:c,value:e.value??"",onChange:r,onInput:r}}}function ue(t){let{state:e,triggerRef:a,label:n,name:p,form:S,isDisabled:c}=t,s=useRef(null),y=useRef(null),{containerProps:x,selectProps:l}=bt({...t,selectRef:e.collection.size<=300?s:y},e,a),u=Array.isArray(e.value)?e.value:[e.value];if(e.collection.size<=300)return jsx("div",{...x,"data-testid":"hidden-select-container",children:jsxs("label",{children:[n,jsxs("select",{...l,ref:s,children:[jsx("option",{value:"",label:"\xA0",children:"\xA0"}),[...e.collection.getKeys()].map(r=>{let d=e.collection.getItem(r);if(d&&d.type==="item")return jsx("option",{value:d.key,children:d.textValue},d.key)}),e.collection.size===0&&p&&u.map((r,d)=>jsx("option",{value:r??""},d))]})]})});if(p){let r=$.get(e)||{},{validationBehavior:d}=r;u.length===0&&(u=[null]);let o=u.map((g,b)=>{let C={type:"hidden",autoComplete:l.autoComplete,name:p,form:S,disabled:c,value:g??""};return d==="native"?jsx("input",{...C,ref:b===0?y:null,style:{display:"none"},type:"text",required:b===0?l.required:false,onChange:()=>{}},b):jsx("input",{...C,ref:b===0?y:null},b)});return jsx(Fragment,{children:o})}return null}function pe(t){let{selectionMode:e="single",shouldCloseOnSelect:a=e==="single"}=t,n=a$p(t),[p,S]=useState(null),c=useMemo(()=>t.defaultValue!==void 0?t.defaultValue:e==="single"?t.defaultSelectedKey??null:[],[t.defaultValue,t.defaultSelectedKey,e]),s=useMemo(()=>t.value!==void 0?t.value:e==="single"?t.selectedKey:void 0,[t.value,t.selectedKey,e]),[y,x]=a$q(s,c,t.onChange),l=e==="single"&&Array.isArray(y)?y[0]:y,u=i=>{if(e==="single"){let M=Array.isArray(i)?i[0]??null:i;x(M),M!==l&&t.onSelectionChange?.(M);}else {let M=[];Array.isArray(i)?M=i:i!=null&&(M=[i]),x(M);}},r=b$8({...t,selectionMode:e,disallowEmptySelection:e==="single",allowDuplicateSelectionEvents:true,selectedKeys:useMemo(()=>Bt(l),[l]),onSelectionChange:i=>{if(i!=="all"){if(e==="single"){let M=i.values().next().value??null;u(M);}else u([...i]);a&&n.close(),g.commitValidation();}}}),d=r.selectionManager.firstSelectedKey,o=useMemo(()=>[...r.selectionManager.selectedKeys].map(i=>r.collection.getItem(i)).filter(i=>i!=null),[r.selectionManager.selectedKeys,r.collection]),g=d$3({...t,value:Array.isArray(l)&&l.length===0?null:l}),[b,C]=useState(false),[O]=useState(l);return {...g,...r,...n,value:l,defaultValue:c??O,setValue:u,selectedKey:d,setSelectedKey:u,selectedItem:o[0]??null,selectedItems:o,defaultSelectedKey:t.defaultSelectedKey??(t.selectionMode==="single"?O:null),focusStrategy:p,open(i=null){(r.collection.size!==0||t.allowsEmptyCollection)&&(S(i),n.open());},toggle(i=null){(r.collection.size!==0||t.allowsEmptyCollection)&&(S(i),n.toggle());},isFocused:b,setFocused:C}}function Bt(t){if(t!==void 0)return t===null?[]:Array.isArray(t)?t:[t]}var j=q.forwardRef(({variant:t,isOpen:e,validationState:a$9="valid",valueProps:n,className:p,style:S,value:c$2,"data-block-id":s,"data-block-class":y,fallbackValue:x,selectionMode:l="single",onRemove:u,maxCount:r=2,moreLabel:d$1,...o},g$1)=>{let{formatMessage:b$2}=b(),C=c$2?.[0]??null,O=C?.label??x,i$1=C?.icon??null,M=q.useRef(null),f=!!(l==="multiple"&&c$2&&c$2?.length>0),{buttonProps:B,isPressed:P}=a({...o,elementType:"div",isDisabled:o.isDisabled||o.isReadOnly},M),{hoverProps:h$1,isHovered:m}=a$1({isDisabled:o.isDisabled}),{focusProps:T,isFocused:N,isFocusVisible:A}=a$2(),F=a$3({isReadOnly:o.isReadOnly,validationState:a$9});o.isReadOnly&&(B.disabled=false);let V=a$4({"data-disabled":o.isDisabled,"data-readonly":o.isReadOnly,"data-focused":N,"data-focus-visible":A,"data-hovered":m,"data-pressed":P,"data-open":e,"data-block-id":s,"data-block-class":y}),w=o["aria-labelledby"],ae=useCallback(()=>{a$5(Array.isArray(c$2),"value must be an array");let U=c$2.slice(0,r),H=c$2.slice(r),W=[...U,...H.length>0?[{label:(typeof d$1=="function"?d$1({count:H.length}):d$1)??b$2(It.more,{count:H.length}),id:"remaining-value"}]:[]];return jsx(a$6,{items:W,onRemove:o.isReadOnly?void 0:X=>{X.has("remaining-value")?u?.(new Set(H.map(E=>E.id))):u?.(X);},"aria-labelledby":w,className:k,isDisabled:o.isDisabled})},[c$2,r,b$2,d$1,w,o.isDisabled,u,o.isReadOnly]),z=l==="multiple";return jsxs("div",{...c$1(z?Object.fromEntries(Object.entries(B).filter(([U])=>U.startsWith("on"))):c$1(B,T),h$1,V),ref:z?g$1:b$1(g$1,M),className:a$8(i({isFocused:A,isDisabled:!!o.isDisabled,isOpen:e,isHovered:m,variant:t,isReadOnly:!!o.isReadOnly,areTagsVisible:f}),h({variant:t,isHovered:m,isFocused:A,validationState:a$9,isDisabled:!!o.isDisabled,isReadOnly:o.isReadOnly}),p,"BaselineUI-Select-Button"),"data-testid":"select-button",style:S,children:[jsxs(a$7,{display:"flex",flexDirection:"row",alignItems:"center",gap:"md",flex:1,paddingRight:"md",children:[l==="multiple"&&c$2&&c$2.length>0?ae():jsxs("span",{className:k,children:[i$1?jsx(i$1,{size:24}):null,jsx("span",{...n,children:O})]}),F?jsx("span",{"aria-hidden":true,className:a$8(d({validationState:a$9,isReadOnly:!!o.isReadOnly}),j$1),children:jsx(F,{size:16})}):null]}),jsx("div",{...z?{...c$1(B,T),ref:M}:{},className:g,children:jsx(CaretDownIcon,{size:8,className:c({isOpen:e})})})]})});j.displayName="SelectButton";var It=c$2({more:{id:"bui.select.more",defaultMessage:"+{count} more"}});var xt=q.createContext({state:null,popoverAnchorRef:null}),Se=q.forwardRef(({className:t,style:e$2,labelPosition:a="top",variant:n="primary","data-block-id":p$1,"data-block-class":S,onTriggerPress:c,placement:s="bottom start",triggerClassName:y,triggerStyle:x,state:l,optionStyle:u,optionClassName:r,showSectionHeader:d,hideSelectAll:o,hideClear:g,clearLabel:b$1,searchLabel:C,selectAllLabel:O,moreLabel:i,renderTrigger:M=({buttonProps:P,selectedValue:h,valueProps:m,isOpen:T,ref:N,selectionMode:A,onRemove:F,maxCount:V})=>jsx(j,{...P,className:y,style:x,isOpen:T,isReadOnly:f$2.isReadOnly,ref:N,variant:n,validationState:f$2.validationState,valueProps:m,value:h,fallbackValue:f$2.placeholder,selectionMode:A,onRemove:F,maxCount:V,moreLabel:i}),...f$2},B)=>{let{popoverAnchorRef:P}=useContext(xt),h=q.useRef(null),{formatMessage:m}=b(),T=C??m(ye.search),N=useContext(a$9),{isVirtualized:A}=useContext(p),F=a$a(f$2.portalContainer),{labelProps:V,triggerProps:w,valueProps:ae,menuProps:z,descriptionProps:U,errorMessageProps:H}=de({...a$b(f$2),validationState:f$2.validationState==="error"?"invalid":"valid"},l,h),W=c$3(),X=a$c(f$2)==="warningMessage",E=b$2({...f$2,descriptionProps:U,errorMessageProps:H,warningMessageProps:{id:W},labelPosition:a}),ht=l.selectedItems?.map(_=>_.value)??null;return jsxs(Fragment,{children:[jsxs("div",{style:e$2,className:a$8(g$1({labelPosition:a}),"BaselineUI-Select",t),"data-block-id":p$1,"data-block-class":S,ref:B,children:[f$2.label||E?jsxs("div",{className:f({labelPosition:a,hasMessage:!!E}),children:[f$2.label?jsx("div",{...V,className:a$8(e,"BaselineUI-Select-Label"),children:f$2.label}):null,a==="start"&&E]}):null,jsx(ue,{state:l,triggerRef:h,isDisabled:f$2.isDisabled,label:f$2.label,name:f$2.name}),M({buttonProps:c$1({onPressStart:c,"aria-labelledby":V.id},w,X?{"aria-describedby":[w["aria-describedby"],W].filter(Boolean).join(" ")}:null),selectedValue:ht,valueProps:ae,isOpen:l.isOpen,ref:h,selectionMode:f$2.selectionMode??"single",onRemove:_=>{l.selectionManager.setSelectedKeys(new Set([...l.selectionManager.selectedKeys].filter(ne=>!_.has(ne))));},maxCount:f$2.maxCount??2}),a==="top"&&E]}),l?jsx(b$3.Provider,{value:l,children:jsx(a$d,{placement:s,state:l,portalContainer:F,offset:2,triggerRef:P||h,style:e$2,className:"BaselineUI-Select-Popover",...f$2,children:jsxs(a$7,{display:"flex",flex:1,flexDirection:"column",className:f$1,children:[N?jsxs(Fragment,{children:[jsx(a$e,{size:"sm","aria-label":T,placeholder:T,className:a$8(h$1,"BaselineUI-Select-SearchInput"),autoFocus:true}),jsx(a$f,{})]}):null,jsx(a$g.Provider,{value:z,children:jsx(q$1,{label:f$2.label,escapeKeyBehavior:"none",className:e$1({isVirtualized:A}),optionStyle:u,optionClassName:r,showSectionHeader:d})}),l.selectionManager.selectionMode==="multiple"&&(!o||!g)&&jsxs(a$7,{display:"flex",flexDirection:"row",className:d$1,children:[!o&&jsx(b$4,{variant:"ghost",size:"md",label:O??m(ye.selectAll),"data-testid":"select-all-button",onPress:()=>{if(l.selectionManager.isSelectAll)return;let ne=[...l.collection.getKeys()].filter(ge=>!l.selectionManager.disabledKeys.has(ge)&&l.selectionManager.canSelectItem(ge));l.selectionManager.setSelectedKeys(new Set(ne));},className:b$5}),!o&&!g&&jsx(a$f,{orientation:"vertical"}),!g&&jsx(b$4,{variant:"ghost",label:b$1??m(ye.clear),size:"md","data-testid":"select-clear-button",onPress:()=>{l.selectionManager.isEmpty||l.selectionManager.clearSelection();},className:b$5})]})]})})}):null]})});Se.displayName="SelectCore";var Pt=q.forwardRef(({collection:t,...e},a)=>{let n=pe({...e,collection:t,validationState:e.validationState==="error"?"invalid":"valid",children:void 0});return jsx(Se,{...e,ref:a,state:n})});Pt.displayName="SelectStandalone";var le=q.forwardRef(({optionStyle:t,optionClassName:e,showSectionHeader:a,...n$1},p)=>{let{state:S}=useContext(xt);useEffect(()=>{a$5(S||n$1.items,"Select: A `state` that can be passed via context or `items` are required.");},[n$1.items,S]);let c=useMemo(()=>({renderOption:(s,y)=>jsx(n,{...y,item:s,selectionIcon:y.selectionMode==="multiple"?"checkbox":"checkmark"}),optionStyle:t,optionClassName:e,showSectionHeader:a}),[t,e,a]);return S?jsx(Se,{...n$1,optionStyle:t,optionClassName:e,showSectionHeader:a,ref:p,state:S}):jsx(a$h,{items:n$1.items,listBoxProps:c,children:s=>jsx(Pt,{collection:s,...n$1,ref:p})})});le.displayName="Select";var ye=c$2({selectAll:{id:"bui.select.selectAll",defaultMessage:"Select All"},clear:{id:"bui.select.clear",defaultMessage:"Clear"},search:{id:"bui.select.search",defaultMessage:"Search"}});var Ct=q.forwardRef(({className:t,style:e,variant:a,"data-block-id":n,icon:p,tooltip:S=true,iconTooltip:c=true,...s},y)=>{let x=q.useRef(null),{tooltipProps:l}=a$i({label:s["aria-label"],tooltip:S}),u=useCallback(({buttonProps:r,selectedValue:d,valueProps:o,isOpen:g,ref:b})=>jsx(a$j,{...l,children:jsx(j,{...r,isOpen:g,isReadOnly:s.isReadOnly,ref:b,variant:a,validationState:s.validationState,value:d,fallbackValue:s.placeholder,valueProps:o,moreLabel:s.moreLabel})}),[s,l,a]);return jsxs(a$7,{display:"flex",flexDirection:"row",gap:"md",paddingX:"md",alignItems:"center",className:a$8("BaselineUI-IconSelect",t),"data-block-id":n,style:e,ref:b$1(y,x),children:[p?jsx(a$k,{icon:p,label:s["aria-label"],tooltip:c,"aria-hidden":"true",size:24,isFocusable:false,className:sprinkles({color:"icon.primary",display:"flex",flexShrink:0})}):null,jsx(le,{...s,renderTrigger:u})]})});Ct.displayName="IconSelect";export{pe as a,xt as b,le as c,Ct as d};
@@ -0,0 +1,10 @@
1
+ import {t}from'./chunk-MRJFGHFW.mjs';import {a,g,e}from'./chunk-AUOQSTS5.mjs';import {useRef,useEffect}from'react';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function H(s){let{ref:n,onInteractOutside:o,isDisabled:u,onInteractOutsideStart:p}=s,m=useRef({isPointerDown:false,ignoreEmulatedMouseEvents:false}),i=t(e=>{o&&d(e,n)&&(p&&p(e),m.current.isPointerDown=true);}),f=t(e=>{o&&o(e);});useEffect(()=>{let e=m.current;if(u)return;let y=n.current,t=a(y);if(typeof PointerEvent<"u"){let a=r=>{r.pointerType==="pen"&&e.isPointerDown&&d(r,n)&&(f(r),e.isPointerDown=false);},c=r=>{e.isPointerDown&&d(r,n)&&(f(r),e.isPointerDown=false);};return t.addEventListener("pointerdown",i,true),t.addEventListener("pointerup",a,true),t.addEventListener("click",c,true),()=>{t.removeEventListener("pointerdown",i,true),t.removeEventListener("pointerup",a,true),t.removeEventListener("click",c,true);}}else if(process.env.NODE_ENV==="test"){let a=r=>{e.ignoreEmulatedMouseEvents?e.ignoreEmulatedMouseEvents=false:e.isPointerDown&&d(r,n)&&f(r),e.isPointerDown=false;},c=r=>{e.ignoreEmulatedMouseEvents=true,e.isPointerDown&&d(r,n)&&f(r),e.isPointerDown=false;};return t.addEventListener("mousedown",i,true),t.addEventListener("mouseup",a,true),t.addEventListener("touchstart",i,true),t.addEventListener("touchend",c,true),()=>{t.removeEventListener("mousedown",i,true),t.removeEventListener("mouseup",a,true),t.removeEventListener("touchstart",i,true),t.removeEventListener("touchend",c,true);}}},[n,u]);}function d(s,n){if(s.button>0)return false;let o=g(s);if(o){let u=o.ownerDocument;if(!u||!e(u.documentElement,o)||o.closest("[data-react-aria-top-layer]"))return false}return n.current?!s.composedPath().includes(n.current):false}export{H as a};
@@ -0,0 +1,10 @@
1
+ import {a}from'./chunk-ENDOKA57.mjs';import {a as a$1}from'./chunk-EK3RIYMV.mjs';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function c(i,r){let{key:s}=i,{checkboxProps:e}=a(i,r);return {checkboxProps:{...e,"aria-labelledby":`${e.id} ${a$1(r,s)}`}}}export{c as a};
@@ -0,0 +1,10 @@
1
+ import {b}from'./chunk-N2XGJKZG.mjs';import {b as b$2}from'./chunk-HONWMHMX.mjs';import {a as a$2}from'./chunk-PF3OQKXP.mjs';import {a as a$3}from'./chunk-2VY4FAOY.mjs';import {i}from'./chunk-MRJFGHFW.mjs';import {a as a$1}from'./chunk-JDLUGVXG.mjs';import {a,f,b as b$1,e}from'./chunk-AUOQSTS5.mjs';import {useState,useRef,useEffect,useCallback}from'react';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var $=1e7;function dt(t,e,l){let o=st(e.body,l);return t==="left"?{...o,left:-$/2,width:$,totalWidth:$,scroll:{...o.scroll,left:0}}:{...o,top:-$/2,height:$,totalHeight:$,scroll:{...o.scroll,top:0}}}var F={top:"top",bottom:"top",left:"left",right:"left"},G={top:"bottom",bottom:"top",left:"right",right:"left"},Ct={top:"left",left:"top"},it={top:"height",left:"width"},Et={width:"totalWidth",height:"totalHeight"},J={};function Ot(t){let e=b$1(t);return typeof e<"u"&&e.visualViewport?e.visualViewport:null}function st(t,e){let l=a(t),o=0,n=0,s=0,i$1=0,c=0,u=0,r={},a$1=(e?.scale??1)>1;if(t.tagName==="BODY"||t.tagName==="HTML"){let h=l.documentElement;s=h.clientWidth,i$1=h.clientHeight,o=e?.width??s,n=e?.height??i$1,r.top=h.scrollTop||t.scrollTop,r.left=h.scrollLeft||t.scrollLeft,e&&(c=e.offsetTop,u=e.offsetLeft);}else (({width:o,height:n,top:c,left:u}=Z(t,false))),r.top=t.scrollTop,r.left=t.scrollLeft,s=o,i$1=n;return i()&&(t.tagName==="BODY"||t.tagName==="HTML")&&a$1&&(r.top=0,r.left=0,c=e?.pageTop??0,u=e?.pageLeft??0),{width:o,height:n,totalWidth:s,totalHeight:i$1,scroll:r,top:c,left:u}}function Mt(t){return {top:t.scrollTop,left:t.scrollLeft,width:t.scrollWidth,height:t.scrollHeight}}function Q(t,e,l,o,n,s,i){let c=n.scroll[t]??0,u=o[it[t]],r=i[t]+o.scroll[F[t]]+s,a=i[t]+o.scroll[F[t]]+u-s,h=e-c+o.scroll[F[t]]+i[t]-o[F[t]],d=e-c+l+o.scroll[F[t]]+i[t]-o[F[t]];return h<r?r-h:d>a?Math.max(a-d,r-h):0}function It(t){let l=b$1(t).getComputedStyle(t);return {top:parseInt(l.marginTop,10)||0,bottom:parseInt(l.marginBottom,10)||0,left:parseInt(l.marginLeft,10)||0,right:parseInt(l.marginRight,10)||0}}function rt(t){if(J[t])return J[t];let[e,l]=t.split(" "),o=F[e]||"right",n=Ct[o];F[l]||(l="center");let s=it[o],i=it[n];return J[t]={placement:e,crossPlacement:l,axis:o,crossAxis:n,size:s,crossSize:i},J[t]}function tt(t,e,l,o,n,s,i,c,u,r,a){let{placement:h,crossPlacement:d,axis:y,crossAxis:f,size:H,crossSize:w}=o,b={};b[f]=t[f]??0,d==="center"?b[f]+=((t[w]??0)-(l[w]??0))/2:d!==f&&(b[f]+=(t[w]??0)-(l[w]??0)),b[f]+=s;let E=t[f]-l[w]+u+r,L=t[f]+t[w]-u-r;if(b[f]=a$3(b[f],E,L),h===y){let W=c?a[H]:a[Et[H]];b[G[y]]=Math.floor(W-t[y]+n);}else b[y]=Math.floor(t[y]+t[H]+n);return b}function vt(t,e,l,o,n,s,i,c,u,r,a){let h=(t.top!=null?t.top:u[Et.height]-(t.bottom??0)-i)-(u.scroll.top??0),d=r?l.top:0,y={top:Math.max(e.top+d,(a?.offsetTop??e.top)+d),bottom:Math.min(e.top+e.height+d,(a?.offsetTop??0)+(a?.height??0))};return c!=="top"?Math.max(0,y.bottom-h-((n.top??0)+(n.bottom??0)+s)):Math.max(0,h+i-y.top-((n.top??0)+(n.bottom??0)+s))}function Pt(t,e,l,o,n,s,i,c){let{placement:u,axis:r,size:a}=s;return u===r?Math.max(0,l[r]-(i.scroll[r]??0)-(t[r]+(c?e[r]:0))-(o[r]??0)-o[G[r]]-n):Math.max(0,t[a]+t[r]+(c?e[r]:0)-l[r]-l[a]+(i.scroll[r]??0)-(o[r]??0)-o[G[r]]-n)}function St(t,e,l,o,n,s,i,c,u,r,a,h,d,y,f,H,w,b,E,L,W,_){let m=rt(t),{size:A,crossAxis:p,crossSize:R,placement:M,crossPlacement:T}=m,P=tt(e,c,l,m,a,h,r,d,f,H,u),S=a,k=E?$:Pt(c,r,e,n,s+a,m,u,w);if(i&&l[A]>k){let j=rt(`${G[M]} ${T}`),X=tt(e,c,l,j,a,h,r,d,f,H,u);Pt(c,r,e,n,s+a,j,u,w)>k&&(m=j,P=X,S=a);}if(_==="anchor"&&L&&(m.placement==="top"||m.placement==="bottom")){let j=E?0:Q(p,P[p],l[R],c,u,s,r);if(j!==0){let X=m.crossPlacement==="center"?j>0?"left":"right":G[m.crossPlacement];if(X){let lt=rt(`${m.placement} ${X}`),pt=tt(e,c,l,lt,a,h,r,d,f,H,u),Lt=E?0:Q(p,pt[p],l[R],c,u,s,r);Math.abs(Lt)<Math.abs(j)&&(m=lt,P=pt);}}}let I="bottom";m.axis==="top"?m.placement==="top"?I="top":m.placement==="bottom"&&(I="bottom"):m.crossAxis==="top"&&(m.crossPlacement==="top"?I="bottom":m.crossPlacement==="bottom"&&(I="top"));let V=_==="anchor"&&L&&(m.placement==="top"||m.placement==="bottom")&&m.crossPlacement!=="center",z=V||E?0:Q(p,P[p],l[R],c,u,s,r);P[p]+=z;let x=E||!W?void 0:vt(P,c,r,d,n,s,l.height,I,u,w,b);y&&(x==null||y<x)&&(x=y),l.height=x!=null?Math.min(l.height,x):l.height,P=tt(e,c,l,m,S,h,r,d,f,H,u),z=V||E?0:Q(p,P[p],l[R],c,u,s,r),P[p]+=z;let v={},g=e[p]-P[p]-n[F[p]],C=g+.5*e[R],D=f/2+H,B=F[p]==="left"?(n.left??0)+(n.right??0):(n.top??0)+(n.bottom??0),N=l[R]-B-f/2-H,ot=e[p]+f/2-(P[p]+n[F[p]]),Tt=e[p]+e[R]-f/2-(P[p]+n[F[p]]),yt=a$3(C,ot,Tt);v[p]=a$3(yt,D,N),{placement:M,crossPlacement:T}=m,f?g=v[p]:T==="right"?g+=e[R]:T==="center"&&(g+=e[R]/2);let at=M==="left"||M==="top"?l[A]:0,Ht={x:M==="top"||M==="bottom"?g:at,y:M==="left"||M==="right"?g:at};return {position:P,maxHeight:x,arrowOffsetLeft:v.left,arrowOffsetTop:v.top,placement:M,triggerAnchorPoint:Ht}}function At(t){let{placement:e$1,targetNode:l,overlayNode:o,scrollNode:n,padding:s,shouldFlip:i,boundaryElement:c,boundaryAxis:u="both",horizontalBoundaryBehavior:r="shift",offset:a$1,crossOffset:h,maxHeight:d,arrowSize:y=0,arrowBoundaryOffset:f=0,targetRect:H}=t,w=a(o),b=b$1(o),E=Ot(o),L=o instanceof b.HTMLElement?zt(o):w.documentElement,W=L===w.documentElement,_=b.getComputedStyle(L).position,m=!!_&&_!=="static",A=W?Z(l,false,H):xt(l,L,false,H);if(!W){let{marginTop:D,marginLeft:B}=b.getComputedStyle(l);A.top+=parseInt(D,10)||0,A.left+=parseInt(B,10)||0;}let p=Z(o,true),R=It(o);p.width+=(R.left??0)+(R.right??0),p.height+=(R.top??0)+(R.bottom??0);let M=Mt(n),T=c===null,P=c??w.body,S=!T&&u!=="vertical",k=!T&&u!=="horizontal",I=st(P,E),V=S?I:dt("left",w,E),z=k?I:dt("top",w,E),x={...z,left:V.left,width:V.width,totalWidth:V.totalWidth,scroll:{top:z.scroll.top,left:V.scroll.left}},v=st(L,E);m&&!W&&(x.top-=v.top,x.left-=v.left,v.top=0,v.left=0);let g=T?{top:0,left:0,width:0,height:0}:xt(P,L,false),C=!T&&e(P,L)&&L!==P;return St(e$1,A,p,M,R,s,i,x,v,g,a$1,h,m,d,y,f,C,E,T,S,k,r)}function et(t,e){let l=b$1(t),{top:o,left:n,width:s,height:i}=t.getBoundingClientRect();return e&&t instanceof l.HTMLElement&&(s=t.offsetWidth,i=t.offsetHeight),{top:o,left:n,width:s,height:i}}function Z(t,e,l){let o=a(t),{top:n,left:s,width:i,height:c}=l||et(t,e),{scrollTop:u,scrollLeft:r,clientTop:a$1,clientLeft:h}=o.documentElement;return {top:n+u-a$1,left:s+r-h,width:i,height:c}}function xt(t,e,l,o){let n=b$1(t),s=n.getComputedStyle(t),i;if(s.position==="fixed")i=o||et(t,l);else {i=Z(t,l,o);let c=Z(e,l),u=n.getComputedStyle(e);c.top+=(parseInt(u.borderTopWidth,10)||0)-e.scrollTop,c.left+=(parseInt(u.borderLeftWidth,10)||0)-e.scrollLeft,i.top-=c.top,i.left-=c.left;}return i.top-=parseInt(s.marginTop,10)||0,i.left-=parseInt(s.marginLeft,10)||0,i}function zt(t){let e=a(t),l=b$1(t),o=t.offsetParent;if(o&&o===e.body&&l.getComputedStyle(o).position==="static"&&!wt(o)&&(o=e.documentElement),o==null)for(o=t.parentElement;o&&!wt(o);)o=o.parentElement;return o||e.documentElement}function wt(t){let l=b$1(t).getComputedStyle(t);return l.transform!=="none"||/transform|perspective/.test(l.willChange)||l.filter!=="none"||l.contain==="paint"||"backdropFilter"in l&&l.backdropFilter!=="none"||"WebkitBackdropFilter"in l&&l.WebkitBackdropFilter!=="none"}function mt(t){return typeof document>"u"?null:b$1(t).visualViewport??null}function te(t){let{direction:e$1}=b(),{arrowSize:l,targetRef:o,overlayRef:n,arrowRef:s,scrollRef:i=n,placement:c="bottom",containerPadding:u=12,shouldFlip:r=true,boundaryElement:a$3,boundaryAxis:h="both",horizontalBoundaryBehavior:d="shift",offset:y=0,crossOffset:f$1=0,shouldUpdatePosition:H=true,shouldCloseOnScroll:w=true,isOpen:b$3=true,onClose:E,maxHeight:L,arrowBoundaryOffset:W=0,getTargetRect:_}=t,m=a$3??(typeof document<"u"?o.current?.ownerDocument.body??n.current?.ownerDocument.body??document.body:void 0),[A,p]=useState(null),R=[H,c,n.current,o.current,s?.current,i.current,u,r,m,h,d,y,f$1,b$3,e$1,L,W,l],M=useRef(mt(n.current)?.scale);useEffect(()=>{b$3&&(M.current=mt(n.current)?.scale);},[b$3,n]);let T=useCallback(()=>{if(H===false||!b$3||!n.current||!o.current||m===void 0||mt(n.current)?.scale!==M.current)return;let z=a(n.current),x=f(z),v=b$1(z.body),g=null;if(i.current&&e(i.current,x)){let B=x?.getBoundingClientRect(),N=i.current.getBoundingClientRect();g={type:"top",offset:(B?.top??0)-N.top},g.offset>N.height/2&&(g.type="bottom",g.offset=(B?.bottom??0)-N.bottom);}let C=n.current;!L&&n.current&&(C.style.top="0px",C.style.bottom="",C.style.maxHeight=(v.visualViewport?.height??v.innerHeight)+"px");let D=At({placement:Wt(c,e$1),overlayNode:n.current,targetNode:o.current,scrollNode:i.current||n.current,padding:u,shouldFlip:r,boundaryElement:m,boundaryAxis:h,horizontalBoundaryBehavior:d,offset:y,crossOffset:f$1,maxHeight:L,arrowSize:l??(s?.current?et(s.current,true).width:0),arrowBoundaryOffset:W,targetRect:_?.(o.current)});if(D.position){if(C.style.top="",C.style.bottom="",C.style.left="",C.style.right="",Object.keys(D.position).forEach(B=>C.style[B]=D.position[B]+"px"),C.style.maxHeight=D.maxHeight!=null?D.maxHeight+"px":"",g&&x&&i.current){let B=x.getBoundingClientRect(),N=i.current.getBoundingClientRect(),ot=B[g.type]-N[g.type];i.current.scrollTop+=ot-g.offset;}p(D);}},R);a$1(T,R);let P=m?b$1(m):o.current?b$1(o.current):n.current?b$1(n.current):void 0;Bt(T,P);let S=useRef(null),k=useCallback(()=>{S.current!==null&&cancelAnimationFrame(S.current),S.current=requestAnimationFrame(()=>{S.current=null,T();});},[T]);useEffect(()=>()=>{S.current!==null&&cancelAnimationFrame(S.current);},[]),a$2({ref:n,onResize:k}),a$2({ref:o,onResize:k});let I=useRef(false);a$1(()=>{let z,x=()=>{I.current=true,clearTimeout(z),z=setTimeout(()=>{I.current=false;},500),T();},g=b$1(n.current).visualViewport,C=()=>{I.current&&x();};return g?.addEventListener("resize",x),g?.addEventListener("scroll",C),()=>{g?.removeEventListener("resize",x),g?.removeEventListener("scroll",C);}},[T]);let V=useCallback(()=>{I.current||E?.();},[E,I]);return b$2({triggerRef:o,isOpen:b$3,onClose:w?E&&V:null}),{overlayProps:{style:{position:A?"absolute":"fixed",top:A?void 0:0,left:A?void 0:0,zIndex:1e5,...A?.position,maxHeight:A==null?"100vh":A.maxHeight!=null?`${A.maxHeight}px`:""}},placement:A?.placement??null,triggerAnchorPoint:A?.triggerAnchorPoint??null,arrowProps:{"aria-hidden":"true",role:"presentation",style:{left:A?.arrowOffsetLeft,top:A?.arrowOffsetTop}},updatePosition:T}}function Bt(t,e=window){a$1(()=>(e?.addEventListener("resize",t,false),()=>{e?.removeEventListener("resize",t,false);}),[t,e]);}function Wt(t,e){return e==="rtl"?t.replace("start","right").replace("end","left"):t.replace("start","left").replace("end","right")}export{te as a};
@@ -0,0 +1,10 @@
1
+ import {j as j$1,l,m,k,o,i,h}from'./chunk-7AY6C5M5.mjs';import {a as a$2}from'./chunk-MEYMETYC.mjs';import {b}from'./chunk-J3MJZQUJ.mjs';import {a}from'./chunk-YV3WI6OV.mjs';import {e}from'./chunk-B7PSE5KC.mjs';import {a as a$1}from'./chunk-4QEH5CGK.mjs';import C,{useEffect,useContext}from'react';import {jsxs,jsx}from'react/jsx-runtime';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ var w="xyd2ss0 _1yep5z6n6 _1yep5z6n7 _1yep5z6n8 _1yep5z6pi _1yep5z6pj _1yep5z6pk _1yep5z6qo _1yep5z6qp _1yep5z6qq _1yep5z6oc _1yep5z6od _1yep5z6oe _1yep5z6ru _1yep5z6rv _1yep5z6rw _1yep5z6u6 _1yep5z6u7 _1yep5z6u8 _1yep5z6vc _1yep5z6vd _1yep5z6ve _1yep5z6t0 _1yep5z6t1 _1yep5z6t2 _1yep5z6wo _1yep5z6wp _1yep5z6wq _1yep5z6xc _1yep5z6xd _1yep5z6xe _1yep5z6y0 _1yep5z6y1 _1yep5z6y2 _1yep5z6yo _1yep5z6yp _1yep5z6yq _1yep5z617v _1yep5z617u _1yep5z6143 _1yep5z617y _1yep5z6124";var u=r=>r!=null&&typeof r=="object"&&!(Symbol.iterator in r);function B(r,t,e){let o=u(t)||u(e),s=t!=null&&!u(t)||e!=null&&!u(e);return r&&s?"Menu: an object `selectionMode` expects `selectedKeys`/`defaultSelectedKeys` to be records keyed by section id.":!r&&o?"Menu: a per-section `selectedKeys`/`defaultSelectedKeys` record requires the object form of `selectionMode`.":null}var H=C.forwardRef(({defaultOpen:r,onOpenChange:t,isOpen:e,isDisabled:o,contentClassName:s,placement:n="bottom start",isNonModal:l$1,shouldFlip:p,shouldUpdatePosition:m,boundaryElement:G,boundaryAxis:J,horizontalBoundaryBehavior:Q,crossOffset:V,offset:W,triggerLabel:f,renderTrigger:g=({buttonProps:c,ref:a})=>jsx(b,{...c,variant:"popover",ref:a,"data-testid":"menu-trigger"}),portalContainer:X,selectionMode:y,selectedKeys:P,defaultSelectedKeys:z,onSelectionChange:h,disabledKeys:_,disallowEmptySelection:T,...M},Y)=>{let c=a(X),a$2=y!=null&&typeof y=="object",K=C.useMemo(()=>_==null?void 0:new Set(_),[_]),O=B(a$2,P,z);if(O)throw new Error(O);return useEffect(()=>{!f&&!g&&console.warn("The `triggerLabel` prop is required when no `renderTrigger` or `children` is provided.");},[g,f]),jsxs(j$1,{defaultOpen:r,onOpenChange:t,isOpen:e,children:[jsx(j,{isDisabled:o,renderTrigger:g,triggerLabel:f}),jsx(L,{placement:n,isNonModal:l$1,shouldFlip:p,shouldUpdatePosition:m,boundaryElement:G,boundaryAxis:J,horizontalBoundaryBehavior:Q,crossOffset:V,offset:W||2,className:"BaselineUI-Menu-Popover",portalContainer:c,children:jsx(l,{...M,disabledKeys:K,...a$2?{}:{selectionMode:y,selectedKeys:P,defaultSelectedKeys:z,onSelectionChange:h,disallowEmptySelection:T},className:a$1(w,s),ref:Y,children:U(M.items,c,{onAction:M.onAction,disabledKeys:K,contentClassName:s,selection:a$2?{modes:y,selectedKeys:P,defaultSelectedKeys:z,onSelectionChange:h,disallowEmptySelection:T}:void 0})})})]})});function U(r,t,e){return r.map((o$1,s)=>{if("children"in o$1){let n=o$1,l=e.selection?.modes[n.id],p=e.selection;return jsx(m,{section:n,componentName:"Menu",isFirstCollectionItem:s===0,showSectionHeader:!!n.title,...l?{selectionMode:l,selectedKeys:p?.selectedKeys?.[n.id],defaultSelectedKeys:p?.defaultSelectedKeys?.[n.id],disabledKeys:e.disabledKeys,disallowEmptySelection:p?.disallowEmptySelection,onSelectionChange:m=>{p?.onSelectionChange?.(m,{sectionId:n.id});}}:{}},n.id)}return o$1.items?jsxs(k,{children:[jsx(o,{item:o$1,componentName:"Menu"}),jsx(L,{className:"BaselineUI-Menu-SubmenuPopover",portalContainer:t,children:jsx(l,{className:a$1(w,e.contentClassName),onAction:e.onAction,disabledKeys:e.disabledKeys,children:U(o$1.items,t,e)})})]},o$1.id):jsx(o,{item:o$1,componentName:"Menu"},o$1.id)})}var j=C.forwardRef(({renderTrigger:r,triggerLabel:t,isDisabled:e,...o},s)=>{let n=useContext(i);return r?.({buttonProps:{...o,isDisabled:e,label:typeof t=="function"?t(n?.isOpen||false):t,isOpen:n?.isOpen||false,className:"BaselineUI-Menu-Trigger"},ref:s})});j.displayName="MyTrigger";var L=({children:r,...t})=>{let e$1=useContext(i),[o]=e(t,void 0,h);return e$1?.isOpen?jsx(a$2,{...o,state:e$1,children:r}):null};H.displayName="Menu";export{H as a};
@@ -0,0 +1,10 @@
1
+ import {a as a$1}from'./chunk-JDLUGVXG.mjs';import O,{useEffect}from'react';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function a({ref:e,onIntersect:t,isDisabled:r,threshold:n,rootMargin:o,root:c}){let s=O.useRef(t);a$1(()=>{s.current=t;}),useEffect(()=>{let i=e.current;if(r||!i)return;let f=new IntersectionObserver(([b])=>{s.current(b);},{root:c?.current,rootMargin:o,threshold:n});return f.observe(i),()=>{f.disconnect();}},[e,r,c,o,n]);}export{a};
@@ -0,0 +1,10 @@
1
+ import {b}from'./chunk-PAQQ7MQG.mjs';import {a}from'./chunk-X3AXUU3H.mjs';import {useMemo}from'react';/**
2
+ * Copyright (c) 2023-2024 PSPDFKit GmbH. All rights reserved.
3
+ *
4
+ * THIS SOURCE CODE AND ANY ACCOMPANYING DOCUMENTATION ARE PROTECTED BY INTERNATIONAL COPYRIGHT LAW
5
+ * AND MAY NOT BE RESOLD OR REDISTRIBUTED. USAGE IS BOUND TO THE PSPDFKIT LICENSE AGREEMENT.
6
+ * UNAUTHORIZED REPRODUCTION OR DISTRIBUTION IS SUBJECT TO CIVIL AND CRIMINAL PENALTIES.
7
+ * This notice may not be removed from this file.
8
+ *
9
+ */
10
+ function K(t){let[e,n]=a(t.selectedKey,t.defaultSelectedKey??null,t.onSelectionChange),s=useMemo(()=>e!=null?[e]:[],[e]),{collection:o,disabledKeys:S,selectionManager:d}=b({...t,selectionMode:"single",disallowEmptySelection:true,allowDuplicateSelectionEvents:true,selectedKeys:s,onSelectionChange:i=>{if(i==="all")return;let l=i.values().next().value??null;l===e&&t.onSelectionChange&&t.onSelectionChange(l),n(l);}}),r=e!=null?o.getItem(e):null;return {collection:o,disabledKeys:S,selectionManager:d,selectedKey:e,setSelectedKey:n,selectedItem:r}}export{K as a};