@fusion.dev/helix-headless 0.147.0 → 0.149.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 (296) hide show
  1. package/custom-elements.json +11222 -2332
  2. package/dist/accordion/item/accordion-item.d.ts +5 -2
  3. package/dist/accordion/item/accordion-item.js +11 -7
  4. package/dist/accordion/root/accordion-root.js +4 -6
  5. package/dist/announcement/root/announcement-root.d.ts +61 -5
  6. package/dist/announcement/root/announcement-root.js +126 -20
  7. package/dist/area-chart/root/area-chart-root.d.ts +11 -0
  8. package/dist/area-chart/root/area-chart-root.js +21 -9
  9. package/dist/avatar/group/avatar-group.d.ts +10 -2
  10. package/dist/avatar/group/avatar-group.js +10 -5
  11. package/dist/badge/count.d.ts +19 -0
  12. package/dist/badge/count.js +20 -0
  13. package/dist/badge/root/badge-root.d.ts +6 -2
  14. package/dist/badge/root/badge-root.js +8 -22
  15. package/dist/bar-chart/root/bar-chart-root.d.ts +13 -1
  16. package/dist/bar-chart/root/bar-chart-root.js +17 -4
  17. package/dist/blockquote/root/blockquote-root.d.ts +66 -8
  18. package/dist/blockquote/root/blockquote-root.js +85 -8
  19. package/dist/breadcrumbs/breadcrumb/breadcrumb.js +2 -2
  20. package/dist/breadcrumbs/root/breadcrumbs-root.d.ts +8 -1
  21. package/dist/breadcrumbs/root/breadcrumbs-root.js +5 -2
  22. package/dist/button/root/button-root.d.ts +10 -1
  23. package/dist/button/root/button-root.js +3 -2
  24. package/dist/button-group/arrows.d.ts +14 -0
  25. package/dist/button-group/arrows.js +10 -0
  26. package/dist/button-group/root/button-group-root.d.ts +144 -3
  27. package/dist/button-group/root/button-group-root.js +142 -2
  28. package/dist/callout/root/callout-root.d.ts +16 -2
  29. package/dist/callout/root/callout-root.js +16 -4
  30. package/dist/canvas/describe.d.ts +10 -0
  31. package/dist/canvas/describe.js +9 -0
  32. package/dist/canvas/edge-pan.d.ts +61 -0
  33. package/dist/canvas/edge-pan.js +63 -0
  34. package/dist/canvas/neighbor.d.ts +17 -0
  35. package/dist/canvas/neighbor.js +1 -0
  36. package/dist/canvas/node/canvas-node.d.ts +12 -2
  37. package/dist/canvas/node/canvas-node.js +8 -3
  38. package/dist/canvas/root/canvas-document.d.ts +10 -0
  39. package/dist/canvas/root/canvas-document.js +1 -0
  40. package/dist/canvas/root/canvas-root.d.ts +168 -9
  41. package/dist/canvas/root/canvas-root.js +239 -69
  42. package/dist/canvas/snap.d.ts +42 -0
  43. package/dist/canvas/snap.js +32 -0
  44. package/dist/carousel/root/carousel-root.d.ts +9 -3
  45. package/dist/carousel/root/carousel-root.js +17 -10
  46. package/dist/chat/composer/chat-composer.d.ts +5 -0
  47. package/dist/chat/composer/chat-composer.js +4 -1
  48. package/dist/chat/message/chat-message.d.ts +9 -5
  49. package/dist/chat/message/chat-message.js +8 -4
  50. package/dist/chat/naming.js +2 -2
  51. package/dist/chat/root/chat-root.d.ts +40 -4
  52. package/dist/chat/root/chat-root.js +38 -14
  53. package/dist/checkbox/root/checkbox-root.d.ts +11 -0
  54. package/dist/checkbox/root/checkbox-root.js +8 -2
  55. package/dist/checkbox-group/root/checkbox-group-root.d.ts +24 -0
  56. package/dist/checkbox-group/root/checkbox-group-root.js +28 -12
  57. package/dist/checkbox-group/select-all.d.ts +11 -0
  58. package/dist/checkbox-group/select-all.js +5 -0
  59. package/dist/code-block/root/code-block-root.d.ts +20 -8
  60. package/dist/code-block/root/code-block-root.js +16 -5
  61. package/dist/color-input/root/color-input-root.d.ts +13 -0
  62. package/dist/color-input/root/color-input-root.js +18 -5
  63. package/dist/color-picker/root/color-picker-root.d.ts +19 -3
  64. package/dist/color-picker/root/color-picker-root.js +52 -24
  65. package/dist/color-picker/wheel.d.ts +11 -0
  66. package/dist/color-picker/wheel.js +9 -0
  67. package/dist/combobox/root/combobox-root.d.ts +106 -18
  68. package/dist/combobox/root/combobox-root.js +101 -26
  69. package/dist/command/root/command-root.d.ts +19 -9
  70. package/dist/command/root/command-root.js +9 -4
  71. package/dist/copy-button/root/copy-button-root.d.ts +5 -0
  72. package/dist/copy-button/root/copy-button-root.js +7 -2
  73. package/dist/data-table/root/data-table-root.d.ts +171 -29
  74. package/dist/data-table/root/data-table-root.js +284 -161
  75. package/dist/date-input/root/date-input-root.d.ts +32 -9
  76. package/dist/date-input/root/date-input-root.js +66 -44
  77. package/dist/date-picker/root/date-picker-root.d.ts +38 -15
  78. package/dist/date-picker/root/date-picker-root.js +52 -33
  79. package/dist/description-list/item/description-list-item.d.ts +4 -0
  80. package/dist/description-list/item/description-list-item.js +7 -1
  81. package/dist/dialog/root/dialog-root.d.ts +12 -1
  82. package/dist/dialog/root/dialog-root.js +11 -4
  83. package/dist/divider/root/divider-root.d.ts +45 -16
  84. package/dist/divider/root/divider-root.js +28 -4
  85. package/dist/donut-chart/root/donut-chart-root.d.ts +5 -0
  86. package/dist/donut-chart/root/donut-chart-root.js +8 -5
  87. package/dist/drawer/root/drawer-root.d.ts +12 -1
  88. package/dist/drawer/root/drawer-root.js +9 -2
  89. package/dist/drilldown/item/drilldown-item.js +3 -4
  90. package/dist/drilldown/root/drilldown-root.d.ts +5 -0
  91. package/dist/drilldown/root/drilldown-root.js +4 -1
  92. package/dist/element-events.generated.js +26 -3
  93. package/dist/empty/root/empty-root.d.ts +17 -3
  94. package/dist/empty/root/empty-root.js +29 -5
  95. package/dist/file-input/root/file-input-root.d.ts +18 -3
  96. package/dist/file-input/root/file-input-root.js +34 -18
  97. package/dist/file-input/status.js +2 -1
  98. package/dist/filter-input/chip/filter-chip.d.ts +13 -0
  99. package/dist/filter-input/chip/filter-chip.js +7 -3
  100. package/dist/filter-input/menu/filter-menu.d.ts +5 -0
  101. package/dist/filter-input/menu/filter-menu.js +3 -1
  102. package/dist/filter-input/root/filter-input-root.d.ts +20 -3
  103. package/dist/filter-input/root/filter-input-root.js +8 -4
  104. package/dist/format-date/fields.d.ts +20 -0
  105. package/dist/format-date/fields.js +14 -0
  106. package/dist/format-date/options.d.ts +2 -1
  107. package/dist/format-date/options.js +9 -38
  108. package/dist/format-date/root/format-date-root.d.ts +55 -5
  109. package/dist/format-date/root/format-date-root.js +29 -34
  110. package/dist/graph/root/graph-model.d.ts +11 -0
  111. package/dist/graph/root/graph-model.js +4 -0
  112. package/dist/graph/root/graph-root.d.ts +101 -14
  113. package/dist/graph/root/graph-root.js +140 -46
  114. package/dist/heatmap/root/heatmap-root.d.ts +37 -4
  115. package/dist/heatmap/root/heatmap-root.js +51 -16
  116. package/dist/icon-button/root/icon-button-root.d.ts +5 -0
  117. package/dist/icon-button/root/icon-button-root.js +1 -0
  118. package/dist/image/root/image-root.d.ts +11 -0
  119. package/dist/input/root/input-root.d.ts +5 -0
  120. package/dist/input/root/input-root.js +4 -1
  121. package/dist/kbd/root/kbd-root.js +1 -2
  122. package/dist/legend/root/legend-root.js +4 -17
  123. package/dist/lightbox/root/lightbox-root.d.ts +14 -4
  124. package/dist/lightbox/root/lightbox-root.js +25 -7
  125. package/dist/line-chart/root/line-chart-root.d.ts +5 -0
  126. package/dist/line-chart/root/line-chart-root.js +4 -2
  127. package/dist/list/item/list-item.d.ts +32 -0
  128. package/dist/list/item/list-item.js +34 -7
  129. package/dist/list/root/list-root.d.ts +87 -0
  130. package/dist/list/root/list-root.js +119 -23
  131. package/dist/listbox/reorder/index.d.ts +1 -0
  132. package/dist/listbox/reorder/index.js +4 -0
  133. package/dist/listbox/reorder/listbox-reorder.d.ts +83 -0
  134. package/dist/listbox/reorder/listbox-reorder.js +151 -0
  135. package/dist/listbox/root/listbox-root.d.ts +185 -33
  136. package/dist/listbox/root/listbox-root.js +166 -136
  137. package/dist/loader/root/loader-root.d.ts +5 -0
  138. package/dist/loader/root/loader-root.js +3 -1
  139. package/dist/map/area/map-area.d.ts +5 -0
  140. package/dist/map/area/map-area.js +3 -1
  141. package/dist/map/buildings/map-buildings.d.ts +5 -0
  142. package/dist/map/buildings/map-buildings.js +3 -1
  143. package/dist/map/contours/map-contours.d.ts +5 -0
  144. package/dist/map/contours/map-contours.js +3 -1
  145. package/dist/map/landcover/map-landcover.d.ts +5 -0
  146. package/dist/map/landcover/map-landcover.js +3 -1
  147. package/dist/map/marker/map-marker.d.ts +18 -2
  148. package/dist/map/marker/map-marker.js +13 -5
  149. package/dist/map/points/map-points.d.ts +5 -0
  150. package/dist/map/points/map-points.js +6 -4
  151. package/dist/map/position/map-position.d.ts +5 -0
  152. package/dist/map/position/map-position.js +3 -1
  153. package/dist/map/raster/map-raster.d.ts +5 -0
  154. package/dist/map/raster/map-raster.js +3 -1
  155. package/dist/map/root/map-root.d.ts +73 -16
  156. package/dist/map/root/map-root.js +122 -44
  157. package/dist/map/route/map-route.d.ts +5 -0
  158. package/dist/map/route/map-route.js +3 -1
  159. package/dist/map/terrain/map-terrain.d.ts +5 -0
  160. package/dist/map/terrain/map-terrain.js +3 -1
  161. package/dist/megamenu/root/megamenu-root.js +4 -11
  162. package/dist/menu/root/menu-root.d.ts +7 -2
  163. package/dist/menu/root/menu-root.js +3 -1
  164. package/dist/meter/root/meter-root.d.ts +16 -3
  165. package/dist/meter/root/meter-root.js +12 -5
  166. package/dist/navigation/root/navigation-root.d.ts +5 -0
  167. package/dist/navigation/root/navigation-root.js +7 -8
  168. package/dist/notifications/group/notification-group.d.ts +8 -1
  169. package/dist/notifications/group/notification-group.js +12 -6
  170. package/dist/notifications/notification/notification.d.ts +17 -1
  171. package/dist/notifications/notification/notification.js +6 -2
  172. package/dist/notifications/root/notifications-root.d.ts +49 -5
  173. package/dist/notifications/root/notifications-root.js +36 -8
  174. package/dist/number-input/root/number-input-root.d.ts +21 -8
  175. package/dist/number-input/root/number-input-root.js +26 -11
  176. package/dist/object-inspector/root/object-inspector-root.d.ts +56 -13
  177. package/dist/object-inspector/root/object-inspector-root.js +41 -30
  178. package/dist/outline/root/outline-root.d.ts +5 -0
  179. package/dist/outline/root/outline-root.js +3 -1
  180. package/dist/pagination/root/pagination-root.d.ts +7 -1
  181. package/dist/pagination/root/pagination-root.js +16 -7
  182. package/dist/pagination/size/pagination-size.d.ts +8 -3
  183. package/dist/pagination/size/pagination-size.js +5 -3
  184. package/dist/pagination/summary/pagination-summary.d.ts +8 -6
  185. package/dist/pagination/summary/pagination-summary.js +4 -9
  186. package/dist/pin-input/code.d.ts +23 -0
  187. package/dist/pin-input/code.js +21 -0
  188. package/dist/pin-input/root/pin-input-root.d.ts +9 -3
  189. package/dist/pin-input/root/pin-input-root.js +13 -23
  190. package/dist/popover/root/popover-root.d.ts +12 -2
  191. package/dist/popover/root/popover-root.js +10 -4
  192. package/dist/progress/root/progress-root.d.ts +7 -2
  193. package/dist/progress/root/progress-root.js +5 -2
  194. package/dist/qr-code/name.d.ts +3 -2
  195. package/dist/qr-code/name.js +2 -2
  196. package/dist/qr-code/root/qr-code-root.d.ts +26 -5
  197. package/dist/qr-code/root/qr-code-root.js +27 -6
  198. package/dist/radio/group/radio-group.d.ts +11 -0
  199. package/dist/radio/group/radio-group.js +8 -2
  200. package/dist/rating/root/rating-root.d.ts +12 -1
  201. package/dist/rating/root/rating-root.js +10 -3
  202. package/dist/scatter-chart/measures.d.ts +22 -0
  203. package/dist/scatter-chart/measures.js +11 -0
  204. package/dist/scatter-chart/root/scatter-chart-root.d.ts +22 -8
  205. package/dist/scatter-chart/root/scatter-chart-root.js +25 -23
  206. package/dist/select/root/select-root.d.ts +67 -8
  207. package/dist/select/root/select-root.js +45 -11
  208. package/dist/skip-link/root/skip-link-root.d.ts +5 -0
  209. package/dist/skip-link/root/skip-link-root.js +3 -1
  210. package/dist/slider/root/slider-root.d.ts +7 -2
  211. package/dist/slider/root/slider-root.js +11 -5
  212. package/dist/sparkline/readings.d.ts +15 -5
  213. package/dist/sparkline/readings.js +3 -3
  214. package/dist/sparkline/root/sparkline-root.d.ts +9 -4
  215. package/dist/sparkline/root/sparkline-root.js +9 -3
  216. package/dist/speed-dial/group/speed-dial-group.d.ts +48 -0
  217. package/dist/speed-dial/group/speed-dial-group.js +43 -0
  218. package/dist/speed-dial/index.d.ts +1 -0
  219. package/dist/speed-dial/index.js +1 -0
  220. package/dist/speed-dial/item/speed-dial-item.d.ts +26 -1
  221. package/dist/speed-dial/item/speed-dial-item.js +41 -3
  222. package/dist/speed-dial/long-press.d.ts +50 -0
  223. package/dist/speed-dial/long-press.js +48 -0
  224. package/dist/speed-dial/root/speed-dial-root.d.ts +85 -1
  225. package/dist/speed-dial/root/speed-dial-root.js +117 -5
  226. package/dist/splitter/root/splitter-root.d.ts +12 -3
  227. package/dist/splitter/root/splitter-root.js +22 -4
  228. package/dist/steps/root/steps-root.d.ts +9 -2
  229. package/dist/steps/root/steps-root.js +6 -3
  230. package/dist/steps/step/step.d.ts +12 -0
  231. package/dist/steps/step/step.js +11 -2
  232. package/dist/switch/root/switch-root.d.ts +11 -0
  233. package/dist/switch/root/switch-root.js +8 -2
  234. package/dist/table/cell/table-cell.d.ts +8 -1
  235. package/dist/table/cell/table-cell.js +6 -2
  236. package/dist/table/column/table-column.d.ts +11 -4
  237. package/dist/table/column/table-column.js +15 -10
  238. package/dist/table/grid-controller.d.ts +122 -0
  239. package/dist/table/grid-controller.js +299 -0
  240. package/dist/table/root/table-root.d.ts +154 -8
  241. package/dist/table/root/table-root.js +197 -38
  242. package/dist/table/row/table-row.d.ts +55 -1
  243. package/dist/table/row/table-row.js +60 -7
  244. package/dist/tabs/root/tabs-root.d.ts +5 -0
  245. package/dist/tabs/root/tabs-root.js +3 -1
  246. package/dist/tag/group/tag-group.d.ts +5 -0
  247. package/dist/tag/group/tag-group.js +8 -15
  248. package/dist/tag/root/tag-root.d.ts +14 -1
  249. package/dist/tag/root/tag-root.js +11 -8
  250. package/dist/textarea/root/textarea-root.d.ts +5 -0
  251. package/dist/textarea/root/textarea-root.js +3 -1
  252. package/dist/time-input/root/time-input-root.d.ts +14 -7
  253. package/dist/time-input/root/time-input-root.js +43 -32
  254. package/dist/time-picker/root/time-picker-root.d.ts +16 -7
  255. package/dist/time-picker/root/time-picker-root.js +28 -12
  256. package/dist/toast/item/toast-item.d.ts +13 -3
  257. package/dist/toast/item/toast-item.js +2 -0
  258. package/dist/toast/root/toast-root.d.ts +22 -2
  259. package/dist/toast/root/toast-root.js +24 -17
  260. package/dist/toggle/group/toggle-group.js +3 -5
  261. package/dist/toolbar/root/toolbar-root.d.ts +36 -0
  262. package/dist/toolbar/root/toolbar-root.js +43 -9
  263. package/dist/tooltip/root/tooltip-root.d.ts +27 -17
  264. package/dist/tooltip/root/tooltip-root.js +1 -2
  265. package/dist/tour/root/tour-root.d.ts +8 -2
  266. package/dist/tour/root/tour-root.js +4 -2
  267. package/dist/tour/stop/tour-stop.d.ts +5 -0
  268. package/dist/tour/stop/tour-stop.js +6 -1
  269. package/dist/tree/grip.d.ts +5 -0
  270. package/dist/tree/grip.js +1 -0
  271. package/dist/tree/item/tree-item.d.ts +24 -0
  272. package/dist/tree/item/tree-item.js +27 -5
  273. package/dist/tree/root/tree-root.d.ts +66 -1
  274. package/dist/tree/root/tree-root.js +77 -5
  275. package/dist/trend/root/trend-root.d.ts +20 -4
  276. package/dist/trend/root/trend-root.js +20 -5
  277. package/dist/video/root/video-root.d.ts +23 -3
  278. package/dist/video/root/video-root.js +56 -15
  279. package/dist/video-playlist/menu/video-playlist-menu.d.ts +5 -0
  280. package/dist/video-playlist/menu/video-playlist-menu.js +3 -1
  281. package/dist/video-playlist/root/video-playlist-root.d.ts +5 -0
  282. package/dist/video-playlist/root/video-playlist-root.js +3 -1
  283. package/dist/virtual-list/root/virtual-list-root.d.ts +19 -3
  284. package/dist/virtual-list/root/virtual-list-root.js +10 -19
  285. package/lint.json +1 -1
  286. package/package.json +7 -6
  287. package/types/jsx.d.ts +6005 -2114
  288. package/types/svelte.d.ts +1 -0
  289. package/types/vue.d.ts +1594 -676
  290. package/types/words.d.ts +3280 -0
  291. package/dist/kbd/keys.d.ts +0 -29
  292. package/dist/kbd/keys.js +0 -52
  293. package/dist/toast/hotkey.d.ts +0 -22
  294. package/dist/toast/hotkey.js +0 -23
  295. package/dist/tooltip/focus-target.d.ts +0 -6
  296. package/dist/tooltip/focus-target.js +0 -9
@@ -65,6 +65,7 @@ import '../../select/index.js';
65
65
  * @csspart control-listbox-loading - The text shown while the options load.
66
66
  * @csspart control-listbox-search - The region that holds the filter field.
67
67
  * @csspart control-listbox-search-field - The filter field.
68
+ * @csspart control-live - The select's `live` part, the region a screen reader hears a choice made on the closed trigger from.
68
69
  * @csspart control-surface - The floating panel.
69
70
  * @csspart control-trigger - The closed control, which shows the chosen size.
70
71
  * @csspart control-value - The chosen size inside the trigger.
@@ -79,6 +80,11 @@ import '../../select/index.js';
79
80
  * @cssstate empty - While there are no sizes to offer.
80
81
  */
81
82
  export declare class HelixHeadlessPaginationSize extends HelixFormElement {
83
+ /**
84
+ * The key this part's words are registered under, its styled tag:
85
+ * `registerWords('de', { 'helix-pagination-size': { label: 'Pro Seite' } })`.
86
+ */
87
+ static words: string;
82
88
  /**
83
89
  * The size to start on when `value` is not set.
84
90
  */
@@ -88,9 +94,8 @@ export declare class HelixHeadlessPaginationSize extends HelixFormElement {
88
94
  */
89
95
  label: string;
90
96
  /**
91
- * Locale for the numbers.
92
- *
93
- * Absent uses the runtime's own.
97
+ * The locale the words and the numbers are in, as a BCP 47 tag such as
98
+ * `de`. Empty reads the nearest `lang`, then the browser's language.
94
99
  */
95
100
  locale: string;
96
101
  /**
@@ -4,7 +4,7 @@ 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, formatNumbers, HelixBeforeChangeEvent, HelixFormElement, hostWords, requestChange, } from '@fusion.dev/helix-core';
7
+ import { customElement, formatNumbers, HelixBeforeChangeEvent, HelixFormElement, hostWords, requestChange, words, wordsLocale, } from '@fusion.dev/helix-core';
8
8
  import { nothing } from 'lit';
9
9
  import { property } from 'lit/decorators.js';
10
10
  import { html } from 'lit/static-html.js';
@@ -47,6 +47,7 @@ let HelixHeadlessPaginationSize = class HelixHeadlessPaginationSize extends Heli
47
47
  event.stopPropagation();
48
48
  };
49
49
  }
50
+ static { this.words = 'helix-pagination-size'; }
50
51
  get value() {
51
52
  return this.valueState ?? this.defaultValue;
52
53
  }
@@ -56,7 +57,7 @@ let HelixHeadlessPaginationSize = class HelixHeadlessPaginationSize extends Heli
56
57
  this.requestUpdate('value', previous);
57
58
  }
58
59
  get numbers() {
59
- return formatNumbers(this.locale);
60
+ return formatNumbers(wordsLocale(this));
60
61
  }
61
62
  get options() {
62
63
  return this.sizes
@@ -98,7 +99,7 @@ let HelixHeadlessPaginationSize = class HelixHeadlessPaginationSize extends Heli
98
99
  listbox-filter-mark: control-listbox-filter-mark, listbox-hint: control-listbox-hint,
99
100
  listbox-items: control-listbox-items, listbox-label: control-listbox-label,
100
101
  listbox-live: control-listbox-live, listbox-loading: control-listbox-loading, listbox-search: control-listbox-search,
101
- listbox-search-field: control-listbox-search-field, surface: control-surface,
102
+ listbox-search-field: control-listbox-search-field, live: control-live, surface: control-surface,
102
103
  trigger: control-trigger, value: control-value"
103
104
  label=${named ? '' : this.label}
104
105
  aria-label=${named || nothing}
@@ -129,6 +130,7 @@ __decorate([
129
130
  property({ attribute: 'default-value', type: Number })
130
131
  ], HelixHeadlessPaginationSize.prototype, "defaultValue", void 0);
131
132
  __decorate([
133
+ words,
132
134
  property()
133
135
  ], HelixHeadlessPaginationSize.prototype, "label", void 0);
134
136
  __decorate([
@@ -21,9 +21,14 @@ import { type TemplateResult } from 'lit';
21
21
  * @documentation https://fusion.dev/helix/components/pagination
22
22
  */
23
23
  export declare class HelixHeadlessPaginationSummary extends HelixElement {
24
+ /**
25
+ * The key this part's words are registered under, its styled tag:
26
+ * `registerWords('de', { 'helix-pagination-summary': { format: '{from} bis {to} von {total}' } })`.
27
+ */
28
+ static words: string;
24
29
  /**
25
30
  * The text shown. `{from}`, `{to}`, and `{total}` are replaced with the first
26
- * item, the last item, and the item count.
31
+ * item, the last item, and the item count, written in the locale.
27
32
  *
28
33
  * A template rather than a prefix and a suffix, because word order is not
29
34
  * universal: `format="{total} 件中 {from}-{to} 件"` is one attribute here and
@@ -39,9 +44,8 @@ export declare class HelixHeadlessPaginationSummary extends HelixElement {
39
44
  */
40
45
  format: string;
41
46
  /**
42
- * Locale for the numbers.
43
- *
44
- * Absent uses the runtime's own.
47
+ * The locale the words and the numbers are in, as a BCP 47 tag such as
48
+ * `de`. Empty reads the nearest `lang`, then the browser's language.
45
49
  */
46
50
  locale: string;
47
51
  /**
@@ -56,8 +60,6 @@ export declare class HelixHeadlessPaginationSummary extends HelixElement {
56
60
  * How many items there are across every page.
57
61
  */
58
62
  total: number;
59
- /** Held across every component asking for the same locale. */
60
- private get numbers();
61
63
  protected render(): TemplateResult;
62
64
  }
63
65
  declare global {
@@ -4,7 +4,7 @@ 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, fillTemplate, formatNumbers, HelixElement } from '@fusion.dev/helix-core';
7
+ import { customElement, formatWords, HelixElement, words } from '@fusion.dev/helix-core';
8
8
  import { html } from 'lit';
9
9
  import { property } from 'lit/decorators.js';
10
10
  let HelixHeadlessPaginationSummary = class HelixHeadlessPaginationSummary extends HelixElement {
@@ -16,9 +16,7 @@ let HelixHeadlessPaginationSummary = class HelixHeadlessPaginationSummary extend
16
16
  this.pageSize = 0;
17
17
  this.total = 0;
18
18
  }
19
- get numbers() {
20
- return formatNumbers(this.locale);
21
- }
19
+ static { this.words = 'helix-pagination-summary'; }
22
20
  render() {
23
21
  if (this.total <= 0 || this.pageSize <= 0) {
24
22
  return html ``;
@@ -28,14 +26,11 @@ let HelixHeadlessPaginationSummary = class HelixHeadlessPaginationSummary extend
28
26
  const page = Math.min(pages, Math.max(1, Math.floor(this.page) || 1));
29
27
  const from = (page - 1) * size + 1;
30
28
  const to = Math.min(this.total, from + size - 1);
31
- return html `${fillTemplate(this.format, {
32
- from: this.numbers(from),
33
- to: this.numbers(to),
34
- total: this.numbers(this.total),
35
- })}`;
29
+ return html `${formatWords(this, 'format', { from, to, total: this.total })}`;
36
30
  }
37
31
  };
38
32
  __decorate([
33
+ words,
39
34
  property()
40
35
  ], HelixHeadlessPaginationSummary.prototype, "format", void 0);
41
36
  __decorate([
@@ -1,3 +1,4 @@
1
+ import type { PickerVerdict } from '@fusion.dev/helix-core';
1
2
  /** What a box accepts, which decides the keyboard a phone offers. */
2
3
  export type PinType = 'alphanumeric' | 'numeric' | 'text';
3
4
  /** How typed letters are cased: as typed, or turned upper or lower case. */
@@ -35,3 +36,25 @@ export declare const readTyped: (raw: string, caret: number, type: PinType, lett
35
36
  * holding two fill from box three.
36
37
  */
37
38
  export declare const overwriteCode: (code: string, at: number, text: string, count: number) => CodeEdit;
39
+ /** The messages a code's verdict is written with. */
40
+ export interface CodeMessages {
41
+ /** For a code with no characters in a required field. */
42
+ missing?: string | undefined;
43
+ /** For a code with fewer characters than boxes, written for how many there are. */
44
+ short: (length: number) => string;
45
+ }
46
+ /**
47
+ * What is wrong with a code, as a picker field reports it: a required field
48
+ * with nothing in it is missing, a code with fewer characters than boxes is
49
+ * too short, and anything else is fine (`''`). The platform's own words for a
50
+ * missing code where the page set none.
51
+ */
52
+ export declare const codeVerdict: (code: string, count: number, required: boolean, messages: CodeMessages) => PickerVerdict;
53
+ /**
54
+ * The box a caret key moves to from `caret`, kept within the boxes up to
55
+ * `end`, or `undefined` for a key that moves nothing.
56
+ *
57
+ * Not `inlineStep`: the row is left to right whatever the page, so the key
58
+ * pointing right is the one that moves on in every script.
59
+ */
60
+ export declare const caretTo: (key: string, caret: number, end: number) => number | undefined;
@@ -23,3 +23,24 @@ export const overwriteCode = (code, at, text, count) => {
23
23
  }
24
24
  return { caret: Math.min(count - 1, start + text.length), code: characters.join('') };
25
25
  };
26
+ export const codeVerdict = (code, count, required, messages) => {
27
+ if (required && code === '') {
28
+ return ['valueMissing', messages.missing || 'Please fill in this field.'];
29
+ }
30
+ if (code !== '' && code.length < count) {
31
+ return ['tooShort', messages.short(count)];
32
+ }
33
+ return '';
34
+ };
35
+ export const caretTo = (key, caret, end) => {
36
+ const to = key === 'ArrowRight'
37
+ ? caret + 1
38
+ : key === 'ArrowLeft'
39
+ ? caret - 1
40
+ : key === 'Home'
41
+ ? 0
42
+ : key === 'End'
43
+ ? end
44
+ : undefined;
45
+ return to === undefined ? undefined : Math.max(0, Math.min(to, end));
46
+ };
@@ -84,6 +84,11 @@ declare const HelixHeadlessPinInput_base: (new (...args: any[]) => import("@fusi
84
84
  * @cssstate invalid - The control has an error to show, from the browser's validation or from your `feedback`.
85
85
  */
86
86
  export declare class HelixHeadlessPinInput extends HelixHeadlessPinInput_base {
87
+ /**
88
+ * The key this family's words are registered under, its styled tag:
89
+ * `registerWords('de', { 'helix-pin-input': { tooShortMessage: '{length, plural, one {Bitte # Zeichen eingeben.} other {Bitte alle # Zeichen eingeben.}}' } })`.
90
+ */
91
+ static words: string;
87
92
  protected readonly aria: AriaForwardController;
88
93
  /** Typed or pasted, so every edit is announced. See `announcesInput`. */
89
94
  protected readonly announcesInput = true;
@@ -144,10 +149,11 @@ export declare class HelixHeadlessPinInput extends HelixHeadlessPinInput_base {
144
149
  */
145
150
  readOnly: boolean;
146
151
  /**
147
- * The message shown when the code is started and not finished, with
148
- * `{length}` filled in. When it is unset, an English default is shown.
152
+ * The message shown when the code is started and not finished. `{length}`
153
+ * is how many characters the code has, written in the locale, and each
154
+ * language writes the forms it has.
149
155
  */
150
- tooShortMessage?: string;
156
+ tooShortMessage: string;
151
157
  /**
152
158
  * The characters a box accepts, which also sets the keyboard a phone shows.
153
159
  *
@@ -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 { AriaForwardController, customElement, fillTemplate, HelixCompleteEvent, HelixFormElement, MixinControllerValue, MixinField, restoreValue, submitImplicitly, } from '@fusion.dev/helix-core';
7
+ import { AriaForwardController, customElement, formatWords, HelixCompleteEvent, HelixFormElement, MixinControllerValue, MixinField, restoreValue, submitImplicitly, verdictFlags, words, } from '@fusion.dev/helix-core';
8
8
  import { html, nothing } from 'lit';
9
9
  import { property, state } from 'lit/decorators.js';
10
- import { cleanCode, overwriteCode, readTyped, } from '../code.js';
10
+ import { caretTo, cleanCode, codeVerdict, overwriteCode, readTyped, } from '../code.js';
11
11
  import { separatorsAfter } from '../format.js';
12
12
  const UNSEEN = 'position:absolute;width:1px;height:1px;opacity:0;pointer-events:none;font-size:16px';
13
13
  const keepFocus = (event) => event.preventDefault();
@@ -28,6 +28,7 @@ let HelixHeadlessPinInput = class HelixHeadlessPinInput extends MixinControllerV
28
28
  this.maskCharacter = '•';
29
29
  this.placeholder = '';
30
30
  this.readOnly = false;
31
+ this.tooShortMessage = '{length, plural, one {Please enter the # character.} other {Please enter all # characters.}}';
31
32
  this.type = 'numeric';
32
33
  this.active = -1;
33
34
  this.pressedAt = undefined;
@@ -61,20 +62,12 @@ let HelixHeadlessPinInput = class HelixHeadlessPinInput extends MixinControllerV
61
62
  }
62
63
  return;
63
64
  }
64
- const to = event.key === 'ArrowRight'
65
- ? this.caretBox + 1
66
- : event.key === 'ArrowLeft'
67
- ? this.caretBox - 1
68
- : event.key === 'Home'
69
- ? 0
70
- : event.key === 'End'
71
- ? this.end
72
- : undefined;
65
+ const to = caretTo(event.key, this.caretBox, this.end);
73
66
  if (to === undefined) {
74
67
  return;
75
68
  }
76
69
  event.preventDefault();
77
- this.active = Math.max(0, Math.min(to, this.end));
70
+ this.active = to;
78
71
  this.placeCaret(true);
79
72
  };
80
73
  this.handlePress = (event) => {
@@ -112,6 +105,7 @@ let HelixHeadlessPinInput = class HelixHeadlessPinInput extends MixinControllerV
112
105
  }
113
106
  };
114
107
  }
108
+ static { this.words = 'helix-pin-input'; }
115
109
  static { this.shadowRootOptions = {
116
110
  ...HelixFormElement.shadowRootOptions,
117
111
  delegatesFocus: true,
@@ -172,17 +166,11 @@ let HelixHeadlessPinInput = class HelixHeadlessPinInput extends MixinControllerV
172
166
  if (!control) {
173
167
  return;
174
168
  }
175
- if (this.required && this.value === '') {
176
- this.internals.setValidity({ valueMissing: true }, this.valueMissingMessage || 'Please fill in this field.', control);
177
- }
178
- else if (this.value !== '' && this.value.length < this.count) {
179
- this.internals.setValidity({ tooShort: true }, fillTemplate(this.tooShortMessage || 'Please enter all {length} characters.', {
180
- length: this.count,
181
- }), control);
182
- }
183
- else {
184
- this.internals.setValidity({}, '', control);
185
- }
169
+ const found = verdictFlags(codeVerdict(this.value, this.count, this.required, {
170
+ missing: this.valueMissingMessage,
171
+ short: (length) => formatWords(this, 'tooShortMessage', { length }),
172
+ }));
173
+ this.internals.setValidity(found?.[0] ?? {}, found?.[1] ?? '', control);
186
174
  this.refreshFeedback();
187
175
  }
188
176
  focus(options) {
@@ -274,6 +262,7 @@ __decorate([
274
262
  property()
275
263
  ], HelixHeadlessPinInput.prototype, "case", void 0);
276
264
  __decorate([
265
+ words,
277
266
  property({ attribute: 'cell-label' })
278
267
  ], HelixHeadlessPinInput.prototype, "cellLabel", void 0);
279
268
  __decorate([
@@ -295,6 +284,7 @@ __decorate([
295
284
  property({ attribute: 'readonly', reflect: true, type: Boolean })
296
285
  ], HelixHeadlessPinInput.prototype, "readOnly", void 0);
297
286
  __decorate([
287
+ words,
298
288
  property({ attribute: 'too-short-message' })
299
289
  ], HelixHeadlessPinInput.prototype, "tooShortMessage", void 0);
300
290
  __decorate([
@@ -81,6 +81,11 @@ declare const HelixHeadlessPopover_base: (new (...args: any[]) => import("@fusio
81
81
  * @cssstate placed-top - While the panel sits above its trigger.
82
82
  */
83
83
  export declare class HelixHeadlessPopover extends HelixHeadlessPopover_base {
84
+ /**
85
+ * The key this family's words are registered under, its styled tag:
86
+ * `registerWords('de', { 'helix-popover': { fallbackLabel: 'Popup' } })`.
87
+ */
88
+ static words: string;
84
89
  /**
85
90
  * Draws a point on the panel's edge facing the trigger.
86
91
  *
@@ -89,8 +94,13 @@ export declare class HelixHeadlessPopover extends HelixHeadlessPopover_base {
89
94
  */
90
95
  arrow: boolean;
91
96
  /**
92
- * The panel's name, read by screen readers. Left at `Popover`, the first
93
- * heading in the panel names it instead.
97
+ * The panel's name where nothing else names it: no `label`, no heading in
98
+ * the panel, and no `aria-labelledby` on the host.
99
+ */
100
+ fallbackLabel: string;
101
+ /**
102
+ * The panel's name, read by screen readers. Left empty, the first heading in
103
+ * the panel names it, and then `fallback-label`.
94
104
  */
95
105
  label: string;
96
106
  /**
@@ -4,7 +4,7 @@ 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 { AriaForwardController, anchorElement, arrowReach, CommandController, customElement, deepActiveElement, FocusScopeController, HelixElement, headingIn, MixinControllerOpen, OpenPhaseController, PopoverController, reflectElements, sideOf, tellDisclosure, } from '@fusion.dev/helix-core';
7
+ import { AriaForwardController, anchorElement, arrowReach, CommandController, customElement, deepActiveElement, FocusScopeController, HelixElement, headingIn, MixinControllerOpen, OpenPhaseController, PopoverController, reflectElements, sideOf, tellDisclosure, words, } from '@fusion.dev/helix-core';
8
8
  import { html, nothing } from 'lit';
9
9
  import { property, state } from 'lit/decorators.js';
10
10
  import { hideOutside } from '../hide-outside.js';
@@ -12,7 +12,8 @@ let HelixHeadlessPopover = class HelixHeadlessPopover extends MixinControllerOpe
12
12
  constructor() {
13
13
  super(...arguments);
14
14
  this.arrow = false;
15
- this.label = 'Popover';
15
+ this.fallbackLabel = 'Popover';
16
+ this.label = '';
16
17
  this.modal = false;
17
18
  this.aria = new AriaForwardController(this, {
18
19
  target: () => this.partNamed('popover'),
@@ -99,13 +100,14 @@ let HelixHeadlessPopover = class HelixHeadlessPopover extends MixinControllerOpe
99
100
  this.pressed = false;
100
101
  this.settled = false;
101
102
  }
103
+ static { this.words = 'helix-popover'; }
102
104
  get slotted() {
103
105
  return (this.renderRoot
104
106
  ?.querySelector('slot:not([name])')
105
107
  ?.assignedElements({ flatten: true }) ?? []);
106
108
  }
107
109
  nameByHeading() {
108
- const asked = this.label !== 'Popover' || this.hasAttribute('aria-labelledby');
110
+ const asked = this.label !== '' || this.hasAttribute('aria-labelledby');
109
111
  const heading = asked ? null : headingIn(this.slotted);
110
112
  this.namedByHeading = reflectElements(this.partNamed('popover'), 'ariaLabelledByElements', heading ? [heading] : [], this.namedByHeading);
111
113
  }
@@ -196,7 +198,7 @@ let HelixHeadlessPopover = class HelixHeadlessPopover extends MixinControllerOpe
196
198
  part="popover"
197
199
  popover="manual"
198
200
  role="dialog"
199
- aria-label=${this.label}
201
+ aria-label=${this.label || this.fallbackLabel}
200
202
  aria-modal=${this.modal ? 'true' : nothing}
201
203
  tabindex="-1"
202
204
  ?hidden=${!this.open}
@@ -214,6 +216,10 @@ let HelixHeadlessPopover = class HelixHeadlessPopover extends MixinControllerOpe
214
216
  __decorate([
215
217
  property({ type: Boolean })
216
218
  ], HelixHeadlessPopover.prototype, "arrow", void 0);
219
+ __decorate([
220
+ words,
221
+ property({ attribute: 'fallback-label' })
222
+ ], HelixHeadlessPopover.prototype, "fallbackLabel", void 0);
217
223
  __decorate([
218
224
  property()
219
225
  ], HelixHeadlessPopover.prototype, "label", void 0);
@@ -43,6 +43,11 @@ import { type PropertyValues, type TemplateResult } from 'lit';
43
43
  * @cssstate complete - The value is at `max` and the bar is not indeterminate.
44
44
  */
45
45
  export declare class HelixHeadlessProgress extends HelixElement {
46
+ /**
47
+ * The key this family's words are registered under, its styled tag:
48
+ * `registerWords('de', { 'helix-progress': { completeLabel: 'Fertig' } })`.
49
+ */
50
+ static words: string;
46
51
  /**
47
52
  * The words a screen reader hears when the value reaches `max`, such as
48
53
  * "Upload complete".
@@ -88,9 +93,9 @@ export declare class HelixHeadlessProgress extends HelixElement {
88
93
  */
89
94
  label: string;
90
95
  /**
91
- * The locale the percentage is written in, such as `fr` for `72 %`.
96
+ * The locale the words and the percentage are in, such as `fr` for `72 %`.
92
97
  *
93
- * Absent uses the runtime's own.
98
+ * Absent reads the nearest `lang`, then the runtime's own.
94
99
  */
95
100
  locale: string;
96
101
  /**
@@ -4,7 +4,7 @@ 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, drawStatus, HelixCompleteEvent, HelixElement, hostAria, readingText, StatusController, slottedWords, } from '@fusion.dev/helix-core';
7
+ import { customElement, drawStatus, HelixCompleteEvent, HelixElement, hostAria, readingText, StatusController, slottedWords, words, wordsLocale, } from '@fusion.dev/helix-core';
8
8
  import { html } from 'lit';
9
9
  import { property } from 'lit/decorators.js';
10
10
  let HelixHeadlessProgress = class HelixHeadlessProgress extends HelixElement {
@@ -24,6 +24,7 @@ let HelixHeadlessProgress = class HelixHeadlessProgress extends HelixElement {
24
24
  this.requestUpdate();
25
25
  };
26
26
  }
27
+ static { this.words = 'helix-progress'; }
27
28
  get complete() {
28
29
  return !this.indeterminate && this.fraction >= 1;
29
30
  }
@@ -66,7 +67,7 @@ let HelixHeadlessProgress = class HelixHeadlessProgress extends HelixElement {
66
67
  }
67
68
  get text() {
68
69
  return (this.valueText ||
69
- readingText(Math.min(Math.max(this.value, this.range.min), this.range.max), this.fraction, this.locale, this.formatOptions));
70
+ readingText(Math.min(Math.max(this.value, this.range.min), this.range.max), this.fraction, wordsLocale(this), this.formatOptions));
70
71
  }
71
72
  render() {
72
73
  const fraction = this.indeterminate ? 1 : this.fraction;
@@ -87,6 +88,7 @@ let HelixHeadlessProgress = class HelixHeadlessProgress extends HelixElement {
87
88
  }
88
89
  };
89
90
  __decorate([
91
+ words,
90
92
  property({ attribute: 'complete-label' })
91
93
  ], HelixHeadlessProgress.prototype, "completeLabel", void 0);
92
94
  __decorate([
@@ -96,6 +98,7 @@ __decorate([
96
98
  property({ reflect: true, type: Boolean })
97
99
  ], HelixHeadlessProgress.prototype, "indeterminate", void 0);
98
100
  __decorate([
101
+ words,
99
102
  property()
100
103
  ], HelixHeadlessProgress.prototype, "label", void 0);
101
104
  __decorate([
@@ -1,6 +1,7 @@
1
1
  /**
2
2
  * The name a code is read by: its `label`, or with none, the word for a code,
3
- * followed by the value where the value is a web address.
3
+ * or where the value is a web address, `addressed` with it, which puts the
4
+ * word and the address in one sentence.
4
5
  *
5
6
  * **A value that is no web address is never read out.** A code that sets up
6
7
  * an authenticator (`otpauth://…?secret=…`) or joins a network
@@ -8,4 +9,4 @@
8
9
  * read that secret aloud to anyone in earshot. A web address is what a
9
10
  * sighted reader gets by scanning, so it is said after the word.
10
11
  */
11
- export declare const qrName: (label: string, value: string, word: string) => string;
12
+ export declare const qrName: (label: string, value: string, word: string, addressed: (address: string) => string) => string;
@@ -1,7 +1,7 @@
1
- export const qrName = (label, value, word) => {
1
+ export const qrName = (label, value, word, addressed) => {
2
2
  if (label.trim() !== '') {
3
3
  return label;
4
4
  }
5
5
  const address = value.trim();
6
- return /^https?:\/\/\S+$/iu.test(address) ? `${word}, ${address}` : word;
6
+ return /^https?:\/\/\S+$/iu.test(address) ? addressed(address) : word;
7
7
  };
@@ -27,7 +27,8 @@ export type QrStyle = 'dots' | 'rounded' | 'square';
27
27
  * `correction` sets how much of the code can be lost. At `H` a code can lose
28
28
  * thirty percent and still scan, so a mark in the center slot is safe. At `L`
29
29
  * the same mark makes the code unscannable. The default is `M`, and `H` when the
30
- * `logo` slot is filled.
30
+ * `logo` slot is filled. A code that holds a logo at a `correction` below `H`
31
+ * warns once with the kind `unscannable-logo`.
31
32
  *
32
33
  * A higher level holds fewer characters, so a value that fits at `M` can be too
33
34
  * long once a logo raises the level to `H`. A value too long for the level
@@ -37,7 +38,8 @@ export type QrStyle = 'dots' | 'rounded' | 'square';
37
38
  * `toSvg()`, `toPng()` and `download()` give the drawn code as a file of its
38
39
  * own, in the colors it is drawn in, with a slotted image or SVG logo where
39
40
  * it sits, for a page that offers it to save or print, as Zag's download
40
- * trigger does.
41
+ * trigger does. `download()` saves an SVG for a name ending in `.svg`, and a
42
+ * PNG for any other.
41
43
  *
42
44
  * @since 0.1.0
43
45
  * @status stable
@@ -60,8 +62,18 @@ export type QrStyle = 'dots' | 'rounded' | 'square';
60
62
  */
61
63
  export declare class HelixHeadlessQrCode extends HelixElement {
62
64
  /**
63
- * The words a code with no `label` is named by, followed by its value where
64
- * the value is a web address.
65
+ * The key this family's words are registered under, its styled tag:
66
+ * `registerWords('de', { 'helix-qr-code': { codeLabel: 'QR-Code' } })`.
67
+ */
68
+ static words: string;
69
+ /**
70
+ * The name of a code with no `label` whose value is a web address.
71
+ * `{code}` is `code-label` and `{address}` the address.
72
+ */
73
+ addressLabel: string;
74
+ /**
75
+ * The words a code with no `label` is named by, with its value where the
76
+ * value is a web address, as `address-label` says.
65
77
  */
66
78
  codeLabel: string;
67
79
  /**
@@ -111,6 +123,14 @@ export declare class HelixHeadlessQrCode extends HelixElement {
111
123
  protected firstUpdated(changed: PropertyValues): void;
112
124
  /** The level actually used, which the slot can raise. */
113
125
  private get level();
126
+ /** Whether this code has warned that its logo may keep it from scanning. */
127
+ private toldLogo;
128
+ /**
129
+ * Warns once when a logo covers a code whose level was set below `H`, where
130
+ * the cover can take more than the level can lose. A level the code chose
131
+ * itself is `H` already.
132
+ */
133
+ private auditLogo;
114
134
  /** The value and level that did not fit, so `error` fires once for each. */
115
135
  private overflowed;
116
136
  /**
@@ -148,7 +168,8 @@ export declare class HelixHeadlessQrCode extends HelixElement {
148
168
  */
149
169
  toPng(size?: number): Promise<Blob | null>;
150
170
  /**
151
- * Saves the code as a PNG named `filename`, `size` pixels square.
171
+ * Saves the code as a file named `filename`, `size` pixels square: an SVG
172
+ * where the name ends in `.svg`, and a PNG otherwise.
152
173
  *
153
174
  * Call it from a press, since a browser lets a page start a download only
154
175
  * in answer to one. Does nothing where no code is drawn.