@fusion.dev/helix-headless 0.146.0 → 0.148.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (288) hide show
  1. package/custom-elements.json +9287 -1084
  2. package/dist/accordion/item/accordion-item.d.ts +43 -21
  3. package/dist/accordion/item/accordion-item.js +37 -11
  4. package/dist/accordion/root/accordion-root.d.ts +8 -2
  5. package/dist/accordion/root/accordion-root.js +6 -8
  6. package/dist/announcement/root/announcement-root.d.ts +66 -6
  7. package/dist/announcement/root/announcement-root.js +144 -13
  8. package/dist/area-chart/root/area-chart-root.d.ts +18 -1
  9. package/dist/area-chart/root/area-chart-root.js +14 -7
  10. package/dist/avatar/root/avatar-root.d.ts +31 -1
  11. package/dist/avatar/root/avatar-root.js +11 -1
  12. package/dist/badge/count.d.ts +14 -0
  13. package/dist/badge/count.js +20 -0
  14. package/dist/badge/root/badge-root.d.ts +57 -6
  15. package/dist/badge/root/badge-root.js +77 -8
  16. package/dist/bar-chart/root/bar-chart-root.js +11 -20
  17. package/dist/bar-chart/stack.d.ts +10 -0
  18. package/dist/bar-chart/stack.js +8 -0
  19. package/dist/blockquote/root/blockquote-root.d.ts +66 -8
  20. package/dist/blockquote/root/blockquote-root.js +85 -8
  21. package/dist/breadcrumbs/breadcrumb/breadcrumb.d.ts +14 -0
  22. package/dist/breadcrumbs/breadcrumb/breadcrumb.js +12 -2
  23. package/dist/breadcrumbs/root/breadcrumbs-root.js +2 -2
  24. package/dist/button/root/button-root.d.ts +24 -38
  25. package/dist/button/root/button-root.js +6 -37
  26. package/dist/button/submitter.d.ts +27 -0
  27. package/dist/button/submitter.js +25 -0
  28. package/dist/button-group/arrows.d.ts +14 -0
  29. package/dist/button-group/arrows.js +10 -0
  30. package/dist/button-group/root/button-group-root.d.ts +141 -3
  31. package/dist/button-group/root/button-group-root.js +142 -2
  32. package/dist/canvas/edge-pan.d.ts +61 -0
  33. package/dist/canvas/edge-pan.js +63 -0
  34. package/dist/canvas/node/canvas-node.d.ts +12 -2
  35. package/dist/canvas/node/canvas-node.js +6 -2
  36. package/dist/canvas/root/canvas-document.d.ts +10 -0
  37. package/dist/canvas/root/canvas-document.js +1 -0
  38. package/dist/canvas/root/canvas-root.d.ts +107 -5
  39. package/dist/canvas/root/canvas-root.js +140 -36
  40. package/dist/canvas/snap.d.ts +42 -0
  41. package/dist/canvas/snap.js +32 -0
  42. package/dist/card/root/card-root.d.ts +12 -1
  43. package/dist/card/root/card-root.js +11 -4
  44. package/dist/carousel/root/carousel-root.d.ts +4 -3
  45. package/dist/carousel/root/carousel-root.js +2 -6
  46. package/dist/chat/root/chat-root.d.ts +28 -4
  47. package/dist/chat/root/chat-root.js +12 -7
  48. package/dist/checkbox/root/checkbox-root.js +5 -7
  49. package/dist/checkbox-group/root/checkbox-group-root.d.ts +13 -0
  50. package/dist/checkbox-group/root/checkbox-group-root.js +16 -7
  51. package/dist/checkbox-group/select-all.d.ts +9 -4
  52. package/dist/checkbox-group/select-all.js +1 -1
  53. package/dist/code-block/root/code-block-root.d.ts +41 -18
  54. package/dist/code-block/root/code-block-root.js +21 -6
  55. package/dist/color-input/root/color-input-root.d.ts +11 -0
  56. package/dist/color-input/root/color-input-root.js +12 -5
  57. package/dist/color-picker/channels.js +1 -2
  58. package/dist/color-picker/root/color-picker-root.d.ts +32 -24
  59. package/dist/color-picker/root/color-picker-root.js +99 -55
  60. package/dist/color-picker/wheel.d.ts +28 -0
  61. package/dist/color-picker/wheel.js +15 -0
  62. package/dist/combobox/root/combobox-root.d.ts +83 -11
  63. package/dist/combobox/root/combobox-root.js +81 -18
  64. package/dist/command/root/command-root.d.ts +7 -4
  65. package/dist/command/root/command-root.js +2 -19
  66. package/dist/copy-button/root/copy-button-root.d.ts +16 -1
  67. package/dist/copy-button/root/copy-button-root.js +7 -2
  68. package/dist/data-table/keys.d.ts +0 -18
  69. package/dist/data-table/keys.js +1 -11
  70. package/dist/data-table/root/data-table-root.js +29 -50
  71. package/dist/date-input/root/date-input-root.d.ts +8 -1
  72. package/dist/date-input/root/date-input-root.js +8 -5
  73. package/dist/date-picker/root/date-picker-root.d.ts +14 -9
  74. package/dist/date-picker/root/date-picker-root.js +21 -16
  75. package/dist/description-list/item/description-list-item.d.ts +22 -4
  76. package/dist/description-list/item/description-list-item.js +14 -4
  77. package/dist/divider/root/divider-root.d.ts +45 -16
  78. package/dist/divider/root/divider-root.js +28 -4
  79. package/dist/donut-chart/root/donut-chart-root.js +13 -6
  80. package/dist/donut-chart/slice-label.d.ts +35 -0
  81. package/dist/donut-chart/slice-label.js +11 -0
  82. package/dist/drawer/root/drawer-root.d.ts +4 -2
  83. package/dist/drawer/root/drawer-root.js +15 -3
  84. package/dist/drilldown/item/drilldown-item.d.ts +21 -1
  85. package/dist/drilldown/item/drilldown-item.js +38 -4
  86. package/dist/drilldown/root/drilldown-root.js +3 -2
  87. package/dist/element-events.generated.js +5 -1
  88. package/dist/empty/root/empty-root.d.ts +46 -2
  89. package/dist/empty/root/empty-root.js +50 -5
  90. package/dist/file-input/root/file-input-root.d.ts +34 -6
  91. package/dist/file-input/root/file-input-root.js +55 -21
  92. package/dist/file-input/status.d.ts +24 -0
  93. package/dist/file-input/status.js +11 -0
  94. package/dist/filter-input/chip/filter-chip.d.ts +23 -0
  95. package/dist/filter-input/chip/filter-chip.js +10 -2
  96. package/dist/filter-input/root/filter-input-root.d.ts +8 -0
  97. package/dist/filter-input/root/filter-input-root.js +17 -27
  98. package/dist/format-date/fields.d.ts +20 -0
  99. package/dist/format-date/fields.js +14 -0
  100. package/dist/format-date/options.d.ts +5 -5
  101. package/dist/format-date/options.js +10 -39
  102. package/dist/format-date/root/format-date-root.d.ts +53 -4
  103. package/dist/format-date/root/format-date-root.js +38 -50
  104. package/dist/graph/root/graph-root.d.ts +23 -5
  105. package/dist/graph/root/graph-root.js +17 -20
  106. package/dist/heatmap/root/buckets.d.ts +21 -0
  107. package/dist/heatmap/root/buckets.js +34 -0
  108. package/dist/heatmap/root/heatmap-root.d.ts +76 -3
  109. package/dist/heatmap/root/heatmap-root.js +105 -20
  110. package/dist/icon/index.d.ts +1 -1
  111. package/dist/icon/index.js +1 -1
  112. package/dist/icon/registry.d.ts +26 -1
  113. package/dist/icon/registry.js +12 -1
  114. package/dist/icon/root/icon-root.d.ts +13 -0
  115. package/dist/icon/root/icon-root.js +23 -2
  116. package/dist/icon/root/index.d.ts +1 -1
  117. package/dist/icon/root/index.js +1 -1
  118. package/dist/image/root/image-root.d.ts +20 -0
  119. package/dist/image/root/image-root.js +6 -1
  120. package/dist/input/root/input-root.d.ts +23 -2
  121. package/dist/input/root/input-root.js +12 -8
  122. package/dist/kbd/root/kbd-root.d.ts +20 -3
  123. package/dist/kbd/root/kbd-root.js +23 -50
  124. package/dist/legend/hidden-series.d.ts +10 -2
  125. package/dist/legend/hidden-series.js +5 -2
  126. package/dist/legend/root/legend-root.d.ts +25 -7
  127. package/dist/legend/root/legend-root.js +25 -26
  128. package/dist/lightbox/root/lightbox-root.d.ts +50 -5
  129. package/dist/lightbox/root/lightbox-root.js +76 -8
  130. package/dist/lightbox/zoom.d.ts +2 -0
  131. package/dist/lightbox/zoom.js +5 -3
  132. package/dist/line-chart/root/line-chart-root.d.ts +16 -0
  133. package/dist/line-chart/root/line-chart-root.js +10 -2
  134. package/dist/list/root/list-root.d.ts +10 -2
  135. package/dist/list/root/list-root.js +31 -24
  136. package/dist/list/selection.d.ts +17 -0
  137. package/dist/list/selection.js +16 -0
  138. package/dist/listbox/root/listbox-root.d.ts +125 -26
  139. package/dist/listbox/root/listbox-root.js +156 -166
  140. package/dist/map/marker/map-marker.d.ts +2 -1
  141. package/dist/map/root/map-root.d.ts +40 -2
  142. package/dist/map/root/map-root.js +64 -23
  143. package/dist/megamenu/hand-over.d.ts +75 -0
  144. package/dist/megamenu/hand-over.js +67 -0
  145. package/dist/megamenu/root/megamenu-root.d.ts +38 -14
  146. package/dist/megamenu/root/megamenu-root.js +29 -50
  147. package/dist/menu/item/menu-item.js +4 -4
  148. package/dist/menu/root/menu-root.d.ts +5 -2
  149. package/dist/meter/root/meter-root.d.ts +42 -0
  150. package/dist/meter/root/meter-root.js +33 -7
  151. package/dist/navigation/root/navigation-root.js +5 -8
  152. package/dist/notifications/group/notification-group.d.ts +8 -1
  153. package/dist/notifications/group/notification-group.js +12 -6
  154. package/dist/notifications/notification/notification.d.ts +12 -1
  155. package/dist/notifications/notification/notification.js +3 -1
  156. package/dist/notifications/root/notifications-root.d.ts +48 -3
  157. package/dist/notifications/root/notifications-root.js +36 -6
  158. package/dist/number-input/grain.d.ts +28 -0
  159. package/dist/number-input/grain.js +14 -0
  160. package/dist/number-input/root/number-input-root.d.ts +17 -1
  161. package/dist/number-input/root/number-input-root.js +29 -18
  162. package/dist/object-inspector/root/object-inspector-root.d.ts +17 -6
  163. package/dist/object-inspector/root/object-inspector-root.js +31 -20
  164. package/dist/option/index.d.ts +1 -0
  165. package/dist/option/index.js +1 -0
  166. package/dist/option/separator/option-separator.d.ts +30 -0
  167. package/dist/option/separator/option-separator.js +21 -0
  168. package/dist/outline/root/outline-root.d.ts +12 -0
  169. package/dist/outline/root/outline-root.js +5 -19
  170. package/dist/pagination/size/pagination-size.d.ts +6 -0
  171. package/dist/pagination/size/pagination-size.js +5 -3
  172. package/dist/pin-input/code.d.ts +51 -1
  173. package/dist/pin-input/code.js +37 -0
  174. package/dist/pin-input/root/pin-input-root.d.ts +98 -121
  175. package/dist/pin-input/root/pin-input-root.js +151 -156
  176. package/dist/popover/hide-outside.js +2 -9
  177. package/dist/popover/root/popover-root.d.ts +7 -1
  178. package/dist/popover/root/popover-root.js +9 -1
  179. package/dist/progress/root/progress-root.d.ts +27 -0
  180. package/dist/progress/root/progress-root.js +25 -7
  181. package/dist/qr-code/export.d.ts +19 -0
  182. package/dist/qr-code/export.js +14 -0
  183. package/dist/qr-code/name.d.ts +11 -0
  184. package/dist/qr-code/name.js +7 -0
  185. package/dist/qr-code/root/qr-code-root.d.ts +31 -9
  186. package/dist/qr-code/root/qr-code-root.js +29 -17
  187. package/dist/radio/group/radio-group.d.ts +15 -0
  188. package/dist/radio/root/radio-root.js +2 -2
  189. package/dist/rating/root/rating-root.d.ts +22 -9
  190. package/dist/rating/root/rating-root.js +15 -39
  191. package/dist/scatter-chart/measures.d.ts +22 -0
  192. package/dist/scatter-chart/measures.js +11 -0
  193. package/dist/scatter-chart/root/scatter-chart-root.d.ts +26 -0
  194. package/dist/scatter-chart/root/scatter-chart-root.js +21 -7
  195. package/dist/scroll-area/scrollbar.d.ts +0 -8
  196. package/dist/scroll-area/scrollbar.js +1 -1
  197. package/dist/select/align.d.ts +47 -0
  198. package/dist/select/align.js +7 -0
  199. package/dist/select/root/select-root.d.ts +115 -11
  200. package/dist/select/root/select-root.js +104 -20
  201. package/dist/slider/root/slider-root.d.ts +18 -1
  202. package/dist/slider/root/slider-root.js +22 -0
  203. package/dist/sparkline/readings.d.ts +30 -12
  204. package/dist/sparkline/readings.js +32 -15
  205. package/dist/sparkline/root/sparkline-root.d.ts +46 -3
  206. package/dist/sparkline/root/sparkline-root.js +60 -21
  207. package/dist/speed-dial/group/speed-dial-group.d.ts +48 -0
  208. package/dist/speed-dial/group/speed-dial-group.js +43 -0
  209. package/dist/speed-dial/index.d.ts +1 -0
  210. package/dist/speed-dial/index.js +1 -0
  211. package/dist/speed-dial/item/speed-dial-item.d.ts +27 -2
  212. package/dist/speed-dial/item/speed-dial-item.js +43 -5
  213. package/dist/speed-dial/long-press.d.ts +50 -0
  214. package/dist/speed-dial/long-press.js +48 -0
  215. package/dist/speed-dial/root/speed-dial-root.d.ts +86 -1
  216. package/dist/speed-dial/root/speed-dial-root.js +123 -6
  217. package/dist/splitter/root/splitter-root.d.ts +9 -2
  218. package/dist/splitter/root/splitter-root.js +18 -3
  219. package/dist/steps/root/steps-root.d.ts +8 -1
  220. package/dist/steps/root/steps-root.js +6 -1
  221. package/dist/steps/step/step.d.ts +1 -0
  222. package/dist/steps/step/step.js +1 -1
  223. package/dist/table/cell/table-cell.d.ts +8 -1
  224. package/dist/table/cell/table-cell.js +6 -2
  225. package/dist/table/column/table-column.d.ts +6 -0
  226. package/dist/table/column/table-column.js +5 -1
  227. package/dist/table/grid-controller.d.ts +117 -0
  228. package/dist/table/grid-controller.js +293 -0
  229. package/dist/table/root/table-root.d.ts +47 -3
  230. package/dist/table/root/table-root.js +93 -29
  231. package/dist/table/row/table-row.d.ts +36 -0
  232. package/dist/table/row/table-row.js +52 -2
  233. package/dist/tabs/root/tabs-root.d.ts +5 -3
  234. package/dist/tag/group/tag-group.d.ts +16 -4
  235. package/dist/tag/group/tag-group.js +23 -20
  236. package/dist/textarea/root/textarea-root.d.ts +14 -2
  237. package/dist/textarea/root/textarea-root.js +6 -7
  238. package/dist/time-input/root/time-input-root.d.ts +5 -1
  239. package/dist/time-input/root/time-input-root.js +10 -7
  240. package/dist/time-picker/root/time-picker-root.d.ts +12 -14
  241. package/dist/time-picker/root/time-picker-root.js +18 -23
  242. package/dist/toast/item/toast-item.d.ts +9 -6
  243. package/dist/toast/item/toast-item.js +1 -1
  244. package/dist/toast/root/toast-root.d.ts +40 -4
  245. package/dist/toast/root/toast-root.js +68 -16
  246. package/dist/toast/words.d.ts +12 -0
  247. package/dist/toast/words.js +25 -0
  248. package/dist/toggle/group/toggle-group.d.ts +29 -5
  249. package/dist/toggle/group/toggle-group.js +26 -43
  250. package/dist/toggle/root/toggle-root.js +2 -4
  251. package/dist/toolbar/root/toolbar-root.d.ts +52 -5
  252. package/dist/toolbar/root/toolbar-root.js +88 -13
  253. package/dist/tooltip/root/tooltip-root.d.ts +7 -1
  254. package/dist/tooltip/root/tooltip-root.js +10 -2
  255. package/dist/tour/root/tour-root.d.ts +15 -0
  256. package/dist/tour/root/tour-root.js +20 -1
  257. package/dist/tour/stop/tour-stop.d.ts +3 -0
  258. package/dist/tour/stop/tour-stop.js +3 -3
  259. package/dist/tree/root/tree-root.js +2 -2
  260. package/dist/trend/figure.d.ts +16 -0
  261. package/dist/trend/figure.js +8 -0
  262. package/dist/trend/root/trend-root.d.ts +41 -2
  263. package/dist/trend/root/trend-root.js +29 -3
  264. package/dist/video/root/extra-controls.d.ts +12 -0
  265. package/dist/video/root/extra-controls.js +6 -2
  266. package/dist/video/root/video-root.d.ts +16 -1
  267. package/dist/video/root/video-root.js +15 -1
  268. package/dist/video-playlist/root/video-playlist-root.d.ts +11 -1
  269. package/dist/video-playlist/root/video-playlist-root.js +3 -0
  270. package/dist/virtual-list/fill.d.ts +11 -0
  271. package/dist/virtual-list/fill.js +9 -0
  272. package/dist/virtual-list/keys.d.ts +16 -7
  273. package/dist/virtual-list/keys.js +17 -6
  274. package/dist/virtual-list/plan.d.ts +17 -1
  275. package/dist/virtual-list/plan.js +13 -2
  276. package/dist/virtual-list/root/virtual-list-root.d.ts +25 -3
  277. package/dist/virtual-list/root/virtual-list-root.js +53 -41
  278. package/lint.json +1 -1
  279. package/package.json +5 -5
  280. package/types/jsx.d.ts +4934 -954
  281. package/types/svelte.d.ts +2 -0
  282. package/types/vue.d.ts +946 -253
  283. package/dist/color-picker/swatches.d.ts +0 -12
  284. package/dist/color-picker/swatches.js +0 -26
  285. package/dist/rating/steps.d.ts +0 -7
  286. package/dist/rating/steps.js +0 -9
  287. package/dist/tooltip/focus-target.d.ts +0 -6
  288. package/dist/tooltip/focus-target.js +0 -9
@@ -13,20 +13,22 @@ declare const HelixHeadlessAccordionItem_base: (new (...args: any[]) => import("
13
13
  * accordion's, then 3.
14
14
  *
15
15
  * Content stays mounted when the item is closed, so it can animate and its text
16
- * is present in server-rendered HTML. Closed content has both `hidden` and
17
- * `inert`. `hidden` collapses it when no stylesheet is loaded. `inert` keeps it
18
- * out of the tab order and the accessibility tree after the styled tier's
19
- * `display` overrides `hidden`.
16
+ * is present in server-rendered HTML.
17
+ *
18
+ * The browser's find in page searches a closed section, and a match opens it,
19
+ * with `helix-before-open` first, as React Aria's disclosure does. Closed
20
+ * content is `hidden="until-found"`, which hides it with no stylesheet loaded
21
+ * and keeps it out of the tab order and the accessibility tree. A section
22
+ * that closes keeps its content drawn until the content part's animations and
23
+ * transitions end, so a sheet that animates the section closed shows the
24
+ * content shrinking rather than an empty box. Set `hidden-until-found="false"`
25
+ * and a closed section is `hidden` and `inert` instead, and find in page skips
26
+ * it.
20
27
  *
21
28
  * While it is open, the content part carries the content's height as
22
29
  * `--accordion-content-height`, as Radix's accordion does, for a stylesheet
23
30
  * that animates the section open with keyframes of its own.
24
31
  *
25
- * Set `hidden-until-found` and the browser's find in page searches a closed
26
- * section too: a match opens it, with `helix-before-open` first, as React
27
- * Aria's disclosure does. The content is then `hidden="until-found"` while
28
- * closed, and not `inert`, since an inert region is never searched.
29
- *
30
32
  * @since 0.1.0
31
33
  * @status stable
32
34
  * @aliases Collapsible, Expander, Disclosure
@@ -97,12 +99,11 @@ export declare class HelixHeadlessAccordionItem extends HelixHeadlessAccordionIt
97
99
  * Whether find in page searches the section while it is closed, and opens it
98
100
  * on a match.
99
101
  *
100
- * Off by default. A closed section is then `hidden="until-found"`, which
101
- * hides through `content-visibility`, so a stylesheet that animates the
102
- * section closed shows an empty box for the length of that animation. The
103
- * accordion's own `hidden-until-found` turns it on for every section.
102
+ * Unset takes the accordion's `hidden-until-found`, which is on. Write
103
+ * `hidden-until-found="false"` to keep find in page out of this section: a
104
+ * closed section is then `hidden` and `inert`.
104
105
  */
105
- hiddenUntilFound: boolean;
106
+ hiddenUntilFound?: boolean;
106
107
  /**
107
108
  * A group name. Opening an item closes the other items with the same name,
108
109
  * as `<details name>` does.
@@ -126,11 +127,32 @@ export declare class HelixHeadlessAccordionItem extends HelixHeadlessAccordionIt
126
127
  name?: string;
127
128
  /** Whether find in page searches this section while it is closed. */
128
129
  private get findable();
130
+ /**
131
+ * Whether the section has closed and its content is still drawn, until the
132
+ * content part's animations end.
133
+ *
134
+ * `hidden="until-found"` hides through `content-visibility`, which an
135
+ * author's `display` does not override, so writing it the moment the section
136
+ * closes empties the box a sheet is still shrinking. `inert` holds the
137
+ * content meanwhile.
138
+ */
139
+ private closing;
140
+ protected willUpdate(changed: PropertyValues): void;
141
+ /**
142
+ * Hides the content of a section that closed, once whatever animates the
143
+ * content part has finished. Nothing running, as under reduced motion or
144
+ * with no stylesheet, hides it at once. `getAnimations` brings the styles up
145
+ * to date first, so a transition the close starts is among them.
146
+ */
147
+ private finishClosing;
129
148
  /**
130
149
  * Opens the section find in page has matched in, before the match is shown.
131
150
  *
132
- * The browser removes `hidden` itself. A refusal puts it back, so the trigger
133
- * and the region still agree.
151
+ * A refusal puts `hidden` back, so the trigger and the region still agree.
152
+ * The browser removes the attribute after this event's listeners have
153
+ * returned, and after the microtasks they queued, so writing it here or in a
154
+ * microtask is undone at once. A mutation observer hears the removal itself
155
+ * and runs before the next paint or key press.
134
156
  */
135
157
  private readonly handleBeforeMatch;
136
158
  /** Whether the item was open at the last update, and `undefined` before one. */
@@ -204,13 +226,13 @@ export declare class HelixHeadlessAccordionItem extends HelixHeadlessAccordionIt
204
226
  * part outranks it and the transition runs exactly as before. Measured on
205
227
  * both tiers.
206
228
  *
207
- * **`hidden="until-found"` only where it was asked for.** It hides through
229
+ * **`hidden="until-found"` unless it is turned off.** It hides through
208
230
  * `content-visibility` rather than `display`, which an author `display` does
209
- * not override, so a section a sheet animates closed shows an empty box while
210
- * it shrinks. `beforematch` sets `open`, so find in page never reveals text
211
- * under a trigger that still reports collapsed.
231
+ * not override, so it is written only once the section's closing motion has
232
+ * ended (`closing`). `beforematch` sets `open`, so find in page never reveals
233
+ * text under a trigger that still reports collapsed.
212
234
  *
213
- * `inert` stays, except under `until-found`. `hidden` answers the reader who
235
+ * `inert` only where `until-found` is not. `hidden` answers the reader who
214
236
  * can see and `inert` answers the one tabbing through, and wherever a sheet
215
237
  * overrides `display`, `inert` is the only one of the two still in force.
216
238
  * `content-visibility: hidden` keeps skipped content out of the tab order and
@@ -4,10 +4,10 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
4
4
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
5
  return c > 3 && r && Object.defineProperty(target, key, r), r;
6
6
  };
7
- import { closestInstance, customElement, HelixElement, headingLevel, MixinControllerOpen, } from '@fusion.dev/helix-core';
7
+ import { animationsFinished, closestInstance, customElement, HelixElement, headingLevel, MixinControllerOpen, onUnlessFalse, } from '@fusion.dev/helix-core';
8
8
  import { caretDown } from '@fusion.dev/helix-icons';
9
9
  import { html, nothing } from 'lit';
10
- import { property } from 'lit/decorators.js';
10
+ import { property, state } from 'lit/decorators.js';
11
11
  import { unsafeSVG } from 'lit/directives/unsafe-svg.js';
12
12
  import { HelixHeadlessAccordion } from '../root/accordion-root.js';
13
13
  const CONTENT_ID = 'content';
@@ -17,14 +17,20 @@ let HelixHeadlessAccordionItem = class HelixHeadlessAccordionItem extends MixinC
17
17
  super(...arguments);
18
18
  this.disabled = false;
19
19
  this.groupHeadingLevel = undefined;
20
- this.groupHiddenUntilFound = false;
21
- this.hiddenUntilFound = false;
20
+ this.groupHiddenUntilFound = true;
21
+ this.closing = false;
22
22
  this.handleBeforeMatch = (event) => {
23
23
  if (this.open || this.requestOpen(true)) {
24
24
  return;
25
25
  }
26
- ;
27
- event.currentTarget.setAttribute('hidden', 'until-found');
26
+ const content = event.currentTarget;
27
+ const observer = new MutationObserver(() => {
28
+ observer.disconnect();
29
+ if (!this.open && !this.closing && !content.hasAttribute('hidden')) {
30
+ content.setAttribute('hidden', 'until-found');
31
+ }
32
+ });
33
+ observer.observe(content, { attributeFilter: ['hidden'] });
28
34
  };
29
35
  this.wasOpen = undefined;
30
36
  this.handleToggle = () => {
@@ -63,7 +69,20 @@ let HelixHeadlessAccordionItem = class HelixHeadlessAccordionItem extends MixinC
63
69
  >`;
64
70
  }
65
71
  get findable() {
66
- return this.hiddenUntilFound || this.groupHiddenUntilFound;
72
+ return this.hiddenUntilFound ?? this.groupHiddenUntilFound;
73
+ }
74
+ willUpdate(changed) {
75
+ super.willUpdate(changed);
76
+ if (changed.has('open')) {
77
+ this.closing = !this.open && changed.get('open') === true && this.findable;
78
+ }
79
+ }
80
+ finishClosing() {
81
+ void animationsFinished(this.partNamed('content')).then(() => {
82
+ if (!this.open) {
83
+ this.closing = false;
84
+ }
85
+ });
67
86
  }
68
87
  get accordion() {
69
88
  return closestInstance(this, HelixHeadlessAccordion);
@@ -96,6 +115,9 @@ let HelixHeadlessAccordionItem = class HelixHeadlessAccordionItem extends MixinC
96
115
  if (this.wasOpen === false && this.open) {
97
116
  this.closePeers();
98
117
  }
118
+ if (changed.has('closing') && this.closing) {
119
+ this.finishClosing();
120
+ }
99
121
  this.wasOpen = this.open;
100
122
  this.measure();
101
123
  }
@@ -104,7 +126,8 @@ let HelixHeadlessAccordionItem = class HelixHeadlessAccordionItem extends MixinC
104
126
  }
105
127
  render() {
106
128
  const open = this.open;
107
- const landmark = open || !this.findable;
129
+ const shown = open || this.closing;
130
+ const landmark = shown || !this.findable;
108
131
  const level = headingLevel(this.headingLevel ?? this.groupHeadingLevel);
109
132
  return html `
110
133
  <div part="container">
@@ -127,8 +150,8 @@ let HelixHeadlessAccordionItem = class HelixHeadlessAccordionItem extends MixinC
127
150
  id=${CONTENT_ID}
128
151
  aria-labelledby=${landmark ? TRIGGER_ID : nothing}
129
152
  part="content"
130
- hidden=${open ? nothing : this.findable ? 'until-found' : ''}
131
- ?inert=${!open && !this.findable}
153
+ hidden=${shown ? nothing : this.findable ? 'until-found' : ''}
154
+ ?inert=${!open && (this.closing || !this.findable)}
132
155
  role=${landmark ? 'region' : nothing}
133
156
  @beforematch=${this.handleBeforeMatch}
134
157
  >
@@ -156,11 +179,14 @@ __decorate([
156
179
  property({ attribute: 'heading-level', type: Number })
157
180
  ], HelixHeadlessAccordionItem.prototype, "headingLevel", void 0);
158
181
  __decorate([
159
- property({ attribute: 'hidden-until-found', type: Boolean })
182
+ property({ attribute: 'hidden-until-found', converter: onUnlessFalse })
160
183
  ], HelixHeadlessAccordionItem.prototype, "hiddenUntilFound", void 0);
161
184
  __decorate([
162
185
  property({ reflect: true })
163
186
  ], HelixHeadlessAccordionItem.prototype, "name", void 0);
187
+ __decorate([
188
+ state()
189
+ ], HelixHeadlessAccordionItem.prototype, "closing", void 0);
164
190
  HelixHeadlessAccordionItem = __decorate([
165
191
  customElement('helix-headless-accordion-item')
166
192
  ], HelixHeadlessAccordionItem);
@@ -27,6 +27,9 @@ import { HelixHeadlessAccordionItem } from '../item/accordion-item.js';
27
27
  * in a screen reader's list of headings. An open section is a region named by
28
28
  * its trigger. Set the level that fits the page's outline.
29
29
  *
30
+ * Find in page searches the closed sections too, and opens the one it matches
31
+ * in. `hidden-until-found="false"` turns that off.
32
+ *
30
33
  * @since 0.1.0
31
34
  * @status stable
32
35
  * @category layout
@@ -44,8 +47,11 @@ export declare class HelixHeadlessAccordion extends HelixElement {
44
47
  headingLevel?: number;
45
48
  /**
46
49
  * Whether find in page searches every closed section, and opens the one it
47
- * matches in. Each item's own `hidden-until-found` turns it on for that item
48
- * alone.
50
+ * matches in.
51
+ *
52
+ * On by default, as in React Aria's disclosure. Write
53
+ * `hidden-until-found="false"` to turn it off for every section; an item's
54
+ * own `hidden-until-found` wins for that item.
49
55
  */
50
56
  hiddenUntilFound: boolean;
51
57
  /**
@@ -4,21 +4,19 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
4
4
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
5
  return c > 3 && r && Object.defineProperty(target, key, r), r;
6
6
  };
7
- import { customElement, HelixElement, KeyboardNavigationController, whenHydrated, } from '@fusion.dev/helix-core';
7
+ import { customElement, focusItemOf, HelixElement, KeyboardNavigationController, onUnlessFalse, whenHydrated, } from '@fusion.dev/helix-core';
8
8
  import { html } from 'lit';
9
9
  import { property } from 'lit/decorators.js';
10
10
  import { HelixHeadlessAccordionItem } from '../item/accordion-item.js';
11
- const navigable = (item) => ({
12
- contains: (node) => node === item,
11
+ const navigable = (item) => focusItemOf(item, {
13
12
  disabled: item.disabled,
14
- focusItem: () => item.focusTrigger(),
15
- select: () => { },
16
- selected: false,
13
+ focus: () => item.focusTrigger(),
14
+ owns: (node) => node === item,
17
15
  });
18
16
  let HelixHeadlessAccordion = class HelixHeadlessAccordion extends HelixElement {
19
17
  constructor() {
20
18
  super(...arguments);
21
- this.hiddenUntilFound = false;
19
+ this.hiddenUntilFound = true;
22
20
  this.keys = new KeyboardNavigationController(this, {
23
21
  items: () => this.items.map(navigable),
24
22
  origin: 'focus',
@@ -71,7 +69,7 @@ __decorate([
71
69
  property({ attribute: 'heading-level', type: Number })
72
70
  ], HelixHeadlessAccordion.prototype, "headingLevel", void 0);
73
71
  __decorate([
74
- property({ attribute: 'hidden-until-found', type: Boolean })
72
+ property({ attribute: 'hidden-until-found', converter: onUnlessFalse })
75
73
  ], HelixHeadlessAccordion.prototype, "hiddenUntilFound", void 0);
76
74
  __decorate([
77
75
  property({ reflect: true })
@@ -1,5 +1,5 @@
1
1
  import { ArrivalController, HelixElement } from '@fusion.dev/helix-core';
2
- import { type PropertyValues, type TemplateResult } from 'lit';
2
+ import { nothing, type PropertyValues, type TemplateResult } from 'lit';
3
3
  declare const HelixHeadlessAnnouncement_base: (new (...args: any[]) => import("@fusion.dev/helix-core").DismissibleElement) & typeof HelixElement;
4
4
  /**
5
5
  * @summary A message for the whole page, shown above its header, that can be dismissed.
@@ -29,10 +29,30 @@ declare const HelixHeadlessAnnouncement_base: (new (...args: any[]) => import("@
29
29
  * announcement beside it, move focus yourself, for example to the page's main
30
30
  * heading.
31
31
  *
32
+ * **The announcement is a landmark region**, named by `label`, "Announcement"
33
+ * unless you set it, so a screen reader lists it among the page's regions.
34
+ * `hotkey`, F6 unless you set it, moves focus to the announcement's first
35
+ * control, an action or the dismiss button, and pressed there moves focus
36
+ * back to where it was, as React Aria's toast region does. An announcement
37
+ * with no control leaves the key to the browser. When an announcement that
38
+ * the key moved focus into is removed with focus still inside, focus goes
39
+ * back to where it was before the key.
40
+ *
41
+ * **Set `queued` to show several announcements one at a time.** A queued
42
+ * announcement waits while a queued announcement before it in the same parent
43
+ * is still there, and shows when that one is removed: its message is then
44
+ * read out, and its `duration` starts. While it waits it renders nothing,
45
+ * is no region, and carries `:state(waiting)`. A server cannot see the
46
+ * announcements beside it, so a served page shows every one until the script
47
+ * runs.
48
+ *
32
49
  * Set `duration` to dismiss it after a time. The clock stops while the pointer
33
50
  * or focus is on the announcement, and continues from what was left, so a
34
- * reader partway through is not cut off. When the time runs out it sends
35
- * `helix-dismiss`, as the button does.
51
+ * reader partway through is not cut off. It stops while the page is hidden too,
52
+ * in another tab or a minimized window, so the message is not spent where
53
+ * nobody can see it. While the clock is stopped the announcement carries
54
+ * `:state(paused)`. When the time runs out it sends `helix-dismiss`, as the
55
+ * button does.
36
56
  *
37
57
  * @since 0.1.0
38
58
  * @status stable
@@ -42,15 +62,19 @@ declare const HelixHeadlessAnnouncement_base: (new (...args: any[]) => import("@
42
62
  *
43
63
  * @slot - The message.
44
64
  * @slot actions - Actions for the message, usually a link or a button.
45
- * @slot icon - Replaces the icon inside the dismiss button.
65
+ * @slot dismiss-icon - Replaces the cross inside the dismiss button, as `Callout`'s slot of the same name does.
66
+ * @slot icon - Replaces the cross inside the dismiss button. Deprecated: use `dismiss-icon`, which is read first.
46
67
  *
47
68
  * @event {HelixDismissEvent} helix-dismiss - The dismiss button was pressed, or `duration` ran out. The announcement does not remove itself, so remove it in response. Cancelable.
48
69
  *
49
70
  * @csspart actions - The region after the message that holds the actions.
50
71
  * @csspart content - The region that holds the message.
51
72
  * @csspart dismiss - The button that dismisses the announcement.
52
- * @csspart dismiss-mark - The icon on the dismiss button, shown when the `icon` slot is empty.
73
+ * @csspart dismiss-mark - The cross on the dismiss button, shown when the `dismiss-icon` and `icon` slots are empty.
53
74
  * @csspart live - A copy of the message in a live region, read by screen readers when the announcement appears after the page has loaded, and emptied seven seconds later. Visually hidden in the styled tier.
75
+ *
76
+ * @cssstate paused - The clock `duration` started is stopped, while the pointer or focus is on the announcement or the page is hidden.
77
+ * @cssstate waiting - The announcement is `queued` behind another, and renders nothing until that one is removed.
54
78
  */
55
79
  export declare class HelixHeadlessAnnouncement extends HelixHeadlessAnnouncement_base {
56
80
  /**
@@ -61,6 +85,28 @@ export declare class HelixHeadlessAnnouncement extends HelixHeadlessAnnouncement
61
85
  * own. The clock stops while the pointer or focus is on the announcement.
62
86
  */
63
87
  duration?: number;
88
+ /**
89
+ * The key that moves focus to the announcement's first control, and back
90
+ * to where it was, written as keys joined by `+`, such as `F6` or `Alt+A`.
91
+ *
92
+ * F6 by default, the key React Aria's regions answer to. Empty turns it
93
+ * off. With several announcements, the first one in the page takes focus.
94
+ */
95
+ hotkey: string;
96
+ /**
97
+ * The name of the announcement's region, which screen readers list among
98
+ * the page's landmarks. Translate it with the rest of your interface.
99
+ *
100
+ * Empty leaves the announcement no region.
101
+ */
102
+ label: string;
103
+ /**
104
+ * Whether the announcement waits its turn behind the queued announcements
105
+ * before it in the same parent, showing when the last of them is removed.
106
+ *
107
+ * Off by default, so every announcement on a page shows at once.
108
+ */
109
+ queued: boolean;
64
110
  /**
65
111
  * The band's color.
66
112
  *
@@ -84,15 +130,29 @@ export declare class HelixHeadlessAnnouncement extends HelixHeadlessAnnouncement
84
130
  * axes, which is the test the registry answers to.
85
131
  */
86
132
  tone?: 'accent' | 'danger' | 'info' | 'neutral' | 'primary' | 'success' | 'warning';
133
+ /** Whether a queued announcement before this one is still there. */
134
+ private waiting;
135
+ /** Watches the parent for the announcements before this one leaving. */
136
+ private queue;
137
+ /** Whether a queued announcement comes before this one in its parent. */
138
+ private behind;
87
139
  protected readonly arrival: ArrivalController;
88
140
  /** The time `duration` gives it, held while a reader is on it. */
89
141
  private readonly countdown;
142
+ private readonly scope;
143
+ /** Where focus was when `hotkey` moved it in. */
144
+ private origin;
145
+ /** Whether focus is inside the announcement, kept as it moves. */
146
+ private focused;
147
+ private readonly handleHotkey;
148
+ protected willUpdate(changed: PropertyValues): void;
90
149
  private readonly handleHold;
91
150
  private readonly handleRelease;
92
151
  connectedCallback(): void;
93
152
  disconnectedCallback(): void;
94
153
  protected firstUpdated(changed: PropertyValues): void;
95
154
  protected updated(changed: PropertyValues): void;
155
+ private watchQueue;
96
156
  /**
97
157
  * Says on the `actions` region whether anything is in it.
98
158
  *
@@ -117,7 +177,7 @@ export declare class HelixHeadlessAnnouncement extends HelixHeadlessAnnouncement
117
177
  * draws a tone mark. An announcement has no tone mark at all.
118
178
  */
119
179
  protected renderDismissIcon(): TemplateResult;
120
- protected render(): TemplateResult;
180
+ protected render(): TemplateResult | typeof nothing;
121
181
  }
122
182
  declare global {
123
183
  interface HTMLElementTagNameMap {
@@ -4,36 +4,107 @@ var __decorate = (this && this.__decorate) || function (decorators, target, key,
4
4
  else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
5
  return c > 3 && r && Object.defineProperty(target, key, r), r;
6
6
  };
7
- import { ArrivalController, CountdownController, customElement, HelixElement, MixinDismissible, markRegion, slottedWords, } from '@fusion.dev/helix-core';
7
+ var HelixHeadlessAnnouncement_1;
8
+ import { ArrivalController, ariaChord, CountdownController, customElement, deepActiveElement, FocusScopeController, HelixElement, hostAria, MixinDismissible, markRegion, matchesChord, onApple, reportRuntime, slottedWords, } from '@fusion.dev/helix-core';
8
9
  import { x } from '@fusion.dev/helix-icons';
9
10
  import { html, nothing } from 'lit';
10
- import { property } from 'lit/decorators.js';
11
+ import { property, state } from 'lit/decorators.js';
11
12
  import { unsafeSVG } from 'lit/directives/unsafe-svg.js';
12
- let HelixHeadlessAnnouncement = class HelixHeadlessAnnouncement extends MixinDismissible(HelixElement) {
13
+ let HelixHeadlessAnnouncement = HelixHeadlessAnnouncement_1 = class HelixHeadlessAnnouncement extends MixinDismissible(HelixElement) {
13
14
  constructor() {
14
15
  super(...arguments);
16
+ this.hotkey = 'F6';
17
+ this.label = 'Announcement';
18
+ this.queued = false;
19
+ this.waiting = false;
15
20
  this.arrival = new ArrivalController(this, {
16
21
  arriving: () => !this.serverRendered && document.readyState === 'complete',
17
- text: () => slottedWords(this, ['']),
22
+ text: () => (this.waiting ? '' : slottedWords(this, [''])),
18
23
  });
19
24
  this.countdown = new CountdownController(this, {
20
25
  done: () => {
21
26
  this.dismiss();
22
27
  },
28
+ holdWhileHidden: true,
29
+ paused: (paused) => {
30
+ this.toggleState('paused', paused);
31
+ },
32
+ });
33
+ this.scope = new FocusScopeController(this, {
34
+ contents: () => [
35
+ ...(this.renderRoot
36
+ ?.querySelector('slot[name="actions"]')
37
+ ?.assignedElements({ flatten: true }) ?? []),
38
+ ...[...(this.renderRoot?.querySelectorAll('[part="dismiss"]') ?? [])],
39
+ ],
40
+ surface: () => null,
23
41
  });
24
- this.handleHold = () => {
42
+ this.focused = false;
43
+ this.handleHotkey = (event) => {
44
+ if (event.defaultPrevented || !matchesChord(event, this.hotkey, onApple())) {
45
+ return;
46
+ }
47
+ if (this.scope.holdsFocus) {
48
+ if (this.scope.leave()) {
49
+ event.preventDefault();
50
+ }
51
+ this.origin = undefined;
52
+ return;
53
+ }
54
+ const other = event
55
+ .composedPath()
56
+ .some((node) => node !== this && node instanceof HelixHeadlessAnnouncement_1);
57
+ if (other || this.scope.controls.length === 0) {
58
+ return;
59
+ }
60
+ event.preventDefault();
61
+ const active = deepActiveElement();
62
+ this.origin = active instanceof HTMLElement ? active : undefined;
63
+ this.scope.enter();
64
+ };
65
+ this.handleHold = (event) => {
66
+ this.focused ||= event.type === 'focusin';
25
67
  this.countdown.hold();
26
68
  };
27
- this.handleRelease = () => {
69
+ this.handleRelease = (event) => {
70
+ if (event.type === 'focusout') {
71
+ queueMicrotask(() => {
72
+ this.focused = this.matches(':focus-within');
73
+ });
74
+ }
28
75
  this.countdown.release();
29
76
  };
30
77
  }
78
+ behind() {
79
+ if (!this.queued || (this.shadowRoot !== null && !this.hasUpdated)) {
80
+ return false;
81
+ }
82
+ for (let at = this.previousElementSibling; at; at = at.previousElementSibling) {
83
+ if (at instanceof HelixHeadlessAnnouncement_1 && at.queued) {
84
+ return true;
85
+ }
86
+ }
87
+ return false;
88
+ }
89
+ willUpdate(changed) {
90
+ super.willUpdate(changed);
91
+ hostAria(this.internals, {
92
+ label: this.label,
93
+ role: this.label.trim() && !this.waiting ? 'region' : '',
94
+ });
95
+ if ('ariaKeyShortcuts' in this.internals) {
96
+ this.internals.ariaKeyShortcuts = ariaChord(this.hotkey, onApple()) || null;
97
+ }
98
+ }
31
99
  connectedCallback() {
100
+ this.waiting = this.behind();
32
101
  super.connectedCallback();
102
+ this.watchQueue();
33
103
  this.addEventListener('mouseenter', this.handleHold);
34
104
  this.addEventListener('mouseleave', this.handleRelease);
35
105
  this.addEventListener('focusin', this.handleHold);
36
106
  this.addEventListener('focusout', this.handleRelease);
107
+ document.addEventListener('keydown', this.handleHotkey);
37
108
  if (this.hasUpdated) {
38
109
  this.countdown.resume();
39
110
  }
@@ -44,26 +115,74 @@ let HelixHeadlessAnnouncement = class HelixHeadlessAnnouncement extends MixinDis
44
115
  this.removeEventListener('mouseleave', this.handleRelease);
45
116
  this.removeEventListener('focusin', this.handleHold);
46
117
  this.removeEventListener('focusout', this.handleRelease);
118
+ document.removeEventListener('keydown', this.handleHotkey);
119
+ this.queue?.disconnect();
120
+ const origin = this.focused ? this.origin : undefined;
121
+ this.focused = false;
122
+ this.origin = undefined;
123
+ if (origin) {
124
+ requestAnimationFrame(() => {
125
+ const active = deepActiveElement();
126
+ if (origin.isConnected && (active === null || active === document.body)) {
127
+ origin.focus({ preventScroll: true });
128
+ }
129
+ });
130
+ }
47
131
  }
48
132
  firstUpdated(changed) {
49
133
  super.firstUpdated(changed);
50
- this.countdown.start(this.duration);
134
+ this.watchQueue();
135
+ if (!this.waiting) {
136
+ this.countdown.start(this.duration);
137
+ }
138
+ if (this.querySelector(':scope > [slot="icon"]')) {
139
+ reportRuntime({
140
+ kind: 'deprecated',
141
+ message: `<${this.localName}>'s \`icon\` slot is deprecated: slot the glyph as \`dismiss-icon\`, the name Callout uses.`,
142
+ tag: this.localName,
143
+ });
144
+ }
51
145
  }
52
146
  updated(changed) {
53
147
  super.updated(changed);
54
148
  this.markEmpty();
149
+ if (changed.has('queued')) {
150
+ this.watchQueue();
151
+ }
152
+ this.toggleState('waiting', this.waiting);
153
+ if (changed.has('waiting') && this.waiting) {
154
+ this.arrival.say();
155
+ }
156
+ else if (changed.get('waiting') === true) {
157
+ this.countdown.start(this.duration);
158
+ }
159
+ }
160
+ watchQueue() {
161
+ this.queue?.disconnect();
162
+ this.waiting = this.behind();
163
+ if (this.queued && this.parentElement && typeof MutationObserver !== 'undefined') {
164
+ this.queue ??= new MutationObserver(() => {
165
+ this.waiting = this.behind();
166
+ });
167
+ this.queue.observe(this.parentElement, { childList: true });
168
+ }
55
169
  }
56
170
  markEmpty() {
57
171
  markRegion(this.renderRoot, 'actions', ['actions']);
58
172
  }
59
173
  renderDismissIcon() {
60
- return html `<slot name="icon">
61
- <svg part="dismiss-mark" viewBox=${x.viewBox} fill="currentColor" aria-hidden="true">
62
- ${unsafeSVG(x.content)}
63
- </svg>
64
- </slot>`;
174
+ return html `<slot name="dismiss-icon"
175
+ ><slot name="icon">
176
+ <svg part="dismiss-mark" viewBox=${x.viewBox} fill="currentColor" aria-hidden="true">
177
+ ${unsafeSVG(x.content)}
178
+ </svg>
179
+ </slot></slot
180
+ >`;
65
181
  }
66
182
  render() {
183
+ if (this.waiting) {
184
+ return nothing;
185
+ }
67
186
  return html `<div aria-hidden=${this.arrival.said === '' ? nothing : 'true'} part="content"
68
187
  ><slot @slotchange=${() => this.arrival.say()}></slot
69
188
  ></div>
@@ -84,10 +203,22 @@ let HelixHeadlessAnnouncement = class HelixHeadlessAnnouncement extends MixinDis
84
203
  __decorate([
85
204
  property({ type: Number })
86
205
  ], HelixHeadlessAnnouncement.prototype, "duration", void 0);
206
+ __decorate([
207
+ property()
208
+ ], HelixHeadlessAnnouncement.prototype, "hotkey", void 0);
209
+ __decorate([
210
+ property()
211
+ ], HelixHeadlessAnnouncement.prototype, "label", void 0);
212
+ __decorate([
213
+ property({ reflect: true, type: Boolean })
214
+ ], HelixHeadlessAnnouncement.prototype, "queued", void 0);
87
215
  __decorate([
88
216
  property({ reflect: true })
89
217
  ], HelixHeadlessAnnouncement.prototype, "tone", void 0);
90
- HelixHeadlessAnnouncement = __decorate([
218
+ __decorate([
219
+ state()
220
+ ], HelixHeadlessAnnouncement.prototype, "waiting", void 0);
221
+ HelixHeadlessAnnouncement = HelixHeadlessAnnouncement_1 = __decorate([
91
222
  customElement('helix-headless-announcement')
92
223
  ], HelixHeadlessAnnouncement);
93
224
  export { HelixHeadlessAnnouncement };
@@ -5,7 +5,10 @@ import '../../tooltip/index.js';
5
5
  export interface AreaStack {
6
6
  /** The table's columns that hold numbers, by their place among its cells. */
7
7
  columns: number[];
8
- /** Each column's running sum at each reading, the top edge of its band. */
8
+ /**
9
+ * Each column's top edge at each reading: its running sum, or its own
10
+ * reading under `overlap`.
11
+ */
9
12
  layers: number[][];
10
13
  /** Each column's heading. */
11
14
  names: string[];
@@ -44,6 +47,11 @@ declare const HelixHeadlessAreaChart_base: typeof HelixElement & (new (...args:
44
47
  * bands show each part's share. Use it to see which part grew. The default
45
48
  * shows whether the total grew.
46
49
  *
50
+ * `overlap` draws every band from zero, one in front of another, so each
51
+ * part's own amount is its height: the first column is in front. Use it to
52
+ * compare the parts with each other; the scale then fits the largest part
53
+ * rather than the total.
54
+ *
47
55
  * The drawing is hidden from screen readers. The text summary gives the latest
48
56
  * reading's total and each part's share of it, and the table beside the chart
49
57
  * has every number.
@@ -121,6 +129,15 @@ export declare class HelixHeadlessAreaChart extends HelixHeadlessAreaChart_base
121
129
  * a rule nobody sees.
122
130
  */
123
131
  gridlines?: 'both' | 'category' | 'value';
132
+ /**
133
+ * Draws every band from zero, in front of the next, so a band's height is
134
+ * its own part's amount and not its place in a stack.
135
+ *
136
+ * Absent stacks the parts, so the top edge is the total. Set, the first
137
+ * column is in front and the scale fits the largest part. Reflected, because
138
+ * the styled tier lets the bands behind show through the ones in front.
139
+ */
140
+ overlap: boolean;
124
141
  /**
125
142
  * Draws each reading as a hundred percent, so each band shows its share of
126
143
  * the total.