@nldd/design-system 0.8.93 → 0.8.94

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 (312) hide show
  1. package/NOTICES.md +21 -1
  2. package/README.md +3 -3
  3. package/custom-elements.json +575 -96
  4. package/dist/components/actions/button/button.d.ts +8 -5
  5. package/dist/components/actions/button/button.d.ts.map +1 -1
  6. package/dist/components/actions/button/button.js +11 -5
  7. package/dist/components/actions/button/button.js.map +1 -1
  8. package/dist/components/actions/button/button.styles.d.ts.map +1 -1
  9. package/dist/components/actions/button/button.styles.js +41 -73
  10. package/dist/components/actions/button/button.styles.js.map +1 -1
  11. package/dist/components/actions/button/button.template.d.ts.map +1 -1
  12. package/dist/components/actions/button/button.template.js +1 -0
  13. package/dist/components/actions/button/button.template.js.map +1 -1
  14. package/dist/components/actions/button-bar/button-bar.d.ts +11 -4
  15. package/dist/components/actions/button-bar/button-bar.d.ts.map +1 -1
  16. package/dist/components/actions/button-bar/button-bar.js +25 -9
  17. package/dist/components/actions/button-bar/button-bar.js.map +1 -1
  18. package/dist/components/actions/button-bar/button-bar.styles.d.ts.map +1 -1
  19. package/dist/components/actions/button-bar/button-bar.styles.js +18 -3
  20. package/dist/components/actions/button-bar/button-bar.styles.js.map +1 -1
  21. package/dist/components/actions/icon-button/icon-button.d.ts +8 -5
  22. package/dist/components/actions/icon-button/icon-button.d.ts.map +1 -1
  23. package/dist/components/actions/icon-button/icon-button.js +11 -5
  24. package/dist/components/actions/icon-button/icon-button.js.map +1 -1
  25. package/dist/components/actions/icon-button/icon-button.styles.d.ts.map +1 -1
  26. package/dist/components/actions/icon-button/icon-button.styles.js +35 -61
  27. package/dist/components/actions/icon-button/icon-button.styles.js.map +1 -1
  28. package/dist/components/actions/icon-button/icon-button.template.d.ts.map +1 -1
  29. package/dist/components/actions/icon-button/icon-button.template.js +1 -0
  30. package/dist/components/actions/icon-button/icon-button.template.js.map +1 -1
  31. package/dist/components/actions/menu/menu.d.ts +17 -2
  32. package/dist/components/actions/menu/menu.d.ts.map +1 -1
  33. package/dist/components/actions/menu/menu.js +34 -11
  34. package/dist/components/actions/menu/menu.js.map +1 -1
  35. package/dist/components/actions/menu/menu.template.d.ts.map +1 -1
  36. package/dist/components/actions/menu/menu.template.js +5 -3
  37. package/dist/components/actions/menu/menu.template.js.map +1 -1
  38. package/dist/components/actions/split-button/split-button.d.ts +2 -2
  39. package/dist/components/actions/split-button/split-button.d.ts.map +1 -1
  40. package/dist/components/actions/split-button/split-button.js +5 -4
  41. package/dist/components/actions/split-button/split-button.js.map +1 -1
  42. package/dist/components/actions/split-button/split-button.styles.d.ts.map +1 -1
  43. package/dist/components/actions/split-button/split-button.styles.js +18 -3
  44. package/dist/components/actions/split-button/split-button.styles.js.map +1 -1
  45. package/dist/components/actions/split-button/split-button.template.js +2 -2
  46. package/dist/components/actions/split-button/split-button.template.js.map +1 -1
  47. package/dist/components/actions/toolbar/toolbar.d.ts.map +1 -1
  48. package/dist/components/actions/toolbar/toolbar.js +3 -2
  49. package/dist/components/actions/toolbar/toolbar.js.map +1 -1
  50. package/dist/components/components.js +1132 -461
  51. package/dist/components/content/avatar/avatar.js +1 -1
  52. package/dist/components/content/avatar/avatar.js.map +1 -1
  53. package/dist/components/content/code-viewer/code-viewer.d.ts +2 -2
  54. package/dist/components/content/code-viewer/code-viewer.d.ts.map +1 -1
  55. package/dist/components/content/code-viewer/code-viewer.js +10 -6
  56. package/dist/components/content/code-viewer/code-viewer.js.map +1 -1
  57. package/dist/components/content/code-viewer/code-viewer.styles.js +6 -6
  58. package/dist/components/content/image/image.d.ts.map +1 -1
  59. package/dist/components/content/image/image.js +2 -1
  60. package/dist/components/content/image/image.js.map +1 -1
  61. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.d.ts +3 -3
  62. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.d.ts.map +1 -1
  63. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.js +3 -3
  64. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.js.map +1 -1
  65. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.styles.js +7 -7
  66. package/dist/components/content/rich-text/rich-text.d.ts +2 -0
  67. package/dist/components/content/rich-text/rich-text.d.ts.map +1 -1
  68. package/dist/components/content/rich-text/rich-text.js +8 -1
  69. package/dist/components/content/rich-text/rich-text.js.map +1 -1
  70. package/dist/components/content/text/text.styles.d.ts.map +1 -1
  71. package/dist/components/content/text/text.styles.js +1 -0
  72. package/dist/components/content/text/text.styles.js.map +1 -1
  73. package/dist/components/content/token/token.d.ts.map +1 -1
  74. package/dist/components/content/token/token.js +2 -1
  75. package/dist/components/content/token/token.js.map +1 -1
  76. package/dist/components/content/token/token.template.js +2 -2
  77. package/dist/components/forms/form-actions/form-actions.d.ts +1 -1
  78. package/dist/components/forms/form-actions/form-actions.js +1 -1
  79. package/dist/components/{icon-button-hO6k8W63.js → icon-button-DHzLMmj0.js} +45 -67
  80. package/dist/components/index.d.ts +1 -0
  81. package/dist/components/index.d.ts.map +1 -1
  82. package/dist/components/index.js +2 -0
  83. package/dist/components/index.js.map +1 -1
  84. package/dist/components/inputs/code-editor/code-editor.d.ts +5 -5
  85. package/dist/components/inputs/code-editor/code-editor.d.ts.map +1 -1
  86. package/dist/components/inputs/code-editor/code-editor.js +5 -5
  87. package/dist/components/inputs/code-editor/code-editor.js.map +1 -1
  88. package/dist/components/inputs/code-editor/code-editor.styles.js +3 -3
  89. package/dist/components/inputs/combo-box/combo-box.d.ts +43 -2
  90. package/dist/components/inputs/combo-box/combo-box.d.ts.map +1 -1
  91. package/dist/components/inputs/combo-box/combo-box.js +115 -40
  92. package/dist/components/inputs/combo-box/combo-box.js.map +1 -1
  93. package/dist/components/inputs/combo-box/combo-box.template.js +2 -2
  94. package/dist/components/inputs/date-field/date-field.d.ts.map +1 -1
  95. package/dist/components/inputs/date-field/date-field.js +2 -1
  96. package/dist/components/inputs/date-field/date-field.js.map +1 -1
  97. package/dist/components/inputs/date-field/date-field.template.js +1 -1
  98. package/dist/components/inputs/date-picker/date-picker.template.js +2 -2
  99. package/dist/components/inputs/date-picker/date-picker.template.js.map +1 -1
  100. package/dist/components/inputs/dropdown/dropdown.d.ts +0 -2
  101. package/dist/components/inputs/dropdown/dropdown.d.ts.map +1 -1
  102. package/dist/components/inputs/dropdown/dropdown.js +1 -13
  103. package/dist/components/inputs/dropdown/dropdown.js.map +1 -1
  104. package/dist/components/inputs/dropdown/dropdown.styles.d.ts.map +1 -1
  105. package/dist/components/inputs/dropdown/dropdown.styles.js +24 -12
  106. package/dist/components/inputs/dropdown/dropdown.styles.js.map +1 -1
  107. package/dist/components/inputs/dropdown/dropdown.template.d.ts.map +1 -1
  108. package/dist/components/inputs/dropdown/dropdown.template.js +0 -1
  109. package/dist/components/inputs/dropdown/dropdown.template.js.map +1 -1
  110. package/dist/components/inputs/file-field/file-field.d.ts.map +1 -1
  111. package/dist/components/inputs/file-field/file-field.js +2 -7
  112. package/dist/components/inputs/file-field/file-field.js.map +1 -1
  113. package/dist/components/inputs/file-field/file-field.template.js +2 -2
  114. package/dist/components/inputs/number-field/number-field.d.ts.map +1 -1
  115. package/dist/components/inputs/number-field/number-field.js +2 -1
  116. package/dist/components/inputs/number-field/number-field.js.map +1 -1
  117. package/dist/components/inputs/number-field/number-field.template.js +2 -2
  118. package/dist/components/inputs/search-field/search-field.d.ts.map +1 -1
  119. package/dist/components/inputs/search-field/search-field.js +2 -1
  120. package/dist/components/inputs/search-field/search-field.js.map +1 -1
  121. package/dist/components/inputs/search-field/search-field.template.js +2 -2
  122. package/dist/components/inputs/segmented-control/segmented-control.d.ts +6 -0
  123. package/dist/components/inputs/segmented-control/segmented-control.d.ts.map +1 -1
  124. package/dist/components/inputs/segmented-control/segmented-control.js +13 -0
  125. package/dist/components/inputs/segmented-control/segmented-control.js.map +1 -1
  126. package/dist/components/inputs/segmented-control/segmented-control.styles.d.ts.map +1 -1
  127. package/dist/components/inputs/segmented-control/segmented-control.styles.js +54 -16
  128. package/dist/components/inputs/segmented-control/segmented-control.styles.js.map +1 -1
  129. package/dist/components/inputs/stepper/stepper.d.ts.map +1 -1
  130. package/dist/components/inputs/stepper/stepper.js +2 -1
  131. package/dist/components/inputs/stepper/stepper.js.map +1 -1
  132. package/dist/components/inputs/stepper/stepper.template.js +2 -2
  133. package/dist/components/inputs/text-editor/text-editor.annotations.d.ts.map +1 -1
  134. package/dist/components/inputs/text-editor/text-editor.annotations.js +6 -4
  135. package/dist/components/inputs/text-editor/text-editor.annotations.js.map +1 -1
  136. package/dist/components/inputs/text-editor/text-editor.d.ts +27 -64
  137. package/dist/components/inputs/text-editor/text-editor.d.ts.map +1 -1
  138. package/dist/components/inputs/text-editor/text-editor.i18n.d.ts +2 -0
  139. package/dist/components/inputs/text-editor/text-editor.i18n.d.ts.map +1 -1
  140. package/dist/components/inputs/text-editor/text-editor.i18n.js +5 -0
  141. package/dist/components/inputs/text-editor/text-editor.i18n.js.map +1 -1
  142. package/dist/components/inputs/text-editor/text-editor.js +87 -20
  143. package/dist/components/inputs/text-editor/text-editor.js.map +1 -1
  144. package/dist/components/inputs/text-editor/text-editor.labels.d.ts +4 -0
  145. package/dist/components/inputs/text-editor/text-editor.labels.d.ts.map +1 -0
  146. package/dist/components/inputs/text-editor/text-editor.labels.js +5 -0
  147. package/dist/components/inputs/text-editor/text-editor.labels.js.map +1 -0
  148. package/dist/components/inputs/text-editor/text-editor.links.d.ts.map +1 -1
  149. package/dist/components/inputs/text-editor/text-editor.links.js +6 -4
  150. package/dist/components/inputs/text-editor/text-editor.links.js.map +1 -1
  151. package/dist/components/inputs/text-editor/text-editor.markdown.d.ts.map +1 -1
  152. package/dist/components/inputs/text-editor/text-editor.markdown.js +5 -1
  153. package/dist/components/inputs/text-editor/text-editor.markdown.js.map +1 -1
  154. package/dist/components/inputs/text-editor/text-editor.mentions.d.ts +27 -3
  155. package/dist/components/inputs/text-editor/text-editor.mentions.d.ts.map +1 -1
  156. package/dist/components/inputs/text-editor/text-editor.mentions.js +144 -25
  157. package/dist/components/inputs/text-editor/text-editor.mentions.js.map +1 -1
  158. package/dist/components/inputs/text-editor/text-editor.spellcheck.d.ts +11 -0
  159. package/dist/components/inputs/text-editor/text-editor.spellcheck.d.ts.map +1 -0
  160. package/dist/components/inputs/text-editor/text-editor.spellcheck.js +134 -0
  161. package/dist/components/inputs/text-editor/text-editor.spellcheck.js.map +1 -0
  162. package/dist/components/inputs/text-editor/text-editor.styles.d.ts.map +1 -1
  163. package/dist/components/inputs/text-editor/text-editor.styles.js +9 -3
  164. package/dist/components/inputs/text-editor/text-editor.styles.js.map +1 -1
  165. package/dist/components/inputs/time-field/time-field.d.ts.map +1 -1
  166. package/dist/components/inputs/time-field/time-field.js +2 -1
  167. package/dist/components/inputs/time-field/time-field.js.map +1 -1
  168. package/dist/components/inputs/time-field/time-field.template.js +2 -2
  169. package/dist/components/inputs/time-picker/time-picker.d.ts.map +1 -1
  170. package/dist/components/inputs/time-picker/time-picker.js +2 -1
  171. package/dist/components/inputs/time-picker/time-picker.js.map +1 -1
  172. package/dist/components/inputs/toggle-button/toggle-button.d.ts +12 -0
  173. package/dist/components/inputs/toggle-button/toggle-button.d.ts.map +1 -1
  174. package/dist/components/inputs/toggle-button/toggle-button.js +17 -0
  175. package/dist/components/inputs/toggle-button/toggle-button.js.map +1 -1
  176. package/dist/components/inputs/toggle-button/toggle-button.styles.d.ts.map +1 -1
  177. package/dist/components/inputs/toggle-button/toggle-button.styles.js +99 -12
  178. package/dist/components/inputs/toggle-button/toggle-button.styles.js.map +1 -1
  179. package/dist/components/inputs/toggle-button/toggle-button.template.d.ts.map +1 -1
  180. package/dist/components/inputs/toggle-button/toggle-button.template.js +3 -2
  181. package/dist/components/inputs/toggle-button/toggle-button.template.js.map +1 -1
  182. package/dist/components/inputs/toggle-button-group/toggle-button-group.d.ts +4 -2
  183. package/dist/components/inputs/toggle-button-group/toggle-button-group.d.ts.map +1 -1
  184. package/dist/components/inputs/toggle-button-group/toggle-button-group.js +8 -2
  185. package/dist/components/inputs/toggle-button-group/toggle-button-group.js.map +1 -1
  186. package/dist/components/inputs/token-field/token-field.d.ts +26 -1
  187. package/dist/components/inputs/token-field/token-field.d.ts.map +1 -1
  188. package/dist/components/inputs/token-field/token-field.js +59 -6
  189. package/dist/components/inputs/token-field/token-field.js.map +1 -1
  190. package/dist/components/inputs/token-field/token-field.template.js +1 -1
  191. package/dist/components/layout/card/card.d.ts +3 -0
  192. package/dist/components/layout/card/card.d.ts.map +1 -1
  193. package/dist/components/layout/card/card.js +3 -0
  194. package/dist/components/layout/card/card.js.map +1 -1
  195. package/dist/components/layout/card/card.styles.d.ts.map +1 -1
  196. package/dist/components/layout/card/card.styles.js +22 -2
  197. package/dist/components/layout/card/card.styles.js.map +1 -1
  198. package/dist/components/layout/collection/collection.d.ts.map +1 -1
  199. package/dist/components/layout/collection/collection.js +2 -1
  200. package/dist/components/layout/collection/collection.js.map +1 -1
  201. package/dist/components/layout/collection/collection.template.js +1 -1
  202. package/dist/components/layout/page-footer/page-footer.d.ts +0 -2
  203. package/dist/components/layout/page-footer/page-footer.d.ts.map +1 -1
  204. package/dist/components/layout/page-footer/page-footer.js +4 -19
  205. package/dist/components/layout/page-footer/page-footer.js.map +1 -1
  206. package/dist/components/layout/page-sections/sidebar-section/sidebar-section.d.ts.map +1 -1
  207. package/dist/components/layout/page-sections/sidebar-section/sidebar-section.js +2 -1
  208. package/dist/components/layout/page-sections/sidebar-section/sidebar-section.js.map +1 -1
  209. package/dist/components/layout/popover/popover.d.ts.map +1 -1
  210. package/dist/components/layout/popover/popover.js +2 -1
  211. package/dist/components/layout/popover/popover.js.map +1 -1
  212. package/dist/components/layout/window/window.d.ts.map +1 -1
  213. package/dist/components/layout/window/window.js +2 -1
  214. package/dist/components/layout/window/window.js.map +1 -1
  215. package/dist/components/lists-and-tables/cells/drag-handle-cell/drag-handle-cell.d.ts.map +1 -1
  216. package/dist/components/lists-and-tables/cells/drag-handle-cell/drag-handle-cell.js +2 -1
  217. package/dist/components/lists-and-tables/cells/drag-handle-cell/drag-handle-cell.js.map +1 -1
  218. package/dist/components/lists-and-tables/cells/timeline-track-cell/timeline-track-cell.d.ts +7 -7
  219. package/dist/components/lists-and-tables/cells/timeline-track-cell/timeline-track-cell.d.ts.map +1 -1
  220. package/dist/components/lists-and-tables/cells/timeline-track-cell/timeline-track-cell.js +9 -9
  221. package/dist/components/lists-and-tables/cells/timeline-track-cell/timeline-track-cell.js.map +1 -1
  222. package/dist/components/lists-and-tables/cells/timeline-track-cell/timeline-track-cell.styles.js +5 -5
  223. package/dist/components/lists-and-tables/cells/timeline-track-cell/timeline-track-cell.template.js +1 -1
  224. package/dist/components/lists-and-tables/cells/timeline-track-cell/timeline-track-cell.template.js.map +1 -1
  225. package/dist/components/lists-and-tables/list/list.d.ts +11 -8
  226. package/dist/components/lists-and-tables/list/list.d.ts.map +1 -1
  227. package/dist/components/lists-and-tables/list/list.js +31 -31
  228. package/dist/components/lists-and-tables/list/list.js.map +1 -1
  229. package/dist/components/lists-and-tables/list/list.styles.js +5 -5
  230. package/dist/components/lists-and-tables/list/list.template.js +1 -1
  231. package/dist/components/lists-and-tables/list-item/list-item.d.ts +4 -4
  232. package/dist/components/lists-and-tables/list-item/list-item.d.ts.map +1 -1
  233. package/dist/components/lists-and-tables/list-item/list-item.js +10 -10
  234. package/dist/components/lists-and-tables/list-item/list-item.js.map +1 -1
  235. package/dist/components/lists-and-tables/table/table.d.ts +2 -0
  236. package/dist/components/lists-and-tables/table/table.d.ts.map +1 -1
  237. package/dist/components/lists-and-tables/table/table.js +10 -7
  238. package/dist/components/lists-and-tables/table/table.js.map +1 -1
  239. package/dist/components/navigation/breadcrumbs/breadcrumbs.d.ts +0 -2
  240. package/dist/components/navigation/breadcrumbs/breadcrumbs.d.ts.map +1 -1
  241. package/dist/components/navigation/breadcrumbs/breadcrumbs.js +4 -19
  242. package/dist/components/navigation/breadcrumbs/breadcrumbs.js.map +1 -1
  243. package/dist/components/navigation/document-tab-bar/document-tab-bar.template.js +1 -1
  244. package/dist/components/navigation/menu-bar/menu-bar.js +1 -1
  245. package/dist/components/navigation/menu-bar/menu-bar.js.map +1 -1
  246. package/dist/components/navigation/pagination/pagination.d.ts +0 -3
  247. package/dist/components/navigation/pagination/pagination.d.ts.map +1 -1
  248. package/dist/components/navigation/pagination/pagination.js +2 -13
  249. package/dist/components/navigation/pagination/pagination.js.map +1 -1
  250. package/dist/components/navigation/pagination/pagination.template.js +2 -2
  251. package/dist/components/navigation/top-navigation-bar/top-navigation-bar.d.ts +12 -0
  252. package/dist/components/navigation/top-navigation-bar/top-navigation-bar.d.ts.map +1 -1
  253. package/dist/components/navigation/top-navigation-bar/top-navigation-bar.js +37 -2
  254. package/dist/components/navigation/top-navigation-bar/top-navigation-bar.js.map +1 -1
  255. package/dist/components/navigation/top-navigation-bar/top-navigation-bar.styles.d.ts.map +1 -1
  256. package/dist/components/navigation/top-navigation-bar/top-navigation-bar.styles.js +48 -3
  257. package/dist/components/navigation/top-navigation-bar/top-navigation-bar.styles.js.map +1 -1
  258. package/dist/components/navigation/top-title-bar/top-title-bar.template.js +3 -3
  259. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.d.ts.map +1 -1
  260. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.js +2 -1
  261. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.js.map +1 -1
  262. package/dist/components/status-and-feedback/banner/banner.d.ts.map +1 -1
  263. package/dist/components/status-and-feedback/banner/banner.js +2 -1
  264. package/dist/components/status-and-feedback/banner/banner.js.map +1 -1
  265. package/dist/components/status-and-feedback/banner/banner.template.js +1 -1
  266. package/dist/components/status-and-feedback/just-in-time-education/just-in-time-education.template.js +1 -1
  267. package/dist/components/status-and-feedback/notification/notification.template.js +1 -1
  268. package/dist/components/status-and-feedback/progress-bar/progress-bar.d.ts +4 -4
  269. package/dist/components/status-and-feedback/progress-bar/progress-bar.d.ts.map +1 -1
  270. package/dist/components/status-and-feedback/progress-bar/progress-bar.js +11 -10
  271. package/dist/components/status-and-feedback/progress-bar/progress-bar.js.map +1 -1
  272. package/dist/components/status-and-feedback/progress-bar/progress-bar.styles.js +6 -6
  273. package/dist/components/status-and-feedback/progress-bar/progress-bar.template.js +1 -1
  274. package/dist/components/status-and-feedback/progress-bar/progress-bar.template.js.map +1 -1
  275. package/dist/components/status-and-feedback/progress-circle/progress-circle.d.ts +6 -4
  276. package/dist/components/status-and-feedback/progress-circle/progress-circle.d.ts.map +1 -1
  277. package/dist/components/status-and-feedback/progress-circle/progress-circle.js +16 -13
  278. package/dist/components/status-and-feedback/progress-circle/progress-circle.js.map +1 -1
  279. package/dist/components/status-and-feedback/progress-circle/progress-circle.styles.js +3 -3
  280. package/dist/components/{with-translations-BAKFoEKy.js → with-translations-Dt2DTXJF.js} +40 -12
  281. package/dist/css/rich-text.css +5 -1
  282. package/dist/css/variables.css +30 -42
  283. package/dist/nldd.min.js +1053 -869
  284. package/dist/translations/en-US.d.ts +17 -0
  285. package/dist/translations/en-US.d.ts.map +1 -0
  286. package/dist/translations/en-US.js +185 -0
  287. package/dist/translations/en-US.js.map +1 -0
  288. package/dist/translations/fy.d.ts +20 -0
  289. package/dist/translations/fy.d.ts.map +1 -0
  290. package/dist/translations/fy.js +185 -0
  291. package/dist/translations/fy.js.map +1 -0
  292. package/dist/translations/nl.generated.d.ts +188 -0
  293. package/dist/translations/nl.generated.d.ts.map +1 -0
  294. package/dist/translations/nl.generated.js +101 -0
  295. package/dist/translations/nl.generated.js.map +1 -0
  296. package/dist/translations/pap-AW.d.ts +22 -0
  297. package/dist/translations/pap-AW.d.ts.map +1 -0
  298. package/dist/translations/pap-AW.js +185 -0
  299. package/dist/translations/pap-AW.js.map +1 -0
  300. package/dist/translations/pap-CW.d.ts +22 -0
  301. package/dist/translations/pap-CW.d.ts.map +1 -0
  302. package/dist/translations/pap-CW.js +185 -0
  303. package/dist/translations/pap-CW.js.map +1 -0
  304. package/dist/types/vue.d.ts +76 -38
  305. package/dist/utilities/translations.d.ts +37 -0
  306. package/dist/utilities/translations.d.ts.map +1 -0
  307. package/dist/utilities/translations.js +80 -0
  308. package/dist/utilities/translations.js.map +1 -0
  309. package/dist/utilities/with-translations.d.ts.map +1 -1
  310. package/dist/utilities/with-translations.js +2 -15
  311. package/dist/utilities/with-translations.js.map +1 -1
  312. package/package.json +29 -3
@@ -1,14 +1,14 @@
1
1
  import { t as __exportAll } from "./rolldown-runtime-D7D4PA-g.js";
2
2
  import { n as slottedReset, t as inheritedTextReset } from "./shadow-resets-aG-rgyNQ.js";
3
- import { n as linkRel, t as withTranslations } from "./with-translations-BAKFoEKy.js";
3
+ import { i as linkRel, n as setTranslations, r as translate, t as withTranslations } from "./with-translations-Dt2DTXJF.js";
4
4
  import { t as __decorate } from "./decorate-lwt_OrAG.js";
5
5
  import { t as reflectNonDefault } from "./reflect-non-default-OLaK60rT.js";
6
- import { i as PopupAnchorController, n as NLDDTooltip, r as NLDDActivityIndicator, t as NLDDIconButton } from "./icon-button-hO6k8W63.js";
6
+ import { i as PopupAnchorController, n as NLDDTooltip, r as NLDDActivityIndicator, t as NLDDIconButton } from "./icon-button-DHzLMmj0.js";
7
7
  import { t as NLDDIcon } from "./icon-DWNVcttg.js";
8
8
  import { n as isPointerMode, r as isTouchMode, t as isKeyboardMode } from "./input-modality-DhTeUxKi.js";
9
9
  import { t as breakpoints } from "./breakpoints-CkxsiRgH.js";
10
10
  import { t as VisibilityMixin } from "./visibility-mixin-BU1vIMW7.js";
11
- import { $ as layer, A as syntaxTree, B as Tree, C as indentNodeProp, Ct as countColumn, D as matchBrackets, E as languageDataProp, F as NodeProp, G as RectangleMarker, H as Decoration, I as NodeSet, J as drawSelection, K as ViewPlugin, L as NodeType, M as styleTags, N as tags, Q as keymap, S as getIndentation, St as combineConfig, T as indentUnit, U as Direction, V as parseMixed, W as EditorView, X as getDrawSelectionConfig, Y as dropCursor, _t as StateField, a as HighlightStyle, at as Annotation, b as foldService, c as Language, ct as Compartment, d as ParseContext, dt as Facet, et as lineNumbers, f as StreamLanguage, gt as StateEffect, h as defineLanguageFacet, it as tooltips, j as Tag, k as syntaxHighlighting, l as LanguageDescription, lt as EditorSelection, mt as RangeSetBuilder, nt as placeholder, o as IndentContext, ot as ChangeDesc, pt as Prec, q as WidgetType, st as ChangeSet, u as LanguageSupport, ut as EditorState, vt as Text, w as indentString, wt as findClusterBreak, x as getIndentUnit, y as foldNodeProp, yt as Transaction, z as Parser } from "./dist-Dn3c5gfb.js";
11
+ import { $ as layer, A as syntaxTree, B as Tree, C as indentNodeProp, Ct as countColumn, D as matchBrackets, E as languageDataProp, F as NodeProp, G as RectangleMarker, H as Decoration, I as NodeSet, J as drawSelection, K as ViewPlugin, L as NodeType, M as styleTags, N as tags, Q as keymap, S as getIndentation, St as combineConfig, T as indentUnit, U as Direction, V as parseMixed, W as EditorView, X as getDrawSelectionConfig, Y as dropCursor, _t as StateField, a as HighlightStyle, at as Annotation, b as foldService, c as Language, ct as Compartment, d as ParseContext, dt as Facet, et as lineNumbers, f as StreamLanguage, gt as StateEffect, h as defineLanguageFacet, it as tooltips, j as Tag, k as syntaxHighlighting, l as LanguageDescription, lt as EditorSelection, mt as RangeSetBuilder, nt as placeholder, o as IndentContext, ot as ChangeDesc, pt as Prec, q as WidgetType, rt as showTooltip, st as ChangeSet, u as LanguageSupport, ut as EditorState, vt as Text, w as indentString, wt as findClusterBreak, x as getIndentUnit, y as foldNodeProp, yt as Transaction, z as Parser } from "./dist-Dn3c5gfb.js";
12
12
  import { i as completionStatus, n as autocompletion, s as startCompletion, t as CompletionContext } from "./dist-BUu-NW5O.js";
13
13
  import { n as html$2, r as htmlCompletionSource } from "./dist-Dxn9Up8K.js";
14
14
  import { LitElement, css, html, nothing, svg, unsafeCSS } from "lit";
@@ -109,7 +109,7 @@ var buttonStyles = css`
109
109
  --_supporting-font: var(--semantics-buttons-lg-supporting-text-font);
110
110
  }
111
111
 
112
- :host([variant="neutral-base"]) {
112
+ :host([appearance="neutral-base"]) {
113
113
  --_background-color: var(--semantics-buttons-neutral-base-background-color);
114
114
  --_primary-content-color: var(--semantics-buttons-neutral-base-content-color);
115
115
  --_secondary-content-color: var(--semantics-buttons-neutral-base-content-secondary-color);
@@ -124,7 +124,7 @@ var buttonStyles = css`
124
124
  --_is-active-highlight-border-color: var(--semantics-buttons-neutral-base-is-active-highlight-border-color);
125
125
  }
126
126
 
127
- :host([variant="neutral-transparent"]) {
127
+ :host([appearance="neutral-transparent"]) {
128
128
  --_background-color: transparent;
129
129
  --_primary-content-color: var(--semantics-buttons-neutral-transparent-content-color);
130
130
  --_secondary-content-color: var(--semantics-buttons-neutral-transparent-content-secondary-color);
@@ -139,8 +139,8 @@ var buttonStyles = css`
139
139
  --_is-active-highlight-border-color: transparent;
140
140
  }
141
141
 
142
- :host([variant="accent-filled"]),
143
- :host([variant="primary"]) {
142
+ :host([appearance="accent-filled"]),
143
+ :host([appearance="primary"]) {
144
144
  --_background-color: var(--semantics-buttons-accent-filled-background-color);
145
145
  --_primary-content-color: var(--semantics-buttons-accent-filled-content-color);
146
146
  --_secondary-content-color: var(--semantics-buttons-accent-filled-content-secondary-color);
@@ -155,7 +155,7 @@ var buttonStyles = css`
155
155
  --_is-active-highlight-border-color: var(--semantics-buttons-accent-filled-is-active-highlight-border-color);
156
156
  }
157
157
 
158
- :host([variant="accent-transparent"]) {
158
+ :host([appearance="accent-transparent"]) {
159
159
  --_background-color: transparent;
160
160
  --_primary-content-color: var(--semantics-buttons-accent-transparent-content-color);
161
161
  --_secondary-content-color: var(--semantics-buttons-accent-transparent-content-secondary-color);
@@ -170,8 +170,8 @@ var buttonStyles = css`
170
170
  --_is-active-highlight-border-color: transparent;
171
171
  }
172
172
 
173
- :host([variant="critical-tinted"]),
174
- :host([variant="destructive"]) {
173
+ :host([appearance="critical-tinted"]),
174
+ :host([appearance="destructive"]) {
175
175
  --_background-color: var(--semantics-buttons-critical-tinted-background-color);
176
176
  --_primary-content-color: var(--semantics-buttons-critical-tinted-content-color);
177
177
  --_secondary-content-color: var(--semantics-buttons-critical-tinted-content-secondary-color);
@@ -186,7 +186,7 @@ var buttonStyles = css`
186
186
  --_is-active-highlight-border-color: var(--semantics-buttons-critical-tinted-is-active-highlight-border-color);
187
187
  }
188
188
 
189
- :host([variant="critical-transparent"]) {
189
+ :host([appearance="critical-transparent"]) {
190
190
  --_background-color: transparent;
191
191
  --_primary-content-color: var(--semantics-buttons-critical-transparent-content-color);
192
192
  --_secondary-content-color: var(--semantics-buttons-critical-transparent-content-secondary-color);
@@ -207,34 +207,36 @@ var buttonStyles = css`
207
207
  here on the host — inside a :root token it would freeze — with the
208
208
  tokens' white/black contrast flip as fallback. */
209
209
 
210
- :host([variant="inherit-tinted"]) {
211
- --_background-color: var(--semantics-buttons-inherit-tinted-background-color);
210
+ :host([appearance="inherit-tinted"]),
211
+ :host([expanded][appearance="inherit-tinted"]) {
212
+ --_background-color: var(--context-button-background-color, var(--semantics-buttons-inherit-tinted-background-color));
212
213
  --_primary-content-color: var(--semantics-buttons-inherit-tinted-content-color);
213
214
  --_secondary-content-color: var(--semantics-buttons-inherit-tinted-content-secondary-color);
214
215
  --_highlight-border-color: var(--semantics-buttons-inherit-tinted-highlight-border-color);
215
- --_is-hovered-background-color: var(--semantics-buttons-inherit-tinted-is-hovered-background-color);
216
- --_is-hovered-primary-content-color: var(--semantics-buttons-inherit-tinted-is-hovered-content-color);
217
- --_is-hovered-secondary-content-color: var(--semantics-buttons-inherit-tinted-is-hovered-content-secondary-color);
218
- --_is-hovered-highlight-border-color: var(--semantics-buttons-inherit-tinted-is-hovered-highlight-border-color);
219
- --_is-active-background-color: var(--semantics-buttons-inherit-tinted-is-active-background-color);
220
- --_is-active-primary-content-color: var(--semantics-buttons-inherit-tinted-is-active-content-color);
221
- --_is-active-secondary-content-color: var(--semantics-buttons-inherit-tinted-is-active-content-secondary-color);
222
- --_is-active-highlight-border-color: var(--semantics-buttons-inherit-tinted-is-active-highlight-border-color);
223
- }
224
-
225
- :host([variant="inherit-filled"]) {
216
+ --_is-hovered-background-color: var(--_background-color);
217
+ --_is-hovered-primary-content-color: var(--_primary-content-color);
218
+ --_is-hovered-secondary-content-color: var(--_secondary-content-color);
219
+ --_is-hovered-highlight-border-color: var(--_highlight-border-color);
220
+ --_is-active-background-color: var(--_background-color);
221
+ --_is-active-primary-content-color: var(--_primary-content-color);
222
+ --_is-active-secondary-content-color: var(--_secondary-content-color);
223
+ --_is-active-highlight-border-color: var(--_highlight-border-color);
224
+ }
225
+
226
+ :host([appearance="inherit-filled"]),
227
+ :host([expanded][appearance="inherit-filled"]) {
226
228
  --_background-color: var(--semantics-buttons-inherit-filled-background-color);
227
229
  --_primary-content-color: var(--context-parent-background-color, var(--semantics-buttons-inherit-filled-content-color));
228
230
  --_secondary-content-color: var(--semantics-buttons-inherit-filled-content-secondary-color);
229
231
  --_highlight-border-color: var(--semantics-buttons-inherit-filled-highlight-border-color);
230
- --_is-hovered-background-color: var(--semantics-buttons-inherit-filled-is-hovered-background-color);
231
- --_is-hovered-primary-content-color: var(--semantics-buttons-inherit-filled-is-hovered-content-color);
232
- --_is-hovered-secondary-content-color: var(--semantics-buttons-inherit-filled-is-hovered-content-secondary-color);
233
- --_is-hovered-highlight-border-color: var(--semantics-buttons-inherit-filled-is-hovered-highlight-border-color);
234
- --_is-active-background-color: var(--semantics-buttons-inherit-filled-is-active-background-color);
235
- --_is-active-primary-content-color: var(--semantics-buttons-inherit-filled-is-active-content-color);
236
- --_is-active-secondary-content-color: var(--semantics-buttons-inherit-filled-is-active-content-secondary-color);
237
- --_is-active-highlight-border-color: var(--semantics-buttons-inherit-filled-is-active-highlight-border-color);
232
+ --_is-hovered-background-color: var(--_background-color);
233
+ --_is-hovered-primary-content-color: var(--_primary-content-color);
234
+ --_is-hovered-secondary-content-color: var(--_secondary-content-color);
235
+ --_is-hovered-highlight-border-color: var(--_highlight-border-color);
236
+ --_is-active-background-color: var(--_background-color);
237
+ --_is-active-primary-content-color: var(--_primary-content-color);
238
+ --_is-active-secondary-content-color: var(--_secondary-content-color);
239
+ --_is-active-highlight-border-color: var(--_highlight-border-color);
238
240
  }
239
241
 
240
242
  /* For inherit-filled the inner button keeps the inherited on-color:
@@ -242,11 +244,11 @@ var buttonStyles = css`
242
244
  against it, and would otherwise self-reference the label. The label
243
245
  color moves to the content layer instead. The higher specificity of
244
246
  these rules deliberately pins the color through hover/active/expanded. */
245
- :host([variant="inherit-filled"]) .button {
247
+ :host([appearance="inherit-filled"]) .button {
246
248
  color: inherit;
247
249
  }
248
250
 
249
- :host([variant="inherit-filled"]) .button > * {
251
+ :host([appearance="inherit-filled"]) .button > * {
250
252
  color: var(--_primary-content-color);
251
253
  }
252
254
 
@@ -267,7 +269,7 @@ var buttonStyles = css`
267
269
  --_is-active-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-expanded-is-active-highlight-border-color);
268
270
  }
269
271
 
270
- :host([expanded][variant="neutral-base"]) {
272
+ :host([expanded][appearance="neutral-base"]) {
271
273
  --_background-color: var(--semantics-buttons-neutral-base-is-expanded-background-color);
272
274
  --_primary-content-color: var(--semantics-buttons-neutral-base-is-expanded-content-color);
273
275
  --_secondary-content-color: var(--semantics-buttons-neutral-base-is-expanded-content-secondary-color);
@@ -282,7 +284,7 @@ var buttonStyles = css`
282
284
  --_is-active-highlight-border-color: var(--semantics-buttons-neutral-base-is-expanded-is-active-highlight-border-color);
283
285
  }
284
286
 
285
- :host([expanded][variant="neutral-transparent"]) {
287
+ :host([expanded][appearance="neutral-transparent"]) {
286
288
  --_background-color: transparent;
287
289
  --_primary-content-color: var(--semantics-buttons-neutral-transparent-content-color);
288
290
  --_secondary-content-color: var(--semantics-buttons-neutral-transparent-content-secondary-color);
@@ -297,8 +299,8 @@ var buttonStyles = css`
297
299
  --_is-active-highlight-border-color: transparent;
298
300
  }
299
301
 
300
- :host([expanded][variant="accent-filled"]),
301
- :host([expanded][variant="primary"]) {
302
+ :host([expanded][appearance="accent-filled"]),
303
+ :host([expanded][appearance="primary"]) {
302
304
  --_background-color: var(--semantics-buttons-accent-filled-is-expanded-background-color);
303
305
  --_primary-content-color: var(--semantics-buttons-accent-filled-is-expanded-content-color);
304
306
  --_secondary-content-color: var(--semantics-buttons-accent-filled-is-expanded-content-secondary-color);
@@ -313,7 +315,7 @@ var buttonStyles = css`
313
315
  --_is-active-highlight-border-color: var(--semantics-buttons-accent-filled-is-expanded-is-active-highlight-border-color);
314
316
  }
315
317
 
316
- :host([expanded][variant="accent-transparent"]) {
318
+ :host([expanded][appearance="accent-transparent"]) {
317
319
  --_background-color: transparent;
318
320
  --_primary-content-color: var(--semantics-buttons-accent-transparent-content-color);
319
321
  --_secondary-content-color: var(--semantics-buttons-accent-transparent-content-secondary-color);
@@ -328,8 +330,8 @@ var buttonStyles = css`
328
330
  --_is-active-highlight-border-color: transparent;
329
331
  }
330
332
 
331
- :host([expanded][variant="critical-tinted"]),
332
- :host([expanded][variant="destructive"]) {
333
+ :host([expanded][appearance="critical-tinted"]),
334
+ :host([expanded][appearance="destructive"]) {
333
335
  --_background-color: var(--semantics-buttons-critical-tinted-is-expanded-background-color);
334
336
  --_primary-content-color: var(--semantics-buttons-critical-tinted-is-expanded-content-color);
335
337
  --_secondary-content-color: var(--semantics-buttons-critical-tinted-is-expanded-content-secondary-color);
@@ -344,7 +346,7 @@ var buttonStyles = css`
344
346
  --_is-active-highlight-border-color: var(--semantics-buttons-critical-tinted-is-expanded-is-active-highlight-border-color);
345
347
  }
346
348
 
347
- :host([expanded][variant="critical-transparent"]) {
349
+ :host([expanded][appearance="critical-transparent"]) {
348
350
  --_background-color: transparent;
349
351
  --_primary-content-color: var(--semantics-buttons-critical-transparent-content-color);
350
352
  --_secondary-content-color: var(--semantics-buttons-critical-transparent-content-secondary-color);
@@ -359,40 +361,6 @@ var buttonStyles = css`
359
361
  --_is-active-highlight-border-color: transparent;
360
362
  }
361
363
 
362
- /* The on-color variants keep their currentColor-derived content; expanded
363
- only deepens the background. Content is restated (not inherited from the
364
- resting block) because the default [expanded] block has equal
365
- specificity and later source order, so it would otherwise win. */
366
- :host([expanded][variant="inherit-tinted"]) {
367
- --_background-color: var(--semantics-buttons-inherit-tinted-is-expanded-background-color);
368
- --_primary-content-color: var(--semantics-buttons-inherit-tinted-is-expanded-content-color);
369
- --_secondary-content-color: var(--semantics-buttons-inherit-tinted-is-expanded-content-secondary-color);
370
- --_highlight-border-color: var(--semantics-buttons-inherit-tinted-is-expanded-highlight-border-color);
371
- --_is-hovered-background-color: var(--semantics-buttons-inherit-tinted-is-expanded-is-hovered-background-color);
372
- --_is-hovered-primary-content-color: var(--semantics-buttons-inherit-tinted-is-expanded-is-hovered-content-color);
373
- --_is-hovered-secondary-content-color: var(--semantics-buttons-inherit-tinted-is-expanded-is-hovered-content-secondary-color);
374
- --_is-hovered-highlight-border-color: var(--semantics-buttons-inherit-tinted-is-expanded-is-hovered-highlight-border-color);
375
- --_is-active-background-color: var(--semantics-buttons-inherit-tinted-is-expanded-is-active-background-color);
376
- --_is-active-primary-content-color: var(--semantics-buttons-inherit-tinted-is-expanded-is-active-content-color);
377
- --_is-active-secondary-content-color: var(--semantics-buttons-inherit-tinted-is-expanded-is-active-content-secondary-color);
378
- --_is-active-highlight-border-color: var(--semantics-buttons-inherit-tinted-is-expanded-is-active-highlight-border-color);
379
- }
380
-
381
- :host([expanded][variant="inherit-filled"]) {
382
- --_background-color: var(--semantics-buttons-inherit-filled-is-expanded-background-color);
383
- --_primary-content-color: var(--context-parent-background-color, var(--semantics-buttons-inherit-filled-is-expanded-content-color));
384
- --_secondary-content-color: var(--semantics-buttons-inherit-filled-is-expanded-content-secondary-color);
385
- --_highlight-border-color: var(--semantics-buttons-inherit-filled-is-expanded-highlight-border-color);
386
- --_is-hovered-background-color: var(--semantics-buttons-inherit-filled-is-expanded-is-hovered-background-color);
387
- --_is-hovered-primary-content-color: var(--semantics-buttons-inherit-filled-is-expanded-is-hovered-content-color);
388
- --_is-hovered-secondary-content-color: var(--semantics-buttons-inherit-filled-is-expanded-is-hovered-content-secondary-color);
389
- --_is-hovered-highlight-border-color: var(--semantics-buttons-inherit-filled-is-expanded-is-hovered-highlight-border-color);
390
- --_is-active-background-color: var(--semantics-buttons-inherit-filled-is-expanded-is-active-background-color);
391
- --_is-active-primary-content-color: var(--semantics-buttons-inherit-filled-is-expanded-is-active-content-color);
392
- --_is-active-secondary-content-color: var(--semantics-buttons-inherit-filled-is-expanded-is-active-content-secondary-color);
393
- --_is-active-highlight-border-color: var(--semantics-buttons-inherit-filled-is-expanded-is-active-highlight-border-color);
394
- }
395
-
396
364
  :host([width="full"]) {
397
365
  display: block;
398
366
  width: 100%;
@@ -691,6 +659,7 @@ function template$23(helpers) {
691
659
  <nldd-activity-indicator
692
660
  timing="instant"
693
661
  size=${this.size === "xs" ? "16" : this.size === "sm" ? "20" : this.size === "lg" ? "28" : "24"}
662
+ text=${this.loadingText || nothing}
694
663
  ></nldd-activity-indicator>
695
664
  </div>
696
665
  ` : nothing;
@@ -833,10 +802,11 @@ function DescribedBy(Base) {
833
802
  * Nederlandse Digitale Dienst Button Component (Lit + TypeScript)
834
803
  *
835
804
  * @element nldd-button
836
- * @attr {string} variant - Button variant: 'primary' | 'secondary' | 'destructive' | 'accent-filled' | 'accent-transparent' | 'neutral-tinted' | 'neutral-base' | 'neutral-transparent' | 'critical-tinted' | 'critical-transparent' | 'inherit-filled' | 'inherit-tinted'. The inherit variants derive their colors from currentColor, for buttons on colored surfaces; inherit-filled uses the surface color (--context-parent-background-color) as the label color, with a white/black contrast flip as a fallback.
805
+ * @attr {string} appearance - Visual style, color included: 'primary' | 'secondary' | 'destructive' | 'accent-filled' | 'accent-transparent' | 'neutral-tinted' | 'neutral-base' | 'neutral-transparent' | 'critical-tinted' | 'critical-transparent' | 'inherit-filled' | 'inherit-tinted'. The inherit appearances derive their colors from currentColor, for buttons on colored surfaces; inherit-filled uses the surface color (--context-parent-background-color) as the label color, with a white/black contrast flip as a fallback.
837
806
  * @attr {string} size - Button size: 'xs' | 'sm' | 'md' | 'lg' (default: 'md'). 'lg' uses larger text and 24px start/end icons.
838
807
  * @attr {string} horizontal-alignment - Horizontal alignment of the button content: 'left' | 'center' | 'right' (default: unset, centered). Most visible with width="full" or a fixed width.
839
808
  * @attr {boolean} loading - Loading state (default: false). Shows an activity indicator over the visually hidden content, sets aria-busy on the inner control and blocks activation, without dropping the button from the tab order (unlike disabled). The content stays laid out, so the button keeps its width.
809
+ * @attr {string} loading-text - What the screen reader announces while `loading` is on, for a button that does more than load: "Aan het bewaren". Leave it out and the activity indicator says its translated "Laden".
840
810
  * @attr {boolean} disabled - Disabled state
841
811
  * @attr {string} type - Button type for form submission: 'button' | 'submit' | 'reset' (ignored when href is set)
842
812
  * @attr {string} popovertarget - ID of a popover element this button invokes; forwarded to the inner button. Use the popoverTargetElement property instead when the popover lives in another tree.
@@ -849,7 +819,7 @@ function DescribedBy(Base) {
849
819
  * @attr {string} text - Button text
850
820
  * @attr {string} supporting-text - Supporting text shown below the text (md/lg) or after it (sm/xs), in a secondary color. Part of the accessible name (unless `accessible-label` is set, which replaces the whole accessible name).
851
821
  * @attr {boolean} single-line - When true, truncates overflowing text with an ellipsis instead of letting it wrap. Requires the button (or an ancestor) to constrain the width.
852
- * @attr {boolean} no-highlight-border - Removes the per-variant highlight border (e.g. when nldd-button-bar draws a single group border instead).
822
+ * @attr {boolean} no-highlight-border - Removes the per-appearance highlight border (e.g. when nldd-button-bar draws a single group border instead).
853
823
  * @attr {boolean} no-tab - Takes the button out of the tab order (tabindex="-1"), for a control owned by a roving container (e.g. a button in a row of an nldd-list, where the arrow keys move between rows) that manages focus itself. Still mouse- and script-focusable.
854
824
  * @attr {string} start-icon - Icon name for the start icon (before text)
855
825
  * @attr {string} end-icon - Icon name for the end icon (after text)
@@ -871,7 +841,7 @@ var NLDDButton = (_NLDDButton = class NLDDButton extends DescribedBy(withTransla
871
841
  constructor(..._args) {
872
842
  super(..._args);
873
843
  this._internals = this.attachInternals();
874
- this.variant = "neutral-tinted";
844
+ this.appearance = "neutral-tinted";
875
845
  this.size = "md";
876
846
  this.horizontalAlignment = "";
877
847
  this.width = "";
@@ -884,6 +854,7 @@ var NLDDButton = (_NLDDButton = class NLDDButton extends DescribedBy(withTransla
884
854
  this.popoverTargetElement = null;
885
855
  this.popoverTargetAction = "toggle";
886
856
  this.loading = false;
857
+ this.loadingText = "";
887
858
  this.disabled = false;
888
859
  this.text = "";
889
860
  this.supportingText = "";
@@ -973,7 +944,7 @@ var NLDDButton = (_NLDDButton = class NLDDButton extends DescribedBy(withTransla
973
944
  __decorate([property({
974
945
  reflect: true,
975
946
  converter: reflectNonDefault("neutral-tinted")
976
- })], NLDDButton.prototype, "variant", void 0);
947
+ })], NLDDButton.prototype, "appearance", void 0);
977
948
  __decorate([property({
978
949
  reflect: true,
979
950
  converter: reflectNonDefault("md")
@@ -1022,6 +993,7 @@ __decorate([property({
1022
993
  type: Boolean,
1023
994
  reflect: true
1024
995
  })], NLDDButton.prototype, "loading", void 0);
996
+ __decorate([property({ attribute: "loading-text" })], NLDDButton.prototype, "loadingText", void 0);
1025
997
  __decorate([property({
1026
998
  type: Boolean,
1027
999
  reflect: true
@@ -1105,19 +1077,34 @@ var splitButtonStyles = css`
1105
1077
 
1106
1078
  /* ## Accent Filled (Primary) */
1107
1079
 
1108
- :host([variant="accent-filled"]),
1109
- :host([variant="primary"]) {
1080
+ :host([appearance="accent-filled"]),
1081
+ :host([appearance="primary"]) {
1110
1082
  --_background-color: var(--semantics-buttons-accent-filled-background-color);
1111
1083
  --_divider-color: var(--semantics-buttons-accent-filled-divider-color);
1112
1084
  --_highlight-border-color: var(--semantics-buttons-accent-filled-highlight-border-color);
1113
1085
  }
1114
1086
 
1115
- :host([variant="neutral-base"]) {
1087
+ :host([appearance="neutral-base"]) {
1116
1088
  --_background-color: var(--semantics-buttons-neutral-base-background-color);
1117
1089
  --_divider-color: var(--semantics-buttons-neutral-base-divider-color);
1118
1090
  --_highlight-border-color: var(--semantics-buttons-neutral-base-highlight-border-color);
1119
1091
  }
1120
1092
 
1093
+ /* ## On-color */
1094
+
1095
+ :host([appearance="inherit-tinted"]) {
1096
+ --_background-color: var(--semantics-buttons-inherit-tinted-background-color);
1097
+ --_divider-color: var(--semantics-buttons-inherit-tinted-divider-color);
1098
+ --_highlight-border-color: var(--semantics-buttons-inherit-tinted-highlight-border-color);
1099
+ --context-button-background-color: transparent;
1100
+ }
1101
+
1102
+ :host([appearance="inherit-filled"]) {
1103
+ --_background-color: var(--semantics-buttons-inherit-filled-background-color);
1104
+ --_divider-color: var(--semantics-buttons-inherit-filled-divider-color);
1105
+ --_highlight-border-color: var(--semantics-buttons-inherit-filled-highlight-border-color);
1106
+ }
1107
+
1121
1108
  :host([width="full"]) {
1122
1109
  display: block;
1123
1110
  width: 100%;
@@ -1187,7 +1174,7 @@ function template$22() {
1187
1174
  return html`
1188
1175
  <div class="split-button">
1189
1176
  <nldd-button
1190
- variant=${this.variant}
1177
+ appearance=${this.appearance}
1191
1178
  size=${this.size}
1192
1179
  text=${this.text}
1193
1180
  start-icon=${this.icon || nothing}
@@ -1200,7 +1187,7 @@ function template$22() {
1200
1187
  <div class="split-button__divider"></div>
1201
1188
  <div class="split-button__popup-button">
1202
1189
  <nldd-icon-button
1203
- variant=${this.variant}
1190
+ appearance=${this.appearance}
1204
1191
  size=${this.size}
1205
1192
  icon="chevron-down-small"
1206
1193
  text=${this._t("components.split-button.menu-action")}
@@ -1747,16 +1734,17 @@ function menuTemplate(isEmpty, variant) {
1747
1734
  }
1748
1735
  function menuItemTemplate(variant = null) {
1749
1736
  const hasCheckState = this.type !== "button" && variant === "menu";
1737
+ const hasCheckColumn = hasCheckState || this.checkColumn && variant === "menu";
1750
1738
  const role = variant ? itemRoleMap[this.type][variant] : nothing;
1751
1739
  const hasSubmenu = this._hasSubmenu;
1752
1740
  const safeHref = sanitizeUrl(this.href) ?? "";
1753
1741
  const asLink = !!safeHref && this.type === "button" && !hasSubmenu && !this.disabled;
1754
1742
  const content = html`
1755
- ${hasCheckState ? html`
1743
+ ${hasCheckColumn ? html`
1756
1744
  <nldd-icon-cell
1757
1745
  size="24"
1758
1746
  horizontal-alignment="center"
1759
- icon=${this.selected ? "check-mark" : nothing}
1747
+ icon=${hasCheckState && this.selected ? "check-mark" : nothing}
1760
1748
  ></nldd-icon-cell>
1761
1749
  <nldd-spacer-cell size="4"></nldd-spacer-cell>
1762
1750
  ` : nothing}
@@ -1800,7 +1788,7 @@ function menuItemTemplate(variant = null) {
1800
1788
  >
1801
1789
  <nldd-keyboard-shortcut
1802
1790
  size="inherit"
1803
- variant="simple"
1791
+ appearance="simple"
1804
1792
  color="inherit"
1805
1793
  keys=${this.shortcut || nothing}
1806
1794
  mac-keys=${this.shortcutMac || nothing}
@@ -2631,16 +2619,16 @@ var keyboardShortcutStyles = css`
2631
2619
  --_font-size: 0.75em;
2632
2620
  }
2633
2621
 
2634
- :host([variant="simple"]) {
2622
+ :host([appearance="simple"]) {
2635
2623
  --_font-family: var(--primitives-font-family-body);
2636
2624
  --_font-size: var(--primitives-font-size-100);
2637
2625
  }
2638
2626
 
2639
- :host([variant="simple"][size="sm"]) {
2627
+ :host([appearance="simple"][size="sm"]) {
2640
2628
  --_font-size: var(--primitives-font-size-90);
2641
2629
  }
2642
2630
 
2643
- :host([variant="simple"][size="inherit"]) {
2631
+ :host([appearance="simple"][size="inherit"]) {
2644
2632
  --_font-size: inherit;
2645
2633
  }
2646
2634
 
@@ -2668,7 +2656,7 @@ var keyboardShortcutStyles = css`
2668
2656
  top: -0.05em;
2669
2657
  }
2670
2658
 
2671
- :host([size="inherit"][variant="simple"]) .keyboard-shortcut {
2659
+ :host([size="inherit"][appearance="simple"]) .keyboard-shortcut {
2672
2660
  position: static;
2673
2661
  }
2674
2662
 
@@ -2694,11 +2682,11 @@ var keyboardShortcutStyles = css`
2694
2682
  white-space: nowrap;
2695
2683
  }
2696
2684
 
2697
- :host([variant="simple"]) .keyboard-shortcut {
2685
+ :host([appearance="simple"]) .keyboard-shortcut {
2698
2686
  gap: 0;
2699
2687
  }
2700
2688
 
2701
- :host([variant="simple"]) .keyboard-shortcut__key {
2689
+ :host([appearance="simple"]) .keyboard-shortcut__key {
2702
2690
  box-shadow: none;
2703
2691
  background-color: transparent;
2704
2692
  border-radius: 0;
@@ -2712,7 +2700,7 @@ var keyboardShortcutStyles = css`
2712
2700
  color: CanvasText;
2713
2701
  }
2714
2702
 
2715
- :host(:not([variant="simple"])) .keyboard-shortcut__key {
2703
+ :host(:not([appearance="simple"])) .keyboard-shortcut__key {
2716
2704
  border: var(--components-keyboard-shortcut-border-width) solid CanvasText;
2717
2705
  background-color: Canvas;
2718
2706
  }
@@ -2795,7 +2783,7 @@ function detectOS() {
2795
2783
  * @attr {string} linux-keys - Optional override for Linux/ChromeOS.
2796
2784
  * @attr {string} size - Size: 'sm' | 'md' | 'inherit' (default: 'md'). 'inherit' takes the
2797
2785
  * font-size from the container; in the box variant the keycaps then scale along in em.
2798
- * @attr {string} variant - 'box' (default) shows each key as a keycap with a fill and a
2786
+ * @attr {string} appearance - 'box' (default) shows each key as a keycap with a fill and a
2799
2787
  * highlight edge. 'simple' shows the keys as plain text with separators: lighter, for
2800
2788
  * inline use such as in a menu item.
2801
2789
  * @attr {boolean} always-visible - Show on touch-only devices too, where shortcuts cannot be invoked.
@@ -2819,7 +2807,7 @@ var NLDDKeyboardShortcut = (_NLDDKeyboardShortcut = class NLDDKeyboardShortcut e
2819
2807
  this.windowsKeys = "";
2820
2808
  this.linuxKeys = "";
2821
2809
  this.size = "md";
2822
- this.variant = "box";
2810
+ this.appearance = "box";
2823
2811
  this.color = "neutral";
2824
2812
  this.alwaysVisible = false;
2825
2813
  this.debugOS = "";
@@ -2871,7 +2859,7 @@ __decorate([property({
2871
2859
  __decorate([property({
2872
2860
  reflect: true,
2873
2861
  converter: reflectNonDefault("box")
2874
- })], NLDDKeyboardShortcut.prototype, "variant", void 0);
2862
+ })], NLDDKeyboardShortcut.prototype, "appearance", void 0);
2875
2863
  __decorate([property({
2876
2864
  reflect: true,
2877
2865
  converter: reflectNonDefault("neutral")
@@ -3484,7 +3472,7 @@ if (!customElements.get("nldd-menu-group")) customElements.define("nldd-menu-gro
3484
3472
  * @attr {string} shortcut - Keyboard shortcut hint shown on the right, e.g. 'Cmd+E'. Display only (rendered via nldd-keyboard-shortcut) — it does not bind the key; wire up the handling in your app. Hidden on touch-only devices, where it isn't invokable.
3485
3473
  * @attr {string} shortcut-mac / shortcut-windows / shortcut-linux - Per-OS overrides for `shortcut`, picked by detected OS (falls back to `shortcut`).
3486
3474
  * @attr {string} href - Optional link target. A plain button item with an href renders as an `<a>` so it is a real link (middle-click, open in new tab, copy link). Ignored for submenu openers, checkbox/radio items, and while disabled.
3487
- * @attr {string} type - Item type: 'button' | 'checkbox' | 'radio'. Default: 'button'.
3475
+ * @attr {string} type - Item type: 'button' | 'checkbox' | 'radio'. Default: 'button'. One checkbox or radio item gives every item in its menu the check-mark column, so the text of the whole menu starts at one line, as in a native menu. Submenus decide for themselves.
3488
3476
  * @attr {boolean} selected - Selected state for checkbox and radio types.
3489
3477
  * @attr {boolean} disabled - Disabled state.
3490
3478
  * @attr {string} value - A value of the item's own, read off the item in a `select` handler. The default filter matches on it as well as on `text` and `aliases`. Not a form value: this component is not form-associated.
@@ -3514,6 +3502,7 @@ var NLDDMenuItem = class NLDDMenuItem extends LitElement {
3514
3502
  this.query = "";
3515
3503
  this.queryMarkMode = "predictive";
3516
3504
  this.menuVariant = null;
3505
+ this.checkColumn = false;
3517
3506
  this._submenuOpen = false;
3518
3507
  this._cachedSubmenuEl = null;
3519
3508
  this._submenuMutationObserver = null;
@@ -3549,6 +3538,9 @@ var NLDDMenuItem = class NLDDMenuItem extends LitElement {
3549
3538
  if (this.hasUpdated) return;
3550
3539
  this._cachedSubmenuEl = this.querySelector(":scope > nldd-menu");
3551
3540
  }
3541
+ updated(changedProperties) {
3542
+ if (changedProperties.has("type") && changedProperties.get("type") !== void 0 && this.menuVariant) this.closest("nldd-menu")?._claimItems();
3543
+ }
3552
3544
  firstUpdated() {
3553
3545
  this._submenuMutationObserver = new MutationObserver(() => {
3554
3546
  const current = this.querySelector(":scope > nldd-menu");
@@ -3662,6 +3654,7 @@ __decorate([property({
3662
3654
  converter: reflectNonDefault("predictive")
3663
3655
  })], NLDDMenuItem.prototype, "queryMarkMode", void 0);
3664
3656
  __decorate([state()], NLDDMenuItem.prototype, "menuVariant", void 0);
3657
+ __decorate([state()], NLDDMenuItem.prototype, "checkColumn", void 0);
3665
3658
  __decorate([state()], NLDDMenuItem.prototype, "_submenuOpen", void 0);
3666
3659
  if (!customElements.get("nldd-menu-item")) customElements.define("nldd-menu-item", NLDDMenuItem);
3667
3660
  var defaultFilterFn = (query, item) => {
@@ -4029,9 +4022,15 @@ var NLDDMenu = class NLDDMenu extends LitElement {
4029
4022
  this._typeaheadBuffer = "";
4030
4023
  this._typeaheadTimer = null;
4031
4024
  this._claimItems = () => {
4032
- Array.from(this.querySelectorAll("nldd-menu-item")).forEach((item) => {
4025
+ const items = Array.from(this.querySelectorAll("nldd-menu-item"));
4026
+ items.forEach((item) => {
4033
4027
  item.menuVariant = this.variant;
4034
4028
  });
4029
+ const own = items.filter((item) => item.closest("nldd-menu") === this);
4030
+ const checkColumn = this.variant === "menu" && own.some((item) => item.type !== "button");
4031
+ own.forEach((item) => {
4032
+ item.checkColumn = checkColumn;
4033
+ });
4035
4034
  };
4036
4035
  this._handleBeforeToggle = (event) => {
4037
4036
  if (event.newState === "open") this.removeAttribute("positioned");
@@ -4075,9 +4074,7 @@ var NLDDMenu = class NLDDMenu extends LitElement {
4075
4074
  };
4076
4075
  }
4077
4076
  _t(key, vars) {
4078
- let str = this.translations[key] ?? nlddMenuTranslations[key];
4079
- if (vars) for (const [k, v] of Object.entries(vars)) str = str.replace(`{${k}}`, String(v));
4080
- return str;
4077
+ return translate(this.translations, nlddMenuTranslations, key, vars);
4081
4078
  }
4082
4079
  /** Resolved empty text: emptyText attribute takes precedence, then i18n fallback. */
4083
4080
  get _resolvedEmptyText() {
@@ -4596,10 +4593,14 @@ var NLDDMenu = class NLDDMenu extends LitElement {
4596
4593
  * remainder (predictive completion — the ARIA APG pattern for combobox).
4597
4594
  *
4598
4595
  * When the query is empty, all items are shown and `query` is cleared.
4596
+ *
4597
+ * With `hide: false` nothing is hidden and every item gets the `query`, for
4598
+ * a list someone else already filtered, such as a server answering per
4599
+ * keystroke. Text without the query in it is shown as it is.
4599
4600
  */
4600
- filter(query) {
4601
+ filter(query, { hide = true } = {}) {
4601
4602
  Array.from(this.querySelectorAll("nldd-menu-item")).forEach((item) => {
4602
- const matches = !query || this.filterFn(query, item);
4603
+ const matches = !hide || !query || this.filterFn(query, item);
4603
4604
  item.toggleAttribute("hidden", !matches);
4604
4605
  item.query = matches && query ? query : "";
4605
4606
  });
@@ -4810,7 +4811,7 @@ if (!customElements.get("nldd-menu")) customElements.define("nldd-menu", NLDDMen
4810
4811
  *
4811
4812
  * @element nldd-split-button
4812
4813
  * @attr {string} size - Button size: 'xs' | 'sm' | 'md' | 'lg' (default: 'md')
4813
- * @attr {string} variant - Button variant (default: 'neutral-tinted')
4814
+ * @attr {string} appearance - Visual style (default: 'neutral-tinted'; 'inherit-tinted' and 'inherit-filled' for a colored surface)
4814
4815
  * @attr {boolean} disabled - Disabled state
4815
4816
  * @attr {string} width - Width mode: 'full' (stretches to container) or any CSS length; the main action button fills the available space
4816
4817
  * @attr {string} text - Button text for the primary action
@@ -4827,7 +4828,7 @@ var NLDDSplitButton = (_NLDDSplitButton = class NLDDSplitButton extends LitEleme
4827
4828
  constructor(..._args) {
4828
4829
  super(..._args);
4829
4830
  this.size = "md";
4830
- this.variant = "neutral-tinted";
4831
+ this.appearance = "neutral-tinted";
4831
4832
  this.disabled = false;
4832
4833
  this.width = "";
4833
4834
  this.text = "";
@@ -4847,7 +4848,7 @@ var NLDDSplitButton = (_NLDDSplitButton = class NLDDSplitButton extends LitEleme
4847
4848
  };
4848
4849
  }
4849
4850
  _t(key) {
4850
- return this.translations[key] ?? nlddSplitButtonTranslations[key];
4851
+ return translate(this.translations, nlddSplitButtonTranslations, key);
4851
4852
  }
4852
4853
  firstUpdated() {
4853
4854
  this._popupButtonWrapper?.addEventListener("pointerdown", this._popup.handlePointerdown);
@@ -4895,7 +4896,7 @@ __decorate([property({
4895
4896
  __decorate([property({
4896
4897
  reflect: true,
4897
4898
  converter: reflectNonDefault("neutral-tinted")
4898
- })], NLDDSplitButton.prototype, "variant", void 0);
4899
+ })], NLDDSplitButton.prototype, "appearance", void 0);
4899
4900
  __decorate([property({
4900
4901
  type: Boolean,
4901
4902
  reflect: true
@@ -4955,19 +4956,34 @@ var buttonBarStyles = css`
4955
4956
 
4956
4957
  /* ## Accent Filled (Primary) */
4957
4958
 
4958
- :host([variant="accent-filled"]),
4959
- :host([variant="primary"]) {
4959
+ :host([appearance="accent-filled"]),
4960
+ :host([appearance="primary"]) {
4960
4961
  --_background-color: var(--semantics-buttons-accent-filled-background-color);
4961
4962
  --_divider-color: var(--semantics-buttons-accent-filled-divider-color);
4962
4963
  --_highlight-border-color: var(--semantics-buttons-accent-filled-highlight-border-color);
4963
4964
  }
4964
4965
 
4965
- :host([variant="neutral-base"]) {
4966
+ :host([appearance="neutral-base"]) {
4966
4967
  --_background-color: var(--semantics-buttons-neutral-base-background-color);
4967
4968
  --_divider-color: var(--semantics-buttons-neutral-base-divider-color);
4968
4969
  --_highlight-border-color: var(--semantics-buttons-neutral-base-highlight-border-color);
4969
4970
  }
4970
4971
 
4972
+ /* ## On-color */
4973
+
4974
+ :host([appearance="inherit-tinted"]) {
4975
+ --_background-color: var(--semantics-buttons-inherit-tinted-background-color);
4976
+ --_divider-color: var(--semantics-buttons-inherit-tinted-divider-color);
4977
+ --_highlight-border-color: var(--semantics-buttons-inherit-tinted-highlight-border-color);
4978
+ --context-button-background-color: transparent;
4979
+ }
4980
+
4981
+ :host([appearance="inherit-filled"]) {
4982
+ --_background-color: var(--semantics-buttons-inherit-filled-background-color);
4983
+ --_divider-color: var(--semantics-buttons-inherit-filled-divider-color);
4984
+ --_highlight-border-color: var(--semantics-buttons-inherit-filled-highlight-border-color);
4985
+ }
4986
+
4971
4987
  :host([hidden]) {
4972
4988
  display: none;
4973
4989
  }
@@ -5053,12 +5069,17 @@ function renderChild(child) {
5053
5069
  * Nederlandse Digitale Dienst Button Bar Component (Lit + TypeScript)
5054
5070
  *
5055
5071
  * A horizontal container for grouping buttons with a neutral background.
5056
- * Automatically propagates its size and variant to all child nldd-button and nldd-icon-button elements.
5072
+ * Automatically propagates its size and appearance to all child nldd-button and nldd-icon-button elements.
5057
5073
  * Renders nldd-button-bar-divider elements as internal dividers — no separate component needed.
5058
5074
  *
5075
+ * The bar is one surface for actions; on/off buttons do not go in it. For a row
5076
+ * of toggles use nldd-toggle-button-group, and for one choice out of a few
5077
+ * options on one surface nldd-segmented-control. An nldd-toggle-button placed
5078
+ * here is shown as it is, and a warning says so in development.
5079
+ *
5059
5080
  * @element nldd-button-bar
5060
5081
  * @attr {string} size - Bar size: 'xs' | 'sm' | 'md' | 'lg' (default: 'md'). At 'lg', icon-button children stack their label below the icon (mobile action-bar style).
5061
- * @attr {string} variant - Button variant (default: 'neutral-tinted')
5082
+ * @attr {string} appearance - Visual style of the buttons (default: 'neutral-tinted'; 'inherit-tinted' and 'inherit-filled' for a colored surface)
5062
5083
  * @attr {boolean} disabled - Disabled state
5063
5084
  *
5064
5085
  * @slot - Default slot for nldd-button, nldd-icon-button and nldd-button-bar-divider elements
@@ -5078,13 +5099,14 @@ var NLDDButtonBar = (_NLDDButtonBar = class NLDDButtonBar extends LitElement {
5078
5099
  constructor(..._args) {
5079
5100
  super(..._args);
5080
5101
  this.size = "md";
5081
- this.variant = "neutral-tinted";
5102
+ this.appearance = "neutral-tinted";
5082
5103
  this.disabled = false;
5083
5104
  this._children = [];
5084
5105
  this._idCounter = 0;
5085
5106
  this._observer = null;
5086
5107
  this._building = false;
5087
5108
  this._individuallyDisabled = /* @__PURE__ */ new WeakSet();
5109
+ this._warnedToggleButton = false;
5088
5110
  }
5089
5111
  connectedCallback() {
5090
5112
  super.connectedCallback();
@@ -5103,7 +5125,7 @@ var NLDDButtonBar = (_NLDDButtonBar = class NLDDButtonBar extends LitElement {
5103
5125
  }
5104
5126
  updated(changedProperties) {
5105
5127
  if (changedProperties.has("size") || changedProperties.has("_children")) this._propagateSize();
5106
- if (changedProperties.has("variant") || changedProperties.has("_children")) this._propagateVariant();
5128
+ if (changedProperties.has("appearance") || changedProperties.has("_children")) this._propagateAppearance();
5107
5129
  if (changedProperties.has("disabled")) this._propagateDisabled();
5108
5130
  else if (changedProperties.has("_children") && this.disabled) Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase())).forEach((el) => el.setAttribute("disabled", ""));
5109
5131
  }
@@ -5118,8 +5140,8 @@ var NLDDButtonBar = (_NLDDButtonBar = class NLDDButtonBar extends LitElement {
5118
5140
  _propagateSize() {
5119
5141
  Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase())).forEach((el) => el.setAttribute("size", this.size));
5120
5142
  }
5121
- _propagateVariant() {
5122
- Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase())).forEach((el) => el.setAttribute("variant", this.variant));
5143
+ _propagateAppearance() {
5144
+ Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase())).forEach((el) => el.setAttribute("appearance", this.appearance));
5123
5145
  }
5124
5146
  _propagateDisabled() {
5125
5147
  const buttons = Array.from(this.children).filter((el) => BUTTON_TAGS.includes(el.tagName.toLowerCase()));
@@ -5145,9 +5167,10 @@ var NLDDButtonBar = (_NLDDButtonBar = class NLDDButtonBar extends LitElement {
5145
5167
  type: "divider",
5146
5168
  id: this._idCounter++
5147
5169
  };
5170
+ if (tag === "nldd-toggle-button") this._warnToggleButton();
5148
5171
  if (BUTTON_TAGS.includes(tag)) {
5149
5172
  el.setAttribute("size", this.size);
5150
- el.setAttribute("variant", this.variant);
5173
+ el.setAttribute("appearance", this.appearance);
5151
5174
  el.setAttribute("no-highlight-border", "");
5152
5175
  }
5153
5176
  const id = this._idCounter++;
@@ -5161,6 +5184,7 @@ var NLDDButtonBar = (_NLDDButtonBar = class NLDDButtonBar extends LitElement {
5161
5184
  });
5162
5185
  this._building = false;
5163
5186
  }
5187
+ _warnToggleButton() {}
5164
5188
  render() {
5165
5189
  return template$17.call(this);
5166
5190
  }
@@ -5172,7 +5196,7 @@ __decorate([property({
5172
5196
  __decorate([property({
5173
5197
  reflect: true,
5174
5198
  converter: reflectNonDefault("neutral-tinted")
5175
- })], NLDDButtonBar.prototype, "variant", void 0);
5199
+ })], NLDDButtonBar.prototype, "appearance", void 0);
5176
5200
  __decorate([property({
5177
5201
  type: Boolean,
5178
5202
  reflect: true
@@ -5759,7 +5783,7 @@ var NLDDToolbarTitle = (_NLDDToolbarTitle = class NLDDToolbarTitle extends LitEl
5759
5783
  this.size = "md";
5760
5784
  }
5761
5785
  _t(key) {
5762
- return this.translations[key] ?? nlddToolbarTranslations[key];
5786
+ return translate(this.translations, nlddToolbarTranslations, key);
5763
5787
  }
5764
5788
  willUpdate(changedProperties) {
5765
5789
  if (changedProperties.has("minWidth")) this._reflectSizeVar("--_title-group-min-width", this.minWidth);
@@ -5862,7 +5886,7 @@ var NLDDToolbar = (_NLDDToolbar = class NLDDToolbar extends LitElement {
5862
5886
  };
5863
5887
  }
5864
5888
  _t(key) {
5865
- return this.translations[key] ?? nlddToolbarTranslations[key];
5889
+ return translate(this.translations, nlddToolbarTranslations, key);
5866
5890
  }
5867
5891
  _getId(el) {
5868
5892
  if (!this._childIds.has(el)) this._childIds.set(el, this._idCounter++);
@@ -7504,7 +7528,7 @@ var NLDDPopover = (_NLDDPopover2 = class NLDDPopover extends LitElement {
7504
7528
  }
7505
7529
  }
7506
7530
  _t(key) {
7507
- return this.translations[key] ?? nlddPopoverTranslations[key];
7531
+ return translate(this.translations, nlddPopoverTranslations, key);
7508
7532
  }
7509
7533
  get _resolvedAccessibleLabel() {
7510
7534
  return this.accessibleLabel || this._t("components.popover.accessible-label");
@@ -8637,12 +8661,12 @@ var listStyles = css`
8637
8661
  }
8638
8662
  }
8639
8663
 
8640
- :host([variant^="box"]) {
8664
+ :host([appearance^="box"]) {
8641
8665
  --_background-color: var(--semantics-surfaces-tinted-background-color);
8642
8666
  --_highlight-border-color: var(--semantics-surfaces-tinted-border-color);
8643
8667
  }
8644
8668
 
8645
- :host([variant="box-base"]) {
8669
+ :host([appearance="box-base"]) {
8646
8670
  --_background-color: var(--semantics-surfaces-base-background-color);
8647
8671
  --_highlight-border-color: var(--semantics-surfaces-base-border-color);
8648
8672
  }
@@ -8688,7 +8712,7 @@ var listStyles = css`
8688
8712
  reach its corners and have nothing to be clipped against. Without it a
8689
8713
  focus ring inside the box paints outward, like every other control in the
8690
8714
  system, instead of being cut off by the frame. */
8691
- :host([variant^="box"]) .list__main {
8715
+ :host([appearance^="box"]) .list__main {
8692
8716
  position: relative;
8693
8717
  border-radius: var(--semantics-surfaces-corner-radius);
8694
8718
  background-color: var(--_background-color);
@@ -8716,7 +8740,7 @@ var listStyles = css`
8716
8740
  display: none;
8717
8741
  }
8718
8742
 
8719
- :host([variant^="box"]) .list__items {
8743
+ :host([appearance^="box"]) .list__items {
8720
8744
  padding-inline: calc(var(--components-list-item-indicator-inline-inset) + var(--_box-padding));
8721
8745
  padding-block: var(--_box-padding);
8722
8746
  }
@@ -8870,7 +8894,7 @@ var listStyles = css`
8870
8894
  /* # High Contrast */
8871
8895
 
8872
8896
  @media (forced-colors: active) {
8873
- :host([variant^="box"]) .list__main {
8897
+ :host([appearance^="box"]) .list__main {
8874
8898
  border: 1px solid CanvasText;
8875
8899
  }
8876
8900
  }
@@ -8923,7 +8947,7 @@ var template$14 = ({ itemsLabel, hasToolbar, type, isEmpty, hasItems, hasEmptySt
8923
8947
  <div class="list__search-field-end">
8924
8948
  <div class="list__search-field-clear">
8925
8949
  <nldd-icon-button
8926
- variant="neutral-transparent"
8950
+ appearance="neutral-transparent"
8927
8951
  size="sm"
8928
8952
  icon="dismiss"
8929
8953
  text=${listbox.searchClearLabel}
@@ -9008,14 +9032,13 @@ var _NLDDList;
9008
9032
  var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9009
9033
  constructor(..._args) {
9010
9034
  super(..._args);
9011
- this.variant = "simple";
9035
+ this.appearance = "simple";
9012
9036
  this.type = "list";
9013
9037
  this.dividers = "always";
9014
9038
  this.height = "";
9015
9039
  this.accessibleLabel = "";
9016
9040
  this.translations = {};
9017
9041
  this.reorderable = false;
9018
- this._mergedTranslations = { ...nlddListTranslations };
9019
9042
  this._hasToolbar = false;
9020
9043
  this._hasSearchBarEnd = false;
9021
9044
  this._hasEmptyState = false;
@@ -9035,6 +9058,7 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9035
9058
  this._cloneOffsetY = 0;
9036
9059
  this._listRect = null;
9037
9060
  this._itemsObserver = null;
9061
+ this._autoLabel = null;
9038
9062
  this._contextScheduled = false;
9039
9063
  this._warnedSilentEmpty = false;
9040
9064
  this._listboxScheduled = false;
@@ -9215,11 +9239,7 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9215
9239
  * from the children instead. The slotchange listeners below keep them true
9216
9240
  * afterwards, and by then a second render is what you actually want.
9217
9241
  */
9218
- willUpdate(changed) {
9219
- if (changed.has("translations") || !this.hasUpdated) this._mergedTranslations = {
9220
- ...nlddListTranslations,
9221
- ...this.translations
9222
- };
9242
+ willUpdate(_changed) {
9223
9243
  if (this.hasUpdated) return;
9224
9244
  this._updateEmpty();
9225
9245
  this._hasToolbar = this.querySelector(":scope > [slot=\"toolbar\"]") !== null;
@@ -9286,12 +9306,13 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9286
9306
  this._cancelDrag();
9287
9307
  }
9288
9308
  updated(changed) {
9309
+ this._syncTranslatedTexts();
9289
9310
  if (changed.has("reorderable") || changed.has("type")) {
9290
9311
  if (this.reorderable && this.type !== "list" && false);
9291
9312
  this._updateItems();
9292
9313
  this._warnArrowNav();
9293
9314
  }
9294
- if (changed.has("variant")) this._updateItemContext();
9315
+ if (changed.has("appearance")) this._updateItemContext();
9295
9316
  if (changed.has("type")) {
9296
9317
  this._applyHostType();
9297
9318
  if (changed.get("type") === "listbox" && this.type !== "listbox") {
@@ -9307,19 +9328,28 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9307
9328
  else this.style.removeProperty("--_max-height");
9308
9329
  }
9309
9330
  }
9331
+ /** On every render, so the texts this list sets itself follow a language switch. */
9332
+ _syncTranslatedTexts() {
9333
+ if (this.hasAttribute("data-nldd-auto-label") && this.getAttribute("aria-label") === this._autoLabel) {
9334
+ this._autoLabel = this._t("components.list.navigation-accessible-label");
9335
+ this.setAttribute("aria-label", this._autoLabel);
9336
+ }
9337
+ if (this.hasAttribute("aria-keyshortcuts")) this.setAttribute("aria-description", this._t("components.list.arrow-navigation-description-text"));
9338
+ }
9310
9339
  _applyHostType() {
9311
9340
  if (this.type === "navigation") {
9312
9341
  this.setAttribute("role", "navigation");
9313
9342
  if (!this.hasAttribute("aria-label") && !this.hasAttribute("aria-labelledby")) {
9314
- this.setAttribute("aria-label", this._t("components.list.navigation-accessible-label"));
9343
+ this._autoLabel = this._t("components.list.navigation-accessible-label");
9344
+ this.setAttribute("aria-label", this._autoLabel);
9315
9345
  this.setAttribute("data-nldd-auto-label", "");
9316
9346
  }
9317
9347
  } else {
9318
9348
  if (this.getAttribute("role") === "navigation") this.removeAttribute("role");
9319
9349
  if (this.hasAttribute("data-nldd-auto-label")) {
9320
- const autoLabel = this._t("components.list.navigation-accessible-label");
9321
- if (this.getAttribute("aria-label") === autoLabel) this.removeAttribute("aria-label");
9350
+ if (this.getAttribute("aria-label") === this._autoLabel) this.removeAttribute("aria-label");
9322
9351
  this.removeAttribute("data-nldd-auto-label");
9352
+ this._autoLabel = null;
9323
9353
  }
9324
9354
  }
9325
9355
  }
@@ -9360,7 +9390,7 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9360
9390
  this._updateRoving();
9361
9391
  if (this.type === "listbox") this._updateListboxOptions();
9362
9392
  }
9363
- /** Push the list's variant + type onto every item, deferred to a microtask:
9393
+ /** Push the list's appearance + type onto every item, deferred to a microtask:
9364
9394
  * _updateItems runs inside the update lifecycle (firstUpdated/updated), and
9365
9395
  * setting the items' reactive state there would trip Lit's change-in-update
9366
9396
  * warning. Coalesced so repeated item updates schedule it only once. */
@@ -9372,13 +9402,13 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9372
9402
  this._applyItemContext();
9373
9403
  });
9374
9404
  }
9375
- /** The list owns variant + type; every item mirrors them (is-boxed styling and
9405
+ /** The list owns appearance + type; every item mirrors them (is-boxed styling and
9376
9406
  * the option/listitem role). Pushing from the list, not a per-item observer,
9377
- * means a runtime variant/type switch, or a freshly added item, always tracks
9407
+ * means a runtime appearance/type switch, or a freshly added item, always tracks
9378
9408
  * the list. */
9379
9409
  _applyItemContext() {
9380
9410
  this._getItems().forEach((item) => {
9381
- item._applyVariant(this.variant);
9411
+ item._applyAppearance(this.appearance);
9382
9412
  item._applyParentType(this.type);
9383
9413
  });
9384
9414
  }
@@ -9794,9 +9824,7 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9794
9824
  this._currentDropIndex = -1;
9795
9825
  }
9796
9826
  _t(key, vars) {
9797
- let str = this._mergedTranslations[key];
9798
- if (vars) for (const [k, v] of Object.entries(vars)) str = str.replace(`{${k}}`, String(v));
9799
- return str;
9827
+ return translate(this.translations, nlddListTranslations, key, vars);
9800
9828
  }
9801
9829
  _announce(message, assertive = false) {
9802
9830
  const selector = assertive ? ".list__assertive-announcer" : ".list__polite-announcer";
@@ -9837,7 +9865,7 @@ var NLDDList = (_NLDDList2 = class NLDDList extends LitElement {
9837
9865
  __decorate([property({
9838
9866
  reflect: true,
9839
9867
  converter: reflectNonDefault("simple")
9840
- })], NLDDList.prototype, "variant", void 0);
9868
+ })], NLDDList.prototype, "appearance", void 0);
9841
9869
  __decorate([property({
9842
9870
  reflect: true,
9843
9871
  converter: reflectNonDefault("list")
@@ -9859,8 +9887,7 @@ __decorate([property({
9859
9887
  type: Boolean,
9860
9888
  reflect: true
9861
9889
  })], NLDDList.prototype, "reorderable", void 0);
9862
- __decorate([state()], NLDDList.prototype, "_mergedTranslations", void 0);
9863
- __decorate([state()], NLDDList.prototype, "_hasToolbar", void 0);
9890
+ __decorate([state(), state()], NLDDList.prototype, "_hasToolbar", void 0);
9864
9891
  __decorate([state()], NLDDList.prototype, "_hasSearchBarEnd", void 0);
9865
9892
  __decorate([state()], NLDDList.prototype, "_hasEmptyState", void 0);
9866
9893
  __decorate([state()], NLDDList.prototype, "_hasNoResultsState", void 0);
@@ -10724,22 +10751,22 @@ var NLDDListItem = (_NLDDListItem2 = class NLDDListItem extends withTranslations
10724
10751
  return this._parentType === "listbox";
10725
10752
  }
10726
10753
  /**
10727
- * Reads the initial variant + type from the closest parent nldd-list, before
10754
+ * Reads the initial appearance + type from the closest parent nldd-list, before
10728
10755
  * the first render, so the item is styled correctly on first paint. Later changes
10729
- * are PUSHED by the list: its `updated` / `_updateItems` calls `_applyVariant`
10756
+ * are PUSHED by the list: its `updated` / `_updateItems` calls `_applyAppearance`
10730
10757
  * and `_applyParentType` on every item, so the list is the single source of
10731
- * truth and a runtime variant/type switch (or an item moved to another list)
10758
+ * truth and a runtime appearance/type switch (or an item moved to another list)
10732
10759
  * always tracks its current parent.
10733
10760
  */
10734
10761
  _syncWithList() {
10735
10762
  const list = this.closest("nldd-list");
10736
10763
  if (!list) return;
10737
- this._applyVariant(list.variant);
10764
+ this._applyAppearance(list.appearance);
10738
10765
  this._applyParentType(list.type);
10739
10766
  }
10740
- _applyVariant(variant) {
10741
- this._isBoxed = variant.startsWith("box");
10742
- this._relayToChildren((item) => item._applyVariant(variant));
10767
+ _applyAppearance(appearance) {
10768
+ this._isBoxed = appearance.startsWith("box");
10769
+ this._relayToChildren((item) => item._applyAppearance(appearance));
10743
10770
  this.classList.toggle("is-boxed", this._isBoxed);
10744
10771
  }
10745
10772
  _applyParentType(type) {
@@ -10850,7 +10877,7 @@ var NLDDListItem = (_NLDDListItem2 = class NLDDListItem extends withTranslations
10850
10877
  if (this._showChildren !== had) this._relayExpanded();
10851
10878
  if (this._showChildren) rows.forEach((row) => {
10852
10879
  const item = row;
10853
- item._applyVariant?.(this._isBoxed ? "box-tinted" : "simple");
10880
+ item._applyAppearance?.(this._isBoxed ? "box-tinted" : "simple");
10854
10881
  item._applyParentType?.(this._parentType);
10855
10882
  });
10856
10883
  }
@@ -11931,12 +11958,12 @@ var codeViewerStyles = css`
11931
11958
  display: none;
11932
11959
  }
11933
11960
 
11934
- :host([variant="box-base"]) {
11961
+ :host([appearance="box-base"]) {
11935
11962
  --_background-color: var(--semantics-surfaces-base-background-color);
11936
11963
  --_border-color: var(--semantics-surfaces-base-border-color);
11937
11964
  }
11938
11965
 
11939
- :host([variant="simple"]) {
11966
+ :host([appearance="simple"]) {
11940
11967
  --_corner-radius: 0;
11941
11968
  --_background-color: transparent;
11942
11969
  --_border-color: transparent;
@@ -11953,7 +11980,7 @@ var codeViewerStyles = css`
11953
11980
  border-radius: var(--_corner-radius);
11954
11981
  /* Inner box-shadow paints the border ring inside the radius
11955
11982
  without taking layout space — matches nldd-box / nldd-banner.
11956
- variant="simple" suppresses the ring via --_border-color. The
11983
+ appearance="simple" suppresses the ring via --_border-color. The
11957
11984
  forced-colors fallback at the bottom restores a real border. */
11958
11985
  box-shadow: var(--_border-shadow);
11959
11986
  background-color: var(--_background-color);
@@ -11975,11 +12002,11 @@ var codeViewerStyles = css`
11975
12002
  padding-right: var(--_actions-area-size);
11976
12003
  }
11977
12004
 
11978
- :host([variant="simple"]:not([no-copy]):not([copy-unavailable])) {
12005
+ :host([appearance="simple"]:not([no-copy]):not([copy-unavailable])) {
11979
12006
  --_actions-area-padding: 0;
11980
12007
  }
11981
12008
 
11982
- :host([variant="simple"]:not([no-copy]):not([copy-unavailable])) .code-viewer {
12009
+ :host([appearance="simple"]:not([no-copy]):not([copy-unavailable])) .code-viewer {
11983
12010
  min-height: var(--_actions-area-size);
11984
12011
  padding-right: 0;
11985
12012
  }
@@ -12033,7 +12060,7 @@ var codeViewerStyles = css`
12033
12060
  border: var(--_border-width) solid CanvasText;
12034
12061
  }
12035
12062
 
12036
- :host([variant="simple"]) .code-viewer {
12063
+ :host([appearance="simple"]) .code-viewer {
12037
12064
  border: none;
12038
12065
  }
12039
12066
  }
@@ -12164,7 +12191,7 @@ function forceScrollLayerRepaint(el) {
12164
12191
  *
12165
12192
  * @element nldd-code-viewer
12166
12193
  *
12167
- * @attr {'box-tinted'|'box-base'|'simple'} variant - Visual style. The two `box` values are a framed card with rounded corners, padding, fill, and a 1px border ring, and differ in which surface they fill with; `box-tinted` is the default. `simple` drops the entire frame — use when embedding inside a parent surface.
12194
+ * @attr {'box-tinted'|'box-base'|'simple'} appearance - Visual style. The two `box` values are a framed card with rounded corners, padding, fill, and a 1px border ring, and differ in which surface they fill with; `box-tinted` is the default. `simple` drops the entire frame — use when embedding inside a parent surface.
12168
12195
  * @attr {string} language - Grammar to highlight with. Empty disables highlighting.
12169
12196
  * @attr {boolean} no-copy - Hide the copy-to-clipboard button (shown by default).
12170
12197
  * @attr {boolean} wrap - Wrap long lines instead of horizontal scroll
@@ -12181,7 +12208,7 @@ function isClipboardAvailable() {
12181
12208
  var NLDDCodeViewer = (_NLDDCodeViewer = class NLDDCodeViewer extends NLDDCodeMirrorElement {
12182
12209
  constructor(..._args) {
12183
12210
  super(..._args);
12184
- this.variant = "box-tinted";
12211
+ this.appearance = "box-tinted";
12185
12212
  this.language = "";
12186
12213
  this.noCopy = false;
12187
12214
  this.wrap = false;
@@ -12273,19 +12300,20 @@ var NLDDCodeViewer = (_NLDDCodeViewer = class NLDDCodeViewer extends NLDDCodeMir
12273
12300
  updated(changed) {
12274
12301
  if (changed.has("noCopy")) this._copyUnavailable = !this.noCopy && !isClipboardAvailable();
12275
12302
  if (!this.view) return;
12303
+ if (this._isScrollable) this.view.scrollDOM.setAttribute("aria-label", this._t("components.code-viewer.region-label"));
12276
12304
  if (changed.has("language")) this._applyLanguage();
12277
12305
  if (changed.has("wrap")) {
12278
12306
  this.reconfigure(this._wrapCompartment, this.wrap ? EditorView.lineWrapping : []);
12279
12307
  this._updateScrollable();
12280
12308
  }
12281
- if (changed.has("variant") || changed.has("noCopy") || changed.has("_copyUnavailable")) this._updateScrollable();
12309
+ if (changed.has("appearance") || changed.has("noCopy") || changed.has("_copyUnavailable")) this._updateScrollable();
12282
12310
  }
12283
12311
  _onSlotChange() {
12284
12312
  this.setDoc(this._getRawText());
12285
12313
  this._updateScrollable();
12286
12314
  }
12287
12315
  _t(key) {
12288
- return this.translations[key] ?? nlddCodeViewerTranslations[key];
12316
+ return translate(this.translations, nlddCodeViewerTranslations, key);
12289
12317
  }
12290
12318
  async getUpdateComplete() {
12291
12319
  const result = await super.getUpdateComplete();
@@ -12370,7 +12398,7 @@ var NLDDCodeViewer = (_NLDDCodeViewer = class NLDDCodeViewer extends NLDDCodeMir
12370
12398
  __decorate([property({
12371
12399
  reflect: true,
12372
12400
  converter: reflectNonDefault("box-tinted")
12373
- })], NLDDCodeViewer.prototype, "variant", void 0);
12401
+ })], NLDDCodeViewer.prototype, "appearance", void 0);
12374
12402
  __decorate([property({
12375
12403
  reflect: true,
12376
12404
  converter: reflectNonDefault("")
@@ -12992,7 +13020,7 @@ var NLDDImage = (_NLDDImage = class NLDDImage extends LitElement {
12992
13020
  };
12993
13021
  }
12994
13022
  _t(key) {
12995
- return this.translations[key] ?? nlddImageTranslations[key];
13023
+ return translate(this.translations, nlddImageTranslations, key);
12996
13024
  }
12997
13025
  /** Parsed LQIP: 7 numbers in [0, 255] — base + 6 cells — or null when the
12998
13026
  * attribute is empty or malformed. Memoised against the raw lqip string,
@@ -13217,7 +13245,7 @@ var NLDDRichText = class NLDDRichText extends LitElement {
13217
13245
  this.hyphens = false;
13218
13246
  }
13219
13247
  _t(key) {
13220
- return this.translations[key] ?? nlddRichTextTranslations[key];
13248
+ return translate(this.translations, nlddRichTextTranslations, key);
13221
13249
  }
13222
13250
  createRenderRoot() {
13223
13251
  return this;
@@ -13240,6 +13268,10 @@ var NLDDRichText = class NLDDRichText extends LitElement {
13240
13268
  this._resizeObserver?.disconnect();
13241
13269
  this._resizeObserver = void 0;
13242
13270
  }
13271
+ /** The labels this component set itself follow a language switch. */
13272
+ updated() {
13273
+ for (const table of this.querySelectorAll(`table[${MANAGED_LABEL_ATTR}]`)) table.setAttribute("aria-label", this._t("components.rich-text.table-scroll-label"));
13274
+ }
13243
13275
  _syncTables() {
13244
13276
  for (const table of this.querySelectorAll("table")) if (table.scrollWidth > table.clientWidth) {
13245
13277
  if (table.getAttribute("tabindex") !== "0") {
@@ -13649,6 +13681,7 @@ var textStyles = css`
13649
13681
  color: var(--_color);
13650
13682
  text-align: var(--_text-align);
13651
13683
  font: var(--_font-weight) var(--_font-size) / var(--_line-height) var(--primitives-font-family-body);
13684
+ text-wrap: pretty;
13652
13685
  }
13653
13686
 
13654
13687
  :host([hidden]) {
@@ -14377,7 +14410,7 @@ function tokenTemplate(component) {
14377
14410
  <div class="token__dismiss-action">
14378
14411
  <nldd-icon-button
14379
14412
  size="sm"
14380
- variant="neutral-tinted"
14413
+ appearance="neutral-tinted"
14381
14414
  icon="dismiss-small"
14382
14415
  text=${component._dismissLabel}
14383
14416
  accessible-label=${component._dismissLabel}
@@ -14392,7 +14425,7 @@ function tokenTemplate(component) {
14392
14425
  <div class="token__menu-action">
14393
14426
  <nldd-icon-button
14394
14427
  size="sm"
14395
- variant="neutral-tinted"
14428
+ appearance="neutral-tinted"
14396
14429
  icon="chevron-down-small"
14397
14430
  text=${component._menuLabel}
14398
14431
  accessible-label=${component._menuLabel}
@@ -14482,7 +14515,7 @@ var NLDDToken = (_NLDDToken = class NLDDToken extends LitElement {
14482
14515
  this._slotText = [...this.childNodes].filter((node) => !(node instanceof Element && node.hasAttribute("slot"))).map((node) => node.textContent).join("").replace(/\s+/g, " ").trim();
14483
14516
  }
14484
14517
  _t(key) {
14485
- return this.translations[key] ?? nlddTokenTranslations[key];
14518
+ return translate(this.translations, nlddTokenTranslations, key);
14486
14519
  }
14487
14520
  get _dismissLabel() {
14488
14521
  const label = this.text || this._slotText;
@@ -14924,7 +14957,7 @@ function formActionsTemplate() {
14924
14957
  * <nldd-form-field>...</nldd-form-field>
14925
14958
  * <nldd-form-actions>
14926
14959
  * <nldd-button-group>
14927
- * <nldd-button variant="primary" type="submit" text="Bewaar"></nldd-button>
14960
+ * <nldd-button appearance="primary" type="submit" text="Bewaar"></nldd-button>
14928
14961
  * </nldd-button-group>
14929
14962
  * </nldd-form-actions>
14930
14963
  * </nldd-form>
@@ -18420,9 +18453,9 @@ var codeEditorStyles = css`
18420
18453
  }
18421
18454
 
18422
18455
 
18423
- /* ## Variant — input-field adds the framed surface + a default content padding */
18456
+ /* ## Appearance — input-field adds the framed surface + a default content padding */
18424
18457
 
18425
- :host([variant="input-field"]) {
18458
+ :host([appearance="input-field"]) {
18426
18459
  --_corner-radius: var(--primitives-corner-radius-lg);
18427
18460
  /* Match the other input fields (text-field, textarea): the input-field
18428
18461
  surface + border + control padding, not the tinted surface. */
@@ -18459,7 +18492,7 @@ var codeEditorStyles = css`
18459
18492
 
18460
18493
  /* Focus ring only on the input-field variant. The simple variant relies on a
18461
18494
  prominent caret and lets a wrapping composition own its focus treatment. */
18462
- :host([variant="input-field"]) .code-editor:focus-within {
18495
+ :host([appearance="input-field"]) .code-editor:focus-within {
18463
18496
  outline: var(--semantics-focus-ring-outline);
18464
18497
  outline-offset: var(--semantics-focus-ring-outline-offset);
18465
18498
  box-shadow: var(--semantics-focus-ring-box-shadow), var(--_border-shadow);
@@ -18521,10 +18554,10 @@ function codeEditorTemplate(_component) {
18521
18554
  * on CodeMirror 6 (via NLDDCodeMirrorElement). Visually pairs with
18522
18555
  * nldd-code-viewer for a matching read-only surface.
18523
18556
  *
18524
- * Default `variant="simple"` is a bare, flush editor (no frame, no focus ring)
18557
+ * Default `appearance="simple"` is a bare, flush editor (no frame, no focus ring)
18525
18558
  * for use inside an nldd-form-field or a consumer composition that owns its own
18526
18559
  * chrome and focus treatment; the caret is rendered as a prominent accent as
18527
- * the focus cue. `variant="input-field"` adds the framed surface (border ring, tinted
18560
+ * the focus cue. `appearance="input-field"` adds the framed surface (border ring, tinted
18528
18561
  * fill, inner padding, radius) and a focus ring for standalone use.
18529
18562
  *
18530
18563
  * The simple variant has no surrounding space of its own: let a layout
@@ -18546,7 +18579,7 @@ function codeEditorTemplate(_component) {
18546
18579
  * @attr {boolean} wrap - Wrap long lines instead of horizontal scroll
18547
18580
  * @attr {number} rows - Minimum visible rows (the floor in every resize mode). Default: 6.
18548
18581
  * @attr {string} resize - 'none' (fixed) | 'vertical' (drag) | 'auto' (grow, default)
18549
- * @attr {string} variant - 'simple' (default, bare) | 'input-field' (framed surface)
18582
+ * @attr {string} appearance - 'simple' (default, bare) | 'input-field' (framed surface)
18550
18583
  * @attr {string} language - Highlight grammar (yaml, json, javascript, typescript, css, html, xml, bash, markdown, rust, gherkin, toml, sql, python). Empty disables highlighting.
18551
18584
  * @attr {boolean} line-numbers - Show a line-number gutter
18552
18585
  * @attr {string} accessible-label - Accessible label forwarded to the editor. Set automatically by nldd-form-field.
@@ -18572,7 +18605,7 @@ var NLDDCodeEditor = (_NLDDCodeEditor = class NLDDCodeEditor extends DescribedBy
18572
18605
  this.wrap = false;
18573
18606
  this.rows = 6;
18574
18607
  this.resize = "auto";
18575
- this.variant = "simple";
18608
+ this.appearance = "simple";
18576
18609
  this.language = "";
18577
18610
  this.lineNumbers = false;
18578
18611
  this.accessibleLabel = "";
@@ -18775,7 +18808,7 @@ __decorate([property({
18775
18808
  __decorate([property({
18776
18809
  reflect: true,
18777
18810
  converter: reflectNonDefault("simple")
18778
- })], NLDDCodeEditor.prototype, "variant", void 0);
18811
+ })], NLDDCodeEditor.prototype, "appearance", void 0);
18779
18812
  __decorate([property({
18780
18813
  reflect: true,
18781
18814
  converter: reflectNonDefault("")
@@ -19037,7 +19070,7 @@ function comboBoxTemplate(component) {
19037
19070
  ${component.text && !component.readonly ? html`
19038
19071
  <div class="combo-box__clear-button">
19039
19072
  <nldd-icon-button
19040
- variant="neutral-transparent"
19073
+ appearance="neutral-transparent"
19041
19074
  size=${iconButtonSize}
19042
19075
  icon="dismiss"
19043
19076
  text=${component._t("components.combo-box.clear-action")}
@@ -19051,7 +19084,7 @@ function comboBoxTemplate(component) {
19051
19084
  ${component.readonly ? nothing : html`
19052
19085
  <div class="combo-box__picker-button">
19053
19086
  <nldd-icon-button
19054
- variant="neutral-tinted"
19087
+ appearance="neutral-tinted"
19055
19088
  size=${iconButtonSize}
19056
19089
  icon="chevron-down"
19057
19090
  text=${component._t("components.combo-box.open-menu-action")}
@@ -19170,7 +19203,8 @@ function submitOnEnter(host, event) {
19170
19203
  * @attr {boolean} invalid - Marks the field as invalid
19171
19204
  * @attr {boolean} disabled - Disabled state
19172
19205
  * @attr {boolean} readonly - Read-only state: the value stays readable, selectable and in the tab order, but the menu does not open and there is nothing to clear. The input drops its combobox role and the aria that goes with it, so assistive technology is not told about a list it cannot open. Use this where the value belongs to the record rather than to the form, e.g. the product an asset is an instance of.
19173
- * @attr {boolean} allow-custom - Allow committing free-typed values that match no option (Enter/blur). Default false: only menu options are accepted.
19206
+ * @attr {boolean} allow-custom - Allow committing free-typed values that match no option (Enter/blur). Default false: only menu options are accepted. Typing an option's label in full picks that option, ignoring case and the spaces around it; with two such labels, the first one.
19207
+ * @attr {boolean} no-filter - Leaves the options as they are while typing, for a list your server already filtered per keystroke. Without it the field hides options that do not contain the typed text, which also hides a server match on, say, an e-mail address.
19174
19208
  * @attr {string} name - Input name for form submission
19175
19209
  * @attr {string} autocomplete - Browser autofill hint. Default 'off' to prevent the native autofill panel from competing with the menu dropdown. Set to a valid token (e.g. 'country', 'organization') when browser autofill is desired.
19176
19210
  * @attr {string} accessible-label - Accessible label forwarded as aria-label to the input. Required for screen reader accessibility.
@@ -19186,7 +19220,14 @@ function submitOnEnter(host, event) {
19186
19220
  * @note Free-text values: only when `allow-custom` is set. Then a typed value that
19187
19221
  * matches no menu option is emitted as-is via the `change` event on Enter or blur
19188
19222
  * (consumers validate emitted values). Without it, such a value is discarded and
19189
- * the input reverts to the current value.
19223
+ * the input reverts to the current value. Only text the user typed is committed:
19224
+ * the label of a chosen option stays a label, and typing an option's label in full
19225
+ * picks that option and its value.
19226
+ *
19227
+ * Options can arrive after the keystroke, from a server you query per
19228
+ * keystroke. Slot them into the menu when they come in: if the user is still
19229
+ * in the field and the keystroke found nothing to show, the menu opens then.
19230
+ * After Escape, or once the user left the field, it stays shut.
19190
19231
  *
19191
19232
  * @slot - An nldd-menu element with nldd-menu-item and nldd-menu-divider children
19192
19233
  *
@@ -19222,6 +19263,7 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19222
19263
  this.disabled = false;
19223
19264
  this.readonly = false;
19224
19265
  this.allowCustom = false;
19266
+ this.noFilter = false;
19225
19267
  this.name = "";
19226
19268
  this.autocomplete = "off";
19227
19269
  this.maxItems = 8;
@@ -19234,6 +19276,9 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19234
19276
  this._menuId = `nldd-combo-box-menu-${_NLDDComboBox._idCounter++}`;
19235
19277
  this._menu = null;
19236
19278
  this._resizeObserver = null;
19279
+ this._menuObserver = null;
19280
+ this._openPending = false;
19281
+ this._typedText = null;
19237
19282
  this.required = false;
19238
19283
  this.pattern = "";
19239
19284
  this._handleScrollOrResize = () => {
@@ -19244,13 +19289,17 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19244
19289
  this._handleMenuToggle = (e) => {
19245
19290
  this._isOpen = e.newState === "open";
19246
19291
  if (!this._isOpen) this._highlightedId = "";
19247
- else requestAnimationFrame(() => {
19248
- if (this._menu && !this._menu.getHighlighted()) this._menu.moveHighlight("next");
19249
- this._highlightedId = this._menu?.getHighlightedId() ?? "";
19250
- });
19292
+ else {
19293
+ this._openPending = false;
19294
+ requestAnimationFrame(() => {
19295
+ if (this._menu && !this._menu.getHighlighted()) this._menu.moveHighlight("next");
19296
+ this._highlightedId = this._menu?.getHighlightedId() ?? "";
19297
+ });
19298
+ }
19251
19299
  };
19252
19300
  this._handleMenuSelect = (e) => {
19253
19301
  const item = e.target;
19302
+ this._typedText = null;
19254
19303
  this.text = item.text;
19255
19304
  this.value = item.value || item.text;
19256
19305
  this._highlightedId = "";
@@ -19264,6 +19313,17 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19264
19313
  }));
19265
19314
  this._input?.focus();
19266
19315
  };
19316
+ this._handleMenuItemsChange = () => {
19317
+ if (!this._menu || this.shadowRoot?.activeElement !== this._input) return;
19318
+ if (this._menu.matches(":popover-open")) {
19319
+ if (this.allowCustom && !this._hasVisibleMenuItems()) this._closeMenu();
19320
+ return;
19321
+ }
19322
+ if (this._openPending && this._hasVisibleMenuItems()) {
19323
+ this._openPending = false;
19324
+ this._openMenu();
19325
+ }
19326
+ };
19267
19327
  this._pickerPointerdownWhileOpen = false;
19268
19328
  this._handleMenuKeydown = (e) => {
19269
19329
  if (e.key !== "Tab") return;
@@ -19273,7 +19333,7 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19273
19333
  };
19274
19334
  }
19275
19335
  _t(key) {
19276
- return this.translations[key] ?? nlddComboBoxTranslations[key];
19336
+ return translate(this.translations, nlddComboBoxTranslations, key);
19277
19337
  }
19278
19338
  firstUpdated() {
19279
19339
  this._initialValue = this.value;
@@ -19281,6 +19341,7 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19281
19341
  }
19282
19342
  willUpdate(changedProperties) {
19283
19343
  if (changedProperties.has("value") && !changedProperties.has("text")) this._deriveTextFromMenu();
19344
+ if (changedProperties.has("value")) this._typedText = null;
19284
19345
  }
19285
19346
  updated(changedProperties) {
19286
19347
  if (changedProperties.has("maxItems") && this._menu) this._menu.maxItems = this.maxItems;
@@ -19328,6 +19389,8 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19328
19389
  this._resizeObserver = null;
19329
19390
  window.removeEventListener("scroll", this._handleScrollOrResize, true);
19330
19391
  window.removeEventListener("resize", this._handleScrollOrResize);
19392
+ this._menuObserver?.disconnect();
19393
+ this._menuObserver = null;
19331
19394
  if (this._menu) {
19332
19395
  this._menu.removeEventListener("toggle", this._handleMenuToggle);
19333
19396
  this._menu.removeEventListener("select", this._handleMenuSelect);
@@ -19347,6 +19410,14 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19347
19410
  menu.addEventListener("toggle", this._handleMenuToggle);
19348
19411
  menu.addEventListener("select", this._handleMenuSelect);
19349
19412
  menu.addEventListener("keydown", this._handleMenuKeydown);
19413
+ this._menuObserver?.disconnect();
19414
+ this._menuObserver = new MutationObserver(this._handleMenuItemsChange);
19415
+ this._menuObserver.observe(menu, {
19416
+ childList: true,
19417
+ subtree: true,
19418
+ attributes: true,
19419
+ attributeFilter: ["hidden"]
19420
+ });
19350
19421
  this._updateMenuWidth();
19351
19422
  if (this.value && !this.text) this._deriveTextFromMenu();
19352
19423
  }
@@ -19361,8 +19432,7 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19361
19432
  this.text = "";
19362
19433
  return;
19363
19434
  }
19364
- const items = Array.from(this._menu.querySelectorAll("nldd-menu-item")).filter((item) => item.closest("nldd-menu") === this._menu);
19365
- for (const item of items) if ((item.value || item.text) === this.value) {
19435
+ for (const item of this._ownMenuItems()) if ((item.value || item.text) === this.value) {
19366
19436
  this.text = item.text;
19367
19437
  return;
19368
19438
  }
@@ -19390,10 +19460,18 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19390
19460
  this._updateMenuWidth();
19391
19461
  this._menu.showPopover();
19392
19462
  }
19463
+ /**
19464
+ * The items that belong to the wired menu itself. A nested nldd-menu
19465
+ * submenu's items are left out, so they cannot match before the intended
19466
+ * top-level item when values or labels overlap.
19467
+ */
19468
+ _ownMenuItems() {
19469
+ if (!this._menu) return [];
19470
+ return Array.from(this._menu.querySelectorAll("nldd-menu-item")).filter((item) => item.closest("nldd-menu") === this._menu);
19471
+ }
19393
19472
  /** Top-level menu items that survived the current filter. */
19394
19473
  _hasVisibleMenuItems() {
19395
- if (!this._menu) return false;
19396
- return Array.from(this._menu.querySelectorAll("nldd-menu-item:not([hidden])")).some((item) => item.closest("nldd-menu") === this._menu);
19474
+ return this._ownMenuItems().some((item) => !item.hidden);
19397
19475
  }
19398
19476
  _closeMenu() {
19399
19477
  if (!this._menu || !this._isOpen) return;
@@ -19418,10 +19496,12 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19418
19496
  _handleInput(e) {
19419
19497
  const input = e.target;
19420
19498
  this.text = input.value;
19421
- this._menu?.filter(this.text);
19499
+ this._typedText = input.value;
19500
+ this._menu?.filter(this.text, { hide: !this.noFilter });
19422
19501
  this._updateActiveDescendant();
19423
19502
  if (this.allowCustom && this._isOpen && !this._hasVisibleMenuItems()) this._closeMenu();
19424
19503
  if (!this._isOpen) this._openMenu();
19504
+ this._openPending = this.text !== "" && !this._menu?.matches(":popover-open");
19425
19505
  this.commitFormValue();
19426
19506
  this.dispatchEvent(new CustomEvent("input", {
19427
19507
  detail: { value: this.text },
@@ -19451,6 +19531,7 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19451
19531
  /** On blur: with allow-custom, accept a custom typed value; otherwise discard a
19452
19532
  * non-matching typed value by reverting the input to the current value. */
19453
19533
  _handleBlur(e) {
19534
+ this._openPending = false;
19454
19535
  if (this.readonly) return;
19455
19536
  const relatedTarget = e.relatedTarget;
19456
19537
  const focusMovedIntoMenu = !!relatedTarget && !!this._menu?.contains(relatedTarget);
@@ -19459,15 +19540,31 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19459
19540
  if (!focusMovedIntoMenu) this._revertTextToValue();
19460
19541
  return;
19461
19542
  }
19462
- if (this.text !== "" && this.text !== this.value) {
19463
- this.value = this.text;
19464
- this.commitFormValue();
19465
- this.dispatchEvent(new CustomEvent("change", {
19466
- detail: { value: this.value },
19467
- bubbles: true,
19468
- composed: true
19469
- }));
19470
- }
19543
+ if (this._hasTypedCustomText()) this._commitTypedText();
19544
+ }
19545
+ /**
19546
+ * With allow-custom, only text the user typed becomes the value. `text`
19547
+ * differing from `value` is not the sign of that: it is the normal state after
19548
+ * every choice from the menu ("Nederland" for "nl"), and committing it would
19549
+ * send the label to the server instead of the value.
19550
+ */
19551
+ _hasTypedCustomText() {
19552
+ return this._typedText !== null && this.text === this._typedText && this.text !== "" && this.text !== this.value;
19553
+ }
19554
+ _commitTypedText() {
19555
+ const typed = this.text.trim().toLowerCase();
19556
+ const option = this._ownMenuItems().find((item) => item.text.trim().toLowerCase() === typed);
19557
+ if (option) this.text = option.text;
19558
+ const value = option ? option.value || option.text : this.text;
19559
+ this._typedText = null;
19560
+ if (value === this.value) return;
19561
+ this.value = value;
19562
+ this.commitFormValue();
19563
+ this.dispatchEvent(new CustomEvent("change", {
19564
+ detail: { value: this.value },
19565
+ bubbles: true,
19566
+ composed: true
19567
+ }));
19471
19568
  }
19472
19569
  /** Restore the input text to the current value's display label, discarding any
19473
19570
  * free text the user typed (used when allow-custom is off). */
@@ -19477,6 +19574,7 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19477
19574
  this._menu?.filter("");
19478
19575
  }
19479
19576
  _handleKeydown(e) {
19577
+ if (e.key === "Escape") this._openPending = false;
19480
19578
  if (this.readonly) {
19481
19579
  if (e.key === "Enter") submitOnEnter(this, e);
19482
19580
  return;
@@ -19485,16 +19583,10 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19485
19583
  if (e.key === "ArrowDown") {
19486
19584
  e.preventDefault();
19487
19585
  this._openMenu();
19488
- } else if (e.key === "Enter" && this.allowCustom && this.text !== "" && this.text !== this.value) {
19586
+ } else if (e.key === "Enter" && this.allowCustom && this._hasTypedCustomText()) {
19489
19587
  e.preventDefault();
19490
19588
  e.stopPropagation();
19491
- this.value = this.text;
19492
- this.commitFormValue();
19493
- this.dispatchEvent(new CustomEvent("change", {
19494
- detail: { value: this.value },
19495
- bubbles: true,
19496
- composed: true
19497
- }));
19589
+ this._commitTypedText();
19498
19590
  } else if (e.key === "Enter") submitOnEnter(this, e);
19499
19591
  return;
19500
19592
  }
@@ -19515,14 +19607,8 @@ var NLDDComboBox = (_NLDDComboBox2 = class NLDDComboBox extends DescribedBy(Form
19515
19607
  const highlighted = this._menu?.getHighlighted();
19516
19608
  if (highlighted) highlighted.select();
19517
19609
  else if (this.allowCustom) {
19518
- this.value = this.text;
19519
19610
  this._closeMenu();
19520
- this.commitFormValue();
19521
- this.dispatchEvent(new CustomEvent("change", {
19522
- detail: { value: this.value },
19523
- bubbles: true,
19524
- composed: true
19525
- }));
19611
+ if (this._hasTypedCustomText()) this._commitTypedText();
19526
19612
  } else {
19527
19613
  this._closeMenu();
19528
19614
  this._revertTextToValue();
@@ -19578,6 +19664,11 @@ __decorate([property({
19578
19664
  reflect: true,
19579
19665
  attribute: "allow-custom"
19580
19666
  })], NLDDComboBox.prototype, "allowCustom", void 0);
19667
+ __decorate([property({
19668
+ type: Boolean,
19669
+ reflect: true,
19670
+ attribute: "no-filter"
19671
+ })], NLDDComboBox.prototype, "noFilter", void 0);
19581
19672
  __decorate([property({
19582
19673
  reflect: true,
19583
19674
  converter: reflectNonDefault("")
@@ -20103,7 +20194,7 @@ function topTitleBarTemplate(component) {
20103
20194
  <div class="top-title-bar__back-button">
20104
20195
  <div class="top-title-bar__text-back-button">
20105
20196
  <nldd-button
20106
- variant="accent-transparent"
20197
+ appearance="accent-transparent"
20107
20198
  start-icon="chevron-left"
20108
20199
  text=${component.backText}
20109
20200
  href=${component.backHref || nothing}
@@ -20113,7 +20204,7 @@ function topTitleBarTemplate(component) {
20113
20204
  </div>
20114
20205
  <div class="top-title-bar__icon-back-button">
20115
20206
  <nldd-icon-button
20116
- variant="accent-transparent"
20207
+ appearance="accent-transparent"
20117
20208
  icon="chevron-left"
20118
20209
  text=${component.backText}
20119
20210
  accessible-label=${component.backText || nothing}
@@ -20143,7 +20234,7 @@ function topTitleBarTemplate(component) {
20143
20234
  ${component.dismissText ? html`
20144
20235
  <div class="top-title-bar__dismiss-button">
20145
20236
  <nldd-button
20146
- variant="accent-transparent"
20237
+ appearance="accent-transparent"
20147
20238
  text=${component.dismissText}
20148
20239
  @click=${component._handleDismiss}
20149
20240
  ></nldd-button>
@@ -20913,7 +21004,7 @@ function renderPagination(component, size, variant) {
20913
21004
  return html`
20914
21005
  <nldd-button-bar
20915
21006
  size=${size}
20916
- variant=${variant}
21007
+ appearance=${variant}
20917
21008
  >
20918
21009
  <nldd-icon-button
20919
21010
  icon="chevron-left"
@@ -20943,7 +21034,7 @@ function renderFooter(component, withPagination) {
20943
21034
  ${component._todayReachable ? html`
20944
21035
  <nldd-button
20945
21036
  size=${withPagination ? "md" : "sm"}
20946
- variant="neutral-tinted"
21037
+ appearance="neutral-tinted"
20947
21038
  text=${component._t("components.date-picker.view-today-action")}
20948
21039
  @click=${component._handleToday}
20949
21040
  ></nldd-button>
@@ -21740,7 +21831,7 @@ function renderPicker$2(component) {
21740
21831
  return html`
21741
21832
  <div class="date-field__picker-button">
21742
21833
  <nldd-icon-button
21743
- variant="neutral-tinted"
21834
+ appearance="neutral-tinted"
21744
21835
  size=${buttonSize}
21745
21836
  icon="calendar"
21746
21837
  text=${component._t("components.date-field.to-pick-date-action")}
@@ -22055,7 +22146,7 @@ var NLDDDateField = (_NLDDDateField = class NLDDDateField extends DescribedBy(Fo
22055
22146
  if (typeof state === "string") this.value = state;
22056
22147
  }
22057
22148
  _t(key) {
22058
- return this.translations[key] ?? nlddDateFieldTranslations[key];
22149
+ return translate(this.translations, nlddDateFieldTranslations, key);
22059
22150
  }
22060
22151
  /**
22061
22152
  * The field's accessible name, with a fallback so the input is never nameless.
@@ -22302,6 +22393,9 @@ var dropdownStyles = css`
22302
22393
  --_validation-icon-area-padding-right: var(--primitives-space-4);
22303
22394
  --_validation-icon-size: var(--semantics-input-fields-md-validation-icon-size);
22304
22395
  --_picker-icon-size: var(--primitives-space-24);
22396
+ --_picker-area: calc((var(--_min-size) + var(--_picker-icon-size)) / 2);
22397
+ --_end-inset: var(--_picker-area);
22398
+ --_fade-size: var(--primitives-space-24);
22305
22399
  --_background-color: var(--semantics-buttons-neutral-tinted-background-color);
22306
22400
  --_content-color: var(--semantics-buttons-neutral-tinted-content-color);
22307
22401
  --_is-hovered-background-color: var(--semantics-buttons-neutral-tinted-is-hovered-background-color);
@@ -22326,6 +22420,11 @@ var dropdownStyles = css`
22326
22420
  display: none;
22327
22421
  }
22328
22422
 
22423
+ :host([valid]),
22424
+ :host([invalid]) {
22425
+ --_end-inset: calc(var(--_picker-area) + var(--_validation-icon-size) + var(--_validation-icon-area-padding-right));
22426
+ }
22427
+
22329
22428
  :host([size="xs"]) {
22330
22429
  --_corner-radius: var(--semantics-controls-xs-corner-radius);
22331
22430
  --_min-size: var(--semantics-controls-xs-min-size);
@@ -22375,6 +22474,7 @@ var dropdownStyles = css`
22375
22474
  min-height: var(--_min-size);
22376
22475
  flex-direction: row;
22377
22476
  align-items: center;
22477
+ justify-content: flex-end;
22378
22478
  color: var(--_content-color);
22379
22479
  transition:
22380
22480
  background-color var(--primitives-transition-duration-fast) var(--primitives-transition-easing-default),
@@ -22423,30 +22523,33 @@ var dropdownStyles = css`
22423
22523
 
22424
22524
  ::slotted(select) {
22425
22525
  ${slottedReset}
22526
+ ${inheritedTextReset}
22426
22527
  box-sizing: border-box !important;
22427
22528
  position: absolute !important;
22428
22529
  inset: 0 !important;
22429
- opacity: 0 !important;
22530
+ overflow: hidden !important;
22430
22531
  margin: 0 !important;
22431
22532
  outline: none !important;
22432
22533
  border: none !important;
22433
22534
  background: transparent !important;
22434
22535
  width: 100% !important;
22435
22536
  height: 100% !important;
22436
- padding: 0 !important;
22437
- font: var(--semantics-input-fields-native-select-font) !important;
22537
+ padding-block: 0 !important;
22538
+ padding-inline: var(--_inline-padding) var(--_end-inset) !important;
22539
+ color: inherit !important;
22540
+ font: var(--_text-font) !important;
22541
+ white-space: nowrap !important;
22438
22542
  appearance: none !important;
22543
+ /* WebKit lets select text run through its end padding and has no ellipsis
22544
+ there, so every browser fades the text out before the icons instead. */
22545
+ mask-image: linear-gradient(to left, transparent var(--_end-inset), black calc(var(--_end-inset) + var(--_fade-size))) !important;
22439
22546
  }
22440
22547
 
22441
- .dropdown__value {
22442
- min-width: 0;
22443
- overflow: hidden;
22444
- padding: 0 var(--_inline-padding);
22445
- flex-grow: 1;
22446
- color: inherit;
22447
- font: var(--_text-font);
22448
- white-space: nowrap;
22449
- text-overflow: ellipsis;
22548
+ :host([size="xs"]) ::slotted(select) {
22549
+ /* iOS Safari zooms in on a select below 16px when it gets focus. */
22550
+ @media (pointer: coarse) {
22551
+ font: var(--semantics-input-fields-native-select-font) !important;
22552
+ }
22450
22553
  }
22451
22554
 
22452
22555
  .dropdown__validation-icon-area {
@@ -22507,7 +22610,6 @@ function dropdownTemplate(component) {
22507
22610
  return html`
22508
22611
  <div class="dropdown">
22509
22612
  <slot @slotchange=${component._onSlotChange}></slot>
22510
- <span class="dropdown__value">${component._displayValue}</span>
22511
22613
  ${renderValidationIcon$6(component)}
22512
22614
  <div class="dropdown__picker-icon">
22513
22615
  <nldd-icon icon="chevron-up-chevron-down"></nldd-icon>
@@ -22562,14 +22664,12 @@ var NLDDDropdown = (_NLDDDropdown = class NLDDDropdown extends DescribedBy(LitEl
22562
22664
  this.expanded = false;
22563
22665
  this.width = "";
22564
22666
  this.accessibleLabel = "";
22565
- this._displayValue = "";
22566
22667
  this._select = null;
22567
22668
  this.required = false;
22568
22669
  this._appliedLabel = null;
22569
22670
  this._appliedRequired = null;
22570
22671
  this._handleSelectChange = (e) => {
22571
22672
  e.stopPropagation();
22572
- this._syncDisplayValue();
22573
22673
  this.dispatchEvent(new CustomEvent("change", {
22574
22674
  detail: { value: this._select?.value ?? "" },
22575
22675
  bubbles: true,
@@ -22612,7 +22712,6 @@ var NLDDDropdown = (_NLDDDropdown = class NLDDDropdown extends DescribedBy(LitEl
22612
22712
  }
22613
22713
  this._select = select;
22614
22714
  if (!select) {
22615
- this._displayValue = "";
22616
22715
  this.expanded = false;
22617
22716
  return;
22618
22717
  }
@@ -22625,7 +22724,6 @@ var NLDDDropdown = (_NLDDDropdown = class NLDDDropdown extends DescribedBy(LitEl
22625
22724
  this._syncAriaInvalid();
22626
22725
  this._syncAccessibleLabel();
22627
22726
  this._syncRequired();
22628
- this._syncDisplayValue();
22629
22727
  }
22630
22728
  _syncDisabled() {
22631
22729
  if (!this._select) return;
@@ -22666,10 +22764,6 @@ var NLDDDropdown = (_NLDDDropdown = class NLDDDropdown extends DescribedBy(LitEl
22666
22764
  if (this.invalid) this._select.setAttribute("aria-invalid", "true");
22667
22765
  else this._select.removeAttribute("aria-invalid");
22668
22766
  }
22669
- _syncDisplayValue() {
22670
- if (!this._select) return;
22671
- this._displayValue = this._select.selectedOptions[0]?.text ?? "";
22672
- }
22673
22767
  /**
22674
22768
  * Delegates focus to the slotted `<select>`. The wrapper itself is not
22675
22769
  * focusable, so without this a label pointing at the dropdown has nowhere
@@ -22714,7 +22808,6 @@ __decorate([property({
22714
22808
  type: String,
22715
22809
  attribute: "accessible-label"
22716
22810
  })], NLDDDropdown.prototype, "accessibleLabel", void 0);
22717
- __decorate([state()], NLDDDropdown.prototype, "_displayValue", void 0);
22718
22811
  __decorate([property({
22719
22812
  type: Boolean,
22720
22813
  reflect: true
@@ -22883,7 +22976,7 @@ function fileFieldTemplate(component) {
22883
22976
  >
22884
22977
  <div class="file-field__choose-button">
22885
22978
  <nldd-button
22886
- variant="neutral-tinted"
22979
+ appearance="neutral-tinted"
22887
22980
  size=${component.size}
22888
22981
  text=${component._chooseLabel()}
22889
22982
  accessible-label=${component._chooseAccessibleLabel() || nothing}
@@ -22900,7 +22993,7 @@ function fileFieldTemplate(component) {
22900
22993
  ${hasFiles ? html`
22901
22994
  <div class="file-field__clear-button">
22902
22995
  <nldd-icon-button
22903
- variant="neutral-transparent"
22996
+ appearance="neutral-transparent"
22904
22997
  size=${buttonSize}
22905
22998
  icon="dismiss"
22906
22999
  text=${component._t("components.file-field.clear-action")}
@@ -22989,9 +23082,7 @@ var NLDDFileField = (_NLDDFileField = class NLDDFileField extends DescribedBy(Fo
22989
23082
  }
22990
23083
  /** @internal */
22991
23084
  _t(key, vars) {
22992
- let text = this.translations[key] ?? nlddFileFieldTranslations[key];
22993
- if (vars) for (const [name, value] of Object.entries(vars)) text = text.split(`{${name}}`).join(String(value));
22994
- return text;
23085
+ return translate(this.translations, nlddFileFieldTranslations, key, vars);
22995
23086
  }
22996
23087
  /** @internal */
22997
23088
  _chooseLabel() {
@@ -23658,7 +23749,7 @@ function numberFieldTemplate(component) {
23658
23749
  ${!component.hideSpinButtons ? html`
23659
23750
  <div class="number-field__decrement-button">
23660
23751
  <nldd-icon-button
23661
- variant="neutral-tinted"
23752
+ appearance="neutral-tinted"
23662
23753
  size=${iconButtonSize}
23663
23754
  icon="minus"
23664
23755
  text=${component._t("components.number-field.decrement-action")}
@@ -23685,7 +23776,7 @@ function numberFieldTemplate(component) {
23685
23776
  ${!component.hideSpinButtons ? html`
23686
23777
  <div class="number-field__increment-button">
23687
23778
  <nldd-icon-button
23688
- variant="neutral-tinted"
23779
+ appearance="neutral-tinted"
23689
23780
  size=${iconButtonSize}
23690
23781
  icon="plus"
23691
23782
  text=${component._t("components.number-field.increment-action")}
@@ -23772,7 +23863,7 @@ var NLDDNumberField = (_NLDDNumberField = class NLDDNumberField extends Describe
23772
23863
  if (!isNaN(parsed)) this.value = this._clamp(parsed);
23773
23864
  }
23774
23865
  _t(key) {
23775
- return this.translations[key] ?? nlddNumberFieldTranslations[key];
23866
+ return translate(this.translations, nlddNumberFieldTranslations, key);
23776
23867
  }
23777
23868
  _handleDecrease() {
23778
23869
  if (this.disabled) return;
@@ -25489,7 +25580,7 @@ function searchFieldTemplate(component) {
25489
25580
  ${component.value ? html`
25490
25581
  <div class="search-field__clear-button">
25491
25582
  <nldd-icon-button
25492
- variant="neutral-transparent"
25583
+ appearance="neutral-transparent"
25493
25584
  size=${buttonSize}
25494
25585
  icon="dismiss"
25495
25586
  text=${component._t("components.search-field.clear-action")}
@@ -25500,7 +25591,7 @@ function searchFieldTemplate(component) {
25500
25591
  ${component.showSearchButton ? html`
25501
25592
  <div class="search-field__search-button">
25502
25593
  <nldd-button
25503
- variant="neutral-tinted"
25594
+ appearance="neutral-tinted"
25504
25595
  size=${buttonSize}
25505
25596
  text=${component._t("components.search-field.search-action")}
25506
25597
  @click=${component._handleSearch}
@@ -25586,7 +25677,7 @@ var NLDDSearchField = (_NLDDSearchField = class NLDDSearchField extends Describe
25586
25677
  if (typeof state === "string") this.value = state;
25587
25678
  }
25588
25679
  _t(key) {
25589
- return this.translations[key] ?? nlddSearchFieldTranslations[key];
25680
+ return translate(this.translations, nlddSearchFieldTranslations, key);
25590
25681
  }
25591
25682
  _handleInput(e) {
25592
25683
  e.stopPropagation();
@@ -25717,6 +25808,8 @@ var segmentedControlStyles = css`
25717
25808
 
25718
25809
  :host {
25719
25810
  --_corner-radius: var(--semantics-controls-md-corner-radius);
25811
+ --_background-color: var(--semantics-buttons-neutral-tinted-background-color);
25812
+ --_highlight-border-color: var(--semantics-buttons-neutral-tinted-highlight-border-color);
25720
25813
  --_width: auto;
25721
25814
  --_gap: var(--primitives-space-1);
25722
25815
  --_selected-z-index: 1;
@@ -25726,7 +25819,7 @@ var segmentedControlStyles = css`
25726
25819
  display: inline-grid;
25727
25820
  position: relative;
25728
25821
  border-radius: var(--_corner-radius);
25729
- background-color: var(--semantics-buttons-neutral-tinted-background-color);
25822
+ background-color: var(--_background-color);
25730
25823
  width: var(--_width);
25731
25824
  max-width: 100%;
25732
25825
  grid-auto-columns: 1fr;
@@ -25743,10 +25836,15 @@ var segmentedControlStyles = css`
25743
25836
  position: absolute;
25744
25837
  inset: 0;
25745
25838
  border-radius: inherit;
25746
- box-shadow: inset 0 0 0 var(--primitives-border-width-thin) var(--semantics-buttons-neutral-tinted-highlight-border-color);
25839
+ box-shadow: inset 0 0 0 var(--primitives-border-width-thin) var(--_highlight-border-color);
25747
25840
  pointer-events: none;
25748
25841
  }
25749
25842
 
25843
+ :host([appearance="neutral-base"]) {
25844
+ --_background-color: var(--semantics-buttons-neutral-base-background-color);
25845
+ --_highlight-border-color: var(--semantics-buttons-neutral-base-highlight-border-color);
25846
+ }
25847
+
25750
25848
  :host([size="sm"]) {
25751
25849
  --_corner-radius: var(--semantics-controls-sm-corner-radius);
25752
25850
  }
@@ -25801,6 +25899,20 @@ var segmentedControlItemStyles = css`
25801
25899
  --_font: var(--semantics-buttons-md-primary-text-font);
25802
25900
  --_icon-size: var(--semantics-buttons-md-icon-size);
25803
25901
  --_highlight-border-color: transparent;
25902
+ --_content-color: var(--semantics-buttons-neutral-tinted-content-color);
25903
+ --_is-hovered-background-color: var(--semantics-buttons-neutral-tinted-is-hovered-background-color);
25904
+ --_is-hovered-content-color: var(--semantics-buttons-neutral-tinted-is-hovered-content-color);
25905
+ --_is-active-background-color: var(--semantics-buttons-neutral-tinted-is-active-background-color);
25906
+ --_is-active-content-color: var(--semantics-buttons-neutral-tinted-is-active-content-color);
25907
+ --_is-selected-background-color: var(--semantics-buttons-neutral-tinted-is-selected-background-color);
25908
+ --_is-selected-content-color: var(--semantics-buttons-neutral-tinted-is-selected-content-color);
25909
+ --_is-selected-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-highlight-border-color);
25910
+ --_is-selected-is-hovered-background-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-background-color);
25911
+ --_is-selected-is-hovered-content-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-content-color);
25912
+ --_is-selected-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-highlight-border-color);
25913
+ --_is-selected-is-active-background-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-background-color);
25914
+ --_is-selected-is-active-content-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-content-color);
25915
+ --_is-selected-is-active-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-highlight-border-color);
25804
25916
 
25805
25917
  ${inheritedTextReset}
25806
25918
  display: flex;
@@ -25809,6 +25921,23 @@ var segmentedControlItemStyles = css`
25809
25921
  -webkit-tap-highlight-color: transparent;
25810
25922
  }
25811
25923
 
25924
+ :host([appearance="neutral-base"]) {
25925
+ --_content-color: var(--semantics-buttons-neutral-base-content-color);
25926
+ --_is-hovered-background-color: var(--semantics-buttons-neutral-base-is-hovered-background-color);
25927
+ --_is-hovered-content-color: var(--semantics-buttons-neutral-base-is-hovered-content-color);
25928
+ --_is-active-background-color: var(--semantics-buttons-neutral-base-is-active-background-color);
25929
+ --_is-active-content-color: var(--semantics-buttons-neutral-base-is-active-content-color);
25930
+ --_is-selected-background-color: var(--semantics-buttons-neutral-base-is-selected-background-color);
25931
+ --_is-selected-content-color: var(--semantics-buttons-neutral-base-is-selected-content-color);
25932
+ --_is-selected-highlight-border-color: var(--semantics-buttons-neutral-base-is-selected-highlight-border-color);
25933
+ --_is-selected-is-hovered-background-color: var(--semantics-buttons-neutral-base-is-selected-is-hovered-background-color);
25934
+ --_is-selected-is-hovered-content-color: var(--semantics-buttons-neutral-base-is-selected-is-hovered-content-color);
25935
+ --_is-selected-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-base-is-selected-is-hovered-highlight-border-color);
25936
+ --_is-selected-is-active-background-color: var(--semantics-buttons-neutral-base-is-selected-is-active-background-color);
25937
+ --_is-selected-is-active-content-color: var(--semantics-buttons-neutral-base-is-selected-is-active-content-color);
25938
+ --_is-selected-is-active-highlight-border-color: var(--semantics-buttons-neutral-base-is-selected-is-active-highlight-border-color);
25939
+ }
25940
+
25812
25941
  :host([hidden]) {
25813
25942
  display: none;
25814
25943
  }
@@ -25878,7 +26007,7 @@ var segmentedControlItemStyles = css`
25878
26007
  gap: var(--_gap);
25879
26008
  align-items: center;
25880
26009
  justify-content: center;
25881
- color: var(--semantics-buttons-neutral-tinted-content-color);
26010
+ color: var(--_content-color);
25882
26011
  font: var(--_font);
25883
26012
  }
25884
26013
 
@@ -25888,37 +26017,37 @@ var segmentedControlItemStyles = css`
25888
26017
 
25889
26018
  @media (hover: hover) {
25890
26019
  :host(:not([selected])) .segmented-control__item:hover {
25891
- background-color: var(--semantics-buttons-neutral-tinted-is-hovered-background-color);
25892
- color: var(--semantics-buttons-neutral-tinted-is-hovered-content-color);
26020
+ background-color: var(--_is-hovered-background-color);
26021
+ color: var(--_is-hovered-content-color);
25893
26022
  }
25894
26023
  }
25895
26024
 
25896
26025
  :host(:not([selected])) .segmented-control__item:active {
25897
- background-color: var(--semantics-buttons-neutral-tinted-is-active-background-color);
25898
- color: var(--semantics-buttons-neutral-tinted-is-active-content-color);
26026
+ background-color: var(--_is-active-background-color);
26027
+ color: var(--_is-active-content-color);
25899
26028
  }
25900
26029
 
25901
26030
  :host([selected]) .segmented-control__item {
25902
- --_highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-highlight-border-color);
26031
+ --_highlight-border-color: var(--_is-selected-highlight-border-color);
25903
26032
 
25904
- background-color: var(--semantics-buttons-neutral-tinted-is-selected-background-color);
25905
- color: var(--semantics-buttons-neutral-tinted-is-selected-content-color);
26033
+ background-color: var(--_is-selected-background-color);
26034
+ color: var(--_is-selected-content-color);
25906
26035
  }
25907
26036
 
25908
26037
  @media (hover: hover) {
25909
26038
  :host([selected]) .segmented-control__item:hover {
25910
- --_highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-highlight-border-color);
26039
+ --_highlight-border-color: var(--_is-selected-is-hovered-highlight-border-color);
25911
26040
 
25912
- background-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-background-color);
25913
- color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-content-color);
26041
+ background-color: var(--_is-selected-is-hovered-background-color);
26042
+ color: var(--_is-selected-is-hovered-content-color);
25914
26043
  }
25915
26044
  }
25916
26045
 
25917
26046
  :host([selected]) .segmented-control__item:active {
25918
- --_highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-highlight-border-color);
26047
+ --_highlight-border-color: var(--_is-selected-is-active-highlight-border-color);
25919
26048
 
25920
- background-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-background-color);
25921
- color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-content-color);
26049
+ background-color: var(--_is-selected-is-active-background-color);
26050
+ color: var(--_is-selected-is-active-content-color);
25922
26051
  }
25923
26052
 
25924
26053
  @media (forced-colors: active) {
@@ -26053,6 +26182,7 @@ function segmentedControlItemTemplate(component) {
26053
26182
  * @element nldd-segmented-control
26054
26183
  * @attr {string} value - Selected value for radio type
26055
26184
  * @prop {string[]} values - Selected values for checkbox type (property binding only, not an attribute)
26185
+ * @attr {string} appearance - Visual style, color included: 'neutral-tinted' | 'neutral-base' (default: 'neutral-tinted'). neutral-base is for a tinted surface. For a quiet row without a track, use nldd-toggle-button-group with type="radio" and a transparent appearance.
26056
26186
  * @attr {string} size - Control size: 'sm' | 'md' | 'lg' (default: 'md')
26057
26187
  * @attr {string} type - Selection mode: 'radio' | 'checkbox' (default: 'radio').
26058
26188
  * @attr {string} variant - Content type for all items: 'text' | 'icon' | 'icon-and-text' (default: 'text')
@@ -26076,6 +26206,7 @@ function segmentedControlItemTemplate(component) {
26076
26206
  * @attr {boolean} disabled - Disabled state
26077
26207
  * @attr {string} text - Text label (shown for variant "text" and "icon-and-text"; used as aria-label and tooltip for variant "icon")
26078
26208
  * @attr {string} icon - Icon name for nldd-icon
26209
+ * @attr {string} appearance - Visual style: 'neutral-tinted' | 'neutral-base' (default: 'neutral-tinted'). Set by nldd-segmented-control.
26079
26210
  * @attr {string} size - Control size: 'sm' | 'md' | 'lg' (default: 'md'). Set by nldd-segmented-control.
26080
26211
  * @attr {string} variant - Content type: 'text' | 'icon' | 'icon-and-text' (default: 'text'). Set by nldd-segmented-control.
26081
26212
  * @attr {string} input-type - Selection mode: 'radio' | 'checkbox' (default: 'radio'). In radio mode the item is the radio itself, in checkbox mode it renders a native checkbox. Set by nldd-segmented-control.
@@ -26096,6 +26227,7 @@ var NLDDSegmentedControlItem = (_NLDDSegmentedControlItem = class NLDDSegmentedC
26096
26227
  this.value = "";
26097
26228
  this.selected = false;
26098
26229
  this.disabled = false;
26230
+ this.appearance = "neutral-tinted";
26099
26231
  this.size = "md";
26100
26232
  this.variant = "text";
26101
26233
  this.inputType = "radio";
@@ -26239,6 +26371,10 @@ __decorate([property({
26239
26371
  type: Boolean,
26240
26372
  reflect: true
26241
26373
  })], NLDDSegmentedControlItem.prototype, "disabled", void 0);
26374
+ __decorate([property({
26375
+ reflect: true,
26376
+ converter: reflectNonDefault("neutral-tinted")
26377
+ })], NLDDSegmentedControlItem.prototype, "appearance", void 0);
26242
26378
  __decorate([property({
26243
26379
  reflect: true,
26244
26380
  converter: reflectNonDefault("md")
@@ -26274,6 +26410,7 @@ var NLDDSegmentedControl = (_NLDDSegmentedControl2 = class NLDDSegmentedControl
26274
26410
  this._initialValues = [];
26275
26411
  this.value = "";
26276
26412
  this.values = [];
26413
+ this.appearance = "neutral-tinted";
26277
26414
  this.size = "md";
26278
26415
  this.type = "radio";
26279
26416
  this.variant = "text";
@@ -26400,7 +26537,7 @@ var NLDDSegmentedControl = (_NLDDSegmentedControl2 = class NLDDSegmentedControl
26400
26537
  if (w && !(w === "full" || w === "fit-content") && CSS.supports("width", w)) this.style.setProperty("--_width", w);
26401
26538
  else this.style.removeProperty("--_width");
26402
26539
  }
26403
- if (changedProperties.has("value") || changedProperties.has("values") || changedProperties.has("size") || changedProperties.has("disabled") || changedProperties.has("type") || changedProperties.has("variant") || changedProperties.has("name")) this._syncItems();
26540
+ if (changedProperties.has("value") || changedProperties.has("values") || changedProperties.has("appearance") || changedProperties.has("size") || changedProperties.has("disabled") || changedProperties.has("type") || changedProperties.has("variant") || changedProperties.has("name")) this._syncItems();
26404
26541
  if (changedProperties.has("value") || changedProperties.has("values") || changedProperties.has("type") || changedProperties.has("name")) this.commitFormValue();
26405
26542
  if (changedProperties.has("type")) this.setAttribute("role", this.type === "checkbox" ? "group" : "radiogroup");
26406
26543
  if (changedProperties.has("accessibleLabel")) this._appliedLabel = setOwnedAttribute(this, "aria-label", this.accessibleLabel, this._appliedLabel);
@@ -26436,6 +26573,7 @@ var NLDDSegmentedControl = (_NLDDSegmentedControl2 = class NLDDSegmentedControl
26436
26573
  }
26437
26574
  });
26438
26575
  items.forEach((item) => {
26576
+ item.appearance = this.appearance;
26439
26577
  item.size = this.size;
26440
26578
  item.inputType = this.type;
26441
26579
  item.variant = this.variant;
@@ -26483,6 +26621,10 @@ __decorate([property({
26483
26621
  type: Array,
26484
26622
  attribute: false
26485
26623
  })], NLDDSegmentedControl.prototype, "values", void 0);
26624
+ __decorate([property({
26625
+ reflect: true,
26626
+ converter: reflectNonDefault("neutral-tinted")
26627
+ })], NLDDSegmentedControl.prototype, "appearance", void 0);
26486
26628
  __decorate([property({
26487
26629
  reflect: true,
26488
26630
  converter: reflectNonDefault("md")
@@ -26621,7 +26763,7 @@ function stepperTemplate(component) {
26621
26763
  @keydown=${component._handleKeydown}
26622
26764
  >
26623
26765
  <nldd-icon-button
26624
- variant="neutral-tinted"
26766
+ appearance="neutral-tinted"
26625
26767
  size=${component.size}
26626
26768
  icon="minus"
26627
26769
  text=${component._t("components.stepper.decrement-action")}
@@ -26636,7 +26778,7 @@ function stepperTemplate(component) {
26636
26778
  aria-hidden="true"
26637
26779
  ></div>
26638
26780
  <nldd-icon-button
26639
- variant="neutral-tinted"
26781
+ appearance="neutral-tinted"
26640
26782
  size=${component.size}
26641
26783
  icon="plus"
26642
26784
  text=${component._t("components.stepper.increment-action")}
@@ -26709,7 +26851,7 @@ var NLDDStepper = (_NLDDStepper = class NLDDStepper extends DescribedBy(FormAsso
26709
26851
  if (!isNaN(parsed)) this.value = Math.max(this.min, Math.min(this.max, parsed));
26710
26852
  }
26711
26853
  _t(key) {
26712
- return this.translations[key] ?? nlddStepperTranslations[key];
26854
+ return translate(this.translations, nlddStepperTranslations, key);
26713
26855
  }
26714
26856
  _decrement() {
26715
26857
  if (this.disabled) return;
@@ -27271,6 +27413,11 @@ __decorate([property({
27271
27413
  })], NLDDSwitchField.prototype, "invalid", void 0);
27272
27414
  NLDDSwitchField = __decorate([customElement("nldd-switch-field")], NLDDSwitchField);
27273
27415
  //#endregion
27416
+ //#region src/components/inputs/text-editor/text-editor.labels.ts
27417
+ /** Says the editor's labels changed, such as after a language switch: the
27418
+ * widgets that draw a translated label rebuild with the new text. */
27419
+ var relabel = StateEffect.define();
27420
+ //#endregion
27274
27421
  //#region node_modules/@lezer/markdown/dist/index.js
27275
27422
  var CompositeBlock = class CompositeBlock {
27276
27423
  static create(type, value, from, parentHash, end) {
@@ -29708,22 +29855,42 @@ function enclosingNamed(state, pos, side, names) {
29708
29855
  }
29709
29856
  //#endregion
29710
29857
  //#region src/components/inputs/text-editor/text-editor.mentions.ts
29858
+ /** What may follow a trigger when a list says nothing else: letters in any
29859
+ * script and with any accent, digits, `_`, `.`, `+` and `-`. A name like
29860
+ * `józef` reaches the source whole, and so does the `+1` of `:+1:`. A space
29861
+ * ends the query, as it ends a mention in most systems. */
29862
+ var DEFAULT_TYPEAHEAD_QUERY = "[\\p{L}\\p{M}\\p{N}_.+-]*";
29711
29863
  /** The query being typed: a trigger at the start of the line or after
29712
- * whitespace, followed by name characters, up to the caret. Anchored that way
29713
- * so a trigger inside a word (an e-mail address, `piet@sam`) stays a plain
29714
- * character. The name class is ASCII for now; widening it changes what a
29715
- * source receives and is its own change. */
29864
+ * whitespace, followed by what the list allows, up to the caret. Anchored that
29865
+ * way so a trigger inside a word (an e-mail address, `piet@sam`) stays a plain
29866
+ * character. */
29716
29867
  var queryPatterns = /* @__PURE__ */ new Map();
29717
- function queryPattern(triggers) {
29718
- const chars = Array.from(new Set(triggers.filter((t) => t.length === 1 && !/[\s\w]/.test(t)))).sort().join("");
29719
- if (!chars) return null;
29720
- let pattern = queryPatterns.get(chars);
29721
- if (!pattern) {
29722
- pattern = new RegExp(`(^|\\s)([${chars.replace(/[\\\]^-]/g, "\\$&")}])([\\w.-]*)$`);
29723
- queryPatterns.set(chars, pattern);
29868
+ function queryPattern(trigger, query) {
29869
+ if (trigger.length !== 1 || /[\s\p{L}\p{N}_]/u.test(trigger)) return null;
29870
+ const key = `${trigger}\u0000${query}`;
29871
+ if (queryPatterns.has(key)) return queryPatterns.get(key);
29872
+ let pattern;
29873
+ try {
29874
+ pattern = new RegExp(`(^|\\s)(${trigger.replace(/[\\^$.*+?()[\]{}|/]/g, "\\$&")})(${query})$`, "u");
29875
+ } catch {
29876
+ pattern = query === "[\\p{L}\\p{M}\\p{N}_.+-]*" ? null : queryPattern(trigger, DEFAULT_TYPEAHEAD_QUERY);
29724
29877
  }
29878
+ queryPatterns.set(key, pattern);
29725
29879
  return pattern;
29726
29880
  }
29881
+ /** One pattern per trigger. Lists on one trigger share it: the first list that
29882
+ * sets a `query` decides, since they all answer the same typed text. */
29883
+ function patternsFor(triggers) {
29884
+ const queries = /* @__PURE__ */ new Map();
29885
+ for (const entry of triggers) {
29886
+ const { trigger, query } = typeof entry === "string" ? {
29887
+ trigger: entry,
29888
+ query: void 0
29889
+ } : entry;
29890
+ if (!queries.has(trigger) || queries.get(trigger) === void 0 && query !== void 0) queries.set(trigger, query);
29891
+ }
29892
+ return Array.from(queries, ([trigger, query]) => queryPattern(trigger, query ?? "[\\p{L}\\p{M}\\p{N}_.+-]*")).filter((pattern) => pattern !== null);
29893
+ }
29727
29894
  /** Code is quoted verbatim, so a trigger in a fenced block, an indented block
29728
29895
  * or a backtick span is not a typeahead and must not open the list. */
29729
29896
  var CODE_NODES = /* @__PURE__ */ new Set([
@@ -29739,18 +29906,21 @@ function inCode(state, pos) {
29739
29906
  * without it. Both the completion source and the reopen-on-delete path go
29740
29907
  * through this, so they cannot disagree about what counts as a query. */
29741
29908
  function typeaheadQueryAt(state, pos, triggers) {
29742
- const pattern = queryPattern(triggers);
29743
- if (!pattern) return null;
29744
29909
  const line = state.doc.lineAt(pos);
29745
- const match = pattern.exec(state.sliceDoc(line.from, pos));
29746
- if (!match) return null;
29747
- const from = line.from + match.index + match[1].length;
29910
+ const text = state.sliceDoc(line.from, pos);
29911
+ let best = null;
29912
+ for (const pattern of patternsFor(triggers)) {
29913
+ const match = pattern.exec(text);
29914
+ if (match && (!best || match.index + match[1].length > best.index + best[1].length)) best = match;
29915
+ }
29916
+ if (!best) return null;
29917
+ const from = line.from + best.index + best[1].length;
29748
29918
  if (inCode(state, from)) return null;
29749
29919
  return {
29750
29920
  from,
29751
29921
  to: pos,
29752
- query: match[3],
29753
- trigger: match[2]
29922
+ query: best[3],
29923
+ trigger: best[2]
29754
29924
  };
29755
29925
  }
29756
29926
  /** Href prefix that marks a markdown link as a mention. */
@@ -29820,10 +29990,11 @@ function renderLead(completion) {
29820
29990
  function rowClass(completion) {
29821
29991
  return completion.candidate.avatar ? "cm-nldd-row-avatar" : "";
29822
29992
  }
29823
- function completionSource(getTypeaheads, onChoose) {
29993
+ var setEmptyMessage = StateEffect.define();
29994
+ function completionSource(getTypeaheads, onChoose, defaultEmptyText) {
29824
29995
  return async (context) => {
29825
29996
  const lists = getTypeaheads();
29826
- const match = typeaheadQueryAt(context.state, context.pos, lists.map((t) => t.trigger));
29997
+ const match = typeaheadQueryAt(context.state, context.pos, lists);
29827
29998
  if (!match) return null;
29828
29999
  const onTrigger = lists.filter((t) => t.trigger === match.trigger);
29829
30000
  const results = await Promise.all(onTrigger.map((t) => t.source(match.query)));
@@ -29856,6 +30027,16 @@ function completionSource(getTypeaheads, onChoose) {
29856
30027
  }
29857
30028
  });
29858
30029
  });
30030
+ const message = options.length ? null : emptyMessageFor(onTrigger, match.query, defaultEmptyText);
30031
+ const view = context.view;
30032
+ if (view && !context.aborted && view.state.doc === context.state.doc) {
30033
+ const current = view.state.field(emptyMessageField, false);
30034
+ const next = message === null ? null : {
30035
+ from: match.from,
30036
+ text: message
30037
+ };
30038
+ if (current?.text !== next?.text || current?.from !== next?.from) view.dispatch({ effects: setEmptyMessage.of(next) });
30039
+ }
29859
30040
  if (!options.length) return null;
29860
30041
  return {
29861
30042
  from: match.from,
@@ -29864,6 +30045,62 @@ function completionSource(getTypeaheads, onChoose) {
29864
30045
  };
29865
30046
  };
29866
30047
  }
30048
+ function emptyMessageFor(lists, query, defaultEmptyText) {
30049
+ for (const list of lists) {
30050
+ const text = list.emptyText?.(query);
30051
+ if (text !== void 0) return text || null;
30052
+ }
30053
+ return defaultEmptyText(query);
30054
+ }
30055
+ /**
30056
+ * The message in place of an empty list. It sits where the list would, in the
30057
+ * same top-layer frame and with the same surface, but it is not an option:
30058
+ * nothing to select or apply, so it is a status that a screen reader announces
30059
+ * rather than a row in the listbox. It goes when there are candidates again,
30060
+ * when the caret leaves the query, on Escape and when the editor loses focus.
30061
+ */
30062
+ var emptyMessageField = StateField.define({
30063
+ create: () => null,
30064
+ update(value, tr) {
30065
+ for (const effect of tr.effects) if (effect.is(setEmptyMessage)) return effect.value;
30066
+ if (!value) return null;
30067
+ if (tr.docChanged) value = {
30068
+ ...value,
30069
+ from: tr.changes.mapPos(value.from)
30070
+ };
30071
+ if (tr.docChanged || tr.selection) {
30072
+ const head = tr.state.selection.main.head;
30073
+ const line = tr.state.doc.lineAt(head);
30074
+ if (value.from < line.from || value.from >= head) return null;
30075
+ }
30076
+ return value;
30077
+ },
30078
+ provide: (field) => showTooltip.from(field, (value) => value && {
30079
+ pos: value.from,
30080
+ above: false,
30081
+ create: () => {
30082
+ const dom = document.createElement("div");
30083
+ dom.className = "cm-nldd-typeahead-empty";
30084
+ dom.setAttribute("role", "status");
30085
+ dom.textContent = value.text;
30086
+ return { dom };
30087
+ }
30088
+ })
30089
+ });
30090
+ var emptyMessageClose = [
30091
+ Prec.high(keymap.of([{
30092
+ key: "Escape",
30093
+ run: (view) => {
30094
+ if (!view.state.field(emptyMessageField, false)) return false;
30095
+ view.dispatch({ effects: setEmptyMessage.of(null) });
30096
+ return true;
30097
+ }
30098
+ }])),
30099
+ EditorView.focusChangeEffect.of((state, focusing) => !focusing && state.field(emptyMessageField, false) ? setEmptyMessage.of(null) : null),
30100
+ EditorView.updateListener.of((update) => {
30101
+ if (completionStatus(update.state) === "active" && update.state.field(emptyMessageField, false)) queueMicrotask(() => update.view.dispatch({ effects: setEmptyMessage.of(null) }));
30102
+ })
30103
+ ];
29867
30104
  /**
29868
30105
  * A frame for the list in the top layer, the way an nldd-menu opens.
29869
30106
  *
@@ -29997,6 +30234,19 @@ var popupTheme = EditorView.theme({
29997
30234
  fontStyle: "normal"
29998
30235
  },
29999
30236
  ".cm-tooltip.cm-tooltip-autocomplete > ul > li[aria-selected] .cm-completionDetail": { color: "inherit" },
30237
+ ".cm-tooltip.cm-nldd-typeahead-empty": {
30238
+ border: "none",
30239
+ borderRadius: "var(--semantics-overlays-corner-radius)",
30240
+ backgroundColor: "var(--semantics-surfaces-base-background-color)",
30241
+ boxShadow: "var(--components-menu-box-shadow)",
30242
+ minWidth: "var(--primitives-area-280)",
30243
+ maxWidth: "var(--primitives-area-400)",
30244
+ boxSizing: "border-box",
30245
+ padding: "var(--primitives-space-12) var(--primitives-space-16)",
30246
+ color: "var(--semantics-content-secondary-color)",
30247
+ fontFamily: "var(--primitives-font-family-body)",
30248
+ fontSize: "var(--primitives-font-size-100)"
30249
+ },
30000
30250
  "@media (pointer: coarse)": { ".cm-tooltip.cm-tooltip-autocomplete > ul > li": { minHeight: "var(--semantics-controls-md-min-size)" } }
30001
30251
  });
30002
30252
  /**
@@ -30004,17 +30254,16 @@ var popupTheme = EditorView.theme({
30004
30254
  * hand over its current lists; choosing a candidate writes what the list's
30005
30255
  * `insert` says and calls `onChoose`. Without lists it is inert.
30006
30256
  */
30007
- function typeaheads(getTypeaheads, onChoose) {
30257
+ function typeaheads(getTypeaheads, onChoose, defaultEmptyText = () => null) {
30008
30258
  const reopenOnDelete = EditorView.updateListener.of((update) => {
30009
30259
  if (!update.docChanged || completionStatus(update.state) !== null) return;
30010
30260
  if (!update.transactions.some((tr) => tr.isUserEvent("delete"))) return;
30011
- const triggers = getTypeaheads().map((t) => t.trigger);
30012
- if (typeaheadQueryAt(update.state, update.state.selection.main.head, triggers)) startCompletion(update.view);
30261
+ if (typeaheadQueryAt(update.state, update.state.selection.main.head, getTypeaheads())) startCompletion(update.view);
30013
30262
  });
30014
30263
  return [
30015
30264
  topLayerPopups(),
30016
30265
  autocompletion({
30017
- override: [completionSource(getTypeaheads, onChoose)],
30266
+ override: [completionSource(getTypeaheads, onChoose, defaultEmptyText)],
30018
30267
  icons: false,
30019
30268
  addToOptions: [{
30020
30269
  position: 20,
@@ -30023,6 +30272,8 @@ function typeaheads(getTypeaheads, onChoose) {
30023
30272
  optionClass: rowClass
30024
30273
  }),
30025
30274
  reopenOnDelete,
30275
+ emptyMessageField,
30276
+ emptyMessageClose,
30026
30277
  popupTheme
30027
30278
  ];
30028
30279
  }
@@ -30057,10 +30308,10 @@ var LinkOpenWidget = class extends WidgetType {
30057
30308
  constructor(href, label) {
30058
30309
  super();
30059
30310
  this.href = href;
30060
- this.label = label;
30311
+ this.ariaLabel = label(href);
30061
30312
  }
30062
30313
  eq(other) {
30063
- return other.href === this.href;
30314
+ return other.href === this.href && other.ariaLabel === this.ariaLabel;
30064
30315
  }
30065
30316
  toDOM() {
30066
30317
  const anchor = document.createElement("a");
@@ -30068,7 +30319,7 @@ var LinkOpenWidget = class extends WidgetType {
30068
30319
  anchor.href = this.href;
30069
30320
  anchor.target = "_blank";
30070
30321
  anchor.rel = "noopener noreferrer";
30071
- anchor.setAttribute("aria-label", this.label(this.href));
30322
+ anchor.setAttribute("aria-label", this.ariaLabel);
30072
30323
  const icon = document.createElement("nldd-icon");
30073
30324
  icon.setAttribute("icon", "external-link");
30074
30325
  icon.setAttribute("aria-hidden", "true");
@@ -30210,7 +30461,7 @@ function linkOpenBadge(label) {
30210
30461
  this.decorations = buildBadges(view, label);
30211
30462
  }
30212
30463
  update(update) {
30213
- if (update.docChanged || update.viewportChanged) this.decorations = buildBadges(update.view, label);
30464
+ if (update.docChanged || update.viewportChanged || update.transactions.some((tr) => tr.effects.some((e) => e.is(relabel)))) this.decorations = buildBadges(update.view, label);
30214
30465
  }
30215
30466
  }, { decorations: (plugin) => plugin.decorations });
30216
30467
  }
@@ -30645,13 +30896,15 @@ var MentionWidget = class extends WidgetType {
30645
30896
  const token = document.createElement("span");
30646
30897
  token.className = "cm-md-mention-token";
30647
30898
  token.setAttribute("data-user", this.id);
30899
+ token.setAttribute("spellcheck", "false");
30648
30900
  if (this.selected) token.setAttribute("data-selected", "");
30649
30901
  const at = document.createElement("nldd-icon");
30650
30902
  at.className = "cm-md-mention-token-icon";
30651
30903
  at.setAttribute("icon", "at");
30652
30904
  at.setAttribute("aria-hidden", "true");
30653
30905
  const name = document.createElement("span");
30654
- name.textContent = this.label;
30906
+ name.className = "cm-md-mention-token-name";
30907
+ name.dataset.label = this.label;
30655
30908
  token.append(at, name);
30656
30909
  return token;
30657
30910
  }
@@ -30746,6 +30999,120 @@ function mentionRangeStartingAt(state, pos) {
30746
30999
  to: link.to
30747
31000
  } : null;
30748
31001
  }
31002
+ //#endregion
31003
+ //#region src/components/inputs/text-editor/text-editor.spellcheck.ts
31004
+ /** Says whether a syntax node is left out of spellchecking, and with it all it
31005
+ * contains. A plugin that renders something of its own adds a test here, so
31006
+ * its syntax does not get a red underline in every consumer's editor. */
31007
+ var spellcheckExclusions = Facet.define();
31008
+ /** Code is quoted as it is, an address is not a word, and a mention is a name
31009
+ * someone chose; none of it is the writer's spelling to correct. The text of
31010
+ * a link is, so a link is checked except for its URL. */
31011
+ var NOT_PROSE = /* @__PURE__ */ new Set([
31012
+ "InlineCode",
31013
+ "FencedCode",
31014
+ "CodeBlock",
31015
+ "URL",
31016
+ "Autolink"
31017
+ ]);
31018
+ function isMention(node, state) {
31019
+ if (node.name !== "Link") return false;
31020
+ const url = node.node.getChild("URL");
31021
+ return url !== null && state.sliceDoc(url.from, url.to).startsWith("user:");
31022
+ }
31023
+ var builtIn = spellcheckExclusions.of((node, state) => NOT_PROSE.has(node.name) || isMention(node, state));
31024
+ var noSpellcheck = Decoration.mark({ attributes: { spellcheck: "false" } });
31025
+ function exclusions(view) {
31026
+ const tests = view.state.facet(spellcheckExclusions);
31027
+ const builder = new RangeSetBuilder();
31028
+ const tree = syntaxTree(view.state);
31029
+ let markedTo = -1;
31030
+ for (const { from, to } of view.visibleRanges) tree.iterate({
31031
+ from,
31032
+ to,
31033
+ enter: (node) => {
31034
+ if (!tests.some((test) => test(node, view.state))) return;
31035
+ if (node.to > node.from && node.from >= markedTo) {
31036
+ builder.add(node.from, node.to, noSpellcheck);
31037
+ markedTo = node.to;
31038
+ }
31039
+ return false;
31040
+ }
31041
+ });
31042
+ return builder.finish();
31043
+ }
31044
+ var exclusionMarks = ViewPlugin.fromClass(class {
31045
+ constructor(view) {
31046
+ this.decorations = exclusions(view);
31047
+ }
31048
+ update(update) {
31049
+ if (update.docChanged || update.viewportChanged || syntaxTree(update.state) !== syntaxTree(update.startState)) this.decorations = exclusions(update.view);
31050
+ }
31051
+ }, { decorations: (plugin) => plugin.decorations });
31052
+ /**
31053
+ * Deleting left to the browser wherever the editor has nothing to add.
31054
+ *
31055
+ * Every Backspace or Delete CodeMirror handles itself costs the spelling marks
31056
+ * on the line: it writes the line anew and the browser drops them until the
31057
+ * next word is typed, in every browser. Typing does not have this, because
31058
+ * CodeMirror lets the browser insert a letter and reads it back, and a deletion
31059
+ * the browser does keeps them too. It has to be every plain deletion: a single
31060
+ * space or a selection removed by CodeMirror is enough to lose them.
31061
+ *
31062
+ * CodeMirror keeps the key where it does more than delete text inside one text
31063
+ * node: a made-up event (which has no default action) or a modifier, more than
31064
+ * one cursor, a deletion that reaches past the text node the caret is in (a
31065
+ * line join, a widget or a mark boundary next to it, or a selection across
31066
+ * them), and the indentation at the start of a line, where it removes a whole
31067
+ * indent step. List and heading markup have their own bindings, which run first
31068
+ * and only take the key when they have something to do.
31069
+ *
31070
+ * A binding that claims the key makes CodeMirror prevent the default, so the
31071
+ * editor's Backspace and Delete bindings ask this and return false when it says
31072
+ * yes: with no binding taking the key, the browser deletes and CodeMirror reads
31073
+ * the change from the DOM.
31074
+ */
31075
+ var nativeDeletion = Facet.define({ combine: (values) => values.some(Boolean) });
31076
+ /** The plain, real Backspace or Delete being handled, if it is one. An observer
31077
+ * runs before the bindings and sees the event, which a binding does not. */
31078
+ var plainDeletion = /* @__PURE__ */ new WeakMap();
31079
+ var watchDeletion = EditorView.domEventObservers({ keydown(event, view) {
31080
+ const plain = event.isTrusted && !event.isComposing && !event.shiftKey && !event.altKey && !event.ctrlKey && !event.metaKey;
31081
+ plainDeletion.set(view, plain && (event.key === "Backspace" || event.key === "Delete") ? event.key : null);
31082
+ } });
31083
+ /** The text node and offset at `pos`, or null when the DOM there is not text. */
31084
+ function textAt(view, pos) {
31085
+ const { node, offset } = view.domAtPos(pos);
31086
+ return node.nodeType === Node.TEXT_NODE ? {
31087
+ node,
31088
+ offset
31089
+ } : null;
31090
+ }
31091
+ function leaveDeletionToBrowser(view, key) {
31092
+ if (!view.state.facet(nativeDeletion) || plainDeletion.get(view) !== key) return false;
31093
+ const { selection, doc } = view.state;
31094
+ if (selection.ranges.length > 1) return false;
31095
+ const { from, to, empty } = selection.main;
31096
+ const line = doc.lineAt(from);
31097
+ if (!/\S/.test(view.state.sliceDoc(line.from, from)) && !(key === "Delete" && empty)) return false;
31098
+ const start = textAt(view, from);
31099
+ if (!start) return false;
31100
+ if (!empty) {
31101
+ const end = textAt(view, to);
31102
+ return end !== null && end.node === start.node && start.offset >= 1;
31103
+ }
31104
+ return key === "Backspace" ? start.offset >= 2 : start.offset >= 1 && start.offset <= start.node.length - 2;
31105
+ }
31106
+ /** Spellchecking on the content, without the parts that are not running text. */
31107
+ function spellcheck() {
31108
+ return [
31109
+ EditorView.contentAttributes.of({ spellcheck: "true" }),
31110
+ builtIn,
31111
+ Prec.highest(exclusionMarks),
31112
+ nativeDeletion.of(true),
31113
+ watchDeletion
31114
+ ];
31115
+ }
30749
31116
  /** Remove every sentinel from a string (doc text -> clean value). */
30750
31117
  function stripSentinels(text) {
30751
31118
  return text.split("⁠").join("");
@@ -30910,10 +31277,10 @@ var AnnotationBadge = class extends WidgetType {
30910
31277
  super();
30911
31278
  this.ids = ids;
30912
31279
  this.quote = quote;
30913
- this.label = label;
31280
+ this.ariaLabel = label(ids.length, truncateQuote(quote));
30914
31281
  }
30915
31282
  eq(other) {
30916
- return other.quote === this.quote && other.ids.length === this.ids.length && other.ids.every((id, i) => id === this.ids[i]);
31283
+ return other.quote === this.quote && other.ids.length === this.ids.length && other.ids.every((id, i) => id === this.ids[i]) && other.ariaLabel === this.ariaLabel;
30917
31284
  }
30918
31285
  toDOM() {
30919
31286
  const badge = document.createElement("button");
@@ -30921,7 +31288,7 @@ var AnnotationBadge = class extends WidgetType {
30921
31288
  badge.type = "button";
30922
31289
  badge.dataset.annotations = this.ids.join(" ");
30923
31290
  badge.textContent = String(this.ids.length);
30924
- badge.setAttribute("aria-label", this.label(this.ids.length, truncateQuote(this.quote)));
31291
+ badge.setAttribute("aria-label", this.ariaLabel);
30925
31292
  return badge;
30926
31293
  }
30927
31294
  /** Give the caret at either edge of the badge a stable, text-height rectangle.
@@ -31060,7 +31427,7 @@ function makeAnnotationRender(label) {
31060
31427
  create: (state) => buildAll(state, label),
31061
31428
  update: (value, tr) => {
31062
31429
  if (value === NOTHING && !tr.state.field(annotationField).length) return value;
31063
- if (tr.docChanged || !tr.startState.selection.eq(tr.state.selection) || tr.effects.some((e) => e.is(setAnnotations))) return buildAll(tr.state, label);
31430
+ if (tr.docChanged || !tr.startState.selection.eq(tr.state.selection) || tr.effects.some((e) => e.is(setAnnotations) || e.is(relabel))) return buildAll(tr.state, label);
31064
31431
  return value;
31065
31432
  },
31066
31433
  provide: (f) => EditorView.decorations.from(f, (v) => v.deco)
@@ -32181,9 +32548,9 @@ var textEditorStyles = css`
32181
32548
  }
32182
32549
 
32183
32550
 
32184
- /* ## Variant — input-field adds the framed surface + a default content padding */
32551
+ /* ## Appearance — input-field adds the framed surface + a default content padding */
32185
32552
 
32186
- :host([variant="input-field"]) {
32553
+ :host([appearance="input-field"]) {
32187
32554
  --_corner-radius: var(--primitives-corner-radius-lg);
32188
32555
  --_background-color: var(--semantics-input-fields-background-color);
32189
32556
  --_highlight-border-color: var(--semantics-input-fields-border-color);
@@ -32218,7 +32585,7 @@ var textEditorStyles = css`
32218
32585
 
32219
32586
  /* Focus ring only on the input-field variant; simple relies on the accent caret and
32220
32587
  lets a wrapping composition own its focus treatment. */
32221
- :host([variant="input-field"]) .text-editor:focus-within {
32588
+ :host([appearance="input-field"]) .text-editor:focus-within {
32222
32589
  outline: var(--semantics-focus-ring-outline);
32223
32590
  outline-offset: var(--semantics-focus-ring-outline-offset);
32224
32591
  box-shadow: var(--semantics-focus-ring-box-shadow), var(--_highlight-border-shadow);
@@ -32405,6 +32772,12 @@ var textEditorStyles = css`
32405
32772
  vertical-align: -0.16em;
32406
32773
  }
32407
32774
 
32775
+ /* Generated content, not a text node: Safari spellchecks a name in the
32776
+ editor despite spellcheck="false", and it cannot see this. */
32777
+ .cm-md-mention-token-name::after {
32778
+ content: attr(data-label);
32779
+ }
32780
+
32408
32781
  .cm-md-mention-token[data-selected] {
32409
32782
  color: var(--_mention-token-is-selected-content-color);
32410
32783
  background-color: var(--_mention-token-is-selected-background-color);
@@ -32700,7 +33073,9 @@ var nlddTextEditorTranslations = {
32700
33073
  "components.text-editor.open-in-new-tab-label": "Open link in nieuw tabblad: {url}",
32701
33074
  "components.text-editor.annotation-count-label": "{count} {noun} op '{quote}'",
32702
33075
  "components.text-editor.annotation-singular-lowercase": "annotatie",
32703
- "components.text-editor.annotation-plural-lowercase": "annotaties"
33076
+ "components.text-editor.annotation-plural-lowercase": "annotaties",
33077
+ "components.text-editor.typeahead-start-typing-text": "Typ om te zoeken",
33078
+ "components.text-editor.typeahead-no-results-text": "Niets gevonden"
32704
33079
  };
32705
33080
  //#endregion
32706
33081
  //#region src/components/inputs/text-editor/text-editor.ts
@@ -32713,9 +33088,9 @@ var nlddTextEditorTranslations = {
32713
33088
  * stay visible, only dimmed — the iA Writer / Kirby approach. No WYSIWYG tree,
32714
33089
  * so the data stays portable.
32715
33090
  *
32716
- * Default `variant="simple"` is bare (no frame, no focus ring) for use inside
33091
+ * Default `appearance="simple"` is bare (no frame, no focus ring) for use inside
32717
33092
  * a composition (e.g. a message field) that owns its chrome and focus; the
32718
- * caret is a prominent accent. `variant="input-field"` adds a framed surface + focus
33093
+ * caret is a prominent accent. `appearance="input-field"` adds a framed surface + focus
32719
33094
  *
32720
33095
  * Headless: there is no built-in toolbar. A consumer drives formatting via the
32721
33096
  * command methods (toggleBold/toggleItalic/toggleInlineCode/toggleStrikethrough/
@@ -32745,14 +33120,17 @@ var nlddTextEditorTranslations = {
32745
33120
  * @attr {string} name - Field name for form submission
32746
33121
  * @attr {boolean} readonly - Readonly state (focusable and selectable, not editable)
32747
33122
  * @attr {boolean} required - Required state
33123
+ * @attr {boolean} no-spellcheck - Turns spellchecking off. It is on by default, like the other text fields, and leaves out what is not running text: inline code and code blocks, the address of a link and a bare URL (the link text is checked), and mentions. Autocorrect and autocapitalize follow the user's own settings, as in the other fields, also with `no-spellcheck`. Two limits come from the browser: text that was already there is checked once you edit near it, not when the editor opens (the editor lives in a shadow root; Firefox only checks around the caret), and markup that changes how a line is built, such as starting a list item, hides the underlines on that line until you type on.
32748
33124
  * @attr {boolean} wrap - Wrap long lines (default true; prose wraps)
32749
33125
  * @attr {number} rows - Minimum visible rows (the floor in every resize mode). Default: 6.
32750
33126
  * @attr {string} resize - 'none' (fixed) | 'vertical' (drag) | 'auto' (grow, default)
32751
- * @attr {string} variant - 'simple' (default, bare) | 'input-field' (framed surface)
33127
+ * @attr {string} appearance - 'simple' (default, bare) | 'input-field' (framed surface)
32752
33128
  * @attr {string} accessible-label - Accessible label forwarded to the editor. Set automatically by nldd-form-field.
32753
33129
  *
32754
33130
  * @prop {MentionSource} mentionSource - Consumer-supplied @-mention candidate source (property only). Without it, @-typeahead is inert.
32755
- * @prop {Typeahead[]} typeaheads - Your own typeahead lists next to the @-mention (property only): each a trigger character (`#`, `:`, `/`), a `source` that returns candidates for the text typed after it, and an optional `insert` that decides what a choice writes (by default the trigger, the text and a space). Lists on one trigger are merged in order. A candidate is `{ id, text, supportingText? }` and can carry an `avatar` (its row then takes two lines, the supporting text under the text), an `icon` or a `symbol` for its row.
33131
+ * @prop {string} mentionQuery - What may follow the `@` of a mention, as a regular expression source (property only). Default: letters with any accent, digits, `_`, `.`, `+` and `-`. Allow one space to search on a full name, as in `@sam jansen`.
33132
+ * @prop {Function} mentionEmptyText - What to say when the @-list has no candidates, called with the typed query (property only). Without it the list says "Typ om te zoeken" or "Niets gevonden", both translatable. Return null to close the list without a word.
33133
+ * @prop {Typeahead[]} typeaheads - Your own typeahead lists next to the @-mention (property only): each a trigger character (`#`, `:`, `/`), a `source` that returns candidates for the text typed after it, an optional `query` (a regular expression for what may follow the trigger, such as a space in a full name), an optional `emptyText` (what to say when there are no candidates, instead of the translated default) and an optional `insert` that decides what a choice writes (by default the trigger, the text and a space). Lists on one trigger are merged in order. A candidate is `{ id, text, supportingText? }` and can carry an `avatar` (its row then takes two lines, the supporting text under the text), an `icon` or a `symbol` for its row.
32756
33134
  * @attr {boolean} annotatable - Enable the annotation overlay (off by default). Annotations only render when this is set.
32757
33135
  * @prop {Annotation[]} annotations - Consumer-supplied annotation overlay (property only). Anchored by offset and mapped through edits; the text stays clean. Requires `annotatable`. Assign a NEW array to apply changes (Lit dirty-checks by identity, so in-place mutation like `.push()` won't re-render): `editor.annotations = [...editor.annotations, next]`.
32758
33136
  * @attr {object} translations - Override the editor's assistive-tech strings (the open-in-new-tab link badge and the annotation count badge). Unset keys fall back to Dutch.
@@ -32779,17 +33157,24 @@ var NLDDTextEditor = (_NLDDTextEditor = class NLDDTextEditor extends DescribedBy
32779
33157
  this.name = "";
32780
33158
  this.readonly = false;
32781
33159
  this.required = false;
33160
+ this.noSpellcheck = false;
32782
33161
  this.wrap = true;
32783
33162
  this.rows = 6;
32784
33163
  this.resize = "auto";
32785
- this.variant = "simple";
33164
+ this.appearance = "simple";
32786
33165
  this.accessibleLabel = "";
32787
33166
  this.typeaheads = [];
32788
- this._mentionTypeahead = {
33167
+ this._mentionTypeahead = ((host) => ({
32789
33168
  trigger: "@",
32790
- source: (query) => this.mentionSource?.(query) ?? [],
32791
- insert: mentionInsert
32792
- };
33169
+ source: (query) => host.mentionSource?.(query) ?? [],
33170
+ insert: mentionInsert,
33171
+ get query() {
33172
+ return host.mentionQuery;
33173
+ },
33174
+ get emptyText() {
33175
+ return host.mentionEmptyText;
33176
+ }
33177
+ }))(this);
32793
33178
  this.annotatable = false;
32794
33179
  this.annotations = [];
32795
33180
  this.translations = {};
@@ -32797,8 +33182,10 @@ var NLDDTextEditor = (_NLDDTextEditor = class NLDDTextEditor extends DescribedBy
32797
33182
  this._wrapCompartment = new Compartment();
32798
33183
  this._placeholderCompartment = new Compartment();
32799
33184
  this._attrsCompartment = new Compartment();
33185
+ this._spellcheckCompartment = new Compartment();
32800
33186
  this._historyCompartment = new Compartment();
32801
33187
  this.invalid = false;
33188
+ this._labels = null;
32802
33189
  this._cutBuffer = null;
32803
33190
  this._lastState = null;
32804
33191
  this._onScrollerPointerDown = (event) => {
@@ -32845,15 +33232,22 @@ var NLDDTextEditor = (_NLDDTextEditor = class NLDDTextEditor extends DescribedBy
32845
33232
  * `vars`. Consumer overrides via `translations` win; unset keys fall back to the
32846
33233
  * Dutch defaults. */
32847
33234
  _t(key, vars) {
32848
- let str = this.translations[key] ?? nlddTextEditorTranslations[key];
32849
- if (vars) for (const [k, v] of Object.entries(vars)) str = str.split(`{${k}}`).join(String(v));
32850
- return str;
33235
+ return translate(this.translations, nlddTextEditorTranslations, key, vars);
33236
+ }
33237
+ /** The translated texts the document's widgets draw, as one string. */
33238
+ _labelSignature() {
33239
+ return [
33240
+ "components.text-editor.open-in-new-tab-label",
33241
+ "components.text-editor.annotation-count-label",
33242
+ "components.text-editor.annotation-singular-lowercase",
33243
+ "components.text-editor.annotation-plural-lowercase"
33244
+ ].map((key) => this._t(key)).join("\n");
32851
33245
  }
32852
33246
  buildExtensions() {
32853
33247
  return [
32854
33248
  nlddCodeMirrorTheme,
32855
33249
  markdownEditing,
32856
- typeaheads(() => this._typeaheadLists(), (choice) => this._onTypeaheadChosen(choice)),
33250
+ typeaheads(() => this._typeaheadLists(), (choice) => this._onTypeaheadChosen(choice), (query) => this._t(query ? "components.text-editor.typeahead-no-results-text" : "components.text-editor.typeahead-start-typing-text")),
32857
33251
  Prec.low(orderedListRenumber),
32858
33252
  annotations((count, quote) => this._t("components.text-editor.annotation-count-label", {
32859
33253
  count,
@@ -32921,13 +33315,23 @@ var NLDDTextEditor = (_NLDDTextEditor = class NLDDTextEditor extends DescribedBy
32921
33315
  return true;
32922
33316
  }
32923
33317
  },
32924
- ...defaultKeymap,
33318
+ {
33319
+ key: "Backspace",
33320
+ run: (view) => !leaveDeletionToBrowser(view, "Backspace") && deleteCharBackward(view),
33321
+ shift: deleteCharBackward
33322
+ },
33323
+ {
33324
+ key: "Delete",
33325
+ run: (view) => !leaveDeletionToBrowser(view, "Delete") && deleteCharForward(view)
33326
+ },
33327
+ ...defaultKeymap.filter((binding) => binding.key !== "Backspace" && binding.key !== "Delete"),
32925
33328
  ...historyKeymap
32926
33329
  ]),
32927
33330
  this._placeholderCompartment.of(this._placeholderExtension()),
32928
33331
  this._wrapCompartment.of(this.wrap ? EditorView.lineWrapping : []),
32929
33332
  this._editableCompartment.of(this._editableExtension()),
32930
33333
  this._attrsCompartment.of(this._attrsExtension()),
33334
+ this._spellcheckCompartment.of(this.noSpellcheck ? [] : spellcheck()),
32931
33335
  EditorView.updateListener.of((u) => {
32932
33336
  if (u.docChanged) this._onDocChanged();
32933
33337
  if (u.docChanged || u.selectionSet) this._emitState();
@@ -32985,8 +33389,25 @@ var NLDDTextEditor = (_NLDDTextEditor = class NLDDTextEditor extends DescribedBy
32985
33389
  _placeholderExtension() {
32986
33390
  return this.placeholder ? placeholder(this.placeholder) : [];
32987
33391
  }
33392
+ /**
33393
+ * A browser checks text when it changes, not when `spellcheck` does: turned
33394
+ * off, the red underlines stayed until the text under them was edited, and
33395
+ * turned on, they only came with new words. Drawing the content anew makes
33396
+ * the browser look again. The state stays as it is, history and selection
33397
+ * included, so this is only the picture.
33398
+ */
33399
+ _redrawForSpellcheck() {
33400
+ const view = this.view;
33401
+ if (!view) return;
33402
+ const focused = view.hasFocus;
33403
+ view.setState(view.state);
33404
+ if (focused) view.focus();
33405
+ }
32988
33406
  _attrsExtension() {
32989
- const attrs = {};
33407
+ const attrs = {
33408
+ autocorrect: "on",
33409
+ autocapitalize: "sentences"
33410
+ };
32990
33411
  if (this.accessibleLabel) attrs["aria-label"] = this.accessibleLabel;
32991
33412
  if (this.inputId) attrs["id"] = this.inputId;
32992
33413
  return EditorView.contentAttributes.of(attrs);
@@ -33009,6 +33430,11 @@ var NLDDTextEditor = (_NLDDTextEditor = class NLDDTextEditor extends DescribedBy
33009
33430
  updated(changed) {
33010
33431
  if (changed.has("rows")) this.style.setProperty("--_rows", String(this.rows));
33011
33432
  if (this.view) {
33433
+ const labels = this._labelSignature();
33434
+ if (labels !== this._labels) {
33435
+ if (this._labels !== null) this.view.dispatch({ effects: relabel.of(null) });
33436
+ this._labels = labels;
33437
+ }
33012
33438
  if (changed.has("value")) {
33013
33439
  if (stripSentinels(this.doc) !== this.value) this.setDoc(stripSentinels(this.value));
33014
33440
  this.commitFormValue();
@@ -33017,6 +33443,10 @@ var NLDDTextEditor = (_NLDDTextEditor = class NLDDTextEditor extends DescribedBy
33017
33443
  if (changed.has("wrap")) this.reconfigure(this._wrapCompartment, this.wrap ? EditorView.lineWrapping : []);
33018
33444
  if (changed.has("placeholder")) this.reconfigure(this._placeholderCompartment, this._placeholderExtension());
33019
33445
  if (changed.has("accessibleLabel") || changed.has("inputId")) this.reconfigure(this._attrsCompartment, this._attrsExtension());
33446
+ if (changed.has("noSpellcheck")) {
33447
+ this.reconfigure(this._spellcheckCompartment, this.noSpellcheck ? [] : spellcheck());
33448
+ this._redrawForSpellcheck();
33449
+ }
33020
33450
  if (changed.has("annotations") || changed.has("annotatable")) this._syncAnnotations();
33021
33451
  }
33022
33452
  this._checkAccessibleLabel();
@@ -33494,6 +33924,11 @@ __decorate([property({
33494
33924
  type: Boolean,
33495
33925
  reflect: true
33496
33926
  })], NLDDTextEditor.prototype, "required", void 0);
33927
+ __decorate([property({
33928
+ type: Boolean,
33929
+ reflect: true,
33930
+ attribute: "no-spellcheck"
33931
+ })], NLDDTextEditor.prototype, "noSpellcheck", void 0);
33497
33932
  __decorate([property({
33498
33933
  type: Boolean,
33499
33934
  reflect: true
@@ -33506,12 +33941,14 @@ __decorate([property({
33506
33941
  __decorate([property({
33507
33942
  reflect: true,
33508
33943
  converter: reflectNonDefault("simple")
33509
- })], NLDDTextEditor.prototype, "variant", void 0);
33944
+ })], NLDDTextEditor.prototype, "appearance", void 0);
33510
33945
  __decorate([property({
33511
33946
  type: String,
33512
33947
  attribute: "accessible-label"
33513
33948
  })], NLDDTextEditor.prototype, "accessibleLabel", void 0);
33514
33949
  __decorate([property({ attribute: false })], NLDDTextEditor.prototype, "mentionSource", void 0);
33950
+ __decorate([property({ attribute: false })], NLDDTextEditor.prototype, "mentionQuery", void 0);
33951
+ __decorate([property({ attribute: false })], NLDDTextEditor.prototype, "mentionEmptyText", void 0);
33515
33952
  __decorate([property({ attribute: false })], NLDDTextEditor.prototype, "typeaheads", void 0);
33516
33953
  __decorate([property({
33517
33954
  type: Boolean,
@@ -34801,7 +35238,7 @@ var NLDDTimePicker = (_NLDDTimePicker = class NLDDTimePicker extends DescribedBy
34801
35238
  this._selfScrollTimer = 0;
34802
35239
  }
34803
35240
  _t(key) {
34804
- return this.translations[key] ?? nlddTimePickerTranslations[key];
35241
+ return translate(this.translations, nlddTimePickerTranslations, key);
34805
35242
  }
34806
35243
  get _label() {
34807
35244
  return this.accessibleLabel || this._t("components.time-picker.default-label");
@@ -35092,7 +35529,7 @@ function renderPicker$1(component) {
35092
35529
  return html`
35093
35530
  <div class="time-field__picker-button">
35094
35531
  <nldd-icon-button
35095
- variant="neutral-tinted"
35532
+ appearance="neutral-tinted"
35096
35533
  size=${buttonSize}
35097
35534
  icon="clock"
35098
35535
  text=${component._t("components.time-field.to-pick-time-action")}
@@ -35133,7 +35570,7 @@ function renderPicker$1(component) {
35133
35570
  `}
35134
35571
  <nldd-spacer size="16"></nldd-spacer>
35135
35572
  <nldd-button
35136
- variant="neutral-tinted"
35573
+ appearance="neutral-tinted"
35137
35574
  size=${component._pickerButtonSize}
35138
35575
  width="full"
35139
35576
  text=${component._t("components.time-field.confirm-action")}
@@ -35341,7 +35778,7 @@ var NLDDTimeField = (_NLDDTimeField3 = class NLDDTimeField extends DescribedBy(F
35341
35778
  super.disconnectedCallback();
35342
35779
  }
35343
35780
  _t(key) {
35344
- return this.translations[key] ?? nlddTimeFieldTranslations[key];
35781
+ return translate(this.translations, nlddTimeFieldTranslations, key);
35345
35782
  }
35346
35783
  get _fieldLabel() {
35347
35784
  return this.accessibleLabel || this._t("components.time-field.default-label");
@@ -35690,11 +36127,23 @@ var toggleButtonStyles = css`
35690
36127
  --_font: var(--semantics-buttons-md-primary-text-font);
35691
36128
  --_icon-size: var(--semantics-buttons-md-icon-size);
35692
36129
  --_icon-only-icon-size: var(--semantics-buttons-md-is-icon-only-icon-size);
36130
+ --_background-color: var(--semantics-buttons-neutral-tinted-background-color);
36131
+ --_content-color: var(--semantics-buttons-neutral-tinted-content-color);
35693
36132
  --_highlight-border-color: var(--semantics-buttons-neutral-tinted-highlight-border-color);
36133
+ --_is-hovered-background-color: var(--semantics-buttons-neutral-tinted-is-hovered-background-color);
36134
+ --_is-hovered-content-color: var(--semantics-buttons-neutral-tinted-is-hovered-content-color);
35694
36135
  --_is-hovered-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-hovered-highlight-border-color);
36136
+ --_is-active-background-color: var(--semantics-buttons-neutral-tinted-is-active-background-color);
36137
+ --_is-active-content-color: var(--semantics-buttons-neutral-tinted-is-active-content-color);
35695
36138
  --_is-active-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-active-highlight-border-color);
36139
+ --_is-selected-background-color: var(--semantics-buttons-neutral-tinted-is-selected-background-color);
36140
+ --_is-selected-content-color: var(--semantics-buttons-neutral-tinted-is-selected-content-color);
35696
36141
  --_is-selected-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-highlight-border-color);
36142
+ --_is-selected-is-hovered-background-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-background-color);
36143
+ --_is-selected-is-hovered-content-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-content-color);
35697
36144
  --_is-selected-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-highlight-border-color);
36145
+ --_is-selected-is-active-background-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-background-color);
36146
+ --_is-selected-is-active-content-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-content-color);
35698
36147
  --_is-selected-is-active-highlight-border-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-highlight-border-color);
35699
36148
 
35700
36149
  ${inheritedTextReset}
@@ -35747,6 +36196,81 @@ var toggleButtonStyles = css`
35747
36196
  --_stacked-text-font: var(--primitives-font-body-xxs-medium-flat);
35748
36197
  }
35749
36198
 
36199
+ :host([appearance="neutral-base"]) {
36200
+ --_background-color: var(--semantics-buttons-neutral-base-background-color);
36201
+ --_content-color: var(--semantics-buttons-neutral-base-content-color);
36202
+ --_highlight-border-color: var(--semantics-buttons-neutral-base-highlight-border-color);
36203
+ --_is-hovered-background-color: var(--semantics-buttons-neutral-base-is-hovered-background-color);
36204
+ --_is-hovered-content-color: var(--semantics-buttons-neutral-base-is-hovered-content-color);
36205
+ --_is-hovered-highlight-border-color: var(--semantics-buttons-neutral-base-is-hovered-highlight-border-color);
36206
+ --_is-active-background-color: var(--semantics-buttons-neutral-base-is-active-background-color);
36207
+ --_is-active-content-color: var(--semantics-buttons-neutral-base-is-active-content-color);
36208
+ --_is-active-highlight-border-color: var(--semantics-buttons-neutral-base-is-active-highlight-border-color);
36209
+ --_is-selected-background-color: var(--semantics-buttons-neutral-base-is-selected-background-color);
36210
+ --_is-selected-content-color: var(--semantics-buttons-neutral-base-is-selected-content-color);
36211
+ --_is-selected-highlight-border-color: var(--semantics-buttons-neutral-base-is-selected-highlight-border-color);
36212
+ --_is-selected-is-hovered-background-color: var(--semantics-buttons-neutral-base-is-selected-is-hovered-background-color);
36213
+ --_is-selected-is-hovered-content-color: var(--semantics-buttons-neutral-base-is-selected-is-hovered-content-color);
36214
+ --_is-selected-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-base-is-selected-is-hovered-highlight-border-color);
36215
+ --_is-selected-is-active-background-color: var(--semantics-buttons-neutral-base-is-selected-is-active-background-color);
36216
+ --_is-selected-is-active-content-color: var(--semantics-buttons-neutral-base-is-selected-is-active-content-color);
36217
+ --_is-selected-is-active-highlight-border-color: var(--semantics-buttons-neutral-base-is-selected-is-active-highlight-border-color);
36218
+ }
36219
+
36220
+ :host([appearance="neutral-transparent"]) {
36221
+ --_background-color: transparent;
36222
+ --_content-color: var(--semantics-buttons-neutral-transparent-content-color);
36223
+ --_highlight-border-color: transparent;
36224
+ --_is-hovered-background-color: transparent;
36225
+ --_is-hovered-content-color: var(--semantics-buttons-neutral-transparent-is-hovered-content-color);
36226
+ --_is-hovered-highlight-border-color: transparent;
36227
+ --_is-active-background-color: transparent;
36228
+ --_is-active-content-color: var(--semantics-buttons-neutral-transparent-is-active-content-color);
36229
+ --_is-active-highlight-border-color: transparent;
36230
+ --_is-selected-background-color: var(--semantics-buttons-neutral-transparent-is-selected-background-color);
36231
+ --_is-selected-content-color: var(--semantics-buttons-neutral-transparent-is-selected-content-color);
36232
+ --_is-selected-highlight-border-color: var(--semantics-buttons-neutral-transparent-is-selected-highlight-border-color);
36233
+ --_is-selected-is-hovered-background-color: var(--semantics-buttons-neutral-transparent-is-selected-is-hovered-background-color);
36234
+ --_is-selected-is-hovered-content-color: var(--semantics-buttons-neutral-transparent-is-selected-is-hovered-content-color);
36235
+ --_is-selected-is-hovered-highlight-border-color: var(--semantics-buttons-neutral-transparent-is-selected-is-hovered-highlight-border-color);
36236
+ --_is-selected-is-active-background-color: var(--semantics-buttons-neutral-transparent-is-selected-is-active-background-color);
36237
+ --_is-selected-is-active-content-color: var(--semantics-buttons-neutral-transparent-is-selected-is-active-content-color);
36238
+ --_is-selected-is-active-highlight-border-color: var(--semantics-buttons-neutral-transparent-is-selected-is-active-highlight-border-color);
36239
+ }
36240
+
36241
+ :host([appearance="accent-transparent"]) {
36242
+ --_background-color: transparent;
36243
+ --_content-color: var(--semantics-buttons-accent-transparent-content-color);
36244
+ --_highlight-border-color: transparent;
36245
+ --_is-hovered-background-color: transparent;
36246
+ --_is-hovered-content-color: var(--semantics-buttons-accent-transparent-is-hovered-content-color);
36247
+ --_is-hovered-highlight-border-color: transparent;
36248
+ --_is-active-background-color: transparent;
36249
+ --_is-active-content-color: var(--semantics-buttons-accent-transparent-is-active-content-color);
36250
+ --_is-active-highlight-border-color: transparent;
36251
+ --_is-selected-background-color: var(--semantics-buttons-accent-transparent-is-selected-background-color);
36252
+ --_is-selected-content-color: var(--semantics-buttons-accent-transparent-is-selected-content-color);
36253
+ --_is-selected-highlight-border-color: var(--semantics-buttons-accent-transparent-is-selected-highlight-border-color);
36254
+ --_is-selected-is-hovered-background-color: var(--semantics-buttons-accent-transparent-is-selected-is-hovered-background-color);
36255
+ --_is-selected-is-hovered-content-color: var(--semantics-buttons-accent-transparent-is-selected-is-hovered-content-color);
36256
+ --_is-selected-is-hovered-highlight-border-color: var(--semantics-buttons-accent-transparent-is-selected-is-hovered-highlight-border-color);
36257
+ --_is-selected-is-active-background-color: var(--semantics-buttons-accent-transparent-is-selected-is-active-background-color);
36258
+ --_is-selected-is-active-content-color: var(--semantics-buttons-accent-transparent-is-selected-is-active-content-color);
36259
+ --_is-selected-is-active-highlight-border-color: var(--semantics-buttons-accent-transparent-is-selected-is-active-highlight-border-color);
36260
+ }
36261
+
36262
+ :host([selected-icon]:is([appearance="neutral-transparent"], [appearance="accent-transparent"])) {
36263
+ --_is-selected-background-color: var(--_background-color);
36264
+ --_is-selected-content-color: var(--_content-color);
36265
+ --_is-selected-highlight-border-color: var(--_highlight-border-color);
36266
+ --_is-selected-is-hovered-background-color: var(--_is-hovered-background-color);
36267
+ --_is-selected-is-hovered-content-color: var(--_is-hovered-content-color);
36268
+ --_is-selected-is-hovered-highlight-border-color: var(--_is-hovered-highlight-border-color);
36269
+ --_is-selected-is-active-background-color: var(--_is-active-background-color);
36270
+ --_is-selected-is-active-content-color: var(--_is-active-content-color);
36271
+ --_is-selected-is-active-highlight-border-color: var(--_is-active-highlight-border-color);
36272
+ }
36273
+
35750
36274
  :host([disabled]) {
35751
36275
  opacity: var(--primitives-opacity-disabled);
35752
36276
  pointer-events: none;
@@ -35763,7 +36287,7 @@ var toggleButtonStyles = css`
35763
36287
  border: none;
35764
36288
  border-radius: var(--_corner-radius);
35765
36289
  background: none;
35766
- background-color: var(--semantics-buttons-neutral-tinted-background-color);
36290
+ background-color: var(--_background-color);
35767
36291
  box-shadow: inset 0 0 0 var(--primitives-border-width-thin) var(--_highlight-border-color);
35768
36292
  width: var(--_min-size);
35769
36293
  min-height: var(--_min-size);
@@ -35771,7 +36295,7 @@ var toggleButtonStyles = css`
35771
36295
  gap: var(--_gap);
35772
36296
  align-items: center;
35773
36297
  justify-content: center;
35774
- color: var(--semantics-buttons-neutral-tinted-content-color);
36298
+ color: var(--_content-color);
35775
36299
  font: var(--_font);
35776
36300
  white-space: nowrap;
35777
36301
  text-decoration: none;
@@ -35787,38 +36311,38 @@ var toggleButtonStyles = css`
35787
36311
  .toggle-button:hover,
35788
36312
  .toggle-button:has(.toggle-button__input:hover) {
35789
36313
  --_highlight-border-color: var(--_is-hovered-highlight-border-color);
35790
- background-color: var(--semantics-buttons-neutral-tinted-is-hovered-background-color);
35791
- color: var(--semantics-buttons-neutral-tinted-is-hovered-content-color);
36314
+ background-color: var(--_is-hovered-background-color);
36315
+ color: var(--_is-hovered-content-color);
35792
36316
  }
35793
36317
  }
35794
36318
 
35795
36319
  .toggle-button:active,
35796
36320
  .toggle-button:has(.toggle-button__input:active) {
35797
36321
  --_highlight-border-color: var(--_is-active-highlight-border-color);
35798
- background-color: var(--semantics-buttons-neutral-tinted-is-active-background-color);
35799
- color: var(--semantics-buttons-neutral-tinted-is-active-content-color);
36322
+ background-color: var(--_is-active-background-color);
36323
+ color: var(--_is-active-content-color);
35800
36324
  }
35801
36325
 
35802
36326
  :host([selected]) .toggle-button {
35803
36327
  --_highlight-border-color: var(--_is-selected-highlight-border-color);
35804
- background-color: var(--semantics-buttons-neutral-tinted-is-selected-background-color);
35805
- color: var(--semantics-buttons-neutral-tinted-is-selected-content-color);
36328
+ background-color: var(--_is-selected-background-color);
36329
+ color: var(--_is-selected-content-color);
35806
36330
  }
35807
36331
 
35808
36332
  @media (hover: hover) {
35809
36333
  :host([selected]) .toggle-button:hover,
35810
36334
  :host([selected]) .toggle-button:has(.toggle-button__input:hover) {
35811
36335
  --_highlight-border-color: var(--_is-selected-is-hovered-highlight-border-color);
35812
- background-color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-background-color);
35813
- color: var(--semantics-buttons-neutral-tinted-is-selected-is-hovered-content-color);
36336
+ background-color: var(--_is-selected-is-hovered-background-color);
36337
+ color: var(--_is-selected-is-hovered-content-color);
35814
36338
  }
35815
36339
  }
35816
36340
 
35817
36341
  :host([selected]) .toggle-button:active,
35818
36342
  :host([selected]) .toggle-button:has(.toggle-button__input:active) {
35819
36343
  --_highlight-border-color: var(--_is-selected-is-active-highlight-border-color);
35820
- background-color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-background-color);
35821
- color: var(--semantics-buttons-neutral-tinted-is-selected-is-active-content-color);
36344
+ background-color: var(--_is-selected-is-active-background-color);
36345
+ color: var(--_is-selected-is-active-content-color);
35822
36346
  }
35823
36347
 
35824
36348
  .toggle-button:focus-visible,
@@ -35893,8 +36417,9 @@ function toggleButtonTemplate(component) {
35893
36417
  const showPlaceholder = component.variant === "icon" || component.variant === "icon-and-text";
35894
36418
  const ariaLabel = component.accessibleLabel || (component.variant === "icon" && component.text ? component.text : "") || nothing;
35895
36419
  const tooltipText = showIcon && !showText ? component.accessibleLabel || component.text || "" : "";
35896
- const icon = component.icon ? html`<nldd-icon class="toggle-button__icon"
35897
- icon=${component.icon}
36420
+ const iconName = component.selected && component.selectedIcon ? component.selectedIcon : component.icon;
36421
+ const icon = iconName ? html`<nldd-icon class="toggle-button__icon"
36422
+ icon=${iconName}
35898
36423
  ></nldd-icon>` : html`<slot
35899
36424
  name="icon"
35900
36425
  @slotchange=${component.requestUpdate}
@@ -35958,6 +36483,11 @@ function toggleButtonTemplate(component) {
35958
36483
  * A selectable button that toggles between selected and unselected.
35959
36484
  * Available as a button (aria-pressed), a checkbox, or a radio.
35960
36485
  *
36486
+ * The label stays the same in both states: the state is in aria-pressed (or
36487
+ * checked) and in the fill, so a screen reader says "Favoriet, pressed". A label
36488
+ * that changes with the state ("Volgen", then "Ontvolgen") says what the
36489
+ * button does next; that is an nldd-button whose text you change, not a toggle.
36490
+ *
35961
36491
  * In radio mode the button itself is the radio: it carries the role, the state
35962
36492
  * and its place in the group. A native radio in a shadow root of its own would
35963
36493
  * be a group of one, counted as "1 of 1" and stopped at by Tab.
@@ -35965,6 +36495,7 @@ function toggleButtonTemplate(component) {
35965
36495
  * @element nldd-toggle-button
35966
36496
  *
35967
36497
  * @attr {'button' | 'checkbox' | 'radio'} type - What the button is: a button with aria-pressed, a native checkbox, or a radio (default: 'button')
36498
+ * @attr {'neutral-tinted' | 'neutral-base' | 'neutral-transparent' | 'accent-transparent'} appearance - Visual style, color included (default: 'neutral-tinted'). Selected is filled in each of them; the transparent ones are for a toggle among transparent buttons, and with a selected-icon they stay quiet when on.
35968
36499
  * @attr {'xs' | 'sm' | 'md' | 'lg'} size - Button size (default: 'md')
35969
36500
  * @attr {boolean} selected - Selected state
35970
36501
  * @attr {boolean} disabled - Disabled state
@@ -35973,6 +36504,7 @@ function toggleButtonTemplate(component) {
35973
36504
  * @attr {string} name - Name for form submission (checkbox/radio)
35974
36505
  * @attr {string} text - Button text
35975
36506
  * @attr {string} icon - Icon name for nldd-icon
36507
+ * @attr {string} selected-icon - Icon shown instead of `icon` while selected, such as `check-mark` for `plus` or `heart-filled` for `heart`. The appearances with a surface fill it when on, as without one. The transparent appearances have no surface to fill: with a selected-icon they stay quiet when on and the change of shape says it is on; without one they fill, so the state always shows.
35976
36508
  * @attr {'text' | 'icon' | 'icon-and-text'} variant - What renders: text, icon, or both. Unset → auto-detect from text/icon attributes.
35977
36509
  * @attr {string} accessible-label - Accessible label; required for icon-only usage
35978
36510
  * @attr {boolean} required - Required state. Set by nldd-toggle-button-group.
@@ -35989,6 +36521,7 @@ var NLDDToggleButton = (_NLDDToggleButton = class NLDDToggleButton extends Descr
35989
36521
  this.required = false;
35990
36522
  this._initialSelected = false;
35991
36523
  this.type = "button";
36524
+ this.appearance = "neutral-tinted";
35992
36525
  this.size = "md";
35993
36526
  this.selected = false;
35994
36527
  this.disabled = false;
@@ -35997,6 +36530,7 @@ var NLDDToggleButton = (_NLDDToggleButton = class NLDDToggleButton extends Descr
35997
36530
  this.name = "";
35998
36531
  this.text = "";
35999
36532
  this.icon = "";
36533
+ this.selectedIcon = "";
36000
36534
  this.variant = "";
36001
36535
  this.accessibleLabel = "";
36002
36536
  this._warnedA11y = false;
@@ -36175,6 +36709,10 @@ __decorate([property({
36175
36709
  type: String,
36176
36710
  reflect: true
36177
36711
  })], NLDDToggleButton.prototype, "type", void 0);
36712
+ __decorate([property({
36713
+ reflect: true,
36714
+ converter: reflectNonDefault("neutral-tinted")
36715
+ })], NLDDToggleButton.prototype, "appearance", void 0);
36178
36716
  __decorate([property({
36179
36717
  reflect: true,
36180
36718
  converter: reflectNonDefault("md")
@@ -36202,6 +36740,11 @@ __decorate([property({
36202
36740
  converter: reflectNonDefault("")
36203
36741
  })], NLDDToggleButton.prototype, "text", void 0);
36204
36742
  __decorate([property({ type: String })], NLDDToggleButton.prototype, "icon", void 0);
36743
+ __decorate([property({
36744
+ reflect: true,
36745
+ attribute: "selected-icon",
36746
+ converter: reflectNonDefault("")
36747
+ })], NLDDToggleButton.prototype, "selectedIcon", void 0);
36205
36748
  __decorate([property({
36206
36749
  reflect: true,
36207
36750
  converter: reflectNonDefault("")
@@ -36268,7 +36811,7 @@ function toggleButtonGroupTemplate(component) {
36268
36811
  * Nederlandse Digitale Dienst Toggle Button Group Component (Lit + TypeScript)
36269
36812
  *
36270
36813
  * Groups nldd-toggle-button elements and manages selection, keyboard navigation,
36271
- * and forwarding of type, name, size, and disabled state to all buttons.
36814
+ * and forwarding of type, name, appearance, size, and disabled state to all buttons.
36272
36815
  *
36273
36816
  * For type="radio" (single-select), arrow keys navigate between buttons and
36274
36817
  * automatically select the focused one.
@@ -36278,6 +36821,7 @@ function toggleButtonGroupTemplate(component) {
36278
36821
  *
36279
36822
  * @attr {'button' | 'checkbox' | 'radio'} type - Selection mode (default: 'checkbox')
36280
36823
  * @attr {string} name - Forwarded to all buttons
36824
+ * @attr {'neutral-tinted' | 'neutral-base' | 'neutral-transparent' | 'accent-transparent'} appearance - Forwarded to all buttons (default: 'neutral-tinted')
36281
36825
  * @attr {'xs' | 'sm' | 'md'} size - Forwarded to all buttons (default: 'md')
36282
36826
  * @attr {boolean} disabled - Disables all buttons
36283
36827
  * @attr {string} accessible-label - Accessible name for the group (aria-label)
@@ -36297,6 +36841,7 @@ var NLDDToggleButtonGroup = (_NLDDToggleButtonGroup = class NLDDToggleButtonGrou
36297
36841
  this._warnedRequired = false;
36298
36842
  this.type = "checkbox";
36299
36843
  this.name = "";
36844
+ this.appearance = "neutral-tinted";
36300
36845
  this.size = "md";
36301
36846
  this.disabled = false;
36302
36847
  this.accessibleLabel = "";
@@ -36366,7 +36911,7 @@ var NLDDToggleButtonGroup = (_NLDDToggleButtonGroup = class NLDDToggleButtonGrou
36366
36911
  }
36367
36912
  firstUpdated() {}
36368
36913
  updated(changed) {
36369
- if (changed.has("type") || changed.has("name") || changed.has("size") || changed.has("disabled")) this._syncButtons();
36914
+ if (changed.has("type") || changed.has("name") || changed.has("appearance") || changed.has("size") || changed.has("disabled")) this._syncButtons();
36370
36915
  if (changed.has("type")) this._syncRole();
36371
36916
  if (changed.has("accessibleLabel")) this._appliedLabel = setOwnedAttribute(this, "aria-label", this.accessibleLabel, this._appliedLabel);
36372
36917
  if (changed.has("accessibleLabeledBy")) {
@@ -36386,6 +36931,7 @@ var NLDDToggleButtonGroup = (_NLDDToggleButtonGroup = class NLDDToggleButtonGrou
36386
36931
  else this.removeAttribute("aria-invalid");
36387
36932
  this._getButtons().forEach((button) => {
36388
36933
  button.type = this.type;
36934
+ button.appearance = this.appearance;
36389
36935
  button.size = this.size;
36390
36936
  button.required = this.required && this.type === "radio";
36391
36937
  if (this.type !== "button") button.name = this.name;
@@ -36440,6 +36986,10 @@ __decorate([property({
36440
36986
  reflect: true
36441
36987
  })], NLDDToggleButtonGroup.prototype, "type", void 0);
36442
36988
  __decorate([property({ type: String })], NLDDToggleButtonGroup.prototype, "name", void 0);
36989
+ __decorate([property({
36990
+ reflect: true,
36991
+ converter: reflectNonDefault("neutral-tinted")
36992
+ })], NLDDToggleButtonGroup.prototype, "appearance", void 0);
36443
36993
  __decorate([property({
36444
36994
  reflect: true,
36445
36995
  converter: reflectNonDefault("md")
@@ -36696,7 +37246,7 @@ function renderPicker(component) {
36696
37246
  return html`
36697
37247
  <div class="token-field__picker">
36698
37248
  <nldd-icon-button
36699
- variant="neutral-tinted"
37249
+ appearance="neutral-tinted"
36700
37250
  size="sm"
36701
37251
  icon="chevron-down"
36702
37252
  text=${component._t("components.token-field.open-menu-action")}
@@ -36795,13 +37345,19 @@ var nlddTokenFieldTranslations = {
36795
37345
  * exactly like nldd-combo-box; the menu filters as you type, with a chevron picker
36796
37346
  * button, arrow-key roving across the tokens and ElementInternals form participation.
36797
37347
  *
37348
+ * Options can arrive after the keystroke, from a server you query per
37349
+ * keystroke. Slot them into the menu when they come in: if the user is still
37350
+ * in the field and the keystroke found nothing to show, the menu opens then.
37351
+ * After Escape, or once the user left the field, it stays shut.
37352
+ *
36798
37353
  * @element nldd-token-field
36799
37354
  * @attr {string} values - Initial token values as a comma-separated string (e.g. "nl, be, de"). Not reflected; the live value is the `.values` array property. Values can't contain commas.
36800
37355
  * @attr {string} placeholder - Placeholder shown in the input
36801
37356
  * @attr {string} type - Input type forwarded to the inner input (e.g. 'email')
36802
37357
  * @attr {string} autocomplete - Autocomplete hint forwarded to the inner input
36803
37358
  * @attr {string} accessible-label - Accessible label forwarded as aria-label to the input
36804
- * @attr {boolean} allow-custom - Allow free-typed values (not just menu options)
37359
+ * @attr {boolean} allow-custom - Allow free-typed values (not just menu options). Typing an option's label in full adds that option, with its value, ignoring case and the spaces around it; with two such labels, the first one.
37360
+ * @attr {boolean} no-filter - Leaves the options as they are while typing, for a list your server already filtered per keystroke. Without it the field hides options that do not contain the typed text, which also hides a server match on, say, an e-mail address.
36805
37361
  * @attr {boolean} valid - Marks the field valid (shows the valid icon)
36806
37362
  * @attr {boolean} invalid - Marks the field invalid (shows the invalid icon)
36807
37363
  * @attr {boolean} no-spellcheck - Disables browser spellchecking on the inner input
@@ -36831,6 +37387,7 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
36831
37387
  this.autocomplete = "";
36832
37388
  this.accessibleLabel = "";
36833
37389
  this.allowCustom = false;
37390
+ this.noFilter = false;
36834
37391
  this.valid = false;
36835
37392
  this.invalid = false;
36836
37393
  this.noSpellcheck = false;
@@ -36848,6 +37405,7 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
36848
37405
  this._menu = null;
36849
37406
  this._resizeObserver = null;
36850
37407
  this._menuObserver = null;
37408
+ this._openPending = false;
36851
37409
  this._templateObserver = null;
36852
37410
  this._pickerPointerdownWhileOpen = false;
36853
37411
  this._removalFocusIndex = null;
@@ -36865,10 +37423,13 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
36865
37423
  this._handleMenuToggle = (e) => {
36866
37424
  this._isOpen = e.newState === "open";
36867
37425
  if (!this._isOpen) this._highlightedId = "";
36868
- else requestAnimationFrame(() => {
36869
- if (this._menu && !this._menu.getHighlighted()) this._menu.moveHighlight("next");
36870
- this._updateActiveDescendant();
36871
- });
37426
+ else {
37427
+ this._openPending = false;
37428
+ requestAnimationFrame(() => {
37429
+ if (this._menu && !this._menu.getHighlighted()) this._menu.moveHighlight("next");
37430
+ this._updateActiveDescendant();
37431
+ });
37432
+ }
36872
37433
  };
36873
37434
  this._handleMenuSelect = (e) => {
36874
37435
  const item = e.target;
@@ -36895,7 +37456,7 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
36895
37456
  this.requestUpdate("values", old);
36896
37457
  }
36897
37458
  _t(key) {
36898
- return this.translations[key] ?? nlddTokenFieldTranslations[key];
37459
+ return translate(this.translations, nlddTokenFieldTranslations, key);
36899
37460
  }
36900
37461
  connectedCallback() {
36901
37462
  super.connectedCallback();
@@ -37090,6 +37651,7 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
37090
37651
  }
37091
37652
  this._syncMenuItems();
37092
37653
  if (!this._isOpen) this._openMenu();
37654
+ this._openPending = this._text !== "" && !this._menu?.matches(":popover-open");
37093
37655
  this.dispatchEvent(new CustomEvent("input", {
37094
37656
  detail: { value: this._text },
37095
37657
  bubbles: true,
@@ -37104,7 +37666,7 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
37104
37666
  const remainder = parts.pop() ?? "";
37105
37667
  const next = [...this.values];
37106
37668
  for (const part of parts) {
37107
- const value = part.trim();
37669
+ const value = part.trim() ? this._valueForTypedText(part) : "";
37108
37670
  if (value && !next.includes(value)) next.push(value);
37109
37671
  }
37110
37672
  if (next.length !== this.values.length) {
@@ -37122,9 +37684,10 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
37122
37684
  }
37123
37685
  /** Close the menu when focus leaves the field for anything but the menu. */
37124
37686
  _handleBlur(e) {
37687
+ this._openPending = false;
37125
37688
  const related = e.relatedTarget;
37126
37689
  if (related && this._menu?.contains(related)) return;
37127
- if (this.allowCustom && this._text.trim()) this._commitValue(this._text.trim(), false);
37690
+ if (this.allowCustom && this._text.trim()) this._commitValue(this._valueForTypedText(this._text), false);
37128
37691
  else this._closeMenu();
37129
37692
  }
37130
37693
  _handleKeydown(e) {
@@ -37152,11 +37715,12 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
37152
37715
  highlighted.select();
37153
37716
  } else if (this.allowCustom && this._text.trim()) {
37154
37717
  e.preventDefault();
37155
- this._commitValue(this._text.trim());
37718
+ this._commitValue(this._valueForTypedText(this._text));
37156
37719
  } else submitOnEnter(this, e);
37157
37720
  break;
37158
37721
  }
37159
37722
  case "Escape":
37723
+ this._openPending = false;
37160
37724
  if (!this._isOpen) return;
37161
37725
  e.preventDefault();
37162
37726
  e.stopPropagation();
@@ -37311,6 +37875,7 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
37311
37875
  this._menuObserver?.disconnect();
37312
37876
  this._menuObserver = new MutationObserver(() => {
37313
37877
  this._hideSelectedMenuItems();
37878
+ this._handleMenuItemsChange();
37314
37879
  this.requestUpdate();
37315
37880
  });
37316
37881
  this._menuObserver.observe(menu, {
@@ -37326,6 +37891,16 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
37326
37891
  this._menu.width = `${rect.width}px`;
37327
37892
  }
37328
37893
  /**
37894
+ * Typing an option's label in full means that option: its value becomes the
37895
+ * token, not the label, so the form sends what a choice from the menu would.
37896
+ * Anything else typed is a custom value as it stands.
37897
+ */
37898
+ _valueForTypedText(text) {
37899
+ const typed = text.trim();
37900
+ const option = Array.from(this._menu?.querySelectorAll("nldd-menu-item") ?? []).find((item) => item.closest("nldd-menu") === this._menu && item.text.trim().toLowerCase() === typed.toLowerCase());
37901
+ return option ? option.value || option.text : typed;
37902
+ }
37903
+ /**
37329
37904
  * Add a value, clear the input, and close the menu — focus returns to the empty
37330
37905
  * input. The menu only reopens on a deliberate action (typing, ArrowDown, or the
37331
37906
  * picker), so a focused empty field behaves the same whether it was just focused
@@ -37350,6 +37925,23 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
37350
37925
  this._updateMenuWidth();
37351
37926
  this._menu.showPopover();
37352
37927
  }
37928
+ /**
37929
+ * The menu decides whether to open on a keystroke. Options that arrive later
37930
+ * get the same decision: they open a menu the keystroke could not open, and a
37931
+ * menu whose options all went away closes again, as it would on typing. Only
37932
+ * while the user is still in the field.
37933
+ */
37934
+ _handleMenuItemsChange() {
37935
+ if (!this._menu || this.shadowRoot?.activeElement !== this._input) return;
37936
+ if (this._menu.matches(":popover-open")) {
37937
+ if (this._visibleOptionCount === 0) this._closeMenu();
37938
+ return;
37939
+ }
37940
+ if (this._openPending && this._visibleOptionCount > 0) {
37941
+ this._openPending = false;
37942
+ this._openMenu();
37943
+ }
37944
+ }
37353
37945
  _closeMenu() {
37354
37946
  if (!this._menu) return;
37355
37947
  if (!this._menu.matches(":popover-open")) return;
@@ -37372,7 +37964,7 @@ var NLDDTokenField = (_NLDDTokenField2 = class NLDDTokenField extends DescribedB
37372
37964
  * typing, selecting, and whenever `values` changes. */
37373
37965
  _syncMenuItems() {
37374
37966
  if (!this._menu) return;
37375
- this._menu.filter(this._text);
37967
+ this._menu.filter(this._text, { hide: !this.noFilter });
37376
37968
  this._hideSelectedMenuItems();
37377
37969
  this._updateActiveDescendant();
37378
37970
  if (this._isOpen && this._visibleOptionCount === 0) this._closeMenu();
@@ -37421,6 +38013,11 @@ __decorate([property({
37421
38013
  reflect: true,
37422
38014
  attribute: "allow-custom"
37423
38015
  })], NLDDTokenField.prototype, "allowCustom", void 0);
38016
+ __decorate([property({
38017
+ type: Boolean,
38018
+ reflect: true,
38019
+ attribute: "no-filter"
38020
+ })], NLDDTokenField.prototype, "noFilter", void 0);
37424
38021
  __decorate([property({
37425
38022
  type: Boolean,
37426
38023
  reflect: true
@@ -42907,7 +43504,7 @@ var NLDDSidebarSection = (_NLDDSidebarSection = class NLDDSidebarSection extends
42907
43504
  return this._t("components.sidebar-section.sheet-dismiss-action");
42908
43505
  }
42909
43506
  _t(key) {
42910
- return this.translations[key] ?? nlddSidebarSectionTranslations[key];
43507
+ return translate(this.translations, nlddSidebarSectionTranslations, key);
42911
43508
  }
42912
43509
  connectedCallback() {
42913
43510
  super.connectedCallback();
@@ -43118,7 +43715,10 @@ var cardStyles = css`
43118
43715
  :host {
43119
43716
  --_background-color: var(--components-card-background-color);
43120
43717
  --_border-color: var(--components-card-highlight-border-color);
43121
- --_highlight-border: inset 0 0 0 var(--components-card-highlight-border-width) var(--_border-color);
43718
+ --_is-hovered-background-color: var(--components-card-is-hovered-background-color);
43719
+ --_is-hovered-border-color: var(--components-card-is-hovered-highlight-border-color);
43720
+ --_is-active-background-color: var(--components-card-is-active-background-color);
43721
+ --_is-active-border-color: var(--components-card-is-active-highlight-border-color);
43122
43722
 
43123
43723
  display: flex;
43124
43724
  /* Anchor for the focus ring, which hangs outside the card box. */
@@ -43137,6 +43737,10 @@ var cardStyles = css`
43137
43737
  :host([background="tinted"]) {
43138
43738
  --_background-color: var(--components-card-tinted-background-color);
43139
43739
  --_border-color: var(--components-card-tinted-highlight-border-color);
43740
+ --_is-hovered-background-color: var(--components-card-tinted-is-hovered-background-color);
43741
+ --_is-hovered-border-color: var(--components-card-tinted-is-hovered-highlight-border-color);
43742
+ --_is-active-background-color: var(--components-card-tinted-is-active-background-color);
43743
+ --_is-active-border-color: var(--components-card-tinted-is-active-highlight-border-color);
43140
43744
  }
43141
43745
 
43142
43746
 
@@ -43152,6 +43756,19 @@ var cardStyles = css`
43152
43756
  flex-direction: column;
43153
43757
  flex-grow: 1;
43154
43758
  isolation: isolate;
43759
+ transition: background-color var(--primitives-transition-duration-fast) var(--primitives-transition-easing-default);
43760
+ }
43761
+
43762
+ @media (hover: hover) {
43763
+ .card:has(> .card__action:hover) {
43764
+ --_border-color: var(--_is-hovered-border-color);
43765
+ background-color: var(--_is-hovered-background-color);
43766
+ }
43767
+ }
43768
+
43769
+ .card:has(> .card__action:active) {
43770
+ --_border-color: var(--_is-active-border-color);
43771
+ background-color: var(--_is-active-background-color);
43155
43772
  }
43156
43773
 
43157
43774
  .card::after {
@@ -43159,7 +43776,7 @@ var cardStyles = css`
43159
43776
  position: absolute;
43160
43777
  inset: 0;
43161
43778
  border-radius: inherit;
43162
- box-shadow: var(--_highlight-border);
43779
+ box-shadow: inset 0 0 0 var(--components-card-highlight-border-width) var(--_border-color);
43163
43780
  pointer-events: none;
43164
43781
  }
43165
43782
 
@@ -43303,6 +43920,9 @@ var nlddCardTranslations = { "components.card.opens-in-new-tab-label": "Opent in
43303
43920
  * directly, and Enter/Space work natively). `href` wins when both are set.
43304
43921
  * Nested interactive content, footer buttons for instance, has to be lifted
43305
43922
  * above it with `position: relative; z-index: 1` to stay clickable.
43923
+ * A card that is a link or button steps its surface and border one shade up
43924
+ * on hover and one more while pressed, as a neutral-base button does; content
43925
+ * lifted above the overlay does not set it off.
43306
43926
  *
43307
43927
  * @element nldd-card
43308
43928
  *
@@ -43610,7 +44230,7 @@ function collectionTemplate(component) {
43610
44230
  ` : nothing}
43611
44231
  ${showLoadMore ? html`
43612
44232
  <nldd-button
43613
- variant="neutral-tinted"
44233
+ appearance="neutral-tinted"
43614
44234
  text=${component._t("components.collection.load-more-action")}
43615
44235
  width="full"
43616
44236
  @click=${() => component._loadMore()}
@@ -43702,7 +44322,7 @@ var NLDDCollection = (_NLDDCollection = class NLDDCollection extends LitElement
43702
44322
  this._scrollListenerAttached = false;
43703
44323
  }
43704
44324
  _t(key) {
43705
- return this.translations[key] ?? nlddCollectionTranslations[key];
44325
+ return translate(this.translations, nlddCollectionTranslations, key);
43706
44326
  }
43707
44327
  _handOffControlFocus(disabling) {
43708
44328
  const controls = this.shadowRoot?.querySelectorAll("nldd-icon-button");
@@ -44139,7 +44759,7 @@ var NLDDWindow = (_NLDDWindow = class NLDDWindow extends LitElement {
44139
44759
  }
44140
44760
  }
44141
44761
  _t(key) {
44142
- return this.translations[key] ?? nlddWindowTranslations[key];
44762
+ return translate(this.translations, nlddWindowTranslations, key);
44143
44763
  }
44144
44764
  get _resolvedAccessibleLabel() {
44145
44765
  return this.accessibleLabel || this._titleBar.text || this._t("components.window.accessible-label");
@@ -44654,7 +45274,6 @@ var NLDDPageFooterLegalBar = class extends LitElement {
44654
45274
  this.translations = {};
44655
45275
  this._hasStart = false;
44656
45276
  this._hasEnd = false;
44657
- this._mergedTranslations = { ...nlddPageFooterTranslations };
44658
45277
  this._onSlotChange = (e) => {
44659
45278
  const slot = e.target;
44660
45279
  const hasContent = slot.assignedElements().length > 0;
@@ -44663,17 +45282,9 @@ var NLDDPageFooterLegalBar = class extends LitElement {
44663
45282
  else if (name === "end") this._hasEnd = hasContent;
44664
45283
  };
44665
45284
  }
44666
- willUpdate(changed) {
44667
- if (changed.has("translations") || changed.has("accessibleLabel")) {
44668
- this._mergedTranslations = {
44669
- ...nlddPageFooterTranslations,
44670
- ...this.translations
44671
- };
44672
- if (this.accessibleLabel) this._mergedTranslations["components.page-footer.legal-bar-accessible-label"] = this.accessibleLabel;
44673
- }
44674
- }
44675
45285
  _t(key) {
44676
- return this._mergedTranslations[key] ?? "";
45286
+ if (key === "components.page-footer.legal-bar-accessible-label" && this.accessibleLabel) return this.accessibleLabel;
45287
+ return translate(this.translations, nlddPageFooterTranslations, key);
44677
45288
  }
44678
45289
  render() {
44679
45290
  return pageFooterLegalBarTemplate(this);
@@ -45332,7 +45943,7 @@ var NLDDTable = (_NLDDTable = class NLDDTable extends LitElement {
45332
45943
  this._warnedSilentEmpty = false;
45333
45944
  }
45334
45945
  _t(key) {
45335
- return this.translations[key] ?? nlddTableTranslations[key];
45946
+ return translate(this.translations, nlddTableTranslations, key);
45336
45947
  }
45337
45948
  connectedCallback() {
45338
45949
  super.connectedCallback();
@@ -45416,12 +46027,16 @@ var NLDDTable = (_NLDDTable = class NLDDTable extends LitElement {
45416
46027
  const overflowX = getComputedStyle(this).overflowX;
45417
46028
  if ((overflowX === "auto" || overflowX === "scroll") && this.scrollWidth > this.clientWidth) this.setAttribute("tabindex", "0");
45418
46029
  else this.removeAttribute("tabindex");
45419
- if (this.accessibleLabel) this.setAttribute("aria-label", this.accessibleLabel);
45420
- else this.setAttribute("aria-label", this._t("components.table.accessible-label"));
46030
+ this._syncLabel();
46031
+ }
46032
+ /** Also on every render, so the fallback follows a language switch. */
46033
+ _syncLabel() {
46034
+ this.setAttribute("aria-label", this.accessibleLabel || this._t("components.table.accessible-label"));
45421
46035
  }
45422
46036
  updated(changed) {
45423
46037
  if (changed.has("columns") || changed.has("smColumns") || changed.has("mdColumns") || changed.has("lgColumns")) this._applyColumns();
45424
46038
  if (changed.has("accessibleLabel")) this._syncHostA11y();
46039
+ else this._syncLabel();
45425
46040
  if (changed.has("selectable")) for (const row of this.querySelectorAll("nldd-table-row")) row._syncAriaSelected();
45426
46041
  if (this.columns) this._warnedColumns = false;
45427
46042
  if (this.accessibleLabel) this._warnedLabel = false;
@@ -46366,7 +46981,7 @@ var NLDDDragHandleCell = (_NLDDDragHandleCell = class NLDDDragHandleCell extends
46366
46981
  this.translations = {};
46367
46982
  }
46368
46983
  _t(key) {
46369
- return this.translations[key] ?? nlddDragHandleCellTranslations[key];
46984
+ return translate(this.translations, nlddDragHandleCellTranslations, key);
46370
46985
  }
46371
46986
  render() {
46372
46987
  const label = this._t("components.drag-handle-cell.accessible-label");
@@ -46421,11 +47036,11 @@ var timelineTrackCellStyles = css`
46421
47036
  --_marker-size: var(--primitives-space-24);
46422
47037
  }
46423
47038
 
46424
- :host([variant="minor"]) {
47039
+ :host([level="minor"]) {
46425
47040
  --_marker-size: var(--primitives-space-10);
46426
47041
  }
46427
47042
 
46428
- :host([size="md"][variant="minor"]) {
47043
+ :host([size="md"][level="minor"]) {
46429
47044
  --_marker-size: var(--primitives-space-12);
46430
47045
  }
46431
47046
 
@@ -46500,9 +47115,9 @@ var timelineTrackCellStyles = css`
46500
47115
  background-color: var(--_track-color);
46501
47116
  }
46502
47117
 
46503
- :host([variant="none"][status="future"]) .timeline-track-cell__full-line,
46504
- :host([variant="none"][status="current"]:not([direction="up"])) .timeline-track-cell__full-line,
46505
- :host([variant="none"][line="none"]) .timeline-track-cell__full-line {
47118
+ :host([level="none"][status="future"]) .timeline-track-cell__full-line,
47119
+ :host([level="none"][status="current"]:not([direction="up"])) .timeline-track-cell__full-line,
47120
+ :host([level="none"][line="none"]) .timeline-track-cell__full-line {
46506
47121
  background-color: var(--_future-fill-color);
46507
47122
  }
46508
47123
 
@@ -46566,7 +47181,7 @@ var timelineTrackCellStyles = css`
46566
47181
  //#endregion
46567
47182
  //#region src/components/lists-and-tables/cells/timeline-track-cell/timeline-track-cell.template.ts
46568
47183
  function timelineTrackCellTemplate(component) {
46569
- if (component.variant === "none") return html`
47184
+ if (component.level === "none") return html`
46570
47185
  <div class="timeline-track-cell">
46571
47186
  ${component.position === "only" ? nothing : html`<div class="timeline-track-cell__full-line"></div>`}
46572
47187
  </div>
@@ -46597,18 +47212,18 @@ function timelineTrackCellTemplate(component) {
46597
47212
  * edge and consecutive steps connect without gaps.
46598
47213
  *
46599
47214
  * By default the cell is a bare track: a line with a dot per row, for a timeline
46600
- * of events. With `variant="step"` the dot grows big enough for a number or an
47215
+ * of events. With `size="md"` the dot grows big enough for a number or an
46601
47216
  * icon and you have a list of steps under each other, the vertical counterpart
46602
- * of `nldd-step-indicator`. The size belongs to the variant rather than to the
47217
+ * of `nldd-step-indicator`. The size belongs to the lane rather than to the
46603
47218
  * content: every dot in a list is the same size, or the track would jump.
46604
47219
  *
46605
47220
  * @element nldd-timeline-track-cell
46606
- * @attr {'major' | 'minor' | 'none'} variant - What stands in the lane: a whole dot (`major`, the default), a smaller one for a row that belongs under the one above it (`minor`), or nothing at all (`none`) for a row that carries what a step holds rather than being a step. A `none` row keeps its `size` and its `status`, so it stays in the same lane and the track runs on in the right color
47221
+ * @attr {'major' | 'minor' | 'none'} level - What stands in the lane: a whole dot (`major`, the default), a smaller one for a row that belongs under the one above it (`minor`), or nothing at all (`none`) for a row that carries what a step holds rather than being a step. A `none` row keeps its `size` and its `status`, so it stays in the same lane and the track runs on in the right color
46607
47222
  * @attr {'past' | 'current' | 'future'} status - How far along this row is (default 'past'); the same values as `nldd-step-indicator-item`. It colors the dot and the track around it: covered above where you are, still ahead below
46608
47223
  * @attr {'sm' | 'md'} size - How wide the lane is and so how big the dot: `sm` (default, 16px) for a timeline of events, `md` (24px) where a number or an icon has to fit. Every row in one list takes the same size, or the track jumps
46609
47224
  * @attr {'down' | 'up'} direction - The direction the timeline moves forward in: `down` (default) puts the past above, `up` below. Only the current step has half a track, so this only has an effect there
46610
- * @attr {'first' | 'between' | 'last' | 'only'} position - Place in the series (default 'between'): decides whether the line continues above the dot, below it, or on both sides. `only` is the single row in the series and gets a line on neither side: a track of one dot leads nowhere. On a `variant="none"` row, which is nothing but line, `only` leaves it out altogether: the track ends above it
46611
- * @attr {'auto' | 'top' | 'bottom' | 'both' | 'none'} line - Which halves of the track you have covered, when `status` and `direction` get it wrong (default 'auto', which is what those two say). The halves you name are drawn as covered and the other one as still ahead, so `none` covers neither. Which halves are drawn at all stays with `position`, except that naming a half draws it: `line="both"` on a `first` row draws one above too. A row that opens a group of its own is the case for `both`, since the going carries on below it. A `variant="none"` row has one line rather than two halves, and no point where a fill could change over, so there the status colors the whole of it and `line` overrules the whole of it. On a `current` row that leans the way the timeline runs: what belongs to a point usually comes after it, so going `down` the stretch reads as still ahead and going `up` as behind you
47225
+ * @attr {'first' | 'between' | 'last' | 'only'} position - Place in the series (default 'between'): decides whether the line continues above the dot, below it, or on both sides. `only` is the single row in the series and gets a line on neither side: a track of one dot leads nowhere. On a `level="none"` row, which is nothing but line, `only` leaves it out altogether: the track ends above it
47226
+ * @attr {'auto' | 'top' | 'bottom' | 'both' | 'none'} line - Which halves of the track you have covered, when `status` and `direction` get it wrong (default 'auto', which is what those two say). The halves you name are drawn as covered and the other one as still ahead, so `none` covers neither. Which halves are drawn at all stays with `position`, except that naming a half draws it: `line="both"` on a `first` row draws one above too. A row that opens a group of its own is the case for `both`, since the going carries on below it. A `level="none"` row has one line rather than two halves, and no point where a fill could change over, so there the status colors the whole of it and `line` overrules the whole of it. On a `current` row that leans the way the timeline runs: what belongs to a point usually comes after it, so going `down` the stretch reads as still ahead and going `up` as behind you
46612
47227
  * @attr {string} text - Number or short text in the dot
46613
47228
  * @attr {string} icon - Icon name in the dot; wins over `text`
46614
47229
  *
@@ -46618,7 +47233,7 @@ var _NLDDTimelineTrackCell;
46618
47233
  var NLDDTimelineTrackCell = (_NLDDTimelineTrackCell = class NLDDTimelineTrackCell extends VisibilityMixin(LitElement, "cells-container") {
46619
47234
  constructor(..._args) {
46620
47235
  super(..._args);
46621
- this.variant = "major";
47236
+ this.level = "major";
46622
47237
  this.status = "past";
46623
47238
  this.size = "sm";
46624
47239
  this.direction = "down";
@@ -46631,7 +47246,7 @@ var NLDDTimelineTrackCell = (_NLDDTimelineTrackCell = class NLDDTimelineTrackCel
46631
47246
  /** Only a whole dot in a wide lane has room to read a number in: a minor one is
46632
47247
  * smaller still, and would claim to be a step of its own. */
46633
47248
  get showsContent() {
46634
- return this.variant === "major" && this.size === "md";
47249
+ return this.level === "major" && this.size === "md";
46635
47250
  }
46636
47251
  updated(changed) {
46637
47252
  super.updated(changed);
@@ -46643,7 +47258,7 @@ var NLDDTimelineTrackCell = (_NLDDTimelineTrackCell = class NLDDTimelineTrackCel
46643
47258
  __decorate([property({
46644
47259
  reflect: true,
46645
47260
  converter: reflectNonDefault("major")
46646
- })], NLDDTimelineTrackCell.prototype, "variant", void 0);
47261
+ })], NLDDTimelineTrackCell.prototype, "level", void 0);
46647
47262
  __decorate([property({
46648
47263
  reflect: true,
46649
47264
  converter: reflectNonDefault("past")
@@ -46863,19 +47478,10 @@ var NLDDBreadcrumbs = (_NLDDBreadcrumbs = class NLDDBreadcrumbs extends LitEleme
46863
47478
  super(..._args2);
46864
47479
  this.accessibleLabel = "";
46865
47480
  this.translations = {};
46866
- this._mergedTranslations = { ...nlddBreadcrumbsTranslations };
46867
- }
46868
- willUpdate(changed) {
46869
- if (changed.has("translations") || changed.has("accessibleLabel")) {
46870
- this._mergedTranslations = {
46871
- ...nlddBreadcrumbsTranslations,
46872
- ...this.translations
46873
- };
46874
- if (this.accessibleLabel) this._mergedTranslations["components.breadcrumbs.accessible-label"] = this.accessibleLabel;
46875
- }
46876
47481
  }
46877
47482
  _t(key) {
46878
- return this._mergedTranslations[key] ?? "";
47483
+ if (key === "components.breadcrumbs.accessible-label" && this.accessibleLabel) return this.accessibleLabel;
47484
+ return translate(this.translations, nlddBreadcrumbsTranslations, key);
46879
47485
  }
46880
47486
  render() {
46881
47487
  return breadcrumbsTemplate(this);
@@ -48100,6 +48706,8 @@ var topNavigationBarStyles = css`
48100
48706
 
48101
48707
  :host {
48102
48708
  --_logo-width: var(--semantics-brand-ribbon-sm-width);
48709
+ --_logo-offset: 0px;
48710
+ --_logo-background-color: #154273;
48103
48711
  --_wordmark-content-color: light-dark(var(--primitives-color-reference-lintblauw), var(--primitives-color-neutral-1000));
48104
48712
  --_wordmark-max-width: 280px;
48105
48713
  --_max-width: var(--semantics-page-sections-body-max-width);
@@ -48121,6 +48729,8 @@ var topNavigationBarStyles = css`
48121
48729
  /* The ribbon's width, and with it everything measured against the ribbon:
48122
48730
  its own height and the wordmark beside it. Here rather than on :host,
48123
48731
  because a container query cannot measure the container it sits on. */
48732
+ --_logo-height: calc(var(--_logo-width) * 2);
48733
+
48124
48734
  @container (max-width: ${smMax$2}) {
48125
48735
  --_logo-width: var(--semantics-brand-ribbon-sm-width);
48126
48736
  }
@@ -48176,13 +48786,54 @@ var topNavigationBarStyles = css`
48176
48786
  .top-navigation-bar__logo {
48177
48787
  display: flex;
48178
48788
  width: var(--_logo-width);
48179
- height: calc(var(--_logo-width) * 2);
48789
+ height: var(--_logo-height);
48180
48790
  grid-column: 2;
48181
48791
  align-self: start;
48182
48792
  align-items: center;
48183
48793
  justify-content: center;
48184
48794
  }
48185
48795
 
48796
+ @supports (animation-timeline: scroll()) {
48797
+ .top-navigation-bar__logo {
48798
+ position: relative;
48799
+ }
48800
+
48801
+ /* The ribbon carries on above the page, seen when it is pulled down.
48802
+ No z-index: Safari does not paint it above the page with one. */
48803
+ .top-navigation-bar__logo::before {
48804
+ content: '';
48805
+ position: absolute;
48806
+ bottom: calc(100% + var(--_logo-offset));
48807
+ left: 0;
48808
+ width: 100%;
48809
+ height: 100lvh;
48810
+ background-color: var(--_logo-background-color);
48811
+ pointer-events: none;
48812
+ }
48813
+
48814
+ /* Safari only paints above the page while something fixed touches the
48815
+ top edge. This sits behind the logo, gone as soon as the page scrolls. */
48816
+ .top-navigation-bar__logo::after {
48817
+ content: '';
48818
+ position: fixed;
48819
+ top: 0;
48820
+ z-index: -1;
48821
+ width: var(--_logo-width);
48822
+ height: var(--_logo-height);
48823
+ background-color: var(--_logo-background-color);
48824
+ pointer-events: none;
48825
+ animation: top-navigation-bar-ribbon-at-top linear both;
48826
+ animation-timeline: scroll(root);
48827
+ animation-range: 0 1px;
48828
+ }
48829
+ }
48830
+
48831
+ @keyframes top-navigation-bar-ribbon-at-top {
48832
+ to {
48833
+ visibility: hidden;
48834
+ }
48835
+ }
48836
+
48186
48837
  .top-navigation-bar__logo svg {
48187
48838
  width: 100%;
48188
48839
  height: 100%;
@@ -48240,7 +48891,7 @@ var topNavigationBarStyles = css`
48240
48891
  ribbon centred. One unbreakable name would push the ribbon off centre
48241
48892
  and the page past the screen. */
48242
48893
  min-width: 0;
48243
- min-height: calc(var(--_logo-width) * 2);
48894
+ min-height: var(--_logo-height);
48244
48895
  grid-column: 3;
48245
48896
  flex-direction: column;
48246
48897
  color: var(--_wordmark-content-color);
@@ -48251,7 +48902,7 @@ var topNavigationBarStyles = css`
48251
48902
  on the middle of the ribbon rather than 6px below it. */
48252
48903
  @container (max-width: ${smMax$2}) {
48253
48904
  align-self: start;
48254
- min-height: calc(var(--_logo-width) * 2 - var(--primitives-space-12));
48905
+ min-height: calc(var(--_logo-height) - var(--primitives-space-12));
48255
48906
  padding-block-start: var(--primitives-space-12);
48256
48907
  }
48257
48908
  }
@@ -48640,6 +49291,9 @@ var nlddTopNavigationBarTranslations = {
48640
49291
  * @attr {string} back-href - URL of the back button. Without it a click fires the `back-click` event, so the consumer navigates itself.
48641
49292
  * @attr {string} back-text - Text of the back button. The button appears as soon as back-text or back-href is set; without text it falls back to the translation ("Terug").
48642
49293
  * @attr {string} width - Limits the bar content to a max-width so it lines up with the page sections. 'full' fills the entire width, or pass your own CSS length.
49294
+ *
49295
+ * @slot global - The global navigation: an nldd-menu-bar with nldd-menu-bar-item elements. On narrow widths these items move into the menu sheet behind the menu button.
49296
+ * @slot utility - The utility navigation, such as search and language: an nldd-menu-bar with nldd-menu-bar-item elements. Stays in the bar on every width.
48643
49297
  */
48644
49298
  var _NLDDTopNavigationBar;
48645
49299
  var NLDDTopNavigationBar = (_NLDDTopNavigationBar = class NLDDTopNavigationBar extends withTranslations(LitElement, nlddTopNavigationBarTranslations) {
@@ -48664,6 +49318,14 @@ var NLDDTopNavigationBar = (_NLDDTopNavigationBar = class NLDDTopNavigationBar e
48664
49318
  this._compactRAF = null;
48665
49319
  this._setupRAF = null;
48666
49320
  this._appliedMenuBarLabels = /* @__PURE__ */ new WeakMap();
49321
+ this._appliedTexts = null;
49322
+ this._syncLogoOffset = () => {
49323
+ if (window.scrollY > 0) return;
49324
+ const logo = this.shadowRoot?.querySelector(".top-navigation-bar__logo");
49325
+ if (!logo) return;
49326
+ const offset = Math.max(0, Math.round(logo.getBoundingClientRect().top + window.scrollY));
49327
+ this.style.setProperty("--_logo-offset", `${offset}px`);
49328
+ };
48667
49329
  this._handleItemSelect = (event) => {
48668
49330
  const detail = event.detail;
48669
49331
  if (!detail?.item) return;
@@ -48737,9 +49399,20 @@ var NLDDTopNavigationBar = (_NLDDTopNavigationBar = class NLDDTopNavigationBar e
48737
49399
  }
48738
49400
  };
48739
49401
  }
49402
+ /** The texts this bar puts on elements it does not render itself, as one string. */
49403
+ _translatedTexts() {
49404
+ return [
49405
+ this._menuText,
49406
+ this._t("components.top-navigation-bar.menu-sheet-dismiss-action"),
49407
+ this._t("components.top-navigation-bar.global-menu-bar-label"),
49408
+ this._t("components.top-navigation-bar.utility-menu-bar-label")
49409
+ ].join("\n");
49410
+ }
48740
49411
  willUpdate(changed) {
48741
49412
  super.willUpdate(changed);
48742
- if (changed.has("translations")) {
49413
+ const texts = this._translatedTexts();
49414
+ if (texts !== this._appliedTexts) {
49415
+ this._appliedTexts = texts;
48743
49416
  this._globalMenuSheet?.setAttribute("accessible-label", this._menuText);
48744
49417
  this._globalMenuSheetTitleBar?.setAttribute("dismiss-text", this._t("components.top-navigation-bar.menu-sheet-dismiss-action"));
48745
49418
  if (this._sheetStack.length > 0) {
@@ -48794,10 +49467,14 @@ var NLDDTopNavigationBar = (_NLDDTopNavigationBar = class NLDDTopNavigationBar e
48794
49467
  connectedCallback() {
48795
49468
  super.connectedCallback();
48796
49469
  this.addEventListener("select", this._handleItemSelect);
49470
+ window.addEventListener("scroll", this._syncLogoOffset, { passive: true });
49471
+ window.addEventListener("resize", this._syncLogoOffset, { passive: true });
48797
49472
  }
48798
49473
  disconnectedCallback() {
48799
49474
  super.disconnectedCallback();
48800
49475
  this.removeEventListener("select", this._handleItemSelect);
49476
+ window.removeEventListener("scroll", this._syncLogoOffset);
49477
+ window.removeEventListener("resize", this._syncLogoOffset);
48801
49478
  this._cleanupCompactDetection();
48802
49479
  this._globalMenuSheet?.remove();
48803
49480
  this._globalMenuSheet = null;
@@ -48808,6 +49485,7 @@ var NLDDTopNavigationBar = (_NLDDTopNavigationBar = class NLDDTopNavigationBar e
48808
49485
  firstUpdated() {
48809
49486
  this._syncHasGlobalItems();
48810
49487
  this._setupCompactDetection();
49488
+ this._syncLogoOffset();
48811
49489
  }
48812
49490
  _setupCompactDetection() {
48813
49491
  this._cleanupCompactDetection();
@@ -48884,7 +49562,7 @@ var NLDDTopNavigationBar = (_NLDDTopNavigationBar = class NLDDTopNavigationBar e
48884
49562
  page.appendChild(titleBar);
48885
49563
  const section = document.createElement("nldd-simple-section");
48886
49564
  this._globalMenuSheetList = document.createElement("nldd-list");
48887
- this._globalMenuSheetList.setAttribute("variant", "simple");
49565
+ this._globalMenuSheetList.setAttribute("appearance", "simple");
48888
49566
  this._globalMenuSheetList.setAttribute("dividers", "never");
48889
49567
  section.appendChild(this._globalMenuSheetList);
48890
49568
  page.appendChild(section);
@@ -50102,7 +50780,7 @@ function documentTabBarTemplate(component) {
50102
50780
  })}>
50103
50781
  <nldd-icon-button
50104
50782
  text=${component._t("components.document-tab-bar.overflow-action")}
50105
- variant="neutral-tinted"
50783
+ appearance="neutral-tinted"
50106
50784
  icon="ellipsis"
50107
50785
  tooltip-timing="never"
50108
50786
  popup-type="menu"
@@ -51191,7 +51869,7 @@ function paginationTemplate(component) {
51191
51869
  <nldd-icon-button
51192
51870
  icon="chevron-left-small"
51193
51871
  text=${t("components.pagination.previous-action")}
51194
- variant="neutral-tinted"
51872
+ appearance="neutral-tinted"
51195
51873
  no-highlight-border
51196
51874
  ?disabled=${isDisabled || atFirst}
51197
51875
  href=${hasHref && !isDisabled && !atFirst ? component._hrefForPage(component.current - 1) : nothing}
@@ -51240,7 +51918,7 @@ function paginationTemplate(component) {
51240
51918
  <nldd-icon-button
51241
51919
  icon="chevron-right-small"
51242
51920
  text=${t("components.pagination.next-action")}
51243
- variant="neutral-tinted"
51921
+ appearance="neutral-tinted"
51244
51922
  no-highlight-border
51245
51923
  ?disabled=${isDisabled || atLast}
51246
51924
  href=${hasHref && !isDisabled && !atLast ? component._hrefForPage(component.current + 1) : nothing}
@@ -51289,7 +51967,6 @@ var NLDDPagination = (_NLDDPagination = class NLDDPagination extends LitElement
51289
51967
  this.centered = false;
51290
51968
  this.hrefPattern = "";
51291
51969
  this.translations = {};
51292
- this._mergedTranslations = { ...nlddPaginationTranslations };
51293
51970
  this._handleSelectFocus = () => {
51294
51971
  this.toggleAttribute("is-pointer-focus", isPointerMode());
51295
51972
  };
@@ -51304,16 +51981,8 @@ var NLDDPagination = (_NLDDPagination = class NLDDPagination extends LitElement
51304
51981
  this.toggleAttribute("select-expanded", e.newState === "open");
51305
51982
  };
51306
51983
  }
51307
- willUpdate(changed) {
51308
- if (changed.has("translations")) this._mergedTranslations = {
51309
- ...nlddPaginationTranslations,
51310
- ...this.translations
51311
- };
51312
- }
51313
51984
  _t(key, params) {
51314
- let text = this._mergedTranslations[key] ?? key;
51315
- if (params) for (const [k, v] of Object.entries(params)) text = text.replace(`{${k}}`, String(v));
51316
- return text;
51985
+ return translate(this.translations, nlddPaginationTranslations, key, params);
51317
51986
  }
51318
51987
  _getVisiblePages() {
51319
51988
  if (this.total <= 7) return Array.from({ length: this.total }, (_, i) => i + 1);
@@ -51944,7 +52613,7 @@ function bannerTemplate(component) {
51944
52613
  <div class="banner__dismiss-button">
51945
52614
  <nldd-icon-button
51946
52615
  icon="dismiss-small"
51947
- variant="neutral-transparent"
52616
+ appearance="neutral-transparent"
51948
52617
  size=${component.size}
51949
52618
  accessible-label=${component._t("components.banner.dismiss-action")}
51950
52619
  @click=${component._onDismissClick}
@@ -52027,7 +52696,7 @@ var NLDDBanner = (_NLDDBanner = class NLDDBanner extends LitElement {
52027
52696
  this._hasActions = false;
52028
52697
  }
52029
52698
  _t(key) {
52030
- return this.translations[key] ?? nlddBannerTranslations[key];
52699
+ return translate(this.translations, nlddBannerTranslations, key);
52031
52700
  }
52032
52701
  get _resolvedIcon() {
52033
52702
  return this.icon || DEFAULT_ICONS$1[this.variant];
@@ -52343,7 +53012,7 @@ function notificationTemplate(component) {
52343
53012
  <nldd-icon-button
52344
53013
  icon="dismiss-small"
52345
53014
  size="sm"
52346
- variant="neutral-transparent"
53015
+ appearance="neutral-transparent"
52347
53016
  tooltip-timing="never"
52348
53017
  accessible-label=${component._t("components.notification.dismiss-action")}
52349
53018
  @click=${component._handleDismiss}
@@ -53413,7 +54082,7 @@ var progressBarStyles = css`
53413
54082
  :host([size="sm"]) { --_height: var(--components-progress-bar-sm-height); }
53414
54083
  :host([size="lg"]) { --_height: var(--components-progress-bar-lg-height); }
53415
54084
 
53416
- :host([mode="distribution"]) {
54085
+ :host([variant="distribution"]) {
53417
54086
  --_segment-indicator-gap: var(--components-progress-bar-distribution-segment-indicator-gap);
53418
54087
  --_corner-radius: var(--components-progress-bar-distribution-corner-radius);
53419
54088
  }
@@ -53638,16 +54307,16 @@ var progressBarSegmentIndicatorStyles = css`
53638
54307
  }
53639
54308
 
53640
54309
 
53641
- /* ## Rounding per mode
53642
- Progress mode: every segment is its own capsule. Distribution mode:
54310
+ /* ## Rounding per variant
54311
+ Progress variant: every segment is its own capsule. Distribution variant:
53643
54312
  segments use a small radius matching the track's outer corners.
53644
- data-mode is set by the parent. */
54313
+ data-variant is set by the parent. */
53645
54314
 
53646
- :host([data-mode="progress"]) {
54315
+ :host([data-variant="progress"]) {
53647
54316
  border-radius: var(--components-progress-bar-corner-radius);
53648
54317
  }
53649
54318
 
53650
- :host([data-mode="distribution"]) {
54319
+ :host([data-variant="distribution"]) {
53651
54320
  border-radius: var(--components-progress-bar-distribution-corner-radius);
53652
54321
  }
53653
54322
 
@@ -53876,7 +54545,7 @@ var nlddProgressBarTranslations = {
53876
54545
  * storage usage). The consumer provides raw values; the component
53877
54546
  * computes percentages from `max`.
53878
54547
  *
53879
- * Two modes:
54548
+ * Two variants:
53880
54549
  * - `progress` (default): segments sum toward `max`; remaining space
53881
54550
  * is empty track. ARIA reads "X% voltooid".
53882
54551
  * - `distribution`: segments fill the bar; ARIA enumerates segments.
@@ -53886,7 +54555,7 @@ var nlddProgressBarTranslations = {
53886
54555
  *
53887
54556
  * @element nldd-progress-bar
53888
54557
  *
53889
- * @attr {'progress'|'distribution'} mode - Semantics for ARIA and visualization (default: 'progress')
54558
+ * @attr {'progress'|'distribution'} variant - Semantics for ARIA and visualization (default: 'progress')
53890
54559
  * @attr {number} max - Total value (default: 100)
53891
54560
  * @attr {number} value - Single-segment shorthand (ignored when segment children are present)
53892
54561
  * @attr {string} color - Color for the single-segment shorthand (default: 'accent')
@@ -53948,7 +54617,7 @@ NLDDProgressBarSegmentIndicator = __decorate([customElement("nldd-progress-bar-s
53948
54617
  var NLDDProgressBar = (_NLDDProgressBar = class NLDDProgressBar extends LitElement {
53949
54618
  constructor(..._args2) {
53950
54619
  super(..._args2);
53951
- this.mode = "progress";
54620
+ this.variant = "progress";
53952
54621
  this.max = 100;
53953
54622
  this.value = null;
53954
54623
  this.color = "accent";
@@ -53966,7 +54635,7 @@ var NLDDProgressBar = (_NLDDProgressBar = class NLDDProgressBar extends LitEleme
53966
54635
  this._onSlotChangeBound = this._onSlotChange.bind(this);
53967
54636
  }
53968
54637
  _t(key) {
53969
- return this.translations[key] ?? nlddProgressBarTranslations[key];
54638
+ return translate(this.translations, nlddProgressBarTranslations, key);
53970
54639
  }
53971
54640
  /** Returns true when the user has provided segment children. */
53972
54641
  get _hasSegmentIndicators() {
@@ -54005,7 +54674,7 @@ var NLDDProgressBar = (_NLDDProgressBar = class NLDDProgressBar extends LitEleme
54005
54674
  const pct = this.max > 0 ? Math.round(s.value / this.max * 100) : 0;
54006
54675
  return s.name ? `${s.name}: ${pct}%` : `${pct}%`;
54007
54676
  });
54008
- if (this.mode === "distribution") return segmentIndicatorDescriptions.join(", ");
54677
+ if (this.variant === "distribution") return segmentIndicatorDescriptions.join(", ");
54009
54678
  const totalPct = Math.round(this._percentage);
54010
54679
  if (allNamed) return `${segmentIndicatorDescriptions.join(", ")}. ${totalPrefix} ${totalPct}% ${completedSuffix}.`;
54011
54680
  return `${totalPct}% ${completedSuffix}`;
@@ -54113,14 +54782,14 @@ var NLDDProgressBar = (_NLDDProgressBar = class NLDDProgressBar extends LitEleme
54113
54782
  const v = Math.max(0, seg.value);
54114
54783
  if (v <= 0) {
54115
54784
  seg.hidden = true;
54116
- seg.removeAttribute("data-mode");
54785
+ seg.removeAttribute("data-variant");
54117
54786
  seg._autoTooltipText = "";
54118
54787
  continue;
54119
54788
  }
54120
54789
  seg.hidden = false;
54121
54790
  const pct = denominator > 0 ? v / denominator * 100 : 0;
54122
54791
  seg.style.setProperty("--context-progress-bar-segment-indicator-width", `${pct}%`);
54123
- seg.setAttribute("data-mode", this.mode);
54792
+ seg.setAttribute("data-variant", this.variant);
54124
54793
  seg._autoTooltipText = suppressAutoTooltip ? "" : this._formatSegmentIndicatorTooltip(seg);
54125
54794
  seg.toggleAttribute("data-grow", isExiting);
54126
54795
  seg.toggleAttribute("data-shrink", isEntering);
@@ -54133,7 +54802,7 @@ var NLDDProgressBar = (_NLDDProgressBar = class NLDDProgressBar extends LitEleme
54133
54802
  __decorate([property({
54134
54803
  reflect: true,
54135
54804
  converter: reflectNonDefault("progress")
54136
- })], NLDDProgressBar.prototype, "mode", void 0);
54805
+ })], NLDDProgressBar.prototype, "variant", void 0);
54137
54806
  __decorate([property({
54138
54807
  type: Number,
54139
54808
  reflect: true
@@ -54277,16 +54946,16 @@ var progressCircleStyles = css`
54277
54946
  opacity: 0;
54278
54947
  }
54279
54948
 
54280
- /* Progress mode: rounded caps for friendly segment ends. The JS gap
54949
+ /* Progress variant: rounded caps for friendly segment ends. The JS gap
54281
54950
  calculation compensates for the half-stroke-width extension so the
54282
54951
  visible gap between segments stays consistent.
54283
- Distribution mode: butt caps keep the segment boundaries crisp. */
54952
+ Distribution variant: butt caps keep the segment boundaries crisp. */
54284
54953
 
54285
54954
  .progress-circle__segment-indicator {
54286
54955
  stroke-linecap: round;
54287
54956
  }
54288
54957
 
54289
- :host([mode="distribution"]) .progress-circle__segment-indicator {
54958
+ :host([variant="distribution"]) .progress-circle__segment-indicator {
54290
54959
  stroke-linecap: butt;
54291
54960
  }
54292
54961
 
@@ -54701,7 +55370,7 @@ var nlddProgressCircleTranslations = {
54701
55370
  * Exports both NLDDProgressCircle and NLDDProgressCircleSegmentIndicator.
54702
55371
  *
54703
55372
  * A circular progress indicator that mirrors the API of nldd-progress-bar:
54704
- * single-value or multi-segment, progress or distribution mode, 24 colors,
55373
+ * single-value or multi-segment, progress or distribution variant, 24 colors,
54705
55374
  * fade transitions between determinate/indeterminate, indeterminate indicator.
54706
55375
  *
54707
55376
  * Visual differences vs the bar:
@@ -54715,7 +55384,7 @@ var nlddProgressCircleTranslations = {
54715
55384
  *
54716
55385
  * @element nldd-progress-circle
54717
55386
  *
54718
- * @attr {'progress'|'distribution'} mode - Semantics for ARIA and gap behavior (default: 'progress')
55387
+ * @attr {'progress'|'distribution'} variant - Semantics for ARIA and gap behavior (default: 'progress')
54719
55388
  * @attr {number} max - Total value (default: 100)
54720
55389
  * @attr {number} value - Single-segment shorthand (ignored when segment children exist)
54721
55390
  * @attr {string} color - Color. Semantic (neutral, accent, success, warning, critical) or a Rijkskleur. Default 'accent'.
@@ -54728,6 +55397,8 @@ var nlddProgressCircleTranslations = {
54728
55397
  * @attr {boolean} indeterminate - Renders the rotating elastic arc animation
54729
55398
  * @attr {object} translations - Override translation keys; unset keys fall back to Dutch
54730
55399
  *
55400
+ * @slot - Place for nldd-progress-circle-segment-indicator elements
55401
+ *
54731
55402
  * @element nldd-progress-circle-segment-indicator
54732
55403
  *
54733
55404
  * @attr {number} value - Share of the parent's total (default 0; <=0 hides segment)
@@ -54764,7 +55435,7 @@ NLDDProgressCircleSegmentIndicator = __decorate([customElement("nldd-progress-ci
54764
55435
  var NLDDProgressCircle = (_NLDDProgressCircle2 = class NLDDProgressCircle extends LitElement {
54765
55436
  constructor(..._args2) {
54766
55437
  super(..._args2);
54767
- this.mode = "progress";
55438
+ this.variant = "progress";
54768
55439
  this.max = 100;
54769
55440
  this.value = null;
54770
55441
  this.color = "accent";
@@ -54784,7 +55455,7 @@ var NLDDProgressCircle = (_NLDDProgressCircle2 = class NLDDProgressCircle extend
54784
55455
  this._onSlotChangeBound = this._onSlotChange.bind(this);
54785
55456
  }
54786
55457
  _t(key) {
54787
- return this.translations[key] ?? nlddProgressCircleTranslations[key];
55458
+ return translate(this.translations, nlddProgressCircleTranslations, key);
54788
55459
  }
54789
55460
  get _hasSegmentIndicators() {
54790
55461
  return this._segmentIndicators.length > 0;
@@ -54825,7 +55496,7 @@ var NLDDProgressCircle = (_NLDDProgressCircle2 = class NLDDProgressCircle extend
54825
55496
  const valuePart = this._formatValuePart(s.value, pct);
54826
55497
  return s.name ? `${s.name}: ${valuePart}` : valuePart;
54827
55498
  });
54828
- if (this.mode === "distribution") return segmentIndicatorDescriptions.join(", ");
55499
+ if (this.variant === "distribution") return segmentIndicatorDescriptions.join(", ");
54829
55500
  const totalPct = Math.round(this._percentage);
54830
55501
  const totalValuePart = this._formatValuePart(this._totalValue, totalPct);
54831
55502
  if (allNamed) {
@@ -54848,7 +55519,7 @@ var NLDDProgressCircle = (_NLDDProgressCircle2 = class NLDDProgressCircle extend
54848
55519
  const valuePart = this._formatValuePart(s.value, pct);
54849
55520
  return s.name ? `${s.name}: ${valuePart}` : valuePart;
54850
55521
  });
54851
- if (this.mode === "distribution") return segmentIndicatorDescriptions.join(", ");
55522
+ if (this.variant === "distribution") return segmentIndicatorDescriptions.join(", ");
54852
55523
  const totalPct = Math.round(this._percentage);
54853
55524
  if (allNamed) return `${segmentIndicatorDescriptions.join(", ")}. ${totalPrefix} ${totalPct}% ${completedSuffix}.`;
54854
55525
  return `${totalPct}% ${completedSuffix}`;
@@ -54947,9 +55618,9 @@ var NLDDProgressCircle = (_NLDDProgressCircle2 = class NLDDProgressCircle extend
54947
55618
  }] : [];
54948
55619
  const sizeInPixels = Number(this.size) || 28;
54949
55620
  const strokeWidthPx = getStrokeWidthPx(sizeInPixels);
54950
- const isMultiSegmentIndicator = sourceSegmentIndicators.length > 1 || this.mode === "distribution";
54951
- const isProgressMode = this.mode !== "distribution";
54952
- const gapLength = ((isMultiSegmentIndicator ? isProgressMode ? 1 : 2 : 0) + (isProgressMode && isMultiSegmentIndicator ? strokeWidthPx : 0)) * (100 / sizeInPixels);
55621
+ const isMultiSegmentIndicator = sourceSegmentIndicators.length > 1 || this.variant === "distribution";
55622
+ const isProgressVariant = this.variant !== "distribution";
55623
+ const gapLength = ((isMultiSegmentIndicator ? isProgressVariant ? 1 : 2 : 0) + (isProgressVariant && isMultiSegmentIndicator ? strokeWidthPx : 0)) * (100 / sizeInPixels);
54953
55624
  const circumference = getCircumference(sizeInPixels);
54954
55625
  const total = this._totalValue;
54955
55626
  const denominator = total > this.max ? total : this.max;
@@ -54993,7 +55664,7 @@ var NLDDProgressCircle = (_NLDDProgressCircle2 = class NLDDProgressCircle extend
54993
55664
  __decorate([property({
54994
55665
  reflect: true,
54995
55666
  converter: reflectNonDefault("progress")
54996
- })], NLDDProgressCircle.prototype, "mode", void 0);
55667
+ })], NLDDProgressCircle.prototype, "variant", void 0);
54997
55668
  __decorate([property({
54998
55669
  type: Number,
54999
55670
  reflect: true
@@ -56212,7 +56883,7 @@ function justInTimeEducationTemplate(component) {
56212
56883
  <div class="just-in-time-education__dismiss-button">
56213
56884
  <nldd-icon-button
56214
56885
  icon="dismiss"
56215
- variant="neutral-transparent"
56886
+ appearance="neutral-transparent"
56216
56887
  size="md"
56217
56888
  accessible-label=${component._t("components.just-in-time-education.dismiss-action")}
56218
56889
  @click=${component._handleDismiss}
@@ -56705,4 +57376,4 @@ __decorate([property({
56705
57376
  })], NLDDJustInTimeEducation.prototype, "noArrow", void 0);
56706
57377
  NLDDJustInTimeEducation = _NLDDJustInTimeEducation = __decorate([customElement("nldd-just-in-time-education")], NLDDJustInTimeEducation);
56707
57378
  //#endregion
56708
- export { NLDDActivityIndicator, NLDDAppView, NLDDAvatar, NLDDAvatarGroup, NLDDBadge, NLDDBanner, NLDDBarSplitView, NLDDBlockquote, NLDDBox, NLDDBreadcrumbs, NLDDBreadcrumbsItem, NLDDButton, NLDDButtonBar, NLDDButtonGroup, NLDDCard, NLDDCell, NLDDCheckbox, NLDDCheckboxField, NLDDCodeEditor, NLDDCodeViewer, NLDDCollection, NLDDComboBox, NLDDContainer, NLDDDateField, NLDDDatePicker, NLDDDescriptionCell, NLDDDivider, NLDDDocumentTabBar, NLDDDragHandleCell, NLDDDropdown, NLDDFileField, NLDDForm, NLDDFormActions, NLDDFormField, NLDDFormSection, NLDDFullBleedSection, NLDDHero, NLDDIcon, NLDDIconButton, NLDDIconCell, NLDDIdentity, NLDDImage, NLDDInlineDialog, NLDDJustInTimeEducation, NLDDKeyboardShortcut, NLDDLink, NLDDList, NLDDListItem, NLDDListItemSegment, NLDDMenu, NLDDMenuBar, NLDDMenuBarItem, NLDDModalDialog, NLDDMultiLineTextField, NLDDNavigationSplitView, NLDDNotification, NLDDNumberField, NLDDOneHalfOneHalfSection, NLDDOneThirdTwoThirdsSection, NLDDPage, NLDDPageFooter, NLDDPageFooterLegalBar, NLDDPageFooterLegalBarItem, NLDDPagination, NLDDPasswordField, NLDDPopover, NLDDProgressBar, NLDDProgressBarSegmentIndicator, NLDDProgressCircle, NLDDProgressCircleSegmentIndicator, NLDDRadioButton, NLDDRadioButtonField, NLDDRadioButtonGroup, NLDDRichText, NLDDSearchField, NLDDSegmentedControl, NLDDSheet, NLDDSideBySideSplitView, NLDDSidebarSection, NLDDSimpleSection, NLDDSkipLink, NLDDSpacer, NLDDSpacerCell, NLDDSplitButton, NLDDSplitViewDivider, NLDDSplitViewPane, NLDDStackedSplitView, NLDDStatusBar, NLDDStepIndicator, NLDDStepIndicatorItem, NLDDStepper, NLDDSwitch, NLDDSwitchField, NLDDTabBar, NLDDTable, NLDDTableRow, NLDDTag, NLDDText, NLDDTextCell, NLDDTextEditor, NLDDTextField, NLDDTimeField, NLDDTimePicker, NLDDTimelineTrackCell, NLDDTitle, NLDDTitleCell, NLDDToggleButton, NLDDToggleButtonGroup, NLDDToken, NLDDTokenField, NLDDToolbar, NLDDTooltip, NLDDTopNavigationBar, NLDDTopTitleBar, NLDDTwoThirdsOneThirdSection, NLDDValidationList, NLDDWindow };
57379
+ export { NLDDActivityIndicator, NLDDAppView, NLDDAvatar, NLDDAvatarGroup, NLDDBadge, NLDDBanner, NLDDBarSplitView, NLDDBlockquote, NLDDBox, NLDDBreadcrumbs, NLDDBreadcrumbsItem, NLDDButton, NLDDButtonBar, NLDDButtonGroup, NLDDCard, NLDDCell, NLDDCheckbox, NLDDCheckboxField, NLDDCodeEditor, NLDDCodeViewer, NLDDCollection, NLDDComboBox, NLDDContainer, NLDDDateField, NLDDDatePicker, NLDDDescriptionCell, NLDDDivider, NLDDDocumentTabBar, NLDDDragHandleCell, NLDDDropdown, NLDDFileField, NLDDForm, NLDDFormActions, NLDDFormField, NLDDFormSection, NLDDFullBleedSection, NLDDHero, NLDDIcon, NLDDIconButton, NLDDIconCell, NLDDIdentity, NLDDImage, NLDDInlineDialog, NLDDJustInTimeEducation, NLDDKeyboardShortcut, NLDDLink, NLDDList, NLDDListItem, NLDDListItemSegment, NLDDMenu, NLDDMenuBar, NLDDMenuBarItem, NLDDModalDialog, NLDDMultiLineTextField, NLDDNavigationSplitView, NLDDNotification, NLDDNumberField, NLDDOneHalfOneHalfSection, NLDDOneThirdTwoThirdsSection, NLDDPage, NLDDPageFooter, NLDDPageFooterLegalBar, NLDDPageFooterLegalBarItem, NLDDPagination, NLDDPasswordField, NLDDPopover, NLDDProgressBar, NLDDProgressBarSegmentIndicator, NLDDProgressCircle, NLDDProgressCircleSegmentIndicator, NLDDRadioButton, NLDDRadioButtonField, NLDDRadioButtonGroup, NLDDRichText, NLDDSearchField, NLDDSegmentedControl, NLDDSheet, NLDDSideBySideSplitView, NLDDSidebarSection, NLDDSimpleSection, NLDDSkipLink, NLDDSpacer, NLDDSpacerCell, NLDDSplitButton, NLDDSplitViewDivider, NLDDSplitViewPane, NLDDStackedSplitView, NLDDStatusBar, NLDDStepIndicator, NLDDStepIndicatorItem, NLDDStepper, NLDDSwitch, NLDDSwitchField, NLDDTabBar, NLDDTable, NLDDTableRow, NLDDTag, NLDDText, NLDDTextCell, NLDDTextEditor, NLDDTextField, NLDDTimeField, NLDDTimePicker, NLDDTimelineTrackCell, NLDDTitle, NLDDTitleCell, NLDDToggleButton, NLDDToggleButtonGroup, NLDDToken, NLDDTokenField, NLDDToolbar, NLDDTooltip, NLDDTopNavigationBar, NLDDTopTitleBar, NLDDTwoThirdsOneThirdSection, NLDDValidationList, NLDDWindow, setTranslations };