lintje 0.1.1 → 0.2.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 (177) hide show
  1. package/dist-elements/actions.js +1 -1
  2. package/dist-elements/charts.js +1 -1
  3. package/dist-elements/chunks/{base-rBLTcEIv.js → base-Bg-IFOPG.js} +134 -105
  4. package/dist-elements/chunks/{date-format-B5DPGjAw.js → date-format-mHtZyBys.js} +28 -2
  5. package/dist-elements/chunks/disclosure-BXTX04gM.js +4 -0
  6. package/dist-elements/chunks/{disclosure-CHasOudX.js → disclosure-CMXhX-Vb.js} +7 -7
  7. package/dist-elements/chunks/download-y528pIHP.js +230 -0
  8. package/dist-elements/chunks/{focus-trap-w3vCamJ6.js → focus-trap-9BnE-xWv.js} +1 -1
  9. package/dist-elements/chunks/{input-jQVTln7H.js → input-BtuNFSWk.js} +13 -13
  10. package/dist-elements/chunks/{player-Bq9YGnpt.js → player-DXOZEyEy.js} +24 -24
  11. package/dist-elements/chunks/{sentence-CLNJOeXz.js → sentence-BI3lwEuT.js} +3 -3
  12. package/dist-elements/chunks/{stagger-9hYzxhMG.js → stagger-qGD3wmhg.js} +145 -123
  13. package/dist-elements/core.js +1 -1
  14. package/dist-elements/custom-elements.json +436 -26
  15. package/dist-elements/feedback.js +1 -1
  16. package/dist-elements/guides/dashboard.md +1 -1
  17. package/dist-elements/guides/events.md +3 -2
  18. package/dist-elements/guides/loading.md +3 -3
  19. package/dist-elements/guides/start.md +1 -1
  20. package/dist-elements/inputs.js +1 -0
  21. package/dist-elements/layout.js +1 -1
  22. package/dist-elements/lintje.js +22659 -22216
  23. package/dist-elements/map.js +1 -1
  24. package/dist-elements/overlays.js +1 -1
  25. package/dist-elements/tag/activity-log.js +11 -11
  26. package/dist-elements/tag/ai-label.js +7 -7
  27. package/dist-elements/tag/announcement.js +19 -19
  28. package/dist-elements/tag/app-search.js +21 -21
  29. package/dist-elements/tag/audio-player.js +34 -34
  30. package/dist-elements/tag/badge.js +1 -1
  31. package/dist-elements/tag/breadcrumbs.js +11 -11
  32. package/dist-elements/tag/button.js +1 -1
  33. package/dist-elements/tag/card-list.js +1 -1
  34. package/dist-elements/tag/card.js +25 -25
  35. package/dist-elements/tag/chart.d.ts +1 -0
  36. package/dist-elements/tag/chart.js +1868 -0
  37. package/dist-elements/tag/chat-answer.js +28 -28
  38. package/dist-elements/tag/chat-composer.js +20 -20
  39. package/dist-elements/tag/chat-message.js +9 -9
  40. package/dist-elements/tag/chat-strip.js +16 -16
  41. package/dist-elements/tag/chat-suggestions.js +1 -1
  42. package/dist-elements/tag/chat.js +27 -27
  43. package/dist-elements/tag/checkbox.js +6 -6
  44. package/dist-elements/tag/code.js +8 -8
  45. package/dist-elements/tag/combobox.js +13 -13
  46. package/dist-elements/tag/confirm-dialog.js +6 -6
  47. package/dist-elements/tag/conflict-alert.js +5 -5
  48. package/dist-elements/tag/copy-button.js +7 -7
  49. package/dist-elements/tag/data-table.js +179 -179
  50. package/dist-elements/tag/date-input.js +34 -42
  51. package/dist-elements/tag/date-range.js +33 -33
  52. package/dist-elements/tag/description-list.js +20 -20
  53. package/dist-elements/tag/document-viewer.js +19 -19
  54. package/dist-elements/tag/drawer.js +7 -7
  55. package/dist-elements/tag/empty-state.js +11 -11
  56. package/dist-elements/tag/error-summary.js +8 -8
  57. package/dist-elements/tag/expander.js +7 -7
  58. package/dist-elements/tag/explainer.js +9 -9
  59. package/dist-elements/tag/field.js +4 -4
  60. package/dist-elements/tag/file-upload.js +20 -20
  61. package/dist-elements/tag/filter-bar.js +35 -35
  62. package/dist-elements/tag/filter-sheet.js +6 -6
  63. package/dist-elements/tag/filter-zone.js +21 -21
  64. package/dist-elements/tag/footer.js +1 -1
  65. package/dist-elements/tag/form-actions.js +7 -7
  66. package/dist-elements/tag/form-section.js +3 -3
  67. package/dist-elements/tag/form.js +4 -4
  68. package/dist-elements/tag/gallery.js +6 -6
  69. package/dist-elements/tag/grid-item.js +1 -1
  70. package/dist-elements/tag/grid.js +1 -1
  71. package/dist-elements/tag/hero.js +6 -6
  72. package/dist-elements/tag/highlight.js +6 -6
  73. package/dist-elements/tag/icon-button.js +1 -1
  74. package/dist-elements/tag/icon.js +1 -1
  75. package/dist-elements/tag/job-list.js +6 -6
  76. package/dist-elements/tag/kpi-row.js +7 -5
  77. package/dist-elements/tag/kpi.js +259 -69
  78. package/dist-elements/tag/level-meter.js +5 -5
  79. package/dist-elements/tag/list.js +28 -28
  80. package/dist-elements/tag/logo.js +9 -9
  81. package/dist-elements/tag/map.d.ts +1 -0
  82. package/dist-elements/tag/map.js +21910 -0
  83. package/dist-elements/tag/menu-button.js +48 -47
  84. package/dist-elements/tag/modal.js +9 -9
  85. package/dist-elements/tag/multiselect.js +18 -18
  86. package/dist-elements/tag/note.js +4 -4
  87. package/dist-elements/tag/notifications.js +24 -24
  88. package/dist-elements/tag/number-input.js +8 -8
  89. package/dist-elements/tag/page-header.js +13 -13
  90. package/dist-elements/tag/pagination.js +27 -27
  91. package/dist-elements/tag/popover.js +1 -1
  92. package/dist-elements/tag/progress-bar.js +1 -1
  93. package/dist-elements/tag/prose.js +4 -4
  94. package/dist-elements/tag/qr-code.js +6 -6
  95. package/dist-elements/tag/radio-group.js +7 -7
  96. package/dist-elements/tag/range.js +13 -13
  97. package/dist-elements/tag/recording-status.js +8 -8
  98. package/dist-elements/tag/repeater.js +1 -1
  99. package/dist-elements/tag/segmented.js +7 -7
  100. package/dist-elements/tag/select.js +6 -6
  101. package/dist-elements/tag/session-expiry.js +13 -13
  102. package/dist-elements/tag/shell.js +168 -168
  103. package/dist-elements/tag/shortcuts.js +8 -8
  104. package/dist-elements/tag/skeleton.js +1 -1
  105. package/dist-elements/tag/slot-picker.d.ts +1 -0
  106. package/dist-elements/tag/slot-picker.js +74 -0
  107. package/dist-elements/tag/sortable-list.js +11 -11
  108. package/dist-elements/tag/spinner.js +1 -1
  109. package/dist-elements/tag/split-pane.js +4 -4
  110. package/dist-elements/tag/status-dot.js +1 -1
  111. package/dist-elements/tag/stepper.js +13 -13
  112. package/dist-elements/tag/streaming-text.js +15 -15
  113. package/dist-elements/tag/sub-nav.js +26 -26
  114. package/dist-elements/tag/tabs.js +13 -13
  115. package/dist-elements/tag/tag-input.js +14 -14
  116. package/dist-elements/tag/text-editor.js +7 -7
  117. package/dist-elements/tag/text-input.js +10 -10
  118. package/dist-elements/tag/textarea.js +6 -6
  119. package/dist-elements/tag/tile.js +1 -1
  120. package/dist-elements/tag/time-input.js +136 -42
  121. package/dist-elements/tag/toast.js +10 -10
  122. package/dist-elements/tag/toggle.js +6 -6
  123. package/dist-elements/tag/toggletip.js +11 -11
  124. package/dist-elements/tag/tooltip.js +1 -1
  125. package/dist-elements/tag/transcript.js +31 -31
  126. package/dist-elements/tag/translator.js +7 -7
  127. package/dist-elements/tag/tree-view.js +12 -12
  128. package/dist-elements/tag/user-menu.js +31 -30
  129. package/dist-elements/tag/video-player.js +13 -13
  130. package/dist-elements/tokens.css +2 -0
  131. package/dist-elements/types/bundle/charts.d.ts +1 -1
  132. package/dist-elements/types/bundle/index.d.ts +1 -1
  133. package/dist-elements/types/bundle/inputs.d.ts +1 -0
  134. package/dist-elements/types/bundle/map.d.ts +1 -1
  135. package/dist-elements/types/components/charts/{chart-tile/chart-tile.d.ts → chart/chart.d.ts} +7 -7
  136. package/dist-elements/types/components/charts/kpi/gauge.d.ts +18 -0
  137. package/dist-elements/types/components/charts/kpi/kpi.d.ts +28 -3
  138. package/dist-elements/types/components/chat/chat-answer/chat-answer.d.ts +1 -1
  139. package/dist-elements/types/components/index.d.ts +8 -5
  140. package/dist-elements/types/components/inputs/date-input/date-format.d.ts +4 -0
  141. package/dist-elements/types/components/inputs/slot-picker/slot-picker.d.ts +41 -0
  142. package/dist-elements/types/components/inputs/time-input/time-format.d.ts +4 -0
  143. package/dist-elements/types/components/inputs/time-input/time-input.d.ts +25 -6
  144. package/dist-elements/types/components/map/{map-tile/map-tile.d.ts → map/map.d.ts} +10 -6
  145. package/dist-elements/types/components/shared/charts/histogram-chart/histogram-chart.d.ts +33 -0
  146. package/dist-elements/types/components/shared/charts/index.d.ts +3 -1
  147. package/dist-elements/types/components/shared/charts/map-chart/area.d.ts +16 -0
  148. package/dist-elements/types/components/shared/charts/map-chart/drawings.d.ts +6 -2
  149. package/dist-elements/types/components/shared/charts/map-chart/geo.d.ts +6 -0
  150. package/dist-elements/types/components/shared/charts/map-chart/leaflet.d.ts +40 -2
  151. package/dist-elements/types/components/shared/charts/map-chart/map-chart.d.ts +17 -3
  152. package/dist-elements/types/components/shared/charts/map-chart/map-legend.d.ts +26 -0
  153. package/dist-elements/types/components/shared/charts/map-chart/marks.d.ts +47 -0
  154. package/dist-elements/types/components/shared/charts/map-chart/reveal.d.ts +1 -1
  155. package/dist-elements/types/components/shared/charts/scatter-chart/scatter-chart.d.ts +29 -0
  156. package/dist-elements/types/components/shared/charts/shared/axes.d.ts +21 -4
  157. package/dist-elements/types/components/shared/charts/shared/chart-icons.d.ts +4 -3
  158. package/dist-elements/types/components/shared/charts/shared/controller.d.ts +27 -15
  159. package/dist-elements/types/components/shared/charts/shared/types.d.ts +112 -6
  160. package/dist-elements/types/core/format.d.ts +5 -2
  161. package/dist-elements/types/icons/register.d.ts +1 -1
  162. package/dist-elements/types/primitives/shared/place.d.ts +1 -1
  163. package/dist-elements/types/primitives/tooltip/tooltip.d.ts +2 -0
  164. package/dist-elements/types/types.d.ts +37 -7
  165. package/dist-icons/functioneel-cirkelselectie.svg +1 -0
  166. package/dist-icons/functioneel-lasso.svg +1 -0
  167. package/dist-icons/functioneel-punaise-outline.svg +1 -0
  168. package/dist-icons/functioneel-punaise.svg +1 -0
  169. package/dist-icons/functioneel-rechthoekselectie.svg +1 -0
  170. package/dist-icons/functioneel-selectie.svg +1 -0
  171. package/package.json +1 -1
  172. package/dist-elements/chunks/disclosure-Z7Ny17sS.js +0 -4
  173. package/dist-elements/chunks/download-lFooAfD1.js +0 -226
  174. package/dist-elements/tag/chart-tile.d.ts +0 -1
  175. package/dist-elements/tag/chart-tile.js +0 -1474
  176. package/dist-elements/tag/map-tile.d.ts +0 -1
  177. package/dist-elements/tag/map-tile.js +0 -22292
@@ -1,4 +1,4 @@
1
- import { $ as e, Bt as t, Gt as n, Ht as r, I as i, Kt as a, Z as o, et as s, zt as c } from "../chunks/base-rBLTcEIv.js";
1
+ import { $ as e, Bt as t, Gt as n, Ht as r, I as i, Z as a, et as o, qt as s, zt as c } from "../chunks/base-Bg-IFOPG.js";
2
2
  //#region src/components/layout/tabs/tabs.css?inline
3
3
  var l = ":host { display: block; min-width: 0; }\n:host([hidden]) { display: none; }\n\n/* ------------------------------------------------------------------------ */\n\n/* `position: relative` makes the row the tabs' offset parent, for scrolling the chosen tab into sight. */\n.lintje-tabs__list {\n position: relative;\n display: flex; flex-wrap: wrap;\n border-bottom: 1px solid var(--color-border-heavy);\n}\n\n/* A transparent bottom edge in reserve, so the chosen tab's line takes no space of its own. */\n.lintje-tabs__tab {\n display: inline-flex; align-items: center; gap: var(--space-2);\n height: var(--h-touch);\n padding: 0 var(--space-4);\n background: transparent;\n color: var(--color-text-primary);\n border-bottom: 3px solid transparent;\n font: var(--text-ui);\n text-decoration: none;\n white-space: nowrap;\n transition: background var(--dur-hover) var(--ease-in-motion),\n border-color var(--dur-hover) var(--ease-in-motion);\n}\n.lintje-tabs__tab:hover:not(.is-active):not(.is-disabled) {\n background: var(--color-bg-subtle);\n border-bottom-color: var(--color-border-heavy);\n}\n\n/* The chosen tab: the line is a line (3:1) and the word is text (4.5:1), hence two tokens. */\n.lintje-tabs__tab.is-active {\n border-bottom-color: var(--color-accent-line);\n color: var(--color-accent-text);\n font-weight: 700;\n}\n\n.lintje-tabs__tab.is-disabled { color: var(--color-text-disabled); cursor: not-allowed; }\n\n.lintje-tabs__panel { padding-top: var(--space-4); }\n.lintje-tabs__panel.is-pressed:focus-visible { outline: none; }\n\n@media (max-width: 767px) {\n .lintje-tabs__list {\n flex-wrap: nowrap;\n overflow-x: auto;\n scrollbar-width: none;\n }\n .lintje-tabs__list::-webkit-scrollbar { display: none; }\n .lintje-tabs__tab { flex: 0 0 auto; }\n .lintje-tabs__list.is-scroll-start { box-shadow: var(--shadow-scroll-start); }\n .lintje-tabs__list.is-scroll-end { box-shadow: var(--shadow-scroll-end); }\n .lintje-tabs__list.is-scroll-start.is-scroll-end {\n box-shadow: var(--shadow-scroll-start), var(--shadow-scroll-end);\n }\n}\n\n/* Forced colours: the chosen tab's line turns Highlight, a disabled tab GrayText. */\n@media (forced-colors: active) {\n .lintje-tabs__tab.is-active { border-bottom-color: Highlight; }\n .lintje-tabs__tab.is-disabled { color: GrayText; }\n}\n\n/* --- The panel variant --------------------------------------------------------\n Large tabs that head a bordered panel. The chosen tab is the panel's own surface and runs into\n it; the others stand on the subtle fill. No line: surface, accent word and weight say it. */\n.lintje-tabs--panel {\n background: var(--color-bg-surface);\n border: 1px solid var(--color-border-default);\n}\n.lintje-tabs--panel .lintje-tabs__list {\n flex-wrap: nowrap;\n background: var(--color-bg-subtle);\n border-bottom-color: var(--color-border-default);\n}\n.lintje-tabs--panel .lintje-tabs__tab {\n flex: 1 1 0;\n min-width: 0;\n height: auto;\n min-height: var(--h-touch);\n margin-bottom: -1px;\n align-items: flex-start;\n gap: var(--space-3);\n padding: var(--space-4) var(--space-5);\n border-right: 1px solid var(--color-border-default);\n border-bottom: 1px solid var(--color-border-default);\n white-space: normal;\n text-align: left;\n}\n.lintje-tabs--panel .lintje-tabs__tab:last-child { border-right: 0; }\n.lintje-tabs--panel .lintje-tabs__tab:hover:not(.is-active):not(.is-disabled) {\n background: var(--color-bg-subtle);\n border-bottom-color: var(--color-border-default);\n}\n.lintje-tabs--panel .lintje-tabs__tab:hover:not(.is-active):not(.is-disabled) .lintje-tabs__label {\n text-decoration: underline;\n}\n/* The bottom edge takes the surface, so the tab and the panel are one shape. */\n.lintje-tabs--panel .lintje-tabs__tab.is-active {\n background: var(--color-bg-surface);\n border-bottom-color: var(--color-bg-surface);\n color: var(--color-accent-text);\n}\n.lintje-tabs__icon { flex: none; }\n.lintje-tabs__text { display: flex; flex-direction: column; gap: 2px; min-width: 0; }\n.lintje-tabs__head { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-1) var(--space-2); }\n.lintje-tabs__hint { font: var(--text-meta); color: var(--color-text-muted); }\n.lintje-tabs--panel .lintje-tabs__panel { padding: var(--space-6); }\n\n@media (max-width: 767px) {\n .lintje-tabs--panel .lintje-tabs__tab {\n flex-direction: column;\n align-items: center;\n gap: var(--space-2);\n padding: var(--space-3) var(--space-2);\n text-align: center;\n }\n .lintje-tabs--panel .lintje-tabs__text { align-items: center; }\n .lintje-tabs--panel .lintje-tabs__head { justify-content: center; }\n .lintje-tabs--panel .lintje-tabs__hint { display: none; }\n .lintje-tabs--panel .lintje-tabs__panel { padding: var(--space-4); }\n}\n\n/* Forced colours drop the surface: the chosen tab's label is underlined instead. */\n@media (forced-colors: active) {\n .lintje-tabs--panel .lintje-tabs__tab.is-active .lintje-tabs__label { text-decoration: underline; }\n}\n";
4
4
  //#endregion
@@ -85,26 +85,26 @@ var f = class extends c {
85
85
  t && n && t.scrollWidth > t.clientWidth && (t.scrollLeft = d(n.offsetLeft, n.offsetWidth, t.scrollLeft, t.clientWidth)), this.measureEdges();
86
86
  }
87
87
  renderTab(e, t, r) {
88
- let i = o({
88
+ let i = a({
89
89
  "lintje-tabs__tab": !0,
90
90
  "focus-inset": !0,
91
91
  "is-active": r,
92
92
  "is-disabled": !!e.disabled
93
- }), c = a`<span class="lintje-tabs__label">${e.label}</span>${typeof e.count == "number" ? a`<lintje-badge variant="count">${e.count}</lintje-badge>` : n}${e.badge ? a`<lintje-badge tone="info">${e.badge}</lintje-badge>` : n}`, l = this.variant === "panel" ? a`${e.icon ? s(e.icon, {
93
+ }), c = s`<span class="lintje-tabs__label">${e.label}</span>${typeof e.count == "number" ? s`<lintje-badge variant="count">${e.count}</lintje-badge>` : n}${e.badge ? s`<lintje-badge tone="info">${e.badge}</lintje-badge>` : n}`, l = this.variant === "panel" ? s`${e.icon ? o(e.icon, {
94
94
  size: 24,
95
95
  className: "lintje-tabs__icon"
96
96
  }) : n}<span
97
97
  class="lintje-tabs__text"
98
- ><span class="lintje-tabs__head">${c}</span>${e.hint ? a`<span class="lintje-tabs__hint">${e.hint}</span>` : n}</span
98
+ ><span class="lintje-tabs__head">${c}</span>${e.hint ? s`<span class="lintje-tabs__hint">${e.hint}</span>` : n}</span
99
99
  >` : c;
100
- return this.isNav ? e.disabled ? a`<a id="tab-${t}" class=${i} role="link" aria-disabled="true">${l}</a>` : a`<a
100
+ return this.isNav ? e.disabled ? s`<a id="tab-${t}" class=${i} role="link" aria-disabled="true">${l}</a>` : s`<a
101
101
  id="tab-${t}"
102
102
  class=${i}
103
103
  href=${e.href}
104
104
  aria-current=${r ? "page" : n}
105
105
  @click=${(e) => this.onClick(e, t)}
106
106
  >${l}</a
107
- >` : e.href && !e.disabled ? a`<a
107
+ >` : e.href && !e.disabled ? s`<a
108
108
  id="tab-${t}"
109
109
  class=${i}
110
110
  role="tab"
@@ -114,7 +114,7 @@ var f = class extends c {
114
114
  tabindex=${r ? 0 : -1}
115
115
  @click=${(e) => this.onClick(e, t)}
116
116
  >${l}</a
117
- >` : a`<button
117
+ >` : s`<button
118
118
  id="tab-${t}"
119
119
  type="button"
120
120
  class=${i}
@@ -129,8 +129,8 @@ var f = class extends c {
129
129
  </button>`;
130
130
  }
131
131
  render() {
132
- let e = this.selectedIndex, t = this.isNav, r = a`<div
133
- class=${o({
132
+ let e = this.selectedIndex, t = this.isNav, r = s`<div
133
+ class=${a({
134
134
  "lintje-tabs__list": !0,
135
135
  "is-scroll-start": this.edges.start,
136
136
  "is-scroll-end": this.edges.end
@@ -141,16 +141,16 @@ var f = class extends c {
141
141
  @scroll=${this.measureEdges}
142
142
  >
143
143
  ${this.tabs.map((t, n) => this.renderTab(t, n, n === e))}
144
- </div>`, i = o({
144
+ </div>`, i = a({
145
145
  "lintje-tabs": !0,
146
146
  "lintje-tabs--panel": this.variant === "panel"
147
147
  });
148
- return t ? a`<div class=${i}>
148
+ return t ? s`<div class=${i}>
149
149
  <nav aria-label=${this.label || n}>${r}</nav>
150
150
  <div class="lintje-tabs__panel"><slot name=${this.tabs[e].value}></slot></div>
151
- </div>` : a`<div class=${i}>
151
+ </div>` : s`<div class=${i}>
152
152
  ${r}
153
- ${this.tabs.map((t, n) => a`<div
153
+ ${this.tabs.map((t, n) => s`<div
154
154
  id="panel-${n}"
155
155
  class="lintje-tabs__panel"
156
156
  role="tabpanel"
@@ -1,5 +1,5 @@
1
- import { $ as e, Bt as t, Gt as n, Ht as r, Kt as i, Z as a, et as o, f as s } from "../chunks/base-rBLTcEIv.js";
2
- import { r as c, t as l } from "../chunks/input-jQVTln7H.js";
1
+ import { $ as e, Bt as t, Gt as n, Ht as r, Z as i, et as a, f as o, qt as s } from "../chunks/base-Bg-IFOPG.js";
2
+ import { r as c, t as l } from "../chunks/input-BtuNFSWk.js";
3
3
  import { filterOptions as u, splitMatch as d } from "./combobox.js";
4
4
  //#region src/components/inputs/tag-input/tag-input.css?inline
5
5
  var f = "/* The keyword field: chips and the typing part in one box that grows in height. */\n:host { display: block; min-width: 0; }\n:host([hidden]) { display: none; }\n/* Below 768 px: the touch height and the full width, as `stacked`. */\n@media (max-width: 767px) {\n :host {\n width: 100%;\n --h-control: var(--h-touch);\n }\n}\n\n/* --- */\n\n/* The padding centres a chip in the control height; wrapped chips grow the box. */\n.lintje-tag-input {\n display: flex; flex-wrap: wrap; align-items: center;\n gap: 6px;\n min-height: var(--h-control);\n padding: calc((var(--h-control) - var(--h-chip-field)) / 2 - 1px) var(--space-2);\n border: 1px solid var(--color-border-field);\n border-radius: var(--radius);\n background: var(--color-bg-surface);\n color: var(--color-text-primary);\n}\n/* The ring is around the whole field; a chip draws it around itself when its cross has the focus. */\n.lintje-tag-input:has(.lintje-tag-input__input:focus-visible),\n.lintje-tag-input__chip:has(.lintje-tag-input__remove:focus-visible) {\n outline: var(--focus-width) solid var(--color-focus);\n outline-offset: var(--focus-offset);\n}\n.lintje-tag-input__input:focus-visible,\n.lintje-tag-input__remove:focus-visible { outline: none; }\n/* The padding gives back the pixel the 2 px error border takes. */\n.lintje-tag-input.is-error {\n border: 2px solid var(--color-error);\n padding: calc((var(--h-control) - var(--h-chip-field)) / 2 - 2px) calc(var(--space-2) - 1px);\n}\n/* Disabled wins over error: placed after it. */\n.lintje-tag-input.is-disabled {\n border: 1px solid var(--color-border-strong);\n padding: calc((var(--h-control) - var(--h-chip-field)) / 2 - 1px) var(--space-2);\n background: var(--color-bg-subtle);\n cursor: not-allowed;\n}\n\n.lintje-tag-input__chips { display: contents; }\n.lintje-tag-input__item { display: flex; min-width: 0; }\n.lintje-tag-input__chip {\n display: inline-flex; align-items: center;\n min-width: 0;\n height: var(--h-chip-field);\n padding: 0 0 0 var(--space-2);\n background: var(--color-bg-subtle);\n border: 1px solid var(--color-border-default);\n font-size: 0.875rem; white-space: nowrap;\n}\n.lintje-tag-input.is-disabled .lintje-tag-input__chip { padding-right: var(--space-2); }\n/* A word typed twice flashes its chip. */\n.lintje-tag-input__chip.is-flash { border-color: var(--color-accent-line); }\n.lintje-tag-input.is-disabled .lintje-tag-input__chip { color: var(--color-text-disabled); }\n/* A transparent hit area, above and below only, reaches the target height. */\n.lintje-tag-input__remove {\n position: relative;\n flex: none;\n width: var(--space-6); align-self: stretch;\n display: inline-flex; align-items: center; justify-content: center;\n color: var(--color-text-muted);\n}\n.lintje-tag-input__remove:hover { color: var(--color-text-primary); }\n.lintje-tag-input__remove::after {\n content: '';\n position: absolute;\n inset: min(0px, calc((var(--h-chip-field) - var(--h-target)) / 2)) 0;\n}\n\n.lintje-tag-input__input {\n flex: 1 1 60px; min-width: 0;\n height: var(--h-chip-field);\n padding: 0 var(--space-1);\n border: 0;\n background: none;\n color: inherit;\n font-size: 1rem;\n}\n.lintje-tag-input__input::placeholder { color: var(--color-text-placeholder); opacity: 1; }\n.lintje-tag-input__input:disabled { cursor: not-allowed; }\n\n.lintje-tag-input__list {\n max-height: calc(7 * var(--h-option) + var(--space-2));\n overflow-y: auto;\n padding: var(--space-1) 0;\n font: var(--text-ui);\n}\n.lintje-tag-input__option {\n display: flex; align-items: center;\n min-height: var(--h-option);\n padding: 0 14px;\n cursor: pointer;\n}\n.lintje-tag-input__option:hover,\n.lintje-tag-input__option.is-active { background: var(--color-bg-subtle); }\n/* The option the keys stand on: the fill alone is about 1.1:1, so the focus ring inside the row. */\n.lintje-tag-input__option.is-active {\n outline: var(--focus-width) solid var(--color-focus);\n outline-offset: calc(var(--focus-width) * -1);\n}\n\n/* Forced colours drop the fill: the row takes an edge inside, keeping its size. */\n@media (forced-colors: active) {\n .lintje-tag-input__option.is-active { outline: 1px solid CanvasText; outline-offset: -1px; }\n}\n";
@@ -155,12 +155,12 @@ var h = 1e3, g = "lintje-tag-input-list", _ = "lintje-tag-input-keys", v = (e) =
155
155
  }
156
156
  renderChip(e, t) {
157
157
  let r = this.labelOf(e);
158
- return i`<li class="lintje-tag-input__item">
159
- <span class=${a({
158
+ return s`<li class="lintje-tag-input__item">
159
+ <span class=${i({
160
160
  "lintje-tag-input__chip": !0,
161
161
  "is-flash": this.flash === e
162
162
  })}
163
- >${r}${this.disabled ? n : i`<button
163
+ >${r}${this.disabled ? n : s`<button
164
164
  type="button"
165
165
  class="lintje-tag-input__remove"
166
166
  tabindex="-1"
@@ -169,13 +169,13 @@ var h = 1e3, g = "lintje-tag-input-list", _ = "lintje-tag-input-keys", v = (e) =
169
169
  @keydown=${(e) => this.onChipKeydown(e, t)}
170
170
  @click=${() => this.removeChip(t, "input")}
171
171
  >
172
- ${o("functioneel-kruis", { size: 12 })}
172
+ ${a("functioneel-kruis", { size: 12 })}
173
173
  </button>`}</span
174
174
  >
175
175
  </li>`;
176
176
  }
177
177
  renderSuggestions() {
178
- return this.listOpen ? i`<ul
178
+ return this.listOpen ? s`<ul
179
179
  id=${g}
180
180
  class="lintje-tag-input__list"
181
181
  role="listbox"
@@ -183,10 +183,10 @@ var h = 1e3, g = "lintje-tag-input-list", _ = "lintje-tag-input-keys", v = (e) =
183
183
  aria-labelledby=${this.labelId}
184
184
  >
185
185
  ${this.suggestions.map((e, t) => {
186
- let [r, o, s] = d(e.label, this.text);
187
- return i`<li
186
+ let [r, a, o] = d(e.label, this.text);
187
+ return s`<li
188
188
  id=${v(t)}
189
- class=${a({
189
+ class=${i({
190
190
  "lintje-tag-input__option": !0,
191
191
  "is-active": t === this.active
192
192
  })}
@@ -194,17 +194,17 @@ var h = 1e3, g = "lintje-tag-input-list", _ = "lintje-tag-input-keys", v = (e) =
194
194
  aria-selected="false"
195
195
  @click=${() => this.add([e.label])}
196
196
  >
197
- ${r}${o ? i`<strong>${o}</strong>` : n}${s}
197
+ ${r}${a ? s`<strong>${a}</strong>` : n}${o}
198
198
  </li>`;
199
199
  })}
200
200
  </ul>` : n;
201
201
  }
202
202
  render() {
203
203
  let e = this.listOpen, t = !!this.options;
204
- return i`<div class="lintje-field">
204
+ return s`<div class="lintje-field">
205
205
  ${this.renderLabel(this.controlId)}
206
206
  <div
207
- class=${a({
207
+ class=${i({
208
208
  "lintje-tag-input": !0,
209
209
  "is-error": !!this.error,
210
210
  "is-disabled": this.disabled
@@ -219,7 +219,7 @@ var h = 1e3, g = "lintje-tag-input-list", _ = "lintje-tag-input-keys", v = (e) =
219
219
  type="text"
220
220
  id=${this.controlId}
221
221
  class="lintje-tag-input__input"
222
- .value=${s(this.text)}
222
+ .value=${o(this.text)}
223
223
  placeholder=${this.value.length ? n : this.placeholder || n}
224
224
  autocomplete="off"
225
225
  enterkeyhint="enter"
@@ -1,5 +1,5 @@
1
- import { $ as e, Bt as t, G as n, Gt as r, Ht as i, Kt as a, Z as o } from "../chunks/base-rBLTcEIv.js";
2
- import { r as s, t as c } from "../chunks/input-jQVTln7H.js";
1
+ import { $ as e, Bt as t, G as n, Gt as r, Ht as i, Z as a, qt as o } from "../chunks/base-Bg-IFOPG.js";
2
+ import { r as s, t as c } from "../chunks/input-BtuNFSWk.js";
3
3
  import { t as l } from "../chunks/prose-CmKVp5kL.js";
4
4
  import "./text-input.js";
5
5
  //#region src/components/inputs/text-editor/text-editor.css?inline
@@ -355,9 +355,9 @@ var z = class extends s {
355
355
  }
356
356
  renderTool(e, t) {
357
357
  let n = this.active.has(e.format), i = e.format === "link" && this.collapsed && !n;
358
- return a`<button
358
+ return o`<button
359
359
  type="button"
360
- class=${o({
360
+ class=${a({
361
361
  "lintje-text-editor__tool": !0,
362
362
  [`lintje-text-editor__tool--${e.format}`]: !0,
363
363
  "lintje-text-editor__tool--word": e.text.length > 1,
@@ -378,10 +378,10 @@ var z = class extends s {
378
378
  </button>`;
379
379
  }
380
380
  render() {
381
- return a`<div class="lintje-field" @focusout=${this.onFocusOut}>
381
+ return o`<div class="lintje-field" @focusout=${this.onFocusOut}>
382
382
  ${this.renderLabel()}
383
383
  <div
384
- class=${o({
384
+ class=${a({
385
385
  "lintje-text-editor": !0,
386
386
  "is-error": !!this.error,
387
387
  "is-disabled": this.disabled
@@ -403,7 +403,7 @@ var z = class extends s {
403
403
  @lintje-close=${this.onLinkClose}
404
404
  @focusout=${this.onLinkFocusOut}
405
405
  >
406
- ${this.linkOpen ? a`<div class="lintje-text-editor__link" @keydown=${this.onLinkKeydown}>
406
+ ${this.linkOpen ? o`<div class="lintje-text-editor__link" @keydown=${this.onLinkKeydown}>
407
407
  <lintje-text-input
408
408
  class="lintje-text-editor__link-field"
409
409
  label="Adres van de link"
@@ -1,5 +1,5 @@
1
- import { $ as e, Bt as t, Gt as n, Ht as r, Kt as i, Z as a, et as o } from "../chunks/base-rBLTcEIv.js";
2
- import { a as s, n as c, t as l } from "../chunks/input-jQVTln7H.js";
1
+ import { $ as e, Bt as t, Gt as n, Ht as r, Z as i, et as a, qt as o } from "../chunks/base-Bg-IFOPG.js";
2
+ import { a as s, n as c, t as l } from "../chunks/input-BtuNFSWk.js";
3
3
  import { t as u } from "../chunks/debounce-JXnLMCcF.js";
4
4
  //#region src/components/inputs/text-input/text-input.css?inline
5
5
  var d = "/* The text field. */\n\n/* --- Text field ----------------------------------------------------------- */\n.lintje-text-input { position: relative; display: flex; align-items: center; }\n.lintje-text-input__control {\n width: 100%; height: var(--h-control);\n padding: 0 14px;\n border: 1px solid var(--color-border-field);\n background: var(--color-bg-surface);\n color: var(--color-text-primary);\n font-size: 1rem;\n border-radius: var(--radius);\n}\n.lintje-text-input__control::placeholder { color: var(--color-text-placeholder); opacity: 1; }\n.lintje-text-input__control.is-error { border: 2px solid var(--color-error); }\n/* Read-only: the subtle surface, the strong border, the text still primary. */\n.lintje-text-input__control.is-readonly {\n border: 1px solid var(--color-border-strong);\n background: var(--color-bg-subtle);\n color: var(--color-text-primary);\n cursor: default;\n}\n.lintje-text-input__control:disabled {\n border: 1px solid var(--color-border-strong);\n background: var(--color-bg-subtle);\n color: var(--color-text-disabled);\n cursor: not-allowed;\n}\n.lintje-text-input--clearable .lintje-text-input__control {\n padding-right: calc(var(--h-icon-button) + var(--space-1));\n}\n/* The hit area reaches the target height above and below only: sideways it would cover the text. */\n.lintje-text-input__clear {\n position: absolute; right: var(--space-1);\n width: var(--h-icon-button); height: var(--h-icon-button);\n display: flex; align-items: center; justify-content: center;\n color: var(--color-text-muted);\n}\n.lintje-text-input__clear:hover { color: var(--color-text-primary); }\n.lintje-text-input__clear::after {\n content: '';\n position: absolute;\n inset: min(0px, calc((100% - var(--h-target)) / 2)) 0;\n}\n\n/* --- Search ---------------------------------------------------------------- */\n/* The browser's own clear button and decoration go: the field draws its own cross. */\n.lintje-text-input--search .lintje-text-input__control { padding-left: var(--space-10); }\n.lintje-text-input__search {\n position: absolute; left: var(--space-3);\n color: var(--color-text-muted);\n pointer-events: none;\n}\n.lintje-text-input__control::-webkit-search-cancel-button,\n.lintje-text-input__control::-webkit-search-decoration { appearance: none; }\n\n/* --- Password -------------------------------------------------------------- */\n.lintje-text-input--password .lintje-text-input__control { border-right: 0; }\n.lintje-text-input__reveal { flex: none; --h-button: var(--h-control); }\n", f = class extends c {
@@ -62,7 +62,7 @@ var d = "/* The text field. */\n\n/* --- Text field ----------------------------
62
62
  hintId: this.hintId,
63
63
  errorId: this.errorId
64
64
  };
65
- return this.type === "search" ? i`${e ? s(void 0, e, t) : n}<span
65
+ return this.type === "search" ? o`${e ? s(void 0, e, t) : n}<span
66
66
  id=${this.hintId}
67
67
  class="lintje-field__hint"
68
68
  aria-live="polite"
@@ -75,24 +75,24 @@ var d = "/* The text field. */\n\n/* --- Text field ----------------------------
75
75
  }
76
76
  render() {
77
77
  let e = this.type === "search", t = this.type === "password", r = (this.clearable || e) && !t && this.value !== "" && !this.disabled && !this.readonly;
78
- return i`<div class="lintje-field">
78
+ return o`<div class="lintje-field">
79
79
  ${this.renderLabel(this.controlId)}
80
80
  <div
81
- class=${a({
81
+ class=${i({
82
82
  "lintje-text-input": !0,
83
83
  "lintje-text-input--clearable": r,
84
84
  "lintje-text-input--search": e,
85
85
  "lintje-text-input--password": t
86
86
  })}
87
87
  >
88
- ${e ? o("functioneel-zoek", {
88
+ ${e ? a("functioneel-zoek", {
89
89
  size: 18,
90
90
  className: "lintje-text-input__search"
91
91
  }) : n}
92
92
  <input
93
93
  type=${this.inputType}
94
94
  id=${this.controlId}
95
- class=${a({
95
+ class=${i({
96
96
  "lintje-text-input__control": !0,
97
97
  "is-error": !!this.error,
98
98
  "is-readonly": this.readonly
@@ -114,16 +114,16 @@ var d = "/* The text field. */\n\n/* --- Text field ----------------------------
114
114
  @change=${this.change}
115
115
  @keydown=${this.onKeydown}
116
116
  />
117
- ${r ? i`<button
117
+ ${r ? o`<button
118
118
  type="button"
119
119
  class="lintje-text-input__clear"
120
120
  aria-label="Wissen"
121
121
  @mousedown=${(e) => e.preventDefault()}
122
122
  @click=${this.clear}
123
123
  >
124
- ${o("functioneel-kruis", { size: 16 })}
124
+ ${a("functioneel-kruis", { size: 16 })}
125
125
  </button>` : n}
126
- ${t ? i`<lintje-button
126
+ ${t ? o`<lintje-button
127
127
  class="lintje-text-input__reveal"
128
128
  variant="secondary"
129
129
  ?disabled=${this.disabled}
@@ -1,5 +1,5 @@
1
- import { $ as e, Bt as t, Gt as n, Ht as r, Kt as i, Z as a, ut as o } from "../chunks/base-rBLTcEIv.js";
2
- import { a as s, i as c, n as l, t as u } from "../chunks/input-jQVTln7H.js";
1
+ import { $ as e, Bt as t, Gt as n, Ht as r, Z as i, qt as a, ut as o } from "../chunks/base-Bg-IFOPG.js";
2
+ import { a as s, i as c, n as l, t as u } from "../chunks/input-BtuNFSWk.js";
3
3
  import { t as d } from "../chunks/debounce-JXnLMCcF.js";
4
4
  //#region src/components/inputs/textarea/textarea.css?inline
5
5
  var f = "/* The multi-line text field. */\n:host { display: block; min-width: 0; }\n:host([hidden]) { display: none; }\n/* Plain takes the type of where it stands, past the UI type every element sets on itself, and\n fills the height the surface gives it. */\n:host([variant='plain']) { display: flex; flex-direction: column; font: inherit; }\n/* Below 768 px: the full width, as `stacked`. */\n@media (max-width: 767px) {\n :host { width: 100%; }\n}\n\n/* --- */\n\n/* `rows` lines at least (three by default); grows with its content up to twelve, then scrolls. */\n.lintje-textarea__control {\n display: block;\n width: 100%;\n min-height: calc(var(--lintje-rows, 3) * 1lh + var(--space-4) + 2px);\n max-height: calc(12lh + var(--space-4) + 2px);\n field-sizing: content;\n padding: var(--space-2) 14px;\n border: 1px solid var(--color-border-field);\n border-radius: var(--radius);\n background: var(--color-bg-surface);\n color: var(--color-text-primary);\n font: var(--text-body);\n resize: vertical;\n overflow-y: auto;\n}\n.lintje-textarea__control::placeholder { color: var(--color-text-placeholder); opacity: 1; }\n/* The padding gives back the pixel the 2 px error border takes. */\n.lintje-textarea__control.is-error { border: 2px solid var(--color-error); padding: 7px 13px; }\n/* Disabled wins over read-only, read-only over error. */\n.lintje-textarea__control.is-readonly {\n border: 1px solid var(--color-border-strong);\n padding: var(--space-2) 14px;\n background: var(--color-bg-subtle);\n color: var(--color-text-primary);\n cursor: default;\n}\n.lintje-textarea__control:disabled {\n border: 1px solid var(--color-border-strong);\n padding: var(--space-2) 14px;\n background: var(--color-bg-subtle);\n color: var(--color-text-disabled);\n cursor: not-allowed;\n}\n\n/* Plain: the surface around it is the field, and draws the focus ring around itself, so the\n ring does not sit tight against the text. It keeps growing; the surface decides the height. */\n:host([variant='plain']) .lintje-field { flex: 1; }\n.lintje-textarea__control--plain { flex: 1; }\n.lintje-textarea__control--plain:focus-visible { outline: none; }\n.lintje-textarea__control--plain,\n.lintje-textarea__control--plain.is-readonly,\n.lintje-textarea__control--plain:disabled {\n min-height: calc(var(--lintje-rows, 3) * 1lh);\n max-height: none;\n padding: 0;\n border: 0;\n background: transparent;\n font: inherit;\n resize: none;\n}\n.lintje-textarea__control--plain.is-error { padding: 0 0 var(--space-1); border: 0; border-bottom: 2px solid var(--color-error); }\n\n.lintje-textarea__counter {\n align-self: flex-end;\n font: var(--text-meta);\n color: var(--color-text-muted);\n}\n.lintje-textarea__counter.is-over { color: var(--color-error-text); font-weight: 700; }\n", p = new Intl.NumberFormat("nl-NL");
@@ -108,10 +108,10 @@ var _ = typeof CSS < "u" && typeof CSS.supports == "function" && CSS.supports("f
108
108
  }, !this.#n || this.#r);
109
109
  if (!this.counterShown) return e;
110
110
  let t = this.maxlength, n = this.value.length;
111
- return i`${e}<span
111
+ return a`${e}<span
112
112
  id=${this.counterId}
113
113
  part="counter"
114
- class=${a({
114
+ class=${i({
115
115
  "lintje-textarea__counter": !0,
116
116
  "is-over": n > t
117
117
  })}
@@ -121,11 +121,11 @@ var _ = typeof CSS < "u" && typeof CSS.supports == "function" && CSS.supports("f
121
121
  }
122
122
  render() {
123
123
  let e = this.message;
124
- return i`<div class="lintje-field">
124
+ return a`<div class="lintje-field">
125
125
  ${this.renderLabel(this.controlId)}
126
126
  <textarea
127
127
  id=${this.controlId}
128
- class=${a({
128
+ class=${i({
129
129
  "lintje-textarea__control": !0,
130
130
  "lintje-textarea__control--plain": this.variant === "plain",
131
131
  "is-error": !!e,
@@ -1 +1 @@
1
- export { x as LintjeTile } from "../chunks/base-rBLTcEIv.js";
1
+ export { x as LintjeTile } from "../chunks/base-Bg-IFOPG.js";
@@ -1,57 +1,65 @@
1
- import { $ as e, Bt as t, Gt as n, Ht as r, Kt as i, Z as a, et as o, f as s } from "../chunks/base-rBLTcEIv.js";
2
- import { r as c, t as l } from "../chunks/input-jQVTln7H.js";
1
+ import { $ as e, Bt as t, G as n, Gt as r, Ht as i, Z as a, et as o, f as s, qt as c } from "../chunks/base-Bg-IFOPG.js";
2
+ import { r as l, t as u } from "../chunks/input-BtuNFSWk.js";
3
3
  //#region src/components/inputs/time-input/time-input.css?inline
4
- var u = ":host {\n display: block;\n min-width: 0;\n width: 120px;\n}\n:host([hidden]) { display: none; }\n:host([stacked]) {\n width: 100%;\n --h-control: var(--h-touch);\n}\n@media (max-width: 767px) {\n :host {\n width: 100%;\n --h-control: var(--h-touch);\n }\n}\n\n/* --- */\n\n.lintje-time-input { position: relative; display: flex; align-items: center; }\n.lintje-time-input__control {\n width: 100%; height: var(--h-control);\n padding: 0 var(--space-10) 0 14px;\n border: 1px solid var(--color-border-field);\n background: var(--color-bg-surface);\n color: var(--color-text-primary);\n font-size: 1rem;\n font-variant-numeric: tabular-nums;\n border-radius: var(--radius);\n}\n.lintje-time-input__control::placeholder { color: var(--color-text-placeholder); opacity: 1; }\n.lintje-time-input__control.is-error { border: 2px solid var(--color-error); }\n/* Disabled wins over error: after it, the whole border back to 1 px strong. */\n.lintje-time-input__control:disabled {\n border: 1px solid var(--color-border-strong);\n background: var(--color-bg-subtle);\n color: var(--color-text-disabled);\n cursor: not-allowed;\n}\n/* A sign, not a button: the pointer goes through it to the field. */\n.lintje-time-input__icon {\n position: absolute; right: var(--space-3);\n color: var(--color-text-muted);\n pointer-events: none;\n}\n.lintje-time-input__control:disabled + .lintje-time-input__icon { color: var(--color-text-disabled); }\n", d = 1440, f = /^(\d{1,2})[:.](\d{2})$/, p = /^\d{1,4}$/, m = /^(\d{2}):(\d{2})$/, h = (e) => String(e).padStart(2, "0");
5
- function g(e, t) {
6
- return !Number.isInteger(e) || !Number.isInteger(t) || e < 0 || e > 23 || t < 0 || t > 59 ? null : `${h(e)}:${h(t)}`;
4
+ var d = "/* The time input: a text field with a list button, and the list in a `lintje-popover`. */\n:host {\n display: block;\n min-width: 0;\n width: 120px;\n}\n:host([hidden]) { display: none; }\n:host([stacked]) {\n width: 100%;\n --h-control: var(--h-touch);\n}\n@media (max-width: 767px) {\n :host {\n width: 100%;\n --h-control: var(--h-touch);\n }\n}\n\n/* --- */\n\n/* --- The field ----------------------------------------------------------- */\n.lintje-time-input { position: relative; display: flex; align-items: center; }\n.lintje-time-input__control {\n width: 100%; height: var(--h-control);\n padding: 0 calc(var(--h-control) - 2px + var(--space-2)) 0 14px;\n border: 1px solid var(--color-border-field);\n background: var(--color-bg-surface);\n color: var(--color-text-primary);\n font-size: 1rem;\n font-variant-numeric: tabular-nums;\n border-radius: var(--radius);\n}\n.lintje-time-input__control::placeholder { color: var(--color-text-placeholder); opacity: 1; }\n.lintje-time-input__control.is-error { border: 2px solid var(--color-error); }\n/* Disabled wins over error: after it, the whole border back to 1 px strong. */\n.lintje-time-input__control:disabled {\n border: 1px solid var(--color-border-strong);\n background: var(--color-bg-subtle);\n color: var(--color-text-disabled);\n cursor: not-allowed;\n}\n\n.lintje-time-input__toggle {\n position: absolute; top: 1px; right: 1px;\n width: calc(var(--h-control) - 2px); height: calc(var(--h-control) - 2px);\n display: flex; align-items: center; justify-content: center;\n border-left: 1px solid var(--color-border-default);\n background: transparent;\n color: var(--color-accent-text);\n transition: background var(--dur-hover) var(--ease-in-motion);\n}\n/* A transparent hit area reaches the target height, never to the left where the typing part is. */\n.lintje-time-input__toggle::after {\n content: '';\n position: absolute;\n inset: min(0px, calc((100% - var(--h-target)) / 2)) min(0px, calc(100% - var(--h-target)))\n min(0px, calc((100% - var(--h-target)) / 2)) 0;\n}\n/* The button steps in past the 2 px error border; a disabled field has 1 px again. */\n.lintje-time-input__control.is-error:not(:disabled) + .lintje-time-input__toggle {\n top: 2px; right: 2px;\n width: calc(var(--h-control) - 4px); height: calc(var(--h-control) - 4px);\n}\n.lintje-time-input__toggle:hover:not(:disabled) { background: var(--color-bg-selected); }\n.lintje-time-input__toggle:disabled { color: var(--color-text-disabled); cursor: not-allowed; }\n\n/* --- The list ------------------------------------------------------------ */\n/* A dense list (`--h-option`): at most seven rows in view, then it scrolls. */\n.lintje-time-input__panel { padding: var(--space-1) 0; }\n.lintje-time-input__list {\n max-height: calc(7 * var(--h-option));\n overflow-y: auto;\n font: var(--text-ui);\n}\n.lintje-time-input__option {\n display: flex; align-items: center;\n width: 100%;\n min-height: var(--h-option);\n padding: 0 14px;\n background: transparent;\n color: var(--color-text-primary);\n font-variant-numeric: tabular-nums;\n cursor: pointer;\n transition: background var(--dur-hover) var(--ease-in-motion);\n}\n.lintje-time-input__option:hover { background: var(--color-bg-subtle); }\n.lintje-time-input__option.is-selected { background: var(--color-bg-selected); font-weight: 700; }\n/* The fill alone is about 1.1:1, so the focus ring stands inside the row. */\n.lintje-time-input__option:focus-visible {\n outline: var(--focus-width) solid var(--color-focus);\n outline-offset: calc(var(--focus-width) * -1);\n}\n\n/* Forced colours drop fills: the chosen row takes an edge inside the row, so none changes size. */\n@media (forced-colors: active) {\n .lintje-time-input__option.is-selected { outline: 2px solid Highlight; outline-offset: -2px; }\n .lintje-time-input__option:focus-visible { outline-color: Highlight; }\n}\n", f = 1440, p = /^(\d{1,2})[:.](\d{2})$/, m = /^\d{1,4}$/, h = /^(\d{2}):(\d{2})$/, g = (e) => String(e).padStart(2, "0");
5
+ function _(e, t) {
6
+ return !Number.isInteger(e) || !Number.isInteger(t) || e < 0 || e > 23 || t < 0 || t > 59 ? null : `${g(e)}:${g(t)}`;
7
7
  }
8
- function _(e) {
9
- let t = e ? m.exec(e) : null;
8
+ function v(e) {
9
+ let t = e ? h.exec(e) : null;
10
10
  if (!t) return null;
11
11
  let [n, r] = [Number(t[1]), Number(t[2])];
12
- return g(n, r) ? n * 60 + r : null;
13
- }
14
- var v = (e) => _(e) !== null;
15
- function y(e) {
16
- let t = (e % d + d) % d;
17
- return `${h(Math.floor(t / 60))}:${h(t % 60)}`;
12
+ return _(n, r) ? n * 60 + r : null;
18
13
  }
14
+ var y = (e) => v(e) !== null;
19
15
  function b(e) {
16
+ let t = (e % f + f) % f;
17
+ return `${g(Math.floor(t / 60))}:${g(t % 60)}`;
18
+ }
19
+ function x(e) {
20
20
  let t = e.trim();
21
21
  if (t === "") return { kind: "empty" };
22
- let n, r, i = f.exec(t);
22
+ let n, r, i = p.exec(t);
23
23
  if (i) n = Number(i[1]), r = Number(i[2]);
24
- else if (p.test(t)) {
24
+ else if (m.test(t)) {
25
25
  let e = t.length <= 2 ? `${t}00` : t;
26
26
  n = Number(e.slice(0, -2)), r = Number(e.slice(-2));
27
27
  } else return { kind: "invalid" };
28
- let a = g(n, r);
28
+ let a = _(n, r);
29
29
  return a ? {
30
30
  kind: "ok",
31
31
  time: a
32
32
  } : { kind: "invalid" };
33
33
  }
34
- function x(e, t) {
35
- return y((_(e) ?? 0) + t);
34
+ function S(e, t) {
35
+ return b((v(e) ?? 0) + t);
36
36
  }
37
- function S(e, t = /* @__PURE__ */ new Date()) {
37
+ function C(e, t = /* @__PURE__ */ new Date()) {
38
38
  let n = t.getHours() * 60 + t.getMinutes(), r = e > 0 ? e : 1;
39
- return y(Math.round(n / r) * r);
39
+ return b(Math.round(n / r) * r);
40
+ }
41
+ function w(e, t, n) {
42
+ return y(t) && e < t ? t : y(n) && e > n ? n : e;
40
43
  }
41
- function C(e, t, n) {
42
- return v(t) && e < t ? t : v(n) && e > n ? n : e;
44
+ function T(e, t, n = 15) {
45
+ let r = n >= 1 ? Math.floor(n) : 1, i = v(e) ?? 0, a = v(t) ?? 1439, o = [];
46
+ for (let e = i; e <= a; e += r) o.push(b(e));
47
+ return o;
48
+ }
49
+ function E(e, t) {
50
+ return e.find((e) => e >= t) ?? e[e.length - 1] ?? "";
43
51
  }
44
52
  //#endregion
45
53
  //#region src/components/inputs/time-input/time-input.ts
46
- var w = class extends c {
54
+ var D = class extends l {
47
55
  constructor(...e) {
48
- super(...e), this.value = null, this.step = 15, this.placeholder = "", this.stacked = !1, this.hint = "uu:mm", this.text = "", this.problem = "";
56
+ super(...e), this.value = null, this.step = 15, this.placeholder = "", this.stacked = !1, this.open = !1, this.hint = "uu:mm", this.text = "", this.problem = "", this.focusTime = "";
49
57
  }
50
58
  static {
51
59
  this.styles = [
52
60
  e,
53
- r(l),
54
- r(u)
61
+ i(u),
62
+ i(d)
55
63
  ];
56
64
  }
57
65
  static {
@@ -65,8 +73,13 @@ var w = class extends c {
65
73
  type: Boolean,
66
74
  reflect: !0
67
75
  },
76
+ open: {
77
+ type: Boolean,
78
+ reflect: !0
79
+ },
68
80
  text: { state: !0 },
69
- problem: { state: !0 }
81
+ problem: { state: !0 },
82
+ focusTime: { state: !0 }
70
83
  };
71
84
  }
72
85
  get message() {
@@ -75,17 +88,20 @@ var w = class extends c {
75
88
  get footMessage() {
76
89
  return this.message;
77
90
  }
91
+ get times() {
92
+ return T(this.min, this.max, this.step);
93
+ }
78
94
  willUpdate(e) {
79
- super.willUpdate(e), e.has("value") && (this.text = v(this.value) ? this.value : "", this.problem = "");
95
+ super.willUpdate(e), e.has("value") && (this.text = y(this.value) ? this.value : "", this.problem = "");
80
96
  }
81
97
  outOfBounds(e) {
82
- return v(this.min) && e < this.min ? `Kies een tijd op of na ${this.min}` : v(this.max) && e > this.max ? `Kies een tijd op of voor ${this.max}` : "";
98
+ return y(this.min) && e < this.min ? `Kies een tijd op of na ${this.min}` : y(this.max) && e > this.max ? `Kies een tijd op of voor ${this.max}` : "";
83
99
  }
84
100
  choose(e) {
85
101
  this.problem = "", this.text = e ?? "", e !== this.value && (this.value = e, this.commit(e));
86
102
  }
87
103
  onChange(e) {
88
- let t = e.target.value, n = b(t);
104
+ let t = e.target.value, n = x(t);
89
105
  if (n.kind === "empty") return this.choose(null);
90
106
  if (this.text = t, n.kind === "invalid") {
91
107
  this.problem = "Vul een tijd in als uu:mm";
@@ -95,6 +111,10 @@ var w = class extends c {
95
111
  r ? this.problem = r : this.choose(n.time);
96
112
  }
97
113
  onKeydown(e) {
114
+ if (e.altKey && e.key === "ArrowDown") {
115
+ e.preventDefault(), this.openList();
116
+ return;
117
+ }
98
118
  let t = {
99
119
  ArrowUp: 1,
100
120
  ArrowDown: -1,
@@ -103,12 +123,72 @@ var w = class extends c {
103
123
  }[e.key];
104
124
  if (t === void 0) return;
105
125
  e.preventDefault();
106
- let n = b(e.target.value), r = n.kind === "ok" ? n.time : this.value, i = r === null ? S(this.step) : x(r, t);
107
- this.choose(C(i, this.min, this.max));
126
+ let n = x(e.target.value), r = n.kind === "ok" ? n.time : this.value, i = r === null ? C(this.step) : S(r, t);
127
+ this.choose(w(i, this.min, this.max));
128
+ }
129
+ openList() {
130
+ if (this.disabled) return;
131
+ let e = this.times;
132
+ e.length && (this.focusTime = E(e, this.value ?? C(this.step)), this.open = !0, this.focusOption("center"));
133
+ }
134
+ toggle() {
135
+ this.open ? this.open = !1 : this.openList();
136
+ }
137
+ async focusOption(e = "nearest") {
138
+ await this.updateComplete;
139
+ let t = this.renderRoot.querySelector(".lintje-time-input__option[tabindex=\"0\"]");
140
+ t?.focus({ preventScroll: !0 }), t?.scrollIntoView?.({ block: e });
141
+ }
142
+ onPopoverClose(e) {
143
+ e.stopPropagation(), this.open = !1, e.detail?.reason === "escape" && this.renderRoot.querySelector(".lintje-time-input__toggle")?.focus();
144
+ }
145
+ onFocusOut(e) {
146
+ let t = e.relatedTarget;
147
+ this.open && t && !this.renderRoot.contains(t) && !n(this, t) && (this.open = !1);
148
+ }
149
+ pick(e) {
150
+ this.choose(e), this.open = !1, this.renderRoot.querySelector(".lintje-time-input__control")?.focus();
151
+ }
152
+ onListKeydown(e) {
153
+ let t = this.times, n = Math.max(1, Math.round(60 / this.step)), r = {
154
+ ArrowDown: 1,
155
+ ArrowUp: -1,
156
+ PageDown: n,
157
+ PageUp: -n,
158
+ Home: -t.length,
159
+ End: t.length
160
+ }[e.key];
161
+ if (r === void 0) return;
162
+ e.preventDefault();
163
+ let i = t.indexOf(this.focusTime), a = Math.min(t.length - 1, Math.max(0, i + r));
164
+ this.focusTime = t[a], this.focusOption();
165
+ }
166
+ renderList() {
167
+ return c`<div class="lintje-time-input__panel"><div
168
+ class="lintje-time-input__list"
169
+ role="listbox"
170
+ tabindex="-1"
171
+ aria-label="Tijden"
172
+ @keydown=${this.onListKeydown}
173
+ >
174
+ ${this.times.map((e) => c`<button
175
+ type="button"
176
+ role="option"
177
+ class=${a({
178
+ "lintje-time-input__option": !0,
179
+ "is-selected": e === this.value
180
+ })}
181
+ tabindex=${e === this.focusTime ? "0" : "-1"}
182
+ aria-selected=${e === this.value ? "true" : "false"}
183
+ @click=${() => this.pick(e)}
184
+ >
185
+ ${e}
186
+ </button>`)}
187
+ </div></div>`;
108
188
  }
109
189
  render() {
110
190
  let e = this.message;
111
- return i`<div class="lintje-field">
191
+ return c`<div class="lintje-field" @focusout=${this.onFocusOut}>
112
192
  ${this.renderLabel(this.controlId)}
113
193
  <div class="lintje-time-input">
114
194
  <input
@@ -121,24 +201,38 @@ var w = class extends c {
121
201
  "is-error": !!e
122
202
  })}
123
203
  .value=${s(this.text)}
124
- placeholder=${this.placeholder || n}
204
+ placeholder=${this.placeholder || r}
125
205
  aria-labelledby=${this.labelId}
126
206
  aria-describedby=${this.describedBy}
127
- aria-invalid=${e ? "true" : n}
128
- aria-required=${this.required ? "true" : n}
207
+ aria-invalid=${e ? "true" : r}
208
+ aria-required=${this.required ? "true" : r}
129
209
  ?disabled=${this.disabled}
130
210
  @change=${this.onChange}
131
211
  @keydown=${this.onKeydown}
132
212
  />
133
- ${o("functioneel-klok", {
134
- size: 18,
135
- className: "lintje-time-input__icon"
136
- })}
213
+ <button
214
+ type="button"
215
+ class="lintje-time-input__toggle"
216
+ aria-label="Tijden openen"
217
+ aria-haspopup="listbox"
218
+ aria-expanded=${this.open ? "true" : "false"}
219
+ ?disabled=${this.disabled}
220
+ @click=${this.toggle}
221
+ >
222
+ ${o("functioneel-klok", { size: 18 })}
223
+ </button>
137
224
  </div>
225
+ <lintje-popover
226
+ ?open=${this.open && !this.disabled}
227
+ match-width
228
+ @lintje-close=${this.onPopoverClose}
229
+ >
230
+ ${this.open ? this.renderList() : r}
231
+ </lintje-popover>
138
232
  ${this.renderFoot()}
139
233
  </div>`;
140
234
  }
141
235
  };
142
- t("lintje-time-input", w);
236
+ t("lintje-time-input", D);
143
237
  //#endregion
144
- export { w as LintjeTimeInput };
238
+ export { D as LintjeTimeInput };