@nldd/design-system 0.10.0 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (267) hide show
  1. package/custom-elements.json +3084 -784
  2. package/dist/components/actions/button/button.d.ts +10 -0
  3. package/dist/components/actions/button/button.d.ts.map +1 -1
  4. package/dist/components/actions/button/button.js +23 -0
  5. package/dist/components/actions/button/button.js.map +1 -1
  6. package/dist/components/actions/button/button.styles.d.ts.map +1 -1
  7. package/dist/components/actions/button/button.styles.js +22 -0
  8. package/dist/components/actions/button/button.styles.js.map +1 -1
  9. package/dist/components/actions/button/button.template.d.ts +1 -0
  10. package/dist/components/actions/button/button.template.d.ts.map +1 -1
  11. package/dist/components/actions/button/button.template.js +20 -2
  12. package/dist/components/actions/button/button.template.js.map +1 -1
  13. package/dist/components/actions/icon-button/icon-button.d.ts +10 -0
  14. package/dist/components/actions/icon-button/icon-button.d.ts.map +1 -1
  15. package/dist/components/actions/icon-button/icon-button.js +23 -0
  16. package/dist/components/actions/icon-button/icon-button.js.map +1 -1
  17. package/dist/components/actions/icon-button/icon-button.template.d.ts.map +1 -1
  18. package/dist/components/actions/icon-button/icon-button.template.js +10 -3
  19. package/dist/components/actions/icon-button/icon-button.template.js.map +1 -1
  20. package/dist/components/actions/menu/menu.styles.js +1 -1
  21. package/dist/components/actions/split-button/split-button.d.ts +8 -0
  22. package/dist/components/actions/split-button/split-button.d.ts.map +1 -1
  23. package/dist/components/actions/split-button/split-button.js +20 -0
  24. package/dist/components/actions/split-button/split-button.js.map +1 -1
  25. package/dist/components/actions/split-button/split-button.template.d.ts.map +1 -1
  26. package/dist/components/actions/split-button/split-button.template.js +4 -0
  27. package/dist/components/actions/split-button/split-button.template.js.map +1 -1
  28. package/dist/components/components.js +2857 -1993
  29. package/dist/components/content/code-viewer/code-viewer.d.ts +14 -1
  30. package/dist/components/content/code-viewer/code-viewer.d.ts.map +1 -1
  31. package/dist/components/content/code-viewer/code-viewer.diff.d.ts +40 -0
  32. package/dist/components/content/code-viewer/code-viewer.diff.d.ts.map +1 -0
  33. package/dist/components/content/code-viewer/code-viewer.diff.js +261 -0
  34. package/dist/components/content/code-viewer/code-viewer.diff.js.map +1 -0
  35. package/dist/components/content/code-viewer/code-viewer.i18n.d.ts +5 -0
  36. package/dist/components/content/code-viewer/code-viewer.i18n.d.ts.map +1 -1
  37. package/dist/components/content/code-viewer/code-viewer.i18n.js +9 -0
  38. package/dist/components/content/code-viewer/code-viewer.i18n.js.map +1 -1
  39. package/dist/components/content/code-viewer/code-viewer.js +98 -6
  40. package/dist/components/content/code-viewer/code-viewer.js.map +1 -1
  41. package/dist/components/content/code-viewer/code-viewer.styles.d.ts.map +1 -1
  42. package/dist/components/content/code-viewer/code-viewer.styles.js +134 -1
  43. package/dist/components/content/code-viewer/code-viewer.styles.js.map +1 -1
  44. package/dist/components/content/code-viewer/code-viewer.template.d.ts.map +1 -1
  45. package/dist/components/content/code-viewer/code-viewer.template.js +5 -4
  46. package/dist/components/content/code-viewer/code-viewer.template.js.map +1 -1
  47. package/dist/components/content/icon/icon-aliases.d.ts.map +1 -1
  48. package/dist/components/content/icon/icon-aliases.js +13 -4
  49. package/dist/components/content/icon/icon-aliases.js.map +1 -1
  50. package/dist/components/content/icon/icon-gallery-status.d.ts.map +1 -1
  51. package/dist/components/content/icon/icon-gallery-status.js +9 -0
  52. package/dist/components/content/icon/icon-gallery-status.js.map +1 -1
  53. package/dist/components/content/icon/icon-registry.d.ts.map +1 -1
  54. package/dist/components/content/icon/icon-registry.js +9 -2
  55. package/dist/components/content/icon/icon-registry.js.map +1 -1
  56. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.d.ts +3 -3
  57. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.d.ts.map +1 -1
  58. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.js +6 -21
  59. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.js.map +1 -1
  60. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.styles.d.ts.map +1 -1
  61. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.styles.js +3 -0
  62. package/dist/components/content/keyboard-shortcut/keyboard-shortcut.styles.js.map +1 -1
  63. package/dist/components/content/rich-text/rich-text.d.ts +10 -0
  64. package/dist/components/content/rich-text/rich-text.d.ts.map +1 -1
  65. package/dist/components/content/rich-text/rich-text.js +10 -0
  66. package/dist/components/content/rich-text/rich-text.js.map +1 -1
  67. package/dist/components/content/tooltip/tooltip.d.ts +14 -0
  68. package/dist/components/content/tooltip/tooltip.d.ts.map +1 -1
  69. package/dist/components/content/tooltip/tooltip.js +45 -6
  70. package/dist/components/content/tooltip/tooltip.js.map +1 -1
  71. package/dist/components/content/tooltip/tooltip.styles.d.ts.map +1 -1
  72. package/dist/components/content/tooltip/tooltip.styles.js +13 -0
  73. package/dist/components/content/tooltip/tooltip.styles.js.map +1 -1
  74. package/dist/components/content/tooltip/tooltip.template.d.ts.map +1 -1
  75. package/dist/components/content/tooltip/tooltip.template.js +18 -2
  76. package/dist/components/content/tooltip/tooltip.template.js.map +1 -1
  77. package/dist/components/{dist-Bo5Jeyfn.js → dist-B5E3q-ea.js} +2 -1
  78. package/dist/components/{dist-DbNhCpS5.js → dist-BFw_yEMS.js} +2 -1
  79. package/dist/components/{dist-DnZmcpbQ.js → dist-BNLAXAyO.js} +2 -1
  80. package/dist/components/{dist-DkqAbJH8.js → dist-BOVSVPSz.js} +1 -1
  81. package/dist/components/{dist-Ch3gNAuT.js → dist-BPB3rWnd.js} +2 -1
  82. package/dist/components/{dist-Bud_7w5g.js → dist-BWlUmyq3.js} +34 -2869
  83. package/dist/components/dist-CC8oiVtm.js +366 -0
  84. package/dist/components/dist-COKR0tYU.js +2860 -0
  85. package/dist/components/{dist-CaxHkqR2.js → dist-Co-tsc9S.js} +4 -3
  86. package/dist/components/{dist-iC2RTM0V.js → dist-D_9ZyZ5v.js} +3 -2
  87. package/dist/components/{dist-BB5mlo7D.js → dist-Dn9pjiud.js} +3 -2
  88. package/dist/components/{dist-B2QcygzG.js → dist-Dz28se9B.js} +2 -1
  89. package/dist/components/{dist-CA0yDFIt.js → dist-IPm8ilWf.js} +3 -2
  90. package/dist/components/{icon-D_ZGezHx.js → icon-DFhgRf3P.js} +19 -7
  91. package/dist/components/{icon-button-BVhiOwX9.js → icon-button-Sxkh5cVr.js} +526 -61
  92. package/dist/components/inputs/code-editor/code-editor.d.ts +4 -54
  93. package/dist/components/inputs/code-editor/code-editor.d.ts.map +1 -1
  94. package/dist/components/inputs/code-editor/code-editor.js +22 -262
  95. package/dist/components/inputs/code-editor/code-editor.js.map +1 -1
  96. package/dist/components/inputs/code-editor/code-editor.styles.d.ts.map +1 -1
  97. package/dist/components/inputs/code-editor/code-editor.styles.js +9 -1
  98. package/dist/components/inputs/code-editor/code-editor.styles.js.map +1 -1
  99. package/dist/components/inputs/date-picker/date-picker.styles.d.ts.map +1 -1
  100. package/dist/components/inputs/date-picker/date-picker.styles.js +29 -5
  101. package/dist/components/inputs/date-picker/date-picker.styles.js.map +1 -1
  102. package/dist/components/inputs/search-field/search-field.d.ts +11 -0
  103. package/dist/components/inputs/search-field/search-field.d.ts.map +1 -1
  104. package/dist/components/inputs/search-field/search-field.js +30 -1
  105. package/dist/components/inputs/search-field/search-field.js.map +1 -1
  106. package/dist/components/inputs/search-field/search-field.styles.d.ts.map +1 -1
  107. package/dist/components/inputs/search-field/search-field.styles.js +18 -0
  108. package/dist/components/inputs/search-field/search-field.styles.js.map +1 -1
  109. package/dist/components/inputs/search-field/search-field.template.d.ts.map +1 -1
  110. package/dist/components/inputs/search-field/search-field.template.js +12 -0
  111. package/dist/components/inputs/search-field/search-field.template.js.map +1 -1
  112. package/dist/components/inputs/segmented-control/segmented-control.d.ts +10 -0
  113. package/dist/components/inputs/segmented-control/segmented-control.d.ts.map +1 -1
  114. package/dist/components/inputs/segmented-control/segmented-control.js +25 -1
  115. package/dist/components/inputs/segmented-control/segmented-control.js.map +1 -1
  116. package/dist/components/inputs/segmented-control/segmented-control.template.d.ts.map +1 -1
  117. package/dist/components/inputs/segmented-control/segmented-control.template.js +20 -3
  118. package/dist/components/inputs/segmented-control/segmented-control.template.js.map +1 -1
  119. package/dist/components/inputs/text-editor/text-editor.annotation-sentinels.d.ts.map +1 -1
  120. package/dist/components/inputs/text-editor/text-editor.annotation-sentinels.js +9 -7
  121. package/dist/components/inputs/text-editor/text-editor.annotation-sentinels.js.map +1 -1
  122. package/dist/components/inputs/text-editor/text-editor.annotations.js +1 -1
  123. package/dist/components/inputs/text-editor/text-editor.annotations.js.map +1 -1
  124. package/dist/components/inputs/text-editor/text-editor.clipboard.d.ts +16 -0
  125. package/dist/components/inputs/text-editor/text-editor.clipboard.d.ts.map +1 -0
  126. package/dist/components/inputs/text-editor/text-editor.clipboard.js +50 -0
  127. package/dist/components/inputs/text-editor/text-editor.clipboard.js.map +1 -0
  128. package/dist/components/inputs/text-editor/text-editor.commands.d.ts.map +1 -1
  129. package/dist/components/inputs/text-editor/text-editor.commands.js +31 -58
  130. package/dist/components/inputs/text-editor/text-editor.commands.js.map +1 -1
  131. package/dist/components/inputs/text-editor/text-editor.d.ts +17 -64
  132. package/dist/components/inputs/text-editor/text-editor.d.ts.map +1 -1
  133. package/dist/components/inputs/text-editor/text-editor.drag.d.ts.map +1 -1
  134. package/dist/components/inputs/text-editor/text-editor.drag.js +2 -1
  135. package/dist/components/inputs/text-editor/text-editor.drag.js.map +1 -1
  136. package/dist/components/inputs/text-editor/text-editor.focus-selection.d.ts +3 -0
  137. package/dist/components/inputs/text-editor/text-editor.focus-selection.d.ts.map +1 -0
  138. package/dist/components/inputs/text-editor/text-editor.focus-selection.js +55 -0
  139. package/dist/components/inputs/text-editor/text-editor.focus-selection.js.map +1 -0
  140. package/dist/components/inputs/text-editor/text-editor.hidden-syntax.d.ts +6 -0
  141. package/dist/components/inputs/text-editor/text-editor.hidden-syntax.d.ts.map +1 -0
  142. package/dist/components/inputs/text-editor/text-editor.hidden-syntax.js +257 -0
  143. package/dist/components/inputs/text-editor/text-editor.hidden-syntax.js.map +1 -0
  144. package/dist/components/inputs/text-editor/text-editor.js +93 -313
  145. package/dist/components/inputs/text-editor/text-editor.js.map +1 -1
  146. package/dist/components/inputs/text-editor/text-editor.keymap.d.ts +6 -0
  147. package/dist/components/inputs/text-editor/text-editor.keymap.d.ts.map +1 -0
  148. package/dist/components/inputs/text-editor/text-editor.keymap.js +38 -0
  149. package/dist/components/inputs/text-editor/text-editor.keymap.js.map +1 -0
  150. package/dist/components/inputs/text-editor/text-editor.links.d.ts.map +1 -1
  151. package/dist/components/inputs/text-editor/text-editor.links.js +11 -9
  152. package/dist/components/inputs/text-editor/text-editor.links.js.map +1 -1
  153. package/dist/components/inputs/text-editor/text-editor.markdown.d.ts +1 -17
  154. package/dist/components/inputs/text-editor/text-editor.markdown.d.ts.map +1 -1
  155. package/dist/components/inputs/text-editor/text-editor.markdown.js +26 -186
  156. package/dist/components/inputs/text-editor/text-editor.markdown.js.map +1 -1
  157. package/dist/components/inputs/text-editor/text-editor.mention.d.ts +52 -0
  158. package/dist/components/inputs/text-editor/text-editor.mention.d.ts.map +1 -0
  159. package/dist/components/inputs/text-editor/text-editor.mention.js +186 -0
  160. package/dist/components/inputs/text-editor/text-editor.mention.js.map +1 -0
  161. package/dist/components/inputs/text-editor/text-editor.mentions.d.ts +0 -16
  162. package/dist/components/inputs/text-editor/text-editor.mentions.d.ts.map +1 -1
  163. package/dist/components/inputs/text-editor/text-editor.mentions.js +1 -41
  164. package/dist/components/inputs/text-editor/text-editor.mentions.js.map +1 -1
  165. package/dist/components/inputs/text-editor/text-editor.selection.d.ts +13 -0
  166. package/dist/components/inputs/text-editor/text-editor.selection.d.ts.map +1 -0
  167. package/dist/components/inputs/text-editor/text-editor.selection.js +62 -0
  168. package/dist/components/inputs/text-editor/text-editor.selection.js.map +1 -0
  169. package/dist/components/inputs/text-editor/text-editor.spellcheck.d.ts.map +1 -1
  170. package/dist/components/inputs/text-editor/text-editor.spellcheck.js +4 -6
  171. package/dist/components/inputs/text-editor/text-editor.spellcheck.js.map +1 -1
  172. package/dist/components/inputs/text-editor/text-editor.styles.d.ts.map +1 -1
  173. package/dist/components/inputs/text-editor/text-editor.styles.js +185 -64
  174. package/dist/components/inputs/text-editor/text-editor.styles.js.map +1 -1
  175. package/dist/components/inputs/text-editor/text-editor.syntax.d.ts +22 -0
  176. package/dist/components/inputs/text-editor/text-editor.syntax.d.ts.map +1 -1
  177. package/dist/components/inputs/text-editor/text-editor.syntax.js +44 -0
  178. package/dist/components/inputs/text-editor/text-editor.syntax.js.map +1 -1
  179. package/dist/components/inputs/toggle-button/toggle-button.d.ts +10 -0
  180. package/dist/components/inputs/toggle-button/toggle-button.d.ts.map +1 -1
  181. package/dist/components/inputs/toggle-button/toggle-button.js +25 -1
  182. package/dist/components/inputs/toggle-button/toggle-button.js.map +1 -1
  183. package/dist/components/inputs/toggle-button/toggle-button.template.d.ts.map +1 -1
  184. package/dist/components/inputs/toggle-button/toggle-button.template.js +21 -7
  185. package/dist/components/inputs/toggle-button/toggle-button.template.js.map +1 -1
  186. package/dist/components/layout/card/card.styles.js +4 -4
  187. package/dist/components/layout/container/container.d.ts +2 -0
  188. package/dist/components/layout/container/container.d.ts.map +1 -1
  189. package/dist/components/layout/container/container.js +9 -0
  190. package/dist/components/layout/container/container.js.map +1 -1
  191. package/dist/components/layout/container/container.styles.d.ts.map +1 -1
  192. package/dist/components/layout/container/container.styles.js +13 -0
  193. package/dist/components/layout/container/container.styles.js.map +1 -1
  194. package/dist/components/lists-and-tables/cells/step-cell/step-cell.styles.d.ts.map +1 -1
  195. package/dist/components/lists-and-tables/cells/step-cell/step-cell.styles.js +9 -5
  196. package/dist/components/lists-and-tables/cells/step-cell/step-cell.styles.js.map +1 -1
  197. package/dist/components/navigation/document-tab-bar/document-tab-bar.styles.d.ts.map +1 -1
  198. package/dist/components/navigation/document-tab-bar/document-tab-bar.styles.js +16 -15
  199. package/dist/components/navigation/document-tab-bar/document-tab-bar.styles.js.map +1 -1
  200. package/dist/components/navigation/menu-bar-item/menu-bar-item.styles.js +2 -2
  201. package/dist/components/navigation/tab-bar/tab-bar.styles.js +9 -9
  202. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.d.ts +16 -9
  203. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.d.ts.map +1 -1
  204. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.js +16 -9
  205. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.js.map +1 -1
  206. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.styles.d.ts.map +1 -1
  207. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.styles.js +23 -18
  208. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.styles.js.map +1 -1
  209. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.template.d.ts.map +1 -1
  210. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.template.js +19 -21
  211. package/dist/components/status-and-feedback/activity-indicator/activity-indicator.template.js.map +1 -1
  212. package/dist/components/status-and-feedback/inline-dialog/inline-dialog.styles.js +1 -1
  213. package/dist/components/status-and-feedback/notification/notification.d.ts +2 -1
  214. package/dist/components/status-and-feedback/notification/notification.d.ts.map +1 -1
  215. package/dist/components/status-and-feedback/notification/notification.js +5 -2
  216. package/dist/components/status-and-feedback/notification/notification.js.map +1 -1
  217. package/dist/components/status-and-feedback/notification/notification.styles.d.ts.map +1 -1
  218. package/dist/components/status-and-feedback/notification/notification.styles.js +19 -1
  219. package/dist/components/status-and-feedback/notification/notification.styles.js.map +1 -1
  220. package/dist/components/status-and-feedback/notification/notifications-area.d.ts.map +1 -1
  221. package/dist/components/status-and-feedback/notification/notifications-area.js +14 -0
  222. package/dist/components/status-and-feedback/notification/notifications-area.js.map +1 -1
  223. package/dist/components/status-and-feedback/progress-bar/progress-bar.styles.js +4 -4
  224. package/dist/components/status-and-feedback/progress-circle/progress-circle.styles.js +3 -3
  225. package/dist/components/status-and-feedback/progress-circle/progress-circle.template.js +1 -1
  226. package/dist/components/status-and-feedback/progress-circle/progress-circle.template.js.map +1 -1
  227. package/dist/components/status-and-feedback/step-bar/step-bar.styles.d.ts.map +1 -1
  228. package/dist/components/status-and-feedback/step-bar/step-bar.styles.js +7 -5
  229. package/dist/components/status-and-feedback/step-bar/step-bar.styles.js.map +1 -1
  230. package/dist/css/rich-text.css +61 -1
  231. package/dist/css/themes/bruin.css +108 -64
  232. package/dist/css/themes/donkerblauw.css +108 -64
  233. package/dist/css/themes/donkerbruin.css +88 -64
  234. package/dist/css/themes/donkergeel.css +149 -94
  235. package/dist/css/themes/donkergroen.css +93 -64
  236. package/dist/css/themes/geel.css +149 -94
  237. package/dist/css/themes/groen.css +108 -64
  238. package/dist/css/themes/hemelblauw.css +108 -64
  239. package/dist/css/themes/lichtblauw.css +111 -64
  240. package/dist/css/themes/mintgroen.css +111 -64
  241. package/dist/css/themes/mosgroen.css +108 -64
  242. package/dist/css/themes/oranje.css +162 -99
  243. package/dist/css/themes/paars.css +115 -64
  244. package/dist/css/themes/robijnrood.css +159 -96
  245. package/dist/css/themes/rood.css +159 -96
  246. package/dist/css/themes/roze.css +118 -64
  247. package/dist/css/themes/violet.css +93 -64
  248. package/dist/css/themes.css +2047 -1247
  249. package/dist/css/variables.css +142 -70
  250. package/dist/nldd.min.js +1468 -998
  251. package/dist/translations/en-US.d.ts.map +1 -1
  252. package/dist/translations/en-US.js +5 -0
  253. package/dist/translations/en-US.js.map +1 -1
  254. package/dist/translations/nl.generated.d.ts +5 -0
  255. package/dist/translations/nl.generated.d.ts.map +1 -1
  256. package/dist/types/vue.d.ts +138 -32
  257. package/dist/utilities/codemirror/codemirror-input.d.ts +90 -0
  258. package/dist/utilities/codemirror/codemirror-input.d.ts.map +1 -0
  259. package/dist/utilities/codemirror/codemirror-input.js +250 -0
  260. package/dist/utilities/codemirror/codemirror-input.js.map +1 -0
  261. package/dist/utilities/codemirror/theme.js +1 -1
  262. package/dist/utilities/codemirror/theme.js.map +1 -1
  263. package/dist/utilities/shortcut.d.ts +50 -0
  264. package/dist/utilities/shortcut.d.ts.map +1 -0
  265. package/dist/utilities/shortcut.js +77 -0
  266. package/dist/utilities/shortcut.js.map +1 -0
  267. package/package.json +2 -1
@@ -0,0 +1,250 @@
1
+ var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
2
+ var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
3
+ if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
4
+ else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
5
+ return c > 3 && r && Object.defineProperty(target, key, r), r;
6
+ };
7
+ import { LitElement } from 'lit';
8
+ import { property } from 'lit/decorators.js';
9
+ import { EditorView, placeholder as cmPlaceholder } from '@codemirror/view';
10
+ import { Compartment, EditorState } from '@codemirror/state';
11
+ import { FormAssociated } from '../form-associated-mixin.js';
12
+ import { reflectNonDefault } from '../reflect-non-default.js';
13
+ import { DescribedBy } from '../described-by-mixin.js';
14
+ import { NLDDCodeMirrorElement } from './codemirror-element.js';
15
+ /**
16
+ * Shared base for the CodeMirror editors that are form controls
17
+ * (nldd-code-editor, nldd-text-editor). nldd-code-viewer is not one, so this
18
+ * sits between NLDDCodeMirrorElement and the two editors.
19
+ *
20
+ * It owns what a form control needs and both editors did the same way: the
21
+ * value and its `input`/`change` events, editable and read-only, the
22
+ * placeholder, the textbox attributes (label, id, aria-readonly,
23
+ * aria-required), form association and reset, a press on the padding that
24
+ * starts editing, and the warning for a missing label. A subclass adds its own
25
+ * extensions after `inputExtensions()` and can shape three things:
26
+ * `docToValue()`, `contentAttributes()` and `beforeChangeCheck()`.
27
+ */
28
+ export class NLDDCodeMirrorInput extends DescribedBy(FormAssociated(NLDDCodeMirrorElement)) {
29
+ constructor() {
30
+ super(...arguments);
31
+ this.value = '';
32
+ this.inputId = '';
33
+ this.placeholder = '';
34
+ this.disabled = false;
35
+ this.name = '';
36
+ this.readonly = false;
37
+ this.required = false;
38
+ this.rows = 6;
39
+ this.accessibleLabel = '';
40
+ /**
41
+ * Marks the control as invalid.
42
+ *
43
+ * Announced and not drawn. What is wrong belongs in an
44
+ * nldd-validation-list, in words: a red ring around a single
45
+ * checkbox or radio would say the option is wrong, while it is the question
46
+ * that is unanswered. `aria-invalid` still goes on the control, because
47
+ * choosing not to show something is not a reason to keep quiet about it.
48
+ */
49
+ this.invalid = false;
50
+ this._initialValue = '';
51
+ this._valueAtFocus = '';
52
+ this._accessibleLabelWarned = false;
53
+ this._editableCompartment = new Compartment();
54
+ this._placeholderCompartment = new Compartment();
55
+ this._attrsCompartment = new Compartment();
56
+ this._onScrollerPointerDown = (event) => {
57
+ // Only the scroller's own padding, not the content or a gutter inside it.
58
+ if (event.target !== this.view?.scrollDOM)
59
+ return;
60
+ this.focusFromPoint(event.clientX, event.clientY);
61
+ event.preventDefault();
62
+ };
63
+ }
64
+ /** The value for a document. Default: the document itself. */
65
+ docToValue(doc) {
66
+ return doc;
67
+ }
68
+ /** Attributes of the content element beyond label, id, aria-readonly and
69
+ * aria-required. Default: none. */
70
+ contentAttributes() {
71
+ return {};
72
+ }
73
+ /** Runs on blur, before the value is compared with the one at focus, so a
74
+ * subclass can settle the document first. Default: nothing. */
75
+ beforeChangeCheck(_view) { }
76
+ /** The extensions every input needs. A subclass puts these in its own
77
+ * `buildExtensions()`, next to what is its own. */
78
+ inputExtensions() {
79
+ return [
80
+ this._placeholderCompartment.of(this._placeholderExtension()),
81
+ this._editableCompartment.of(this._editableExtension()),
82
+ this._attrsCompartment.of(this._attrsExtension()),
83
+ EditorView.updateListener.of((u) => {
84
+ if (u.docChanged)
85
+ this._onDocChanged();
86
+ }),
87
+ EditorView.domEventHandlers({
88
+ focus: () => {
89
+ this._valueAtFocus = this.value;
90
+ },
91
+ blur: (_event, view) => {
92
+ this.beforeChangeCheck(view);
93
+ if (this.value !== this._valueAtFocus)
94
+ this._emitChange();
95
+ },
96
+ }),
97
+ ];
98
+ }
99
+ _editableExtension() {
100
+ // Readonly stays focusable and selectable (read and copy); disabled is inert.
101
+ return [EditorView.editable.of(!this.disabled), EditorState.readOnly.of(this.disabled || this.readonly)];
102
+ }
103
+ _placeholderExtension() {
104
+ return this.placeholder ? cmPlaceholder(this.placeholder) : [];
105
+ }
106
+ _attrsExtension() {
107
+ const attrs = { ...this.contentAttributes() };
108
+ if (this.accessibleLabel)
109
+ attrs['aria-label'] = this.accessibleLabel;
110
+ if (this.inputId)
111
+ attrs['id'] = this.inputId;
112
+ // Not editable either way, so it is read-only to assistive tech (WCAG 4.1.2).
113
+ if (this.readonly || this.disabled)
114
+ attrs['aria-readonly'] = 'true';
115
+ if (this.required)
116
+ attrs['aria-required'] = 'true';
117
+ return EditorView.contentAttributes.of(attrs);
118
+ }
119
+ /** Build the textbox attributes again, after something `contentAttributes()`
120
+ * reads has changed. */
121
+ refreshContentAttributes() {
122
+ this.reconfigure(this._attrsCompartment, this._attrsExtension());
123
+ }
124
+ firstUpdated() {
125
+ this._initialValue = this.value;
126
+ this.style.setProperty(this.rowsProperty, String(this.rows));
127
+ this.mountEditor(this.docToValue(this.value));
128
+ this.onEditorMounted();
129
+ }
130
+ /* Runs on the initial mount and on every re-mount after a detach/reattach
131
+ * (e.g. Vue <KeepAlive>): the view and its scroller are rebuilt, so the
132
+ * padding forwarder goes on again. A subclass calls super first. */
133
+ onEditorMounted() {
134
+ // A press on the scroller's own padding (outside .cm-content) doesn't place
135
+ // a caret; forward it to the nearest line so the padding is clickable too.
136
+ this.view?.scrollDOM.addEventListener('pointerdown', this._onScrollerPointerDown);
137
+ this.commitFormValue();
138
+ this._checkAccessibleLabel();
139
+ }
140
+ updated(changed) {
141
+ if (changed.has('rows')) {
142
+ this.style.setProperty(this.rowsProperty, String(this.rows));
143
+ }
144
+ if (this.view) {
145
+ if (changed.has('value')) {
146
+ // Only an outside change goes into the document: the echo of the user's
147
+ // own typing already matches it. Such a change while focused must not look
148
+ // like an edit on the next blur, so the baseline moves along.
149
+ if (this.docToValue(this.doc) !== this.value) {
150
+ this.setDoc(this.docToValue(this.value));
151
+ this._valueAtFocus = this.value;
152
+ }
153
+ this.commitFormValue();
154
+ }
155
+ if (changed.has('disabled') || changed.has('readonly')) {
156
+ this.reconfigure(this._editableCompartment, this._editableExtension());
157
+ }
158
+ if (changed.has('placeholder')) {
159
+ this.reconfigure(this._placeholderCompartment, this._placeholderExtension());
160
+ }
161
+ if (['accessibleLabel', 'inputId', 'disabled', 'readonly', 'required'].some((name) => changed.has(name))) {
162
+ this.refreshContentAttributes();
163
+ }
164
+ }
165
+ this._checkAccessibleLabel();
166
+ }
167
+ _onDocChanged() {
168
+ const text = this.docToValue(this.doc);
169
+ if (text === this.value)
170
+ return;
171
+ this.value = text;
172
+ this.commitFormValue();
173
+ this.dispatchEvent(new CustomEvent('input', {
174
+ detail: { value: text },
175
+ bubbles: true,
176
+ composed: true,
177
+ }));
178
+ }
179
+ _emitChange() {
180
+ this.commitFormValue();
181
+ this.dispatchEvent(new CustomEvent('change', {
182
+ detail: { value: this.value },
183
+ bubbles: true,
184
+ composed: true,
185
+ }));
186
+ }
187
+ /* From updated(), not firstUpdated(): a parent nldd-form-field sets input-id
188
+ * slightly after the first render, so an earlier check would warn for the
189
+ * standard form-field usage. It warns once if the label is still missing. */
190
+ _checkAccessibleLabel() {
191
+ if (this._accessibleLabelWarned)
192
+ return;
193
+ if (this.accessibleLabel || this.inputId)
194
+ return;
195
+ this._accessibleLabelWarned = true;
196
+ console.warn(`<${this.localName}>: No accessible-label or input-id provided. Use nldd-form-field for labeled usage, or set accessible-label for screen reader accessibility (WCAG SC 4.1.2).`);
197
+ }
198
+ formValue() {
199
+ return this.value;
200
+ }
201
+ formResetCallback() {
202
+ this.value = this._initialValue;
203
+ }
204
+ formStateRestoreCallback(state) {
205
+ if (typeof state === 'string')
206
+ this.value = state;
207
+ }
208
+ /** CodeMirror builds the textbox; the host is only its container. */
209
+ describedTarget() {
210
+ return this.shadowRoot?.querySelector('.cm-content') ?? null;
211
+ }
212
+ }
213
+ NLDDCodeMirrorInput.shadowRootOptions = {
214
+ ...LitElement.shadowRootOptions,
215
+ delegatesFocus: true,
216
+ };
217
+ /** Says this is the control an nldd-form-field is about, so the field can
218
+ * find it, name it and move focus into it. See nldd-form-field. */
219
+ NLDDCodeMirrorInput.isFormInput = true;
220
+ __decorate([
221
+ property({ type: String })
222
+ ], NLDDCodeMirrorInput.prototype, "value", void 0);
223
+ __decorate([
224
+ property({ type: String, attribute: 'input-id' })
225
+ ], NLDDCodeMirrorInput.prototype, "inputId", void 0);
226
+ __decorate([
227
+ property({ reflect: true, converter: reflectNonDefault('') })
228
+ ], NLDDCodeMirrorInput.prototype, "placeholder", void 0);
229
+ __decorate([
230
+ property({ type: Boolean, reflect: true })
231
+ ], NLDDCodeMirrorInput.prototype, "disabled", void 0);
232
+ __decorate([
233
+ property({ reflect: true, converter: reflectNonDefault('') })
234
+ ], NLDDCodeMirrorInput.prototype, "name", void 0);
235
+ __decorate([
236
+ property({ type: Boolean, reflect: true })
237
+ ], NLDDCodeMirrorInput.prototype, "readonly", void 0);
238
+ __decorate([
239
+ property({ type: Boolean, reflect: true })
240
+ ], NLDDCodeMirrorInput.prototype, "required", void 0);
241
+ __decorate([
242
+ property({ type: Number })
243
+ ], NLDDCodeMirrorInput.prototype, "rows", void 0);
244
+ __decorate([
245
+ property({ type: String, attribute: 'accessible-label' })
246
+ ], NLDDCodeMirrorInput.prototype, "accessibleLabel", void 0);
247
+ __decorate([
248
+ property({ type: Boolean, reflect: true })
249
+ ], NLDDCodeMirrorInput.prototype, "invalid", void 0);
250
+ //# sourceMappingURL=codemirror-input.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"codemirror-input.js","sourceRoot":"","sources":["../../../src/utilities/codemirror/codemirror-input.ts"],"names":[],"mappings":";;;;;;AAAA,OAAO,EAAE,UA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AAE,CAAC;qDAC1B;AAGjB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;qDAC1B;AAGjB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,CAAC;iDAClB;AAGT;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,MAAM,EAAE,SAAS,EAAE,kBAAkB,EAAE,CAAC;4DACrC;AAYrB;IADC,QAAQ,CAAC,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,IAAI,EAAE,CAAC;oDAC3B"}
@@ -41,7 +41,7 @@ const baseTheme = EditorView.theme({
41
41
  // equal specificity — otherwise CM's light base theme paints the focused
42
42
  // selection lavender, unreadable on a dark surface.
43
43
  '&.cm-focused > .cm-scroller > .cm-selectionLayer .cm-selectionBackground, .cm-selectionBackground, .cm-content ::selection': {
44
- backgroundColor: 'light-dark(var(--primitives-color-accent-150), var(--primitives-color-accent-250))',
44
+ backgroundColor: 'var(--semantics-text-selection-background-color)',
45
45
  },
46
46
  '.cm-gutters': {
47
47
  border: 'none',
@@ -1 +1 @@
1
- {"version":3,"file":"theme.js","sourceRoot":"","sources":["../../../src/utilities/codemirror/theme.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,kBAAkB,CAAC;AAC9C,OAAO,EAAE,cAAc,EAAE,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAC1E,OAAO,EAAE,IAAI,IAAI,CAAC,EAAE,MAAM,kBAAkB,CAAC;AAG7C;;;;mEAImE;AACnE,MAAM,SAAS,GAAG,UAAU,CAAC,KAAK,CAAC;IAClC,GAAG,EAAE;QACJ,MAAM,EAAE,MAAM;QACd,KAAK,EAAE,gCAAgC;QACvC,eAAe,EAAE,aAAa;KAC9B;IACD,cAAc,EAAE;QACf,gEAAgE;QAChE,OAAO,EAAE,MAAM;KACf;IACD,cAAc,EAAE;QACf,UAAU,EAAE,SAAS;QACrB,UA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wC,EAAE;IAC/D,EAAE,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,UAAU,EAAE,MAAM,EAAE;IACrC,EAAE,GAAG,EAAE,CAAC,CAAC,QAAQ,EAAE,SAAS,EAAE,QAAQ,EAAE;CACxC,CAAC,CAAC;AAEH,8EAA8E;AAC9E,MAAM,CAAC,MAAM,mBAAmB,GAAc,CAAC,SAAS,EAAE,kBAAkB,CAAC,cAAc,CAAC,CAAC,CAAC"}
@@ -0,0 +1,50 @@
1
+ import type { ReactiveController, ReactiveControllerHost } from 'lit';
2
+ import type { OS } from './os.js';
3
+ /**
4
+ * The shortcut hint attributes that nldd-menu-item, nldd-tooltip, nldd-button,
5
+ * nldd-icon-button, nldd-toggle-button, nldd-segmented-control-item,
6
+ * nldd-split-button and nldd-search-field share: `shortcut` plus a per-OS
7
+ * override. Display only; the application binds the key.
8
+ */
9
+ export interface ShortcutHint {
10
+ shortcut: string;
11
+ shortcutMac: string;
12
+ shortcutWindows: string;
13
+ shortcutLinux: string;
14
+ }
15
+ export interface KeysPerOS {
16
+ keys: string;
17
+ macKeys: string;
18
+ windowsKeys: string;
19
+ linuxKeys: string;
20
+ }
21
+ export declare function hasShortcut(hint: ShortcutHint): boolean;
22
+ /** The key spec for this OS, with `keys` as the fallback. */
23
+ export declare function resolveKeys(spec: KeysPerOS, os: OS): string;
24
+ /** Splits 'Ctrl+Shift+P' into keys; a trailing '++' ('Ctrl++') or '+++' is a literal '+' key. */
25
+ export declare function parseKeys(spec: string): string[];
26
+ /** Whether a keyboard shortcut can be used on this device, so a hint for it is worth showing. */
27
+ export declare function shortcutsAvailable(): boolean;
28
+ /**
29
+ * Renders the host again when shortcuts become available or unavailable, such
30
+ * as when a pointer is attached or removed, so a shortcut in its accessible
31
+ * name follows the visible hint. Pass `onChange` for work that a render does
32
+ * not redo.
33
+ */
34
+ export declare class ShortcutAvailabilityController implements ReactiveController {
35
+ private _query;
36
+ private _onChange;
37
+ constructor(host: ReactiveControllerHost, onChange?: () => void);
38
+ private _handleChange;
39
+ hostConnected(): void;
40
+ hostDisconnected(): void;
41
+ }
42
+ /**
43
+ * The shortcut as words for an accessible name ("Ctrl Z"), matching how
44
+ * nldd-menu-item is announced. Empty without a shortcut, and where
45
+ * shortcutsAvailable() says the key cannot be pressed, as the hint is hidden
46
+ * there too. Read when the component renders; ShortcutAvailabilityController
47
+ * renders it again when that changes.
48
+ */
49
+ export declare function shortcutLabel(hint: ShortcutHint): string;
50
+ //# sourceMappingURL=shortcut.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shortcut.d.ts","sourceRoot":"","sources":["../../src/utilities/shortcut.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,sBAAsB,EAAE,MAAM,KAAK,CAAC;AAEtE,OAAO,KAAK,EAAE,EAAE,EAAE,MAAM,SAAS,CAAC;AAElC;;;;;GAKG;AACH,MAAM,WAAW,YAAY;IAC5B,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;IACxB,aAAa,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,SAAS;IACzB,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,SAAS,EAAE,MAAM,CAAC;CAClB;AAED,wBAAgB,WAAW,CAAC,IAAI,EAAE,YAAY,GAAG,OAAO,CAEvD;AAED,6DAA6D;AAC7D,wBAAgB,WAAW,CAAC,IAAI,EAAE,SAAS,EAAE,EAAE,EAAE,EAAE,GAAG,MAAM,CAK3D;AAED,iGAAiG;AACjG,wBAAgB,SAAS,CAAC,IAAI,EAAE,MAAM,GAAG,MAAM,EAAE,CAYhD;AAOD,iGAAiG;AACjG,wBAAgB,kBAAkB,IAAI,OAAO,CAE5C;AAED;;;;;GAKG;AACH,qBAAa,8BAA+B,YAAW,kBAAkB;IACxE,OAAO,CAAC,MAAM,CAA4E;IAC1F,OAAO,CAAC,SAAS,CAAa;gBAElB,IAAI,EAAE,sBAAsB,EAAE,QAAQ,CAAC,EAAE,MAAM,IAAI;IAK/D,OAAO,CAAC,aAAa,CAA0B;IAE/C,aAAa,IAAI,IAAI;IAIrB,gBAAgB,IAAI,IAAI;CAGxB;AAED;;;;;;GAMG;AACH,wBAAgB,aAAa,CAAC,IAAI,EAAE,YAAY,GAAG,MAAM,CASxD"}
@@ -0,0 +1,77 @@
1
+ import { detectOS } from './os.js';
2
+ export function hasShortcut(hint) {
3
+ return Boolean(hint.shortcut || hint.shortcutMac || hint.shortcutWindows || hint.shortcutLinux);
4
+ }
5
+ /** The key spec for this OS, with `keys` as the fallback. */
6
+ export function resolveKeys(spec, os) {
7
+ if (os === 'mac' && spec.macKeys)
8
+ return spec.macKeys;
9
+ if (os === 'windows' && spec.windowsKeys)
10
+ return spec.windowsKeys;
11
+ if (os === 'linux' && spec.linuxKeys)
12
+ return spec.linuxKeys;
13
+ return spec.keys;
14
+ }
15
+ /** Splits 'Ctrl+Shift+P' into keys; a trailing '++' ('Ctrl++') or '+++' is a literal '+' key. */
16
+ export function parseKeys(spec) {
17
+ if (!spec)
18
+ return [];
19
+ // Spaces around a '+' are spacing, not part of a key: 'Ctrl + +' is 'Ctrl++'.
20
+ const compact = spec.trim().replace(/\s*\+\s*/g, '+');
21
+ if (compact === '+')
22
+ return ['+'];
23
+ const MARKER = '\u0000';
24
+ return compact
25
+ .replace(/\+\+\+/g, `+${MARKER}+`)
26
+ .replace(/\+\+$/, `+${MARKER}`)
27
+ .split('+')
28
+ .map(k => k.trim().split(MARKER).join('+'))
29
+ .filter(Boolean);
30
+ }
31
+ // A browser cannot tell whether there is a keyboard. A device whose pointers
32
+ // cannot hover is touch-only and most likely has none; nldd-keyboard-shortcut
33
+ // hides itself on the same media query.
34
+ const NO_SHORTCUTS_QUERY = '(any-hover: none)';
35
+ /** Whether a keyboard shortcut can be used on this device, so a hint for it is worth showing. */
36
+ export function shortcutsAvailable() {
37
+ return typeof matchMedia !== 'function' || !matchMedia(NO_SHORTCUTS_QUERY).matches;
38
+ }
39
+ /**
40
+ * Renders the host again when shortcuts become available or unavailable, such
41
+ * as when a pointer is attached or removed, so a shortcut in its accessible
42
+ * name follows the visible hint. Pass `onChange` for work that a render does
43
+ * not redo.
44
+ */
45
+ export class ShortcutAvailabilityController {
46
+ constructor(host, onChange) {
47
+ this._query = typeof matchMedia === 'function' ? matchMedia(NO_SHORTCUTS_QUERY) : null;
48
+ this._handleChange = () => this._onChange();
49
+ this._onChange = onChange ?? (() => host.requestUpdate());
50
+ host.addController(this);
51
+ }
52
+ hostConnected() {
53
+ this._query?.addEventListener('change', this._handleChange);
54
+ }
55
+ hostDisconnected() {
56
+ this._query?.removeEventListener('change', this._handleChange);
57
+ }
58
+ }
59
+ /**
60
+ * The shortcut as words for an accessible name ("Ctrl Z"), matching how
61
+ * nldd-menu-item is announced. Empty without a shortcut, and where
62
+ * shortcutsAvailable() says the key cannot be pressed, as the hint is hidden
63
+ * there too. Read when the component renders; ShortcutAvailabilityController
64
+ * renders it again when that changes.
65
+ */
66
+ export function shortcutLabel(hint) {
67
+ if (!hasShortcut(hint) || !shortcutsAvailable())
68
+ return '';
69
+ const spec = resolveKeys({
70
+ keys: hint.shortcut,
71
+ macKeys: hint.shortcutMac,
72
+ windowsKeys: hint.shortcutWindows,
73
+ linuxKeys: hint.shortcutLinux,
74
+ }, detectOS());
75
+ return parseKeys(spec).join(' ');
76
+ }
77
+ //# sourceMappingURL=shortcut.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"shortcut.js","sourceRoot":"","sources":["../../src/utilities/shortcut.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,QAAQ,EAAE,MAAM,SAAS,CAAC;AAuBnC,MAAM,UAAU,WAAW,CAAC,IAAkB;IAC7C,OAAO,OAAO,CAAC,IAAI,CAAC,QAAQ,IAAI,IAAI,CAAC,WAAW,IAAI,IAAI,CAAC,eAAe,I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
2
2
  "name": "@nldd/design-system",
3
- "version": "0.10.0",
3
+ "version": "0.12.0",
4
4
  "description": "Designsysteem voor de Nederlandse Digitale Dienst",
5
5
  "type": "module",
6
6
  "main": "dist/components/components.js",
@@ -620,6 +620,7 @@
620
620
  "@codemirror/lang-yaml": "^6.1.3",
621
621
  "@codemirror/language": "^6.12.4",
622
622
  "@codemirror/legacy-modes": "^6.5.3",
623
+ "@codemirror/merge": "^6.12.2",
623
624
  "@codemirror/state": "^6.7.0",
624
625
  "@codemirror/view": "^6.43.4",
625
626
  "@floating-ui/dom": "^1.7.6",