@vertexvis/ui 0.1.5-testing.0 → 1.0.0-testing.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 (888) hide show
  1. package/dist/cjs/components.cjs.js +14 -84
  2. package/dist/cjs/{dom-a2c535e3.js → dom-v38DVhe2.js} +4 -4
  3. package/dist/cjs/icon-helper-ut8vR2Rk.js +559 -0
  4. package/dist/cjs/index-D-R2lvls.js +62 -0
  5. package/dist/cjs/index-DihxupoM.js +95 -0
  6. package/dist/cjs/index-DwS9D24e.js +2230 -0
  7. package/dist/cjs/index.cjs.js +91 -92
  8. package/dist/cjs/{lib-1bd1e383.js → lib-CCXuRx1c.js} +2 -2
  9. package/dist/cjs/loader.cjs.js +5 -15
  10. package/dist/cjs/slots-DEdmqbtw.js +29 -0
  11. package/dist/cjs/templates-C_WUWcnZ.js +230 -0
  12. package/dist/cjs/tslib.es6-AsLBQn5u.js +68 -0
  13. package/dist/cjs/vertex-auto-resize-textarea.cjs.entry.js +132 -5
  14. package/dist/cjs/vertex-avatar-group.cjs.entry.js +12 -5
  15. package/dist/cjs/vertex-avatar.cjs.entry.js +44 -6
  16. package/dist/cjs/vertex-badge.cjs.entry.js +21 -6
  17. package/dist/cjs/vertex-banner.cjs.entry.js +122 -7
  18. package/dist/cjs/vertex-button.cjs.entry.js +83 -6
  19. package/dist/cjs/vertex-card-group.cjs.entry.js +34 -6
  20. package/dist/cjs/vertex-card.cjs.entry.js +33 -5
  21. package/dist/cjs/vertex-chip.cjs.entry.js +28 -6
  22. package/dist/cjs/vertex-click-to-edit-textfield.cjs.entry.js +112 -7
  23. package/dist/cjs/vertex-collapsible.cjs.entry.js +22 -6
  24. package/dist/cjs/vertex-color-circle-picker.cjs.entry.js +142 -6
  25. package/dist/cjs/vertex-color-picker.cjs.entry.js +67 -7
  26. package/dist/cjs/vertex-color-swatch.cjs.entry.js +141 -7
  27. package/dist/cjs/vertex-context-menu.cjs.entry.js +91 -6
  28. package/dist/cjs/vertex-dialog.cjs.entry.js +226 -5
  29. package/dist/cjs/vertex-draggable-popover.cjs.entry.js +79 -6
  30. package/dist/cjs/vertex-dropdown-menu.cjs.entry.js +34 -6
  31. package/dist/cjs/vertex-expandable.cjs.entry.js +101 -6
  32. package/dist/cjs/vertex-help-tooltip.cjs.entry.js +36 -5
  33. package/dist/cjs/vertex-icon-button.cjs.entry.js +58 -7
  34. package/dist/cjs/vertex-icon.cjs.entry.js +29 -7
  35. package/dist/cjs/vertex-logo-loading.cjs.entry.js +12 -5
  36. package/dist/cjs/vertex-menu-divider.cjs.entry.js +12 -5
  37. package/dist/cjs/vertex-menu-item.cjs.entry.js +24 -6
  38. package/dist/cjs/vertex-menu.cjs.entry.js +80 -6
  39. package/dist/cjs/vertex-popover.cjs.entry.js +1894 -5
  40. package/dist/cjs/vertex-radio-group.cjs.entry.js +73 -5
  41. package/dist/cjs/vertex-radio.cjs.entry.js +29 -6
  42. package/dist/cjs/vertex-resizable.cjs.entry.js +439 -7
  43. package/dist/cjs/vertex-result-list.cjs.entry.js +300 -7
  44. package/dist/cjs/vertex-search-bar.cjs.entry.js +528 -7
  45. package/dist/cjs/vertex-select.cjs.entry.js +181 -6
  46. package/dist/cjs/vertex-slider.cjs.entry.js +55 -7
  47. package/dist/cjs/vertex-spinner.cjs.entry.js +32 -6
  48. package/dist/cjs/vertex-tab.cjs.entry.js +20 -6
  49. package/dist/cjs/vertex-tabs.cjs.entry.js +104 -6
  50. package/dist/cjs/vertex-textfield.cjs.entry.js +147 -7
  51. package/dist/cjs/vertex-toast.cjs.entry.js +109 -6
  52. package/dist/cjs/vertex-toggle.cjs.entry.js +47 -6
  53. package/dist/cjs/vertex-tooltip.cjs.entry.js +343 -8
  54. package/dist/collection/collection-manifest.json +44 -43
  55. package/dist/collection/components/auto-resize-textarea/auto-resize-textarea.js +222 -213
  56. package/dist/collection/components/auto-resize-textarea/utils.js +1 -1
  57. package/dist/collection/components/avatar/avatar.js +153 -137
  58. package/dist/collection/components/avatar-group/avatar-group.js +16 -16
  59. package/dist/collection/components/badge/badge.js +75 -66
  60. package/dist/collection/components/banner/banner.js +284 -247
  61. package/dist/collection/components/button/button.css +1 -1
  62. package/dist/collection/components/button/button.js +274 -230
  63. package/dist/collection/components/card/card.js +89 -76
  64. package/dist/collection/components/card-group/card-group.js +104 -89
  65. package/dist/collection/components/chip/chip.js +89 -73
  66. package/dist/collection/components/click-to-edit-text-field/click-to-edit-text-field.js +412 -373
  67. package/dist/collection/components/collapsible/collapsible.js +71 -65
  68. package/dist/collection/components/color-circle-picker/color-circle-picker.js +398 -312
  69. package/dist/collection/components/color-picker/color-picker.js +225 -186
  70. package/dist/collection/components/color-swatch/color-swatch.js +341 -272
  71. package/dist/collection/components/color-swatch/lib.js +2 -2
  72. package/dist/collection/components/context-menu/context-menu.js +168 -161
  73. package/dist/collection/components/dialog/dialog.js +332 -323
  74. package/dist/collection/components/dialog/lib.js +4 -4
  75. package/dist/collection/components/draggable-popover/draggable-popover.js +182 -175
  76. package/dist/collection/components/dropdown-menu/dropdown-menu.js +122 -108
  77. package/dist/collection/components/expandable/expandable.js +272 -224
  78. package/dist/collection/components/help-tooltip/help-tooltip.js +132 -118
  79. package/dist/collection/components/icon/icon-helper.js +414 -414
  80. package/dist/collection/components/icon/icon.js +91 -75
  81. package/dist/collection/components/icon/icons/adjustments.js +1 -1
  82. package/dist/collection/components/icon/icons/align-to-global.js +1 -1
  83. package/dist/collection/components/icon/icons/align-to-part.js +1 -1
  84. package/dist/collection/components/icon/icons/align-to-surface.js +1 -1
  85. package/dist/collection/components/icon/icons/align-view-to-plane.js +1 -1
  86. package/dist/collection/components/icon/icons/annotation.js +1 -1
  87. package/dist/collection/components/icon/icons/arrow-filled.js +1 -1
  88. package/dist/collection/components/icon/icons/arrow-left-circled.js +1 -1
  89. package/dist/collection/components/icon/icons/arrow-line-left.js +1 -1
  90. package/dist/collection/components/icon/icons/arrow-line-right.js +1 -1
  91. package/dist/collection/components/icon/icons/arrow-partial.js +1 -1
  92. package/dist/collection/components/icon/icons/arrow-right-circled.js +2 -2
  93. package/dist/collection/components/icon/icons/arrow-swap.js +1 -1
  94. package/dist/collection/components/icon/icons/arrow-triangle-left.js +1 -1
  95. package/dist/collection/components/icon/icons/arrow-triangle-right.js +1 -1
  96. package/dist/collection/components/icon/icons/arrow-up-circled.js +1 -1
  97. package/dist/collection/components/icon/icons/attachment.js +1 -1
  98. package/dist/collection/components/icon/icons/axis-x.js +1 -1
  99. package/dist/collection/components/icon/icons/axis-y.js +1 -1
  100. package/dist/collection/components/icon/icons/axis-z.js +1 -1
  101. package/dist/collection/components/icon/icons/back.js +1 -1
  102. package/dist/collection/components/icon/icons/box-cursor.js +1 -1
  103. package/dist/collection/components/icon/icons/box-select.js +1 -1
  104. package/dist/collection/components/icon/icons/camera-add.js +1 -1
  105. package/dist/collection/components/icon/icons/camera.js +1 -1
  106. package/dist/collection/components/icon/icons/caret-down.js +1 -1
  107. package/dist/collection/components/icon/icons/caret-left.js +1 -1
  108. package/dist/collection/components/icon/icons/caret-right.js +1 -1
  109. package/dist/collection/components/icon/icons/caret-up.js +1 -1
  110. package/dist/collection/components/icon/icons/caution.js +1 -1
  111. package/dist/collection/components/icon/icons/check-circle.js +1 -1
  112. package/dist/collection/components/icon/icons/check.js +1 -1
  113. package/dist/collection/components/icon/icons/chevron-down.js +1 -1
  114. package/dist/collection/components/icon/icons/chevron-left.js +1 -1
  115. package/dist/collection/components/icon/icons/chevron-right.js +1 -1
  116. package/dist/collection/components/icon/icons/chevron-up.js +1 -1
  117. package/dist/collection/components/icon/icons/circle-outline.js +1 -1
  118. package/dist/collection/components/icon/icons/close-circle-fill.js +1 -1
  119. package/dist/collection/components/icon/icons/close-circle.js +1 -1
  120. package/dist/collection/components/icon/icons/close.js +1 -1
  121. package/dist/collection/components/icon/icons/collapse-all.js +1 -1
  122. package/dist/collection/components/icon/icons/columns-add.js +1 -1
  123. package/dist/collection/components/icon/icons/columns.js +1 -1
  124. package/dist/collection/components/icon/icons/comment-add.js +1 -1
  125. package/dist/collection/components/icon/icons/comment-filled.js +1 -1
  126. package/dist/collection/components/icon/icons/comment-reopen.js +1 -1
  127. package/dist/collection/components/icon/icons/comment-resolve.js +1 -1
  128. package/dist/collection/components/icon/icons/comment-show.js +1 -1
  129. package/dist/collection/components/icon/icons/compare.js +1 -1
  130. package/dist/collection/components/icon/icons/compress.js +1 -1
  131. package/dist/collection/components/icon/icons/copy.js +1 -1
  132. package/dist/collection/components/icon/icons/cross-section.js +1 -1
  133. package/dist/collection/components/icon/icons/cube-orthographic.js +1 -1
  134. package/dist/collection/components/icon/icons/cube-perspective.js +1 -1
  135. package/dist/collection/components/icon/icons/cube-stack.js +1 -1
  136. package/dist/collection/components/icon/icons/delete.js +1 -1
  137. package/dist/collection/components/icon/icons/download.js +1 -1
  138. package/dist/collection/components/icon/icons/drag-indicator.js +1 -1
  139. package/dist/collection/components/icon/icons/ellipse.js +1 -1
  140. package/dist/collection/components/icon/icons/error-circle.js +1 -1
  141. package/dist/collection/components/icon/icons/expand-all.js +1 -1
  142. package/dist/collection/components/icon/icons/expand.js +1 -1
  143. package/dist/collection/components/icon/icons/export.js +1 -1
  144. package/dist/collection/components/icon/icons/file-folder.js +1 -1
  145. package/dist/collection/components/icon/icons/file-pdf.js +1 -1
  146. package/dist/collection/components/icon/icons/file.js +1 -1
  147. package/dist/collection/components/icon/icons/fit-all.js +1 -1
  148. package/dist/collection/components/icon/icons/fit-selected.js +1 -1
  149. package/dist/collection/components/icon/icons/flip.js +1 -1
  150. package/dist/collection/components/icon/icons/folder-plus.js +1 -1
  151. package/dist/collection/components/icon/icons/forward.js +1 -1
  152. package/dist/collection/components/icon/icons/gear.js +1 -1
  153. package/dist/collection/components/icon/icons/help.js +1 -1
  154. package/dist/collection/components/icon/icons/info.js +1 -1
  155. package/dist/collection/components/icon/icons/invert.js +1 -1
  156. package/dist/collection/components/icon/icons/label-off.js +1 -1
  157. package/dist/collection/components/icon/icons/label.js +1 -1
  158. package/dist/collection/components/icon/icons/line-dot-left.js +1 -1
  159. package/dist/collection/components/icon/icons/line-dot-right.js +1 -1
  160. package/dist/collection/components/icon/icons/line-hash-left.js +1 -1
  161. package/dist/collection/components/icon/icons/line-hash-right.js +1 -1
  162. package/dist/collection/components/icon/icons/line.js +1 -1
  163. package/dist/collection/components/icon/icons/locate.js +1 -1
  164. package/dist/collection/components/icon/icons/lock-closed.js +1 -1
  165. package/dist/collection/components/icon/icons/lock-open.js +1 -1
  166. package/dist/collection/components/icon/icons/markup.js +1 -1
  167. package/dist/collection/components/icon/icons/menu.js +1 -1
  168. package/dist/collection/components/icon/icons/notification.js +1 -1
  169. package/dist/collection/components/icon/icons/open-window.js +1 -1
  170. package/dist/collection/components/icon/icons/open.js +1 -1
  171. package/dist/collection/components/icon/icons/pan.js +1 -1
  172. package/dist/collection/components/icon/icons/paper-airplane.js +1 -1
  173. package/dist/collection/components/icon/icons/paste.js +1 -1
  174. package/dist/collection/components/icon/icons/pencil.js +1 -1
  175. package/dist/collection/components/icon/icons/person-height.js +1 -1
  176. package/dist/collection/components/icon/icons/person-run.js +1 -1
  177. package/dist/collection/components/icon/icons/person-short.js +1 -1
  178. package/dist/collection/components/icon/icons/person-tall.js +1 -1
  179. package/dist/collection/components/icon/icons/person-walk.js +1 -1
  180. package/dist/collection/components/icon/icons/pin-fill.js +1 -1
  181. package/dist/collection/components/icon/icons/pin-line.js +1 -1
  182. package/dist/collection/components/icon/icons/pin-text-fill.js +1 -1
  183. package/dist/collection/components/icon/icons/pin-text-square.js +1 -1
  184. package/dist/collection/components/icon/icons/pin-text.js +1 -1
  185. package/dist/collection/components/icon/icons/plus-with-arrow.js +1 -1
  186. package/dist/collection/components/icon/icons/plus.js +1 -1
  187. package/dist/collection/components/icon/icons/pmi.js +1 -1
  188. package/dist/collection/components/icon/icons/precise-measurement.js +1 -1
  189. package/dist/collection/components/icon/icons/rabbit.js +1 -1
  190. package/dist/collection/components/icon/icons/refresh.js +1 -1
  191. package/dist/collection/components/icon/icons/rename.js +1 -1
  192. package/dist/collection/components/icon/icons/report.js +1 -1
  193. package/dist/collection/components/icon/icons/reset.js +1 -1
  194. package/dist/collection/components/icon/icons/resize.js +1 -1
  195. package/dist/collection/components/icon/icons/rotate.js +1 -1
  196. package/dist/collection/components/icon/icons/ruler.js +1 -1
  197. package/dist/collection/components/icon/icons/scissors.js +1 -1
  198. package/dist/collection/components/icon/icons/search.js +1 -1
  199. package/dist/collection/components/icon/icons/show-only-nearby.js +1 -1
  200. package/dist/collection/components/icon/icons/snapshots.js +1 -1
  201. package/dist/collection/components/icon/icons/square-dot-outline.js +1 -1
  202. package/dist/collection/components/icon/icons/star.js +1 -1
  203. package/dist/collection/components/icon/icons/tag.js +1 -1
  204. package/dist/collection/components/icon/icons/tape-measure.js +1 -1
  205. package/dist/collection/components/icon/icons/teleport-and-align.js +1 -1
  206. package/dist/collection/components/icon/icons/teleport-toward.js +1 -1
  207. package/dist/collection/components/icon/icons/teleport.js +1 -1
  208. package/dist/collection/components/icon/icons/triad.js +1 -1
  209. package/dist/collection/components/icon/icons/turtle.js +1 -1
  210. package/dist/collection/components/icon/icons/update.js +1 -1
  211. package/dist/collection/components/icon/icons/version-history.js +1 -1
  212. package/dist/collection/components/icon/icons/views.js +1 -1
  213. package/dist/collection/components/icon/icons/visibility-hidden.js +1 -1
  214. package/dist/collection/components/icon/icons/visibility-partial.js +1 -1
  215. package/dist/collection/components/icon/icons/visibility-visible.js +1 -1
  216. package/dist/collection/components/icon/icons/workspace-add.js +1 -1
  217. package/dist/collection/components/icon/icons/zoom.js +1 -1
  218. package/dist/collection/components/icon-button/icon-button.css +5 -2
  219. package/dist/collection/components/icon-button/icon-button.js +190 -152
  220. package/dist/collection/components/logo-loading/logo-loading.js +16 -16
  221. package/dist/collection/components/menu/menu.js +286 -250
  222. package/dist/collection/components/menu-divider/menu-divider.js +16 -16
  223. package/dist/collection/components/menu-item/menu-item.js +54 -48
  224. package/dist/collection/components/popover/middleware.js +22 -22
  225. package/dist/collection/components/popover/popover.js +654 -567
  226. package/dist/collection/components/popover/util.js +7 -7
  227. package/dist/collection/components/radio/radio.js +157 -145
  228. package/dist/collection/components/radio-group/radio-group.js +135 -133
  229. package/dist/collection/components/resizable/resizable.js +758 -702
  230. package/dist/collection/components/result-list/lib.js +6 -6
  231. package/dist/collection/components/result-list/result-list.js +456 -431
  232. package/dist/collection/components/search-bar/dom.js +13 -13
  233. package/dist/collection/components/search-bar/lib.js +50 -50
  234. package/dist/collection/components/search-bar/search-bar.js +739 -661
  235. package/dist/collection/components/select/select.css +7 -2
  236. package/dist/collection/components/select/select.js +332 -303
  237. package/dist/collection/components/slider/slider.js +258 -220
  238. package/dist/collection/components/spinner/spinner.js +93 -77
  239. package/dist/collection/components/tab/tab.js +86 -83
  240. package/dist/collection/components/tab/util.js +1 -1
  241. package/dist/collection/components/tabs/tabs.js +150 -151
  242. package/dist/collection/components/text-field/text-field.js +637 -572
  243. package/dist/collection/components/toast/toast.js +266 -228
  244. package/dist/collection/components/toggle/toggle.js +139 -119
  245. package/dist/collection/components/tooltip/tooltip.js +280 -247
  246. package/dist/collection/types/icon.js +137 -137
  247. package/dist/collection/util/components/dom.js +5 -5
  248. package/dist/collection/util/components/slots.js +17 -17
  249. package/dist/collection/util/templates/binding.js +121 -121
  250. package/dist/collection/util/templates/element-pool.js +79 -79
  251. package/dist/collection/util/templates/templates.js +15 -15
  252. package/dist/components/components.esm.js +1 -1
  253. package/dist/components/index.d.ts +6 -42
  254. package/dist/components/index.esm.js +1 -1
  255. package/dist/components/index.js +1 -52
  256. package/dist/components/p-00eaa8d7.entry.js +1 -0
  257. package/dist/components/p-0180556d.entry.js +1 -0
  258. package/dist/components/p-091b9e27.entry.js +1 -0
  259. package/dist/components/p-0af9b71c.entry.js +1 -0
  260. package/dist/components/p-0bd4222b.entry.js +1 -0
  261. package/dist/components/p-0c389e6f.entry.js +1 -0
  262. package/dist/{esm/toggle-1fe22e4f.js → components/p-0f13f6f3.entry.js} +1 -38
  263. package/dist/components/p-1KuzBK7Z.js +1 -0
  264. package/dist/components/p-1c5e8df5.entry.js +1 -0
  265. package/dist/components/p-1e6ff76a.entry.js +1 -0
  266. package/dist/components/p-26f9abc0.entry.js +1 -0
  267. package/dist/components/p-28460604.entry.js +1 -0
  268. package/dist/components/p-2cdfe6bf.entry.js +1 -0
  269. package/dist/components/p-2e0ee616.entry.js +1 -0
  270. package/dist/components/p-34d8a04e.entry.js +1 -0
  271. package/dist/components/p-3ddb0c4e.entry.js +1 -0
  272. package/dist/components/p-4HdACFFW.js +1 -0
  273. package/dist/components/p-553d01af.entry.js +1 -0
  274. package/dist/components/p-595b8bd6.entry.js +1 -0
  275. package/dist/components/p-5c032b37.entry.js +1 -0
  276. package/dist/components/p-5e3fe5e7.entry.js +1 -0
  277. package/dist/components/p-61742c05.entry.js +1 -0
  278. package/dist/components/p-6b2db72c.entry.js +1 -0
  279. package/dist/components/p-6c6a2fc5.entry.js +1 -0
  280. package/dist/components/p-6d03a954.entry.js +1 -0
  281. package/dist/components/p-6qoO8Yf3.js +1 -0
  282. package/dist/components/p-705d25f3.entry.js +1 -0
  283. package/dist/components/p-7f768637.entry.js +1 -0
  284. package/dist/components/p-8358ad1c.entry.js +1 -0
  285. package/dist/components/p-88781e72.entry.js +1 -0
  286. package/dist/components/p-B-yvbsY0.js +1 -0
  287. package/dist/components/p-B23i1cwy.js +1 -0
  288. package/dist/components/p-B2oECB2P.js +1 -0
  289. package/dist/components/p-B9qe9CNv.js +1 -0
  290. package/dist/components/p-BAfJR2VF.js +1 -0
  291. package/dist/components/p-BHmM6WC-.js +1 -0
  292. package/dist/components/p-BLc3P-0q.js +1 -0
  293. package/dist/components/{p-1356f525.js → p-BSoicxl1.js} +1 -1
  294. package/dist/components/p-BZ5oF5Ci.js +1 -0
  295. package/dist/components/p-BZutc-CC.js +1 -0
  296. package/dist/components/p-BbDaHMlz.js +1 -0
  297. package/dist/components/p-BdR40EV2.js +1 -0
  298. package/dist/components/p-Beav1bNT.js +6 -0
  299. package/dist/components/p-Bo65Viuh.js +1 -0
  300. package/dist/components/p-ByQGREpQ.js +1 -0
  301. package/dist/components/p-C1H5-_5m.js +1 -0
  302. package/dist/components/p-C1qwHMcr.js +1 -0
  303. package/dist/components/p-C27tS7nl.js +2 -0
  304. package/dist/components/p-C7VaFE8W.js +1 -0
  305. package/dist/components/p-CAFdRyLE.js +1 -0
  306. package/dist/components/p-CDYHYPYF.js +1 -0
  307. package/dist/components/p-CFaiLAq0.js +1 -0
  308. package/dist/components/{p-59032668.js → p-CIs0DJX1.js} +1 -1
  309. package/dist/components/p-CZ1Qa_xv.js +1 -0
  310. package/dist/components/p-CZyp2id8.js +1 -0
  311. package/dist/components/p-Ci26QjYl.js +1 -0
  312. package/dist/components/p-D1P5FeY6.js +1 -0
  313. package/dist/components/p-D3BXoJJN.js +1 -0
  314. package/dist/components/p-DEpMfvdS.js +1 -0
  315. package/dist/components/p-DGZHaSjz.js +1 -0
  316. package/dist/components/p-DHNuRvq0.js +1 -0
  317. package/dist/components/p-DMLgHhJc.js +1 -0
  318. package/dist/components/p-DO6VjClS.js +1 -0
  319. package/dist/components/p-DPgx10Cw.js +1 -0
  320. package/dist/components/p-DXQBJLz-.js +1 -0
  321. package/dist/components/p-D_mp9WMh.js +1 -0
  322. package/dist/components/p-De54LBPx.js +1 -0
  323. package/dist/components/p-DjrAIJhB.js +1 -0
  324. package/dist/components/p-DsAkiOMC.js +1 -0
  325. package/dist/components/p-Dw5WRKyY.js +1 -0
  326. package/dist/components/p-ILu24ZUX.js +1 -0
  327. package/dist/components/p-K5a7HQMt.js +1 -0
  328. package/dist/components/p-KilWQmEJ.js +1 -0
  329. package/dist/components/p-Mnv_zHXq.js +1 -0
  330. package/dist/components/p-RaMDrnzd.js +1 -0
  331. package/dist/components/p-TLO_pywp.js +1 -0
  332. package/dist/components/p-_3Hgy0Z4.js +1 -0
  333. package/dist/components/p-a287d016.entry.js +1 -0
  334. package/dist/components/p-a886721b.entry.js +1 -0
  335. package/dist/components/p-a8e75bdc.entry.js +1 -0
  336. package/dist/components/p-al_CUADF.js +1 -0
  337. package/dist/components/p-b5921385.entry.js +1 -0
  338. package/dist/components/p-c2f3cf8b.entry.js +1 -0
  339. package/dist/components/p-ca6a4b08.entry.js +1 -0
  340. package/dist/components/p-e311af0e.entry.js +1 -0
  341. package/dist/components/p-eYTN_sVb.js +1 -0
  342. package/dist/components/p-edfd86c9.entry.js +1 -0
  343. package/dist/components/p-ef419ddf.entry.js +1 -0
  344. package/dist/components/p-efd0223b.entry.js +1 -0
  345. package/dist/components/p-f1abef98.entry.js +1 -0
  346. package/dist/components/p-f23df530.entry.js +1 -0
  347. package/dist/components/p-f37dc3c4.entry.js +1 -0
  348. package/dist/components/p-f793f80a.entry.js +1 -0
  349. package/dist/components/p-y4p55dbx.js +1 -0
  350. package/dist/components/vertex-auto-resize-textarea.d.ts +2 -2
  351. package/dist/components/vertex-auto-resize-textarea.js +1 -6
  352. package/dist/components/vertex-avatar-group.d.ts +2 -2
  353. package/dist/components/vertex-avatar-group.js +1 -34
  354. package/dist/components/vertex-avatar.d.ts +2 -2
  355. package/dist/components/vertex-avatar.js +1 -68
  356. package/dist/components/vertex-badge.d.ts +2 -2
  357. package/dist/components/vertex-badge.js +1 -43
  358. package/dist/components/vertex-banner.d.ts +2 -2
  359. package/dist/components/vertex-banner.js +1 -141
  360. package/dist/components/vertex-button.d.ts +2 -2
  361. package/dist/components/vertex-button.js +1 -96
  362. package/dist/components/vertex-card-group.d.ts +2 -2
  363. package/dist/components/vertex-card-group.js +1 -51
  364. package/dist/components/vertex-card.d.ts +2 -2
  365. package/dist/components/vertex-card.js +1 -49
  366. package/dist/components/vertex-chip.d.ts +2 -2
  367. package/dist/components/vertex-chip.js +1 -45
  368. package/dist/components/vertex-click-to-edit-textfield.d.ts +2 -2
  369. package/dist/components/vertex-click-to-edit-textfield.js +1 -156
  370. package/dist/components/vertex-collapsible.d.ts +2 -2
  371. package/dist/components/vertex-collapsible.js +1 -63
  372. package/dist/components/vertex-color-circle-picker.d.ts +2 -2
  373. package/dist/components/vertex-color-circle-picker.js +1 -131
  374. package/dist/components/vertex-color-picker.d.ts +2 -2
  375. package/dist/components/vertex-color-picker.js +1 -75
  376. package/dist/components/vertex-color-swatch.d.ts +2 -2
  377. package/dist/components/vertex-color-swatch.js +1 -6
  378. package/dist/components/vertex-context-menu.d.ts +2 -2
  379. package/dist/components/vertex-context-menu.js +1 -125
  380. package/dist/components/vertex-dialog.d.ts +2 -2
  381. package/dist/components/vertex-dialog.js +1 -265
  382. package/dist/components/vertex-draggable-popover.d.ts +2 -2
  383. package/dist/components/vertex-draggable-popover.js +1 -119
  384. package/dist/components/vertex-dropdown-menu.d.ts +2 -2
  385. package/dist/components/vertex-dropdown-menu.js +1 -64
  386. package/dist/components/vertex-expandable.d.ts +2 -2
  387. package/dist/components/vertex-expandable.js +1 -6
  388. package/dist/components/vertex-help-tooltip.d.ts +2 -2
  389. package/dist/components/vertex-help-tooltip.js +1 -67
  390. package/dist/components/vertex-icon-button.d.ts +2 -2
  391. package/dist/components/vertex-icon-button.js +1 -6
  392. package/dist/components/vertex-icon.d.ts +2 -2
  393. package/dist/components/vertex-icon.js +1 -6
  394. package/dist/components/vertex-logo-loading.d.ts +2 -2
  395. package/dist/components/vertex-logo-loading.js +1 -34
  396. package/dist/components/vertex-menu-divider.d.ts +2 -2
  397. package/dist/components/vertex-menu-divider.js +1 -34
  398. package/dist/components/vertex-menu-item.d.ts +2 -2
  399. package/dist/components/vertex-menu-item.js +1 -44
  400. package/dist/components/vertex-menu.d.ts +2 -2
  401. package/dist/components/vertex-menu.js +1 -6
  402. package/dist/components/vertex-popover.d.ts +2 -2
  403. package/dist/components/vertex-popover.js +1 -6
  404. package/dist/components/vertex-radio-group.d.ts +2 -2
  405. package/dist/components/vertex-radio-group.js +1 -98
  406. package/dist/components/vertex-radio.d.ts +2 -2
  407. package/dist/components/vertex-radio.js +1 -56
  408. package/dist/components/vertex-resizable.d.ts +2 -2
  409. package/dist/components/vertex-resizable.js +1 -463
  410. package/dist/components/vertex-result-list.d.ts +2 -2
  411. package/dist/components/vertex-result-list.js +1 -6
  412. package/dist/components/vertex-search-bar.d.ts +2 -2
  413. package/dist/components/vertex-search-bar.js +1 -568
  414. package/dist/components/vertex-select.d.ts +2 -2
  415. package/dist/components/vertex-select.js +1 -202
  416. package/dist/components/vertex-slider.d.ts +2 -2
  417. package/dist/components/vertex-slider.js +1 -81
  418. package/dist/components/vertex-spinner.d.ts +2 -2
  419. package/dist/components/vertex-spinner.js +1 -49
  420. package/dist/components/vertex-tab.d.ts +2 -2
  421. package/dist/components/vertex-tab.js +1 -46
  422. package/dist/components/vertex-tabs.d.ts +2 -2
  423. package/dist/components/vertex-tabs.js +1 -133
  424. package/dist/components/vertex-textfield.d.ts +2 -2
  425. package/dist/components/vertex-textfield.js +1 -6
  426. package/dist/components/vertex-toast.d.ts +2 -2
  427. package/dist/components/vertex-toast.js +1 -127
  428. package/dist/components/vertex-toggle.d.ts +2 -2
  429. package/dist/components/vertex-toggle.js +1 -67
  430. package/dist/components/vertex-tooltip.d.ts +2 -2
  431. package/dist/components/vertex-tooltip.js +1 -6
  432. package/dist/esm/components.js +14 -83
  433. package/dist/{components/dom.js → esm/dom-Oz9KwTs0.js} +4 -4
  434. package/dist/esm/icon-helper-Dw0fFePg.js +557 -0
  435. package/dist/esm/index-Beav1bNT.js +92 -0
  436. package/dist/esm/index-C27tS7nl.js +2219 -0
  437. package/dist/esm/index-DYRkgxax.js +60 -0
  438. package/dist/esm/index.js +50 -49
  439. package/dist/esm/{lib-73fbca8b.js → lib-DgySd_r0.js} +2 -2
  440. package/dist/esm/loader.js +6 -14
  441. package/dist/esm/slots-DXuCPm6v.js +26 -0
  442. package/dist/esm/templates-DZ8xV3--.js +228 -0
  443. package/dist/esm/tslib.es6-CIs0DJX1.js +65 -0
  444. package/dist/esm/vertex-auto-resize-textarea.entry.js +136 -3
  445. package/dist/esm/vertex-avatar-group.entry.js +15 -2
  446. package/dist/esm/vertex-avatar.entry.js +47 -3
  447. package/dist/esm/vertex-badge.entry.js +24 -3
  448. package/dist/esm/vertex-banner.entry.js +125 -4
  449. package/dist/esm/vertex-button.entry.js +86 -3
  450. package/dist/esm/vertex-card-group.entry.js +37 -3
  451. package/dist/esm/vertex-card.entry.js +36 -2
  452. package/dist/esm/vertex-chip.entry.js +31 -3
  453. package/dist/esm/vertex-click-to-edit-textfield.entry.js +114 -3
  454. package/dist/esm/vertex-collapsible.entry.js +25 -3
  455. package/dist/esm/vertex-color-circle-picker.entry.js +145 -3
  456. package/dist/esm/vertex-color-picker.entry.js +70 -4
  457. package/dist/esm/vertex-color-swatch.entry.js +144 -4
  458. package/dist/esm/vertex-context-menu.entry.js +93 -2
  459. package/dist/esm/vertex-dialog.entry.js +230 -3
  460. package/dist/esm/vertex-draggable-popover.entry.js +82 -3
  461. package/dist/esm/vertex-dropdown-menu.entry.js +36 -2
  462. package/dist/esm/vertex-expandable.entry.js +104 -3
  463. package/dist/esm/vertex-help-tooltip.entry.js +39 -2
  464. package/dist/esm/vertex-icon-button.entry.js +61 -4
  465. package/dist/esm/vertex-icon.entry.js +32 -4
  466. package/dist/esm/vertex-logo-loading.entry.js +15 -2
  467. package/dist/esm/vertex-menu-divider.entry.js +15 -2
  468. package/dist/esm/vertex-menu-item.entry.js +27 -3
  469. package/dist/esm/vertex-menu.entry.js +83 -3
  470. package/dist/esm/vertex-popover.entry.js +1898 -3
  471. package/dist/esm/vertex-radio-group.entry.js +76 -2
  472. package/dist/esm/vertex-radio.entry.js +32 -3
  473. package/dist/esm/vertex-resizable.entry.js +442 -4
  474. package/dist/esm/vertex-result-list.entry.js +304 -5
  475. package/dist/esm/vertex-search-bar.entry.js +532 -5
  476. package/dist/esm/vertex-select.entry.js +184 -3
  477. package/dist/esm/vertex-slider.entry.js +58 -4
  478. package/dist/esm/vertex-spinner.entry.js +35 -3
  479. package/dist/esm/vertex-tab.entry.js +23 -3
  480. package/dist/esm/vertex-tabs.entry.js +108 -4
  481. package/dist/esm/vertex-textfield.entry.js +149 -3
  482. package/dist/esm/vertex-toast.entry.js +112 -3
  483. package/dist/esm/vertex-toggle.entry.js +50 -3
  484. package/dist/esm/vertex-tooltip.entry.js +347 -6
  485. package/dist/types/components/auto-resize-textarea/auto-resize-textarea.d.ts +43 -43
  486. package/dist/types/components/avatar/avatar.d.ts +33 -33
  487. package/dist/types/components/avatar-group/avatar-group.d.ts +1 -1
  488. package/dist/types/components/badge/badge.d.ts +10 -10
  489. package/dist/types/components/banner/banner.d.ts +50 -50
  490. package/dist/types/components/button/button.d.ts +52 -52
  491. package/dist/types/components/card/card.d.ts +19 -19
  492. package/dist/types/components/card-group/card-group.d.ts +13 -13
  493. package/dist/types/components/chip/chip.d.ts +11 -11
  494. package/dist/types/components/click-to-edit-text-field/click-to-edit-text-field.d.ts +78 -78
  495. package/dist/types/components/collapsible/collapsible.d.ts +10 -10
  496. package/dist/types/components/color-circle-picker/color-circle-picker.d.ts +89 -89
  497. package/dist/types/components/color-picker/color-picker.d.ts +46 -46
  498. package/dist/types/components/color-swatch/color-swatch.d.ts +69 -69
  499. package/dist/types/components/context-menu/context-menu.d.ts +33 -33
  500. package/dist/types/components/dialog/dialog.d.ts +55 -55
  501. package/dist/types/components/draggable-popover/draggable-popover.d.ts +32 -32
  502. package/dist/types/components/dropdown-menu/dropdown-menu.d.ts +22 -22
  503. package/dist/types/components/expandable/expandable.d.ts +58 -58
  504. package/dist/types/components/help-tooltip/help-tooltip.d.ts +22 -22
  505. package/dist/types/components/icon/icon.d.ts +15 -15
  506. package/dist/types/components/icon/icons/adjustments.d.ts +0 -1
  507. package/dist/types/components/icon/icons/align-to-global.d.ts +0 -1
  508. package/dist/types/components/icon/icons/align-to-part.d.ts +0 -1
  509. package/dist/types/components/icon/icons/align-to-surface.d.ts +0 -1
  510. package/dist/types/components/icon/icons/align-view-to-plane.d.ts +0 -1
  511. package/dist/types/components/icon/icons/annotation.d.ts +0 -1
  512. package/dist/types/components/icon/icons/arrow-filled.d.ts +0 -1
  513. package/dist/types/components/icon/icons/arrow-left-circled.d.ts +0 -1
  514. package/dist/types/components/icon/icons/arrow-line-left.d.ts +0 -1
  515. package/dist/types/components/icon/icons/arrow-line-right.d.ts +0 -1
  516. package/dist/types/components/icon/icons/arrow-partial.d.ts +0 -1
  517. package/dist/types/components/icon/icons/arrow-right-circled.d.ts +0 -1
  518. package/dist/types/components/icon/icons/arrow-swap.d.ts +0 -1
  519. package/dist/types/components/icon/icons/arrow-triangle-left.d.ts +0 -1
  520. package/dist/types/components/icon/icons/arrow-triangle-right.d.ts +0 -1
  521. package/dist/types/components/icon/icons/arrow-up-circled.d.ts +0 -1
  522. package/dist/types/components/icon/icons/attachment.d.ts +0 -1
  523. package/dist/types/components/icon/icons/axis-x.d.ts +0 -1
  524. package/dist/types/components/icon/icons/axis-y.d.ts +0 -1
  525. package/dist/types/components/icon/icons/axis-z.d.ts +0 -1
  526. package/dist/types/components/icon/icons/back.d.ts +0 -1
  527. package/dist/types/components/icon/icons/box-cursor.d.ts +0 -1
  528. package/dist/types/components/icon/icons/box-select.d.ts +0 -1
  529. package/dist/types/components/icon/icons/camera-add.d.ts +0 -1
  530. package/dist/types/components/icon/icons/camera.d.ts +0 -1
  531. package/dist/types/components/icon/icons/caret-down.d.ts +0 -1
  532. package/dist/types/components/icon/icons/caret-left.d.ts +0 -1
  533. package/dist/types/components/icon/icons/caret-right.d.ts +0 -1
  534. package/dist/types/components/icon/icons/caret-up.d.ts +0 -1
  535. package/dist/types/components/icon/icons/caution.d.ts +0 -1
  536. package/dist/types/components/icon/icons/check-circle.d.ts +0 -1
  537. package/dist/types/components/icon/icons/check.d.ts +0 -1
  538. package/dist/types/components/icon/icons/chevron-down.d.ts +0 -1
  539. package/dist/types/components/icon/icons/chevron-left.d.ts +0 -1
  540. package/dist/types/components/icon/icons/chevron-right.d.ts +0 -1
  541. package/dist/types/components/icon/icons/chevron-up.d.ts +0 -1
  542. package/dist/types/components/icon/icons/circle-outline.d.ts +0 -1
  543. package/dist/types/components/icon/icons/close-circle-fill.d.ts +0 -1
  544. package/dist/types/components/icon/icons/close-circle.d.ts +0 -1
  545. package/dist/types/components/icon/icons/close.d.ts +0 -1
  546. package/dist/types/components/icon/icons/collapse-all.d.ts +0 -1
  547. package/dist/types/components/icon/icons/columns-add.d.ts +0 -1
  548. package/dist/types/components/icon/icons/columns.d.ts +0 -1
  549. package/dist/types/components/icon/icons/comment-add.d.ts +0 -1
  550. package/dist/types/components/icon/icons/comment-filled.d.ts +0 -1
  551. package/dist/types/components/icon/icons/comment-reopen.d.ts +0 -1
  552. package/dist/types/components/icon/icons/comment-resolve.d.ts +0 -1
  553. package/dist/types/components/icon/icons/comment-show.d.ts +0 -1
  554. package/dist/types/components/icon/icons/compare.d.ts +0 -1
  555. package/dist/types/components/icon/icons/compress.d.ts +0 -1
  556. package/dist/types/components/icon/icons/copy.d.ts +0 -1
  557. package/dist/types/components/icon/icons/cross-section.d.ts +0 -1
  558. package/dist/types/components/icon/icons/cube-orthographic.d.ts +0 -1
  559. package/dist/types/components/icon/icons/cube-perspective.d.ts +0 -1
  560. package/dist/types/components/icon/icons/cube-stack.d.ts +0 -1
  561. package/dist/types/components/icon/icons/delete.d.ts +0 -1
  562. package/dist/types/components/icon/icons/download.d.ts +0 -1
  563. package/dist/types/components/icon/icons/drag-indicator.d.ts +0 -1
  564. package/dist/types/components/icon/icons/ellipse.d.ts +0 -1
  565. package/dist/types/components/icon/icons/error-circle.d.ts +0 -1
  566. package/dist/types/components/icon/icons/expand-all.d.ts +0 -1
  567. package/dist/types/components/icon/icons/expand.d.ts +0 -1
  568. package/dist/types/components/icon/icons/export.d.ts +0 -1
  569. package/dist/types/components/icon/icons/file-folder.d.ts +0 -1
  570. package/dist/types/components/icon/icons/file-pdf.d.ts +0 -1
  571. package/dist/types/components/icon/icons/file.d.ts +0 -1
  572. package/dist/types/components/icon/icons/fit-all.d.ts +0 -1
  573. package/dist/types/components/icon/icons/fit-selected.d.ts +0 -1
  574. package/dist/types/components/icon/icons/flip.d.ts +0 -1
  575. package/dist/types/components/icon/icons/folder-plus.d.ts +0 -1
  576. package/dist/types/components/icon/icons/forward.d.ts +0 -1
  577. package/dist/types/components/icon/icons/gear.d.ts +0 -1
  578. package/dist/types/components/icon/icons/help.d.ts +0 -1
  579. package/dist/types/components/icon/icons/info.d.ts +0 -1
  580. package/dist/types/components/icon/icons/invert.d.ts +0 -1
  581. package/dist/types/components/icon/icons/label-off.d.ts +0 -1
  582. package/dist/types/components/icon/icons/label.d.ts +0 -1
  583. package/dist/types/components/icon/icons/line-dot-left.d.ts +0 -1
  584. package/dist/types/components/icon/icons/line-dot-right.d.ts +0 -1
  585. package/dist/types/components/icon/icons/line-hash-left.d.ts +0 -1
  586. package/dist/types/components/icon/icons/line-hash-right.d.ts +0 -1
  587. package/dist/types/components/icon/icons/line.d.ts +0 -1
  588. package/dist/types/components/icon/icons/locate.d.ts +0 -1
  589. package/dist/types/components/icon/icons/lock-closed.d.ts +0 -1
  590. package/dist/types/components/icon/icons/lock-open.d.ts +0 -1
  591. package/dist/types/components/icon/icons/markup.d.ts +0 -1
  592. package/dist/types/components/icon/icons/menu.d.ts +0 -1
  593. package/dist/types/components/icon/icons/notification.d.ts +0 -1
  594. package/dist/types/components/icon/icons/open-window.d.ts +0 -1
  595. package/dist/types/components/icon/icons/open.d.ts +0 -1
  596. package/dist/types/components/icon/icons/pan.d.ts +0 -1
  597. package/dist/types/components/icon/icons/paper-airplane.d.ts +0 -1
  598. package/dist/types/components/icon/icons/paste.d.ts +0 -1
  599. package/dist/types/components/icon/icons/pencil.d.ts +0 -1
  600. package/dist/types/components/icon/icons/person-height.d.ts +0 -1
  601. package/dist/types/components/icon/icons/person-run.d.ts +0 -1
  602. package/dist/types/components/icon/icons/person-short.d.ts +0 -1
  603. package/dist/types/components/icon/icons/person-tall.d.ts +0 -1
  604. package/dist/types/components/icon/icons/person-walk.d.ts +0 -1
  605. package/dist/types/components/icon/icons/pin-fill.d.ts +0 -1
  606. package/dist/types/components/icon/icons/pin-line.d.ts +0 -1
  607. package/dist/types/components/icon/icons/pin-text-fill.d.ts +0 -1
  608. package/dist/types/components/icon/icons/pin-text-square.d.ts +0 -1
  609. package/dist/types/components/icon/icons/pin-text.d.ts +0 -1
  610. package/dist/types/components/icon/icons/plus-with-arrow.d.ts +0 -1
  611. package/dist/types/components/icon/icons/plus.d.ts +0 -1
  612. package/dist/types/components/icon/icons/pmi.d.ts +0 -1
  613. package/dist/types/components/icon/icons/precise-measurement.d.ts +0 -1
  614. package/dist/types/components/icon/icons/rabbit.d.ts +0 -1
  615. package/dist/types/components/icon/icons/refresh.d.ts +0 -1
  616. package/dist/types/components/icon/icons/rename.d.ts +0 -1
  617. package/dist/types/components/icon/icons/report.d.ts +0 -1
  618. package/dist/types/components/icon/icons/reset.d.ts +0 -1
  619. package/dist/types/components/icon/icons/resize.d.ts +0 -1
  620. package/dist/types/components/icon/icons/rotate.d.ts +0 -1
  621. package/dist/types/components/icon/icons/ruler.d.ts +0 -1
  622. package/dist/types/components/icon/icons/scissors.d.ts +0 -1
  623. package/dist/types/components/icon/icons/search.d.ts +0 -1
  624. package/dist/types/components/icon/icons/show-only-nearby.d.ts +0 -1
  625. package/dist/types/components/icon/icons/snapshots.d.ts +0 -1
  626. package/dist/types/components/icon/icons/square-dot-outline.d.ts +0 -1
  627. package/dist/types/components/icon/icons/star.d.ts +0 -1
  628. package/dist/types/components/icon/icons/tag.d.ts +0 -1
  629. package/dist/types/components/icon/icons/tape-measure.d.ts +0 -1
  630. package/dist/types/components/icon/icons/teleport-and-align.d.ts +0 -1
  631. package/dist/types/components/icon/icons/teleport-toward.d.ts +0 -1
  632. package/dist/types/components/icon/icons/teleport.d.ts +0 -1
  633. package/dist/types/components/icon/icons/triad.d.ts +0 -1
  634. package/dist/types/components/icon/icons/turtle.d.ts +0 -1
  635. package/dist/types/components/icon/icons/update.d.ts +0 -1
  636. package/dist/types/components/icon/icons/version-history.d.ts +0 -1
  637. package/dist/types/components/icon/icons/views.d.ts +0 -1
  638. package/dist/types/components/icon/icons/visibility-hidden.d.ts +0 -1
  639. package/dist/types/components/icon/icons/visibility-partial.d.ts +0 -1
  640. package/dist/types/components/icon/icons/visibility-visible.d.ts +0 -1
  641. package/dist/types/components/icon/icons/workspace-add.d.ts +0 -1
  642. package/dist/types/components/icon/icons/zoom.d.ts +0 -1
  643. package/dist/types/components/icon-button/icon-button.d.ts +36 -36
  644. package/dist/types/components/logo-loading/logo-loading.d.ts +1 -1
  645. package/dist/types/components/menu/menu.d.ts +53 -53
  646. package/dist/types/components/menu-divider/menu-divider.d.ts +1 -1
  647. package/dist/types/components/menu-item/menu-item.d.ts +6 -6
  648. package/dist/types/components/popover/popover.d.ts +156 -156
  649. package/dist/types/components/radio/radio.d.ts +28 -28
  650. package/dist/types/components/radio-group/radio-group.d.ts +23 -23
  651. package/dist/types/components/resizable/resizable.d.ts +161 -161
  652. package/dist/types/components/result-list/result-list.d.ts +42 -42
  653. package/dist/types/components/result-list/types.d.ts +2 -2
  654. package/dist/types/components/search-bar/lib.d.ts +5 -5
  655. package/dist/types/components/search-bar/search-bar.d.ts +144 -144
  656. package/dist/types/components/select/select.d.ts +65 -65
  657. package/dist/types/components/slider/slider.d.ts +44 -44
  658. package/dist/types/components/spinner/spinner.d.ts +11 -11
  659. package/dist/types/components/tab/tab.d.ts +8 -8
  660. package/dist/types/components/tabs/tabs.d.ts +20 -20
  661. package/dist/types/components/text-field/text-field.d.ts +112 -112
  662. package/dist/types/components/toast/toast.d.ts +50 -50
  663. package/dist/types/components/toggle/toggle.d.ts +17 -17
  664. package/dist/types/components/tooltip/tooltip.d.ts +60 -60
  665. package/dist/types/components.d.ts +970 -90
  666. package/dist/types/stencil-public-runtime.d.ts +257 -34
  667. package/dist/types/types/icon.d.ts +137 -137
  668. package/dist/types/types/point.d.ts +2 -2
  669. package/dist/types/util/components/slots.d.ts +3 -3
  670. package/dist/types/util/templates/binding.d.ts +20 -20
  671. package/dist/types/util/templates/disposable.d.ts +4 -4
  672. package/dist/types/util/templates/element-pool.d.ts +19 -19
  673. package/dist/types/util/templates/templates.d.ts +2 -2
  674. package/loader/cdn.js +1 -3
  675. package/loader/index.cjs.js +1 -3
  676. package/loader/index.d.ts +5 -2
  677. package/loader/index.es2017.js +1 -3
  678. package/loader/index.js +1 -3
  679. package/package.json +32 -32
  680. package/dist/cjs/auto-resize-textarea-deb05359.js +0 -137
  681. package/dist/cjs/avatar-e69bb687.js +0 -45
  682. package/dist/cjs/avatar-group-d2af53e4.js +0 -17
  683. package/dist/cjs/badge-d39ac1fc.js +0 -23
  684. package/dist/cjs/banner-8325d5ca.js +0 -104
  685. package/dist/cjs/button-e63d25b1.js +0 -70
  686. package/dist/cjs/card-ae9e8a8f.js +0 -30
  687. package/dist/cjs/card-group-da93e610.js +0 -30
  688. package/dist/cjs/chip-a3b2e8e0.js +0 -25
  689. package/dist/cjs/click-to-edit-text-field-2c87ee66.js +0 -105
  690. package/dist/cjs/collapsible-50ea984c.js +0 -25
  691. package/dist/cjs/color-circle-picker-b0927289.js +0 -82
  692. package/dist/cjs/color-picker-6aa97d3b.js +0 -47
  693. package/dist/cjs/color-swatch-6d98da5f.js +0 -95
  694. package/dist/cjs/context-menu-664922cd.js +0 -91
  695. package/dist/cjs/dialog-34244fe1.js +0 -225
  696. package/dist/cjs/dom-ff96a4bc.js +0 -75
  697. package/dist/cjs/draggable-popover-125717a7.js +0 -83
  698. package/dist/cjs/dropdown-menu-5ae03a72.js +0 -31
  699. package/dist/cjs/expandable-b1cd4f0b.js +0 -72
  700. package/dist/cjs/help-tooltip-f72eccc7.js +0 -34
  701. package/dist/cjs/icon-ab3e2b83.js +0 -26
  702. package/dist/cjs/icon-button-9a6314cd.js +0 -43
  703. package/dist/cjs/icon-helper-b2117772.js +0 -785
  704. package/dist/cjs/index-6a92256c.js +0 -2152
  705. package/dist/cjs/index-e1b40fa6.js +0 -91
  706. package/dist/cjs/logo-loading-4d49fedf.js +0 -17
  707. package/dist/cjs/menu-bfc03108.js +0 -74
  708. package/dist/cjs/menu-divider-5bdebe5d.js +0 -17
  709. package/dist/cjs/menu-item-d213fd4d.js +0 -25
  710. package/dist/cjs/popover-942209b8.js +0 -1706
  711. package/dist/cjs/radio-bff991d2.js +0 -34
  712. package/dist/cjs/radio-group-11ecf8bf.js +0 -78
  713. package/dist/cjs/resizable-c0a69532.js +0 -423
  714. package/dist/cjs/result-list-241ffe8d.js +0 -304
  715. package/dist/cjs/search-bar-2e7ee35a.js +0 -527
  716. package/dist/cjs/select-554f3c11.js +0 -163
  717. package/dist/cjs/shadow-css-8eb74fbb.js +0 -389
  718. package/dist/cjs/slider-7714cccb.js +0 -44
  719. package/dist/cjs/slots-fb5ac359.js +0 -29
  720. package/dist/cjs/spinner-bb990a42.js +0 -29
  721. package/dist/cjs/tab-4335cd8f.js +0 -26
  722. package/dist/cjs/tabs-6f3e76e1.js +0 -111
  723. package/dist/cjs/templates-e7b3ffbb.js +0 -230
  724. package/dist/cjs/text-field-bccbde1f.js +0 -133
  725. package/dist/cjs/toast-bee7f47b.js +0 -90
  726. package/dist/cjs/toggle-a5dde469.js +0 -40
  727. package/dist/cjs/tooltip-634eb8c9.js +0 -333
  728. package/dist/cjs/tslib.es6-838fd860.js +0 -68
  729. package/dist/components/auto-resize-textarea.js +0 -157
  730. package/dist/components/color-swatch.js +0 -124
  731. package/dist/components/expandable.js +0 -100
  732. package/dist/components/icon-button.js +0 -63
  733. package/dist/components/icon-helper.js +0 -783
  734. package/dist/components/icon.js +0 -43
  735. package/dist/components/index2.js +0 -89
  736. package/dist/components/menu.js +0 -103
  737. package/dist/components/p-01d4be1d.entry.js +0 -1
  738. package/dist/components/p-0541e2b0.js +0 -1
  739. package/dist/components/p-09ba50c3.js +0 -1
  740. package/dist/components/p-0b4406fa.entry.js +0 -1
  741. package/dist/components/p-0de26b21.entry.js +0 -1
  742. package/dist/components/p-0e628c05.js +0 -1
  743. package/dist/components/p-16fc9e9a.entry.js +0 -1
  744. package/dist/components/p-18ed73e9.js +0 -1
  745. package/dist/components/p-1e645c1f.js +0 -1
  746. package/dist/components/p-211c1186.entry.js +0 -1
  747. package/dist/components/p-226e83a6.entry.js +0 -1
  748. package/dist/components/p-22ec9b78.entry.js +0 -1
  749. package/dist/components/p-24c72960.entry.js +0 -1
  750. package/dist/components/p-2930bcb0.entry.js +0 -1
  751. package/dist/components/p-29d7697f.js +0 -1
  752. package/dist/components/p-2ae8175d.entry.js +0 -1
  753. package/dist/components/p-2cff3285.js +0 -1
  754. package/dist/components/p-33400eed.entry.js +0 -1
  755. package/dist/components/p-3508048d.js +0 -12
  756. package/dist/components/p-36c853c4.js +0 -1
  757. package/dist/components/p-39133bc7.js +0 -1
  758. package/dist/components/p-3b794014.entry.js +0 -1
  759. package/dist/components/p-3dd08a0f.js +0 -1
  760. package/dist/components/p-406e73da.entry.js +0 -1
  761. package/dist/components/p-407430fe.entry.js +0 -1
  762. package/dist/components/p-41ced35c.entry.js +0 -1
  763. package/dist/components/p-43b1b3f9.js +0 -1
  764. package/dist/components/p-48629bf1.js +0 -1
  765. package/dist/components/p-4e3ba3df.entry.js +0 -1
  766. package/dist/components/p-53515813.entry.js +0 -1
  767. package/dist/components/p-5366a759.entry.js +0 -1
  768. package/dist/components/p-573b8ec6.entry.js +0 -1
  769. package/dist/components/p-59fb829f.js +0 -1
  770. package/dist/components/p-5fb1724f.js +0 -1
  771. package/dist/components/p-606596de.entry.js +0 -1
  772. package/dist/components/p-65f9817e.js +0 -1
  773. package/dist/components/p-6834631c.js +0 -2
  774. package/dist/components/p-69375605.entry.js +0 -1
  775. package/dist/components/p-6a49c365.entry.js +0 -1
  776. package/dist/components/p-6a640a2c.js +0 -1
  777. package/dist/components/p-6b6c2260.js +0 -1
  778. package/dist/components/p-6b862967.js +0 -1
  779. package/dist/components/p-6d4f055b.entry.js +0 -1
  780. package/dist/components/p-756c9977.entry.js +0 -1
  781. package/dist/components/p-7ace7800.entry.js +0 -1
  782. package/dist/components/p-7e6ca4fb.entry.js +0 -1
  783. package/dist/components/p-80c989fa.entry.js +0 -1
  784. package/dist/components/p-817bf6ff.js +0 -1
  785. package/dist/components/p-81cb4da4.js +0 -1
  786. package/dist/components/p-8a52767f.js +0 -1
  787. package/dist/components/p-8b211d6f.js +0 -1
  788. package/dist/components/p-8c69bb83.js +0 -1
  789. package/dist/components/p-8d83dfff.entry.js +0 -1
  790. package/dist/components/p-8fe0084d.js +0 -1
  791. package/dist/components/p-90931a94.js +0 -1
  792. package/dist/components/p-90b4e04b.js +0 -1
  793. package/dist/components/p-90cf31d2.js +0 -1
  794. package/dist/components/p-91123ff6.entry.js +0 -1
  795. package/dist/components/p-95358d00.entry.js +0 -1
  796. package/dist/components/p-96f55673.js +0 -1
  797. package/dist/components/p-988058f9.js +0 -1
  798. package/dist/components/p-9c384f6c.entry.js +0 -1
  799. package/dist/components/p-a2018217.entry.js +0 -1
  800. package/dist/components/p-a3c04bbd.js +0 -1
  801. package/dist/components/p-a6614625.js +0 -1
  802. package/dist/components/p-bca6275a.entry.js +0 -1
  803. package/dist/components/p-bec53c3a.js +0 -1
  804. package/dist/components/p-c2706288.js +0 -1
  805. package/dist/components/p-c2c076f1.js +0 -1
  806. package/dist/components/p-c3ec6642.js +0 -19
  807. package/dist/components/p-c8ab09fb.js +0 -1
  808. package/dist/components/p-c939fa4e.js +0 -1
  809. package/dist/components/p-c9a967d9.js +0 -1
  810. package/dist/components/p-cc2e3192.entry.js +0 -1
  811. package/dist/components/p-d7c0c287.entry.js +0 -1
  812. package/dist/components/p-dfe98f07.entry.js +0 -1
  813. package/dist/components/p-e3d0c2d1.entry.js +0 -1
  814. package/dist/components/p-e3ea44b2.js +0 -1
  815. package/dist/components/p-ea8f3750.entry.js +0 -1
  816. package/dist/components/p-ec7be8df.js +0 -1
  817. package/dist/components/p-ee496965.entry.js +0 -1
  818. package/dist/components/p-f2bc7ec5.js +0 -1
  819. package/dist/components/p-f55574fb.js +0 -1
  820. package/dist/components/p-f6f2bc86.entry.js +0 -1
  821. package/dist/components/p-fe062eb0.js +0 -7
  822. package/dist/components/p-fe7e7a74.entry.js +0 -1
  823. package/dist/components/p-fedcc21e.js +0 -1
  824. package/dist/components/p-ff4a1c3a.js +0 -1
  825. package/dist/components/popover.js +0 -1737
  826. package/dist/components/result-list.js +0 -565
  827. package/dist/components/slots.js +0 -26
  828. package/dist/components/text-field.js +0 -171
  829. package/dist/components/tooltip.js +0 -360
  830. package/dist/components/tslib.es6.js +0 -65
  831. package/dist/esm/auto-resize-textarea-087fecdb.js +0 -135
  832. package/dist/esm/avatar-775455a5.js +0 -43
  833. package/dist/esm/avatar-group-e5ca86bf.js +0 -15
  834. package/dist/esm/badge-6d27ca92.js +0 -21
  835. package/dist/esm/banner-b292060d.js +0 -102
  836. package/dist/esm/button-81207236.js +0 -68
  837. package/dist/esm/card-1e8790aa.js +0 -28
  838. package/dist/esm/card-group-4e8e0421.js +0 -28
  839. package/dist/esm/chip-4e568eee.js +0 -23
  840. package/dist/esm/click-to-edit-text-field-d9b27cd0.js +0 -103
  841. package/dist/esm/collapsible-b52960e6.js +0 -23
  842. package/dist/esm/color-circle-picker-c4e92fea.js +0 -80
  843. package/dist/esm/color-picker-b292ad8d.js +0 -45
  844. package/dist/esm/color-swatch-ab647632.js +0 -93
  845. package/dist/esm/context-menu-12f1afe1.js +0 -89
  846. package/dist/esm/dialog-c69d9152.js +0 -223
  847. package/dist/esm/dom-64053c71.js +0 -73
  848. package/dist/esm/dom-9d0f7bf4.js +0 -13
  849. package/dist/esm/draggable-popover-9f9b7c97.js +0 -81
  850. package/dist/esm/dropdown-menu-1598ba20.js +0 -29
  851. package/dist/esm/expandable-b487cb00.js +0 -70
  852. package/dist/esm/help-tooltip-c2f0d996.js +0 -32
  853. package/dist/esm/icon-390b9402.js +0 -24
  854. package/dist/esm/icon-button-552e31fe.js +0 -41
  855. package/dist/esm/icon-helper-7437b548.js +0 -783
  856. package/dist/esm/index-72f28b71.js +0 -2118
  857. package/dist/esm/index-9c609209.js +0 -89
  858. package/dist/esm/logo-loading-3c7fa23d.js +0 -15
  859. package/dist/esm/menu-49420f98.js +0 -72
  860. package/dist/esm/menu-divider-87c888cb.js +0 -15
  861. package/dist/esm/menu-item-c33aa9dd.js +0 -23
  862. package/dist/esm/polyfills/core-js.js +0 -11
  863. package/dist/esm/polyfills/css-shim.js +0 -1
  864. package/dist/esm/polyfills/dom.js +0 -79
  865. package/dist/esm/polyfills/es5-html-element.js +0 -1
  866. package/dist/esm/polyfills/index.js +0 -34
  867. package/dist/esm/polyfills/system.js +0 -6
  868. package/dist/esm/popover-6e806354.js +0 -1704
  869. package/dist/esm/radio-39c11ba4.js +0 -32
  870. package/dist/esm/radio-group-2f5467b5.js +0 -76
  871. package/dist/esm/resizable-833336bf.js +0 -421
  872. package/dist/esm/result-list-16c6afbd.js +0 -302
  873. package/dist/esm/search-bar-8d18626e.js +0 -525
  874. package/dist/esm/select-66bb59f8.js +0 -161
  875. package/dist/esm/shadow-css-008a49f5.js +0 -387
  876. package/dist/esm/slider-3d8545e3.js +0 -42
  877. package/dist/esm/slots-fbb5afb3.js +0 -26
  878. package/dist/esm/spinner-afccea51.js +0 -27
  879. package/dist/esm/tab-c76332b0.js +0 -24
  880. package/dist/esm/tabs-e9f6dcbe.js +0 -109
  881. package/dist/esm/templates-797420bf.js +0 -228
  882. package/dist/esm/text-field-32ac877e.js +0 -131
  883. package/dist/esm/toast-255648ff.js +0 -88
  884. package/dist/esm/tooltip-bed548f4.js +0 -331
  885. package/dist/esm/tslib.es6-99cd0de8.js +0 -65
  886. package/loader/package.json +0 -11
  887. /package/dist/components/{p-b2c7b113.js → p-DXuCPm6v.js} +0 -0
  888. /package/dist/components/{p-3438c441.js → p-DgySd_r0.js} +0 -0
@@ -1,3 +1,1898 @@
1
- export { P as vertex_popover } from './popover-6e806354.js';
2
- import './index-72f28b71.js';
3
- import './index-9c609209.js';
1
+ import { a as registerInstance, c as createEvent, h, H as Host, d as getElement } from './index-C27tS7nl.js';
2
+ import { c as classNames } from './index-Beav1bNT.js';
3
+
4
+ /**
5
+ * Custom positioning reference element.
6
+ * @see https://floating-ui.com/docs/virtual-elements
7
+ */
8
+
9
+ const min = Math.min;
10
+ const max = Math.max;
11
+ const round = Math.round;
12
+ const floor = Math.floor;
13
+ const createCoords = v => ({
14
+ x: v,
15
+ y: v
16
+ });
17
+ const oppositeSideMap = {
18
+ left: 'right',
19
+ right: 'left',
20
+ bottom: 'top',
21
+ top: 'bottom'
22
+ };
23
+ function clamp(start, value, end) {
24
+ return max(start, min(value, end));
25
+ }
26
+ function evaluate(value, param) {
27
+ return typeof value === 'function' ? value(param) : value;
28
+ }
29
+ function getSide(placement) {
30
+ return placement.split('-')[0];
31
+ }
32
+ function getAlignment(placement) {
33
+ return placement.split('-')[1];
34
+ }
35
+ function getOppositeAxis(axis) {
36
+ return axis === 'x' ? 'y' : 'x';
37
+ }
38
+ function getAxisLength(axis) {
39
+ return axis === 'y' ? 'height' : 'width';
40
+ }
41
+ function getSideAxis(placement) {
42
+ const firstChar = placement[0];
43
+ return firstChar === 't' || firstChar === 'b' ? 'y' : 'x';
44
+ }
45
+ function getAlignmentAxis(placement) {
46
+ return getOppositeAxis(getSideAxis(placement));
47
+ }
48
+ function getAlignmentSides(placement, rects, rtl) {
49
+ if (rtl === void 0) {
50
+ rtl = false;
51
+ }
52
+ const alignment = getAlignment(placement);
53
+ const alignmentAxis = getAlignmentAxis(placement);
54
+ const length = getAxisLength(alignmentAxis);
55
+ let mainAlignmentSide = alignmentAxis === 'x' ? alignment === (rtl ? 'end' : 'start') ? 'right' : 'left' : alignment === 'start' ? 'bottom' : 'top';
56
+ if (rects.reference[length] > rects.floating[length]) {
57
+ mainAlignmentSide = getOppositePlacement(mainAlignmentSide);
58
+ }
59
+ return [mainAlignmentSide, getOppositePlacement(mainAlignmentSide)];
60
+ }
61
+ function getExpandedPlacements(placement) {
62
+ const oppositePlacement = getOppositePlacement(placement);
63
+ return [getOppositeAlignmentPlacement(placement), oppositePlacement, getOppositeAlignmentPlacement(oppositePlacement)];
64
+ }
65
+ function getOppositeAlignmentPlacement(placement) {
66
+ return placement.includes('start') ? placement.replace('start', 'end') : placement.replace('end', 'start');
67
+ }
68
+ const lrPlacement = ['left', 'right'];
69
+ const rlPlacement = ['right', 'left'];
70
+ const tbPlacement = ['top', 'bottom'];
71
+ const btPlacement = ['bottom', 'top'];
72
+ function getSideList(side, isStart, rtl) {
73
+ switch (side) {
74
+ case 'top':
75
+ case 'bottom':
76
+ if (rtl) return isStart ? rlPlacement : lrPlacement;
77
+ return isStart ? lrPlacement : rlPlacement;
78
+ case 'left':
79
+ case 'right':
80
+ return isStart ? tbPlacement : btPlacement;
81
+ default:
82
+ return [];
83
+ }
84
+ }
85
+ function getOppositeAxisPlacements(placement, flipAlignment, direction, rtl) {
86
+ const alignment = getAlignment(placement);
87
+ let list = getSideList(getSide(placement), direction === 'start', rtl);
88
+ if (alignment) {
89
+ list = list.map(side => side + "-" + alignment);
90
+ if (flipAlignment) {
91
+ list = list.concat(list.map(getOppositeAlignmentPlacement));
92
+ }
93
+ }
94
+ return list;
95
+ }
96
+ function getOppositePlacement(placement) {
97
+ const side = getSide(placement);
98
+ return oppositeSideMap[side] + placement.slice(side.length);
99
+ }
100
+ function expandPaddingObject(padding) {
101
+ return {
102
+ top: 0,
103
+ right: 0,
104
+ bottom: 0,
105
+ left: 0,
106
+ ...padding
107
+ };
108
+ }
109
+ function getPaddingObject(padding) {
110
+ return typeof padding !== 'number' ? expandPaddingObject(padding) : {
111
+ top: padding,
112
+ right: padding,
113
+ bottom: padding,
114
+ left: padding
115
+ };
116
+ }
117
+ function rectToClientRect(rect) {
118
+ const {
119
+ x,
120
+ y,
121
+ width,
122
+ height
123
+ } = rect;
124
+ return {
125
+ width,
126
+ height,
127
+ top: y,
128
+ left: x,
129
+ right: x + width,
130
+ bottom: y + height,
131
+ x,
132
+ y
133
+ };
134
+ }
135
+
136
+ function computeCoordsFromPlacement(_ref, placement, rtl) {
137
+ let {
138
+ reference,
139
+ floating
140
+ } = _ref;
141
+ const sideAxis = getSideAxis(placement);
142
+ const alignmentAxis = getAlignmentAxis(placement);
143
+ const alignLength = getAxisLength(alignmentAxis);
144
+ const side = getSide(placement);
145
+ const isVertical = sideAxis === 'y';
146
+ const commonX = reference.x + reference.width / 2 - floating.width / 2;
147
+ const commonY = reference.y + reference.height / 2 - floating.height / 2;
148
+ const commonAlign = reference[alignLength] / 2 - floating[alignLength] / 2;
149
+ let coords;
150
+ switch (side) {
151
+ case 'top':
152
+ coords = {
153
+ x: commonX,
154
+ y: reference.y - floating.height
155
+ };
156
+ break;
157
+ case 'bottom':
158
+ coords = {
159
+ x: commonX,
160
+ y: reference.y + reference.height
161
+ };
162
+ break;
163
+ case 'right':
164
+ coords = {
165
+ x: reference.x + reference.width,
166
+ y: commonY
167
+ };
168
+ break;
169
+ case 'left':
170
+ coords = {
171
+ x: reference.x - floating.width,
172
+ y: commonY
173
+ };
174
+ break;
175
+ default:
176
+ coords = {
177
+ x: reference.x,
178
+ y: reference.y
179
+ };
180
+ }
181
+ switch (getAlignment(placement)) {
182
+ case 'start':
183
+ coords[alignmentAxis] -= commonAlign * (rtl && isVertical ? -1 : 1);
184
+ break;
185
+ case 'end':
186
+ coords[alignmentAxis] += commonAlign * (rtl && isVertical ? -1 : 1);
187
+ break;
188
+ }
189
+ return coords;
190
+ }
191
+
192
+ /**
193
+ * Resolves with an object of overflow side offsets that determine how much the
194
+ * element is overflowing a given clipping boundary on each side.
195
+ * - positive = overflowing the boundary by that number of pixels
196
+ * - negative = how many pixels left before it will overflow
197
+ * - 0 = lies flush with the boundary
198
+ * @see https://floating-ui.com/docs/detectOverflow
199
+ */
200
+ async function detectOverflow$1(state, options) {
201
+ var _await$platform$isEle;
202
+ if (options === void 0) {
203
+ options = {};
204
+ }
205
+ const {
206
+ x,
207
+ y,
208
+ platform,
209
+ rects,
210
+ elements,
211
+ strategy
212
+ } = state;
213
+ const {
214
+ boundary = 'clippingAncestors',
215
+ rootBoundary = 'viewport',
216
+ elementContext = 'floating',
217
+ altBoundary = false,
218
+ padding = 0
219
+ } = evaluate(options, state);
220
+ const paddingObject = getPaddingObject(padding);
221
+ const altContext = elementContext === 'floating' ? 'reference' : 'floating';
222
+ const element = elements[altBoundary ? altContext : elementContext];
223
+ const clippingClientRect = rectToClientRect(await platform.getClippingRect({
224
+ element: ((_await$platform$isEle = await (platform.isElement == null ? void 0 : platform.isElement(element))) != null ? _await$platform$isEle : true) ? element : element.contextElement || (await (platform.getDocumentElement == null ? void 0 : platform.getDocumentElement(elements.floating))),
225
+ boundary,
226
+ rootBoundary,
227
+ strategy
228
+ }));
229
+ const rect = elementContext === 'floating' ? {
230
+ x,
231
+ y,
232
+ width: rects.floating.width,
233
+ height: rects.floating.height
234
+ } : rects.reference;
235
+ const offsetParent = await (platform.getOffsetParent == null ? void 0 : platform.getOffsetParent(elements.floating));
236
+ const offsetScale = (await (platform.isElement == null ? void 0 : platform.isElement(offsetParent))) ? (await (platform.getScale == null ? void 0 : platform.getScale(offsetParent))) || {
237
+ x: 1,
238
+ y: 1
239
+ } : {
240
+ x: 1,
241
+ y: 1
242
+ };
243
+ const elementClientRect = rectToClientRect(platform.convertOffsetParentRelativeRectToViewportRelativeRect ? await platform.convertOffsetParentRelativeRectToViewportRelativeRect({
244
+ elements,
245
+ rect,
246
+ offsetParent,
247
+ strategy
248
+ }) : rect);
249
+ return {
250
+ top: (clippingClientRect.top - elementClientRect.top + paddingObject.top) / offsetScale.y,
251
+ bottom: (elementClientRect.bottom - clippingClientRect.bottom + paddingObject.bottom) / offsetScale.y,
252
+ left: (clippingClientRect.left - elementClientRect.left + paddingObject.left) / offsetScale.x,
253
+ right: (elementClientRect.right - clippingClientRect.right + paddingObject.right) / offsetScale.x
254
+ };
255
+ }
256
+
257
+ // Maximum number of resets that can occur before bailing to avoid infinite reset loops.
258
+ const MAX_RESET_COUNT = 50;
259
+
260
+ /**
261
+ * Computes the `x` and `y` coordinates that will place the floating element
262
+ * next to a given reference element.
263
+ *
264
+ * This export does not have any `platform` interface logic. You will need to
265
+ * write one for the platform you are using Floating UI with.
266
+ */
267
+ const computePosition$1 = async (reference, floating, config) => {
268
+ const {
269
+ placement = 'bottom',
270
+ strategy = 'absolute',
271
+ middleware = [],
272
+ platform
273
+ } = config;
274
+ const platformWithDetectOverflow = platform.detectOverflow ? platform : {
275
+ ...platform,
276
+ detectOverflow: detectOverflow$1
277
+ };
278
+ const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(floating));
279
+ let rects = await platform.getElementRects({
280
+ reference,
281
+ floating,
282
+ strategy
283
+ });
284
+ let {
285
+ x,
286
+ y
287
+ } = computeCoordsFromPlacement(rects, placement, rtl);
288
+ let statefulPlacement = placement;
289
+ let resetCount = 0;
290
+ const middlewareData = {};
291
+ for (let i = 0; i < middleware.length; i++) {
292
+ const currentMiddleware = middleware[i];
293
+ if (!currentMiddleware) {
294
+ continue;
295
+ }
296
+ const {
297
+ name,
298
+ fn
299
+ } = currentMiddleware;
300
+ const {
301
+ x: nextX,
302
+ y: nextY,
303
+ data,
304
+ reset
305
+ } = await fn({
306
+ x,
307
+ y,
308
+ initialPlacement: placement,
309
+ placement: statefulPlacement,
310
+ strategy,
311
+ middlewareData,
312
+ rects,
313
+ platform: platformWithDetectOverflow,
314
+ elements: {
315
+ reference,
316
+ floating
317
+ }
318
+ });
319
+ x = nextX != null ? nextX : x;
320
+ y = nextY != null ? nextY : y;
321
+ middlewareData[name] = {
322
+ ...middlewareData[name],
323
+ ...data
324
+ };
325
+ if (reset && resetCount < MAX_RESET_COUNT) {
326
+ resetCount++;
327
+ if (typeof reset === 'object') {
328
+ if (reset.placement) {
329
+ statefulPlacement = reset.placement;
330
+ }
331
+ if (reset.rects) {
332
+ rects = reset.rects === true ? await platform.getElementRects({
333
+ reference,
334
+ floating,
335
+ strategy
336
+ }) : reset.rects;
337
+ }
338
+ ({
339
+ x,
340
+ y
341
+ } = computeCoordsFromPlacement(rects, statefulPlacement, rtl));
342
+ }
343
+ i = -1;
344
+ }
345
+ }
346
+ return {
347
+ x,
348
+ y,
349
+ placement: statefulPlacement,
350
+ strategy,
351
+ middlewareData
352
+ };
353
+ };
354
+
355
+ /**
356
+ * Optimizes the visibility of the floating element by flipping the `placement`
357
+ * in order to keep it in view when the preferred placement(s) will overflow the
358
+ * clipping boundary. Alternative to `autoPlacement`.
359
+ * @see https://floating-ui.com/docs/flip
360
+ */
361
+ const flip$1 = function (options) {
362
+ if (options === void 0) {
363
+ options = {};
364
+ }
365
+ return {
366
+ name: 'flip',
367
+ options,
368
+ async fn(state) {
369
+ var _middlewareData$arrow, _middlewareData$flip;
370
+ const {
371
+ placement,
372
+ middlewareData,
373
+ rects,
374
+ initialPlacement,
375
+ platform,
376
+ elements
377
+ } = state;
378
+ const {
379
+ mainAxis: checkMainAxis = true,
380
+ crossAxis: checkCrossAxis = true,
381
+ fallbackPlacements: specifiedFallbackPlacements,
382
+ fallbackStrategy = 'bestFit',
383
+ fallbackAxisSideDirection = 'none',
384
+ flipAlignment = true,
385
+ ...detectOverflowOptions
386
+ } = evaluate(options, state);
387
+
388
+ // If a reset by the arrow was caused due to an alignment offset being
389
+ // added, we should skip any logic now since `flip()` has already done its
390
+ // work.
391
+ // https://github.com/floating-ui/floating-ui/issues/2549#issuecomment-1719601643
392
+ if ((_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
393
+ return {};
394
+ }
395
+ const side = getSide(placement);
396
+ const initialSideAxis = getSideAxis(initialPlacement);
397
+ const isBasePlacement = getSide(initialPlacement) === initialPlacement;
398
+ const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
399
+ const fallbackPlacements = specifiedFallbackPlacements || (isBasePlacement || !flipAlignment ? [getOppositePlacement(initialPlacement)] : getExpandedPlacements(initialPlacement));
400
+ const hasFallbackAxisSideDirection = fallbackAxisSideDirection !== 'none';
401
+ if (!specifiedFallbackPlacements && hasFallbackAxisSideDirection) {
402
+ fallbackPlacements.push(...getOppositeAxisPlacements(initialPlacement, flipAlignment, fallbackAxisSideDirection, rtl));
403
+ }
404
+ const placements = [initialPlacement, ...fallbackPlacements];
405
+ const overflow = await platform.detectOverflow(state, detectOverflowOptions);
406
+ const overflows = [];
407
+ let overflowsData = ((_middlewareData$flip = middlewareData.flip) == null ? void 0 : _middlewareData$flip.overflows) || [];
408
+ if (checkMainAxis) {
409
+ overflows.push(overflow[side]);
410
+ }
411
+ if (checkCrossAxis) {
412
+ const sides = getAlignmentSides(placement, rects, rtl);
413
+ overflows.push(overflow[sides[0]], overflow[sides[1]]);
414
+ }
415
+ overflowsData = [...overflowsData, {
416
+ placement,
417
+ overflows
418
+ }];
419
+
420
+ // One or more sides is overflowing.
421
+ if (!overflows.every(side => side <= 0)) {
422
+ var _middlewareData$flip2, _overflowsData$filter;
423
+ const nextIndex = (((_middlewareData$flip2 = middlewareData.flip) == null ? void 0 : _middlewareData$flip2.index) || 0) + 1;
424
+ const nextPlacement = placements[nextIndex];
425
+ if (nextPlacement) {
426
+ const ignoreCrossAxisOverflow = checkCrossAxis === 'alignment' ? initialSideAxis !== getSideAxis(nextPlacement) : false;
427
+ if (!ignoreCrossAxisOverflow ||
428
+ // We leave the current main axis only if every placement on that axis
429
+ // overflows the main axis.
430
+ overflowsData.every(d => getSideAxis(d.placement) === initialSideAxis ? d.overflows[0] > 0 : true)) {
431
+ // Try next placement and re-run the lifecycle.
432
+ return {
433
+ data: {
434
+ index: nextIndex,
435
+ overflows: overflowsData
436
+ },
437
+ reset: {
438
+ placement: nextPlacement
439
+ }
440
+ };
441
+ }
442
+ }
443
+
444
+ // First, find the candidates that fit on the mainAxis side of overflow,
445
+ // then find the placement that fits the best on the main crossAxis side.
446
+ let resetPlacement = (_overflowsData$filter = overflowsData.filter(d => d.overflows[0] <= 0).sort((a, b) => a.overflows[1] - b.overflows[1])[0]) == null ? void 0 : _overflowsData$filter.placement;
447
+
448
+ // Otherwise fallback.
449
+ if (!resetPlacement) {
450
+ switch (fallbackStrategy) {
451
+ case 'bestFit':
452
+ {
453
+ var _overflowsData$filter2;
454
+ const placement = (_overflowsData$filter2 = overflowsData.filter(d => {
455
+ if (hasFallbackAxisSideDirection) {
456
+ const currentSideAxis = getSideAxis(d.placement);
457
+ return currentSideAxis === initialSideAxis ||
458
+ // Create a bias to the `y` side axis due to horizontal
459
+ // reading directions favoring greater width.
460
+ currentSideAxis === 'y';
461
+ }
462
+ return true;
463
+ }).map(d => [d.placement, d.overflows.filter(overflow => overflow > 0).reduce((acc, overflow) => acc + overflow, 0)]).sort((a, b) => a[1] - b[1])[0]) == null ? void 0 : _overflowsData$filter2[0];
464
+ if (placement) {
465
+ resetPlacement = placement;
466
+ }
467
+ break;
468
+ }
469
+ case 'initialPlacement':
470
+ resetPlacement = initialPlacement;
471
+ break;
472
+ }
473
+ }
474
+ if (placement !== resetPlacement) {
475
+ return {
476
+ reset: {
477
+ placement: resetPlacement
478
+ }
479
+ };
480
+ }
481
+ }
482
+ return {};
483
+ }
484
+ };
485
+ };
486
+
487
+ const originSides = /*#__PURE__*/new Set(['left', 'top']);
488
+
489
+ // For type backwards-compatibility, the `OffsetOptions` type was also
490
+ // Derivable.
491
+
492
+ async function convertValueToCoords(state, options) {
493
+ const {
494
+ placement,
495
+ platform,
496
+ elements
497
+ } = state;
498
+ const rtl = await (platform.isRTL == null ? void 0 : platform.isRTL(elements.floating));
499
+ const side = getSide(placement);
500
+ const alignment = getAlignment(placement);
501
+ const isVertical = getSideAxis(placement) === 'y';
502
+ const mainAxisMulti = originSides.has(side) ? -1 : 1;
503
+ const crossAxisMulti = rtl && isVertical ? -1 : 1;
504
+ const rawValue = evaluate(options, state);
505
+
506
+ // eslint-disable-next-line prefer-const
507
+ let {
508
+ mainAxis,
509
+ crossAxis,
510
+ alignmentAxis
511
+ } = typeof rawValue === 'number' ? {
512
+ mainAxis: rawValue,
513
+ crossAxis: 0,
514
+ alignmentAxis: null
515
+ } : {
516
+ mainAxis: rawValue.mainAxis || 0,
517
+ crossAxis: rawValue.crossAxis || 0,
518
+ alignmentAxis: rawValue.alignmentAxis
519
+ };
520
+ if (alignment && typeof alignmentAxis === 'number') {
521
+ crossAxis = alignment === 'end' ? alignmentAxis * -1 : alignmentAxis;
522
+ }
523
+ return isVertical ? {
524
+ x: crossAxis * crossAxisMulti,
525
+ y: mainAxis * mainAxisMulti
526
+ } : {
527
+ x: mainAxis * mainAxisMulti,
528
+ y: crossAxis * crossAxisMulti
529
+ };
530
+ }
531
+
532
+ /**
533
+ * Modifies the placement by translating the floating element along the
534
+ * specified axes.
535
+ * A number (shorthand for `mainAxis` or distance), or an axes configuration
536
+ * object may be passed.
537
+ * @see https://floating-ui.com/docs/offset
538
+ */
539
+ const offset$1 = function (options) {
540
+ if (options === void 0) {
541
+ options = 0;
542
+ }
543
+ return {
544
+ name: 'offset',
545
+ options,
546
+ async fn(state) {
547
+ var _middlewareData$offse, _middlewareData$arrow;
548
+ const {
549
+ x,
550
+ y,
551
+ placement,
552
+ middlewareData
553
+ } = state;
554
+ const diffCoords = await convertValueToCoords(state, options);
555
+
556
+ // If the placement is the same and the arrow caused an alignment offset
557
+ // then we don't need to change the positioning coordinates.
558
+ if (placement === ((_middlewareData$offse = middlewareData.offset) == null ? void 0 : _middlewareData$offse.placement) && (_middlewareData$arrow = middlewareData.arrow) != null && _middlewareData$arrow.alignmentOffset) {
559
+ return {};
560
+ }
561
+ return {
562
+ x: x + diffCoords.x,
563
+ y: y + diffCoords.y,
564
+ data: {
565
+ ...diffCoords,
566
+ placement
567
+ }
568
+ };
569
+ }
570
+ };
571
+ };
572
+
573
+ /**
574
+ * Optimizes the visibility of the floating element by shifting it in order to
575
+ * keep it in view when it will overflow the clipping boundary.
576
+ * @see https://floating-ui.com/docs/shift
577
+ */
578
+ const shift$1 = function (options) {
579
+ if (options === void 0) {
580
+ options = {};
581
+ }
582
+ return {
583
+ name: 'shift',
584
+ options,
585
+ async fn(state) {
586
+ const {
587
+ x,
588
+ y,
589
+ placement,
590
+ platform
591
+ } = state;
592
+ const {
593
+ mainAxis: checkMainAxis = true,
594
+ crossAxis: checkCrossAxis = false,
595
+ limiter = {
596
+ fn: _ref => {
597
+ let {
598
+ x,
599
+ y
600
+ } = _ref;
601
+ return {
602
+ x,
603
+ y
604
+ };
605
+ }
606
+ },
607
+ ...detectOverflowOptions
608
+ } = evaluate(options, state);
609
+ const coords = {
610
+ x,
611
+ y
612
+ };
613
+ const overflow = await platform.detectOverflow(state, detectOverflowOptions);
614
+ const crossAxis = getSideAxis(getSide(placement));
615
+ const mainAxis = getOppositeAxis(crossAxis);
616
+ let mainAxisCoord = coords[mainAxis];
617
+ let crossAxisCoord = coords[crossAxis];
618
+ if (checkMainAxis) {
619
+ const minSide = mainAxis === 'y' ? 'top' : 'left';
620
+ const maxSide = mainAxis === 'y' ? 'bottom' : 'right';
621
+ const min = mainAxisCoord + overflow[minSide];
622
+ const max = mainAxisCoord - overflow[maxSide];
623
+ mainAxisCoord = clamp(min, mainAxisCoord, max);
624
+ }
625
+ if (checkCrossAxis) {
626
+ const minSide = crossAxis === 'y' ? 'top' : 'left';
627
+ const maxSide = crossAxis === 'y' ? 'bottom' : 'right';
628
+ const min = crossAxisCoord + overflow[minSide];
629
+ const max = crossAxisCoord - overflow[maxSide];
630
+ crossAxisCoord = clamp(min, crossAxisCoord, max);
631
+ }
632
+ const limitedCoords = limiter.fn({
633
+ ...state,
634
+ [mainAxis]: mainAxisCoord,
635
+ [crossAxis]: crossAxisCoord
636
+ });
637
+ return {
638
+ ...limitedCoords,
639
+ data: {
640
+ x: limitedCoords.x - x,
641
+ y: limitedCoords.y - y,
642
+ enabled: {
643
+ [mainAxis]: checkMainAxis,
644
+ [crossAxis]: checkCrossAxis
645
+ }
646
+ }
647
+ };
648
+ }
649
+ };
650
+ };
651
+
652
+ function hasWindow() {
653
+ return typeof window !== 'undefined';
654
+ }
655
+ function getNodeName(node) {
656
+ if (isNode(node)) {
657
+ return (node.nodeName || '').toLowerCase();
658
+ }
659
+ // Mocked nodes in testing environments may not be instances of Node. By
660
+ // returning `#document` an infinite loop won't occur.
661
+ // https://github.com/floating-ui/floating-ui/issues/2317
662
+ return '#document';
663
+ }
664
+ function getWindow(node) {
665
+ var _node$ownerDocument;
666
+ return (node == null || (_node$ownerDocument = node.ownerDocument) == null ? void 0 : _node$ownerDocument.defaultView) || window;
667
+ }
668
+ function getDocumentElement(node) {
669
+ var _ref;
670
+ return (_ref = (isNode(node) ? node.ownerDocument : node.document) || window.document) == null ? void 0 : _ref.documentElement;
671
+ }
672
+ function isNode(value) {
673
+ if (!hasWindow()) {
674
+ return false;
675
+ }
676
+ return value instanceof Node || value instanceof getWindow(value).Node;
677
+ }
678
+ function isElement(value) {
679
+ if (!hasWindow()) {
680
+ return false;
681
+ }
682
+ return value instanceof Element || value instanceof getWindow(value).Element;
683
+ }
684
+ function isHTMLElement(value) {
685
+ if (!hasWindow()) {
686
+ return false;
687
+ }
688
+ return value instanceof HTMLElement || value instanceof getWindow(value).HTMLElement;
689
+ }
690
+ function isShadowRoot(value) {
691
+ if (!hasWindow() || typeof ShadowRoot === 'undefined') {
692
+ return false;
693
+ }
694
+ return value instanceof ShadowRoot || value instanceof getWindow(value).ShadowRoot;
695
+ }
696
+ function isOverflowElement(element) {
697
+ const {
698
+ overflow,
699
+ overflowX,
700
+ overflowY,
701
+ display
702
+ } = getComputedStyle$1(element);
703
+ return /auto|scroll|overlay|hidden|clip/.test(overflow + overflowY + overflowX) && display !== 'inline' && display !== 'contents';
704
+ }
705
+ function isTableElement(element) {
706
+ return /^(table|td|th)$/.test(getNodeName(element));
707
+ }
708
+ function isTopLayer(element) {
709
+ try {
710
+ if (element.matches(':popover-open')) {
711
+ return true;
712
+ }
713
+ } catch (_e) {
714
+ // no-op
715
+ }
716
+ try {
717
+ return element.matches(':modal');
718
+ } catch (_e) {
719
+ return false;
720
+ }
721
+ }
722
+ const willChangeRe = /transform|translate|scale|rotate|perspective|filter/;
723
+ const containRe = /paint|layout|strict|content/;
724
+ const isNotNone = value => !!value && value !== 'none';
725
+ let isWebKitValue;
726
+ function isContainingBlock(elementOrCss) {
727
+ const css = isElement(elementOrCss) ? getComputedStyle$1(elementOrCss) : elementOrCss;
728
+
729
+ // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
730
+ // https://drafts.csswg.org/css-transforms-2/#individual-transforms
731
+ return isNotNone(css.transform) || isNotNone(css.translate) || isNotNone(css.scale) || isNotNone(css.rotate) || isNotNone(css.perspective) || !isWebKit() && (isNotNone(css.backdropFilter) || isNotNone(css.filter)) || willChangeRe.test(css.willChange || '') || containRe.test(css.contain || '');
732
+ }
733
+ function getContainingBlock(element) {
734
+ let currentNode = getParentNode(element);
735
+ while (isHTMLElement(currentNode) && !isLastTraversableNode(currentNode)) {
736
+ if (isContainingBlock(currentNode)) {
737
+ return currentNode;
738
+ } else if (isTopLayer(currentNode)) {
739
+ return null;
740
+ }
741
+ currentNode = getParentNode(currentNode);
742
+ }
743
+ return null;
744
+ }
745
+ function isWebKit() {
746
+ if (isWebKitValue == null) {
747
+ isWebKitValue = typeof CSS !== 'undefined' && CSS.supports && CSS.supports('-webkit-backdrop-filter', 'none');
748
+ }
749
+ return isWebKitValue;
750
+ }
751
+ function isLastTraversableNode(node) {
752
+ return /^(html|body|#document)$/.test(getNodeName(node));
753
+ }
754
+ function getComputedStyle$1(element) {
755
+ return getWindow(element).getComputedStyle(element);
756
+ }
757
+ function getNodeScroll(element) {
758
+ if (isElement(element)) {
759
+ return {
760
+ scrollLeft: element.scrollLeft,
761
+ scrollTop: element.scrollTop
762
+ };
763
+ }
764
+ return {
765
+ scrollLeft: element.scrollX,
766
+ scrollTop: element.scrollY
767
+ };
768
+ }
769
+ function getParentNode(node) {
770
+ if (getNodeName(node) === 'html') {
771
+ return node;
772
+ }
773
+ const result =
774
+ // Step into the shadow DOM of the parent of a slotted node.
775
+ node.assignedSlot ||
776
+ // DOM Element detected.
777
+ node.parentNode ||
778
+ // ShadowRoot detected.
779
+ isShadowRoot(node) && node.host ||
780
+ // Fallback.
781
+ getDocumentElement(node);
782
+ return isShadowRoot(result) ? result.host : result;
783
+ }
784
+ function getNearestOverflowAncestor(node) {
785
+ const parentNode = getParentNode(node);
786
+ if (isLastTraversableNode(parentNode)) {
787
+ return node.ownerDocument ? node.ownerDocument.body : node.body;
788
+ }
789
+ if (isHTMLElement(parentNode) && isOverflowElement(parentNode)) {
790
+ return parentNode;
791
+ }
792
+ return getNearestOverflowAncestor(parentNode);
793
+ }
794
+ function getOverflowAncestors(node, list, traverseIframes) {
795
+ var _node$ownerDocument2;
796
+ if (list === void 0) {
797
+ list = [];
798
+ }
799
+ if (traverseIframes === void 0) {
800
+ traverseIframes = true;
801
+ }
802
+ const scrollableAncestor = getNearestOverflowAncestor(node);
803
+ const isBody = scrollableAncestor === ((_node$ownerDocument2 = node.ownerDocument) == null ? void 0 : _node$ownerDocument2.body);
804
+ const win = getWindow(scrollableAncestor);
805
+ if (isBody) {
806
+ const frameElement = getFrameElement(win);
807
+ return list.concat(win, win.visualViewport || [], isOverflowElement(scrollableAncestor) ? scrollableAncestor : [], frameElement && traverseIframes ? getOverflowAncestors(frameElement) : []);
808
+ } else {
809
+ return list.concat(scrollableAncestor, getOverflowAncestors(scrollableAncestor, [], traverseIframes));
810
+ }
811
+ }
812
+ function getFrameElement(win) {
813
+ return win.parent && Object.getPrototypeOf(win.parent) ? win.frameElement : null;
814
+ }
815
+
816
+ function getCssDimensions(element) {
817
+ const css = getComputedStyle$1(element);
818
+ // In testing environments, the `width` and `height` properties are empty
819
+ // strings for SVG elements, returning NaN. Fallback to `0` in this case.
820
+ let width = parseFloat(css.width) || 0;
821
+ let height = parseFloat(css.height) || 0;
822
+ const hasOffset = isHTMLElement(element);
823
+ const offsetWidth = hasOffset ? element.offsetWidth : width;
824
+ const offsetHeight = hasOffset ? element.offsetHeight : height;
825
+ const shouldFallback = round(width) !== offsetWidth || round(height) !== offsetHeight;
826
+ if (shouldFallback) {
827
+ width = offsetWidth;
828
+ height = offsetHeight;
829
+ }
830
+ return {
831
+ width,
832
+ height,
833
+ $: shouldFallback
834
+ };
835
+ }
836
+
837
+ function unwrapElement(element) {
838
+ return !isElement(element) ? element.contextElement : element;
839
+ }
840
+
841
+ function getScale(element) {
842
+ const domElement = unwrapElement(element);
843
+ if (!isHTMLElement(domElement)) {
844
+ return createCoords(1);
845
+ }
846
+ const rect = domElement.getBoundingClientRect();
847
+ const {
848
+ width,
849
+ height,
850
+ $
851
+ } = getCssDimensions(domElement);
852
+ let x = ($ ? round(rect.width) : rect.width) / width;
853
+ let y = ($ ? round(rect.height) : rect.height) / height;
854
+
855
+ // 0, NaN, or Infinity should always fallback to 1.
856
+
857
+ if (!x || !Number.isFinite(x)) {
858
+ x = 1;
859
+ }
860
+ if (!y || !Number.isFinite(y)) {
861
+ y = 1;
862
+ }
863
+ return {
864
+ x,
865
+ y
866
+ };
867
+ }
868
+
869
+ const noOffsets = /*#__PURE__*/createCoords(0);
870
+ function getVisualOffsets(element) {
871
+ const win = getWindow(element);
872
+ if (!isWebKit() || !win.visualViewport) {
873
+ return noOffsets;
874
+ }
875
+ return {
876
+ x: win.visualViewport.offsetLeft,
877
+ y: win.visualViewport.offsetTop
878
+ };
879
+ }
880
+ function shouldAddVisualOffsets(element, isFixed, floatingOffsetParent) {
881
+ if (isFixed === void 0) {
882
+ isFixed = false;
883
+ }
884
+ if (!floatingOffsetParent || isFixed && floatingOffsetParent !== getWindow(element)) {
885
+ return false;
886
+ }
887
+ return isFixed;
888
+ }
889
+
890
+ function getBoundingClientRect(element, includeScale, isFixedStrategy, offsetParent) {
891
+ if (includeScale === void 0) {
892
+ includeScale = false;
893
+ }
894
+ if (isFixedStrategy === void 0) {
895
+ isFixedStrategy = false;
896
+ }
897
+ const clientRect = element.getBoundingClientRect();
898
+ const domElement = unwrapElement(element);
899
+ let scale = createCoords(1);
900
+ if (includeScale) {
901
+ if (offsetParent) {
902
+ if (isElement(offsetParent)) {
903
+ scale = getScale(offsetParent);
904
+ }
905
+ } else {
906
+ scale = getScale(element);
907
+ }
908
+ }
909
+ const visualOffsets = shouldAddVisualOffsets(domElement, isFixedStrategy, offsetParent) ? getVisualOffsets(domElement) : createCoords(0);
910
+ let x = (clientRect.left + visualOffsets.x) / scale.x;
911
+ let y = (clientRect.top + visualOffsets.y) / scale.y;
912
+ let width = clientRect.width / scale.x;
913
+ let height = clientRect.height / scale.y;
914
+ if (domElement) {
915
+ const win = getWindow(domElement);
916
+ const offsetWin = offsetParent && isElement(offsetParent) ? getWindow(offsetParent) : offsetParent;
917
+ let currentWin = win;
918
+ let currentIFrame = getFrameElement(currentWin);
919
+ while (currentIFrame && offsetParent && offsetWin !== currentWin) {
920
+ const iframeScale = getScale(currentIFrame);
921
+ const iframeRect = currentIFrame.getBoundingClientRect();
922
+ const css = getComputedStyle$1(currentIFrame);
923
+ const left = iframeRect.left + (currentIFrame.clientLeft + parseFloat(css.paddingLeft)) * iframeScale.x;
924
+ const top = iframeRect.top + (currentIFrame.clientTop + parseFloat(css.paddingTop)) * iframeScale.y;
925
+ x *= iframeScale.x;
926
+ y *= iframeScale.y;
927
+ width *= iframeScale.x;
928
+ height *= iframeScale.y;
929
+ x += left;
930
+ y += top;
931
+ currentWin = getWindow(currentIFrame);
932
+ currentIFrame = getFrameElement(currentWin);
933
+ }
934
+ }
935
+ return rectToClientRect({
936
+ width,
937
+ height,
938
+ x,
939
+ y
940
+ });
941
+ }
942
+
943
+ // If <html> has a CSS width greater than the viewport, then this will be
944
+ // incorrect for RTL.
945
+ function getWindowScrollBarX(element, rect) {
946
+ const leftScroll = getNodeScroll(element).scrollLeft;
947
+ if (!rect) {
948
+ return getBoundingClientRect(getDocumentElement(element)).left + leftScroll;
949
+ }
950
+ return rect.left + leftScroll;
951
+ }
952
+
953
+ function getHTMLOffset(documentElement, scroll) {
954
+ const htmlRect = documentElement.getBoundingClientRect();
955
+ const x = htmlRect.left + scroll.scrollLeft - getWindowScrollBarX(documentElement, htmlRect);
956
+ const y = htmlRect.top + scroll.scrollTop;
957
+ return {
958
+ x,
959
+ y
960
+ };
961
+ }
962
+
963
+ function convertOffsetParentRelativeRectToViewportRelativeRect(_ref) {
964
+ let {
965
+ elements,
966
+ rect,
967
+ offsetParent,
968
+ strategy
969
+ } = _ref;
970
+ const isFixed = strategy === 'fixed';
971
+ const documentElement = getDocumentElement(offsetParent);
972
+ const topLayer = elements ? isTopLayer(elements.floating) : false;
973
+ if (offsetParent === documentElement || topLayer && isFixed) {
974
+ return rect;
975
+ }
976
+ let scroll = {
977
+ scrollLeft: 0,
978
+ scrollTop: 0
979
+ };
980
+ let scale = createCoords(1);
981
+ const offsets = createCoords(0);
982
+ const isOffsetParentAnElement = isHTMLElement(offsetParent);
983
+ if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
984
+ if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
985
+ scroll = getNodeScroll(offsetParent);
986
+ }
987
+ if (isOffsetParentAnElement) {
988
+ const offsetRect = getBoundingClientRect(offsetParent);
989
+ scale = getScale(offsetParent);
990
+ offsets.x = offsetRect.x + offsetParent.clientLeft;
991
+ offsets.y = offsetRect.y + offsetParent.clientTop;
992
+ }
993
+ }
994
+ const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
995
+ return {
996
+ width: rect.width * scale.x,
997
+ height: rect.height * scale.y,
998
+ x: rect.x * scale.x - scroll.scrollLeft * scale.x + offsets.x + htmlOffset.x,
999
+ y: rect.y * scale.y - scroll.scrollTop * scale.y + offsets.y + htmlOffset.y
1000
+ };
1001
+ }
1002
+
1003
+ function getClientRects(element) {
1004
+ return Array.from(element.getClientRects());
1005
+ }
1006
+
1007
+ // Gets the entire size of the scrollable document area, even extending outside
1008
+ // of the `<html>` and `<body>` rect bounds if horizontally scrollable.
1009
+ function getDocumentRect(element) {
1010
+ const html = getDocumentElement(element);
1011
+ const scroll = getNodeScroll(element);
1012
+ const body = element.ownerDocument.body;
1013
+ const width = max(html.scrollWidth, html.clientWidth, body.scrollWidth, body.clientWidth);
1014
+ const height = max(html.scrollHeight, html.clientHeight, body.scrollHeight, body.clientHeight);
1015
+ let x = -scroll.scrollLeft + getWindowScrollBarX(element);
1016
+ const y = -scroll.scrollTop;
1017
+ if (getComputedStyle$1(body).direction === 'rtl') {
1018
+ x += max(html.clientWidth, body.clientWidth) - width;
1019
+ }
1020
+ return {
1021
+ width,
1022
+ height,
1023
+ x,
1024
+ y
1025
+ };
1026
+ }
1027
+
1028
+ // Safety check: ensure the scrollbar space is reasonable in case this
1029
+ // calculation is affected by unusual styles.
1030
+ // Most scrollbars leave 15-18px of space.
1031
+ const SCROLLBAR_MAX = 25;
1032
+ function getViewportRect(element, strategy) {
1033
+ const win = getWindow(element);
1034
+ const html = getDocumentElement(element);
1035
+ const visualViewport = win.visualViewport;
1036
+ let width = html.clientWidth;
1037
+ let height = html.clientHeight;
1038
+ let x = 0;
1039
+ let y = 0;
1040
+ if (visualViewport) {
1041
+ width = visualViewport.width;
1042
+ height = visualViewport.height;
1043
+ const visualViewportBased = isWebKit();
1044
+ if (!visualViewportBased || visualViewportBased && strategy === 'fixed') {
1045
+ x = visualViewport.offsetLeft;
1046
+ y = visualViewport.offsetTop;
1047
+ }
1048
+ }
1049
+ const windowScrollbarX = getWindowScrollBarX(html);
1050
+ // <html> `overflow: hidden` + `scrollbar-gutter: stable` reduces the
1051
+ // visual width of the <html> but this is not considered in the size
1052
+ // of `html.clientWidth`.
1053
+ if (windowScrollbarX <= 0) {
1054
+ const doc = html.ownerDocument;
1055
+ const body = doc.body;
1056
+ const bodyStyles = getComputedStyle(body);
1057
+ const bodyMarginInline = doc.compatMode === 'CSS1Compat' ? parseFloat(bodyStyles.marginLeft) + parseFloat(bodyStyles.marginRight) || 0 : 0;
1058
+ const clippingStableScrollbarWidth = Math.abs(html.clientWidth - body.clientWidth - bodyMarginInline);
1059
+ if (clippingStableScrollbarWidth <= SCROLLBAR_MAX) {
1060
+ width -= clippingStableScrollbarWidth;
1061
+ }
1062
+ } else if (windowScrollbarX <= SCROLLBAR_MAX) {
1063
+ // If the <body> scrollbar is on the left, the width needs to be extended
1064
+ // by the scrollbar amount so there isn't extra space on the right.
1065
+ width += windowScrollbarX;
1066
+ }
1067
+ return {
1068
+ width,
1069
+ height,
1070
+ x,
1071
+ y
1072
+ };
1073
+ }
1074
+
1075
+ // Returns the inner client rect, subtracting scrollbars if present.
1076
+ function getInnerBoundingClientRect(element, strategy) {
1077
+ const clientRect = getBoundingClientRect(element, true, strategy === 'fixed');
1078
+ const top = clientRect.top + element.clientTop;
1079
+ const left = clientRect.left + element.clientLeft;
1080
+ const scale = isHTMLElement(element) ? getScale(element) : createCoords(1);
1081
+ const width = element.clientWidth * scale.x;
1082
+ const height = element.clientHeight * scale.y;
1083
+ const x = left * scale.x;
1084
+ const y = top * scale.y;
1085
+ return {
1086
+ width,
1087
+ height,
1088
+ x,
1089
+ y
1090
+ };
1091
+ }
1092
+ function getClientRectFromClippingAncestor(element, clippingAncestor, strategy) {
1093
+ let rect;
1094
+ if (clippingAncestor === 'viewport') {
1095
+ rect = getViewportRect(element, strategy);
1096
+ } else if (clippingAncestor === 'document') {
1097
+ rect = getDocumentRect(getDocumentElement(element));
1098
+ } else if (isElement(clippingAncestor)) {
1099
+ rect = getInnerBoundingClientRect(clippingAncestor, strategy);
1100
+ } else {
1101
+ const visualOffsets = getVisualOffsets(element);
1102
+ rect = {
1103
+ x: clippingAncestor.x - visualOffsets.x,
1104
+ y: clippingAncestor.y - visualOffsets.y,
1105
+ width: clippingAncestor.width,
1106
+ height: clippingAncestor.height
1107
+ };
1108
+ }
1109
+ return rectToClientRect(rect);
1110
+ }
1111
+ function hasFixedPositionAncestor(element, stopNode) {
1112
+ const parentNode = getParentNode(element);
1113
+ if (parentNode === stopNode || !isElement(parentNode) || isLastTraversableNode(parentNode)) {
1114
+ return false;
1115
+ }
1116
+ return getComputedStyle$1(parentNode).position === 'fixed' || hasFixedPositionAncestor(parentNode, stopNode);
1117
+ }
1118
+
1119
+ // A "clipping ancestor" is an `overflow` element with the characteristic of
1120
+ // clipping (or hiding) child elements. This returns all clipping ancestors
1121
+ // of the given element up the tree.
1122
+ function getClippingElementAncestors(element, cache) {
1123
+ const cachedResult = cache.get(element);
1124
+ if (cachedResult) {
1125
+ return cachedResult;
1126
+ }
1127
+ let result = getOverflowAncestors(element, [], false).filter(el => isElement(el) && getNodeName(el) !== 'body');
1128
+ let currentContainingBlockComputedStyle = null;
1129
+ const elementIsFixed = getComputedStyle$1(element).position === 'fixed';
1130
+ let currentNode = elementIsFixed ? getParentNode(element) : element;
1131
+
1132
+ // https://developer.mozilla.org/en-US/docs/Web/CSS/Containing_block#identifying_the_containing_block
1133
+ while (isElement(currentNode) && !isLastTraversableNode(currentNode)) {
1134
+ const computedStyle = getComputedStyle$1(currentNode);
1135
+ const currentNodeIsContaining = isContainingBlock(currentNode);
1136
+ if (!currentNodeIsContaining && computedStyle.position === 'fixed') {
1137
+ currentContainingBlockComputedStyle = null;
1138
+ }
1139
+ const shouldDropCurrentNode = elementIsFixed ? !currentNodeIsContaining && !currentContainingBlockComputedStyle : !currentNodeIsContaining && computedStyle.position === 'static' && !!currentContainingBlockComputedStyle && (currentContainingBlockComputedStyle.position === 'absolute' || currentContainingBlockComputedStyle.position === 'fixed') || isOverflowElement(currentNode) && !currentNodeIsContaining && hasFixedPositionAncestor(element, currentNode);
1140
+ if (shouldDropCurrentNode) {
1141
+ // Drop non-containing blocks.
1142
+ result = result.filter(ancestor => ancestor !== currentNode);
1143
+ } else {
1144
+ // Record last containing block for next iteration.
1145
+ currentContainingBlockComputedStyle = computedStyle;
1146
+ }
1147
+ currentNode = getParentNode(currentNode);
1148
+ }
1149
+ cache.set(element, result);
1150
+ return result;
1151
+ }
1152
+
1153
+ // Gets the maximum area that the element is visible in due to any number of
1154
+ // clipping ancestors.
1155
+ function getClippingRect(_ref) {
1156
+ let {
1157
+ element,
1158
+ boundary,
1159
+ rootBoundary,
1160
+ strategy
1161
+ } = _ref;
1162
+ const elementClippingAncestors = boundary === 'clippingAncestors' ? isTopLayer(element) ? [] : getClippingElementAncestors(element, this._c) : [].concat(boundary);
1163
+ const clippingAncestors = [...elementClippingAncestors, rootBoundary];
1164
+ const firstRect = getClientRectFromClippingAncestor(element, clippingAncestors[0], strategy);
1165
+ let top = firstRect.top;
1166
+ let right = firstRect.right;
1167
+ let bottom = firstRect.bottom;
1168
+ let left = firstRect.left;
1169
+ for (let i = 1; i < clippingAncestors.length; i++) {
1170
+ const rect = getClientRectFromClippingAncestor(element, clippingAncestors[i], strategy);
1171
+ top = max(rect.top, top);
1172
+ right = min(rect.right, right);
1173
+ bottom = min(rect.bottom, bottom);
1174
+ left = max(rect.left, left);
1175
+ }
1176
+ return {
1177
+ width: right - left,
1178
+ height: bottom - top,
1179
+ x: left,
1180
+ y: top
1181
+ };
1182
+ }
1183
+
1184
+ function getDimensions(element) {
1185
+ const {
1186
+ width,
1187
+ height
1188
+ } = getCssDimensions(element);
1189
+ return {
1190
+ width,
1191
+ height
1192
+ };
1193
+ }
1194
+
1195
+ function getRectRelativeToOffsetParent(element, offsetParent, strategy) {
1196
+ const isOffsetParentAnElement = isHTMLElement(offsetParent);
1197
+ const documentElement = getDocumentElement(offsetParent);
1198
+ const isFixed = strategy === 'fixed';
1199
+ const rect = getBoundingClientRect(element, true, isFixed, offsetParent);
1200
+ let scroll = {
1201
+ scrollLeft: 0,
1202
+ scrollTop: 0
1203
+ };
1204
+ const offsets = createCoords(0);
1205
+
1206
+ // If the <body> scrollbar appears on the left (e.g. RTL systems). Use
1207
+ // Firefox with layout.scrollbar.side = 3 in about:config to test this.
1208
+ function setLeftRTLScrollbarOffset() {
1209
+ offsets.x = getWindowScrollBarX(documentElement);
1210
+ }
1211
+ if (isOffsetParentAnElement || !isOffsetParentAnElement && !isFixed) {
1212
+ if (getNodeName(offsetParent) !== 'body' || isOverflowElement(documentElement)) {
1213
+ scroll = getNodeScroll(offsetParent);
1214
+ }
1215
+ if (isOffsetParentAnElement) {
1216
+ const offsetRect = getBoundingClientRect(offsetParent, true, isFixed, offsetParent);
1217
+ offsets.x = offsetRect.x + offsetParent.clientLeft;
1218
+ offsets.y = offsetRect.y + offsetParent.clientTop;
1219
+ } else if (documentElement) {
1220
+ setLeftRTLScrollbarOffset();
1221
+ }
1222
+ }
1223
+ if (isFixed && !isOffsetParentAnElement && documentElement) {
1224
+ setLeftRTLScrollbarOffset();
1225
+ }
1226
+ const htmlOffset = documentElement && !isOffsetParentAnElement && !isFixed ? getHTMLOffset(documentElement, scroll) : createCoords(0);
1227
+ const x = rect.left + scroll.scrollLeft - offsets.x - htmlOffset.x;
1228
+ const y = rect.top + scroll.scrollTop - offsets.y - htmlOffset.y;
1229
+ return {
1230
+ x,
1231
+ y,
1232
+ width: rect.width,
1233
+ height: rect.height
1234
+ };
1235
+ }
1236
+
1237
+ function isStaticPositioned(element) {
1238
+ return getComputedStyle$1(element).position === 'static';
1239
+ }
1240
+
1241
+ function getTrueOffsetParent(element, polyfill) {
1242
+ if (!isHTMLElement(element) || getComputedStyle$1(element).position === 'fixed') {
1243
+ return null;
1244
+ }
1245
+ if (polyfill) {
1246
+ return polyfill(element);
1247
+ }
1248
+ let rawOffsetParent = element.offsetParent;
1249
+
1250
+ // Firefox returns the <html> element as the offsetParent if it's non-static,
1251
+ // while Chrome and Safari return the <body> element. The <body> element must
1252
+ // be used to perform the correct calculations even if the <html> element is
1253
+ // non-static.
1254
+ if (getDocumentElement(element) === rawOffsetParent) {
1255
+ rawOffsetParent = rawOffsetParent.ownerDocument.body;
1256
+ }
1257
+ return rawOffsetParent;
1258
+ }
1259
+
1260
+ // Gets the closest ancestor positioned element. Handles some edge cases,
1261
+ // such as table ancestors and cross browser bugs.
1262
+ function getOffsetParent(element, polyfill) {
1263
+ const win = getWindow(element);
1264
+ if (isTopLayer(element)) {
1265
+ return win;
1266
+ }
1267
+ if (!isHTMLElement(element)) {
1268
+ let svgOffsetParent = getParentNode(element);
1269
+ while (svgOffsetParent && !isLastTraversableNode(svgOffsetParent)) {
1270
+ if (isElement(svgOffsetParent) && !isStaticPositioned(svgOffsetParent)) {
1271
+ return svgOffsetParent;
1272
+ }
1273
+ svgOffsetParent = getParentNode(svgOffsetParent);
1274
+ }
1275
+ return win;
1276
+ }
1277
+ let offsetParent = getTrueOffsetParent(element, polyfill);
1278
+ while (offsetParent && isTableElement(offsetParent) && isStaticPositioned(offsetParent)) {
1279
+ offsetParent = getTrueOffsetParent(offsetParent, polyfill);
1280
+ }
1281
+ if (offsetParent && isLastTraversableNode(offsetParent) && isStaticPositioned(offsetParent) && !isContainingBlock(offsetParent)) {
1282
+ return win;
1283
+ }
1284
+ return offsetParent || getContainingBlock(element) || win;
1285
+ }
1286
+
1287
+ const getElementRects = async function (data) {
1288
+ const getOffsetParentFn = this.getOffsetParent || getOffsetParent;
1289
+ const getDimensionsFn = this.getDimensions;
1290
+ const floatingDimensions = await getDimensionsFn(data.floating);
1291
+ return {
1292
+ reference: getRectRelativeToOffsetParent(data.reference, await getOffsetParentFn(data.floating), data.strategy),
1293
+ floating: {
1294
+ x: 0,
1295
+ y: 0,
1296
+ width: floatingDimensions.width,
1297
+ height: floatingDimensions.height
1298
+ }
1299
+ };
1300
+ };
1301
+
1302
+ function isRTL(element) {
1303
+ return getComputedStyle$1(element).direction === 'rtl';
1304
+ }
1305
+
1306
+ const platform = {
1307
+ convertOffsetParentRelativeRectToViewportRelativeRect,
1308
+ getDocumentElement,
1309
+ getClippingRect,
1310
+ getOffsetParent,
1311
+ getElementRects,
1312
+ getClientRects,
1313
+ getDimensions,
1314
+ getScale,
1315
+ isElement,
1316
+ isRTL
1317
+ };
1318
+
1319
+ function rectsAreEqual(a, b) {
1320
+ return a.x === b.x && a.y === b.y && a.width === b.width && a.height === b.height;
1321
+ }
1322
+
1323
+ // https://samthor.au/2021/observing-dom/
1324
+ function observeMove(element, onMove) {
1325
+ let io = null;
1326
+ let timeoutId;
1327
+ const root = getDocumentElement(element);
1328
+ function cleanup() {
1329
+ var _io;
1330
+ clearTimeout(timeoutId);
1331
+ (_io = io) == null || _io.disconnect();
1332
+ io = null;
1333
+ }
1334
+ function refresh(skip, threshold) {
1335
+ if (skip === void 0) {
1336
+ skip = false;
1337
+ }
1338
+ if (threshold === void 0) {
1339
+ threshold = 1;
1340
+ }
1341
+ cleanup();
1342
+ const elementRectForRootMargin = element.getBoundingClientRect();
1343
+ const {
1344
+ left,
1345
+ top,
1346
+ width,
1347
+ height
1348
+ } = elementRectForRootMargin;
1349
+ if (!skip) {
1350
+ onMove();
1351
+ }
1352
+ if (!width || !height) {
1353
+ return;
1354
+ }
1355
+ const insetTop = floor(top);
1356
+ const insetRight = floor(root.clientWidth - (left + width));
1357
+ const insetBottom = floor(root.clientHeight - (top + height));
1358
+ const insetLeft = floor(left);
1359
+ const rootMargin = -insetTop + "px " + -insetRight + "px " + -insetBottom + "px " + -insetLeft + "px";
1360
+ const options = {
1361
+ rootMargin,
1362
+ threshold: max(0, min(1, threshold)) || 1
1363
+ };
1364
+ let isFirstUpdate = true;
1365
+ function handleObserve(entries) {
1366
+ const ratio = entries[0].intersectionRatio;
1367
+ if (ratio !== threshold) {
1368
+ if (!isFirstUpdate) {
1369
+ return refresh();
1370
+ }
1371
+ if (!ratio) {
1372
+ // If the reference is clipped, the ratio is 0. Throttle the refresh
1373
+ // to prevent an infinite loop of updates.
1374
+ timeoutId = setTimeout(() => {
1375
+ refresh(false, 1e-7);
1376
+ }, 1000);
1377
+ } else {
1378
+ refresh(false, ratio);
1379
+ }
1380
+ }
1381
+ if (ratio === 1 && !rectsAreEqual(elementRectForRootMargin, element.getBoundingClientRect())) {
1382
+ // It's possible that even though the ratio is reported as 1, the
1383
+ // element is not actually fully within the IntersectionObserver's root
1384
+ // area anymore. This can happen under performance constraints. This may
1385
+ // be a bug in the browser's IntersectionObserver implementation. To
1386
+ // work around this, we compare the element's bounding rect now with
1387
+ // what it was at the time we created the IntersectionObserver. If they
1388
+ // are not equal then the element moved, so we refresh.
1389
+ refresh();
1390
+ }
1391
+ isFirstUpdate = false;
1392
+ }
1393
+
1394
+ // Older browsers don't support a `document` as the root and will throw an
1395
+ // error.
1396
+ try {
1397
+ io = new IntersectionObserver(handleObserve, {
1398
+ ...options,
1399
+ // Handle <iframe>s
1400
+ root: root.ownerDocument
1401
+ });
1402
+ } catch (_e) {
1403
+ io = new IntersectionObserver(handleObserve, options);
1404
+ }
1405
+ io.observe(element);
1406
+ }
1407
+ refresh(true);
1408
+ return cleanup;
1409
+ }
1410
+
1411
+ /**
1412
+ * Automatically updates the position of the floating element when necessary.
1413
+ * Should only be called when the floating element is mounted on the DOM or
1414
+ * visible on the screen.
1415
+ * @returns cleanup function that should be invoked when the floating element is
1416
+ * removed from the DOM or hidden from the screen.
1417
+ * @see https://floating-ui.com/docs/autoUpdate
1418
+ */
1419
+ function autoUpdate(reference, floating, update, options) {
1420
+ if (options === void 0) {
1421
+ options = {};
1422
+ }
1423
+ const {
1424
+ ancestorScroll = true,
1425
+ ancestorResize = true,
1426
+ elementResize = typeof ResizeObserver === 'function',
1427
+ layoutShift = typeof IntersectionObserver === 'function',
1428
+ animationFrame = false
1429
+ } = options;
1430
+ const referenceEl = unwrapElement(reference);
1431
+ const ancestors = ancestorScroll || ancestorResize ? [...(referenceEl ? getOverflowAncestors(referenceEl) : []), ...(floating ? getOverflowAncestors(floating) : [])] : [];
1432
+ ancestors.forEach(ancestor => {
1433
+ ancestorScroll && ancestor.addEventListener('scroll', update, {
1434
+ passive: true
1435
+ });
1436
+ ancestorResize && ancestor.addEventListener('resize', update);
1437
+ });
1438
+ const cleanupIo = referenceEl && layoutShift ? observeMove(referenceEl, update) : null;
1439
+ let reobserveFrame = -1;
1440
+ let resizeObserver = null;
1441
+ if (elementResize) {
1442
+ resizeObserver = new ResizeObserver(_ref => {
1443
+ let [firstEntry] = _ref;
1444
+ if (firstEntry && firstEntry.target === referenceEl && resizeObserver && floating) {
1445
+ // Prevent update loops when using the `size` middleware.
1446
+ // https://github.com/floating-ui/floating-ui/issues/1740
1447
+ resizeObserver.unobserve(floating);
1448
+ cancelAnimationFrame(reobserveFrame);
1449
+ reobserveFrame = requestAnimationFrame(() => {
1450
+ var _resizeObserver;
1451
+ (_resizeObserver = resizeObserver) == null || _resizeObserver.observe(floating);
1452
+ });
1453
+ }
1454
+ update();
1455
+ });
1456
+ if (referenceEl && !animationFrame) {
1457
+ resizeObserver.observe(referenceEl);
1458
+ }
1459
+ if (floating) {
1460
+ resizeObserver.observe(floating);
1461
+ }
1462
+ }
1463
+ let frameId;
1464
+ let prevRefRect = animationFrame ? getBoundingClientRect(reference) : null;
1465
+ if (animationFrame) {
1466
+ frameLoop();
1467
+ }
1468
+ function frameLoop() {
1469
+ const nextRefRect = getBoundingClientRect(reference);
1470
+ if (prevRefRect && !rectsAreEqual(prevRefRect, nextRefRect)) {
1471
+ update();
1472
+ }
1473
+ prevRefRect = nextRefRect;
1474
+ frameId = requestAnimationFrame(frameLoop);
1475
+ }
1476
+ update();
1477
+ return () => {
1478
+ var _resizeObserver2;
1479
+ ancestors.forEach(ancestor => {
1480
+ ancestorScroll && ancestor.removeEventListener('scroll', update);
1481
+ ancestorResize && ancestor.removeEventListener('resize', update);
1482
+ });
1483
+ cleanupIo == null || cleanupIo();
1484
+ (_resizeObserver2 = resizeObserver) == null || _resizeObserver2.disconnect();
1485
+ resizeObserver = null;
1486
+ if (animationFrame) {
1487
+ cancelAnimationFrame(frameId);
1488
+ }
1489
+ };
1490
+ }
1491
+
1492
+ /**
1493
+ * Resolves with an object of overflow side offsets that determine how much the
1494
+ * element is overflowing a given clipping boundary on each side.
1495
+ * - positive = overflowing the boundary by that number of pixels
1496
+ * - negative = how many pixels left before it will overflow
1497
+ * - 0 = lies flush with the boundary
1498
+ * @see https://floating-ui.com/docs/detectOverflow
1499
+ */
1500
+ const detectOverflow = detectOverflow$1;
1501
+
1502
+ /**
1503
+ * Modifies the placement by translating the floating element along the
1504
+ * specified axes.
1505
+ * A number (shorthand for `mainAxis` or distance), or an axes configuration
1506
+ * object may be passed.
1507
+ * @see https://floating-ui.com/docs/offset
1508
+ */
1509
+ const offset = offset$1;
1510
+
1511
+ /**
1512
+ * Optimizes the visibility of the floating element by shifting it in order to
1513
+ * keep it in view when it will overflow the clipping boundary.
1514
+ * @see https://floating-ui.com/docs/shift
1515
+ */
1516
+ const shift = shift$1;
1517
+
1518
+ /**
1519
+ * Optimizes the visibility of the floating element by flipping the `placement`
1520
+ * in order to keep it in view when the preferred placement(s) will overflow the
1521
+ * clipping boundary. Alternative to `autoPlacement`.
1522
+ * @see https://floating-ui.com/docs/flip
1523
+ */
1524
+ const flip = flip$1;
1525
+
1526
+ /**
1527
+ * Computes the `x` and `y` coordinates that will place the floating element
1528
+ * next to a given reference element.
1529
+ */
1530
+ const computePosition = (reference, floating, options) => {
1531
+ // This caches the expensive `getClippingElementAncestors` function so that
1532
+ // multiple lifecycle resets re-use the same result. It only lives for a
1533
+ // single call. If other functions become expensive, we can add them as well.
1534
+ const cache = new Map();
1535
+ const mergedOptions = {
1536
+ platform,
1537
+ ...options
1538
+ };
1539
+ const platformWithCache = {
1540
+ ...mergedOptions.platform,
1541
+ _c: cache
1542
+ };
1543
+ return computePosition$1(reference, floating, {
1544
+ ...mergedOptions,
1545
+ platform: platformWithCache
1546
+ });
1547
+ };
1548
+
1549
+ function getDefaultMiddleware(offsetOptions, overflowOptions, flipOptions) {
1550
+ const isMiddleware = (v) => typeof v !== 'boolean';
1551
+ return [
1552
+ offsetOptions != null ? offset(offsetOptions) : offset(4),
1553
+ overflowOptions == null && flip(flipOptions),
1554
+ shift(),
1555
+ overflowOptions != null && preventOverflow(overflowOptions),
1556
+ ].filter(isMiddleware);
1557
+ }
1558
+ function preventOverflow(overflowOptions) {
1559
+ return {
1560
+ name: 'boundaryContain',
1561
+ fn: async (state) => {
1562
+ const overflow = await detectOverflow(state, overflowOptions);
1563
+ const leftOverflow = overflow.left > 0 ? overflow.left : 0;
1564
+ const rightOverflow = overflow.right > 0 ? overflow.right : 0;
1565
+ const topOverflow = overflow.top > 0 ? overflow.top : 0;
1566
+ const bottomOverflow = overflow.bottom > 0 ? overflow.bottom : 0;
1567
+ return {
1568
+ x: state.x + leftOverflow - rightOverflow,
1569
+ y: state.y + topOverflow - bottomOverflow,
1570
+ };
1571
+ },
1572
+ };
1573
+ }
1574
+
1575
+ async function computeUpdatedPosition(referenceElement, contentElement, placement, middleware) {
1576
+ const position = await computePosition(referenceElement, contentElement, {
1577
+ placement,
1578
+ middleware,
1579
+ strategy: 'fixed',
1580
+ });
1581
+ return position;
1582
+ }
1583
+
1584
+ const popoverCss = () => `:host{--open-animation-name:open-scale-all;--open-animation:var(--open-animation-name) 0.1s ease-out 1;--close-animation-name:close-scale-all;--close-animation:var(--close-animation-name) 0.2s ease-in-out 1;--transform-origin:var(--none)}.open-animated{animation:var(--open-animation)}.hidden-animated{animation:var(--close-animation)}.hidden>.content{opacity:0;width:0;height:0;visibility:hidden}.hidden{pointer-events:none}.open{z-index:var(--vertex-ui-context-menu-layer)}.anchor{position:fixed}.backdrop{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:var(--backdrop-color, white);opacity:var(--backdrop-opacity, 0);z-index:var(--vertex-ui-context-menu-layer)}.popper{position:fixed}.center-bottom{transform-origin:var(--transform-origin, center bottom)}.left-bottom{transform-origin:var(--transform-origin, left bottom)}.right-bottom{transform-origin:var(--transform-origin, right bottom)}.center-top{transform-origin:var(--transform-origin, center top)}.left-top{transform-origin:var(--transform-origin, left top)}.right-top{transform-origin:var(--transform-origin, right top)}.left-center{transform-origin:var(--transform-origin, left center)}.left-top{transform-origin:var(--transform-origin, left top)}.left-bottom{transform-origin:var(--transform-origin, left bottom)}.right-center{transform-origin:var(--transform-origin, right center)}.right-top{transform-origin:var(--transform-origin, right top)}.right-bottom{transform-origin:var(--transform-origin, right bottom)}@keyframes open-fade-in{from{opacity:0}to{opacity:1}}@keyframes close-fade-out{from{visibility:visible;height:auto;width:auto;opacity:1}to{opacity:0;height:auto;width:auto}}@keyframes open-scale-all{from{opacity:0;transform:scale(0)}to{opacity:1;transform:scale(1)}}@keyframes close-scale-all{from{visibility:visible;height:auto;width:auto;opacity:1;transform:scale(1)}to{opacity:0;height:auto;width:auto;transform:scale(0)}}@keyframes open-scale-y{from{opacity:0;transform:scaleY(0)}to{opacity:1;transform:scaleY(1)}}@keyframes close-scale-y{from{visibility:visible;height:auto;width:auto;opacity:1;transform:scaleY(1)}to{opacity:0;height:auto;width:auto;transform:scaleY(0)}}@keyframes open-scale-x{from{opacity:0;transform:scaleX(0)}to{opacity:1;transform:scaleX(1)}}@keyframes close-scale-x{from{visibility:visible;height:auto;width:auto;opacity:1;transform:scaleX(1)}to{opacity:0;height:auto;width:auto;transform:scaleX(0)}}`;
1585
+
1586
+ const WINDOW_RESIZE_DEBOUNCE_THRESHOLD = 200;
1587
+ const Popover = class {
1588
+ constructor(hostRef) {
1589
+ registerInstance(this, hostRef);
1590
+ this.dismissed = createEvent(this, "dismissed");
1591
+ /**
1592
+ * Whether this popover's content is visible.
1593
+ */
1594
+ this.open = false;
1595
+ /**
1596
+ * The placement of the popover at the clicked point.
1597
+ * This can be any of the following values:
1598
+ *
1599
+ * 'top', 'top-start', 'top-end',
1600
+ * 'bottom', 'bottom-start', 'bottom-end',
1601
+ * 'right', 'right-start', 'right-end',
1602
+ * 'left', 'left-start', 'left-end', and
1603
+ * defaults to 'bottom-start'.
1604
+ *
1605
+ * Note: placement will adjust based on the amount
1606
+ * of available space, so popovers close to screen
1607
+ * edges may appear in a different location.
1608
+ */
1609
+ this.placement = 'bottom-start';
1610
+ /**
1611
+ * Whether to show a backdrop that dismisses this popover.
1612
+ * Defaults to true, and is invisible, but can be styled.
1613
+ */
1614
+ this.backdrop = true;
1615
+ /**
1616
+ * Whether this popover should animate its contents it is opened.
1617
+ * Defaults to false, and the animation can be overridden using
1618
+ * the `var(--open-animation)` and `var(--close-animation)` CSS
1619
+ * variables. The `transform-origin` will update relative to the
1620
+ * `position` property provided.
1621
+ */
1622
+ this.animated = false;
1623
+ /**
1624
+ * The behavior that this popover will have when the window
1625
+ * is resized. Can be either 'dynamic' or 'fixed', and defaults
1626
+ * to 'dynamic'.
1627
+ *
1628
+ * 'dynamic' will cause a position-based popover to adjust its
1629
+ * position relative to the window resize to keep it in the same
1630
+ * relative position.
1631
+ * 'fixed' will keep the popover in the same position even if
1632
+ * that means it would disappear off-screen.
1633
+ */
1634
+ this.resizeBehavior = 'dynamic';
1635
+ /**
1636
+ * Indicates if the position of the popover should be updated when the
1637
+ * popover's content size changes.
1638
+ */
1639
+ this.updateOnResize = false;
1640
+ this.opened = false;
1641
+ this.computedPlacement = this.placement;
1642
+ this.shouldUpdatePosition = false;
1643
+ this.middleware = [];
1644
+ this.partialWindow = window;
1645
+ /**
1646
+ * @internal
1647
+ */
1648
+ this.resizeObserverFactory = (cb) => new ResizeObserver(cb);
1649
+ this.updateListener = this.updateListener.bind(this);
1650
+ this.handlePositionUpdate = this.handlePositionUpdate.bind(this);
1651
+ this.handleResize = this.handleResize.bind(this);
1652
+ this.handleMiddlewareChange = this.handleMiddlewareChange.bind(this);
1653
+ this.setWindow = this.setWindow.bind(this);
1654
+ this.updateResizeObserver = this.updateResizeObserver.bind(this);
1655
+ }
1656
+ connectedCallback() {
1657
+ this.updatePosition(this.position);
1658
+ this.updateResizeObserver();
1659
+ }
1660
+ componentDidUpdate() {
1661
+ if (this.shouldUpdatePosition) {
1662
+ this.shouldUpdatePosition = false;
1663
+ if (this.updateDispose != null) {
1664
+ this.handlePositionUpdate();
1665
+ }
1666
+ else {
1667
+ this.updateListener();
1668
+ }
1669
+ }
1670
+ }
1671
+ componentDidLoad() {
1672
+ this.updateViewport();
1673
+ this.handleMiddlewareChange();
1674
+ this.updateListener();
1675
+ if (this.resizeBehavior === 'dynamic') {
1676
+ window.addEventListener('resize', this.handleResize);
1677
+ }
1678
+ }
1679
+ disconnectedCallback() {
1680
+ var _a;
1681
+ this.viewportWidth = undefined;
1682
+ this.viewportHeight = undefined;
1683
+ this.opened = false;
1684
+ if (this.resizeBehavior === 'dynamic') {
1685
+ window.removeEventListener('resize', this.handleResize);
1686
+ }
1687
+ (_a = this.boundaryResizeObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
1688
+ }
1689
+ updatePosition(position) {
1690
+ if (position != null) {
1691
+ this.anchorPosition =
1692
+ typeof position === 'object' ? position : JSON.parse(position);
1693
+ this.shouldUpdatePosition = true;
1694
+ }
1695
+ }
1696
+ updatePlacement() {
1697
+ this.updatePosition(this.position);
1698
+ }
1699
+ updateOpened(open) {
1700
+ if (open) {
1701
+ this.opened = true;
1702
+ }
1703
+ this.updateListener();
1704
+ }
1705
+ updateAnimated() {
1706
+ this.opened = this.open;
1707
+ }
1708
+ updateMiddleware() {
1709
+ this.handleMiddlewareChange();
1710
+ }
1711
+ updateResizeObserver() {
1712
+ const observer = this.getOrCreateResizeObserver();
1713
+ observer.disconnect();
1714
+ if (this.boundarySelector != null) {
1715
+ const element = document.querySelector(this.boundarySelector);
1716
+ if (element != null) {
1717
+ observer.observe(element);
1718
+ }
1719
+ }
1720
+ }
1721
+ /**
1722
+ * @private Used for internals or testing.
1723
+ */
1724
+ setWindow(partialWindow) {
1725
+ this.partialWindow = partialWindow;
1726
+ }
1727
+ render() {
1728
+ var _a, _b;
1729
+ return (h(Host, { key: 'dac6fddc73d5a5e84b46a0f3f98bdcb027535859' }, this.open && this.backdrop && (h("div", { key: '63ae8150fb738a142d206af25add705b27bb825c', class: "backdrop", onPointerDown: () => {
1730
+ this.open = false;
1731
+ this.dismissed.emit();
1732
+ } })), this.anchorPosition && (h("div", { key: '148cea536e94dbdcd14cc495406b23cc63835aba', ref: (element) => (this.anchorPointRef = element), class: "anchor", style: {
1733
+ left: `${((_a = this.anchorPosition) === null || _a === void 0 ? void 0 : _a.x) || 0}px`,
1734
+ top: `${((_b = this.anchorPosition) === null || _b === void 0 ? void 0 : _b.y) || 0}px`,
1735
+ } })), h("slot", { key: '350776528927625987a29301f0723cb5d5171b3e', name: "anchor" }), h("div", { key: '25141e224afc06546816136873c49cae7d0e7aaa', ref: (element) => (this.wrapperRef = element), class: classNames('popper', {
1736
+ hidden: !this.open,
1737
+ open: this.open,
1738
+ }) }, h("div", { key: '5ea57501baa48d579941d274c2d139207289c45a', class: classNames('content', {
1739
+ 'hidden-animated': !this.open && this.opened && this.animated,
1740
+ 'open-animated': this.open && this.animated,
1741
+ }, this.getTransformClass()), onAnimationEnd: () => {
1742
+ this.opened = this.open;
1743
+ } }, h("slot", { key: 'a2cec0930f7c5c4a505a4bcc1432e9dec095c587' })))));
1744
+ }
1745
+ updateListener() {
1746
+ var _a, _b, _c, _d;
1747
+ const referenceElement = (_b = (_a = this.getSlottedAnchorElement()) !== null && _a !== void 0 ? _a : this.anchorPointRef) !== null && _b !== void 0 ? _b : this.getAnchorBoundsVirtualElement();
1748
+ if (this.open && referenceElement != null && this.wrapperRef != null) {
1749
+ (_c = this.updateDispose) === null || _c === void 0 ? void 0 : _c.call(this);
1750
+ this.updateDispose = autoUpdate(referenceElement, this.wrapperRef, this.handlePositionUpdate);
1751
+ this.handlePositionUpdate();
1752
+ }
1753
+ else {
1754
+ (_d = this.updateDispose) === null || _d === void 0 ? void 0 : _d.call(this);
1755
+ }
1756
+ }
1757
+ async handlePositionUpdate() {
1758
+ var _a, _b, _c;
1759
+ const referenceElement = (_b = (_a = this.getSlottedAnchorElement()) !== null && _a !== void 0 ? _a : this.anchorPointRef) !== null && _b !== void 0 ? _b : this.getAnchorBoundsVirtualElement();
1760
+ if (referenceElement != null && this.wrapperRef != null) {
1761
+ const position = await computeUpdatedPosition(referenceElement, this.wrapperRef, this.placement, this.middleware);
1762
+ this.computedPlacement = position.placement;
1763
+ (_c = this.wrapperRef) === null || _c === void 0 ? void 0 : _c.setAttribute('style', `left: ${position.x}px; top: ${position.y}px;`);
1764
+ }
1765
+ }
1766
+ handleMiddlewareChange() {
1767
+ var _a, _b, _c;
1768
+ const anchorSlotElement = (_a = this.getSlottedAnchorElement()) !== null && _a !== void 0 ? _a : this.getAnchorBoundsVirtualElement();
1769
+ const offset = anchorSlotElement != null ? 4 : 0;
1770
+ const boundary = this.boundarySelector != null
1771
+ ? ((_b = document.querySelector(this.boundarySelector)) !== null && _b !== void 0 ? _b : undefined)
1772
+ : undefined;
1773
+ this.middleware = getDefaultMiddleware((_c = this.offsetBehavior) !== null && _c !== void 0 ? _c : offset, boundary != null
1774
+ ? {
1775
+ boundary,
1776
+ ...this.overflowBehavior,
1777
+ }
1778
+ : this.overflowBehavior, this.flipBehavior);
1779
+ this.updateListener();
1780
+ }
1781
+ getSlottedAnchorElement() {
1782
+ var _a, _b, _c;
1783
+ if (this.anchorSelector != null) {
1784
+ return (((_a = this.hostElement.shadowRoot) === null || _a === void 0 ? void 0 : _a.querySelector(this.anchorSelector)) ||
1785
+ this.hostElement.querySelector(this.anchorSelector) ||
1786
+ undefined);
1787
+ }
1788
+ else {
1789
+ const anchorSlot = ((_b = this.hostElement.shadowRoot) === null || _b === void 0 ? void 0 : _b.querySelector('slot[name="anchor"]')) ||
1790
+ undefined;
1791
+ if (((_c = anchorSlot === null || anchorSlot === void 0 ? void 0 : anchorSlot.assignedElements) === null || _c === void 0 ? void 0 : _c.call(anchorSlot).length) || 0 > 0) {
1792
+ return anchorSlot === null || anchorSlot === void 0 ? void 0 : anchorSlot.assignedElements()[0];
1793
+ }
1794
+ }
1795
+ }
1796
+ getAnchorBoundsVirtualElement() {
1797
+ if (this.anchorBounds != null) {
1798
+ return {
1799
+ getBoundingClientRect: () => {
1800
+ return DOMRect.fromRect(this.anchorBounds);
1801
+ },
1802
+ };
1803
+ }
1804
+ }
1805
+ handleResize() {
1806
+ if (this.resizeTimeout != null) {
1807
+ clearTimeout(this.resizeTimeout);
1808
+ }
1809
+ if (this.open) {
1810
+ this.resizeTimeout = setTimeout(() => {
1811
+ this.resizeTimeout = undefined;
1812
+ if (this.anchorPosition != null &&
1813
+ this.viewportWidth != null &&
1814
+ this.viewportHeight != null) {
1815
+ const relativeWidth = this.anchorPosition.x / this.viewportWidth;
1816
+ const relativeHeight = this.anchorPosition.y / this.viewportHeight;
1817
+ this.position = {
1818
+ x: this.partialWindow.innerWidth * relativeWidth,
1819
+ y: this.partialWindow.innerHeight * relativeHeight,
1820
+ };
1821
+ }
1822
+ this.updateViewport();
1823
+ }, WINDOW_RESIZE_DEBOUNCE_THRESHOLD);
1824
+ }
1825
+ }
1826
+ updateViewport() {
1827
+ this.viewportWidth = this.partialWindow.innerWidth;
1828
+ this.viewportHeight = this.partialWindow.innerHeight;
1829
+ }
1830
+ getOrCreateResizeObserver() {
1831
+ if (this.boundaryResizeObserver == null) {
1832
+ this.boundaryResizeObserver = this.resizeObserverFactory(this.handleMiddlewareChange);
1833
+ }
1834
+ return this.boundaryResizeObserver;
1835
+ }
1836
+ getTransformClass() {
1837
+ if (this.animated) {
1838
+ switch (this.computedPlacement) {
1839
+ case 'top':
1840
+ return 'center-bottom';
1841
+ case 'top-start':
1842
+ return 'left-bottom';
1843
+ case 'top-end':
1844
+ return 'right-bottom';
1845
+ case 'bottom':
1846
+ return 'center-top';
1847
+ case 'bottom-start':
1848
+ return 'left-top';
1849
+ case 'bottom-end':
1850
+ return 'right-top';
1851
+ case 'right':
1852
+ return 'left-center';
1853
+ case 'right-start':
1854
+ return 'left-top';
1855
+ case 'right-end':
1856
+ return 'left-bottom';
1857
+ case 'left':
1858
+ return 'right-center';
1859
+ case 'left-start':
1860
+ return 'right-top';
1861
+ case 'left-end':
1862
+ return 'right-bottom';
1863
+ }
1864
+ }
1865
+ }
1866
+ get hostElement() { return getElement(this); }
1867
+ static get watchers() { return {
1868
+ "position": [{
1869
+ "updatePosition": 0
1870
+ }],
1871
+ "placement": [{
1872
+ "updatePlacement": 0
1873
+ }],
1874
+ "open": [{
1875
+ "updateOpened": 0
1876
+ }],
1877
+ "animated": [{
1878
+ "updateAnimated": 0
1879
+ }],
1880
+ "boundarySelector": [{
1881
+ "updateMiddleware": 0
1882
+ }, {
1883
+ "updateResizeObserver": 0
1884
+ }],
1885
+ "overflowBehavior": [{
1886
+ "updateMiddleware": 0
1887
+ }],
1888
+ "flipBehavior": [{
1889
+ "updateMiddleware": 0
1890
+ }],
1891
+ "offsetBehavior": [{
1892
+ "updateMiddleware": 0
1893
+ }]
1894
+ }; }
1895
+ };
1896
+ Popover.style = popoverCss();
1897
+
1898
+ export { Popover as vertex_popover };