spell-ui 0.8.6 → 0.8.8

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 (722) hide show
  1. package/README-components.md +14 -6
  2. package/README-frameworks.md +22 -12
  3. package/README-migrating.md +7 -6
  4. package/README-runtime.md +14 -13
  5. package/README-site.md +11 -11
  6. package/README-themes.md +38 -11
  7. package/README.md +61 -73
  8. package/dist/Dragging-CMZoLEWQ.js +169 -0
  9. package/dist/Dragging-CMZoLEWQ.js.map +1 -0
  10. package/dist/{MarkdownEngine-CbuT9Mjc.js → MarkdownEngine-CW1WGqNp.js} +122 -100
  11. package/dist/MarkdownEngine-CW1WGqNp.js.map +1 -0
  12. package/dist/{PrefStore-CeaTtjTz.js → PrefStore-Qv0e5y04.js} +22 -22
  13. package/dist/PrefStore-Qv0e5y04.js.map +1 -0
  14. package/dist/ScrollingRow-7n7Z-HIE.js +88 -0
  15. package/dist/ScrollingRow-7n7Z-HIE.js.map +1 -0
  16. package/dist/SitePages-CciwREek.js +51 -0
  17. package/dist/SitePages-CciwREek.js.map +1 -0
  18. package/dist/{SlottedItems-Ch0tzzlL.js → SlottedItems-Du3aJwG1.js} +22 -22
  19. package/dist/{SlottedItems-Ch0tzzlL.js.map → SlottedItems-Du3aJwG1.js.map} +1 -1
  20. package/dist/ThemeDraft-B7NPif4d.js +805 -0
  21. package/dist/ThemeDraft-B7NPif4d.js.map +1 -0
  22. package/dist/TreeMeasure-BVJeGb1L.js +42 -0
  23. package/dist/TreeMeasure-BVJeGb1L.js.map +1 -0
  24. package/dist/UIButton-DFEds67r.js +6 -0
  25. package/dist/UIButton-DFEds67r.js.map +1 -0
  26. package/dist/UIInput-BodVbUoQ.js +6 -0
  27. package/dist/UIInput-BodVbUoQ.js.map +1 -0
  28. package/dist/{UIKeys-DJF2TIKE.js → UIKeys-Rh_gUZjP.js} +10 -9
  29. package/dist/UIKeys-Rh_gUZjP.js.map +1 -0
  30. package/dist/UILabel-DgJUBzB_.js +6 -0
  31. package/dist/UILabel-DgJUBzB_.js.map +1 -0
  32. package/dist/UIMenu-zdcAtwTa.js +42 -0
  33. package/dist/UIMenu-zdcAtwTa.js.map +1 -0
  34. package/dist/{UIRuntime-BBuehGly.js → UIRuntime-KH309p5B.js} +398 -207
  35. package/dist/UIRuntime-KH309p5B.js.map +1 -0
  36. package/dist/_spell-element/DOMElement.d.ts +62 -5
  37. package/dist/_spell-element/MoveAndResize.d.ts +75 -0
  38. package/dist/_spell-element/UIComponent.d.ts +42 -0
  39. package/dist/_spell-element/elements.types.d.ts +47 -0
  40. package/dist/_spell-element/index.d.ts +1 -0
  41. package/dist/_spell-element/vocabulary.types.d.ts +34 -2
  42. package/dist/{runtime → _util}/Api.d.ts +14 -4
  43. package/dist/_util/Dragging.d.ts +148 -0
  44. package/dist/_util/ListSelection.d.ts +46 -0
  45. package/dist/{util → _util}/LoadOnce.d.ts +9 -1
  46. package/dist/_util/ReconnectingSocket.d.ts +51 -0
  47. package/dist/_util/diagram/DiagramColumns.d.ts +14 -0
  48. package/dist/_util/diagram/DiagramLayout.d.ts +119 -0
  49. package/dist/_util/diagram/DiagramSVG.d.ts +17 -0
  50. package/dist/_util/dom.d.ts +10 -0
  51. package/dist/_util/fetching.d.ts +92 -0
  52. package/dist/_util/measures/Dimension.d.ts +63 -0
  53. package/dist/_util/measures/MeasureSystem.d.ts +66 -0
  54. package/dist/_util/measures/dimensions.generated.d.ts +16 -0
  55. package/dist/_util/persist/ColorScheme.d.ts +6 -0
  56. package/dist/_util/persist/ServerPlace.d.ts +42 -0
  57. package/dist/_util/persist/WaitedOnPlace.d.ts +27 -0
  58. package/dist/_util/persist/persist.types.d.ts +21 -2
  59. package/dist/_util/timing.d.ts +10 -1
  60. package/dist/api.js +8 -7
  61. package/dist/api.js.map +1 -1
  62. package/dist/components/ComponentDefinitions.d.ts +29 -0
  63. package/dist/components/components.es.d.ts +13 -0
  64. package/dist/components/components.types.d.ts +113 -8
  65. package/dist/components/ui-accordion/UIAccordion.d.ts +1 -0
  66. package/dist/components/ui-accordion/UIAccordion.en.d.ts +1 -0
  67. package/dist/components/ui-action/UIAction.en.d.ts +5 -1
  68. package/dist/components/ui-ad/UIAd.d.ts +1 -0
  69. package/dist/components/ui-ad/UIAd.en.d.ts +1 -0
  70. package/dist/components/ui-breadcrumbs/UIBreadcrumb.d.ts +1 -0
  71. package/dist/components/ui-breadcrumbs/UIBreadcrumb.en.d.ts +1 -0
  72. package/dist/components/ui-breadcrumbs/UIBreadcrumbs.d.ts +1 -0
  73. package/dist/components/ui-breadcrumbs/UIBreadcrumbs.en.d.ts +1 -0
  74. package/dist/components/ui-button/UIButton.d.ts +8 -3
  75. package/dist/components/ui-button/UIButton.en.d.ts +9 -4
  76. package/dist/components/ui-button/UIButton.es.d.ts +6 -0
  77. package/dist/components/ui-button/UIButton.fallback.d.ts +8 -3
  78. package/dist/components/ui-button/UIButtons.d.ts +1 -0
  79. package/dist/components/ui-button/UIButtons.en.d.ts +1 -0
  80. package/dist/components/ui-button/UIOr.d.ts +1 -0
  81. package/dist/components/ui-button/UIOr.en.d.ts +1 -0
  82. package/dist/components/ui-calendar/UICalendar.d.ts +6 -0
  83. package/dist/components/ui-calendar/UICalendar.en.d.ts +6 -0
  84. package/dist/components/ui-calendar/UICalendar.fallback.d.ts +6 -0
  85. package/dist/components/ui-card/CardClicks.d.ts +40 -0
  86. package/dist/components/ui-card/UICard.d.ts +41 -0
  87. package/dist/components/ui-card/UICard.en.d.ts +49 -0
  88. package/dist/components/ui-card/UICard.es.d.ts +1 -0
  89. package/dist/components/ui-card/UICards.d.ts +31 -0
  90. package/dist/components/ui-card/UICards.en.d.ts +31 -0
  91. package/dist/components/ui-card/UICards.es.d.ts +8 -0
  92. package/dist/components/ui-checkbox/CheckControl.d.ts +7 -0
  93. package/dist/components/ui-checkbox/UICheckbox.d.ts +7 -0
  94. package/dist/components/ui-checkbox/UICheckbox.en.d.ts +7 -0
  95. package/dist/components/ui-checkbox/UICheckbox.es.d.ts +1 -0
  96. package/dist/components/ui-checkbox/UICheckbox.fallback.d.ts +7 -0
  97. package/dist/components/ui-checkbox/UICheckbox.types.d.ts +5 -0
  98. package/dist/components/ui-checkbox/UIRadio.d.ts +8 -0
  99. package/dist/components/ui-checkbox/UIRadio.en.d.ts +6 -0
  100. package/dist/components/ui-code/UICode.en.d.ts +1 -0
  101. package/dist/components/ui-comment/UIComment.d.ts +1 -0
  102. package/dist/components/ui-comment/UIComment.en.d.ts +1 -0
  103. package/dist/components/ui-comment/UIComments.d.ts +1 -0
  104. package/dist/components/ui-comment/UIComments.en.d.ts +1 -0
  105. package/dist/components/ui-components/PackHotSwap.d.ts +13 -3
  106. package/dist/components/ui-components/UIComponents.d.ts +1 -0
  107. package/dist/components/ui-components/UIComponents.en.d.ts +1 -0
  108. package/dist/components/ui-container/UIContainer.d.ts +11 -0
  109. package/dist/components/ui-container/UIContainer.en.d.ts +7 -0
  110. package/dist/components/ui-container/UIContainer.es.d.ts +1 -0
  111. package/dist/components/ui-diagram/UIDiagram.d.ts +268 -0
  112. package/dist/components/ui-diagram/UIDiagram.en.d.ts +106 -0
  113. package/dist/components/ui-diagram/UIDiagram.es.d.ts +37 -0
  114. package/dist/components/ui-diagram/UIDiagramNode.d.ts +98 -0
  115. package/dist/components/ui-diagram/UIDiagramNode.en.d.ts +38 -0
  116. package/dist/components/ui-diagram/UIDiagramNode.es.d.ts +16 -0
  117. package/dist/components/ui-diagram/index.d.ts +8 -0
  118. package/dist/components/ui-dimension/UIDimension.d.ts +81 -0
  119. package/dist/components/ui-dimension/UIDimension.en.d.ts +54 -0
  120. package/dist/components/ui-dimension/UIDimension.es.d.ts +22 -0
  121. package/dist/components/ui-dimension/index.d.ts +2 -0
  122. package/dist/components/ui-dimmer/UIDimmer.d.ts +6 -1
  123. package/dist/components/ui-dimmer/UIDimmer.en.d.ts +1 -0
  124. package/dist/components/ui-dimmer/UIDimmer.es.d.ts +1 -1
  125. package/dist/components/ui-divider/UIDivider.d.ts +2 -0
  126. package/dist/components/ui-divider/UIDivider.en.d.ts +2 -0
  127. package/dist/components/ui-divider/UIDivider.es.d.ts +1 -0
  128. package/dist/components/ui-dropdown/UIDropdown.d.ts +6 -0
  129. package/dist/components/ui-dropdown/UIDropdown.en.d.ts +6 -0
  130. package/dist/components/ui-dropdown/UIDropdown.fallback.d.ts +6 -0
  131. package/dist/components/ui-embed/UIEmbed.d.ts +1 -0
  132. package/dist/components/ui-embed/UIEmbed.en.d.ts +1 -0
  133. package/dist/components/ui-emoji/UIEmoji.d.ts +1 -0
  134. package/dist/components/ui-emoji/UIEmoji.en.d.ts +1 -0
  135. package/dist/components/ui-example/UIExample.en.d.ts +4 -2
  136. package/dist/components/ui-example/UIExample.es.d.ts +3 -2
  137. package/dist/components/ui-feed/UIFeed.d.ts +1 -0
  138. package/dist/components/ui-feed/UIFeed.en.d.ts +1 -0
  139. package/dist/components/ui-feed/UIFeedEvent.d.ts +1 -0
  140. package/dist/components/ui-feed/UIFeedEvent.en.d.ts +1 -0
  141. package/dist/components/ui-flag/UIFlag.d.ts +1 -0
  142. package/dist/components/ui-flag/UIFlag.en.d.ts +1 -0
  143. package/dist/components/ui-flyout/UIFlyout.d.ts +1 -0
  144. package/dist/components/ui-flyout/UIFlyout.en.d.ts +1 -0
  145. package/dist/components/ui-form/FormBinding.d.ts +13 -1
  146. package/dist/components/ui-form/FormFields.d.ts +4 -4
  147. package/dist/components/ui-form/UIField.d.ts +30 -3
  148. package/dist/components/ui-form/UIField.en.d.ts +9 -0
  149. package/dist/components/ui-form/UIField.es.d.ts +6 -0
  150. package/dist/components/ui-form/UIFields.d.ts +1 -0
  151. package/dist/components/ui-form/UIFields.en.d.ts +1 -0
  152. package/dist/components/ui-form/UIForm.d.ts +15 -0
  153. package/dist/components/ui-form/UIForm.en.d.ts +6 -0
  154. package/dist/components/ui-form/UIRepeat.d.ts +1 -0
  155. package/dist/components/ui-form/UIRepeat.en.d.ts +1 -0
  156. package/dist/components/ui-form/index.d.ts +2 -1
  157. package/dist/components/ui-grid/UIColumn.d.ts +1 -0
  158. package/dist/components/ui-grid/UIColumn.en.d.ts +1 -0
  159. package/dist/components/ui-grid/UIGrid.d.ts +1 -0
  160. package/dist/components/ui-grid/UIGrid.en.d.ts +1 -0
  161. package/dist/components/ui-grid/UIRow.d.ts +1 -0
  162. package/dist/components/ui-grid/UIRow.en.d.ts +1 -0
  163. package/dist/components/ui-icon/UIIcon.d.ts +3 -2
  164. package/dist/components/ui-icon/UIIcon.en.d.ts +3 -2
  165. package/dist/components/ui-icon/UIIcons.d.ts +1 -0
  166. package/dist/components/ui-icon/UIIcons.en.d.ts +1 -0
  167. package/dist/components/ui-icon-picker/UIIconPicker.d.ts +6 -0
  168. package/dist/components/ui-icon-picker/UIIconPicker.en.d.ts +6 -0
  169. package/dist/components/ui-icon-picker/UIIconPicker.fallback.d.ts +6 -0
  170. package/dist/components/ui-image/UIImage.d.ts +34 -0
  171. package/dist/components/ui-image/UIImage.en.d.ts +23 -0
  172. package/dist/components/ui-image/UIImage.es.d.ts +2 -0
  173. package/dist/components/ui-image/UIImages.d.ts +1 -0
  174. package/dist/components/ui-image/UIImages.en.d.ts +1 -0
  175. package/dist/components/ui-include/UIInclude.d.ts +1 -0
  176. package/dist/components/ui-include/UIInclude.en.d.ts +1 -0
  177. package/dist/components/ui-input/TextControl.d.ts +7 -0
  178. package/dist/components/ui-input/UIInput.d.ts +22 -3
  179. package/dist/components/ui-input/UIInput.en.d.ts +9 -2
  180. package/dist/components/ui-input/UIInput.es.d.ts +2 -0
  181. package/dist/components/ui-input/UIInput.fallback.d.ts +9 -2
  182. package/dist/components/ui-input/UITextarea.d.ts +20 -0
  183. package/dist/components/ui-input/UITextarea.en.d.ts +15 -0
  184. package/dist/components/ui-input/UITextarea.es.d.ts +4 -0
  185. package/dist/components/ui-item/UIItem.d.ts +27 -4
  186. package/dist/components/ui-item/UIItem.en.d.ts +5 -1
  187. package/dist/components/ui-items/UIItems.d.ts +1 -0
  188. package/dist/components/ui-items/UIItems.en.d.ts +1 -0
  189. package/dist/components/ui-json/JsonChild.d.ts +30 -0
  190. package/dist/components/ui-json/UIJson.d.ts +128 -0
  191. package/dist/components/ui-json/UIJson.en.d.ts +71 -0
  192. package/dist/components/ui-json/UIJson.es.d.ts +12 -0
  193. package/dist/components/ui-json/index.d.ts +3 -0
  194. package/dist/components/ui-keys/UIKeys.d.ts +1 -0
  195. package/dist/components/ui-keys/UIKeys.en.d.ts +1 -0
  196. package/dist/components/ui-label/UILabel.d.ts +2 -0
  197. package/dist/components/ui-label/UILabel.en.d.ts +2 -0
  198. package/dist/components/ui-label/UILabel.es.d.ts +1 -0
  199. package/dist/components/ui-label/UILabels.d.ts +1 -0
  200. package/dist/components/ui-label/UILabels.en.d.ts +1 -0
  201. package/dist/components/ui-list/UIList.d.ts +2 -0
  202. package/dist/components/ui-list/UIList.en.d.ts +2 -0
  203. package/dist/components/ui-list/UIList.es.d.ts +1 -0
  204. package/dist/components/ui-loader/UILoader.d.ts +1 -0
  205. package/dist/components/ui-loader/UILoader.en.d.ts +1 -0
  206. package/dist/components/ui-markdown/MarkdownBox.d.ts +143 -0
  207. package/dist/components/ui-markdown/MarkdownEngine.d.ts +14 -2
  208. package/dist/components/ui-markdown/MarkdownFormats.d.ts +95 -0
  209. package/dist/components/ui-markdown/MarkdownSource.d.ts +57 -0
  210. package/dist/components/ui-markdown/UIMarkdown.d.ts +126 -6
  211. package/dist/components/ui-markdown/UIMarkdown.en.d.ts +111 -8
  212. package/dist/components/ui-markdown/UIMarkdown.es.d.ts +29 -1
  213. package/dist/components/ui-markdown/UIMarkdown.types.d.ts +26 -0
  214. package/dist/components/ui-menu/ScrollingRow.d.ts +79 -0
  215. package/dist/components/ui-menu/TitleFit.d.ts +3 -0
  216. package/dist/components/ui-menu/UIMenu.d.ts +97 -4
  217. package/dist/components/ui-menu/UIMenu.en.d.ts +50 -1
  218. package/dist/components/ui-menu/UIMenu.es.d.ts +4 -0
  219. package/dist/components/ui-message/UIMessage.d.ts +2 -0
  220. package/dist/components/ui-message/UIMessage.en.d.ts +2 -0
  221. package/dist/components/ui-message/UIMessage.es.d.ts +1 -0
  222. package/dist/components/ui-modal/UIModal.d.ts +1 -0
  223. package/dist/components/ui-modal/UIModal.en.d.ts +1 -0
  224. package/dist/components/ui-nag/UINag.d.ts +1 -0
  225. package/dist/components/ui-nag/UINag.en.d.ts +1 -0
  226. package/dist/components/ui-page/UIPage.d.ts +15 -0
  227. package/dist/components/ui-page/UIPage.en.d.ts +15 -0
  228. package/dist/components/ui-page/UIPage.es.d.ts +1 -0
  229. package/dist/components/ui-panel/UIPanel.d.ts +6 -0
  230. package/dist/components/ui-panel/UIPanel.en.d.ts +33 -20
  231. package/dist/components/ui-parts/UIActions.d.ts +1 -0
  232. package/dist/components/ui-parts/UIActions.en.d.ts +1 -0
  233. package/dist/components/ui-parts/UIAuthor.d.ts +1 -0
  234. package/dist/components/ui-parts/UIAuthor.en.d.ts +1 -0
  235. package/dist/components/ui-parts/UIAvatar.d.ts +1 -0
  236. package/dist/components/ui-parts/UIAvatar.en.d.ts +1 -0
  237. package/dist/components/ui-parts/UIContent.d.ts +1 -0
  238. package/dist/components/ui-parts/UIContent.en.d.ts +1 -0
  239. package/dist/components/ui-parts/UIDate.d.ts +1 -0
  240. package/dist/components/ui-parts/UIDate.en.d.ts +1 -0
  241. package/dist/components/ui-parts/UIDescription.d.ts +1 -0
  242. package/dist/components/ui-parts/UIDescription.en.d.ts +1 -0
  243. package/dist/components/ui-parts/UIDetail.d.ts +1 -0
  244. package/dist/components/ui-parts/UIDetail.en.d.ts +1 -0
  245. package/dist/components/ui-parts/UIExtra.d.ts +1 -0
  246. package/dist/components/ui-parts/UIExtra.en.d.ts +1 -0
  247. package/dist/components/ui-parts/UIHeader.d.ts +3 -1
  248. package/dist/components/ui-parts/UIHeader.en.d.ts +3 -1
  249. package/dist/components/ui-parts/UIMeta.d.ts +1 -0
  250. package/dist/components/ui-parts/UIMeta.en.d.ts +1 -0
  251. package/dist/components/ui-parts/UIParts.types.d.ts +15 -1
  252. package/dist/components/ui-parts/UISummary.d.ts +1 -0
  253. package/dist/components/ui-parts/UISummary.en.d.ts +1 -0
  254. package/dist/components/ui-parts/UITitle.d.ts +1 -0
  255. package/dist/components/ui-parts/UITitle.en.d.ts +1 -0
  256. package/dist/components/ui-parts/UIValue.d.ts +1 -0
  257. package/dist/components/ui-parts/UIValue.en.d.ts +1 -0
  258. package/dist/components/ui-placeholder/UIPlaceholder.d.ts +1 -0
  259. package/dist/components/ui-placeholder/UIPlaceholder.en.d.ts +1 -0
  260. package/dist/components/ui-placeholder/UIPlaceholderHeader.d.ts +1 -0
  261. package/dist/components/ui-placeholder/UIPlaceholderHeader.en.d.ts +1 -0
  262. package/dist/components/ui-placeholder/UIPlaceholderImage.d.ts +1 -0
  263. package/dist/components/ui-placeholder/UIPlaceholderImage.en.d.ts +1 -0
  264. package/dist/components/ui-placeholder/UIPlaceholderLine.d.ts +1 -0
  265. package/dist/components/ui-placeholder/UIPlaceholderLine.en.d.ts +1 -0
  266. package/dist/components/ui-placeholder/UIPlaceholderParagraph.d.ts +1 -0
  267. package/dist/components/ui-placeholder/UIPlaceholderParagraph.en.d.ts +1 -0
  268. package/dist/components/ui-popup/UIPopup.d.ts +30 -3
  269. package/dist/components/ui-popup/UIPopup.en.d.ts +7 -0
  270. package/dist/components/ui-popup/UIPopup.es.d.ts +1 -0
  271. package/dist/components/ui-progress/UIProgress.d.ts +2 -0
  272. package/dist/components/ui-progress/UIProgress.en.d.ts +2 -0
  273. package/dist/components/ui-progress/UIProgress.es.d.ts +1 -0
  274. package/dist/components/ui-property-editor/UIProperty.d.ts +132 -5
  275. package/dist/components/ui-property-editor/UIProperty.en.d.ts +11 -44
  276. package/dist/components/ui-property-editor/UIProperty.es.d.ts +4 -0
  277. package/dist/components/ui-property-editor/UIPropertyEditor.d.ts +38 -0
  278. package/dist/components/ui-property-editor/UIPropertyEditor.en.d.ts +1 -0
  279. package/dist/components/ui-property-editor/UIPropertyEditor.es.d.ts +4 -0
  280. package/dist/components/ui-property-editor/UIPropertyEditor.types.d.ts +33 -0
  281. package/dist/components/ui-property-editor/UIPropertyGroup.d.ts +12 -0
  282. package/dist/components/ui-property-editor/UIPropertyGroup.en.d.ts +2 -0
  283. package/dist/components/ui-property-editor/UIPropertyGroup.es.d.ts +9 -0
  284. package/dist/components/ui-property-editor/index.d.ts +1 -0
  285. package/dist/components/ui-quote/UIQuote.d.ts +1 -0
  286. package/dist/components/ui-quote/UIQuote.en.d.ts +1 -0
  287. package/dist/components/ui-rail/UIRail.d.ts +1 -0
  288. package/dist/components/ui-rail/UIRail.en.d.ts +1 -0
  289. package/dist/components/ui-rating/UIRating.d.ts +6 -0
  290. package/dist/components/ui-rating/UIRating.en.d.ts +6 -0
  291. package/dist/components/ui-rating/UIRating.fallback.d.ts +6 -0
  292. package/dist/components/ui-reveal/UIReveal.d.ts +1 -0
  293. package/dist/components/ui-reveal/UIReveal.en.d.ts +1 -0
  294. package/dist/components/ui-root/UIRoot.d.ts +18 -3
  295. package/dist/components/ui-root/UIRoot.en.d.ts +15 -0
  296. package/dist/components/ui-root/UIRoot.es.d.ts +1 -0
  297. package/dist/components/ui-search/UISearch.d.ts +48 -7
  298. package/dist/components/ui-search/UISearch.en.d.ts +13 -1
  299. package/dist/components/ui-search/UISearch.es.d.ts +1 -0
  300. package/dist/components/ui-search/UISearch.fallback.d.ts +13 -1
  301. package/dist/components/ui-section/UISection.d.ts +22 -1
  302. package/dist/components/ui-section/UISection.en.d.ts +10 -0
  303. package/dist/components/ui-section/UISection.es.d.ts +1 -0
  304. package/dist/components/ui-section/UISections.d.ts +1 -0
  305. package/dist/components/ui-section/UISections.en.d.ts +1 -0
  306. package/dist/components/ui-segment/UISegment.d.ts +2 -0
  307. package/dist/components/ui-segment/UISegment.en.d.ts +2 -0
  308. package/dist/components/ui-segment/UISegment.es.d.ts +1 -0
  309. package/dist/components/ui-segment/UISegments.d.ts +1 -0
  310. package/dist/components/ui-segment/UISegments.en.d.ts +1 -0
  311. package/dist/components/ui-select/UISelect.d.ts +6 -0
  312. package/dist/components/ui-select/UISelect.en.d.ts +6 -0
  313. package/dist/components/ui-select/UISelect.fallback.d.ts +6 -0
  314. package/dist/components/ui-shape/UIShape.d.ts +23 -2
  315. package/dist/components/ui-shape/UIShape.en.d.ts +8 -0
  316. package/dist/components/ui-shape/UIShape.es.d.ts +1 -0
  317. package/dist/components/ui-shape/UISide.d.ts +4 -0
  318. package/dist/components/ui-shape/UISide.en.d.ts +4 -0
  319. package/dist/components/ui-sidebar/UIPushable.d.ts +1 -0
  320. package/dist/components/ui-sidebar/UIPushable.en.d.ts +1 -0
  321. package/dist/components/ui-sidebar/UIPusher.d.ts +1 -0
  322. package/dist/components/ui-sidebar/UIPusher.en.d.ts +1 -0
  323. package/dist/components/ui-sidebar/UISidebar.d.ts +1 -0
  324. package/dist/components/ui-sidebar/UISidebar.en.d.ts +1 -0
  325. package/dist/components/ui-sides/UISides.d.ts +209 -0
  326. package/dist/components/ui-sides/UISides.en.d.ts +122 -0
  327. package/dist/components/ui-sides/UISides.es.d.ts +30 -0
  328. package/dist/components/ui-sides/UISides.fallback.d.ts +134 -0
  329. package/dist/components/ui-sides/index.d.ts +2 -0
  330. package/dist/components/ui-site-nav/SitePages.d.ts +53 -0
  331. package/dist/components/ui-site-nav/UISiteNav.d.ts +207 -0
  332. package/dist/components/ui-site-nav/UISiteNav.en.d.ts +87 -0
  333. package/dist/components/ui-site-nav/UISiteNav.es.d.ts +29 -0
  334. package/dist/components/ui-site-nav/index.d.ts +1 -0
  335. package/dist/components/ui-site-tabs/UISiteTabs.d.ts +126 -0
  336. package/dist/components/ui-site-tabs/UISiteTabs.en.d.ts +49 -0
  337. package/dist/components/ui-site-tabs/UISiteTabs.es.d.ts +18 -0
  338. package/dist/components/ui-site-tabs/index.d.ts +1 -0
  339. package/dist/components/ui-slider/UISlider.d.ts +7 -0
  340. package/dist/components/ui-slider/UISlider.en.d.ts +7 -0
  341. package/dist/components/ui-slider/UISlider.es.d.ts +1 -0
  342. package/dist/components/ui-slider/UISlider.fallback.d.ts +7 -0
  343. package/dist/components/ui-space/UISpace.d.ts +1 -0
  344. package/dist/components/ui-space/UISpace.en.d.ts +1 -0
  345. package/dist/components/ui-split-panel/UISplitPanel.d.ts +175 -0
  346. package/dist/components/ui-split-panel/UISplitPanel.en.d.ts +74 -0
  347. package/dist/components/ui-split-panel/UISplitPanel.es.d.ts +25 -0
  348. package/dist/components/ui-split-panel/index.d.ts +2 -0
  349. package/dist/components/ui-stack/UIStack.d.ts +31 -5
  350. package/dist/components/ui-stack/UIStack.en.d.ts +15 -3
  351. package/dist/components/ui-statistic/UIStatistic.d.ts +1 -0
  352. package/dist/components/ui-statistic/UIStatistic.en.d.ts +1 -0
  353. package/dist/components/ui-statistic/UIStatistics.d.ts +1 -0
  354. package/dist/components/ui-statistic/UIStatistics.en.d.ts +1 -0
  355. package/dist/components/ui-step/UIStep.d.ts +1 -0
  356. package/dist/components/ui-step/UIStep.en.d.ts +1 -0
  357. package/dist/components/ui-step/UISteps.d.ts +1 -0
  358. package/dist/components/ui-step/UISteps.en.d.ts +1 -0
  359. package/dist/components/ui-sticky/UISticky.d.ts +4 -0
  360. package/dist/components/ui-sticky/UISticky.en.d.ts +1 -0
  361. package/dist/components/ui-tab/UITab.d.ts +8 -0
  362. package/dist/components/ui-tab/UITab.en.d.ts +1 -0
  363. package/dist/components/ui-tab/UITabs.d.ts +107 -16
  364. package/dist/components/ui-tab/UITabs.en.d.ts +40 -1
  365. package/dist/components/ui-tab/UITabs.es.d.ts +4 -0
  366. package/dist/components/ui-table/TableEditing.d.ts +77 -0
  367. package/dist/components/ui-table/UICell.d.ts +1 -0
  368. package/dist/components/ui-table/UICell.en.d.ts +1 -0
  369. package/dist/components/ui-table/UITable.d.ts +145 -5
  370. package/dist/components/ui-table/UITable.en.d.ts +19 -0
  371. package/dist/components/ui-table/UITable.es.d.ts +3 -0
  372. package/dist/components/ui-terms/UITerm.d.ts +1 -0
  373. package/dist/components/ui-terms/UITerm.en.d.ts +1 -0
  374. package/dist/components/ui-terms/UITerms.d.ts +1 -0
  375. package/dist/components/ui-terms/UITerms.en.d.ts +1 -0
  376. package/dist/components/ui-text/UILink.d.ts +11 -0
  377. package/dist/components/ui-text/UILink.en.d.ts +4 -0
  378. package/dist/components/ui-text/UIText.d.ts +7 -0
  379. package/dist/components/ui-text/UIText.en.d.ts +7 -0
  380. package/dist/components/ui-text/UIText.es.d.ts +2 -0
  381. package/dist/components/ui-theme-editor/SavedTheme.d.ts +55 -43
  382. package/dist/components/ui-theme-editor/ThemeDraft.d.ts +15 -0
  383. package/dist/components/ui-theme-editor/UIColorChip.d.ts +1 -0
  384. package/dist/components/ui-theme-editor/UIColorChip.en.d.ts +1 -0
  385. package/dist/components/ui-theme-editor/UIThemeEditor.d.ts +157 -26
  386. package/dist/components/ui-theme-editor/UIThemeEditor.en.d.ts +79 -6
  387. package/dist/components/ui-theme-editor/UIThemeEditor.es.d.ts +20 -2
  388. package/dist/components/ui-theme-editor/UIThemeEditor.types.d.ts +0 -2
  389. package/dist/components/ui-theme-editor/UIThemeToken.d.ts +1 -0
  390. package/dist/components/ui-theme-editor/UIThemeToken.en.d.ts +1 -0
  391. package/dist/components/ui-theme-menu/HueDropdown.d.ts +47 -0
  392. package/dist/components/ui-theme-menu/ThemeMenu.d.ts +18 -7
  393. package/dist/components/ui-theme-menu/ThemePreference.d.ts +145 -36
  394. package/dist/components/ui-theme-menu/UIThemeMenu.d.ts +118 -7
  395. package/dist/components/ui-theme-menu/UIThemeMenu.en.d.ts +82 -2
  396. package/dist/components/ui-theme-menu/UIThemeMenu.es.d.ts +21 -1
  397. package/dist/components/ui-theme-menu/UIThemeMenu.types.d.ts +36 -8
  398. package/dist/components/ui-theme-menu/index.d.ts +2 -1
  399. package/dist/components/ui-toast/UIToast.d.ts +1 -0
  400. package/dist/components/ui-toast/UIToast.en.d.ts +1 -0
  401. package/dist/components/ui-toc/UIToc.d.ts +1 -0
  402. package/dist/components/ui-toc/UIToc.en.d.ts +1 -0
  403. package/dist/components/ui-toolbar/UIToolbar.d.ts +13 -10
  404. package/dist/components/ui-toolbar/UIToolbar.en.d.ts +138 -84
  405. package/dist/components/ui-toolbar/UIToolbar.es.d.ts +2 -0
  406. package/dist/components/ui-transition/UITransition.d.ts +1 -0
  407. package/dist/components/ui-transition/UITransition.en.d.ts +1 -0
  408. package/dist/components/ui-tree/UITree.d.ts +162 -0
  409. package/dist/components/ui-tree/UITree.en.d.ts +88 -0
  410. package/dist/components/ui-tree/UITree.es.d.ts +35 -0
  411. package/dist/components/ui-tree/UITreeItem.d.ts +204 -0
  412. package/dist/components/ui-tree/UITreeItem.en.d.ts +142 -0
  413. package/dist/components/ui-tree/UITreeItem.es.d.ts +32 -0
  414. package/dist/components/ui-tree/index.d.ts +3 -0
  415. package/dist/components/ui-tree-diagram/TreeData.d.ts +3 -12
  416. package/dist/components/ui-tree-diagram/TreeLayout.d.ts +54 -21
  417. package/dist/components/ui-tree-diagram/TreeMeasure.d.ts +36 -0
  418. package/dist/components/ui-tree-diagram/UITreeDiagram.d.ts +152 -27
  419. package/dist/components/ui-tree-diagram/UITreeDiagram.en.d.ts +47 -7
  420. package/dist/components/ui-tree-diagram/UITreeDiagram.es.d.ts +12 -1
  421. package/dist/components/ui-tree-diagram/UITreeDiagram.types.d.ts +66 -21
  422. package/dist/components/ui-tree-diagram/UITreeNode.d.ts +148 -0
  423. package/dist/components/ui-tree-diagram/UITreeNode.en.d.ts +69 -0
  424. package/dist/components/ui-tree-diagram/UITreeNode.es.d.ts +21 -0
  425. package/dist/components/ui-tree-diagram/index.d.ts +4 -2
  426. package/dist/components/ui-video/UIAudio.d.ts +1 -0
  427. package/dist/components/ui-video/UIAudio.en.d.ts +1 -0
  428. package/dist/components/ui-video/UIVideo.d.ts +1 -0
  429. package/dist/components/ui-video/UIVideo.en.d.ts +1 -0
  430. package/dist/components/ui-visibility/UIVisibility.d.ts +1 -0
  431. package/dist/components/ui-visibility/UIVisibility.en.d.ts +1 -0
  432. package/dist/components/ui-zoom/UIZoom.d.ts +1 -0
  433. package/dist/components/ui-zoom/UIZoom.en.d.ts +1 -0
  434. package/dist/{components.es-DmLzT-Bq.js → components.es-BOa_7gFF.js} +498 -109
  435. package/dist/components.es-BOa_7gFF.js.map +1 -0
  436. package/dist/core.d.ts +3 -1
  437. package/dist/core.js +1082 -511
  438. package/dist/core.js.map +1 -1
  439. package/dist/crisp-VfYZlTph.js +6 -0
  440. package/dist/{crisp-CoZRRDuQ.js.map → crisp-VfYZlTph.js.map} +1 -1
  441. package/dist/docs-components/index.d.ts +1 -0
  442. package/dist/docs-components/ui-docs-index/UIDocsIndex.d.ts +89 -0
  443. package/dist/docs-components/ui-docs-index/UIDocsIndex.en.d.ts +43 -0
  444. package/dist/docs-components/ui-docs-index/index.d.ts +2 -0
  445. package/dist/docs-components/ui-docs-nav/UIDocsNav.d.ts +54 -87
  446. package/dist/docs-components/ui-docs-nav/UIDocsNav.types.d.ts +2 -29
  447. package/dist/docs-components/ui-docs-search/SearchIndex.d.ts +8 -2
  448. package/dist/docs-components/ui-docs-search/UIDocsSearch.d.ts +10 -0
  449. package/dist/docs-components/ui-docs-search/UIDocsSearch.en.d.ts +5 -0
  450. package/dist/elements/AddressParameter.d.ts +87 -0
  451. package/dist/elements/DOMFormControl.d.ts +5 -0
  452. package/dist/elements/FormComponent.d.ts +32 -0
  453. package/dist/elements/LoadableBody.d.ts +6 -1
  454. package/dist/elements/LoadableComponent.d.ts +10 -1
  455. package/dist/elements/RootSettings.d.ts +43 -6
  456. package/dist/elements/SpellUISettings.d.ts +1 -0
  457. package/dist/elements/StickyWatch.d.ts +20 -0
  458. package/dist/elements/elements.types.d.ts +15 -0
  459. package/dist/elements/index.d.ts +2 -0
  460. package/dist/forms.js +93 -63
  461. package/dist/forms.js.map +1 -1
  462. package/dist/fruity-BRVlgJZd.js +6 -0
  463. package/dist/fruity-BRVlgJZd.js.map +1 -0
  464. package/dist/{fruity.theme-BJcMiPl1.js → fruity.theme-CbC7Jyvk.js} +2 -2
  465. package/dist/fruity.theme-CbC7Jyvk.js.map +1 -0
  466. package/dist/glass-x9tbbwVq.js +6 -0
  467. package/dist/glass-x9tbbwVq.js.map +1 -0
  468. package/dist/glass.theme-24wY2wH9.js +6 -0
  469. package/dist/glass.theme-24wY2wH9.js.map +1 -0
  470. package/dist/hot.js +530 -24
  471. package/dist/hot.js.map +1 -1
  472. package/dist/index.d.ts +8 -0
  473. package/dist/index.js +91 -81
  474. package/dist/jsx.d.ts +21149 -10377
  475. package/dist/matrix-QY2gWbJ0.js +6 -0
  476. package/dist/{matrix-CqA59hiF.js.map → matrix-QY2gWbJ0.js.map} +1 -1
  477. package/dist/{matrix.theme-jqQZjcq3.js → matrix.theme-_8xtwhDq.js} +2 -2
  478. package/dist/matrix.theme-_8xtwhDq.js.map +1 -0
  479. package/dist/midnight-BxlTQSfw.js +6 -0
  480. package/dist/{midnight-BnoVOrhC.js.map → midnight-BxlTQSfw.js.map} +1 -1
  481. package/dist/mockup-83ELBuVr.js +6 -0
  482. package/dist/mockup-83ELBuVr.js.map +1 -0
  483. package/dist/mockup.theme-DmpBgGBl.js +6 -0
  484. package/dist/mockup.theme-DmpBgGBl.js.map +1 -0
  485. package/dist/paper-M61nUilz.js +6 -0
  486. package/dist/{paper-CynH8ZuT.js.map → paper-M61nUilz.js.map} +1 -1
  487. package/dist/persist.types-D2m6wD-S.js +9 -0
  488. package/dist/persist.types-D2m6wD-S.js.map +1 -0
  489. package/dist/pop-CxXfytjk.js +6 -0
  490. package/dist/{pop-D2i9V_rG.js.map → pop-CxXfytjk.js.map} +1 -1
  491. package/dist/runtime/DataTooltips.d.ts +75 -0
  492. package/dist/runtime/PropertyControls.d.ts +15 -1
  493. package/dist/runtime/Sources.d.ts +16 -4
  494. package/dist/runtime/Styles.d.ts +11 -0
  495. package/dist/runtime/Themes.d.ts +10 -4
  496. package/dist/runtime/UIRuntime.d.ts +4 -1
  497. package/dist/runtime/index.d.ts +1 -1
  498. package/dist/runtime/runtime.types.d.ts +18 -85
  499. package/dist/spell-By5Y3jKP.js +6 -0
  500. package/dist/{spell-BFtLICm7.js.map → spell-By5Y3jKP.js.map} +1 -1
  501. package/dist/{spell.theme-B7AU7SQX.js → spell.theme-DxGj7qHx.js} +2 -2
  502. package/dist/spell.theme-DxGj7qHx.js.map +1 -0
  503. package/dist/styles/CodeThemeFile.d.ts +73 -0
  504. package/dist/styles/StyleGenerator.d.ts +6 -0
  505. package/dist/styles/styles.en.d.ts +141 -3
  506. package/dist/styles/styles.types.d.ts +2 -0
  507. package/dist/{styles.en-RLpYiO5_.js → styles.en-CUUxNwHo.js} +71 -14
  508. package/dist/styles.en-CUUxNwHo.js.map +1 -0
  509. package/dist/styles.js +13 -13
  510. package/dist/styles.js.map +1 -1
  511. package/dist/ui-accordion.js +54 -53
  512. package/dist/ui-accordion.js.map +1 -1
  513. package/dist/ui-action.js +20 -19
  514. package/dist/ui-action.js.map +1 -1
  515. package/dist/ui-ad.js +5 -4
  516. package/dist/ui-ad.js.map +1 -1
  517. package/dist/ui-breadcrumbs.js +15 -13
  518. package/dist/ui-breadcrumbs.js.map +1 -1
  519. package/dist/ui-button.js +132 -125
  520. package/dist/ui-button.js.map +1 -1
  521. package/dist/ui-calendar.js +208 -206
  522. package/dist/ui-calendar.js.map +1 -1
  523. package/dist/ui-card.js +260 -98
  524. package/dist/ui-card.js.map +1 -1
  525. package/dist/ui-checkbox.js +95 -81
  526. package/dist/ui-checkbox.js.map +1 -1
  527. package/dist/ui-code.js +25 -24
  528. package/dist/ui-code.js.map +1 -1
  529. package/dist/ui-comment.js +14 -12
  530. package/dist/ui-comment.js.map +1 -1
  531. package/dist/ui-components.js +7 -6
  532. package/dist/ui-components.js.map +1 -1
  533. package/dist/ui-container.js +24 -12
  534. package/dist/ui-container.js.map +1 -1
  535. package/dist/ui-diagram.js +1328 -0
  536. package/dist/ui-diagram.js.map +1 -0
  537. package/dist/ui-dimension.js +779 -0
  538. package/dist/ui-dimension.js.map +1 -0
  539. package/dist/ui-dimmer.js +36 -34
  540. package/dist/ui-dimmer.js.map +1 -1
  541. package/dist/ui-divider.js +7 -5
  542. package/dist/ui-divider.js.map +1 -1
  543. package/dist/ui-dropdown.js +107 -105
  544. package/dist/ui-dropdown.js.map +1 -1
  545. package/dist/ui-embed.js +36 -35
  546. package/dist/ui-embed.js.map +1 -1
  547. package/dist/ui-emoji.js +10 -9
  548. package/dist/ui-emoji.js.map +1 -1
  549. package/dist/ui-example.js +63 -61
  550. package/dist/ui-example.js.map +1 -1
  551. package/dist/ui-feed.js +12 -10
  552. package/dist/ui-feed.js.map +1 -1
  553. package/dist/ui-flag.js +10 -9
  554. package/dist/ui-flag.js.map +1 -1
  555. package/dist/ui-flyout.js +7 -6
  556. package/dist/ui-flyout.js.map +1 -1
  557. package/dist/ui-form.js +244 -162
  558. package/dist/ui-form.js.map +1 -1
  559. package/dist/ui-grid.js +21 -18
  560. package/dist/ui-grid.js.map +1 -1
  561. package/dist/ui-icon-picker.js +46 -44
  562. package/dist/ui-icon-picker.js.map +1 -1
  563. package/dist/ui-icon.js +17 -14
  564. package/dist/ui-icon.js.map +1 -1
  565. package/dist/ui-image.js +93 -55
  566. package/dist/ui-image.js.map +1 -1
  567. package/dist/ui-include.js +18 -17
  568. package/dist/ui-include.js.map +1 -1
  569. package/dist/ui-input.js +154 -112
  570. package/dist/ui-input.js.map +1 -1
  571. package/dist/ui-item.js +152 -102
  572. package/dist/ui-item.js.map +1 -1
  573. package/dist/ui-items.js +9 -8
  574. package/dist/ui-items.js.map +1 -1
  575. package/dist/ui-json.js +115 -0
  576. package/dist/ui-json.js.map +1 -0
  577. package/dist/ui-keys.js +1 -1
  578. package/dist/ui-label.js +18 -15
  579. package/dist/ui-label.js.map +1 -1
  580. package/dist/ui-list.js +7 -5
  581. package/dist/ui-list.js.map +1 -1
  582. package/dist/ui-loader.js +7 -6
  583. package/dist/ui-loader.js.map +1 -1
  584. package/dist/ui-markdown.js +975 -83
  585. package/dist/ui-markdown.js.map +1 -1
  586. package/dist/ui-menu.js +329 -196
  587. package/dist/ui-menu.js.map +1 -1
  588. package/dist/ui-message.js +20 -18
  589. package/dist/ui-message.js.map +1 -1
  590. package/dist/ui-modal.js +46 -45
  591. package/dist/ui-modal.js.map +1 -1
  592. package/dist/ui-nag.js +19 -18
  593. package/dist/ui-nag.js.map +1 -1
  594. package/dist/ui-page.js +8 -7
  595. package/dist/ui-page.js.map +1 -1
  596. package/dist/ui-panel.js +28 -17
  597. package/dist/ui-panel.js.map +1 -1
  598. package/dist/ui-parts.js +66 -52
  599. package/dist/ui-parts.js.map +1 -1
  600. package/dist/ui-placeholder.js +21 -16
  601. package/dist/ui-placeholder.js.map +1 -1
  602. package/dist/ui-popup.js +113 -84
  603. package/dist/ui-popup.js.map +1 -1
  604. package/dist/ui-progress.js +9 -7
  605. package/dist/ui-progress.js.map +1 -1
  606. package/dist/ui-property-editor.js +706 -203
  607. package/dist/ui-property-editor.js.map +1 -1
  608. package/dist/ui-quote.js +5 -4
  609. package/dist/ui-quote.js.map +1 -1
  610. package/dist/ui-rail.js +5 -4
  611. package/dist/ui-rail.js.map +1 -1
  612. package/dist/ui-rating.js +31 -29
  613. package/dist/ui-rating.js.map +1 -1
  614. package/dist/ui-reveal.js +7 -6
  615. package/dist/ui-reveal.js.map +1 -1
  616. package/dist/ui-root.js +324 -158
  617. package/dist/ui-root.js.map +1 -1
  618. package/dist/ui-search.js +210 -168
  619. package/dist/ui-search.js.map +1 -1
  620. package/dist/ui-section.js +124 -92
  621. package/dist/ui-section.js.map +1 -1
  622. package/dist/ui-segment.js +15 -12
  623. package/dist/ui-segment.js.map +1 -1
  624. package/dist/ui-select.js +83 -81
  625. package/dist/ui-select.js.map +1 -1
  626. package/dist/ui-shape.js +86 -58
  627. package/dist/ui-shape.js.map +1 -1
  628. package/dist/ui-sidebar.js +59 -56
  629. package/dist/ui-sidebar.js.map +1 -1
  630. package/dist/ui-sides.js +325 -0
  631. package/dist/ui-sides.js.map +1 -0
  632. package/dist/ui-site-nav.js +329 -0
  633. package/dist/ui-site-nav.js.map +1 -0
  634. package/dist/ui-site-tabs.js +177 -0
  635. package/dist/ui-site-tabs.js.map +1 -0
  636. package/dist/ui-slider.js +84 -81
  637. package/dist/ui-slider.js.map +1 -1
  638. package/dist/ui-space.js +7 -6
  639. package/dist/ui-space.js.map +1 -1
  640. package/dist/ui-split-panel.js +298 -0
  641. package/dist/ui-split-panel.js.map +1 -0
  642. package/dist/ui-stack.js +47 -23
  643. package/dist/ui-stack.js.map +1 -1
  644. package/dist/ui-statistic.js +15 -13
  645. package/dist/ui-statistic.js.map +1 -1
  646. package/dist/ui-step.js +31 -29
  647. package/dist/ui-step.js.map +1 -1
  648. package/dist/ui-sticky.js +7 -6
  649. package/dist/ui-sticky.js.map +1 -1
  650. package/dist/ui-tab.js +230 -138
  651. package/dist/ui-tab.js.map +1 -1
  652. package/dist/ui-table.js +724 -162
  653. package/dist/ui-table.js.map +1 -1
  654. package/dist/ui-terms.js +12 -10
  655. package/dist/ui-terms.js.map +1 -1
  656. package/dist/ui-text.js +53 -28
  657. package/dist/ui-text.js.map +1 -1
  658. package/dist/ui-theme-editor.js +1018 -1545
  659. package/dist/ui-theme-editor.js.map +1 -1
  660. package/dist/ui-theme-menu-CuIjr8Ou.js +1493 -0
  661. package/dist/ui-theme-menu-CuIjr8Ou.js.map +1 -0
  662. package/dist/ui-toast.js +45 -44
  663. package/dist/ui-toast.js.map +1 -1
  664. package/dist/ui-toc.js +75 -74
  665. package/dist/ui-toc.js.map +1 -1
  666. package/dist/ui-toolbar.js +51 -73
  667. package/dist/ui-toolbar.js.map +1 -1
  668. package/dist/ui-transition.js +12 -11
  669. package/dist/ui-transition.js.map +1 -1
  670. package/dist/ui-tree-diagram.js +676 -197
  671. package/dist/ui-tree-diagram.js.map +1 -1
  672. package/dist/ui-tree.js +625 -0
  673. package/dist/ui-tree.js.map +1 -0
  674. package/dist/ui-video.js +13 -11
  675. package/dist/ui-video.js.map +1 -1
  676. package/dist/ui-visibility.js +26 -25
  677. package/dist/ui-visibility.js.map +1 -1
  678. package/dist/ui-zoom.js +79 -78
  679. package/dist/ui-zoom.js.map +1 -1
  680. package/dist/util/TopLayerTip.d.ts +28 -0
  681. package/dist/util/index.d.ts +5 -2
  682. package/dist/vocabulary/DefaultValues.d.ts +34 -0
  683. package/dist/vocabulary/SharedVocabulary.d.ts +4 -0
  684. package/dist/vocabulary/SharedVocabulary.es.d.ts +7 -0
  685. package/dist/vocabulary/ValueSets.d.ts +18 -0
  686. package/dist/vocabulary/Vocabulary.d.ts +1 -0
  687. package/dist/vocabulary/defaults.generated.d.ts +6 -0
  688. package/dist/vocabulary/index.d.ts +1 -0
  689. package/package.json +1 -1
  690. package/dist/MarkdownEngine-CbuT9Mjc.js.map +0 -1
  691. package/dist/PrefStore-CeaTtjTz.js.map +0 -1
  692. package/dist/UIButton-XkfGqgh6.js +0 -6
  693. package/dist/UIButton-XkfGqgh6.js.map +0 -1
  694. package/dist/UIInput-BUudZstW.js +0 -6
  695. package/dist/UIInput-BUudZstW.js.map +0 -1
  696. package/dist/UIKeys-DJF2TIKE.js.map +0 -1
  697. package/dist/UILabel-C1jy3Yl8.js +0 -6
  698. package/dist/UILabel-C1jy3Yl8.js.map +0 -1
  699. package/dist/UIMenu-Btd-8V3A.js +0 -42
  700. package/dist/UIMenu-Btd-8V3A.js.map +0 -1
  701. package/dist/UIRuntime-BBuehGly.js.map +0 -1
  702. package/dist/components.es-DmLzT-Bq.js.map +0 -1
  703. package/dist/crisp-CoZRRDuQ.js +0 -6
  704. package/dist/fruity-CQFYeRlh.js +0 -6
  705. package/dist/fruity-CQFYeRlh.js.map +0 -1
  706. package/dist/fruity.theme-BJcMiPl1.js.map +0 -1
  707. package/dist/glass-CAfW11kL.js +0 -6
  708. package/dist/glass-CAfW11kL.js.map +0 -1
  709. package/dist/glass.theme-DQcBbtCW.js +0 -6
  710. package/dist/glass.theme-DQcBbtCW.js.map +0 -1
  711. package/dist/matrix-CqA59hiF.js +0 -6
  712. package/dist/matrix.theme-jqQZjcq3.js.map +0 -1
  713. package/dist/midnight-BnoVOrhC.js +0 -6
  714. package/dist/paper-CynH8ZuT.js +0 -6
  715. package/dist/persist.types-CsZxS8TG.js +0 -9
  716. package/dist/persist.types-CsZxS8TG.js.map +0 -1
  717. package/dist/pop-D2i9V_rG.js +0 -6
  718. package/dist/spell-BFtLICm7.js +0 -6
  719. package/dist/spell.theme-B7AU7SQX.js.map +0 -1
  720. package/dist/styles.en-RLpYiO5_.js.map +0 -1
  721. package/dist/ui-theme-menu-DyKZygpV.js +0 -921
  722. package/dist/ui-theme-menu-DyKZygpV.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"ui-popup.js","names":["UIT.PopupTriggers","ref={(element) => this.box = element}","<Show when={this.heading}>\n <div class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </div>\n </Show>","this","part={this.partForName(\"header\")}","<div class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </div>","<div ref={(element) => this.box = element} class={this.rootClass} part={this.partForName(\"popup\")}>\n <Show when={this.heading}>\n <div class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </div>\n </Show>\n <Show when={this.label}>\n <div class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </div>\n </Show>\n <slot />\n </div>","<Show when={this.label}>\n <div class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </div>\n </Show>","part={this.partForName(\"content\")}","<div class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </div>","part={this.partForName(\"popup\")}","<Show when={this.heading}>\n <span class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </span>\n </Show>","<span class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </span>","<span class={this.rootClass} part={this.partForName(\"popup\")} popover={this.serverPopover}>\n <Show when={this.heading}>\n <span class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </span>\n </Show>\n <Show when={this.label}>\n <span class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </span>\n </Show>\n <slot />\n </span>","<Show when={this.label}>\n <span class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </span>\n </Show>","<span class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </span>","popover={this.serverPopover}","E.UIComponent","E.proto","E.protoMerged","E.whileConnected","E.untracked","E.on","E.derived","E.state","E.onChange","E.aria","E.Disclosure","E.after","_$createComponent","_$readShallow","UIT.HEADER","_$setAttribute","UIT.CONTENT","_$getOwner","UIT.WHITESPACE","__name","popupCSS","anchoredCSS","__publicField","HEADER","__decorateElement","PopupTrigger","__decoratorMetadata","PopupTriggers","__decoratorStart","WHITESPACE","__name$1","__runInitializers","AnimationLookup","CONTENT","ToggleCommands","__privateAdd","getOwner$1","popupVocabulary","UIPopup_default","UIPopup_anchored_default","_tmpl$","_tmpl$2","_tmpl$3","_tmpl$4","_onPopoverModeChanged_dec","_onPositionChanged_dec","_accessibleName_dec","_ariaRole_dec","_onPopupFocusOut_dec","_onPopupLeave_dec","_onPopupEnter_dec","_onTargetClick_dec","_onExpandedChanged_dec","_onTargetChanged_dec","_ariaElement_dec","_targetElement_dec","_onCommand_dec","_onToggle_dec","_show_dec","_watchPlacement_dec","_elementSetup_dec","_vocabulary_dec","_a","_init","_ariaElement","_UIPopup","UIComponent","proto","protoMerged","whileConnected","untracked","on","derived","state","onChange","aria","Disclosure","event","UI","visible","originalEvent","delay","after","box","keyframes","animation","animations","each","target","anchor","domElement","CLOSED","action","property","id","DEFAULT_TRIGGER","isReady","trigger","ID_PREFIX","listeners","options","isClick","events","element","unrelate","CONTROLS","DESCRIBED_BY","isInteractive","isVisible","token","HOVER_DELAY_TOKEN","match","DURATION","next","POSITION_AREAS","position","DEFAULT_POSITION","mode","SHOWN_CLASS","isServer","_self$","_el$","_el$3","_el$5","ref","insert","createComponent","Show","_el$2","effect","readShallow","className","_p$","setAttribute","_el$4","t","_self$2","_el$6","_el$8","_el$10","_el$7","_el$9","a","value","NodeType","CONTENTS","root","style","names","name","reflected","ids","relation","rest","elements","attribute","UIPopup"],"sources":["../src/components/ui-popup/UIPopup.en.ts","../src/components/ui-popup/UIPopup.css?inline","../src/components/ui-popup/UIPopup.tsx","../src/components/ui-popup/index.ts"],"sourcesContent":["/**\n * Every name `<ui-popup>` uses: tag, attributes (kind + allowed values), events, slots, parts, states, texts.\n * Schema: `E.ComponentVocabulary` (`spell/ui/vocabulary`).\n * - Pure data: node imports it (`yarn site:data`, `yarn gen:root`), so `spell/ui/core` for types only,\n * `UIT` by value straight from `components.types`.\n * - Class words come out through `ClassBuilder`, in Fomantic's grammar:\n * `<ui-popup size=\"small\" inverted wide=\"very\">` => `ui small inverted very wide popup`.\n * The element adds the `position` words before the noun (`ui inverted bottom left popup`),\n * the words Fomantic's script added.\n * - `visible`, Fomantic's shown-popup class, is the element's own while it shows (the shared `visible` / `hidden`),\n * so static markup and the element share one sheet.\n * - A popup OWNS the `header` and `content` parts:\n * slotted `<ui-header>` / `<ui-content>` get `:state(in-popup)` and style themselves from `UIParts.css`.\n * - `target` is a PROPERTY (an element); first paint never needs it --\n * `for` or the previous sibling carry what markup must say.\n */\n\nimport type { E } from \"spell/ui/core\"\nimport * as UIT from \"spell/ui/components/components.types\"\n\n/****************\n * ### `<ui-popup>`\n * A popup: a popover DOM element anchored to its target, holding `<div class=\"ui ... popup\" part=\"popup\">`.\n ****************/\nexport const popupVocabulary = {\n tag: \"ui-popup\",\n topics: [\"popups\", \"overlays\", \"feedback\", \"modules\"],\n aka: [\"tooltip\", \"popover\", \"hint\", \"hover card\", \"info bubble\"],\n noun: \"popup\",\n description: \"A popup displays additional information on top of a page.\",\n attributes: [\n {\n name: \"size\",\n group: \"appearance\",\n kind: \"size\",\n description: \"Text size, `mini` ... `massive`; `medium` is the default.\"\n },\n {\n name: \"color\",\n group: \"appearance\",\n kind: \"color\",\n description: \"Hue: fills the popup (and its arrow), with a readable text colour.\"\n },\n {\n name: \"appearance\",\n group: \"appearance\",\n kind: \"multiple\",\n values: [\"basic\"],\n // each word draws itself: no key after it\n classes: {},\n replaces: [{ from: \"basic\", value: \"basic\" }],\n description: \"The look: `basic`, no pointing arrow. Old name: `basic`.\"\n },\n {\n name: \"fixed\",\n group: \"layout\",\n kind: \"keyOnly\",\n description: \"Always its maximum width (`wide` / `very wide` widen it).\"\n },\n {\n name: \"flowing\",\n group: \"appearance\",\n kind: \"keyOnly\",\n description: \"No maximum width: as wide as its content, e.g. a grid.\"\n },\n { name: \"fluid\", group: \"layout\", kind: \"keyOnly\", description: \"As wide as its target.\" },\n {\n name: \"inverted\",\n group: \"appearance\",\n kind: \"keyOnly\",\n description: \"The opposite scheme: dark on a light page.\"\n },\n { name: \"loading\", group: \"states\", kind: \"keyOnly\", description: \"Busy: a spinner over faded content.\" },\n {\n name: \"wide\",\n group: \"layout\",\n kind: \"keyOrValueAndKey\",\n values: [\"very\"],\n description: 'A wider maximum width; `wide=\"very\"` wider still (`very wide`).'\n },\n {\n name: \"position\",\n group: \"layout\",\n kind: \"enum\",\n values: \"positions\",\n default: \"top left\",\n description:\n \"Where it sits against its target: `top left` (default) ... `right center`, `left top` ... `right bottom` \" +\n \"(beside, lined up with its top / bottom edge). It flips to the other \" +\n \"side when there's no room.\"\n },\n {\n name: \"open-on\",\n group: \"appearance\",\n kind: \"enum\",\n values: UIT.PopupTriggers,\n default: UIT.PopupTrigger.hover,\n description:\n \"What opens it: `hover` (also keyboard focus), `focus`, `click` (toggles; a non-modal dialog), or \" +\n \"`manual` (only `visible`).\"\n },\n {\n name: \"for\",\n group: \"appearance\",\n kind: \"string\",\n property: \"htmlFor\",\n description: \"Id of the target, in the popup's own tree; without it, the previous element sibling.\"\n },\n {\n name: \"heading\",\n replaces: [\"header\"],\n group: \"name\",\n kind: \"string\",\n description:\n \"Shorthand for a header line (Fomantic's `title`); a slotted `<ui-header>` is the rich version. Its old name was `header`.\"\n },\n {\n name: \"label\",\n group: \"content\",\n kind: \"string\",\n replaces: [\"content\"],\n description:\n \"Shorthand for the text (Fomantic's `content`); slotted content is the rich version. Old name: `content`.\"\n },\n {\n name: \"hoverable\",\n group: \"behaviour\",\n kind: \"boolean\",\n default: true,\n description:\n \"`hover`: the popup stays open while the pointer is over it, so it can be reached and its text read or \" +\n \"selected -- on by default, as WCAG 1.4.13 (Content on Hover or Focus) asks for. \" +\n '`hoverable=\"false\"` is Fomantic\\'s `hoverable: false` (its default): it closes as the pointer leaves ' +\n \"the target, after `hide-delay`.\"\n },\n {\n name: \"show-delay\",\n group: \"behaviour\",\n kind: \"number\",\n default: 50,\n description: \"`hover`: ms before it shows; not written, the page's `--ui-hover-delay` (800ms by default).\"\n },\n {\n name: \"hide-delay\",\n group: \"appearance\",\n kind: \"number\",\n default: 70,\n description: \"`hover`: ms before it hides.\"\n },\n {\n name: \"target\",\n group: \"behaviour\",\n kind: \"json\",\n reflect: false,\n description: \"The target as a PROPERTY (an `Element`); wins over `for`.\"\n }\n ],\n events: [\n {\n name: \"ui-opening\",\n detail: \"{ visible: true, originalEvent?: Event }\",\n cancelable: true,\n description:\n \"About to show for a person's action (the trigger, an invoker command); `preventDefault()` keeps it hidden.\"\n },\n {\n name: \"ui-closing\",\n detail: \"{ visible: false, originalEvent?: Event }\",\n cancelable: true,\n description:\n \"About to hide; `preventDefault()` keeps it shown. NOT cancelable in effect when the browser already \" +\n \"dismissed a `hint` popover (Escape, a click elsewhere).\"\n }\n ],\n slots: [{ name: \"\", description: \"Content: text, `<ui-header>` / `<ui-content>` parts, a grid, controls.\" }],\n parts: [\n { name: \"popup\", description: \"The popup box (its arrow is `::before`).\" },\n { name: \"header\", description: \"The `header` shorthand.\" },\n { name: \"content\", description: \"The `content` shorthand.\" }\n ],\n states: [{ name: \"fluid\", description: \"As wide as its target (`fluid`).\" }],\n texts: [],\n ownsParts: [\"header\", \"content\"]\n} as const satisfies E.ComponentVocabulary\n","/*\n * `<ui-popup>`: port of Fomantic's `popup.less` + `popup.variables` (the CSS-only `[data-tooltip]` rules live in\n * `native.css`, a page sheet: they style light-DOM markup).\n * - Shadow markup contract (class grammar; a popup has no better element than `<div>`):\n * `<div class=\"ui [size] [color] [keyOnly ...] [very] [wide] popup [position]\" part=\"popup\">` holding, in order,\n * `<div class=\"header\" part=\"header\">` (the `header` shorthand),\n * `<div class=\"content\" part=\"content\">` (the `content` shorthand) and the default `<slot>`.\n * The position words (`top left` ... `right center`) come before the noun (the words Fomantic's script added);\n * `visible` while open.\n * - The DOM element is the positioned box: a popover (`popover=\"hint\"` for hover / focus popups where supported,\n * else `manual`) in the top layer, anchored to its target. The element sets on it, inline:\n * - `position-anchor`: the target's `anchor-name` (a per-instance dashed ident it adds to the target's inline\n * `anchor-name` list), or `auto` -- the implicit anchor `showPopover({ source })` sets -- when the target has\n * no box of its own (`display: contents`, e.g. `<ui-icon>`, `<ui-label>`): it's then anchored to the\n * target's first shadow box, which a tree-scoped `anchor-name` can't name across the shadow boundary\n * - `position-area`: from `position` (`top left` => `top span-right` ...)\n * - this sheet adds `position-try-fallbacks: flip-block, flip-inline` (no JS positioning,\n * ever) and `container-type: anchored`, so the arrow and the gap follow a flip where anchored queries exist\n * - Distance: Fomantic's margin on the popup box (`.ui.top.popup { margin-bottom }`):\n * the DOM element shrink-wraps it, so the margin is the gap to the target.\n * - The inner box's `position: absolute` / `display: none` are STATIC-markup rules; inside the shadow root the\n * box is always a block and the DOM element's popover state decides visibility.\n * - Motion: the box scales and fades in from `@starting-style` and out while the DOM element's `display` / `overlay`\n * transition (`allow-discrete`) keeps it in the top layer; `reset.css` shortens it under reduced motion.\n * - Colours: `color` remaps (`colors.css`) fill the box and arrow with `--ui-color` and write\n * `--ui-color-on`; the arrow's edge takes `--ui-color` too, so it disappears into a coloured box (no per-hue\n * rules). Uncoloured, the arrow's edge is the box's border colour (`--ui-popup-border-color`), unless\n * `--ui-popup-arrow-edge` says otherwise: a theme's rim runs on round the arrow (Owen, 2026-10-25: \"Arrow tip\n * border doesn't match shading on tooltip\"). `inverted` swaps in the opposite scheme's ink, and a coloured inverted popup the hue's `-inverted`\n * variant (Fomantic's \"light\" hue). The DOM element resets the remap and `--ui-scale`, so a popup opened from inside\n * a red message or a large button isn't red or large.\n * - Public tokens (`--ui-popup-*`, the theming surface) are NEVER declared here: the token block reads each\n * through a private alias, `--_ui-popup-radius: var(--ui-popup-radius, var(--ui-radius))` (the duration on the\n * DOM element, which transitions too), and every rule reads the alias, `UIPopup.anchored.css` included.\n * So a value set on `:root`, an ancestor, the DOM element, `::part(popup)` or in the app stylesheet reaches the box\n * (`notes/theming.md` \"Component tokens\"). `wide` / `very wide` swap the max width for `--ui-popup-wide-width` /\n * `--ui-popup-very-wide-width`, back to the base on phones.\n * - OWNER side: slotted `<ui-header>` / `<ui-content>` style themselves from `UIParts.css` (context `in-popup`),\n * reading the aliases `--_ui-popup-header-font-size` / `--_ui-popup-header-distance`, declared on every root.\n * - NOTE: left out, on purpose:\n * - `.ui.invisible.popup` / `.ui.animating.popup`: script states the popover replaces\n * - the nested-grid coupling's `rem` margins: `.ui.popup > .ui.grid` gets the same inset in `em`\n * - Fomantic's per-position arrow BACKGROUND variables (all the same colour in the default theme)\n */\n\n@layer ui.components.popup.types, ui.components.popup.content, ui.components.popup.variations, ui.components.popup.states;\n\n/* Breakpoints (`@custom-media`), inlined at build time. */\n@import \"../../styles/media.css\";\n\n/*******************************\n Popup\n*******************************/\n\n@layer ui.components.popup.types {\n /* DOM element: the popover in the top layer, shrink-wrapped around the box; the UA popover look reset. */\n :host {\n --ui-color: initial;\n --ui-color-text: initial;\n --ui-color-header: initial;\n --ui-color-border: initial;\n --ui-color-background: initial;\n --ui-color-inverted: initial;\n --ui-color-on: initial;\n --ui-color-inverted-on: initial;\n --ui-scale: initial;\n --_ui-popup-duration: var(--ui-popup-duration, var(--ui-duration-normal));\n position: absolute;\n inset: auto;\n z-index: var(--ui-z-popup);\n display: block;\n box-sizing: border-box;\n width: max-content;\n height: max-content;\n margin: 0;\n padding: 0;\n overflow: visible;\n border: 0;\n background: transparent;\n color: inherit;\n position-try-fallbacks: flip-block, flip-inline;\n container-type: anchored;\n transition-property: display, overlay;\n transition-duration: var(--_ui-popup-duration);\n transition-behavior: allow-discrete;\n }\n :host(:not(:popover-open)) {\n display: none;\n }\n :host(:state(fluid)) {\n width: anchor-size(width);\n }\n\n /* Tokens: one private alias per `popup.variables` entry that still matters, from the global tokens. */\n .ui.popup {\n --_ui-popup-background: var(--ui-popup-background, var(--ui-surface));\n --_ui-popup-color: var(--ui-popup-color, var(--ui-text-color));\n --_ui-popup-border-color: var(--ui-popup-border-color, var(--ui-border-color-strong));\n --_ui-popup-shadow: var(--ui-popup-shadow, var(--ui-shadow-floating));\n --_ui-popup-radius: var(--ui-popup-radius, var(--ui-radius));\n --_ui-popup-padding: var(--ui-popup-padding, 0.833em 1em);\n --_ui-popup-max-width: var(--ui-popup-max-width, 250px);\n --_ui-popup-wide-width: var(--ui-popup-wide-width, 350px);\n --_ui-popup-very-wide-width: var(--ui-popup-very-wide-width, 550px);\n --_ui-popup-arrow-size: var(--ui-popup-arrow-size, 0.71428em);\n --_ui-popup-arrow-edge-distance: var(--ui-popup-arrow-edge-distance, 1em);\n --_ui-popup-arrow-offset: var(--ui-popup-arrow-offset, calc(var(--_ui-popup-arrow-size) / -2 + 0.05em));\n /* the box's own rim by default, so a themed rim (a glass theme's white one) runs on round the arrow */\n --_ui-popup-arrow-edge: var(--ui-popup-arrow-edge, var(--_ui-popup-border-color));\n --_ui-popup-distance: var(--ui-popup-distance, var(--_ui-popup-arrow-size));\n --_ui-popup-inverted-background: var(--ui-popup-inverted-background, var(--ui-ink));\n --_ui-popup-inverted-color: var(--ui-popup-inverted-color, var(--ui-surface));\n --_ui-popup-loading-opacity: var(--ui-popup-loading-opacity, 0.3);\n /* Also declared on `:host` (which transitions too); static markup has no shadow host, so the box needs its own. */\n --_ui-popup-duration: var(--ui-popup-duration, var(--ui-duration-normal));\n /* ## Owner tokens (`UIParts.css`): declared on every root. */\n --_ui-popup-header-font-size: var(--ui-popup-header-font-size, 1.14285em);\n --_ui-popup-header-distance: var(--ui-popup-header-distance, 0.5em);\n /* Arrow placement, set per position below. */\n --_popup-arrow-shadow: 1px 1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(calc(100% + 2px) -5px, calc(100% + 2px) calc(100% + 2px), -5px calc(100% + 2px));\n --_popup-arrow-edge: var(--ui-color, var(--_ui-popup-arrow-edge));\n position: absolute;\n top: 0;\n right: 0;\n z-index: var(--ui-z-popup);\n box-sizing: border-box;\n display: none;\n min-width: min-content;\n max-width: var(--_ui-popup-max-width);\n margin: 0;\n padding: var(--_ui-popup-padding);\n border: var(--ui-border-width) solid var(--ui-color, var(--_ui-popup-border-color));\n border-radius: var(--_ui-popup-radius);\n background: var(--ui-color, var(--_ui-popup-background));\n box-shadow: var(--_ui-popup-shadow);\n color: var(--ui-color-on, var(--_ui-popup-color));\n font-family: var(--ui-font-family);\n font-size: calc(var(--ui-font-size) * var(--ui-scale, 1));\n font-style: normal;\n font-weight: var(--ui-font-weight-normal);\n line-height: var(--ui-line-height);\n text-align: start;\n }\n\n /* Inside the shadow root: always a block in flow; the DOM element decides whether it shows. */\n :host > .ui.popup {\n position: relative;\n top: auto;\n right: auto;\n display: block;\n opacity: 1;\n transform: none;\n transition:\n opacity var(--_ui-popup-duration) var(--ui-ease),\n transform var(--_ui-popup-duration) var(--ui-ease);\n }\n :host(:not(:popover-open)) > .ui.popup {\n opacity: 0;\n transform: scale(0.8);\n }\n @starting-style {\n :host(:popover-open) > .ui.popup {\n opacity: 0;\n transform: scale(0.8);\n }\n }\n\n /* Arrow: a rotated square under the edge facing the target. */\n .ui.popup::before {\n content: \"\";\n position: absolute;\n z-index: 1;\n width: var(--_ui-popup-arrow-size);\n height: var(--_ui-popup-arrow-size);\n background: inherit;\n box-shadow: var(--_popup-arrow-shadow);\n /*\n * only the triangle OUTSIDE the box, and a hair over its edge to cover the box's rim: the half inside it doubled a see-through fill (a theme's glass) into a\n * darker diamond over the text (Owen, 2026-10-25: \"clip the triangle, make opacity match the text\")\n */\n clip-path: var(--_popup-arrow-clip, none);\n transform: rotate(45deg);\n }\n}\n\n/*******************************\n Content\n*******************************/\n\n@layer ui.components.popup.content {\n /* Header (the shorthand, or static `.header`); a block even as a server render's `<span>` (`UIPopup`). */\n .ui.popup > .header {\n display: block;\n padding: 0;\n font-family: var(--ui-font-family-heading);\n font-size: var(--_ui-popup-header-font-size);\n font-weight: var(--ui-font-weight-bold);\n line-height: 1.2;\n }\n .ui.popup > .header + .content {\n padding-top: var(--_ui-popup-header-distance);\n }\n /* The `content` shorthand: a block, for the same reason. */\n .ui.popup > .content {\n display: block;\n }\n\n /* Coupling: a grid right inside a popup sits flush with its padding. */\n .ui.popup > .ui.grid:not(.padded),\n .ui.popup > ::slotted(ui-grid:not([padding])) {\n width: calc(100% + 2em);\n margin: -0.7em -1em;\n }\n}\n\n/*******************************\n Variations\n*******************************/\n\n@layer ui.components.popup.variations {\n /* ## Position: the gap on the side facing the target, and the arrow on that edge. */\n .ui.top.popup {\n margin: 0 0 var(--_ui-popup-distance);\n }\n .ui.bottom.popup {\n margin: var(--_ui-popup-distance) 0 0;\n --_popup-arrow-shadow: -1px -1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-2px -2px, calc(100% + 5px) -2px, -2px calc(100% + 5px));\n }\n .ui.left.center.popup {\n margin: 0 var(--_ui-popup-distance) 0 0;\n transform-origin: right 50%;\n --_popup-arrow-shadow: 1px -1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-5px -2px, calc(100% + 2px) -2px, calc(100% + 2px) calc(100% + 5px));\n }\n .ui.right.center.popup {\n margin: 0 0 0 var(--_ui-popup-distance);\n transform-origin: left 50%;\n --_popup-arrow-shadow: -1px 1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-2px -5px, calc(100% + 5px) calc(100% + 2px), -2px calc(100% + 2px));\n }\n .ui.top.left.popup {\n transform-origin: left bottom;\n }\n .ui.top.center.popup {\n transform-origin: center bottom;\n }\n .ui.top.right.popup {\n transform-origin: right bottom;\n }\n .ui.bottom.left.popup {\n transform-origin: left top;\n }\n .ui.bottom.center.popup {\n transform-origin: center top;\n }\n .ui.bottom.right.popup {\n transform-origin: right top;\n }\n\n /* Below */\n .ui.bottom.center.popup::before {\n inset: var(--_ui-popup-arrow-offset) auto auto 50%;\n margin-left: var(--_ui-popup-arrow-offset);\n }\n .ui.bottom.left.popup::before {\n inset: var(--_ui-popup-arrow-offset) auto auto var(--_ui-popup-arrow-edge-distance);\n }\n .ui.bottom.right.popup::before {\n inset: var(--_ui-popup-arrow-offset) var(--_ui-popup-arrow-edge-distance) auto auto;\n }\n\n /* Above */\n .ui.top.center.popup::before {\n inset: auto auto var(--_ui-popup-arrow-offset) 50%;\n margin-left: var(--_ui-popup-arrow-offset);\n }\n .ui.top.left.popup::before {\n inset: auto auto var(--_ui-popup-arrow-offset) var(--_ui-popup-arrow-edge-distance);\n }\n .ui.top.right.popup::before {\n inset: auto var(--_ui-popup-arrow-edge-distance) var(--_ui-popup-arrow-offset) auto;\n }\n\n /* Beside */\n .ui.left.center.popup::before {\n inset: 50% var(--_ui-popup-arrow-offset) auto auto;\n margin-top: var(--_ui-popup-arrow-offset);\n }\n .ui.right.center.popup::before {\n inset: 50% auto auto var(--_ui-popup-arrow-offset);\n margin-top: var(--_ui-popup-arrow-offset);\n }\n\n /*\n * Beside, lined up with the target's top / bottom edge (ours, not Fomantic's). Class words have no order,\n * so `left top` carries the same words as `top left`: these match the PHRASE (`[class*=\"left top\"]`,\n * Fomantic's `very wide` idiom) plus the side word, which ties `.ui.top.left.popup` on specificity and wins by coming\n * later. They set everything the above / below rules set (margin, arrow edge and inset, transform origin).\n */\n .ui[class*=\"left top\"].left.popup,\n .ui[class*=\"left bottom\"].left.popup {\n margin: 0 var(--_ui-popup-distance) 0 0;\n --_popup-arrow-shadow: 1px -1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-5px -2px, calc(100% + 2px) -2px, calc(100% + 2px) calc(100% + 5px));\n }\n .ui[class*=\"right top\"].right.popup,\n .ui[class*=\"right bottom\"].right.popup {\n margin: 0 0 0 var(--_ui-popup-distance);\n --_popup-arrow-shadow: -1px 1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-2px -5px, calc(100% + 5px) calc(100% + 2px), -2px calc(100% + 2px));\n }\n .ui[class*=\"left top\"].left.popup {\n transform-origin: right top;\n }\n .ui[class*=\"left bottom\"].left.popup {\n transform-origin: right bottom;\n }\n .ui[class*=\"right top\"].right.popup {\n transform-origin: left top;\n }\n .ui[class*=\"right bottom\"].right.popup {\n transform-origin: left bottom;\n }\n .ui[class*=\"left top\"].left.popup::before {\n inset: var(--_ui-popup-arrow-edge-distance) var(--_ui-popup-arrow-offset) auto auto;\n }\n .ui[class*=\"left bottom\"].left.popup::before {\n inset: auto var(--_ui-popup-arrow-offset) var(--_ui-popup-arrow-edge-distance) auto;\n }\n .ui[class*=\"right top\"].right.popup::before {\n inset: var(--_ui-popup-arrow-edge-distance) auto auto var(--_ui-popup-arrow-offset);\n }\n .ui[class*=\"right bottom\"].right.popup::before {\n inset: auto auto var(--_ui-popup-arrow-edge-distance) var(--_ui-popup-arrow-offset);\n }\n\n /* Flipped by `position-try-fallbacks`: see `UIPopup.anchored.css`. */\n\n /* ## Basic: no arrow. */\n .ui.basic.popup::before {\n display: none;\n }\n\n /* ## Widths */\n .ui.fixed.popup {\n width: var(--_ui-popup-max-width);\n }\n .ui.wide.popup {\n --_ui-popup-max-width: var(--_ui-popup-wide-width);\n }\n .ui[class*=\"very wide\"].popup {\n --_ui-popup-max-width: var(--_ui-popup-very-wide-width);\n }\n @media (--ui-mobile) {\n .ui.wide.popup,\n .ui[class*=\"very wide\"].popup {\n --_ui-popup-max-width: var(--ui-popup-max-width, 250px);\n }\n }\n .ui.fluid.popup {\n width: 100%;\n max-width: none;\n }\n .ui.flowing.popup {\n max-width: none;\n }\n /*\n * A slotted grid is a size container (`UIGrid.css`), so its inline size ignores its content and a popup sized\n * BY its content collapses to a sliver. Drop the containment here: this outer tree's `::slotted()` beats the\n * grid's own `:host` rule. Its stackable / device ranges then follow the nearest container above.\n */\n .ui.flowing.popup > ::slotted(ui-grid) {\n container-type: normal;\n }\n\n /* ## Inverted: the opposite scheme's ink; a coloured one takes the hue's light variant. */\n .ui.inverted.popup {\n --ui-inverted: 1;\n --_popup-arrow-shadow: none;\n border-color: transparent;\n background: var(--ui-color-inverted, var(--_ui-popup-inverted-background));\n box-shadow: none;\n color: var(--ui-color-inverted-on, var(--_ui-popup-inverted-color));\n }\n .ui.inverted.popup > .header {\n background: none;\n color: inherit;\n }\n}\n\n/*******************************\n States\n*******************************/\n\n@layer ui.components.popup.states {\n /* Shown (static markup; on the element, its DOM element is the popover). */\n .ui.visible.popup {\n display: block;\n }\n\n /*\n * Static markup whose box IS the popover (a server render's, `spell/ui/static`): hidden until open,\n * as the DOM element is.\n * Never matches inside the element's shadow root, where the DOM element carries `popover`.\n */\n .ui.popup[popover]:not(:popover-open) {\n display: none;\n }\n\n /* Loading: faded content under a spinner; not interactive. */\n .ui.loading.popup {\n cursor: default;\n pointer-events: none;\n user-select: none;\n }\n .ui.loading.popup > *,\n .ui.loading.popup > ::slotted(*) {\n opacity: var(--_ui-popup-loading-opacity);\n }\n .ui.loading.popup::after {\n content: \"\";\n position: absolute;\n top: 50%;\n left: 50%;\n z-index: 2;\n width: 2em;\n height: 2em;\n margin: -1em 0 0 -1em;\n border: 0.2em solid oklch(from currentColor l c h / 0.15);\n border-top-color: currentColor;\n border-radius: var(--ui-radius-circle);\n animation: ui-popup-spin 0.6s linear infinite;\n }\n}\n\n/* Loader spin. */\n@keyframes ui-popup-spin {\n to {\n transform: rotate(360deg);\n }\n}\n","import { Show } from \"solid-js\"\nimport { isServer, type JSX } from \"@solidjs/web\"\n\nimport { E, UI, UIT } from \"spell/ui/core\"\nimport { popupVocabulary } from \"./UIPopup.en\"\n\nimport popupCSS from \"./UIPopup.css?inline\"\nimport anchoredCSS from \"./UIPopup.anchored.css?raw\"\n\n/****************\n * ### `UIPopup`\n * The component behind `<ui-popup>`: a popup anchored to a TARGET.\n * The DOM element is a popover in the top layer, placed by CSS anchor positioning only (`UIPopup.css`),\n * holding `<div class=\"ui … popup [position]\" part=\"popup\">`.\n *\n * - Its target: the `target` property, else the element `for` names (in the popup's own tree),\n * else the previous element sibling (Fomantic's `inline` markup: a popup right after what opens it).\n *\n * - `open-on`:\n * - `hover` (with `show-delay` / `hide-delay`, and on keyboard focus too)\n * - `focus`\n * - `click` (toggles)\n * - `manual` (only `visible`)\n * - A hovered popup stays open while the pointer is over it (WCAG 1.4.13),\n * unlike Fomantic's default `hoverable: false`.\n * `hoverable=\"false\"` gives Fomantic's behaviour back:\n * it hides as the pointer leaves the target, after `hide-delay`.\n *\n * - Invoker commands (`<button commandfor=\"id\" command=\"--toggle\">`, `UIT.ToggleCommands`)\n * are a person's actions too: the popup opens at ITS target, whichever button sent the command.\n *\n * - Shown by the shared `visible` / `hidden` (`UIComponent`, \"Shown or hidden\"), starting hidden.\n * - Controlled: a person's cancelable `ui-opening` / `ui-closing` come first.\n * - Escape and outside clicks come from `UI.overlays` (kind `popover`; the target counts as inside).\n *\n * - Its popover mode: `hint` for hover / focus popups when `UI.browser.supports.popoverHint`\n * (they don't close an open dropdown's menu), else `manual`.\n * - Click and manual popups are always `manual`: `auto`'s light dismiss would skip the cancelable `ui-closing`.\n * - When the browser dismisses a `hint` popover itself,\n * the component follows (with a `ui-closing` that can no longer veto).\n *\n * - Accessibility, by `open-on`:\n * - `hover` / `focus` / `manual`: the DOM element is `role=tooltip`; the target is `aria-describedby` it\n * - `click`: the DOM element is `role=dialog` (non-modal, named by `header` or its `aria-label`);\n * the target gets `aria-haspopup=dialog`, `aria-expanded`, `aria-controls`\n * - the ARIA goes on the element that takes focus: a `delegatesFocus` target's (`<ui-button>`'s) first focusable,\n * through element reflection (`ariaDescribedByElements`) when that is in another tree.\n *\n * - SIDE EFFECTS on light DOM the popup doesn't own, undone when it unbinds:\n * - the target's inline `anchor-name` (a per-instance name ADDED to its list) and its ARIA attributes\n * - the DOM element's `popover`, `id`, and inline `position-anchor` / `position-area`.\n ****************/\nexport class UIPopup extends E.UIComponent<Vocabulary> {\n @E.proto static vocabulary = popupVocabulary\n @E.protoMerged static elementSetup = {\n styleSheets: { popup: popupCSS, \"popup-anchored\": anchoredCSS },\n cssStates: [\"fluid\"],\n // nothing inside needs focus delegated: a click on a tooltip's text must not jump to a link in it\n delegatesFocus: false,\n // `loading`: Fomantic's loader inside the popup\n loading: \"its own\",\n visible: \"hidden\",\n // the sheet's own transition is Fomantic's `scale`: faded in from 80%\n animation: \"scale\"\n } satisfies Partial<E.ElementSetup>\n\n ////////////////\n // ## Shown or hidden\n ////////////////\n\n /** Pending delayed show / hide. */\n private delayTimer?: E.CancelablePromise<unknown>\n\n /** This element's `UI.overlays` entry; `anchor` follows the target. */\n private readonly overlay: E.OverlayEntry = {\n element: this.domElement,\n kind: \"popover\",\n onDismiss: () => void this.requestVisible(false)\n }\n\n /** Shown or hidden, as `visible` (`isVisible`): `ui-opening` / `ui-closing` first. */\n readonly disclosure = new E.Disclosure({\n component: this,\n member: \"isVisible\",\n detail: (visible, originalEvent): UIT.PopupOpenDetail => ({ visible, originalEvent })\n })\n\n /** Show or hide, dispatching the cancelable `ui-opening` / `ui-closing` first; true when applied. */\n requestVisible(visible: boolean, originalEvent?: Event): boolean {\n this.delayTimer?.cancel()\n return this.disclosure.request(visible, originalEvent)\n }\n\n /** `requestVisible()` after `delay` ms (at once for `0`); a newer call replaces a pending one. */\n private schedule(visible: boolean, delay: number, originalEvent?: Event) {\n this.delayTimer?.cancel()\n if (delay <= 0) return void this.requestVisible(visible, originalEvent)\n this.delayTimer = E.after(delay / 1000, () => this.requestVisible(visible, originalEvent))\n }\n\n /**\n * `visible` changed (`UIComponent`'s hook): show or hide the popover; resolves once its transition has ended.\n * - Showing waits for a `ui-*` target to be ready:\n * it renders async, so its box (or `display: contents`) is only known then.\n * - `animation`:\n * - the family's own (`elementSetup.animation`): the sheet's transition (`UIPopup.css`)\n * - another one (the element's own `animation`): run on the popup box through `UI.transitions`\n * - `none`: at once\n */\n protected async onVisibleChange(visible: boolean, animation: UIT.Animation): Promise<void> {\n const box = this.box\n const keyframes = UIT.AnimationLookup.keyframesBeside(animation, this.elementSetup.animation)\n if (visible) {\n const target = this.targetElement as { ready?: Promise<void> } | undefined\n await target?.ready\n if (!this.isVisible || !this.isConnected) return\n this.show()\n if (keyframes && box) await UI.transitions.animate({ element: box, name: keyframes, direction: UIT.IN })\n return\n }\n if (keyframes && box) await UI.transitions.animate({ element: box, name: keyframes, direction: UIT.OUT })\n // shown again while the keyframes ran\n if (this.isVisible) return\n this.hide()\n const animations = [...this.domElement.getAnimations(), ...(box?.getAnimations() ?? [])]\n await Promise.allSettled(animations.map((each) => each.finished))\n }\n\n /**\n * Shown again when it comes back into the page while `visible`; hidden, quietly, when it leaves.\n * - Not on the first connect: `onVisibleChange()` runs once the popup first draws.\n */\n @E.whileConnected\n protected watchPlacement() {\n if (this.isVisible && this.isReady) this.show()\n return () => this.hide()\n }\n\n /** The popup box in the shadow root (`part=\"popup\"`). */\n private box?: HTMLElement\n\n /**\n * Show the popover against the target and register with `UI.overlays`.\n * - Anchor: the target's `anchor-name` when it has a box,\n * else the implicit anchor of `source` (see `UIPopup.css`).\n * - `source` also makes the target the popover's invoker, so Tab from it continues inside.\n * - A box other keyframes animated out (`hidden` on it) shows again first.\n */\n @E.untracked\n private show() {\n const { domElement } = this\n if (this.box) UI.transitions.reveal(this.box)\n const target = this.targetElement\n const anchor = target ? UIPopup.anchorBoxFor(target) : undefined\n domElement.popover ||= this.popoverMode\n domElement.style.setProperty(\"position-anchor\", anchor === target ? this.anchorName : anchor ? \"auto\" : \"none\")\n if (!domElement.matches(\":popover-open\")) {\n domElement.showPopover(anchor ? ({ source: anchor } as ShowPopoverOptions) : undefined)\n }\n this.overlay.anchor = target\n this.overlay.restoreFocus = this.isInteractive\n UI.overlays.open(this.overlay)\n }\n\n /** Hide the popover and leave `UI.overlays`. */\n private hide() {\n this.delayTimer?.cancel()\n if (this.domElement.matches(\":popover-open\")) this.domElement.hidePopover()\n UI.overlays.close(this.overlay)\n }\n\n /**\n * The popover's `toggle`: the browser closed it (a `hint` popover's light dismiss)\n * while the element thinks it's open -- follow, announcing a `ui-closing` that can't veto any more.\n */\n @E.on(\"toggle\")\n protected onToggle(event: Event) {\n if ((event as ToggleEvent).newState !== CLOSED || !this.domElement.isConnected) return\n this.disclosure.adopt(false, event)\n }\n\n /** An invoker command aimed at the DOM element (`ToggleCommands`). */\n @E.on(\"command\")\n protected onCommand(event: Event) {\n const action = UIT.ToggleCommands.action(event, this.isVisible)\n if (action) this.requestVisible(action === \"show\", event)\n }\n\n ////////////////\n // ## The target\n ////////////////\n\n /**\n * The target: `target` property, else `for`, else the previous element sibling; `undefined` when unbound.\n * - Not `target`: that's the attribute's getter, the property this reads first.\n */\n @E.derived\n get targetElement(): Element | undefined {\n if (!this.isConnected) return undefined\n const property = this.target\n if (UIPopup.isElement(property)) return property\n const id = this.for\n if (id) return (this.domElement.getRootNode() as Document | ShadowRoot).getElementById?.(id) ?? undefined\n return this.domElement.previousElementSibling ?? undefined\n }\n\n /** What opens it. */\n get trigger(): UIT.PopupTrigger {\n return this.openOn ?? DEFAULT_TRIGGER\n }\n\n /** A click popup: a non-modal dialog with interactive content, not a tooltip. */\n get isInteractive(): boolean {\n return this.trigger === UIT.PopupTrigger.click\n }\n\n /** Element carrying the target's ARIA (see class docs), while bound. */\n @E.state accessor ariaElement: Element | undefined = undefined\n\n /** Per-instance anchor name, from `UI.ids` on first bind. */\n private anchorName = \"\"\n\n /** Ready with a target: bind it for the trigger; the cleanup is `bind()`'s undo. */\n @E.onChange(\"isReady\", \"targetElement\", \"trigger\")\n protected onTargetChanged(isReady: boolean, target: Element | undefined, trigger: UIT.PopupTrigger) {\n return isReady && target ? this.bind(target, trigger) : undefined\n }\n\n /**\n * Listen to `target` for `trigger`, add the anchor name and the ARIA; returns the undo.\n * - SIDE EFFECTS: see class docs.\n */\n private bind(target: Element, trigger: UIT.PopupTrigger): () => void {\n const { domElement } = this\n this.anchorName ||= `--${UI.ids.next(ID_PREFIX)}`\n const listeners = new AbortController()\n const options = { signal: listeners.signal }\n const isClick = trigger === UIT.PopupTrigger.click\n // `HTMLElement`'s event map: an SVG target fires the same pointer / focus events\n const events = target as HTMLElement\n if (trigger === UIT.PopupTrigger.hover) {\n events.addEventListener(\"pointerenter\", this.onTargetEnter, options)\n events.addEventListener(\"pointerleave\", this.onTargetLeave, options)\n }\n if (trigger === UIT.PopupTrigger.hover || trigger === UIT.PopupTrigger.focus) {\n events.addEventListener(\"focusin\", this.onTargetFocus, options)\n events.addEventListener(\"focusout\", this.onTargetBlur, options)\n }\n if (isClick) events.addEventListener(\"click\", this.onTargetClick, options)\n UIPopup.addAnchorName(target, this.anchorName)\n UI.ids.ensure(domElement, ID_PREFIX)\n const element = UIPopup.ariaTargetFor(target)\n const unrelate = UIPopup.addAriaRelation({ element, relation: isClick ? CONTROLS : DESCRIBED_BY, domElement })\n if (isClick) element.setAttribute(\"aria-haspopup\", \"dialog\")\n this.ariaElement = element\n return () => {\n listeners.abort()\n this.delayTimer?.cancel()\n UIPopup.removeAnchorName(target, this.anchorName)\n unrelate()\n if (isClick) {\n element.removeAttribute(\"aria-haspopup\")\n element.removeAttribute(\"aria-expanded\")\n }\n this.ariaElement = undefined\n }\n }\n\n /**\n * A server render's binding: the target's ARIA, as `bind()` adds it, without listeners.\n * - SIDE EFFECTS: gives the DOM element (the render's parsed copy) an id, which its root keeps,\n * and sets the target's `aria-describedby` / `aria-controls` and `aria-haspopup`.\n * - No `aria-expanded`: a native invoker reports its popover's state itself.\n */\n private serverBind() {\n const target = this.targetElement\n if (!target) return\n const isInteractive = this.isInteractive\n UI.ids.ensure(this.domElement, ID_PREFIX)\n const element = UIPopup.ariaTargetFor(target)\n UIPopup.addAriaRelation({ element, relation: isInteractive ? CONTROLS : DESCRIBED_BY, domElement: this.domElement })\n if (isInteractive) element.setAttribute(\"aria-haspopup\", \"dialog\")\n }\n\n /** A click popup's target says whether it's shown (`aria-expanded`). */\n @E.onChange(\"ariaElement\", \"isInteractive\", \"isVisible\")\n protected onExpandedChanged(element: Element | undefined, isInteractive: boolean, isVisible: boolean) {\n if (element && isInteractive) element.setAttribute(\"aria-expanded\", String(isVisible))\n }\n\n /** Pointer onto the target (`hover`): show after `show-delay`, else the page's `--ui-hover-delay`. */\n private readonly onTargetEnter = (event: PointerEvent) => {\n this.schedule(true, this.hoverDelay, event)\n }\n\n /**\n * How long the pointer rests before it shows: its own `show-delay` when written, else the page's preference,\n * the `--ui-hover-delay` token (`styles.en.ts`'s `hoverDelay`), in `ms` or `s`; else `show-delay`'s default.\n */\n private get hoverDelay(): number {\n if (this.attributes[\"show-delay\"] !== null) return this.showDelay ?? 0\n const token = getComputedStyle(this.domElement).getPropertyValue(HOVER_DELAY_TOKEN).trim()\n const match = DURATION.exec(token)\n if (!match) return this.showDelay ?? 0\n return Number(match[1]) * (match[2] === \"s\" ? 1000 : 1)\n }\n\n /** Pointer off the target (`hover`): hide after `hide-delay`, unless it reaches the popup first. */\n private readonly onTargetLeave = (event: PointerEvent) => {\n this.schedule(false, this.hideDelay ?? 0, event)\n }\n\n /** Focus onto the target (`hover`, `focus`): show at once. */\n private readonly onTargetFocus = (event: FocusEvent) => {\n this.schedule(true, 0, event)\n }\n\n /** Focus off the target (`hover`, `focus`): hide, unless focus moved into the popup. */\n private readonly onTargetBlur = (event: FocusEvent) => {\n if (UI.focus.containsDeep(this.domElement, event.relatedTarget as Node | null)) return\n this.schedule(false, 0, event)\n }\n\n /** Click on the target (`click`): toggle. */\n @E.untracked\n private readonly onTargetClick = (event: MouseEvent) => {\n this.requestVisible(!this.isVisible, event)\n }\n\n ////////////////\n // ## The popup itself\n ////////////////\n\n /** Pointer onto the popup: keep a hovered popup open, unless `hoverable` is off (Fomantic's default). */\n @E.on(\"pointerenter\")\n protected onPopupEnter() {\n if (this.trigger !== UIT.PopupTrigger.hover) return\n if (this.hoverable !== false) this.delayTimer?.cancel()\n }\n\n /** Pointer off the popup: hide a hovered popup after `hide-delay`. */\n @E.on(\"pointerleave\")\n protected onPopupLeave(event: PointerEvent) {\n if (this.trigger === UIT.PopupTrigger.hover) this.schedule(false, this.hideDelay ?? 0, event)\n }\n\n /** Focus off the popup (`focus`): hide, unless it went back to the target. */\n @E.on(\"focusout\")\n protected onPopupFocusOut(event: FocusEvent) {\n if (this.trigger !== UIT.PopupTrigger.focus) return\n const next = event.relatedTarget as Node | null\n const target = this.targetElement\n if (UI.focus.containsDeep(this.domElement, next) || (target && next && UI.focus.containsDeep(target, next))) return\n this.schedule(false, 0, event)\n }\n\n ////////////////\n // ## The DOM element's role, name, position and popover\n ////////////////\n\n /** The DOM element is a dialog for a click popup, else a tooltip. */\n @E.aria(\"role\")\n protected get ariaRole(): string {\n return this.isInteractive ? \"dialog\" : \"tooltip\"\n }\n\n /** A click popup's dialog is named by `header`. */\n @E.aria(\"label\")\n protected get accessibleName(): string | undefined {\n return this.isInteractive ? this.heading : undefined\n }\n\n /** SIDE EFFECT: the DOM element's `position-area` follows `position`. */\n @E.onChange(\"position\", { writesDOMElement: true })\n protected onPositionChanged(position: string | undefined) {\n this.domElement.style.setProperty(\"position-area\", POSITION_AREAS[position ?? DEFAULT_POSITION])\n }\n\n /**\n * `popover` mode for the current trigger, see class docs.\n * - `manual` popups too stay `manual`:\n * the page decides, so several may be open at once (a `hint` closes the other hints).\n */\n private get popoverMode(): PopoverMode {\n const trigger = this.trigger\n const isHintable = trigger === UIT.PopupTrigger.hover || trigger === UIT.PopupTrigger.focus\n return isHintable && UI.browser.supports.popoverHint ? \"hint\" : \"manual\"\n }\n\n /**\n * Once ready, the DOM element's `popover` follows the trigger (`popoverMode`).\n * - Reads `popoverMode` HERE, not as a member of the effect: it reads `UI.browser`, which exists only once ready.\n */\n @E.onChange(\"isReady\", \"trigger\")\n protected onPopoverModeChanged(isReady: boolean) {\n if (!isReady) return\n const mode = this.popoverMode\n if (this.domElement.popover !== mode) this.domElement.popover = mode\n }\n\n /**\n * `popover` of the ROOT in a server render (`spell/ui/static`), where the root replaces the DOM element:\n * hidden until opened, in the HTML.\n * - `auto` for a click popup: light dismiss and Escape without JS, once something opens it (`popovertarget`).\n * - `manual` for the rest (`hint` isn't everywhere, and an unknown value means `manual`).\n */\n private get serverPopover(): PopoverMode {\n return this.isInteractive ? \"auto\" : \"manual\"\n }\n\n ////////////////\n // ## Classes and states\n ////////////////\n\n /**\n * The position words before the noun, then Fomantic's `visible` while shown: `ui top left visible popup`.\n * - After the position: a phrase rule (`[class*=\"left top\"]`) needs its words side by side.\n */\n protected get extraClass(): string | undefined {\n const position = this.position ?? DEFAULT_POSITION\n return this.isVisible ? `${position} ${SHOWN_CLASS}` : position\n }\n\n ////////////////\n // ## Rendering\n ////////////////\n\n /**\n * Adds the server render's target binding (`serverBind()`) to `UIComponent.onMount()`;\n * the role and name (`@aria`) and the position effect (`writesDOMElement`) write the DOM element there too.\n */\n onMount(): JSX.Element {\n if (isServer) this.serverBind()\n return super.onMount()\n }\n\n render(): JSX.Element {\n if (isServer) return this.serverMarkup()\n return (\n <div ref={(element) => (this.box = element)} class={this.rootClass} part={this.partForName(\"popup\")}>\n <Show when={this.heading}>\n <div class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </div>\n </Show>\n <Show when={this.label}>\n <div class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </div>\n </Show>\n <slot />\n </div>\n )\n }\n\n /**\n * The static markup of a server render (`spell/ui/static`), where the root replaces the DOM element:\n * - a popover itself (`serverPopover`): hidden until opened, in the HTML\n * - PHRASING content (`<span>`s): a popup often sits in running text, after a `<dfn>` or a button in a `<p>`,\n * where its DOM element was valid; a `<div>` would close the `<p>` when a browser parses the page\n */\n private serverMarkup(): JSX.Element {\n return (\n <span class={this.rootClass} part={this.partForName(\"popup\")} popover={this.serverPopover}>\n <Show when={this.heading}>\n <span class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </span>\n </Show>\n <Show when={this.label}>\n <span class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </span>\n </Show>\n <slot />\n </span>\n )\n }\n\n ////////////////\n // ## Targets\n ////////////////\n\n /**\n * `value` is an element: by node type, since a server render (`spell/ui/static`) has no `Element` global.\n * - STATIC: pure.\n */\n private static isElement(value: unknown): value is Element {\n return typeof value === \"object\" && value !== null && (value as Node).nodeType === E.NodeType.element\n }\n\n /**\n * The box to anchor to: `target`, or -- when it has none (`display: contents`) --\n * the first element of its shadow root, else its first child element.\n * - STATIC: needs no instance, only the target.\n */\n private static anchorBoxFor(target: Element): Element {\n if (getComputedStyle(target).display !== CONTENTS) return target\n return target.shadowRoot?.firstElementChild ?? target.firstElementChild ?? target\n }\n\n /**\n * The element that takes focus for `target`: a `delegatesFocus` DOM element's first focusable, else `target`.\n * - STATIC: needs no instance, only the target.\n */\n private static ariaTargetFor(target: Element): Element {\n const root = target.shadowRoot\n return (root?.delegatesFocus && UI.focus.first(root)) || target\n }\n\n ////////////////\n // ## Target markup: light DOM the popup doesn't own\n ////////////////\n\n /**\n * Add `name` to `element`'s inline `anchor-name` LIST:\n * several popups can share one target, and the page may name it too.\n * - STATIC: needs no instance; every popup bound to one target writes the same list.\n */\n private static addAnchorName(element: Element, name: string) {\n const style = (element as HTMLElement).style\n if (!style) return\n const names = UIPopup.anchorNamesIn(style)\n if (!names.includes(name)) style.setProperty(\"anchor-name\", [...names, name].join(\", \"))\n }\n\n /**\n * Remove `name` from `element`'s inline `anchor-name`; drops the property when none are left.\n * - STATIC: as `addAnchorName()`.\n */\n private static removeAnchorName(element: Element, name: string) {\n const style = (element as HTMLElement).style\n if (!style) return\n const names = UIPopup.anchorNamesIn(style).filter((each) => each !== name)\n if (names.length) style.setProperty(\"anchor-name\", names.join(\", \"))\n else style.removeProperty(\"anchor-name\")\n }\n\n /**\n * Names in `style`'s `anchor-name`.\n * - STATIC: pure.\n */\n private static anchorNamesIn(style: CSSStyleDeclaration): string[] {\n const value = style.getPropertyValue(\"anchor-name\").trim()\n return value && value !== \"none\" ? value.split(\",\").map((name) => name.trim()) : []\n }\n\n /**\n * Point `element`'s idref `relation` (`aria-describedby`, `aria-controls`) at `domElement` too,\n * ADDED to what's there; returns the undo.\n * - The attribute's token list when both share a tree,\n * else element reflection (`ariaDescribedByElements`), since an idref can't cross a shadow boundary.\n * - The undo keeps the way it was added:\n * by the time it runs the DOM element may be detached (its root is then itself),\n * which must not switch an attribute token list over to reflection.\n * - STATIC: needs no instance; a server render (`serverBind()`) and a live binding (`bind()`) share it.\n */\n private static addAriaRelation({ element, relation, domElement }: AriaRelationProps): () => void {\n const reflected = element as unknown as Record<string, Element[] | null>\n if (element.getRootNode() === domElement.getRootNode()) {\n const id = domElement.id\n const ids = UIPopup.idsIn(element, relation.attribute)\n if (!ids.includes(id)) element.setAttribute(relation.attribute, [...ids, id].join(\" \"))\n return () => {\n const rest = UIPopup.idsIn(element, relation.attribute).filter((each) => each !== id)\n if (rest.length) element.setAttribute(relation.attribute, rest.join(\" \"))\n else element.removeAttribute(relation.attribute)\n }\n }\n const elements = reflected[relation.property] ?? []\n if (!elements.includes(domElement)) reflected[relation.property] = [...elements, domElement]\n return () => {\n const rest = (reflected[relation.property] ?? []).filter((each) => each !== domElement)\n // `null`, not `undefined`: element reflection is a platform property, cleared by `null`\n reflected[relation.property] = rest.length ? rest : null\n }\n }\n\n /**\n * Ids in `element`'s `attribute`.\n * - STATIC: pure.\n */\n private static idsIn(element: Element, attribute: string): string[] {\n return (element.getAttribute(attribute) ?? \"\").split(UIT.WHITESPACE).filter(Boolean)\n }\n}\n\n/** The vocabulary's attribute getters, typed (see \"Attributes\" in `UIComponent`). */\nexport interface UIPopup extends E.AttributeValues<Vocabulary> {}\n\n/** The vocabulary type, for brevity. */\ntype Vocabulary = typeof popupVocabulary\n\n/** An idref ARIA relation: its attribute and its element-reflection property. */\ntype AriaRelation = {\n /** the idref attribute, e.g. `aria-describedby` */\n attribute: string\n /** its element-reflection property, e.g. `ariaDescribedByElements` (an idref can't cross a shadow boundary) */\n property: string\n}\n\n/** `showPopover()` options with `source` (not in every DOM lib yet). */\ntype ShowPopoverOptions = {\n /** the invoker: the implicit anchor, and where Tab continues from */\n source?: HTMLElement\n}\n\n/**\n * A `popover` value the component sets on its DOM element (or, in a server render, on its root):\n * - `auto`: light dismiss; only a server render's click popup\n * - `manual`: the page (or the component) decides; click and manual popups\n * - `hint`: hover / focus popups, where the browser has it (`UI.browser.supports.popoverHint`)\n */\ntype PopoverMode = \"auto\" | \"manual\" | \"hint\"\n\n/** What `UIPopup.addAriaRelation()` takes. */\ntype AriaRelationProps = {\n /** the element that takes focus for the target */\n element: Element\n /** which idref relation */\n relation: AriaRelation\n /** the popup's DOM element it points at */\n domElement: Element\n}\n\n////////////////\n// ## Constants\n////////////////\n\n/** Fomantic's default position: the popup's class words before its noun, `ui top left popup`. */\nconst DEFAULT_POSITION = \"top left\"\n\n/** Fomantic's class word of a shown popup. */\nconst SHOWN_CLASS = \"visible\"\n\n/** Fomantic's default trigger. */\nconst DEFAULT_TRIGGER: UIT.PopupTrigger = UIT.PopupTrigger.hover\n\n/** `UI.ids` prefix. */\nconst ID_PREFIX = \"ui-popup\"\n\n/** Tooltips describe their target. */\nconst DESCRIBED_BY: AriaRelation = { attribute: \"aria-describedby\", property: \"ariaDescribedByElements\" }\n\n/** Click popups are controlled by their target. */\nconst CONTROLS: AriaRelation = { attribute: \"aria-controls\", property: \"ariaControlsElements\" }\n\n/** `ToggleEvent.newState` of a popover the browser closed. */\nconst CLOSED = \"closed\"\n\n/** `display` of a target with no box of its own. */\nconst CONTENTS = \"contents\"\n\n/**\n * `position` => `position-area`: the popup on that side,\n * its edge lined up with the target's (`span-*` grows away from the named corner), or centred on it.\n */\nconst POSITION_AREAS: Readonly<Record<string, string>> = {\n \"top left\": \"top span-right\",\n \"top center\": \"top center\",\n \"top right\": \"top span-left\",\n \"bottom left\": \"bottom span-right\",\n \"bottom center\": \"bottom center\",\n \"bottom right\": \"bottom span-left\",\n \"left center\": \"left center\",\n \"right center\": \"right center\",\n \"left top\": \"left span-bottom\",\n \"left bottom\": \"left span-top\",\n \"right top\": \"right span-bottom\",\n \"right bottom\": \"right span-top\"\n}\n\n/** The page's hover-delay preference, a token (`styles.en.ts`'s `hoverDelay`). */\nconst HOVER_DELAY_TOKEN = \"--ui-hover-delay\"\n\n/** A CSS time: `800ms`, `2s`, `1.5s`. */\nconst DURATION = /^(\\d+(?:\\.\\d+)?)(ms|s)$/\n","/**\n * The popup family: defines `<ui-popup>` and exports its component, `UIPopup`.\n * - SIDE EFFECT: importing it defines `<ui-popup>`, the owner of the `header` and `content` parts.\n * - NOTE: the CSS-only tooltip (`data-tooltip`) needs no script: it's in `native.css`, a page sheet.\n * - Also the library's `spell/ui/ui-popup` entry (its size is in `notes/report.md`).\n */\n\nimport { UIPopup } from \"./UIPopup\"\n\nUIPopup.define()\n\nexport { UIPopup }\n"],"mappings":";;;;;AAwBA,IAAasD,KAAkB;CAC7B,KAAK;CACL,QAAQ;EAAC;EAAU;EAAY;EAAY;CAAS;CACpD,KAAK;EAAC;EAAW;EAAW;EAAQ;EAAc;CAAa;CAC/D,MAAM;CACN,aAAa;CACb,YAAY;EACV;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,aAAa;EACf;EACA;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,aAAa;EACf;EACA;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,QAAQ,CAAC,OAAO;GAEhB,SAAS,CAAC;GACV,UAAU,CAAC;IAAE,MAAM;IAAS,O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,GAEI3C,EAFJ2C,GAEW,gBAAelC,EAAtBgC,GAAA,IAFJE,GAE0B;CACnC,aAAa;EAAE,OAAO7C;EAAU,kBAAkBC;CAAY;CAC9D,WAAW,CAAC,OAAO;CAEnB,gBAAgB;CAEhB,SAAS;CACT,SAAS;CAET,WAAW;AACb,CAAA,CAAA,GAVeU,EAAAgC,GAAA,IAFJE,CAAA;AAAN,IAAM2F,KAAN3F,GAkkBDmD,KAAmB,YAGnBE,KAAc,WAGdvB,KAAAtE,EAAqD,OAGrDyE,IAAY,YAGZQ,KAA6B;CAAE,WAAW;CAAoB,UAAU;AAA0B,GAGlGD,IAAyB;CAAE,WAAW;CAAiB,UAAU;AAAuB,GAGxFd,KAAS,UAGTsD,KAAW,YAMX/B,KAAmD;CACvD,YAAY;CACZ,cAAc;CACd,aAAa;CACb,eAAe;CACf,iBAAiB;CACjB,gBAAgB;CAChB,eAAe;CACf,gBAAgB;CAChB,YAAY;CACZ,eAAe;CACf,aAAa;CACb,gBAAgB;AAClB,GAGMJ,KAAoB,oBAGpBE,KAAW;;;AC3pBjB4C,GAAQ,OAAO"}
1
+ {"version":3,"file":"ui-popup.js","names":["UIT.PopupTriggers","ref={(element) => this.box = element}","<Show when={this.heading}>\n <div class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </div>\n </Show>","this","part={this.partForName(\"header\")}","<div class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </div>","<div ref={(element) => this.box = element} class={this.rootClass} part={this.partForName(\"popup\")}>\n <Show when={this.heading}>\n <div class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </div>\n </Show>\n <Show when={this.label}>\n <div class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </div>\n </Show>\n <slot />\n </div>","<Show when={this.label}>\n <div class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </div>\n </Show>","part={this.partForName(\"content\")}","<div class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </div>","part={this.partForName(\"popup\")}","<Show when={this.heading}>\n <span class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </span>\n </Show>","<span class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </span>","<span class={this.rootClass} part={this.partForName(\"popup\")} popover={this.serverPopover}>\n <Show when={this.heading}>\n <span class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </span>\n </Show>\n <Show when={this.label}>\n <span class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </span>\n </Show>\n <slot />\n </span>","<Show when={this.label}>\n <span class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </span>\n </Show>","<span class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </span>","popover={this.serverPopover}","E.UIComponent","E.proto","E.protoMerged","E.whileConnected","E.untracked","E.state","E.onChange","E.on","E.derived","E.aria","E.Disclosure","E.after","_$createComponent","_$readShallow","UIT.HEADER","_$setAttribute","UIT.CONTENT","_$getOwner","UIT.WHITESPACE","__name","popupCSS","anchoredCSS","__name$1","HEADER","WHITESPACE","PopupTrigger","__publicField","PopupTriggers","__decorateElement","__decoratorMetadata","__runInitializers","__privateAdd","AnimationLookup","CONTENT","ToggleCommands","__decoratorStart","getOwner$1","popupVocabulary","UIPopup_default","UIPopup_anchored_default","_tmpl$","_tmpl$2","_tmpl$3","_tmpl$4","_onPopoverModeChanged_dec","_onPositionChanged_dec","_accessibleName_dec","_ariaRole_dec","_onPopupFocusOut_dec","_onPopupLeave_dec","_onPopupEnter_dec","_onTargetClick_dec","_onExpandedChanged_dec","_onTargetChanged_dec","_ariaElement_dec","_targetElement_dec","_onCommand_dec","_onToggle_dec","_onPointChanged_dec","_pointBox_dec","_show_dec","_watchPlacement_dec","_elementSetup_dec","_vocabulary_dec","_a","_init","_pointBox","_ariaElement","_UIPopup","UIComponent","proto","protoMerged","whileConnected","untracked","state","onChange","on","derived","aria","Disclosure","event","UI","visible","originalEvent","delay","after","box","keyframes","animation","beforeNextPaint","QUIET_FOCUS","animations","each","target","anchor","domElement","at","point","root","ID_PREFIX","DISTANCE_TOKEN","CLOSED","action","property","id","DEFAULT_TRIGGER","isReady","trigger","listeners","options","isClick","events","element","unrelate","CONTROLS","DESCRIBED_BY","isInteractive","isVisible","token","HOVER_DELAY_TOKEN","match","DURATION","next","area","AT_POINT_POSITION","position","DEFAULT_POSITION","POSITION_AREAS","mode","BASIC_CLASS","SHOWN_CLASS","isServer","_self$","_el$","_el$3","_el$5","ref","insert","createComponent","Show","_el$2","effect","readShallow","className","_p$","setAttribute","_el$4","t","_self$2","_el$6","_el$8","_el$10","_el$7","_el$9","a","value","NodeType","CONTENTS","style","names","name","reflected","ids","relation","rest","elements","attribute","UIPopup"],"sources":["../src/components/ui-popup/UIPopup.en.ts","../src/components/ui-popup/UIPopup.css?inline","../src/components/ui-popup/UIPopup.tsx","../src/components/ui-popup/index.ts"],"sourcesContent":["/**\n * Every name `<ui-popup>` uses: tag, attributes (kind + allowed values), events, slots, parts, states, texts.\n * Schema: `E.ComponentVocabulary` (`spell/ui/vocabulary`).\n * - Pure data: node imports it (`yarn site:data`, `yarn gen:root`), so `spell/ui/core` for types only,\n * `UIT` by value straight from `components.types`.\n * - Class words come out through `ClassBuilder`, in Fomantic's grammar:\n * `<ui-popup size=\"small\" inverted wide=\"very\">` => `ui small inverted very wide popup`.\n * The element adds the `position` words before the noun (`ui inverted bottom left popup`),\n * the words Fomantic's script added.\n * - `visible`, Fomantic's shown-popup class, is the element's own while it shows (the shared `visible` / `hidden`),\n * so static markup and the element share one sheet.\n * - A popup OWNS the `header` and `content` parts:\n * slotted `<ui-header>` / `<ui-content>` get `:state(in-popup)` and style themselves from `UIParts.css`.\n * - `target` is a PROPERTY (an element); first paint never needs it --\n * `for` or the previous sibling carry what markup must say.\n */\n\nimport type { E } from \"spell/ui/core\"\nimport * as UIT from \"spell/ui/components/components.types\"\n\n/****************\n * ### `<ui-popup>`\n * A popup: a popover DOM element anchored to its target, holding `<div class=\"ui ... popup\" part=\"popup\">`.\n ****************/\nexport const popupVocabulary = {\n tag: \"ui-popup\",\n icon: \"comment outline\",\n topics: [\"popups\", \"overlays\", \"feedback\", \"modules\"],\n aka: [\"tooltip\", \"popover\", \"hint\", \"hover card\", \"info bubble\"],\n noun: \"popup\",\n description: \"A popup displays additional information on top of a page.\",\n attributes: [\n {\n name: \"size\",\n group: \"appearance\",\n kind: \"size\",\n description: \"Text size, `mini` ... `massive`; `medium` is the default.\"\n },\n {\n name: \"color\",\n group: \"appearance\",\n kind: \"color\",\n description: \"Hue: fills the popup (and its arrow), with a readable text colour.\"\n },\n {\n name: \"appearance\",\n group: \"appearance\",\n kind: \"multiple\",\n values: [\"basic\"],\n // each word draws itself: no key after it\n classes: {},\n replaces: [{ from: \"basic\", value: \"basic\" }],\n description: \"The look: `basic`, no pointing arrow. Old name: `basic`.\"\n },\n {\n name: \"fixed\",\n group: \"layout\",\n kind: \"keyOnly\",\n description: \"Always its maximum width (`wide` / `very wide` widen it).\"\n },\n {\n name: \"flowing\",\n group: \"appearance\",\n kind: \"keyOnly\",\n description: \"No maximum width: as wide as its content, e.g. a grid.\"\n },\n { name: \"fluid\", group: \"layout\", kind: \"keyOnly\", description: \"As wide as its target.\" },\n {\n name: \"inverted\",\n group: \"appearance\",\n kind: \"keyOnly\",\n description: \"The opposite scheme: dark on a light page.\"\n },\n { name: \"loading\", group: \"states\", kind: \"keyOnly\", description: \"Busy: a spinner over faded content.\" },\n {\n name: \"wide\",\n group: \"layout\",\n kind: \"keyOrValueAndKey\",\n values: [\"very\"],\n description: 'A wider maximum width; `wide=\"very\"` wider still (`very wide`).'\n },\n {\n name: \"position\",\n group: \"layout\",\n kind: \"enum\",\n values: \"positions\",\n default: \"top left\",\n description:\n \"Where it sits against its target: `top left` (default) ... `right center`, `left top` ... `right bottom` \" +\n \"(beside, lined up with its top / bottom edge). It flips to the other \" +\n \"side when there's no room.\"\n },\n {\n name: \"open-on\",\n group: \"appearance\",\n kind: \"enum\",\n values: UIT.PopupTriggers,\n default: UIT.PopupTrigger.hover,\n description:\n \"What opens it: `hover` (also keyboard focus), `focus`, `click` (toggles; a non-modal dialog), or \" +\n \"`manual` (only `visible`).\"\n },\n {\n name: \"for\",\n group: \"appearance\",\n kind: \"string\",\n property: \"htmlFor\",\n description: \"Id of the target, in the popup's own tree; without it, the previous element sibling.\"\n },\n {\n name: \"heading\",\n replaces: [\"header\"],\n group: \"name\",\n kind: \"string\",\n description:\n \"Shorthand for a header line (Fomantic's `title`); a slotted `<ui-header>` is the rich version. Its old name was `header`.\"\n },\n {\n name: \"label\",\n group: \"content\",\n kind: \"string\",\n replaces: [\"content\"],\n description:\n \"Shorthand for the text (Fomantic's `content`); slotted content is the rich version. Old name: `content`.\"\n },\n {\n name: \"hoverable\",\n group: \"behaviour\",\n kind: \"boolean\",\n default: true,\n description:\n \"`hover`: the popup stays open while the pointer is over it, so it can be reached and its text read or \" +\n \"selected -- on by default, as WCAG 1.4.13 (Content on Hover or Focus) asks for. \" +\n '`hoverable=\"false\"` is Fomantic\\'s `hoverable: false` (its default): it closes as the pointer leaves ' +\n \"the target, after `hide-delay`.\"\n },\n {\n name: \"show-delay\",\n group: \"behaviour\",\n kind: \"number\",\n default: 50,\n description: \"`hover`: ms before it shows; not written, the page's `--ui-hover-delay` (800ms by default).\"\n },\n {\n name: \"hide-delay\",\n group: \"appearance\",\n kind: \"number\",\n default: 70,\n description: \"`hover`: ms before it hides.\"\n },\n {\n name: \"target\",\n group: \"behaviour\",\n kind: \"json\",\n reflect: false,\n description: \"The target as a PROPERTY (an `Element`); wins over `for`.\"\n },\n {\n name: \"at\",\n group: \"behaviour\",\n kind: \"json\",\n reflect: false,\n description:\n 'A point in the window, `{ x, y }`, to open at instead of a target: a right click\\'s menu. With `open-on=\"manual\"` and `visible`; it stays inside the window, takes focus and gives it back.'\n }\n ],\n events: [\n {\n name: \"ui-opening\",\n detail: \"{ visible: true, originalEvent?: Event }\",\n cancelable: true,\n description:\n \"About to show for a person's action (the trigger, an invoker command); `preventDefault()` keeps it hidden.\"\n },\n {\n name: \"ui-closing\",\n detail: \"{ visible: false, originalEvent?: Event }\",\n cancelable: true,\n description:\n \"About to hide; `preventDefault()` keeps it shown. NOT cancelable in effect when the browser already \" +\n \"dismissed a `hint` popover (Escape, a click elsewhere).\"\n }\n ],\n slots: [{ name: \"\", description: \"Content: text, `<ui-header>` / `<ui-content>` parts, a grid, controls.\" }],\n parts: [\n { name: \"popup\", description: \"The popup box (its arrow is `::before`).\" },\n { name: \"header\", description: \"The `header` shorthand.\" },\n { name: \"content\", description: \"The `content` shorthand.\" }\n ],\n states: [{ name: \"fluid\", description: \"As wide as its target (`fluid`).\" }],\n texts: [],\n ownsParts: [\"header\", \"content\"]\n} as const satisfies E.ComponentVocabulary\n","/*\n * `<ui-popup>`: port of Fomantic's `popup.less` + `popup.variables` (the CSS-only `[data-tooltip]` rules live in\n * `native.css`, a page sheet: they style light-DOM markup).\n * - Shadow markup contract (class grammar; a popup has no better element than `<div>`):\n * `<div class=\"ui [size] [color] [keyOnly ...] [very] [wide] popup [position]\" part=\"popup\">` holding, in order,\n * `<div class=\"header\" part=\"header\">` (the `header` shorthand),\n * `<div class=\"content\" part=\"content\">` (the `content` shorthand) and the default `<slot>`.\n * The position words (`top left` ... `right center`) come before the noun (the words Fomantic's script added);\n * `visible` while open.\n * - The DOM element is the positioned box: a popover (`popover=\"hint\"` for hover / focus popups where supported,\n * else `manual`) in the top layer, anchored to its target. The element sets on it, inline:\n * - `position-anchor`: the target's `anchor-name` (a per-instance dashed ident it adds to the target's inline\n * `anchor-name` list), or `auto` -- the implicit anchor `showPopover({ source })` sets -- when the target has\n * no box of its own (`display: contents`, e.g. `<ui-icon>`, `<ui-label>`): it's then anchored to the\n * target's first shadow box, which a tree-scoped `anchor-name` can't name across the shadow boundary\n * - `position-area`: from `position` (`top left` => `top span-right` ...)\n * - this sheet adds `position-try-fallbacks: flip-block, flip-inline` (no JS positioning,\n * ever) and `container-type: anchored`, so the arrow and the gap follow a flip where anchored queries exist\n * - Distance: Fomantic's margin on the popup box (`.ui.top.popup { margin-bottom }`):\n * the DOM element shrink-wraps it, so the margin is the gap to the target.\n * - The inner box's `position: absolute` / `display: none` are STATIC-markup rules; inside the shadow root the\n * box is always a block and the DOM element's popover state decides visibility.\n * - Motion: the box scales and fades in from `@starting-style` and out while the DOM element's `display` / `overlay`\n * transition (`allow-discrete`) keeps it in the top layer; `reset.css` shortens it under reduced motion.\n * - Colours: `color` remaps (`colors.css`) fill the box and arrow with `--ui-color` and write\n * `--ui-color-on`; the arrow's edge takes `--ui-color` too, so it disappears into a coloured box (no per-hue\n * rules). Uncoloured, the arrow's edge is the box's border colour (`--ui-popup-border-color`), unless\n * `--ui-popup-arrow-edge` says otherwise: a theme's rim runs on round the arrow (Owen, 2026-10-25: \"Arrow tip\n * border doesn't match shading on tooltip\"). `inverted` swaps in the opposite scheme's ink, and a coloured inverted popup the hue's `-inverted`\n * variant (Fomantic's \"light\" hue). The DOM element resets the remap and `--ui-scale`, so a popup opened from inside\n * a red message or a large button isn't red or large.\n * - Public tokens (`--ui-popup-*`, the theming surface) are NEVER declared here: the token block reads each\n * through a private alias, `--_ui-popup-radius: var(--ui-popup-radius, var(--ui-radius))` (the duration on the\n * DOM element, which transitions too), and every rule reads the alias, `UIPopup.anchored.css` included.\n * So a value set on `:root`, an ancestor, the DOM element, `::part(popup)` or in the app stylesheet reaches the box\n * (`notes/theming.md` \"Component tokens\"). `wide` / `very wide` swap the max width for `--ui-popup-wide-width` /\n * `--ui-popup-very-wide-width`, back to the base on phones.\n * - OWNER side: slotted `<ui-header>` / `<ui-content>` style themselves from `UIParts.css` (context `in-popup`),\n * reading the aliases `--_ui-popup-header-font-size` / `--_ui-popup-header-distance`, declared on every root.\n * - NOTE: left out, on purpose:\n * - `.ui.invisible.popup` / `.ui.animating.popup`: script states the popover replaces\n * - the nested-grid coupling's `rem` margins: `.ui.popup > .ui.grid` gets the same inset in `em`\n * - Fomantic's per-position arrow BACKGROUND variables (all the same colour in the default theme)\n */\n\n@layer ui.components.popup.types, ui.components.popup.content, ui.components.popup.variations, ui.components.popup.states;\n\n/* Breakpoints (`@custom-media`), inlined at build time. */\n@import \"../../styles/media.css\";\n\n/*******************************\n Popup\n*******************************/\n\n@layer ui.components.popup.types {\n /* DOM element: the popover in the top layer, shrink-wrapped around the box; the UA popover look reset. */\n :host {\n --ui-color: initial;\n --ui-color-text: initial;\n --ui-color-header: initial;\n --ui-color-border: initial;\n --ui-color-background: initial;\n --ui-color-inverted: initial;\n --ui-color-on: initial;\n --ui-color-inverted-on: initial;\n --ui-scale: initial;\n --_ui-popup-duration: var(--ui-popup-duration, var(--ui-duration-normal));\n position: absolute;\n inset: auto;\n z-index: var(--ui-z-popup);\n display: block;\n box-sizing: border-box;\n width: max-content;\n height: max-content;\n margin: 0;\n padding: 0;\n overflow: visible;\n border: 0;\n background: transparent;\n color: inherit;\n position-try-fallbacks:\n flip-block,\n flip-inline,\n flip-block flip-inline;\n container-type: anchored;\n transition-property: display, overlay;\n transition-duration: var(--_ui-popup-duration);\n transition-behavior: allow-discrete;\n }\n :host(:not(:popover-open)) {\n display: none;\n }\n :host(:state(fluid)) {\n width: anchor-size(width);\n }\n\n /* Tokens: one private alias per `popup.variables` entry that still matters, from the global tokens. */\n .ui.popup {\n --_ui-popup-background: var(--ui-popup-background, var(--ui-surface));\n --_ui-popup-color: var(--ui-popup-color, var(--ui-text-color));\n --_ui-popup-border-color: var(--ui-popup-border-color, var(--ui-border-color-strong));\n --_ui-popup-shadow: var(--ui-popup-shadow, var(--ui-shadow-floating));\n --_ui-popup-radius: var(--ui-popup-radius, var(--ui-radius));\n --_ui-popup-padding: var(--ui-popup-padding, 0.833em 1em);\n --_ui-popup-max-width: var(--ui-popup-max-width, 250px);\n --_ui-popup-wide-width: var(--ui-popup-wide-width, 350px);\n --_ui-popup-very-wide-width: var(--ui-popup-very-wide-width, 550px);\n --_ui-popup-arrow-size: var(--ui-popup-arrow-size, 0.71428em);\n --_ui-popup-arrow-edge-distance: var(--ui-popup-arrow-edge-distance, 1em);\n --_ui-popup-arrow-offset: var(--ui-popup-arrow-offset, calc(var(--_ui-popup-arrow-size) / -2 + 0.05em));\n /* the box's own rim by default, so a themed rim (a glass theme's white one) runs on round the arrow */\n --_ui-popup-arrow-edge: var(--ui-popup-arrow-edge, var(--_ui-popup-border-color));\n --_ui-popup-distance: var(--ui-popup-distance, var(--_ui-popup-arrow-size));\n --_ui-popup-inverted-background: var(--ui-popup-inverted-background, var(--ui-ink));\n --_ui-popup-inverted-color: var(--ui-popup-inverted-color, var(--ui-surface));\n --_ui-popup-loading-opacity: var(--ui-popup-loading-opacity, 0.3);\n /* Also declared on `:host` (which transitions too); static markup has no shadow host, so the box needs its own. */\n --_ui-popup-duration: var(--ui-popup-duration, var(--ui-duration-normal));\n /* ## Owner tokens (`UIParts.css`): declared on every root. */\n --_ui-popup-header-font-size: var(--ui-popup-header-font-size, 1.14285em);\n --_ui-popup-header-distance: var(--ui-popup-header-distance, 0.5em);\n /* Arrow placement, set per position below. */\n --_popup-arrow-shadow: 1px 1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(calc(100% + 2px) -5px, calc(100% + 2px) calc(100% + 2px), -5px calc(100% + 2px));\n --_popup-arrow-edge: var(--ui-color, var(--_ui-popup-arrow-edge));\n position: absolute;\n top: 0;\n right: 0;\n z-index: var(--ui-z-popup);\n box-sizing: border-box;\n display: none;\n min-width: min-content;\n max-width: var(--_ui-popup-max-width);\n margin: 0;\n padding: var(--_ui-popup-padding);\n border: var(--ui-border-width) solid var(--ui-color, var(--_ui-popup-border-color));\n border-radius: var(--_ui-popup-radius);\n background: var(--ui-color, var(--_ui-popup-background));\n box-shadow: var(--_ui-popup-shadow);\n color: var(--ui-color-on, var(--_ui-popup-color));\n font-family: var(--ui-font-family);\n font-size: calc(var(--ui-font-size) * var(--ui-scale, 1));\n font-style: normal;\n font-weight: var(--ui-font-weight-normal);\n line-height: var(--ui-line-height);\n text-align: start;\n }\n\n /* Inside the shadow root: always a block in flow; the DOM element decides whether it shows. */\n :host > .ui.popup {\n position: relative;\n top: auto;\n right: auto;\n display: block;\n opacity: 1;\n transform: none;\n transition:\n opacity var(--_ui-popup-duration) var(--ui-ease),\n transform var(--_ui-popup-duration) var(--ui-ease);\n }\n :host(:not(:popover-open)) > .ui.popup {\n opacity: 0;\n transform: scale(0.8);\n }\n @starting-style {\n :host(:popover-open) > .ui.popup {\n opacity: 0;\n transform: scale(0.8);\n }\n }\n\n /* Arrow: a rotated square under the edge facing the target. */\n .ui.popup::before {\n content: \"\";\n position: absolute;\n z-index: 1;\n width: var(--_ui-popup-arrow-size);\n height: var(--_ui-popup-arrow-size);\n background: inherit;\n box-shadow: var(--_popup-arrow-shadow);\n /*\n * only the triangle OUTSIDE the box, and a hair over its edge to cover the box's rim: the half inside it doubled a see-through fill (a theme's glass) into a\n * darker diamond over the text (Owen, 2026-10-25: \"clip the triangle, make opacity match the text\")\n */\n clip-path: var(--_popup-arrow-clip, none);\n transform: rotate(45deg);\n }\n}\n\n/*******************************\n Content\n*******************************/\n\n@layer ui.components.popup.content {\n /* Header (the shorthand, or static `.header`); a block even as a server render's `<span>` (`UIPopup`). */\n .ui.popup > .header {\n display: block;\n padding: 0;\n font-family: var(--ui-font-family-heading);\n font-size: var(--_ui-popup-header-font-size);\n font-weight: var(--ui-font-weight-bold);\n line-height: 1.2;\n }\n .ui.popup > .header + .content {\n padding-top: var(--_ui-popup-header-distance);\n }\n /* The `content` shorthand: a block, for the same reason. */\n .ui.popup > .content {\n display: block;\n }\n\n /* Coupling: a grid right inside a popup sits flush with its padding. */\n .ui.popup > .ui.grid:not(.padded),\n .ui.popup > ::slotted(ui-grid:not([padding])) {\n width: calc(100% + 2em);\n margin: -0.7em -1em;\n }\n}\n\n/*******************************\n Variations\n*******************************/\n\n@layer ui.components.popup.variations {\n /* ## Position: the gap on the side facing the target, and the arrow on that edge. */\n .ui.top.popup {\n margin: 0 0 var(--_ui-popup-distance);\n }\n .ui.bottom.popup {\n margin: var(--_ui-popup-distance) 0 0;\n --_popup-arrow-shadow: -1px -1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-2px -2px, calc(100% + 5px) -2px, -2px calc(100% + 5px));\n }\n .ui.left.center.popup {\n margin: 0 var(--_ui-popup-distance) 0 0;\n transform-origin: right 50%;\n --_popup-arrow-shadow: 1px -1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-5px -2px, calc(100% + 2px) -2px, calc(100% + 2px) calc(100% + 5px));\n }\n .ui.right.center.popup {\n margin: 0 0 0 var(--_ui-popup-distance);\n transform-origin: left 50%;\n --_popup-arrow-shadow: -1px 1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-2px -5px, calc(100% + 5px) calc(100% + 2px), -2px calc(100% + 2px));\n }\n .ui.top.left.popup {\n transform-origin: left bottom;\n }\n .ui.top.center.popup {\n transform-origin: center bottom;\n }\n .ui.top.right.popup {\n transform-origin: right bottom;\n }\n .ui.bottom.left.popup {\n transform-origin: left top;\n }\n .ui.bottom.center.popup {\n transform-origin: center top;\n }\n .ui.bottom.right.popup {\n transform-origin: right top;\n }\n\n /* Below */\n .ui.bottom.center.popup::before {\n inset: var(--_ui-popup-arrow-offset) auto auto 50%;\n margin-left: var(--_ui-popup-arrow-offset);\n }\n .ui.bottom.left.popup::before {\n inset: var(--_ui-popup-arrow-offset) auto auto var(--_ui-popup-arrow-edge-distance);\n }\n .ui.bottom.right.popup::before {\n inset: var(--_ui-popup-arrow-offset) var(--_ui-popup-arrow-edge-distance) auto auto;\n }\n\n /* Above */\n .ui.top.center.popup::before {\n inset: auto auto var(--_ui-popup-arrow-offset) 50%;\n margin-left: var(--_ui-popup-arrow-offset);\n }\n .ui.top.left.popup::before {\n inset: auto auto var(--_ui-popup-arrow-offset) var(--_ui-popup-arrow-edge-distance);\n }\n .ui.top.right.popup::before {\n inset: auto var(--_ui-popup-arrow-edge-distance) var(--_ui-popup-arrow-offset) auto;\n }\n\n /* Beside */\n .ui.left.center.popup::before {\n inset: 50% var(--_ui-popup-arrow-offset) auto auto;\n margin-top: var(--_ui-popup-arrow-offset);\n }\n .ui.right.center.popup::before {\n inset: 50% auto auto var(--_ui-popup-arrow-offset);\n margin-top: var(--_ui-popup-arrow-offset);\n }\n\n /*\n * Beside, lined up with the target's top / bottom edge (ours, not Fomantic's). Class words have no order,\n * so `left top` carries the same words as `top left`: these match the PHRASE (`[class*=\"left top\"]`,\n * Fomantic's `very wide` idiom) plus the side word, which ties `.ui.top.left.popup` on specificity and wins by coming\n * later. They set everything the above / below rules set (margin, arrow edge and inset, transform origin).\n */\n .ui[class*=\"left top\"].left.popup,\n .ui[class*=\"left bottom\"].left.popup {\n margin: 0 var(--_ui-popup-distance) 0 0;\n --_popup-arrow-shadow: 1px -1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-5px -2px, calc(100% + 2px) -2px, calc(100% + 2px) calc(100% + 5px));\n }\n .ui[class*=\"right top\"].right.popup,\n .ui[class*=\"right bottom\"].right.popup {\n margin: 0 0 0 var(--_ui-popup-distance);\n --_popup-arrow-shadow: -1px 1px 0 0 var(--_popup-arrow-edge);\n --_popup-arrow-clip: polygon(-2px -5px, calc(100% + 5px) calc(100% + 2px), -2px calc(100% + 2px));\n }\n .ui[class*=\"left top\"].left.popup {\n transform-origin: right top;\n }\n .ui[class*=\"left bottom\"].left.popup {\n transform-origin: right bottom;\n }\n .ui[class*=\"right top\"].right.popup {\n transform-origin: left top;\n }\n .ui[class*=\"right bottom\"].right.popup {\n transform-origin: left bottom;\n }\n .ui[class*=\"left top\"].left.popup::before {\n inset: var(--_ui-popup-arrow-edge-distance) var(--_ui-popup-arrow-offset) auto auto;\n }\n .ui[class*=\"left bottom\"].left.popup::before {\n inset: auto var(--_ui-popup-arrow-offset) var(--_ui-popup-arrow-edge-distance) auto;\n }\n .ui[class*=\"right top\"].right.popup::before {\n inset: var(--_ui-popup-arrow-edge-distance) auto auto var(--_ui-popup-arrow-offset);\n }\n .ui[class*=\"right bottom\"].right.popup::before {\n inset: auto auto var(--_ui-popup-arrow-edge-distance) var(--_ui-popup-arrow-offset);\n }\n\n /* Flipped by `position-try-fallbacks`: see `UIPopup.anchored.css`. */\n\n /* ## Basic: no arrow. */\n .ui.basic.popup::before {\n display: none;\n }\n\n /* ## Widths */\n .ui.fixed.popup {\n width: var(--_ui-popup-max-width);\n }\n .ui.wide.popup {\n --_ui-popup-max-width: var(--_ui-popup-wide-width);\n }\n .ui[class*=\"very wide\"].popup {\n --_ui-popup-max-width: var(--_ui-popup-very-wide-width);\n }\n @media (--ui-mobile) {\n .ui.wide.popup,\n .ui[class*=\"very wide\"].popup {\n --_ui-popup-max-width: var(--ui-popup-max-width, 250px);\n }\n }\n .ui.fluid.popup {\n width: 100%;\n max-width: none;\n }\n .ui.flowing.popup {\n max-width: none;\n }\n /*\n * A slotted grid is a size container (`UIGrid.css`), so its inline size ignores its content and a popup sized\n * BY its content collapses to a sliver. Drop the containment here: this outer tree's `::slotted()` beats the\n * grid's own `:host` rule. Its stackable / device ranges then follow the nearest container above.\n */\n .ui.flowing.popup > ::slotted(ui-grid) {\n container-type: normal;\n }\n\n /* ## Inverted: the opposite scheme's ink; a coloured one takes the hue's light variant. */\n .ui.inverted.popup {\n --ui-inverted: 1;\n --_popup-arrow-shadow: none;\n border-color: transparent;\n background: var(--ui-color-inverted, var(--_ui-popup-inverted-background));\n box-shadow: none;\n color: var(--ui-color-inverted-on, var(--_ui-popup-inverted-color));\n }\n .ui.inverted.popup > .header {\n background: none;\n color: inherit;\n }\n}\n\n/*******************************\n States\n*******************************/\n\n@layer ui.components.popup.states {\n /* Shown (static markup; on the element, its DOM element is the popover). */\n .ui.visible.popup {\n display: block;\n }\n\n /*\n * Static markup whose box IS the popover (a server render's, `spell/ui/static`): hidden until open,\n * as the DOM element is.\n * Never matches inside the element's shadow root, where the DOM element carries `popover`.\n */\n .ui.popup[popover]:not(:popover-open) {\n display: none;\n }\n\n /* Loading: faded content under a spinner; not interactive. */\n .ui.loading.popup {\n cursor: default;\n pointer-events: none;\n user-select: none;\n }\n .ui.loading.popup > *,\n .ui.loading.popup > ::slotted(*) {\n opacity: var(--_ui-popup-loading-opacity);\n }\n .ui.loading.popup::after {\n content: \"\";\n position: absolute;\n top: 50%;\n left: 50%;\n z-index: 2;\n width: 2em;\n height: 2em;\n margin: -1em 0 0 -1em;\n border: 0.2em solid oklch(from currentColor l c h / 0.15);\n border-top-color: currentColor;\n border-radius: var(--ui-radius-circle);\n animation: ui-popup-spin 0.6s linear infinite;\n }\n}\n\n/* Loader spin. */\n@keyframes ui-popup-spin {\n to {\n transform: rotate(360deg);\n }\n}\n","import { Show } from \"solid-js\"\nimport { isServer, type JSX } from \"@solidjs/web\"\n\nimport { E, UI, UIT } from \"spell/ui/core\"\nimport { popupVocabulary } from \"./UIPopup.en\"\n\nimport popupCSS from \"./UIPopup.css?inline\"\nimport anchoredCSS from \"./UIPopup.anchored.css?raw\"\n\n/****************\n * ### `UIPopup`\n * The component behind `<ui-popup>`: a popup anchored to a TARGET.\n * The DOM element is a popover in the top layer, placed by CSS anchor positioning only (`UIPopup.css`),\n * holding `<div class=\"ui … popup [position]\" part=\"popup\">`.\n *\n * - Its target: the `target` property, else the element `for` names (in the popup's own tree),\n * else the previous element sibling (Fomantic's `inline` markup: a popup right after what opens it).\n *\n * - `open-on`:\n * - `hover` (with `show-delay` / `hide-delay`, and on keyboard focus too)\n * - `focus`\n * - `click` (toggles)\n * - `manual` (only `visible`)\n * - A hovered popup stays open while the pointer is over it (WCAG 1.4.13),\n * unlike Fomantic's default `hoverable: false`.\n * `hoverable=\"false\"` gives Fomantic's behaviour back:\n * it hides as the pointer leaves the target, after `hide-delay`.\n *\n * - `at`, a point in the window (`{ x, y }`), in place of a target: a right click's menu.\n * - It opens with its corner there, staying inside the window, and takes focus, which goes back when it closes.\n * - The point is a box the popup puts on the page while it's open (`placeAtPoint()`): anchor positioning needs one.\n * - Written with `open-on=\"manual\"`, and with `visible` to open: it has no target to listen to.\n *\n * - Invoker commands (`<button commandfor=\"id\" command=\"--toggle\">`, `UIT.ToggleCommands`)\n * are a person's actions too: the popup opens at ITS target, whichever button sent the command.\n *\n * - Shown by the shared `visible` / `hidden` (`UIComponent`, \"Shown or hidden\"), starting hidden.\n * - Controlled: a person's cancelable `ui-opening` / `ui-closing` come first.\n * - Escape and outside clicks come from `UI.overlays` (kind `popover`; the target counts as inside).\n *\n * - Its popover mode: `hint` for hover / focus popups when `UI.browser.supports.popoverHint`\n * (they don't close an open dropdown's menu), else `manual`.\n * - Click and manual popups are always `manual`: `auto`'s light dismiss would skip the cancelable `ui-closing`.\n * - When the browser dismisses a `hint` popover itself,\n * the component follows (with a `ui-closing` that can no longer veto).\n *\n * - Accessibility, by `open-on`:\n * - `hover` / `focus` / `manual`: the DOM element is `role=tooltip`; the target is `aria-describedby` it;\n * `at` is interactive, as `click`\n * - `click`: the DOM element is `role=dialog` (non-modal, named by `header` or its `aria-label`);\n * the target gets `aria-haspopup=dialog`, `aria-expanded`, `aria-controls`\n * - the ARIA goes on the element that takes focus: a `delegatesFocus` target's (`<ui-button>`'s) first focusable,\n * through element reflection (`ariaDescribedByElements`) when that is in another tree.\n *\n * - SIDE EFFECTS on light DOM the popup doesn't own, undone when it unbinds:\n * - the target's inline `anchor-name` (a per-instance name ADDED to its list) and its ARIA attributes\n * - the DOM element's `popover`, `id`, and inline `position-anchor` / `position-area`.\n ****************/\nexport class UIPopup extends E.UIComponent<Vocabulary> {\n @E.proto static vocabulary = popupVocabulary\n @E.protoMerged static elementSetup = {\n styleSheets: { popup: popupCSS, \"popup-anchored\": anchoredCSS },\n cssStates: [\"fluid\"],\n // nothing inside needs focus delegated: a click on a tooltip's text must not jump to a link in it\n delegatesFocus: false,\n // `loading`: Fomantic's loader inside the popup\n loading: \"its own\",\n visible: \"hidden\",\n // the sheet's own transition is Fomantic's `scale`: faded in from 80%\n animation: \"scale\"\n } satisfies Partial<E.ElementSetup>\n\n ////////////////\n // ## Shown or hidden\n ////////////////\n\n /** Pending delayed show / hide. */\n private delayTimer?: E.CancelablePromise<unknown>\n\n /** This element's `UI.overlays` entry; `anchor` follows the target. */\n private readonly overlay: E.OverlayEntry = {\n element: this.domElement,\n kind: \"popover\",\n onDismiss: () => void this.requestVisible(false)\n }\n\n /** Shown or hidden, as `visible` (`isVisible`): `ui-opening` / `ui-closing` first. */\n readonly disclosure = new E.Disclosure({\n component: this,\n member: \"isVisible\",\n detail: (visible, originalEvent): UIT.PopupOpenDetail => ({ visible, originalEvent })\n })\n\n /** Show or hide, dispatching the cancelable `ui-opening` / `ui-closing` first; true when applied. */\n requestVisible(visible: boolean, originalEvent?: Event): boolean {\n this.delayTimer?.cancel()\n return this.disclosure.request(visible, originalEvent)\n }\n\n /** `requestVisible()` after `delay` ms (at once for `0`); a newer call replaces a pending one. */\n private schedule(visible: boolean, delay: number, originalEvent?: Event) {\n this.delayTimer?.cancel()\n if (delay <= 0) return void this.requestVisible(visible, originalEvent)\n this.delayTimer = E.after(delay / 1000, () => this.requestVisible(visible, originalEvent))\n }\n\n /**\n * `visible` changed (`UIComponent`'s hook): show or hide the popover; resolves once its transition has ended.\n * - Showing waits for a `ui-*` target to be ready:\n * it renders async, so its box (or `display: contents`) is only known then.\n * - `animation`:\n * - the family's own (`elementSetup.animation`): the sheet's transition (`UIPopup.css`)\n * - another one (the element's own `animation`): run on the popup box through `UI.transitions`\n * - `none`: at once\n */\n protected async onVisibleChange(visible: boolean, animation: UIT.Animation): Promise<void> {\n const box = this.box\n const keyframes = UIT.AnimationLookup.keyframesBeside(animation, this.elementSetup.animation)\n if (visible) {\n const target = this.targetElement as { ready?: Promise<void> } | undefined\n await target?.ready\n if (!this.isVisible || !this.isConnected) return\n this.show()\n // no ring for a mouse's right click: the arrow keys show it\n if (this.point) E.beforeNextPaint(() => UI.focus.first(this.domElement)?.focus(QUIET_FOCUS))\n if (keyframes && box) await UI.transitions.animate({ element: box, name: keyframes, direction: UIT.IN })\n return\n }\n if (keyframes && box) await UI.transitions.animate({ element: box, name: keyframes, direction: UIT.OUT })\n // shown again while the keyframes ran\n if (this.isVisible) return\n this.hide()\n const animations = [...this.domElement.getAnimations(), ...(box?.getAnimations() ?? [])]\n await Promise.allSettled(animations.map((each) => each.finished))\n }\n\n /**\n * Shown again when it comes back into the page while `visible`; hidden, quietly, when it leaves.\n * - Not on the first connect: `onVisibleChange()` runs once the popup first draws.\n */\n @E.whileConnected\n protected watchPlacement() {\n if (this.isVisible && this.isReady) this.show()\n return () => this.hide()\n }\n\n /** The popup box in the shadow root (`part=\"popup\"`). */\n private box?: HTMLElement\n\n /**\n * Show the popover against the target and register with `UI.overlays`.\n * - Anchor: the target's `anchor-name` when it has a box,\n * else the implicit anchor of `source` (see `UIPopup.css`).\n * - `source` also makes the target the popover's invoker, so Tab from it continues inside.\n * - A box other keyframes animated out (`hidden` on it) shows again first.\n */\n @E.untracked\n private show() {\n const { domElement } = this\n if (this.box) UI.transitions.reveal(this.box)\n this.placeAtPoint()\n const target = this.targetElement\n const anchor = target ? UIPopup.anchorBoxFor(target) : undefined\n domElement.popover ||= this.popoverMode\n domElement.style.setProperty(\"position-anchor\", anchor === target ? this.anchorName : anchor ? \"auto\" : \"none\")\n if (!domElement.matches(\":popover-open\")) {\n domElement.showPopover(anchor ? ({ source: anchor } as ShowPopoverOptions) : undefined)\n }\n this.overlay.anchor = target\n this.overlay.restoreFocus = this.isInteractive\n UI.overlays.open(this.overlay)\n }\n\n /** Hide the popover and leave `UI.overlays`. */\n private hide() {\n this.delayTimer?.cancel()\n if (this.domElement.matches(\":popover-open\")) this.domElement.hidePopover()\n UI.overlays.close(this.overlay)\n this.removePointBox()\n }\n\n ////////////////\n // ## A point\n ////////////////\n\n /** `at`, when it's a point. */\n get point(): UIT.PopupPoint | undefined {\n const at = this.at as UIT.PopupPoint | undefined\n return typeof at?.x === \"number\" && typeof at.y === \"number\" ? at : undefined\n }\n\n /** The box at `point`, while it's open: what it's anchored to. */\n @E.state accessor pointBox: HTMLElement | undefined = undefined\n\n /**\n * Put the box at `point`, and make it the target, its anchor name on it already: `bind()` comes a moment later.\n * - In the popup's own tree: an anchor name reaches only there.\n * - SIDE EFFECT: no pointing arrow and no gap; `removePointBox()` undoes it.\n */\n private placeAtPoint() {\n const { point, domElement } = this\n if (!point) return this.removePointBox()\n const root = domElement.getRootNode() as Document | ShadowRoot\n const box = this.pointBox ?? (domElement.ownerDocument.createElement(\"div\") as HTMLElement)\n box.style.cssText = `position:fixed;left:${point.x}px;top:${point.y}px;width:0;height:0`\n box.setAttribute(\"aria-hidden\", \"true\")\n if (!box.isConnected) (\"body\" in root ? root.body : root).append(box)\n this.anchorName ||= `--${UI.ids.next(ID_PREFIX)}`\n UIPopup.addAnchorName(box, this.anchorName)\n domElement.style.setProperty(DISTANCE_TOKEN, \"0px\")\n this.pointBox = box\n }\n\n /** Take the box away. */\n private removePointBox() {\n if (!this.pointBox) return\n this.pointBox.remove()\n this.pointBox = undefined\n this.domElement.style.removeProperty(DISTANCE_TOKEN)\n }\n\n /** Told of a new point while it's open: it moves there. */\n @E.onChange(\"at\", { defer: true })\n protected onPointChanged() {\n if (this.isVisible && this.isConnected) this.placeAtPoint()\n }\n\n /**\n * The popover's `toggle`: the browser closed it (a `hint` popover's light dismiss)\n * while the element thinks it's open -- follow, announcing a `ui-closing` that can't veto any more.\n */\n @E.on(\"toggle\")\n protected onToggle(event: Event) {\n if ((event as ToggleEvent).newState !== CLOSED || !this.domElement.isConnected) return\n this.disclosure.adopt(false, event)\n }\n\n /** An invoker command aimed at the DOM element (`ToggleCommands`). */\n @E.on(\"command\")\n protected onCommand(event: Event) {\n const action = UIT.ToggleCommands.action(event, this.isVisible)\n if (action) this.requestVisible(action === \"show\", event)\n }\n\n ////////////////\n // ## The target\n ////////////////\n\n /**\n * The target: `target` property, else `for`, else the previous element sibling; `undefined` when unbound.\n * - Not `target`: that's the attribute's getter, the property this reads first.\n */\n @E.derived\n get targetElement(): Element | undefined {\n if (!this.isConnected) return undefined\n if (this.pointBox) return this.pointBox\n const property = this.target\n if (UIPopup.isElement(property)) return property\n const id = this.for\n if (id) return (this.domElement.getRootNode() as Document | ShadowRoot).getElementById?.(id) ?? undefined\n return this.domElement.previousElementSibling ?? undefined\n }\n\n /** What opens it. */\n get trigger(): UIT.PopupTrigger {\n return this.openOn ?? DEFAULT_TRIGGER\n }\n\n /** A click popup, or one at a point: a non-modal dialog with interactive content, not a tooltip. */\n get isInteractive(): boolean {\n return this.trigger === UIT.PopupTrigger.click || !!this.point\n }\n\n /** Element carrying the target's ARIA (see class docs), while bound. */\n @E.state accessor ariaElement: Element | undefined = undefined\n\n /** Per-instance anchor name, from `UI.ids` on first bind. */\n private anchorName = \"\"\n\n /** Ready with a target: bind it for the trigger; the cleanup is `bind()`'s undo. */\n @E.onChange(\"isReady\", \"targetElement\", \"trigger\")\n protected onTargetChanged(isReady: boolean, target: Element | undefined, trigger: UIT.PopupTrigger) {\n return isReady && target ? this.bind(target, trigger) : undefined\n }\n\n /**\n * Listen to `target` for `trigger`, add the anchor name and the ARIA; returns the undo.\n * - SIDE EFFECTS: see class docs.\n */\n private bind(target: Element, trigger: UIT.PopupTrigger): () => void {\n const { domElement } = this\n this.anchorName ||= `--${UI.ids.next(ID_PREFIX)}`\n const listeners = new AbortController()\n const options = { signal: listeners.signal }\n const isClick = trigger === UIT.PopupTrigger.click\n // `HTMLElement`'s event map: an SVG target fires the same pointer / focus events\n const events = target as HTMLElement\n if (trigger === UIT.PopupTrigger.hover) {\n events.addEventListener(\"pointerenter\", this.onTargetEnter, options)\n events.addEventListener(\"pointerleave\", this.onTargetLeave, options)\n }\n if (trigger === UIT.PopupTrigger.hover || trigger === UIT.PopupTrigger.focus) {\n events.addEventListener(\"focusin\", this.onTargetFocus, options)\n events.addEventListener(\"focusout\", this.onTargetBlur, options)\n }\n if (isClick) events.addEventListener(\"click\", this.onTargetClick, options)\n UIPopup.addAnchorName(target, this.anchorName)\n UI.ids.ensure(domElement, ID_PREFIX)\n const element = UIPopup.ariaTargetFor(target)\n const unrelate = UIPopup.addAriaRelation({ element, relation: isClick ? CONTROLS : DESCRIBED_BY, domElement })\n if (isClick) element.setAttribute(\"aria-haspopup\", \"dialog\")\n this.ariaElement = element\n return () => {\n listeners.abort()\n this.delayTimer?.cancel()\n UIPopup.removeAnchorName(target, this.anchorName)\n unrelate()\n if (isClick) {\n element.removeAttribute(\"aria-haspopup\")\n element.removeAttribute(\"aria-expanded\")\n }\n this.ariaElement = undefined\n }\n }\n\n /**\n * A server render's binding: the target's ARIA, as `bind()` adds it, without listeners.\n * - SIDE EFFECTS: gives the DOM element (the render's parsed copy) an id, which its root keeps,\n * and sets the target's `aria-describedby` / `aria-controls` and `aria-haspopup`.\n * - No `aria-expanded`: a native invoker reports its popover's state itself.\n */\n private serverBind() {\n const target = this.targetElement\n if (!target) return\n const isInteractive = this.isInteractive\n UI.ids.ensure(this.domElement, ID_PREFIX)\n const element = UIPopup.ariaTargetFor(target)\n UIPopup.addAriaRelation({ element, relation: isInteractive ? CONTROLS : DESCRIBED_BY, domElement: this.domElement })\n if (isInteractive) element.setAttribute(\"aria-haspopup\", \"dialog\")\n }\n\n /** A click popup's target says whether it's shown (`aria-expanded`). */\n @E.onChange(\"ariaElement\", \"isInteractive\", \"isVisible\")\n protected onExpandedChanged(element: Element | undefined, isInteractive: boolean, isVisible: boolean) {\n if (element && isInteractive) element.setAttribute(\"aria-expanded\", String(isVisible))\n }\n\n /** Pointer onto the target (`hover`): show after `show-delay`, else the page's `--ui-hover-delay`. */\n private readonly onTargetEnter = (event: PointerEvent) => {\n this.schedule(true, this.hoverDelay, event)\n }\n\n /**\n * How long the pointer rests before it shows: its own `show-delay` when written, else the page's preference,\n * the `--ui-hover-delay` token (`styles.en.ts`'s `hoverDelay`), in `ms` or `s`; else `show-delay`'s default.\n */\n private get hoverDelay(): number {\n if (this.attributes[\"show-delay\"] !== null) return this.showDelay ?? 0\n const token = getComputedStyle(this.domElement).getPropertyValue(HOVER_DELAY_TOKEN).trim()\n const match = DURATION.exec(token)\n if (!match) return this.showDelay ?? 0\n return Number(match[1]) * (match[2] === \"s\" ? 1000 : 1)\n }\n\n /** Pointer off the target (`hover`): hide after `hide-delay`, unless it reaches the popup first. */\n private readonly onTargetLeave = (event: PointerEvent) => {\n this.schedule(false, this.hideDelay ?? 0, event)\n }\n\n /** Focus onto the target (`hover`, `focus`): show at once. */\n private readonly onTargetFocus = (event: FocusEvent) => {\n this.schedule(true, 0, event)\n }\n\n /** Focus off the target (`hover`, `focus`): hide, unless focus moved into the popup. */\n private readonly onTargetBlur = (event: FocusEvent) => {\n if (UI.focus.containsDeep(this.domElement, event.relatedTarget as Node | null)) return\n this.schedule(false, 0, event)\n }\n\n /** Click on the target (`click`): toggle. */\n @E.untracked\n private readonly onTargetClick = (event: MouseEvent) => {\n this.requestVisible(!this.isVisible, event)\n }\n\n ////////////////\n // ## The popup itself\n ////////////////\n\n /** Pointer onto the popup: keep a hovered popup open, unless `hoverable` is off (Fomantic's default). */\n @E.on(\"pointerenter\")\n protected onPopupEnter() {\n if (this.trigger !== UIT.PopupTrigger.hover) return\n if (this.hoverable !== false) this.delayTimer?.cancel()\n }\n\n /** Pointer off the popup: hide a hovered popup after `hide-delay`. */\n @E.on(\"pointerleave\")\n protected onPopupLeave(event: PointerEvent) {\n if (this.trigger === UIT.PopupTrigger.hover) this.schedule(false, this.hideDelay ?? 0, event)\n }\n\n /** Focus off the popup (`focus`): hide, unless it went back to the target. */\n @E.on(\"focusout\")\n protected onPopupFocusOut(event: FocusEvent) {\n if (this.trigger !== UIT.PopupTrigger.focus) return\n const next = event.relatedTarget as Node | null\n const target = this.targetElement\n if (UI.focus.containsDeep(this.domElement, next) || (target && next && UI.focus.containsDeep(target, next))) return\n this.schedule(false, 0, event)\n }\n\n ////////////////\n // ## The DOM element's role, name, position and popover\n ////////////////\n\n /** The DOM element is a dialog for a click popup, else a tooltip. */\n @E.aria(\"role\")\n protected get ariaRole(): string {\n return this.isInteractive ? \"dialog\" : \"tooltip\"\n }\n\n /** A click popup's dialog is named by `header`. */\n @E.aria(\"label\")\n protected get accessibleName(): string | undefined {\n return this.isInteractive ? this.heading : undefined\n }\n\n /** SIDE EFFECT: the DOM element's `position-area` follows `position`. */\n @E.onChange(\"position\", \"point\", { writesDOMElement: true })\n protected onPositionChanged(position: string | undefined, point: UIT.PopupPoint | undefined) {\n const area = point ? AT_POINT_POSITION : (position ?? DEFAULT_POSITION)\n this.domElement.style.setProperty(\"position-area\", POSITION_AREAS[area])\n }\n\n /**\n * `popover` mode for the current trigger, see class docs.\n * - `manual` popups too stay `manual`:\n * the page decides, so several may be open at once (a `hint` closes the other hints).\n */\n private get popoverMode(): PopoverMode {\n const trigger = this.trigger\n const isHintable = trigger === UIT.PopupTrigger.hover || trigger === UIT.PopupTrigger.focus\n return isHintable && UI.browser.supports.popoverHint ? \"hint\" : \"manual\"\n }\n\n /**\n * Once ready, the DOM element's `popover` follows the trigger (`popoverMode`).\n * - Reads `popoverMode` HERE, not as a member of the effect: it reads `UI.browser`, which exists only once ready.\n */\n @E.onChange(\"isReady\", \"trigger\")\n protected onPopoverModeChanged(isReady: boolean) {\n if (!isReady) return\n const mode = this.popoverMode\n if (this.domElement.popover !== mode) this.domElement.popover = mode\n }\n\n /**\n * `popover` of the ROOT in a server render (`spell/ui/static`), where the root replaces the DOM element:\n * hidden until opened, in the HTML.\n * - `auto` for a click popup: light dismiss and Escape without JS, once something opens it (`popovertarget`).\n * - `manual` for the rest (`hint` isn't everywhere, and an unknown value means `manual`).\n */\n private get serverPopover(): PopoverMode {\n return this.isInteractive ? \"auto\" : \"manual\"\n }\n\n ////////////////\n // ## Classes and states\n ////////////////\n\n /**\n * The position words before the noun, then Fomantic's `visible` while shown: `ui top left visible popup`.\n * - After the position: a phrase rule (`[class*=\"left top\"]`) needs its words side by side.\n */\n protected get extraClass(): string | undefined {\n const position = this.point ? `${BASIC_CLASS} ${AT_POINT_POSITION}` : (this.position ?? DEFAULT_POSITION)\n return this.isVisible ? `${position} ${SHOWN_CLASS}` : position\n }\n\n ////////////////\n // ## Rendering\n ////////////////\n\n /**\n * Adds the server render's target binding (`serverBind()`) to `UIComponent.onMount()`;\n * the role and name (`@aria`) and the position effect (`writesDOMElement`) write the DOM element there too.\n */\n onMount(): JSX.Element {\n if (isServer) this.serverBind()\n return super.onMount()\n }\n\n render(): JSX.Element {\n if (isServer) return this.serverMarkup()\n return (\n <div ref={(element) => (this.box = element)} class={this.rootClass} part={this.partForName(\"popup\")}>\n <Show when={this.heading}>\n <div class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </div>\n </Show>\n <Show when={this.label}>\n <div class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </div>\n </Show>\n <slot />\n </div>\n )\n }\n\n /**\n * The static markup of a server render (`spell/ui/static`), where the root replaces the DOM element:\n * - a popover itself (`serverPopover`): hidden until opened, in the HTML\n * - PHRASING content (`<span>`s): a popup often sits in running text, after a `<dfn>` or a button in a `<p>`,\n * where its DOM element was valid; a `<div>` would close the `<p>` when a browser parses the page\n */\n private serverMarkup(): JSX.Element {\n return (\n <span class={this.rootClass} part={this.partForName(\"popup\")} popover={this.serverPopover}>\n <Show when={this.heading}>\n <span class={UIT.HEADER} part={this.partForName(\"header\")}>\n {this.heading}\n </span>\n </Show>\n <Show when={this.label}>\n <span class={UIT.CONTENT} part={this.partForName(\"content\")}>\n {this.label}\n </span>\n </Show>\n <slot />\n </span>\n )\n }\n\n ////////////////\n // ## Targets\n ////////////////\n\n /**\n * `value` is an element: by node type, since a server render (`spell/ui/static`) has no `Element` global.\n * - STATIC: pure.\n */\n private static isElement(value: unknown): value is Element {\n return typeof value === \"object\" && value !== null && (value as Node).nodeType === E.NodeType.element\n }\n\n /**\n * The box to anchor to: `target`, or -- when it has none (`display: contents`) --\n * the first element of its shadow root, else its first child element.\n * - STATIC: needs no instance, only the target.\n */\n private static anchorBoxFor(target: Element): Element {\n if (getComputedStyle(target).display !== CONTENTS) return target\n return target.shadowRoot?.firstElementChild ?? target.firstElementChild ?? target\n }\n\n /**\n * The element that takes focus for `target`: a `delegatesFocus` DOM element's first focusable, else `target`.\n * - STATIC: needs no instance, only the target.\n */\n private static ariaTargetFor(target: Element): Element {\n const root = target.shadowRoot\n return (root?.delegatesFocus && UI.focus.first(root)) || target\n }\n\n ////////////////\n // ## Target markup: light DOM the popup doesn't own\n ////////////////\n\n /**\n * Add `name` to `element`'s inline `anchor-name` LIST:\n * several popups can share one target, and the page may name it too.\n * - STATIC: needs no instance; every popup bound to one target writes the same list.\n */\n private static addAnchorName(element: Element, name: string) {\n const style = (element as HTMLElement).style\n if (!style) return\n const names = UIPopup.anchorNamesIn(style)\n if (!names.includes(name)) style.setProperty(\"anchor-name\", [...names, name].join(\", \"))\n }\n\n /**\n * Remove `name` from `element`'s inline `anchor-name`; drops the property when none are left.\n * - STATIC: as `addAnchorName()`.\n */\n private static removeAnchorName(element: Element, name: string) {\n const style = (element as HTMLElement).style\n if (!style) return\n const names = UIPopup.anchorNamesIn(style).filter((each) => each !== name)\n if (names.length) style.setProperty(\"anchor-name\", names.join(\", \"))\n else style.removeProperty(\"anchor-name\")\n }\n\n /**\n * Names in `style`'s `anchor-name`.\n * - STATIC: pure.\n */\n private static anchorNamesIn(style: CSSStyleDeclaration): string[] {\n const value = style.getPropertyValue(\"anchor-name\").trim()\n return value && value !== \"none\" ? value.split(\",\").map((name) => name.trim()) : []\n }\n\n /**\n * Point `element`'s idref `relation` (`aria-describedby`, `aria-controls`) at `domElement` too,\n * ADDED to what's there; returns the undo.\n * - The attribute's token list when both share a tree,\n * else element reflection (`ariaDescribedByElements`), since an idref can't cross a shadow boundary.\n * - The undo keeps the way it was added:\n * by the time it runs the DOM element may be detached (its root is then itself),\n * which must not switch an attribute token list over to reflection.\n * - STATIC: needs no instance; a server render (`serverBind()`) and a live binding (`bind()`) share it.\n */\n private static addAriaRelation({ element, relation, domElement }: AriaRelationProps): () => void {\n const reflected = element as unknown as Record<string, Element[] | null>\n if (element.getRootNode() === domElement.getRootNode()) {\n const id = domElement.id\n const ids = UIPopup.idsIn(element, relation.attribute)\n if (!ids.includes(id)) element.setAttribute(relation.attribute, [...ids, id].join(\" \"))\n return () => {\n const rest = UIPopup.idsIn(element, relation.attribute).filter((each) => each !== id)\n if (rest.length) element.setAttribute(relation.attribute, rest.join(\" \"))\n else element.removeAttribute(relation.attribute)\n }\n }\n const elements = reflected[relation.property] ?? []\n if (!elements.includes(domElement)) reflected[relation.property] = [...elements, domElement]\n return () => {\n const rest = (reflected[relation.property] ?? []).filter((each) => each !== domElement)\n // `null`, not `undefined`: element reflection is a platform property, cleared by `null`\n reflected[relation.property] = rest.length ? rest : null\n }\n }\n\n /**\n * Ids in `element`'s `attribute`.\n * - STATIC: pure.\n */\n private static idsIn(element: Element, attribute: string): string[] {\n return (element.getAttribute(attribute) ?? \"\").split(UIT.WHITESPACE).filter(Boolean)\n }\n}\n\n/** The vocabulary's attribute getters, typed (see \"Attributes\" in `UIComponent`). */\nexport interface UIPopup extends E.AttributeValues<Vocabulary> {}\n\n/** The vocabulary type, for brevity. */\ntype Vocabulary = typeof popupVocabulary\n\n/** An idref ARIA relation: its attribute and its element-reflection property. */\ntype AriaRelation = {\n /** the idref attribute, e.g. `aria-describedby` */\n attribute: string\n /** its element-reflection property, e.g. `ariaDescribedByElements` (an idref can't cross a shadow boundary) */\n property: string\n}\n\n/** `showPopover()` options with `source` (not in every DOM lib yet). */\ntype ShowPopoverOptions = {\n /** the invoker: the implicit anchor, and where Tab continues from */\n source?: HTMLElement\n}\n\n/**\n * A `popover` value the component sets on its DOM element (or, in a server render, on its root):\n * - `auto`: light dismiss; only a server render's click popup\n * - `manual`: the page (or the component) decides; click and manual popups\n * - `hint`: hover / focus popups, where the browser has it (`UI.browser.supports.popoverHint`)\n */\ntype PopoverMode = \"auto\" | \"manual\" | \"hint\"\n\n/** What `UIPopup.addAriaRelation()` takes. */\ntype AriaRelationProps = {\n /** the element that takes focus for the target */\n element: Element\n /** which idref relation */\n relation: AriaRelation\n /** the popup's DOM element it points at */\n domElement: Element\n}\n\n////////////////\n// ## Constants\n////////////////\n\n/** Fomantic's default position: the popup's class words before its noun, `ui top left popup`. */\nconst DEFAULT_POSITION = \"top left\"\n\n/** Focus with no ring and no scrolling. */\nconst QUIET_FOCUS = { preventScroll: true, focusVisible: false } as FocusOptions\n\n/** Where a popup at a point opens: below it and to its right, until the window's edge flips it. */\nconst AT_POINT_POSITION = \"bottom left\"\n\n/** The class word for no pointing arrow. */\nconst BASIC_CLASS = \"basic\"\n\n/** The token for the gap between a popup and its target. */\nconst DISTANCE_TOKEN = \"--ui-popup-distance\"\n\n/** Fomantic's class word of a shown popup. */\nconst SHOWN_CLASS = \"visible\"\n\n/** Fomantic's default trigger. */\nconst DEFAULT_TRIGGER: UIT.PopupTrigger = UIT.PopupTrigger.hover\n\n/** `UI.ids` prefix. */\nconst ID_PREFIX = \"ui-popup\"\n\n/** Tooltips describe their target. */\nconst DESCRIBED_BY: AriaRelation = { attribute: \"aria-describedby\", property: \"ariaDescribedByElements\" }\n\n/** Click popups are controlled by their target. */\nconst CONTROLS: AriaRelation = { attribute: \"aria-controls\", property: \"ariaControlsElements\" }\n\n/** `ToggleEvent.newState` of a popover the browser closed. */\nconst CLOSED = \"closed\"\n\n/** `display` of a target with no box of its own. */\nconst CONTENTS = \"contents\"\n\n/**\n * `position` => `position-area`: the popup on that side,\n * its edge lined up with the target's (`span-*` grows away from the named corner), or centred on it.\n */\nconst POSITION_AREAS: Readonly<Record<string, string>> = {\n \"top left\": \"top span-right\",\n \"top center\": \"top center\",\n \"top right\": \"top span-left\",\n \"bottom left\": \"bottom span-right\",\n \"bottom center\": \"bottom center\",\n \"bottom right\": \"bottom span-left\",\n \"left center\": \"left center\",\n \"right center\": \"right center\",\n \"left top\": \"left span-bottom\",\n \"left bottom\": \"left span-top\",\n \"right top\": \"right span-bottom\",\n \"right bottom\": \"right span-top\"\n}\n\n/** The page's hover-delay preference, a token (`styles.en.ts`'s `hoverDelay`). */\nconst HOVER_DELAY_TOKEN = \"--ui-hover-delay\"\n\n/** A CSS time: `800ms`, `2s`, `1.5s`. */\nconst DURATION = /^(\\d+(?:\\.\\d+)?)(ms|s)$/\n","/**\n * The popup family: defines `<ui-popup>` and exports its component, `UIPopup`.\n * - SIDE EFFECT: importing it defines `<ui-popup>`, the owner of the `header` and `content` parts.\n * - NOTE: the tooltip (`data-tooltip`) needs no family: the runtime's `DataTooltips` shows it; with no script it's `native.css`'s, a page sheet.\n * - Also the library's `spell/ui/ui-popup` entry (its size is in `notes/report.md`).\n */\n\nimport { UIPopup } from \"./UIPopup\"\n\nUIPopup.define()\n\nexport { UIPopup }\n"],"mappings":";;;;;AAwBA,IAAasD,KAAkB;CAC7B,KAAK;CACL,MAAM;CACN,QAAQ;EAAC;EAAU;EAAY;EAAY;CAAS;CACpD,KAAK;EAAC;EAAW;EAAW;EAAQ;EAAc;CAAa;CAC/D,MAAM;CACN,aAAa;CACb,YAAY;EACV;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,aAAa;EACf;EACA;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,aAAa;EACf;EACA;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,QAAQ,CAAC,OAAO;GAEhB,SAAS,CAAC;GACV,UAAU,CAAC;IAAE,MAAM;IAAS,OAAO;GAAQ,CAAC;GAC5C,aAAa;EACf;EACA;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,aAAa;EACf;EACA;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,aAAa;EACf;EACA;GAAE,MAAM;GAAS,OAAO;GAAU,MAAM;GAAW,aAAa;EAAyB;EACzF;GACE,MAAM;GACN,OAAO;GACP,MAAM;GACN,aAAa;EACf;EACA;GAAE,MAAM;GAAW,OAAO;GAAU,MAAM;GAAW,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AA,IADEG,CAAA,GAEI1C,EAFJ0C,GAEW,gBAAetC,EAAtBmC,GAAA,IAFJG,GAE0B;CACnC,aAAa;EAAE,OAAOhD;EAAU,kBAAkBC;CAAY;CAC9D,WAAW,CAAC,OAAO;CAEnB,gBAAgB;CAEhB,SAAS;CACT,SAAS;CAET,WAAW;AACb,CAAA,CAAA,GAVeS,EAAAmC,GAAA,IAFJG,CAAA;AAAN,IAAMmG,KAANnG,GAsnBD0D,KAAmB,YAGnBpC,KAAc;CAAE,eAAe;CAAM,cAAc;AAAM,GAGzDkC,KAAoB,eAGpBK,KAAc,SAGd7B,IAAiB,uBAGjB8B,KAAc,WAGdzB,KAAAhF,EAAqD,OAGrD0E,IAAY,YAGZgB,KAA6B;CAAE,WAAW;CAAoB,UAAU;AAA0B,GAGlGD,KAAyB;CAAE,WAAW;CAAiB,UAAU;AAAuB,GAGxFb,KAAS,UAGTwD,KAAW,YAMX9B,KAAmD;CACvD,YAAY;CACZ,cAAc;CACd,aAAa;CACb,eAAe;CACf,iBAAiB;CACjB,gBAAgB;CAChB,eAAe;CACf,gBAAgB;CAChB,YAAY;CACZ,eAAe;CACf,aAAa;CACb,gBAAgB;AAClB,GAGMR,KAAoB,oBAGpBE,KAAW;;;ACjuBjB8C,GAAQ,OAAO"}
@@ -1,5 +1,5 @@
1
1
  import "./rolldown-runtime-CYGlBXrH.js";
2
- import { Bt as e, Ft as t, I as n, It as r, Lt as i, Rt as a, UI as o, UIComponent as s, ValueSets as c, Vt as l, clamp as u, cssState as d, derived as f, onChange as p, proto as m, protoMerged as h, watches as g } from "./core.js";
2
+ import { Bt as e, Ht as t, I as n, Lt as r, Rt as i, UI as a, UIComponent as o, Ut as s, ValueSets as c, clamp as l, cssState as u, derived as d, onChange as f, proto as p, protoMerged as m, watches as h, zt as g } from "./core.js";
3
3
  import { Repeat as _, Show as v } from "solid-js";
4
4
  import { className as y, createComponent as b, effect as x, getOwner as S, insert as C, readShallow as w, setAttribute as T, style as E, template as D } from "@solidjs/web";
5
5
  //#region src/components/ui-progress/UIProgress.types.ts
@@ -13,7 +13,7 @@ var O = /[\s,]+/, k = class ProgressValues {
13
13
  precision;
14
14
  constructor(e) {
15
15
  let t = Math.max(0, Math.floor(e.precision ?? 0)), n = e.total !== void 0 && e.total > 0 ? e.total : void 0, r = ProgressValues.list(e.percent), i = ProgressValues.list(e.value), a = r.length ? r : i.length ? i.map((e) => n ? e / n * 100 : e) : [0];
16
- a = a.map((e) => u(e, 0, 100));
16
+ a = a.map((e) => l(e, 0, 100));
17
17
  let o = a.reduce((e, t) => e + t, 0);
18
18
  o > 100 && (a = a.map((e) => e * 100 / o)), this.precision = t, this.total = n, this.percents = a, this.shown = a.map((e) => ProgressValues.round(e, t)), this.percent = ProgressValues.round(a.reduce((e, t) => e + t, 0), t), this.values = n ? a.map((e) => ProgressValues.round(e / 100 * n, t)) : void 0, this.value = this.values ? ProgressValues.round(this.values.reduce((e, t) => e + t, 0), t) : void 0;
19
19
  }
@@ -40,6 +40,8 @@ var O = /[\s,]+/, k = class ProgressValues {
40
40
  }
41
41
  }, A = {
42
42
  tag: "ui-progress",
43
+ icon: "tasks",
44
+ snippet: "<ui-progress percent=\"50\"></ui-progress>",
43
45
  topics: [
44
46
  "progress",
45
47
  "loading",
@@ -269,13 +271,13 @@ var O = /[\s,]+/, k = class ProgressValues {
269
271
  text: "{value} of {total}",
270
272
  description: "`bar-text=\"ratio\"`."
271
273
  }]
272
- }, j = "@layer ui.components.progress.types{:host{display:block}.ui.progress{--_ui-progress-margin:var(--ui-progress-margin,1em);--_ui-progress-label-height:var(--ui-progress-label-height,1.5em);--_ui-progress-background:var(--ui-progress-background,oklch(from var(--ui-ink) l c h / .1));--_ui-progress-radius:var(--ui-progress-radius,var(--ui-radius-s));--_ui-progress-bar-height:var(--ui-progress-bar-height,1.75em);--_ui-progress-bar-background:var(--ui-progress-bar-background,oklch(50% 0 0));--_ui-progress-bar-min-width:var(--ui-progress-bar-min-width,2.5em);--_ui-progress-duration:var(--ui-progress-duration,var(--ui-duration-normal));--_ui-progress-text-size:var(--ui-progress-text-size,.92857em);--_ui-progress-text-color:var(--ui-progress-text-color,oklch(100% 0 0));--_ui-progress-indicating-text-color:var(--ui-progress-indicating-text-color,oklch(20% 0 0));--_ui-progress-label-color:var(--ui-progress-label-color,var(--ui-text-color));--_ui-progress-pulse-color:var(--ui-progress-pulse-color,oklch(100% 0 0));--_ui-progress-pulse-opacity:var(--ui-progress-pulse-opacity,.3);--_ui-progress-pulse-duration:var(--ui-progress-pulse-duration,2s);--_ui-progress-indeterminate-slow:var(--ui-progress-indeterminate-slow,4s);--_ui-progress-indeterminate-fast:var(--ui-progress-indeterminate-fast,1s);--_ui-progress-attached-height:var(--ui-progress-attached-height,.2em);--_ui-progress-inverted-background:var(--ui-progress-inverted-background,oklch(100% 0 0/.08));--_ui-progress-inverted-label-color:var(--ui-progress-inverted-label-color,oklch(100% 0 0));--_ui-progress-disabled-opacity:var(--ui-progress-disabled-opacity,.35);--_ui-progress-indicating-1:var(--ui-progress-indicating-1,oklch(63% .15 22));--_ui-progress-indicating-2:var(--ui-progress-indicating-2,oklch(83% .11 75));--_ui-progress-indicating-3:var(--ui-progress-indicating-3,oklch(81% .13 87));--_ui-progress-indicating-4:var(--ui-progress-indicating-4,oklch(83% .16 102));--_ui-progress-indicating-5:var(--ui-progress-indicating-5,oklch(84% .15 125));--_ui-progress-indicating-6:var(--ui-progress-indicating-6,oklch(80% .16 150));box-sizing:border-box;max-width:100%;margin:var(--_progress-margin-top,var(--_ui-progress-margin)) 0 var(--_progress-margin-bottom,calc(var(--_ui-progress-label-height) + var(--_ui-progress-margin)));border-radius:var(--_ui-progress-radius);background:var(--_ui-progress-background);box-shadow:none;font-family:var(--ui-font-family);font-size:calc(var(--ui-font-size) * var(--ui-scale,1));border:none;padding:0;display:flex;position:relative}.ui.progress:first-child{--_progress-margin-top:0}.ui.progress:last-child{--_progress-margin-bottom:var(--_ui-progress-label-height)}:host(:not(:first-child))>.ui.progress{--_progress-margin-top:initial}:host(:not(:last-child))>.ui.progress{--_progress-margin-bottom:initial}.ui.indicating.progress[data-percent]{--_progress-bar-on:var(--_ui-progress-indicating-text-color)}.ui.indicating.progress:is([data-percent^=\"1\"],[data-percent^=\"2\"]){--_progress-bar-color:var(--_ui-progress-indicating-1)}.ui.indicating.progress[data-percent^=\"3\"]{--_progress-bar-color:var(--_ui-progress-indicating-2)}.ui.indicating.progress:is([data-percent^=\"4\"],[data-percent^=\"5\"]){--_progress-bar-color:var(--_ui-progress-indicating-3)}.ui.indicating.progress[data-percent^=\"6\"]{--_progress-bar-color:var(--_ui-progress-indicating-4)}.ui.indicating.progress:is([data-percent^=\"7\"],[data-percent^=\"8\"]){--_progress-bar-color:var(--_ui-progress-indicating-5)}.ui.indicating.progress:is([data-percent^=\"9\"],[data-percent=\"100\"]){--_progress-bar-color:var(--_ui-progress-indicating-6)}.ui.indicating.progress:is([data-percent=\"1\"],[data-percent=\"2\"],[data-percent=\"3\"],[data-percent=\"4\"],[data-percent=\"5\"],[data-percent=\"6\"],[data-percent=\"7\"],[data-percent=\"8\"],[data-percent=\"9\"]){--_progress-bar-color:var(--_ui-progress-indicating-1)}}@layer ui.components.progress.content{.ui.progress .bar{box-sizing:border-box;width:0;height:var(--_ui-progress-bar-height);border-radius:var(--_ui-progress-radius);background:var(--_progress-bar-color,var(--ui-color,var(--_ui-progress-bar-background)));color:var(--_progress-bar-on,var(--ui-color-on,var(--_ui-progress-text-color)));transition:width var(--_ui-progress-duration) var(--ui-ease), background-color var(--_ui-progress-duration) var(--ui-ease);line-height:1;display:block;position:relative;overflow:hidden}.ui.progress .bar:not(:empty){min-width:var(--_ui-progress-bar-min-width)}.ui.progress .bar>.progress{width:auto;color:inherit;font-size:var(--_ui-progress-text-size);font-weight:var(--ui-font-weight-bold);text-align:left;text-shadow:none;white-space:nowrap;margin-top:-.5em;position:absolute;inset:50% .5em auto auto}.ui.progress>.label{width:100%;margin-top:calc(var(--_ui-progress-label-height) - 1.3em);color:var(--_progress-label-color,var(--_ui-progress-label-color));font-size:1em;font-weight:var(--ui-font-weight-bold);text-align:center;text-shadow:none;transition:color .4s var(--ui-ease);position:absolute;inset:100% auto auto 0}}@layer ui.components.progress.variations{.ui.basic.progress{box-shadow:none;background:0 0;border:none}.ui.right.aligned.progress{justify-content:flex-end}.ui.right.aligned.progress .bar>.progress{left:.5em;right:auto}.ui.inverted.progress{--_ui-progress-label-color:var(--_ui-progress-inverted-label-color);color-scheme:dark;--ui-scheme:dark}.ui.inverted.progress:not(.basic){background:var(--_ui-progress-inverted-background);border:none}.ui.inverted.progress .bar{background:var(--_progress-bar-color,var(--ui-color-inverted,var(--_ui-progress-bar-background)));color:var(--_progress-bar-on,var(--ui-color-inverted-on,var(--_ui-progress-text-color)))}.ui.attached.progress,.ui.bottom.attached.progress{background:0 0;border:none;margin:0;position:relative}.ui.attached.progress,.ui.attached.progress .bar{height:var(--_ui-progress-attached-height);border-radius:0 0 var(--_ui-progress-radius) var(--_ui-progress-radius);padding:0;overflow:hidden}.ui.attached.progress .bar{border-radius:0}.ui.top.attached.progress,.ui.top.attached.progress .bar{border-radius:var(--_ui-progress-radius) var(--_ui-progress-radius) 0 0;top:0}.ui.top.attached.progress .bar{border-radius:0}.ui.mini.progress{--_ui-progress-bar-height:.3em}.ui.tiny.progress{--_ui-progress-bar-height:.5em}.ui.small.progress{--_ui-progress-bar-height:1em}.ui.large.progress{--_ui-progress-bar-height:2.5em}.ui.big.progress{--_ui-progress-bar-height:3.5em}.ui.huge.progress{--_ui-progress-bar-height:4em}.ui.massive.progress{--_ui-progress-bar-height:5em}.ui.indeterminate.progress .bar{width:100%}.ui.indeterminate.progress .bar .progress{text-align:center;position:relative;right:0}.ui.indeterminate.progress .bar:before{content:\"\";border-radius:var(--_ui-progress-radius);background:var(--_ui-progress-pulse-color);width:100%;animation:progress-pulsating var(--_ui-progress-pulse-duration) var(--ui-ease) infinite;transform-origin:50%;position:absolute;top:0;bottom:0}.ui.slow.indeterminate.progress .bar:before{animation-duration:var(--_ui-progress-indeterminate-slow)}.ui.fast.indeterminate.progress .bar:before{animation-duration:var(--_ui-progress-indeterminate-fast)}.ui.swinging.indeterminate.progress .bar:before{transform-origin:0;animation-name:progress-swinging}.ui.sliding.indeterminate.progress .bar:before{transform-origin:0;animation-name:progress-sliding}.ui.filling.indeterminate.progress .bar:before{animation-name:progress-filling}.ui:is(.sliding,.swinging,.filling).indeterminate.progress .bar{background:var(--_ui-progress-background)}.ui:is(.sliding,.swinging,.filling).indeterminate.progress .bar:before{background:var(--_progress-bar-color,var(--ui-color,var(--_ui-progress-bar-background)))}.ui:is(.sliding,.swinging).indeterminate.progress .bar .progress{color:var(--ui-text-color)}.ui.inverted:is(.sliding,.swinging,.filling).indeterminate.progress .bar{background:var(--_ui-progress-inverted-background)}.ui.inverted:is(.sliding,.swinging,.filling).indeterminate.progress .bar:before{background:var(--_progress-bar-color,var(--ui-color-inverted,var(--_ui-progress-bar-background)))}.ui.inverted:is(.sliding,.swinging).indeterminate.progress .bar .progress{color:var(--ui-text-inverted-color)}@keyframes progress-pulsating{0%{opacity:.7;transform:scaleX(0)}to{opacity:0;transform:scale(1)}}@keyframes progress-swinging{0%,to{width:10%;left:-25%}25%,65%{width:70%}50%{width:10%;left:100%}}@keyframes progress-sliding{0%{width:10%;left:-25%}50%{width:70%}to{width:10%;left:100%}}@keyframes progress-filling{0%{transform:scaleX(0)}80%{opacity:1;transform:scale(1)}to{opacity:0}}}@layer ui.components.progress.states{.ui.active.progress .bar{position:relative}.ui.active.progress .bar:not(:empty){min-width:var(--_ui-progress-bar-min-width)}.ui.active.progress .bar:after{content:\"\";border-radius:var(--_ui-progress-radius);background:var(--_ui-progress-pulse-color);opacity:0;animation:progress-active var(--_ui-progress-pulse-duration) var(--ui-ease) infinite;transform-origin:0;position:absolute;inset:0}.ui.active.right.aligned.progress .bar:after{transform-origin:100%}@keyframes progress-active{0%{opacity:var(--_ui-progress-pulse-opacity);transform:scaleX(0)}to{opacity:0;transform:scale(1)}}.ui.progress:not([data-percent],.indeterminate) .bar:not(:empty),.ui.progress[data-percent=\"0\"]:not(.indeterminate) .bar:not(:empty){background:0 0}.ui.progress[data-percent=\"0\"] .bar .progress{color:var(--ui-text-color)}.ui.inverted.progress[data-percent=\"0\"] .bar .progress{color:var(--ui-text-inverted-color)}.ui.success.progress{--_progress-bar-color:var(--ui-success);--_progress-bar-on:var(--ui-success-on);--_progress-label-color:var(--ui-success-header)}.ui.warning.progress{--_progress-bar-color:var(--ui-warning);--_progress-bar-on:var(--ui-warning-on);--_progress-label-color:var(--ui-warning-header)}.ui.error.progress{--_progress-bar-color:var(--ui-error);--_progress-bar-on:var(--ui-error-on);--_progress-label-color:var(--ui-error-header)}.ui.inverted.success.progress{--_progress-label-color:var(--ui-success)}.ui.inverted.warning.progress{--_progress-label-color:var(--ui-warning)}.ui.inverted.error.progress{--_progress-label-color:var(--ui-error)}.ui:is(.success,.warning,.error).progress .bar,.ui:is(.success,.warning,.error).progress .bar:after{animation:none}.ui.disabled.progress{opacity:var(--_ui-progress-disabled-opacity)}.ui.disabled.progress .bar,.ui.disabled.progress .bar:before,.ui.disabled.progress .bar:after{animation:none}@media (prefers-reduced-motion:reduce){.ui.progress .bar,.ui.progress .bar:after{transition:none;animation:none}.ui.active.progress .bar:after{display:none}.ui.indeterminate.progress .bar:before{opacity:.5;width:100%;animation:none;left:0;transform:none}}}", M = /* @__PURE__ */ D("<div><div><slot>"), N = /* @__PURE__ */ D("<div>"), P, F, I, L, R, z, B, V, H, U, W, G = class _UIProgress extends (U = s, H = [m], V = [h], B = [f], z = [p("numbers", { defer: !0 })], R = [d("indeterminate")], L = [d("complete")], I = [g({
274
+ }, j = "@layer ui.components.progress.types{:host{display:block}.ui.progress{--_ui-progress-margin:var(--ui-progress-margin,1em);--_ui-progress-label-height:var(--ui-progress-label-height,1.5em);--_ui-progress-background:var(--ui-progress-background,oklch(from var(--ui-ink) l c h / .1));--_ui-progress-radius:var(--ui-progress-radius,var(--ui-radius-s));--_ui-progress-bar-height:var(--ui-progress-bar-height,1.75em);--_ui-progress-bar-background:var(--ui-progress-bar-background,oklch(50% 0 0));--_ui-progress-bar-min-width:var(--ui-progress-bar-min-width,2.5em);--_ui-progress-duration:var(--ui-progress-duration,var(--ui-duration-normal));--_ui-progress-text-size:var(--ui-progress-text-size,.92857em);--_ui-progress-text-color:var(--ui-progress-text-color,oklch(100% 0 0));--_ui-progress-indicating-text-color:var(--ui-progress-indicating-text-color,oklch(20% 0 0));--_ui-progress-label-color:var(--ui-progress-label-color,var(--ui-text-color));--_ui-progress-pulse-color:var(--ui-progress-pulse-color,oklch(100% 0 0));--_ui-progress-pulse-opacity:var(--ui-progress-pulse-opacity,.3);--_ui-progress-pulse-duration:var(--ui-progress-pulse-duration,2s);--_ui-progress-indeterminate-slow:var(--ui-progress-indeterminate-slow,4s);--_ui-progress-indeterminate-fast:var(--ui-progress-indeterminate-fast,1s);--_ui-progress-attached-height:var(--ui-progress-attached-height,.2em);--_ui-progress-inverted-background:var(--ui-progress-inverted-background,oklch(100% 0 0/.08));--_ui-progress-inverted-label-color:var(--ui-progress-inverted-label-color,oklch(100% 0 0));--_ui-progress-disabled-opacity:var(--ui-progress-disabled-opacity,.35);--_ui-progress-indicating-1:var(--ui-progress-indicating-1,oklch(63% .15 22));--_ui-progress-indicating-2:var(--ui-progress-indicating-2,oklch(83% .11 75));--_ui-progress-indicating-3:var(--ui-progress-indicating-3,oklch(81% .13 87));--_ui-progress-indicating-4:var(--ui-progress-indicating-4,oklch(83% .16 102));--_ui-progress-indicating-5:var(--ui-progress-indicating-5,oklch(84% .15 125));--_ui-progress-indicating-6:var(--ui-progress-indicating-6,oklch(80% .16 150));box-sizing:border-box;max-width:100%;margin:var(--_progress-margin-top,var(--_ui-progress-margin)) 0 var(--_progress-margin-bottom,calc(var(--_ui-progress-label-height) + var(--_ui-progress-margin)));border-radius:var(--_ui-progress-radius);background:var(--_ui-progress-background);box-shadow:none;font-family:var(--ui-font-family);font-size:calc(var(--ui-font-size) * var(--ui-scale,1));border:none;padding:0;display:flex;position:relative}.ui.progress:first-child{--_progress-margin-top:0}.ui.progress:last-child{--_progress-margin-bottom:var(--_ui-progress-label-height)}:host(:not(:first-child))>.ui.progress{--_progress-margin-top:initial}:host(:not(:last-child))>.ui.progress{--_progress-margin-bottom:initial}.ui.indicating.progress[data-percent]{--_progress-bar-on:var(--_ui-progress-indicating-text-color)}.ui.indicating.progress:is([data-percent^=\"1\"],[data-percent^=\"2\"]){--_progress-bar-color:var(--_ui-progress-indicating-1)}.ui.indicating.progress[data-percent^=\"3\"]{--_progress-bar-color:var(--_ui-progress-indicating-2)}.ui.indicating.progress:is([data-percent^=\"4\"],[data-percent^=\"5\"]){--_progress-bar-color:var(--_ui-progress-indicating-3)}.ui.indicating.progress[data-percent^=\"6\"]{--_progress-bar-color:var(--_ui-progress-indicating-4)}.ui.indicating.progress:is([data-percent^=\"7\"],[data-percent^=\"8\"]){--_progress-bar-color:var(--_ui-progress-indicating-5)}.ui.indicating.progress:is([data-percent^=\"9\"],[data-percent=\"100\"]){--_progress-bar-color:var(--_ui-progress-indicating-6)}.ui.indicating.progress:is([data-percent=\"1\"],[data-percent=\"2\"],[data-percent=\"3\"],[data-percent=\"4\"],[data-percent=\"5\"],[data-percent=\"6\"],[data-percent=\"7\"],[data-percent=\"8\"],[data-percent=\"9\"]){--_progress-bar-color:var(--_ui-progress-indicating-1)}}@layer ui.components.progress.content{.ui.progress .bar{box-sizing:border-box;width:0;height:var(--_ui-progress-bar-height);border-radius:var(--_ui-progress-radius);background:var(--_progress-bar-color,var(--ui-color,var(--_ui-progress-bar-background)));color:var(--_progress-bar-on,var(--ui-color-on,var(--_ui-progress-text-color)));transition:width var(--_ui-progress-duration) var(--ui-ease), background-color var(--_ui-progress-duration) var(--ui-ease);line-height:1;display:block;position:relative;overflow:hidden}.ui.progress .bar:not(:empty){min-width:var(--_ui-progress-bar-min-width)}.ui.progress .bar>.progress{width:auto;color:inherit;font-size:var(--_ui-progress-text-size);font-weight:var(--ui-font-weight-bold);text-align:left;text-shadow:none;white-space:nowrap;margin-top:-.5em;position:absolute;inset:50% .5em auto auto}.ui.progress>.label{width:100%;margin-top:calc(var(--_ui-progress-label-height) - 1.3em);color:var(--_progress-label-color,var(--_ui-progress-label-color));font-size:1em;font-weight:var(--ui-font-weight-bold);text-align:center;text-shadow:none;transition:color .4s var(--ui-ease);position:absolute;inset:100% auto auto 0}}@layer ui.components.progress.variations{.ui.basic.progress{box-shadow:none;background:0 0;border:none}.ui.right.aligned.progress{justify-content:flex-end}.ui.right.aligned.progress .bar>.progress{left:.5em;right:auto}.ui.inverted.progress{--_ui-progress-label-color:var(--_ui-progress-inverted-label-color);color-scheme:dark;--ui-scheme:dark}.ui.inverted.progress:not(.basic){background:var(--_ui-progress-inverted-background);border:none}.ui.inverted.progress .bar{background:var(--_progress-bar-color,var(--ui-color-inverted,var(--_ui-progress-bar-background)));color:var(--_progress-bar-on,var(--ui-color-inverted-on,var(--_ui-progress-text-color)))}.ui.attached.progress,.ui.bottom.attached.progress{background:0 0;border:none;margin:0;position:relative}.ui.attached.progress,.ui.attached.progress .bar{height:var(--_ui-progress-attached-height);border-radius:0 0 var(--_ui-progress-radius) var(--_ui-progress-radius);padding:0;overflow:hidden}.ui.attached.progress .bar{border-radius:0}.ui.top.attached.progress,.ui.top.attached.progress .bar{border-radius:var(--_ui-progress-radius) var(--_ui-progress-radius) 0 0;top:0}.ui.top.attached.progress .bar{border-radius:0}.ui.mini.progress{--_ui-progress-bar-height:.3em}.ui.tiny.progress{--_ui-progress-bar-height:.5em}.ui.small.progress{--_ui-progress-bar-height:1em}.ui.large.progress{--_ui-progress-bar-height:2.5em}.ui.big.progress{--_ui-progress-bar-height:3.5em}.ui.huge.progress{--_ui-progress-bar-height:4em}.ui.massive.progress{--_ui-progress-bar-height:5em}.ui.indeterminate.progress .bar{width:100%}.ui.indeterminate.progress .bar .progress{text-align:center;position:relative;right:0}.ui.indeterminate.progress .bar:before{content:\"\";border-radius:var(--_ui-progress-radius);background:var(--_ui-progress-pulse-color);width:100%;animation:progress-pulsating var(--_ui-progress-pulse-duration) var(--ui-ease) infinite;transform-origin:50%;position:absolute;top:0;bottom:0}.ui.slow.indeterminate.progress .bar:before{animation-duration:var(--_ui-progress-indeterminate-slow)}.ui.fast.indeterminate.progress .bar:before{animation-duration:var(--_ui-progress-indeterminate-fast)}.ui.swinging.indeterminate.progress .bar:before{transform-origin:0;animation-name:progress-swinging}.ui.sliding.indeterminate.progress .bar:before{transform-origin:0;animation-name:progress-sliding}.ui.filling.indeterminate.progress .bar:before{animation-name:progress-filling}.ui:is(.sliding,.swinging,.filling).indeterminate.progress .bar{background:var(--_ui-progress-background)}.ui:is(.sliding,.swinging,.filling).indeterminate.progress .bar:before{background:var(--_progress-bar-color,var(--ui-color,var(--_ui-progress-bar-background)))}.ui:is(.sliding,.swinging).indeterminate.progress .bar .progress{color:var(--ui-text-color)}.ui.inverted:is(.sliding,.swinging,.filling).indeterminate.progress .bar{background:var(--_ui-progress-inverted-background)}.ui.inverted:is(.sliding,.swinging,.filling).indeterminate.progress .bar:before{background:var(--_progress-bar-color,var(--ui-color-inverted,var(--_ui-progress-bar-background)))}.ui.inverted:is(.sliding,.swinging).indeterminate.progress .bar .progress{color:var(--ui-text-inverted-color)}@keyframes progress-pulsating{0%{opacity:.7;transform:scaleX(0)}to{opacity:0;transform:scale(1)}}@keyframes progress-swinging{0%,to{width:10%;left:-25%}25%,65%{width:70%}50%{width:10%;left:100%}}@keyframes progress-sliding{0%{width:10%;left:-25%}50%{width:70%}to{width:10%;left:100%}}@keyframes progress-filling{0%{transform:scaleX(0)}80%{opacity:1;transform:scale(1)}to{opacity:0}}}@layer ui.components.progress.states{.ui.active.progress .bar{position:relative}.ui.active.progress .bar:not(:empty){min-width:var(--_ui-progress-bar-min-width)}.ui.active.progress .bar:after{content:\"\";border-radius:var(--_ui-progress-radius);background:var(--_ui-progress-pulse-color);opacity:0;animation:progress-active var(--_ui-progress-pulse-duration) var(--ui-ease) infinite;transform-origin:0;position:absolute;inset:0}.ui.active.right.aligned.progress .bar:after{transform-origin:100%}@keyframes progress-active{0%{opacity:var(--_ui-progress-pulse-opacity);transform:scaleX(0)}to{opacity:0;transform:scale(1)}}.ui.progress:not([data-percent],.indeterminate) .bar:not(:empty),.ui.progress[data-percent=\"0\"]:not(.indeterminate) .bar:not(:empty){background:0 0}.ui.progress[data-percent=\"0\"] .bar .progress{color:var(--ui-text-color)}.ui.inverted.progress[data-percent=\"0\"] .bar .progress{color:var(--ui-text-inverted-color)}.ui.success.progress{--_progress-bar-color:var(--ui-success);--_progress-bar-on:var(--ui-success-on);--_progress-label-color:var(--ui-success-header)}.ui.warning.progress{--_progress-bar-color:var(--ui-warning);--_progress-bar-on:var(--ui-warning-on);--_progress-label-color:var(--ui-warning-header)}.ui.error.progress{--_progress-bar-color:var(--ui-error);--_progress-bar-on:var(--ui-error-on);--_progress-label-color:var(--ui-error-header)}.ui.inverted.success.progress{--_progress-label-color:var(--ui-success)}.ui.inverted.warning.progress{--_progress-label-color:var(--ui-warning)}.ui.inverted.error.progress{--_progress-label-color:var(--ui-error)}.ui:is(.success,.warning,.error).progress .bar,.ui:is(.success,.warning,.error).progress .bar:after{animation:none}.ui.disabled.progress{opacity:var(--_ui-progress-disabled-opacity)}.ui.disabled.progress .bar,.ui.disabled.progress .bar:before,.ui.disabled.progress .bar:after{animation:none}@media (prefers-reduced-motion:reduce){.ui.progress .bar,.ui.progress .bar:after{transition:none;animation:none}.ui.active.progress .bar:after{display:none}.ui.indeterminate.progress .bar:before{opacity:.5;width:100%;animation:none;left:0;transform:none}}}", M = /* @__PURE__ */ D("<div><div><slot>"), N = /* @__PURE__ */ D("<div>"), P, F, I, L, R, z, B, V, H, U, W, G = class _UIProgress extends (U = o, H = [p], V = [m], B = [d], z = [f("numbers", { defer: !0 })], R = [u("indeterminate")], L = [u("complete")], I = [h({
273
275
  childList: !0,
274
276
  characterData: !0,
275
277
  subtree: !0
276
- })], F = [p("ariaValues", { writesDOMElement: !0 })], P = [f], U) {
278
+ })], F = [f("ariaValues", { writesDOMElement: !0 })], P = [d], U) {
277
279
  constructor() {
278
- super(...arguments), l(W, 5, this), e(this, "lastAnnouncedPercent", this.numbers.percent), e(this, "format", /* @__PURE__ */ a((e) => o.i18n.formatNumber(e, { maximumFractionDigits: this.numbers.precision }), "format"));
280
+ super(...arguments), s(W, 5, this), t(this, "lastAnnouncedPercent", this.numbers.percent), t(this, "format", /* @__PURE__ */ e((e) => a.i18n.formatNumber(e, { maximumFractionDigits: this.numbers.precision }), "format"));
279
281
  }
280
282
  get numbers() {
281
283
  return new k({
@@ -401,7 +403,7 @@ var O = /[\s,]+/, k = class ProgressValues {
401
403
  }), c) : c;
402
404
  }
403
405
  };
404
- W = i(U), t(W, 2, "numbers", B, G), t(W, 1, "onNumbersChanged", z, G), t(W, 2, "isIndeterminate", R, G), t(W, 2, "isComplete", L, G), t(W, 2, "elementText", I, G), t(W, 1, "onAriaValuesChanged", F, G), t(W, 2, "barHues", P, G), t(W, 13, "vocabulary", H, G), t(W, 13, "elementSetup", V, G), r(W, G), a(G, "UIProgress"), e(G, "vocabulary", l(W, 8, G, A)), l(W, 11, G), e(G, "elementSetup", l(W, 12, G, {
406
+ W = g(U), r(W, 2, "numbers", B, G), r(W, 1, "onNumbersChanged", z, G), r(W, 2, "isIndeterminate", R, G), r(W, 2, "isComplete", L, G), r(W, 2, "elementText", I, G), r(W, 1, "onAriaValuesChanged", F, G), r(W, 2, "barHues", P, G), r(W, 13, "vocabulary", H, G), r(W, 13, "elementSetup", V, G), i(W, G), e(G, "UIProgress"), t(G, "vocabulary", s(W, 8, G, A)), s(W, 11, G), t(G, "elementSetup", s(W, 12, G, {
405
407
  styleSheets: { progress: j },
406
408
  cssStates: ["active"],
407
409
  delegatesFocus: !1,
@@ -410,7 +412,7 @@ W = i(U), t(W, 2, "numbers", B, G), t(W, 1, "onNumbersChanged", z, G), t(W, 2, "
410
412
  valueMin: "0"
411
413
  },
412
414
  disabled: "its own"
413
- })), l(W, 15, G);
415
+ })), s(W, 15, G);
414
416
  var K = G, q = "success", J = "ratio", Y = ", ", X = "progress";
415
417
  //#endregion
416
418
  //#region src/components/ui-progress/index.ts