lintje 0.2.0 → 0.3.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 (276) hide show
  1. package/README.md +2 -2
  2. package/dist-elements/actions.js +1 -1
  3. package/dist-elements/chunks/{base-Bg-IFOPG.js → base-CbmWxUig.js} +444 -272
  4. package/dist-elements/chunks/{controls-B1455oPG.js → controls-DxmnDSBr.js} +6 -0
  5. package/dist-elements/chunks/dialog-DChINFxD.js +28 -0
  6. package/dist-elements/chunks/{disclosure-BXTX04gM.js → disclosure-D39vAR5q.js} +1 -1
  7. package/dist-elements/chunks/{disclosure-CMXhX-Vb.js → disclosure-DLkXPUpV.js} +6 -6
  8. package/dist-elements/chunks/download-Ct9q2anY.js +206 -0
  9. package/dist-elements/chunks/{focus-trap-9BnE-xWv.js → focus-trap-BwOxE5BX.js} +1 -1
  10. package/dist-elements/chunks/input-CRW_exv_.js +195 -0
  11. package/dist-elements/chunks/{player-DXOZEyEy.js → player-B8QXJ0Z5.js} +26 -26
  12. package/dist-elements/chunks/{sentence-BI3lwEuT.js → sentence-B19AyZBS.js} +3 -3
  13. package/dist-elements/chunks/{stagger-qGD3wmhg.js → stagger-BHoOgy0g.js} +81 -75
  14. package/dist-elements/core.js +1 -1
  15. package/dist-elements/custom-elements.json +980 -670
  16. package/dist-elements/data-types.json +6798 -0
  17. package/dist-elements/feedback.js +2 -1
  18. package/dist-elements/frame.js +0 -2
  19. package/dist-elements/guides/dashboard.md +8 -0
  20. package/dist-elements/guides/events.md +4 -5
  21. package/dist-elements/guides/loading.md +8 -7
  22. package/dist-elements/guides/page-contents.md +110 -0
  23. package/dist-elements/guides/start.md +12 -0
  24. package/dist-elements/inputs.js +2 -1
  25. package/dist-elements/layout.js +1 -1
  26. package/dist-elements/lintje.js +6975 -6120
  27. package/dist-elements/overlays.js +2 -2
  28. package/dist-elements/skills/lintje/SKILL.md +1 -1
  29. package/dist-elements/tables.js +1 -1
  30. package/dist-elements/tag/activity-log.js +15 -15
  31. package/dist-elements/tag/ai-label.js +10 -10
  32. package/dist-elements/tag/announcement.js +36 -76
  33. package/dist-elements/tag/app-search.js +49 -49
  34. package/dist-elements/tag/audio-player.js +57 -57
  35. package/dist-elements/tag/badge.js +1 -1
  36. package/dist-elements/tag/breadcrumbs.js +15 -15
  37. package/dist-elements/tag/button.js +1 -1
  38. package/dist-elements/tag/card-list.js +12 -12
  39. package/dist-elements/tag/card.js +39 -44
  40. package/dist-elements/tag/chart.js +1050 -795
  41. package/dist-elements/tag/chat-answer.js +49 -49
  42. package/dist-elements/tag/chat-composer.js +75 -71
  43. package/dist-elements/tag/chat-message.js +8 -8
  44. package/dist-elements/tag/chat-strip.js +22 -22
  45. package/dist-elements/tag/chat-suggestions.js +12 -12
  46. package/dist-elements/tag/chat.js +56 -56
  47. package/dist-elements/tag/checkbox-group.d.ts +1 -0
  48. package/dist-elements/tag/checkbox-group.js +59 -0
  49. package/dist-elements/tag/checkbox.js +8 -8
  50. package/dist-elements/tag/code.js +9 -9
  51. package/dist-elements/tag/combobox.js +18 -18
  52. package/dist-elements/tag/conflict-alert.js +12 -12
  53. package/dist-elements/tag/copy-button.js +14 -14
  54. package/dist-elements/tag/data-table.js +878 -530
  55. package/dist-elements/tag/date-input.js +30 -30
  56. package/dist-elements/tag/date-range.js +37 -37
  57. package/dist-elements/tag/description-list.js +29 -32
  58. package/dist-elements/tag/dialog.d.ts +1 -0
  59. package/dist-elements/tag/dialog.js +144 -0
  60. package/dist-elements/tag/document-viewer.js +23 -23
  61. package/dist-elements/tag/drawer.js +28 -32
  62. package/dist-elements/tag/empty-state.js +19 -30
  63. package/dist-elements/tag/error-page.d.ts +1 -0
  64. package/dist-elements/tag/error-page.js +109 -0
  65. package/dist-elements/tag/error-summary.js +10 -10
  66. package/dist-elements/tag/expander.js +8 -8
  67. package/dist-elements/tag/explainer.js +11 -11
  68. package/dist-elements/tag/field.js +5 -5
  69. package/dist-elements/tag/file-upload.js +34 -34
  70. package/dist-elements/tag/filter-bar.js +56 -56
  71. package/dist-elements/tag/filter-sheet.js +11 -11
  72. package/dist-elements/tag/filter-zone.js +31 -31
  73. package/dist-elements/tag/footer.js +21 -21
  74. package/dist-elements/tag/form-actions.js +29 -25
  75. package/dist-elements/tag/form-section.js +6 -6
  76. package/dist-elements/tag/form.js +12 -12
  77. package/dist-elements/tag/gallery.js +14 -14
  78. package/dist-elements/tag/grid-item.js +1 -1
  79. package/dist-elements/tag/grid.js +1 -1
  80. package/dist-elements/tag/hero.js +12 -12
  81. package/dist-elements/tag/highlight.js +5 -5
  82. package/dist-elements/tag/icon-button.js +1 -1
  83. package/dist-elements/tag/icon.js +1 -1
  84. package/dist-elements/tag/job-list.js +22 -44
  85. package/dist-elements/tag/kpi-row.js +12 -10
  86. package/dist-elements/tag/kpi.js +146 -137
  87. package/dist-elements/tag/level-meter.js +11 -11
  88. package/dist-elements/tag/list.js +55 -55
  89. package/dist-elements/tag/logo.js +30 -30
  90. package/dist-elements/tag/map.js +690 -665
  91. package/dist-elements/tag/menu-button.js +70 -69
  92. package/dist-elements/tag/modal.js +28 -37
  93. package/dist-elements/tag/multiselect.js +34 -34
  94. package/dist-elements/tag/note.js +5 -5
  95. package/dist-elements/tag/notifications.js +36 -36
  96. package/dist-elements/tag/number-input.js +12 -12
  97. package/dist-elements/tag/page-header.js +140 -37
  98. package/dist-elements/tag/pagination.js +53 -48
  99. package/dist-elements/tag/popover.js +1 -1
  100. package/dist-elements/tag/progress-bar.js +1 -1
  101. package/dist-elements/tag/prose.js +6 -6
  102. package/dist-elements/tag/qr-code.js +7 -7
  103. package/dist-elements/tag/radio-group.js +12 -12
  104. package/dist-elements/tag/range.js +22 -22
  105. package/dist-elements/tag/recording-status.js +14 -14
  106. package/dist-elements/tag/repeater.js +10 -10
  107. package/dist-elements/tag/segmented.js +13 -13
  108. package/dist-elements/tag/select.js +10 -10
  109. package/dist-elements/tag/shell.js +356 -339
  110. package/dist-elements/tag/skeleton.js +1 -1
  111. package/dist-elements/tag/slot-picker.js +14 -14
  112. package/dist-elements/tag/sortable-list.js +14 -14
  113. package/dist-elements/tag/spinner.js +1 -1
  114. package/dist-elements/tag/split-pane.js +12 -12
  115. package/dist-elements/tag/status-dot.js +1 -1
  116. package/dist-elements/tag/stepper.js +21 -21
  117. package/dist-elements/tag/streaming-text.js +13 -13
  118. package/dist-elements/tag/sub-nav.js +39 -38
  119. package/dist-elements/tag/tabs.js +38 -38
  120. package/dist-elements/tag/tag-input.js +19 -19
  121. package/dist-elements/tag/text-editor.js +24 -24
  122. package/dist-elements/tag/text-input.js +14 -14
  123. package/dist-elements/tag/textarea.js +14 -14
  124. package/dist-elements/tag/tile.js +1 -1
  125. package/dist-elements/tag/time-input.js +19 -19
  126. package/dist-elements/tag/toast.js +32 -23
  127. package/dist-elements/tag/toggle.js +8 -8
  128. package/dist-elements/tag/toggletip.js +27 -27
  129. package/dist-elements/tag/tooltip.js +1 -1
  130. package/dist-elements/tag/transcript.js +48 -48
  131. package/dist-elements/tag/translator.js +13 -13
  132. package/dist-elements/tag/tree-view.js +13 -13
  133. package/dist-elements/tag/user-menu.js +37 -37
  134. package/dist-elements/tag/video-player.js +21 -21
  135. package/dist-elements/tokens.css +120 -96
  136. package/dist-elements/types/bundle/feedback.d.ts +1 -0
  137. package/dist-elements/types/bundle/frame.d.ts +0 -2
  138. package/dist-elements/types/bundle/inputs.d.ts +1 -0
  139. package/dist-elements/types/bundle/overlays.d.ts +1 -1
  140. package/dist-elements/types/components/actions/copy-button/copy-button.d.ts +6 -7
  141. package/dist-elements/types/components/actions/menu-button/menu-button.d.ts +13 -15
  142. package/dist-elements/types/components/actions/qr-code/qr-code.d.ts +9 -9
  143. package/dist-elements/types/components/charts/chart/chart.d.ts +5 -4
  144. package/dist-elements/types/components/charts/kpi/kpi.d.ts +16 -8
  145. package/dist-elements/types/components/charts/kpi-row/kpi-row.d.ts +1 -7
  146. package/dist-elements/types/components/charts/note/note.d.ts +1 -1
  147. package/dist-elements/types/components/chat/chat/chat.d.ts +8 -10
  148. package/dist-elements/types/components/chat/chat-answer/chat-answer.d.ts +7 -8
  149. package/dist-elements/types/components/chat/chat-composer/chat-composer.d.ts +8 -10
  150. package/dist-elements/types/components/chat/chat-message/chat-message.d.ts +6 -7
  151. package/dist-elements/types/components/chat/chat-strip/chat-strip.d.ts +5 -5
  152. package/dist-elements/types/components/chat/chat-suggestions/chat-suggestions.d.ts +9 -10
  153. package/dist-elements/types/components/content/audio-player/audio-player.d.ts +10 -12
  154. package/dist-elements/types/components/content/code/code.d.ts +2 -3
  155. package/dist-elements/types/components/content/document-viewer/document-viewer.d.ts +8 -9
  156. package/dist-elements/types/components/content/gallery/gallery.d.ts +5 -4
  157. package/dist-elements/types/components/content/highlight/highlight.d.ts +4 -3
  158. package/dist-elements/types/components/content/prose/prose.d.ts +2 -3
  159. package/dist-elements/types/components/content/transcript/transcript.d.ts +12 -25
  160. package/dist-elements/types/components/content/translator/translator.d.ts +11 -15
  161. package/dist-elements/types/components/content/video-player/video-player.d.ts +11 -13
  162. package/dist-elements/types/components/feedback/ai-label/ai-label.d.ts +3 -4
  163. package/dist-elements/types/components/feedback/announcement/announcement.d.ts +3 -7
  164. package/dist-elements/types/components/feedback/conflict-alert/conflict-alert.d.ts +3 -4
  165. package/dist-elements/types/components/feedback/empty-state/empty-state.d.ts +5 -8
  166. package/dist-elements/types/components/feedback/error-page/error-page.d.ts +52 -0
  167. package/dist-elements/types/components/feedback/job-list/job-list.d.ts +9 -12
  168. package/dist-elements/types/components/feedback/level-meter/level-meter.d.ts +4 -6
  169. package/dist-elements/types/components/feedback/recording-status/recording-status.d.ts +5 -6
  170. package/dist-elements/types/components/feedback/streaming-text/streaming-text.d.ts +10 -7
  171. package/dist-elements/types/components/feedback/toast/toast.d.ts +8 -9
  172. package/dist-elements/types/components/filters/filter-bar/filter-bar.d.ts +9 -4
  173. package/dist-elements/types/components/filters/filter-sheet/filter-sheet.d.ts +5 -5
  174. package/dist-elements/types/components/filters/filter-zone/filter-zone.d.ts +4 -4
  175. package/dist-elements/types/components/forms/error-summary/error-summary.d.ts +5 -6
  176. package/dist-elements/types/components/forms/form/form.d.ts +5 -5
  177. package/dist-elements/types/components/forms/form-actions/form-actions.d.ts +9 -7
  178. package/dist-elements/types/components/forms/form-section/form-section.d.ts +6 -5
  179. package/dist-elements/types/components/forms/repeater/repeater.d.ts +13 -7
  180. package/dist-elements/types/components/forms/stepper/stepper.d.ts +5 -4
  181. package/dist-elements/types/components/frame/app-search/app-search.d.ts +6 -7
  182. package/dist-elements/types/components/frame/breadcrumbs/breadcrumbs.d.ts +2 -2
  183. package/dist-elements/types/components/frame/footer/footer.d.ts +3 -2
  184. package/dist-elements/types/components/frame/hero/hero.d.ts +7 -9
  185. package/dist-elements/types/components/frame/notifications/notifications.d.ts +5 -9
  186. package/dist-elements/types/components/frame/page-header/page-header.d.ts +12 -15
  187. package/dist-elements/types/components/frame/shell/shell.d.ts +14 -13
  188. package/dist-elements/types/components/frame/sub-nav/sub-nav.d.ts +10 -6
  189. package/dist-elements/types/components/frame/user-menu/user-menu.d.ts +11 -10
  190. package/dist-elements/types/components/index.d.ts +8 -9
  191. package/dist-elements/types/components/inputs/checkbox/checkbox.d.ts +4 -4
  192. package/dist-elements/types/components/inputs/checkbox-group/checkbox-group.d.ts +33 -0
  193. package/dist-elements/types/components/inputs/combobox/combobox.d.ts +12 -6
  194. package/dist-elements/types/components/inputs/date-input/date-input.d.ts +5 -5
  195. package/dist-elements/types/components/inputs/date-range/date-range.d.ts +11 -6
  196. package/dist-elements/types/components/inputs/field/field.d.ts +5 -3
  197. package/dist-elements/types/components/inputs/file-upload/file-upload.d.ts +6 -8
  198. package/dist-elements/types/components/inputs/multiselect/multiselect.d.ts +4 -6
  199. package/dist-elements/types/components/inputs/number-input/number-input.d.ts +8 -7
  200. package/dist-elements/types/components/inputs/radio-group/radio-group.d.ts +2 -4
  201. package/dist-elements/types/components/inputs/range/range.d.ts +5 -6
  202. package/dist-elements/types/components/inputs/segmented/segmented.d.ts +7 -4
  203. package/dist-elements/types/components/inputs/select/select.d.ts +6 -3
  204. package/dist-elements/types/components/inputs/slot-picker/slot-picker.d.ts +6 -5
  205. package/dist-elements/types/components/inputs/tag-input/tag-input.d.ts +7 -5
  206. package/dist-elements/types/components/inputs/text-editor/text-editor.d.ts +6 -6
  207. package/dist-elements/types/components/inputs/text-input/text-input.d.ts +11 -6
  208. package/dist-elements/types/components/inputs/textarea/textarea.d.ts +12 -11
  209. package/dist-elements/types/components/inputs/time-input/time-input.d.ts +7 -8
  210. package/dist-elements/types/components/inputs/toggle/toggle.d.ts +3 -1
  211. package/dist-elements/types/components/layout/expander/expander.d.ts +9 -10
  212. package/dist-elements/types/components/layout/split-pane/split-pane.d.ts +6 -6
  213. package/dist-elements/types/components/layout/tabs/tabs.d.ts +11 -9
  214. package/dist-elements/types/components/map/map/map.d.ts +10 -9
  215. package/dist-elements/types/components/overlays/dialog/dialog.d.ts +49 -0
  216. package/dist-elements/types/components/overlays/drawer/drawer.d.ts +6 -5
  217. package/dist-elements/types/components/overlays/modal/modal.d.ts +7 -12
  218. package/dist-elements/types/components/overlays/toggletip/toggletip.d.ts +3 -7
  219. package/dist-elements/types/components/shared/charts/index.d.ts +4 -1
  220. package/dist-elements/types/components/shared/charts/kinds.d.ts +86 -0
  221. package/dist-elements/types/components/shared/charts/line-chart/line-chart.d.ts +2 -2
  222. package/dist-elements/types/components/shared/charts/map-chart/leaflet.d.ts +5 -0
  223. package/dist-elements/types/components/shared/charts/shared/chart-states.d.ts +8 -19
  224. package/dist-elements/types/components/shared/charts/shared/controller.d.ts +7 -0
  225. package/dist-elements/types/components/shared/charts/shared/types.d.ts +29 -0
  226. package/dist-elements/types/components/shared/charts/stacked-area-chart/stacked-area-chart.d.ts +13 -0
  227. package/dist-elements/types/components/shared/dialog.d.ts +9 -0
  228. package/dist-elements/types/components/shared/overflow.d.ts +58 -0
  229. package/dist-elements/types/components/tables/activity-log/activity-log.d.ts +2 -3
  230. package/dist-elements/types/components/tables/card/card.d.ts +14 -20
  231. package/dist-elements/types/components/tables/card-list/card-list.d.ts +9 -11
  232. package/dist-elements/types/components/tables/data-table/data-table.d.ts +85 -16
  233. package/dist-elements/types/components/tables/data-table/filters.d.ts +13 -4
  234. package/dist-elements/types/components/tables/description-list/description-list.d.ts +12 -11
  235. package/dist-elements/types/components/tables/list/list.d.ts +9 -20
  236. package/dist-elements/types/components/tables/pagination/pagination.d.ts +12 -11
  237. package/dist-elements/types/components/tables/sortable-list/sortable-list.d.ts +5 -6
  238. package/dist-elements/types/components/tables/tree-view/tree-view.d.ts +4 -4
  239. package/dist-elements/types/core/media.d.ts +2 -2
  240. package/dist-elements/types/core/motion.d.ts +5 -0
  241. package/dist-elements/types/core/print.d.ts +15 -0
  242. package/dist-elements/types/core/shortcuts.d.ts +2 -2
  243. package/dist-elements/types/icons/icon/icon.d.ts +2 -3
  244. package/dist-elements/types/icons/register.d.ts +1 -1
  245. package/dist-elements/types/primitives/badge/badge.d.ts +9 -5
  246. package/dist-elements/types/primitives/button/button.d.ts +12 -9
  247. package/dist-elements/types/primitives/grid/grid.d.ts +3 -3
  248. package/dist-elements/types/primitives/grid-item/grid-item.d.ts +1 -1
  249. package/dist-elements/types/primitives/icon-button/icon-button.d.ts +7 -5
  250. package/dist-elements/types/primitives/index.d.ts +3 -1
  251. package/dist-elements/types/primitives/popover/popover.d.ts +5 -4
  252. package/dist-elements/types/primitives/progress-bar/progress-bar.d.ts +8 -6
  253. package/dist-elements/types/primitives/shared/announcement-block.d.ts +38 -0
  254. package/dist-elements/types/primitives/shared/empty-state-block.d.ts +26 -0
  255. package/dist-elements/types/primitives/shared/tone.d.ts +18 -0
  256. package/dist-elements/types/primitives/skeleton/skeleton.d.ts +1 -1
  257. package/dist-elements/types/primitives/spinner/spinner.d.ts +1 -2
  258. package/dist-elements/types/primitives/status-dot/status-dot.d.ts +4 -5
  259. package/dist-elements/types/primitives/tile/tile.d.ts +17 -5
  260. package/dist-elements/types/primitives/tooltip/tooltip.d.ts +6 -6
  261. package/dist-elements/types/types.d.ts +70 -10
  262. package/dist-icons/functioneel-kolommen.svg +1 -0
  263. package/dist-icons/functioneel-trechter.svg +1 -0
  264. package/package.json +1 -1
  265. package/dist-elements/chunks/confirm-dialog-D5EVGuil.js +0 -4
  266. package/dist-elements/chunks/download-y528pIHP.js +0 -230
  267. package/dist-elements/chunks/input-BtuNFSWk.js +0 -195
  268. package/dist-elements/tag/confirm-dialog.d.ts +0 -1
  269. package/dist-elements/tag/confirm-dialog.js +0 -118
  270. package/dist-elements/tag/session-expiry.d.ts +0 -1
  271. package/dist-elements/tag/session-expiry.js +0 -184
  272. package/dist-elements/tag/shortcuts.d.ts +0 -1
  273. package/dist-elements/tag/shortcuts.js +0 -104
  274. package/dist-elements/types/components/frame/session-expiry/session-expiry.d.ts +0 -55
  275. package/dist-elements/types/components/frame/shortcuts/shortcuts.d.ts +0 -41
  276. package/dist-elements/types/components/overlays/confirm-dialog/confirm-dialog.d.ts +0 -41
@@ -1,15 +1,13 @@
1
1
  /**
2
- * `<lintje-textarea>` — the multi-line text field: three to twelve lines (`rows` sets the least),
3
- * with a counter when there is a `maxlength`. `variant="plain"` drops the field's box and its
4
- * focus ring, takes the type of where it stands and fills its height, for a surface that frames
5
- * the text and draws the ring itself (`lintje-translator`). Typing past the limit is allowed (a paste lands whole); the field
6
- * shows the error, alerted once as the text crosses the limit. The counter is read out from 90 %
7
- * of the limit on.
2
+ * `<lintje-textarea>` — the multi-line text field: three to twelve lines, with a counter when
3
+ * there is a `maxlength`.
8
4
  *
9
- * The counter is `part="counter"`, so a surface can stand it on its own line.
5
+ * It commits like `lintje-text-input`; Ctrl+Enter commits and submits a host's form. Typing past
6
+ * the limit is allowed, so a paste lands whole: the field shows the error. The counter is
7
+ * `part="counter"`, so a surface can stand it on its own line.
10
8
  *
11
- * Commits like `lintje-text-input`; Ctrl+Enter commits and submits a host's form.
12
- * Events: `lintje-change`, and `lintje-values-change` with a `name`.
9
+ * Events: `lintje-change` `string`, `lintje-values-change` `{ [name]: value }` (with a `name`),
10
+ * `lintje-reset` (the reset link was pressed).
13
11
  */
14
12
  import { nothing, type PropertyDeclarations, type PropertyValues, type TemplateResult } from 'lit';
15
13
  import { LintjeFormInputElement } from '../shared/input.js';
@@ -24,14 +22,17 @@ export declare class LintjeTextarea extends LintjeFormInputElement {
24
22
  static properties: PropertyDeclarations;
25
23
  value: string;
26
24
  placeholder: string;
27
- /** The limit the counter counts to. */
25
+ /** The limit the counter counts to; the counter is read out from 90 % of it on. */
28
26
  maxlength?: number;
29
27
  /** The attribute `commit`; `commit()` is the method every input commits through. */
30
28
  commitOn: CommitOn;
31
29
  stacked: boolean;
32
30
  /** The least number of lines the field shows. */
33
31
  rows: number;
34
- /** `field` (default): the bordered field; `plain`: no box, the type of where it stands. */
32
+ /**
33
+ * `field` (default): the bordered field. `plain`: no box and no focus ring, the type of where it
34
+ * stands and the full height, for a surface that frames the text and draws the ring itself.
35
+ */
35
36
  variant: TextareaVariant;
36
37
  private readonly typing;
37
38
  private get counterId();
@@ -1,13 +1,12 @@
1
1
  /**
2
- * `<lintje-time-input>` — a time of day, `HH:MM` on a 24-hour clock, or `null` when empty, typed
3
- * or picked from a list. Typed text is read on leaving the field or Enter (`time-format.ts`).
4
- * The list holds the times from `min` to `max`, `step` minutes apart; a typed value between two
5
- * of them stays as typed, and the list opens on the first time at or after it without selecting
6
- * one. The element checks its own text and shows a message in place of the hint; a host's
7
- * `error` wins. It knows no day or time zone. Tab out of the element closes the list, so it does
8
- * not cover the next field.
2
+ * `<lintje-time-input>` — a time of day, `HH:MM` on a 24-hour clock, typed or picked from a list.
9
3
  *
10
- * Events: `lintje-change` with `HH:MM` or `null`; with a `name` also `lintje-values-change`.
4
+ * The element reads typed text on leaving the field or Enter, checks it and shows a message in
5
+ * place of the hint; a host's `error` wins. A typed time between two in the list stays as typed.
6
+ * It knows no day or time zone. Tab out of the element closes the list.
7
+ *
8
+ * Events: `lintje-change` `string | null` (`HH:MM`), `lintje-values-change` `{ [name]: value }`
9
+ * (with a `name`), `lintje-reset` (the reset link was pressed).
11
10
  */
12
11
  import { type PropertyDeclarations, type PropertyValues, type TemplateResult } from 'lit';
13
12
  import { LintjeInputElement } from '../shared/input.js';
@@ -1,8 +1,10 @@
1
1
  /**
2
2
  * `<lintje-toggle>` — a switch for immediate effect: it commits when switched, never in a form.
3
+ *
3
4
  * A value that waits for a button is a checkbox.
4
5
  *
5
- * Events: `lintje-change`; with a `name` also the composed `lintje-values-change`.
6
+ * Events: `lintje-change` `boolean`, `lintje-values-change` `{ [name]: value }` (with a `name`),
7
+ * `lintje-reset` (the reset link was pressed).
6
8
  */
7
9
  import { type PropertyDeclarations, type TemplateResult } from 'lit';
8
10
  import { LintjeInputElement } from '../shared/input.js';
@@ -1,15 +1,11 @@
1
1
  /**
2
2
  * `<lintje-expander>` — a title you press; what is slotted under it shows or hides.
3
3
  *
4
- * Shares its disclosure (`shared/disclosure.ts`) with `lintje-explainer` (rule 2). Closed, the
5
- * content stays in the DOM, out of the tab order and the accessibility tree. What is slotted in
6
- * `actions` stands beside the title, outside its button: a few icon buttons about the content.
7
- * `leading` puts the chevron before the title and the content in line with the title's text, for
8
- * a stack of expanders that read as rows. `columns` sets the title in a column of its own
9
- * (`--lintje-expander-label`) with the content beside it, as rows of text do beside their speaker;
10
- * a narrow expander stacks them again.
4
+ * Closed, the content stays in the DOM, out of the tab order and the accessibility tree. What is
5
+ * slotted in `actions` stands beside the title, outside its button: a few icon buttons about the
6
+ * content.
11
7
  *
12
- * Events: `lintje-toggle` (open, after the reader pressed the title).
8
+ * Events: `lintje-toggle` `boolean` (open, after the reader pressed the title).
13
9
  */
14
10
  import { type PropertyDeclarations, type PropertyValues, type TemplateResult } from 'lit';
15
11
  import { LintjeGridItemElement } from '../../../primitives/shared/grid-item-element.js';
@@ -24,9 +20,12 @@ export declare class LintjeExpander extends LintjeGridItemElement {
24
20
  open: boolean;
25
21
  /** No surface of its own: an expander inside a tile is not a second card. */
26
22
  flat: boolean;
27
- /** The chevron before the title, the content under the title's text. */
23
+ /** The chevron before the title, the content under the title's text: expanders read as rows. */
28
24
  leading: boolean;
29
- /** The title in a column of its own, the content beside it. */
25
+ /**
26
+ * The title in a column of its own (`--lintje-expander-label`), the content beside it, as rows
27
+ * of text beside their speaker; a narrow expander stacks them again.
28
+ */
30
29
  columns: boolean;
31
30
  protected updated(changed: PropertyValues<this>): void;
32
31
  protected render(): TemplateResult;
@@ -1,13 +1,12 @@
1
1
  /**
2
2
  * `<lintje-split-pane>` — two panels side by side with a split the reader moves.
3
3
  *
4
- * Without dragging (WCAG 2.5.7): a click on the strip lifts the split, and the next click places
5
- * it where it lands; Escape or a click outside puts it back. A double click returns to 50/50.
4
+ * It moves without dragging too: a click on the strip lifts the split and the next click places
5
+ * it; Escape or a click outside puts it back, a double click returns to 50/50. Below 768 px there
6
+ * are never two panels: a segmented control chooses which one shows.
6
7
  *
7
- * Below 768 px there are never two panels: a `<lintje-segmented>` chooses which one shows. That
8
- * choice is `pane`; a host that keeps it in the URL sets `pane` back.
9
- *
10
- * Events: `lintje-split-change` (the percentage), `lintje-pane-change` (`'start'` | `'end'`).
8
+ * Events: `lintje-split-change` `number` (the percentage), `lintje-pane-change`
9
+ * `'start' | 'end'`.
11
10
  */
12
11
  import { type PropertyDeclarations, type PropertyValues, type TemplateResult } from 'lit';
13
12
  import { LintjeElement } from '../../../core/element.js';
@@ -31,6 +30,7 @@ export declare class LintjeSplitPane extends LintjeElement {
31
30
  /** The two panels' names, for the phone's choice. */
32
31
  startLabel: string;
33
32
  endLabel: string;
33
+ /** The panel shown below 768 px; a host that keeps it in the URL sets it back. */
34
34
  pane: SplitPaneSide;
35
35
  protected dragging: boolean;
36
36
  protected willUpdate(changed: PropertyValues<this>): void;
@@ -1,13 +1,12 @@
1
1
  /**
2
- * `<lintje-tabs>` — switches between panels slotted under each tab's `value`. The host holds
3
- * `value`; the tabs only ask. A modified click on a link tab is the browser's.
4
- * The row is one tab stop: arrows choose at once, and a disabled tab is reached but not chosen.
5
- * `variant="panel"` draws large tabs that head a panel: each with an icon and a hint, the chosen
6
- * one running into the panel below; on a phone the icon stands above the label and the hint goes.
7
- * When every tab is a link, the row is a `<nav>` of links, the chosen one `aria-current="page"`,
8
- * with the same look: pages are no tabs, and the content under it is the page's, not a tabpanel.
2
+ * `<lintje-tabs>` — switches between panels slotted under each tab's `value`.
9
3
  *
10
- * Events: `lintje-tab-change` (the value), `lintje-navigate` `{ href }` for a tab with an `href`.
4
+ * The host holds `value`: the tabs only ask. The row is one tab stop; arrows choose at once. When
5
+ * every tab is a link, the row is a `<nav>` of links with the same look, and the content under it
6
+ * is the page's, not a tab panel.
7
+ *
8
+ * Events: `lintje-tab-change` `string` (the value), `lintje-navigate` `{ href }` (a tab with an
9
+ * `href`).
11
10
  */
12
11
  import { type PropertyDeclarations, type PropertyValues, type TemplateResult } from 'lit';
13
12
  import { LintjeElement } from '../../../core/element.js';
@@ -40,7 +39,10 @@ export declare class LintjeTabs extends LintjeElement {
40
39
  /** The chosen tab's value; the first tab when unset. */
41
40
  value?: string;
42
41
  label: string;
43
- /** `line` (default): a row over the content; `panel`: large tabs that head a bordered panel. */
42
+ /**
43
+ * `line` (default): a row over the content. `panel`: large tabs that head a bordered panel, each
44
+ * with an icon and a hint; on a phone the icon stands above the label and the hint goes.
45
+ */
44
46
  variant: TabsVariant;
45
47
  protected edges: {
46
48
  start: boolean;
@@ -1,15 +1,14 @@
1
1
  /**
2
- * `<lintje-map>` — a map in its tile. The map shows a new layer at once and expects the host
3
- * to confirm it in the next `data`. `tile.expandable` shows the same map again in the modal; the
4
- * modal's own events stop here.
2
+ * `<lintje-map>` — a map in its tile.
5
3
  *
6
- * Events: `lintje-mark-select` `{id, label, href?}` (`href` is the one the server minted on that
7
- * mark) and `lintje-layer-change` (the chosen layer's `value`). Undoing a selection is
8
- * `lintje-mark-select` with `id: null` and `data.clearHref`, so a page that keeps the selection
9
- * in the URL can drop it. With `data.controls.lasso`, `.circle` or `.rect` a drawn area chooses
10
- * every mark in it — two or more tools share one button that opens their menu:
11
- * `lintje-area-select` `{area, ids}`, and `{area: null, ids: []}` when it is undone; the host
4
+ * A new layer shows at once and expects the host to confirm it in the next `data`. With
5
+ * `tile.expandable` the same map shows again in the modal, whose own events stop here. With
6
+ * `data.controls.lasso`, `.circle` or `.rect` a drawn area chooses every mark in it; the host
12
7
  * keeps the area in its URL and sends it back as `selectedArea`.
8
+ *
9
+ * Events: `lintje-mark-select` `{ id, label, href? }` (deselected, `id: null` and
10
+ * `href: data.clearHref`), `lintje-layer-change` `string` (the chosen layer's value),
11
+ * `lintje-area-select` `{ area, ids }` (undone, `{ area: null, ids: [] }`).
13
12
  */
14
13
  import { nothing, type PropertyDeclarations, type PropertyValues, type TemplateResult } from 'lit';
15
14
  import { type FrameSettings } from '../../../core/element.js';
@@ -26,12 +25,14 @@ export declare class LintjeMap extends LintjeContentTileElement {
26
25
  /** The chosen layer, shown before the host confirms it. */
27
26
  layer?: string;
28
27
  protected get dataSettings(): FrameSettings | undefined;
28
+ connectedCallback(): void;
29
29
  disconnectedCallback(): void;
30
30
  protected expandChanged(open: boolean): void;
31
31
  protected willUpdate(changed: PropertyValues<this>): void;
32
32
  private png;
33
33
  private csv;
34
34
  protected render(): TemplateResult | typeof nothing;
35
+ /** The map, or its skeleton for the tile's `loading` slot; empty and error are the tile's. */
35
36
  private content;
36
37
  /** Refocuses the chosen mark so clearing does not drop a keyboard user at the top; the map area
37
38
  * takes the focus when the mark is gone after a redraw. */
@@ -0,0 +1,49 @@
1
+ /**
2
+ * `<lintje-dialog>` — the small window: a question that needs an answer, or a short form. The
3
+ * large window for content is `<lintje-modal>`.
4
+ *
5
+ * The host holds `open` and puts its own buttons in `actions`: Escape, the close button and the
6
+ * scrim only ask. Focus goes to the slotted element with `autofocus`, else the first field; an
7
+ * alert without one takes it itself, so Enter never confirms. Below 768 px the buttons stack
8
+ * with the last on top: put the safe one first.
9
+ *
10
+ * Events: `lintje-close` `{ reason: 'escape' | 'scrim' | 'button' }`.
11
+ */
12
+ import { nothing, type PropertyDeclarations, type PropertyValues, type TemplateResult } from 'lit';
13
+ import { LintjeElement } from '../../../core/element.js';
14
+ export type DialogCloseReason = 'escape' | 'scrim' | 'button';
15
+ export declare class LintjeDialog extends LintjeElement {
16
+ #private;
17
+ static styles: import("lit").CSSResult[];
18
+ static properties: PropertyDeclarations;
19
+ /** The owner's: the dialog asks to be closed and never closes itself. */
20
+ open: boolean;
21
+ /** The question or the task, and the dialog's accessible name. */
22
+ heading: string;
23
+ /** A question that needs an answer: an `alertdialog`, without a close button. */
24
+ alert: boolean;
25
+ /** Escape and the scrim ask nothing, for a question that must be answered. */
26
+ persistent: boolean;
27
+ /** As wide as a short form reads, instead of a question. */
28
+ wide: boolean;
29
+ /**
30
+ * The answer is under way: nothing asks to close, the last primary or danger button in
31
+ * `actions` turns busy and the others disabled.
32
+ */
33
+ busy: boolean;
34
+ protected footerSlotted: boolean;
35
+ private ask;
36
+ private get frame();
37
+ private get buttons();
38
+ /** Read once on opening, before the slots exist to report; `slotchange` keeps it current. */
39
+ protected willUpdate(changed: PropertyValues<this>): void;
40
+ disconnectedCallback(): void;
41
+ protected updated(changed: PropertyValues<this>): void;
42
+ private onSlotChange;
43
+ protected render(): TemplateResult | typeof nothing;
44
+ }
45
+ declare global {
46
+ interface HTMLElementTagNameMap {
47
+ 'lintje-dialog': LintjeDialog;
48
+ }
49
+ }
@@ -1,10 +1,8 @@
1
1
  /**
2
2
  * `<lintje-drawer>` — a side panel over the page, for a detail or a short form.
3
3
  *
4
- * The host holds `open`: Escape, the close button and the scrim only ask. Whether unsaved input
5
- * needs confirming first is the host's call. While `busy` none of them asks. The footer slot is
6
- * hidden when empty. A dialog on the shared focus-trap stack; focus goes to the first field,
7
- * else the close button.
4
+ * The host holds `open`: Escape, the close button and the scrim only ask. While `busy` none
5
+ * of them asks. Focus goes to the first field, else the close button.
8
6
  *
9
7
  * Events: `lintje-close` `{ reason: 'escape' | 'button' | 'scrim' }`.
10
8
  */
@@ -15,7 +13,10 @@ export declare class LintjeDrawer extends LintjeElement {
15
13
  #private;
16
14
  static styles: import("lit").CSSResult[];
17
15
  static properties: PropertyDeclarations;
18
- /** The host's: the drawer only asks to be closed. */
16
+ /**
17
+ * The host's: the drawer only asks to be closed. Whether unsaved input needs confirming first
18
+ * is the host's call.
19
+ */
19
20
  open: boolean;
20
21
  /** The title and the dialog's accessible name; without it the dialog is "Zijpaneel". */
21
22
  heading: string;
@@ -1,14 +1,11 @@
1
1
  /**
2
- * `<lintje-modal>` — the expand modal: title, subtitle, slotted content, a footer.
2
+ * `<lintje-modal>` — the large window for content: a title, the content and a footer. A question
3
+ * or a short form goes in the small `<lintje-dialog>`.
3
4
  *
4
- * It is `position: fixed` above the app frame, so no ancestor may carry a `transform`, `filter`
5
- * or `contain`. The footer is hidden, not unrendered, when empty: an unrendered slot never
6
- * reports its content again.
5
+ * The host holds `open`: Escape, the close button and the scrim only ask. It is `position: fixed`
6
+ * above the app frame, so no ancestor may carry a `transform`, `filter` or `contain`.
7
7
  *
8
- * `narrow` makes it a dialog with a form: as high as its content and as wide as a form reads,
9
- * with a sentence in `footer` on the left and its buttons in `actions` on the right.
10
- *
11
- * Events: `lintje-close` (the host owns `open`), `lintje-download-csv`, `lintje-download-png`.
8
+ * Events: `lintje-close`, `lintje-download-csv`, `lintje-download-png`.
12
9
  */
13
10
  import { nothing, type PropertyDeclarations, type TemplateResult } from 'lit';
14
11
  import { LintjeElement } from '../../../core/element.js';
@@ -20,14 +17,12 @@ export declare class LintjeModal extends LintjeElement {
20
17
  static properties: PropertyDeclarations;
21
18
  /** The host owns it; `lintje-close` asks for `false`. */
22
19
  open: boolean;
23
- /** The dialog's accessible name and its title line. */
20
+ /** The dialog's accessible name and its title line; without it the dialog is "Venster". */
24
21
  heading: string;
25
22
  subtitle?: string;
26
- /** The footer's CSV and PNG buttons. Default `true`: bind as a property, `.csv=${false}`. */
23
+ /** The footer's CSV and PNG buttons, for content that can be downloaded. */
27
24
  csv: boolean;
28
25
  png: boolean;
29
- /** A dialog with a form: its content's height, a form's width. */
30
- narrow: boolean;
31
26
  footerSlotted: boolean;
32
27
  actionsSlotted: boolean;
33
28
  private onActionsSlotChange;
@@ -1,14 +1,10 @@
1
1
  /**
2
2
  * `<lintje-toggletip>` — a small "i" button that shows a short explanation on a click.
3
3
  *
4
- * The trigger is a real `<button>` in this root, not a nested `<lintje-icon-button>`, because
5
- * `aria-controls` cannot point across a shadow boundary. The explanation is a `role="status"`
6
- * region that is always rendered, empty and `.visually-hidden` while closed: filling a region
7
- * that already exists is what a screen reader announces. Escape is taken in the capture phase
8
- * and stopped, so a modal or sheet around it stays open. The popover is fixed to the viewport
9
- * and placed by `place()`, so a scrolling tile cannot cut it off.
4
+ * Escape closes it and stops there, so a modal or sheet around it stays open. The explanation is
5
+ * fixed to the viewport, so a scrolling tile cannot cut it off.
10
6
  *
11
- * Events: `lintje-toggle` (composed, bubbling), detail `{ open }`.
7
+ * Events: `lintje-toggle` `{ open }`.
12
8
  */
13
9
  import { type PropertyDeclarations, type PropertyValues, type TemplateResult } from 'lit';
14
10
  import { LintjeElement } from '../../../core/element.js';
@@ -3,12 +3,15 @@
3
3
  * `renderMap` a map. See README.md for the contract.
4
4
  */
5
5
  export { renderChart } from './shared/render-chart.js';
6
+ export { CHART_KINDS, CHART_QUESTIONS } from './kinds.js';
7
+ export type { ChartKindGuide, ChartQuestion } from './kinds.js';
6
8
  export { renderLineChart } from './line-chart/line-chart.js';
7
9
  export { renderBarChart, TINTS } from './bar-chart/bar-chart.js';
8
10
  export { renderHorizontalBarChart, rowsHeight } from './horizontal-bar-chart/horizontal-bar-chart.js';
9
11
  export { renderTargetProgressChart } from './target-progress-chart/target-progress-chart.js';
10
12
  export { renderGroupedBarChart } from './grouped-bar-chart/grouped-bar-chart.js';
11
13
  export { renderStackedBarChart } from './stacked-bar-chart/stacked-bar-chart.js';
14
+ export { renderStackedAreaChart } from './stacked-area-chart/stacked-area-chart.js';
12
15
  export { renderPieChart } from './pie-chart/pie-chart.js';
13
16
  export { renderDualAxisChart } from './dual-axis-chart/dual-axis-chart.js';
14
17
  export { renderScatterChart } from './scatter-chart/scatter-chart.js';
@@ -20,7 +23,7 @@ export type { MapOptions } from './map-chart/map-chart.js';
20
23
  export { renderChartFrame, renderLegend, renderAsOfMarker } from './shared/axes.js';
21
24
  export type { ChartFrameOptions, LegendItem, SvgSlot } from './shared/axes.js';
22
25
  export { renderTooltip } from './shared/tooltip.js';
23
- export { renderChartSkeleton, renderChartEmpty, renderChartError, liveAnnouncement, } from './shared/chart-states.js';
26
+ export { renderChartSkeleton } from './shared/chart-states.js';
24
27
  export type { ChartSkeletonKind } from './shared/chart-states.js';
25
28
  export { ChartController, chartArea } from './shared/controller.js';
26
29
  export type { ChartOptions, MeasureSpec, TooltipContent, TooltipRow, TooltipState, } from './shared/controller.js';
@@ -0,0 +1,86 @@
1
+ export type ChartQuestion = 'time' | 'compare' | 'parts' | 'spread' | 'relation' | 'target';
2
+ /** The questions in the order a page asks them, as a reader would put them. */
3
+ export declare const CHART_QUESTIONS: Readonly<Record<ChartQuestion, string>>;
4
+ export interface ChartKindGuide {
5
+ /** The kind's Dutch name. */
6
+ label: string;
7
+ question: ChartQuestion;
8
+ /** What the kind is for. */
9
+ use: string;
10
+ /** When another kind fits better, and which. */
11
+ avoid: string;
12
+ }
13
+ export declare const CHART_KINDS: {
14
+ readonly line: {
15
+ readonly label: 'Lijn';
16
+ readonly question: 'time';
17
+ readonly use: 'Het verloop van een of meer reeksen over de tijd, met een vergelijking in grijs, een peilmoment of wat er gebeurde.';
18
+ readonly avoid: 'Een paar losse groepen zonder volgorde: neem staven.';
19
+ };
20
+ readonly 'stacked-area': {
21
+ readonly label: 'Gestapeld vlak';
22
+ readonly question: 'time';
23
+ readonly use: 'Hoe de delen van één variabele samen het totaal vormen, door de tijd.';
24
+ readonly avoid: 'Delen die je los wilt volgen: alleen de onderste laag staat op de nullijn. Neem lijnen.';
25
+ };
26
+ readonly 'dual-axis': {
27
+ readonly label: 'Twee assen';
28
+ readonly question: 'time';
29
+ readonly use: 'Twee maten met een andere eenheid over dezelfde periode, zoals aantallen en een wachttijd met norm.';
30
+ readonly avoid: 'Twee maten in dezelfde eenheid: neem een lijn met twee reeksen. Waar de lijnen elkaar kruisen, kiest de schaal, niet de data.';
31
+ };
32
+ readonly bar: {
33
+ readonly label: 'Staven';
34
+ readonly question: 'compare';
35
+ readonly use: 'Eén waarde per groep of per periode, als de losse waarden tellen, met datalabels of een trendlijn.';
36
+ readonly avoid: 'Lange namen of veel groepen: neem horizontale staven.';
37
+ };
38
+ readonly 'horizontal-bar': {
39
+ readonly label: 'Horizontale staven';
40
+ readonly question: 'compare';
41
+ readonly use: 'Groepen met lange namen, op grootte, met een norm die laat zien wie erboven zit.';
42
+ readonly avoid: 'Een verloop in de tijd: tijd loopt van links naar rechts. Neem staven of een lijn.';
43
+ };
44
+ readonly 'grouped-bar': {
45
+ readonly label: 'Gegroepeerde staven';
46
+ readonly question: 'compare';
47
+ readonly use: 'Twee of drie reeksen naast elkaar per groep, om ze binnen de groep te vergelijken.';
48
+ readonly avoid: 'Meer dan drie reeksen: de groepen worden onleesbaar. Neem een lijn of een tabel.';
49
+ };
50
+ readonly 'stacked-bar': {
51
+ readonly label: 'Gestapelde staven';
52
+ readonly question: 'parts';
53
+ readonly use: 'De samenstelling per groep of per periode, in aantallen of op 100 %.';
54
+ readonly avoid: 'Eén geheel op één moment: neem een taart. Een deel boven de onderste laag precies vergelijken: neem gegroepeerde staven.';
55
+ };
56
+ readonly pie: {
57
+ readonly label: 'Taart of donut';
58
+ readonly question: 'parts';
59
+ readonly use: 'De delen van één geheel op één moment, tot vijf; meer vouwt tot "Overig". Een donut toont ook het deel van een geheel, met het cijfer in het midden.';
60
+ readonly avoid: 'Een verloop in de tijd, of delen die bijna even groot zijn: neem gestapelde staven.';
61
+ };
62
+ readonly histogram: {
63
+ readonly label: 'Histogram';
64
+ readonly question: 'spread';
65
+ readonly use: 'Hoe waarden over klassen vallen, zoals doorlooptijden, met een mediaan of een termijn.';
66
+ readonly avoid: 'Groepen zonder volgorde of zonder doorlopende as: neem staven.';
67
+ };
68
+ readonly heatmap: {
69
+ readonly label: 'Heatmap';
70
+ readonly question: 'spread';
71
+ readonly use: 'Een waarde over twee indelingen tegelijk, zoals uur en dag, in vijf klassen.';
72
+ readonly avoid: 'Precieze waarden aflezen: klassen ronden af. Neem een tabel.';
73
+ };
74
+ readonly scatter: {
75
+ readonly label: 'Spreiding';
76
+ readonly question: 'relation';
77
+ readonly use: 'Of twee maten samenhangen: een punt per eenheid, met een norm op de verticale as.';
78
+ readonly avoid: 'Een verloop in de tijd: neem een lijn.';
79
+ };
80
+ readonly 'target-progress': {
81
+ readonly label: 'Voortgang tegen een doel';
82
+ readonly question: 'target';
83
+ readonly use: 'Hoe ver een paar onderdelen zijn tegen één doel.';
84
+ readonly avoid: 'Eén kerncijfer tegen een doel: dat is een KPI op een schaal, in lintje-kpi.';
85
+ };
86
+ };
@@ -1,6 +1,6 @@
1
1
  /**
2
- * Line and area chart with comparison, hatching and as-of time. Missing data is never drawn
3
- * as 0 (rule 15): `null` points are skipped and the missing part is hatched or cut off.
2
+ * Line and area chart with comparison, hatching, as-of time and events. Missing data is never
3
+ * drawn as 0 (rule 15): `null` points are skipped and the missing part is hatched or cut off.
4
4
  */
5
5
  import { type TemplateResult } from 'lit';
6
6
  import { type ChartOptions } from '../shared/controller.js';
@@ -59,6 +59,11 @@ export declare class LeafletSurface {
59
59
  width: number;
60
60
  metres: number;
61
61
  } | null;
62
+ /**
63
+ * On paper the box has another size, and Leaflet would keep the screen's pixels and cut the
64
+ * rest off: the area the reader saw fills the paper's box instead, and returns afterwards.
65
+ */
66
+ print(printing: boolean): void;
62
67
  home(): void;
63
68
  destroy(): void;
64
69
  }
@@ -1,27 +1,16 @@
1
1
  /**
2
- * Empty, error and loading states: the tile keeps its header, size and axes; only the data is
3
- * missing. This module writes the markup of `lintje-skeleton` and `lintje-announcement`, not
4
- * their CSS. A host with its own announcement element passes it in `announcement`.
2
+ * The loading skeleton in the shape of the chart. Empty and error are the tile's: it draws them
3
+ * with the shared blocks. The skeleton writes the markup of `lintje-skeleton`, not its CSS.
5
4
  */
6
5
  import { type TemplateResult } from 'lit';
7
6
  export type ChartSkeletonKind = 'line' | 'bar' | 'pie' | 'donut' | 'heatmap' | 'map' | 'table';
8
- /** Loading skeleton in the shape of the chart, exactly `height` tall so the tile keeps its size. */
9
- export declare function renderChartSkeleton({ kind, height, }?: {
10
- kind?: ChartSkeletonKind;
11
- height?: string;
12
- }): TemplateResult;
13
- /** Axes, grid and zero line stay; the message names the way out itself. */
14
- export declare function renderChartEmpty(message: unknown, height?: string): TemplateResult;
15
- /** The error announcement for a component: `live: true`, so a screen reader speaks it. */
16
- export declare function liveAnnouncement(message: unknown): TemplateResult;
17
7
  /**
18
- * Error state: the announcement with the last known value, without "Opnieuw proberen". The
19
- * calling component defines the element; a host with its own announcement passes it in.
8
+ * Loading skeleton in the shape of the chart, exactly `height` tall so the tile keeps its size.
9
+ * Inside a tile's `loading` slot the tile's region speaks (`status: false`); on its own it is
10
+ * the region, in words.
20
11
  */
21
- export declare function renderChartError({ message, lastKnown, height, announcement, }: {
22
- message: unknown;
23
- lastKnown?: unknown;
12
+ export declare function renderChartSkeleton({ kind, height, status, }?: {
13
+ kind?: ChartSkeletonKind;
24
14
  height?: string;
25
- /** The host's own announcement; without one, `liveAnnouncement`. */
26
- announcement?: (message: unknown) => TemplateResult;
15
+ status?: boolean;
27
16
  }): TemplateResult;
@@ -31,12 +31,19 @@ export interface TooltipRow {
31
31
  value: string;
32
32
  /** The swatch; a row without one is a plain figure. */
33
33
  color?: string;
34
+ /** A line above the row, which sums up the rows before it: a total. */
35
+ divider?: boolean;
34
36
  /** The series' shape instead of a square swatch, as its legend draws it. */
35
37
  symbol?: SeriesKey;
36
38
  }
37
39
  export interface TooltipContent {
38
40
  title: string;
39
41
  rows: TooltipRow[];
42
+ /** The events at this category, under the values: their number and text. */
43
+ events?: {
44
+ number: number;
45
+ label: string;
46
+ }[];
40
47
  }
41
48
  export interface TooltipState {
42
49
  x: number;
@@ -21,6 +21,17 @@ export interface LineSeriesData {
21
21
  comparison?: boolean;
22
22
  area?: boolean;
23
23
  }
24
+ /**
25
+ * Something that happened at a category. The chart numbers its events 1, 2, … from left to
26
+ * right, in the host's order within one category; one whose `index` is not in `labels` is left
27
+ * out and takes no number.
28
+ */
29
+ export interface ChartEvent {
30
+ /** Index into `labels`: the category it happened at. */
31
+ index: number;
32
+ /** What happened, in a few words; listed under the chart and shown in the tooltip. */
33
+ label: string;
34
+ }
24
35
  export interface BarSeriesData {
25
36
  label: string;
26
37
  values: number[];
@@ -59,6 +70,8 @@ export type ChartSpec = {
59
70
  pendingHours?: number;
60
71
  fixedMax?: number;
61
72
  small?: boolean;
73
+ /** Events: a numbered square above their category, listed with their text under the chart. */
74
+ events?: ChartEvent[];
62
75
  } | {
63
76
  kind: 'bar';
64
77
  labels: string[];
@@ -105,6 +118,22 @@ export type ChartSpec = {
105
118
  normalized?: boolean;
106
119
  totalOnTop?: boolean;
107
120
  small?: boolean;
121
+ } | {
122
+ kind: 'stacked-area';
123
+ labels: string[];
124
+ /**
125
+ * The parts of one variable, the first at the bottom. A `null` in any part breaks the whole
126
+ * stack at that point: no area bridges it and the period is hatched (rule 15).
127
+ */
128
+ series: {
129
+ label: string;
130
+ values: (number | null)[];
131
+ }[];
132
+ /** The variable the stack divides: its parts take this colour's tints. Default sky blue. */
133
+ color?: ChartColor;
134
+ axisTitle?: string;
135
+ unit?: string;
136
+ small?: boolean;
108
137
  } | {
109
138
  kind: 'pie';
110
139
  segments: {
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Stacked areas: the parts of one variable in its tints, the first at the bottom and darkest. A
3
+ * missing value breaks its part and every part above it; the parts below stay, and the rest of
4
+ * the column is hatched (rule 15). A part switched off shrinks out and the parts above settle.
5
+ */
6
+ import { type TemplateResult } from 'lit';
7
+ import { type ChartOptions } from '../shared/controller.js';
8
+ import type { ChartSpec } from '../shared/types.js';
9
+ type StackedAreaSpec = Extract<ChartSpec, {
10
+ kind: 'stacked-area';
11
+ }>;
12
+ export declare function renderStackedAreaChart(spec: StackedAreaSpec, options: ChartOptions): TemplateResult;
13
+ export {};
@@ -0,0 +1,9 @@
1
+ export declare class DialogHold {
2
+ #private;
3
+ constructor(onEscape: () => void);
4
+ get held(): boolean;
5
+ isTopmost(): boolean;
6
+ /** The focus stays where it is: the window moves it once its content has drawn. */
7
+ hold(container: HTMLElement): void;
8
+ release(): void;
9
+ }