@webtides/element-library 0.1.2 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (398) hide show
  1. package/CHANGELOG.md +390 -3
  2. package/README.md +61 -41
  3. package/all.js +28 -0
  4. package/catalog.d.ts +14 -0
  5. package/catalog.js +63 -0
  6. package/custom-elements.json +16604 -3420
  7. package/package.json +37 -25
  8. package/src/components/accordion/accordion.changelog.md +10 -0
  9. package/src/components/accordion/accordion.js +10 -7
  10. package/src/components/accordion/accordion.readme.md +2 -0
  11. package/src/components/accordion/accordion.style.js +8 -0
  12. package/src/components/amount-field/amount-field.changelog.md +23 -3
  13. package/src/components/amount-field/amount-field.js +53 -26
  14. package/src/components/amount-field/amount-field.readme.md +82 -20
  15. package/src/components/amount-field/amount-field.style.js +111 -47
  16. package/src/components/avatar/avatar.changelog.md +23 -0
  17. package/src/components/avatar/avatar.define.js +3 -0
  18. package/src/components/avatar/avatar.js +115 -0
  19. package/src/components/avatar/avatar.readme.md +132 -0
  20. package/src/components/avatar/avatar.style.js +67 -0
  21. package/src/components/badge/badge.changelog.md +23 -0
  22. package/src/components/badge/badge.define.js +3 -0
  23. package/src/components/badge/badge.js +59 -0
  24. package/src/components/badge/badge.readme.md +109 -0
  25. package/src/components/badge/badge.style.js +63 -0
  26. package/src/components/breadcrumb/breadcrumb.changelog.md +22 -0
  27. package/src/components/breadcrumb/breadcrumb.define.js +3 -0
  28. package/src/components/breadcrumb/breadcrumb.js +47 -0
  29. package/src/components/breadcrumb/breadcrumb.readme.md +108 -0
  30. package/src/components/breadcrumb/breadcrumb.style.js +20 -0
  31. package/src/components/breadcrumb-item/breadcrumb-item.changelog.md +23 -0
  32. package/src/components/breadcrumb-item/breadcrumb-item.define.js +3 -0
  33. package/src/components/breadcrumb-item/breadcrumb-item.js +82 -0
  34. package/src/components/breadcrumb-item/breadcrumb-item.readme.md +106 -0
  35. package/src/components/breadcrumb-item/breadcrumb-item.style.js +92 -0
  36. package/src/components/button/button.changelog.md +34 -1
  37. package/src/components/button/button.js +285 -29
  38. package/src/components/button/button.readme.md +130 -10
  39. package/src/components/button/button.style.js +99 -120
  40. package/src/components/button-group/button-group.changelog.md +24 -0
  41. package/src/components/button-group/button-group.define.js +3 -0
  42. package/src/components/button-group/button-group.js +53 -0
  43. package/src/components/button-group/button-group.readme.md +114 -0
  44. package/src/components/button-group/button-group.style.js +41 -0
  45. package/src/components/card/card.changelog.md +23 -0
  46. package/src/components/card/card.define.js +3 -0
  47. package/src/components/card/card.js +73 -0
  48. package/src/components/card/card.readme.md +136 -0
  49. package/src/components/card/card.style.js +99 -0
  50. package/src/components/carousel/carousel.changelog.md +20 -0
  51. package/src/components/carousel/carousel.js +89 -40
  52. package/src/components/carousel/carousel.readme.md +39 -6
  53. package/src/components/carousel/carousel.style.js +21 -77
  54. package/src/components/carousel/glide/components/ShadowAnchors.js +3 -1
  55. package/src/components/carousel/glide/components/ShadowClones.js +21 -24
  56. package/src/components/carousel/glide/components/ShadowGaps.js +2 -2
  57. package/src/components/carousel/glide/components/ShadowHtml.js +22 -3
  58. package/src/components/checkbox-field/checkbox-field.changelog.md +19 -0
  59. package/src/components/checkbox-field/checkbox-field.js +25 -10
  60. package/src/components/checkbox-field/checkbox-field.readme.md +17 -4
  61. package/src/components/checkbox-field/checkbox-field.style.js +15 -3
  62. package/src/components/checkbox-group-field/checkbox-group-field.changelog.md +25 -0
  63. package/src/components/checkbox-group-field/checkbox-group-field.define.js +3 -0
  64. package/src/components/checkbox-group-field/checkbox-group-field.js +217 -0
  65. package/src/components/checkbox-group-field/checkbox-group-field.readme.md +95 -0
  66. package/src/components/checkbox-group-field/checkbox-group-field.style.js +62 -0
  67. package/src/components/color-field/color-field.changelog.md +24 -0
  68. package/src/components/color-field/color-field.define.js +3 -0
  69. package/src/components/color-field/color-field.js +184 -0
  70. package/src/components/color-field/color-field.readme.md +95 -0
  71. package/src/components/color-field/color-field.style.js +39 -0
  72. package/src/components/combobox-field/combobox-field.changelog.md +23 -0
  73. package/src/components/combobox-field/combobox-field.define.js +3 -0
  74. package/src/components/combobox-field/combobox-field.js +97 -0
  75. package/src/components/combobox-field/combobox-field.readme.md +93 -0
  76. package/src/components/combobox-field/combobox-field.style.js +56 -0
  77. package/src/components/copy-button/copy-button.changelog.md +24 -0
  78. package/src/components/copy-button/copy-button.define.js +3 -0
  79. package/src/components/copy-button/copy-button.events.js +4 -0
  80. package/src/components/copy-button/copy-button.js +237 -0
  81. package/src/components/copy-button/copy-button.readme.md +134 -0
  82. package/src/components/copy-button/copy-button.style.js +109 -0
  83. package/src/components/date-field/date-field.changelog.md +24 -0
  84. package/src/components/date-field/date-field.define.js +3 -0
  85. package/src/components/date-field/date-field.js +119 -0
  86. package/src/components/date-field/date-field.readme.md +110 -0
  87. package/src/components/date-field/date-field.style.js +53 -0
  88. package/src/components/dialog/dialog.changelog.md +16 -1
  89. package/src/components/dialog/dialog.js +252 -57
  90. package/src/components/dialog/dialog.readme.md +36 -4
  91. package/src/components/dialog/dialog.style.js +9 -109
  92. package/src/components/divider/divider.changelog.md +23 -0
  93. package/src/components/divider/divider.define.js +3 -0
  94. package/src/components/divider/divider.js +48 -0
  95. package/src/components/divider/divider.readme.md +101 -0
  96. package/src/components/divider/divider.style.js +50 -0
  97. package/src/components/drawer/drawer.changelog.md +25 -0
  98. package/src/components/drawer/drawer.define.js +3 -0
  99. package/src/components/drawer/drawer.events.js +8 -0
  100. package/src/components/drawer/drawer.js +80 -0
  101. package/src/components/drawer/drawer.readme.md +194 -0
  102. package/src/components/drawer/drawer.style.js +83 -0
  103. package/src/components/dropdown/dropdown.js +9 -7
  104. package/src/components/empty-state/empty-state.changelog.md +22 -0
  105. package/src/components/empty-state/empty-state.define.js +3 -0
  106. package/src/components/empty-state/empty-state.js +55 -0
  107. package/src/components/empty-state/empty-state.readme.md +114 -0
  108. package/src/components/empty-state/empty-state.style.js +60 -0
  109. package/src/components/file-field/file-field.changelog.md +24 -0
  110. package/src/components/file-field/file-field.define.js +3 -0
  111. package/src/components/file-field/file-field.js +205 -0
  112. package/src/components/file-field/file-field.readme.md +103 -0
  113. package/src/components/file-field/file-field.style.js +28 -0
  114. package/src/components/form-field/form-field.changelog.md +25 -0
  115. package/src/components/form-field/form-field.js +212 -15
  116. package/src/components/form-field/form-field.readme.md +82 -18
  117. package/src/components/form-field/form-field.style.js +6 -24
  118. package/src/components/input-field/input-field.changelog.md +24 -0
  119. package/src/components/input-field/input-field.js +82 -6
  120. package/src/components/input-field/input-field.readme.md +34 -5
  121. package/src/components/input-field/input-field.style.js +32 -13
  122. package/src/components/notification/notification.changelog.md +21 -1
  123. package/src/components/notification/notification.js +80 -74
  124. package/src/components/notification/notification.readme.md +54 -13
  125. package/src/components/notification/notification.style.js +37 -22
  126. package/src/components/otp-field/otp-field.changelog.md +23 -0
  127. package/src/components/otp-field/otp-field.define.js +3 -0
  128. package/src/components/otp-field/otp-field.events.js +3 -0
  129. package/src/components/otp-field/otp-field.js +172 -0
  130. package/src/components/otp-field/otp-field.readme.md +111 -0
  131. package/src/components/otp-field/otp-field.style.js +53 -0
  132. package/src/components/pagination/pagination.changelog.md +30 -0
  133. package/src/components/pagination/pagination.define.js +3 -0
  134. package/src/components/pagination/pagination.events.js +3 -0
  135. package/src/components/pagination/pagination.js +282 -0
  136. package/src/components/pagination/pagination.readme.md +167 -0
  137. package/src/components/pagination/pagination.style.js +162 -0
  138. package/src/components/password-field/password-field.changelog.md +24 -0
  139. package/src/components/password-field/password-field.js +7 -1
  140. package/src/components/password-field/password-field.readme.md +15 -6
  141. package/src/components/password-field/password-field.style.js +36 -13
  142. package/src/components/popover/popover.changelog.md +24 -0
  143. package/src/components/popover/popover.define.js +3 -0
  144. package/src/components/popover/popover.events.js +4 -0
  145. package/src/components/popover/popover.js +255 -0
  146. package/src/components/popover/popover.readme.md +132 -0
  147. package/src/components/popover/popover.style.js +41 -0
  148. package/src/components/progress-bar/progress-bar.changelog.md +23 -0
  149. package/src/components/progress-bar/progress-bar.define.js +3 -0
  150. package/src/components/progress-bar/progress-bar.js +80 -0
  151. package/src/components/progress-bar/progress-bar.readme.md +110 -0
  152. package/src/components/progress-bar/progress-bar.style.js +93 -0
  153. package/src/components/progress-ring/progress-ring.changelog.md +23 -0
  154. package/src/components/progress-ring/progress-ring.define.js +3 -0
  155. package/src/components/progress-ring/progress-ring.js +83 -0
  156. package/src/components/progress-ring/progress-ring.readme.md +115 -0
  157. package/src/components/progress-ring/progress-ring.style.js +85 -0
  158. package/src/components/radio-field/radio-field.changelog.md +16 -0
  159. package/src/components/radio-field/radio-field.js +34 -11
  160. package/src/components/radio-field/radio-field.readme.md +13 -8
  161. package/src/components/radio-field/radio-field.style.js +17 -65
  162. package/src/components/range-field/range-field.changelog.md +24 -0
  163. package/src/components/range-field/range-field.define.js +3 -0
  164. package/src/components/range-field/range-field.js +167 -0
  165. package/src/components/range-field/range-field.readme.md +87 -0
  166. package/src/components/range-field/range-field.style.js +41 -0
  167. package/src/components/rating-field/rating-field.changelog.md +24 -0
  168. package/src/components/rating-field/rating-field.define.js +3 -0
  169. package/src/components/rating-field/rating-field.js +195 -0
  170. package/src/components/rating-field/rating-field.readme.md +82 -0
  171. package/src/components/rating-field/rating-field.style.js +79 -0
  172. package/src/components/select-field/select-field.changelog.md +17 -0
  173. package/src/components/select-field/select-field.js +100 -8
  174. package/src/components/select-field/select-field.readme.md +32 -6
  175. package/src/components/select-field/select-field.style.js +19 -9
  176. package/src/components/skeleton/skeleton.changelog.md +22 -0
  177. package/src/components/skeleton/skeleton.define.js +3 -0
  178. package/src/components/skeleton/skeleton.js +49 -0
  179. package/src/components/skeleton/skeleton.readme.md +115 -0
  180. package/src/components/skeleton/skeleton.style.js +79 -0
  181. package/src/components/slider/slider.changelog.md +15 -0
  182. package/src/components/slider/slider.js +37 -5
  183. package/src/components/slider/slider.readme.md +28 -6
  184. package/src/components/slider/slider.style.js +7 -71
  185. package/src/components/spinner/spinner.changelog.md +22 -0
  186. package/src/components/spinner/spinner.define.js +3 -0
  187. package/src/components/spinner/spinner.js +48 -0
  188. package/src/components/spinner/spinner.readme.md +98 -0
  189. package/src/components/spinner/spinner.style.js +44 -0
  190. package/src/components/switch-field/switch-field.changelog.md +16 -0
  191. package/src/components/switch-field/switch-field.js +17 -9
  192. package/src/components/switch-field/switch-field.readme.md +11 -4
  193. package/src/components/switch-field/switch-field.style.js +13 -13
  194. package/src/components/tab-group/tab-group.changelog.md +19 -0
  195. package/src/components/tab-group/tab-group.js +122 -10
  196. package/src/components/tab-group/tab-group.readme.md +25 -4
  197. package/src/components/tab-link/tab-link.changelog.md +16 -0
  198. package/src/components/tab-link/tab-link.js +51 -8
  199. package/src/components/tab-link/tab-link.readme.md +14 -8
  200. package/src/components/tab-link/tab-link.style.js +13 -0
  201. package/src/components/tab-panel/tab-panel.changelog.md +8 -2
  202. package/src/components/tab-panel/tab-panel.js +7 -3
  203. package/src/components/tab-panel/tab-panel.readme.md +7 -5
  204. package/src/components/tag/tag.changelog.md +24 -0
  205. package/src/components/tag/tag.define.js +3 -0
  206. package/src/components/tag/tag.events.js +3 -0
  207. package/src/components/tag/tag.js +116 -0
  208. package/src/components/tag/tag.readme.md +119 -0
  209. package/src/components/tag/tag.style.js +101 -0
  210. package/src/components/tag-field/tag-field.changelog.md +25 -0
  211. package/src/components/tag-field/tag-field.define.js +3 -0
  212. package/src/components/tag-field/tag-field.js +359 -0
  213. package/src/components/tag-field/tag-field.readme.md +113 -0
  214. package/src/components/tag-field/tag-field.style.js +62 -0
  215. package/src/components/textarea-field/textarea-field.changelog.md +28 -4
  216. package/src/components/textarea-field/textarea-field.js +68 -14
  217. package/src/components/textarea-field/textarea-field.readme.md +45 -9
  218. package/src/components/textarea-field/textarea-field.style.js +45 -2
  219. package/src/components/toast/toast.changelog.md +24 -0
  220. package/src/components/toast/toast.define.js +3 -0
  221. package/src/components/toast/toast.js +193 -0
  222. package/src/components/toast/toast.readme.md +189 -0
  223. package/src/components/toast/toast.style.js +74 -0
  224. package/src/components/tooltip/tooltip.changelog.md +24 -0
  225. package/src/components/tooltip/tooltip.define.js +3 -0
  226. package/src/components/tooltip/tooltip.events.js +4 -0
  227. package/src/components/tooltip/tooltip.js +377 -0
  228. package/src/components/tooltip/tooltip.readme.md +172 -0
  229. package/src/components/tooltip/tooltip.style.js +107 -0
  230. package/src/components/transition-classes/transition-classes.js +6 -6
  231. package/src/styles/appearance.style.js +42 -0
  232. package/src/styles/arrow.style.js +65 -0
  233. package/src/styles/choice-group.style.js +94 -0
  234. package/src/styles/form-control.style.js +79 -0
  235. package/src/styles/host.style.js +55 -0
  236. package/src/styles/layers.css +31 -0
  237. package/src/styles/modal.style.js +146 -0
  238. package/src/styles/native.css +275 -0
  239. package/src/styles/size.style.js +48 -0
  240. package/src/styles/slide-controls.style.js +225 -0
  241. package/src/styles/utilities.css +30 -0
  242. package/src/styles/variants.style.js +78 -0
  243. package/src/themes/default.css +86 -142
  244. package/src/themes/high-contrast.css +72 -129
  245. package/src/themes/sketchy.css +95 -175
  246. package/src/utils/floating.js +71 -0
  247. package/src/utils/focus.js +18 -0
  248. package/src/utils/progress.js +25 -0
  249. package/src/utils/slots.js +21 -0
  250. package/src/utils/text-entry-attributes.js +51 -0
  251. package/types/all.d.ts +54 -1
  252. package/types/index.d.ts +1 -0
  253. package/types/src/components/accordion/accordion.d.ts +6 -4
  254. package/types/src/components/accordion/accordion.events.d.ts +3 -3
  255. package/types/src/components/accordion-group/accordion-group.d.ts +4 -3
  256. package/types/src/components/amount-field/amount-field.d.ts +30 -16
  257. package/types/src/components/avatar/avatar.d.ts +57 -0
  258. package/types/src/components/avatar/avatar.define.d.ts +1 -0
  259. package/types/src/components/avatar/avatar.style.d.ts +2 -0
  260. package/types/src/components/badge/badge.d.ts +32 -0
  261. package/types/src/components/badge/badge.define.d.ts +1 -0
  262. package/types/src/components/badge/badge.style.d.ts +2 -0
  263. package/types/src/components/breadcrumb/breadcrumb.d.ts +27 -0
  264. package/types/src/components/breadcrumb/breadcrumb.define.d.ts +1 -0
  265. package/types/src/components/breadcrumb/breadcrumb.style.d.ts +2 -0
  266. package/types/src/components/breadcrumb-item/breadcrumb-item.d.ts +38 -0
  267. package/types/src/components/breadcrumb-item/breadcrumb-item.define.d.ts +1 -0
  268. package/types/src/components/breadcrumb-item/breadcrumb-item.style.d.ts +2 -0
  269. package/types/src/components/button/button.d.ts +129 -14
  270. package/types/src/components/button-group/button-group.d.ts +28 -0
  271. package/types/src/components/button-group/button-group.define.d.ts +1 -0
  272. package/types/src/components/button-group/button-group.style.d.ts +2 -0
  273. package/types/src/components/card/card.d.ts +40 -0
  274. package/types/src/components/card/card.define.d.ts +1 -0
  275. package/types/src/components/card/card.style.d.ts +2 -0
  276. package/types/src/components/carousel/carousel.d.ts +22 -8
  277. package/types/src/components/carousel/carousel.events.d.ts +3 -3
  278. package/types/src/components/carousel/glide/components/ShadowAnchors.d.ts +1 -1
  279. package/types/src/components/carousel/glide/components/ShadowClones.d.ts +8 -1
  280. package/types/src/components/carousel/glide/components/ShadowGaps.d.ts +1 -1
  281. package/types/src/components/carousel/glide/components/ShadowHtml.d.ts +1 -1
  282. package/types/src/components/carousel/glide/components/glide-html.d.ts +1 -1
  283. package/types/src/components/checkbox-field/checkbox-field.d.ts +22 -15
  284. package/types/src/components/checkbox-group-field/checkbox-group-field.d.ts +100 -0
  285. package/types/src/components/checkbox-group-field/checkbox-group-field.define.d.ts +1 -0
  286. package/types/src/components/checkbox-group-field/checkbox-group-field.style.d.ts +2 -0
  287. package/types/src/components/color-field/color-field.d.ts +102 -0
  288. package/types/src/components/color-field/color-field.define.d.ts +1 -0
  289. package/types/src/components/color-field/color-field.style.d.ts +2 -0
  290. package/types/src/components/combobox-field/combobox-field.d.ts +84 -0
  291. package/types/src/components/combobox-field/combobox-field.define.d.ts +1 -0
  292. package/types/src/components/combobox-field/combobox-field.style.d.ts +2 -0
  293. package/types/src/components/copy-button/copy-button.d.ts +93 -0
  294. package/types/src/components/copy-button/copy-button.define.d.ts +1 -0
  295. package/types/src/components/copy-button/copy-button.events.d.ts +5 -0
  296. package/types/src/components/copy-button/copy-button.style.d.ts +2 -0
  297. package/types/src/components/date-field/date-field.d.ts +102 -0
  298. package/types/src/components/date-field/date-field.define.d.ts +1 -0
  299. package/types/src/components/date-field/date-field.style.d.ts +2 -0
  300. package/types/src/components/dialog/dialog.d.ts +101 -19
  301. package/types/src/components/dialog/dialog.events.d.ts +8 -8
  302. package/types/src/components/divider/divider.d.ts +27 -0
  303. package/types/src/components/divider/divider.define.d.ts +1 -0
  304. package/types/src/components/divider/divider.style.d.ts +2 -0
  305. package/types/src/components/drawer/drawer.d.ts +70 -0
  306. package/types/src/components/drawer/drawer.define.d.ts +1 -0
  307. package/types/src/components/drawer/drawer.events.d.ts +9 -0
  308. package/types/src/components/drawer/drawer.style.d.ts +2 -0
  309. package/types/src/components/dropdown/dropdown.d.ts +5 -3
  310. package/types/src/components/empty-state/empty-state.d.ts +29 -0
  311. package/types/src/components/empty-state/empty-state.define.d.ts +1 -0
  312. package/types/src/components/empty-state/empty-state.style.d.ts +2 -0
  313. package/types/src/components/file-field/file-field.d.ts +115 -0
  314. package/types/src/components/file-field/file-field.define.d.ts +1 -0
  315. package/types/src/components/file-field/file-field.style.d.ts +2 -0
  316. package/types/src/components/form-field/form-field.d.ts +129 -14
  317. package/types/src/components/form-field/form-field.events.d.ts +4 -4
  318. package/types/src/components/input-field/input-field.d.ts +52 -5
  319. package/types/src/components/lazy-src/lazy-src.d.ts +7 -5
  320. package/types/src/components/lazy-src/lazy-src.events.d.ts +5 -5
  321. package/types/src/components/notification/notification.d.ts +18 -18
  322. package/types/src/components/notification/notification.events.d.ts +6 -6
  323. package/types/src/components/otp-field/otp-field.d.ts +130 -0
  324. package/types/src/components/otp-field/otp-field.define.d.ts +1 -0
  325. package/types/src/components/otp-field/otp-field.events.d.ts +4 -0
  326. package/types/src/components/otp-field/otp-field.style.d.ts +2 -0
  327. package/types/src/components/pagination/pagination.d.ts +117 -0
  328. package/types/src/components/pagination/pagination.define.d.ts +1 -0
  329. package/types/src/components/pagination/pagination.events.d.ts +4 -0
  330. package/types/src/components/pagination/pagination.style.d.ts +2 -0
  331. package/types/src/components/password-field/password-field.d.ts +29 -12
  332. package/types/src/components/popover/popover.d.ts +123 -0
  333. package/types/src/components/popover/popover.define.d.ts +1 -0
  334. package/types/src/components/popover/popover.events.d.ts +5 -0
  335. package/types/src/components/popover/popover.style.d.ts +2 -0
  336. package/types/src/components/progress-bar/progress-bar.d.ts +35 -0
  337. package/types/src/components/progress-bar/progress-bar.define.d.ts +1 -0
  338. package/types/src/components/progress-bar/progress-bar.style.d.ts +2 -0
  339. package/types/src/components/progress-ring/progress-ring.d.ts +40 -0
  340. package/types/src/components/progress-ring/progress-ring.define.d.ts +1 -0
  341. package/types/src/components/progress-ring/progress-ring.style.d.ts +2 -0
  342. package/types/src/components/radio-field/radio-field.d.ts +21 -9
  343. package/types/src/components/range-field/range-field.d.ts +94 -0
  344. package/types/src/components/range-field/range-field.define.d.ts +1 -0
  345. package/types/src/components/range-field/range-field.style.d.ts +2 -0
  346. package/types/src/components/rating-field/rating-field.d.ts +96 -0
  347. package/types/src/components/rating-field/rating-field.define.d.ts +1 -0
  348. package/types/src/components/rating-field/rating-field.style.d.ts +2 -0
  349. package/types/src/components/scroll-to/scroll-to.d.ts +3 -2
  350. package/types/src/components/scroll-to-top/scroll-to-top.d.ts +4 -2
  351. package/types/src/components/select-field/select-field.d.ts +55 -5
  352. package/types/src/components/skeleton/skeleton.d.ts +29 -0
  353. package/types/src/components/skeleton/skeleton.define.d.ts +1 -0
  354. package/types/src/components/skeleton/skeleton.style.d.ts +2 -0
  355. package/types/src/components/slider/slider.d.ts +14 -8
  356. package/types/src/components/slider/slider.events.d.ts +4 -4
  357. package/types/src/components/spinner/spinner.d.ts +28 -0
  358. package/types/src/components/spinner/spinner.define.d.ts +1 -0
  359. package/types/src/components/spinner/spinner.style.d.ts +2 -0
  360. package/types/src/components/sticky/sticky.d.ts +4 -2
  361. package/types/src/components/svg-use/svg-use.d.ts +4 -2
  362. package/types/src/components/switch-field/switch-field.d.ts +17 -15
  363. package/types/src/components/tab-group/tab-group.d.ts +44 -3
  364. package/types/src/components/tab-link/tab-link.d.ts +33 -10
  365. package/types/src/components/tab-panel/tab-panel.d.ts +8 -5
  366. package/types/src/components/tag/tag.d.ts +53 -0
  367. package/types/src/components/tag/tag.define.d.ts +1 -0
  368. package/types/src/components/tag/tag.events.d.ts +4 -0
  369. package/types/src/components/tag/tag.style.d.ts +2 -0
  370. package/types/src/components/tag-field/tag-field.d.ts +178 -0
  371. package/types/src/components/tag-field/tag-field.define.d.ts +1 -0
  372. package/types/src/components/tag-field/tag-field.style.d.ts +2 -0
  373. package/types/src/components/textarea-field/textarea-field.d.ts +44 -4
  374. package/types/src/components/toast/toast.d.ts +110 -0
  375. package/types/src/components/toast/toast.define.d.ts +1 -0
  376. package/types/src/components/toast/toast.style.d.ts +2 -0
  377. package/types/src/components/tooltip/tooltip.d.ts +161 -0
  378. package/types/src/components/tooltip/tooltip.define.d.ts +1 -0
  379. package/types/src/components/tooltip/tooltip.events.d.ts +5 -0
  380. package/types/src/components/tooltip/tooltip.style.d.ts +2 -0
  381. package/types/src/components/transition-classes/transition-classes.d.ts +9 -8
  382. package/types/src/styles/appearance.style.d.ts +18 -0
  383. package/types/src/styles/arrow.style.d.ts +15 -0
  384. package/types/src/styles/choice-group.style.d.ts +23 -0
  385. package/types/src/styles/form-control.style.d.ts +26 -0
  386. package/types/src/styles/host.style.d.ts +24 -0
  387. package/types/src/styles/modal.style.d.ts +20 -0
  388. package/types/src/styles/size.style.d.ts +20 -0
  389. package/types/src/styles/slide-controls.style.d.ts +20 -0
  390. package/types/src/styles/variants.style.d.ts +32 -0
  391. package/types/src/utils/body-scroll.d.ts +12 -2
  392. package/types/src/utils/floating.d.ts +36 -0
  393. package/types/src/utils/focus.d.ts +16 -0
  394. package/types/src/utils/progress.d.ts +19 -0
  395. package/types/src/utils/slots.d.ts +19 -0
  396. package/types/src/utils/text-entry-attributes.d.ts +18 -0
  397. package/types/src/utils/transitions.d.ts +2 -2
  398. package/web-types.json +6590 -1584
@@ -0,0 +1,95 @@
1
+ # ColorField
2
+
3
+ `color-field` takes a colour: the colour of a label, of a calendar, the accent of a workspace. It renders a native `<input type="color">`, so the picker, the keyboard and the form submission are the ones of the browser. It extends `form-field`, inheriting the label, help text, error message and touched-state handling.
4
+
5
+ It is headless by default: the control keeps the look of the browser. `styles/native.css` gives it the border, the radius and the height of the other controls.
6
+
7
+ ## How to use
8
+
9
+ #### Install
10
+
11
+ ```sh
12
+ npm i --save @webtides/element-library
13
+ ```
14
+
15
+ #### Use
16
+
17
+ ```js
18
+ import '@webtides/element-library/color-field/define';
19
+ ```
20
+
21
+ ```html
22
+ <el-color-field name="accent" label="Accent colour" value="#2563eb"></el-color-field>
23
+
24
+ <el-color-field
25
+ name="label"
26
+ label="Label colour"
27
+ value="#16a34a"
28
+ show-value="true"
29
+ options='["#2563eb", "#16a34a", "#f59e0b", "#dc2626"]'
30
+ ></el-color-field>
31
+ ```
32
+
33
+ #### The value
34
+
35
+ The value is the colour as the control has it: `#rrggbb`, in lower case. That is what the form submits.
36
+
37
+ A colour input always has a value. Without a `value` the control is black, and the field takes that over: `value` is `#000000`. That is no change, so no `input-change` reports it.
38
+
39
+ The control also brings a value from outside into its format, and the field takes over what the control made of it: `#F00` becomes `#ff0000`. A text that is no colour becomes black. Which other notations a browser reads (`red`, `rgb(255 0 0)`) is up to the browser, so give the field `#rrggbb`.
40
+
41
+ The field cannot be empty. A page that needs "no colour" puts a checkbox or a button beside it.
42
+
43
+ #### Colours to pick from
44
+
45
+ `options` is a list of colours the picker of the browser offers, the colours of a brand for example. The field renders them as the native list of the control (`<datalist>`). How a browser shows them is up to the browser, and one that does not know the list shows its picker without them. The user can still pick any other colour.
46
+
47
+ ```js
48
+ field.options = ['#2563eb', '#16a34a', '#f59e0b', '#dc2626'];
49
+ ```
50
+
51
+ ## API
52
+
53
+ #### Properties/Attributes
54
+
55
+ Inherits all of `form-field`'s properties (`name`, `value`, `disabled`, `label`, `labelScreenReaderOnly`, `errorMessage`, `helpMessage`, `valid`, `touched`) and adds:
56
+
57
+ | Name | Type | Default | Description |
58
+ | --- | --- | --- | --- |
59
+ | `value` | `string` | `null` | The colour, `#rrggbb`. Without one: the value of the control, see above. |
60
+ | `size` | `'small' \| 'medium' \| 'large'` | `'medium'` | Size of the control. Reflected to the `size` attribute. It shows once the control is decorated. |
61
+ | `showValue` | `boolean` | `false` | Shows the value beside the control (`show-value`). |
62
+ | `options` | `Array<string \| { value, label? }>` | `[]` | Colours the picker offers. A `label` is passed on to the option of the list. |
63
+
64
+ `required` has no effect: the control always has a value. The browser never finds a colour invalid, so the error message shows when the page sets `valid="false"` after a check of its own.
65
+
66
+ #### Events
67
+
68
+ | Name | Detail | Description |
69
+ | --- | --- | --- |
70
+ | `input-change` | `string` (the value) | Fired when the value changes, also while the user goes through the picker. Each value once. |
71
+
72
+ #### CSS States
73
+
74
+ | Name | Description |
75
+ | --------- | ----------------------------------------------------------------------------------------- |
76
+ | `touched` | Set once the control has been focused and left. A value alone does not set it. |
77
+ | `valid` | Set while the field passes validation. |
78
+ | `invalid` | Set while the field fails validation, which for this field is when the page says it does. |
79
+
80
+ #### CSS Custom Properties
81
+
82
+ Headless by default. The texts read the tokens every field reads (`--el-color-fg`, `--el-color-fg-muted`, `--el-color-danger`, `--el-font-size-sm`, `--el-space-1`, `--el-space-2`). With `styles/native.css` the control is a well with the border of the other controls (`--el-border-width`, `--el-color-border`, `--el-radius-md`) on `--el-color-bg`. It is as high as an input of its size (`--el-control-height`) and half again as wide, and the colour fills it up to a rim of `--el-space-1`. Keyboard focus shows the ring of the theme (`--el-focus-ring-width`, `--el-focus-ring-offset`, `--el-color-focus-ring`).
83
+
84
+ The label, the help message, the control and the error message stack in a column, and the texts have one look in every field: see [Layout](../form-field/form-field.readme.md#layout) in the readme of `form-field`. The shown value stands after the control, in its row.
85
+
86
+ On a touch screen (`@media (any-pointer: coarse)`) the control is at least `--el-touch-target` high. Without that token, and on a fine pointer, the size stays as it is.
87
+
88
+ ## Accessibility
89
+
90
+ - The native control is named by the label, and it says its value itself. Enter and Space open the picker of the browser, which brings its own keyboard handling.
91
+ - The shown value is hidden from assistive technology (`aria-hidden`): the control already says it, and it would be heard twice.
92
+ - A colour alone says little to a user who cannot tell colours apart. `show-value` gives the value as text; where a colour has a meaning, name it in the page.
93
+ - The control names the help message in `aria-describedby`, and the error message while that is shown.
94
+ - The control says whether the field is valid (`aria-invalid`).
95
+ - The error message is an alert (`role="alert"`): a screen reader announces it when it appears.
@@ -0,0 +1,39 @@
1
+ import hostStyle from '../../styles/host.style.js';
2
+ import formControlStyle from '../../styles/form-control.style.js';
3
+ import sizeStyle from '../../styles/size.style.js';
4
+
5
+ const css = String.raw;
6
+
7
+ /**
8
+ * The control keeps the look of the browser, as the control of every field does: `styles/native.css`
9
+ * gives it the border and the height of the other controls.
10
+ */
11
+ const style = css`
12
+ el-color-field {
13
+ /* The value beside the control. Every colour has as many characters, and digits of one
14
+ width keep the text from moving while the user goes through the picker. */
15
+ .value {
16
+ flex: none;
17
+ color: var(--el-color-fg, inherit);
18
+ font-variant-numeric: tabular-nums;
19
+ }
20
+
21
+ /* Touch screens: the control is at least --el-touch-target high, whatever the size of the
22
+ field. Without the token the size stays as it is. */
23
+ @media (any-pointer: coarse) {
24
+ input {
25
+ min-height: max(
26
+ calc(var(--el-control-height, 0px) * var(--_el-size-scale, 1)),
27
+ var(--el-touch-target, 0px)
28
+ );
29
+ }
30
+ }
31
+ }
32
+ `;
33
+
34
+ export default [
35
+ hostStyle('el-color-field'),
36
+ formControlStyle('el-color-field'),
37
+ sizeStyle('el-color-field'),
38
+ style,
39
+ ].join('\n');
@@ -0,0 +1,23 @@
1
+ # Change Log
2
+
3
+ All notable changes to this component live here. Versions refer to the parent `@webtides/element-library` release (see root [`CHANGELOG.md`](../../../CHANGELOG.md)); components no longer version independently.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/).
6
+
7
+ <!--
8
+ When your PR touches this component, add an entry under Unreleased and
9
+ mirror it (prefixed with the component name) in root CHANGELOG.md.
10
+ Uncomment headings as needed.
11
+ -->
12
+
13
+ ## Unreleased
14
+
15
+ ## [0.3.0] - 2026-11-17
16
+
17
+ ### Added
18
+
19
+ - Initial `el-combobox-field`: a text the user writes, with suggestions the browser offers while they type. An `el-input-field` with a native `<datalist>`, so it has the label, the messages, `required`, `pattern`, the sizes and the place in a form of an input field. ([#145](https://github.com/webtides/element-library/issues/145))
20
+ - `options` are the suggestions: plain strings, or `{ value, label }`. The field renders them as a list with an id of its own and names it on the control. Options that change reach the list, for suggestions a page loads while the user types.
21
+ - Without options there is no list, and the control is a plain text input, also for a screen reader.
22
+ - The value is free text: a suggestion is an offer, not a limit. `value` follows what is typed and what is picked, and `input-change` reports it.
23
+ - With `styles/native.css` the input has the look and the three sizes of the input of `el-input-field`. The list of the suggestions is drawn by the browser.
@@ -0,0 +1,3 @@
1
+ import { define } from './combobox-field.js';
2
+
3
+ define();
@@ -0,0 +1,97 @@
1
+ import { html, defineElement } from '@webtides/element-js';
2
+ import InputField from '../input-field/input-field.js';
3
+ import style from './combobox-field.style.js';
4
+
5
+ /**
6
+ * A text the user writes, with suggestions the browser offers while they type: a city, a job
7
+ * title, the name of a product. Extends `InputField` (and therefore `FormField`), inheriting the
8
+ * label / help / error / validation surface and the look from `styles/native.css`.
9
+ *
10
+ * The suggestions are a native `<datalist>`: the browser filters and shows them, and the keyboard
11
+ * and a screen reader work as the browser has them. A suggestion is an offer, not a limit: the
12
+ * value is free text. For a choice from a fixed list there is `el-select-field`.
13
+ *
14
+ * @element el-combobox-field
15
+ *
16
+ * @fires {CustomEvent<string>} input-change - Fired when the value changes: typed, or picked from
17
+ * the suggestions. `detail` is the new value. Bubbles.
18
+ *
19
+ * @property {Array<string | { value: string, label?: string }>} options - The suggestions: plain
20
+ * strings (`['Berlin', 'Bern']`) or option objects. The `value` is what a pick writes into the
21
+ * control; a `label` is a text the browser may show with it. Without options the control has no
22
+ * list and is a plain text input.
23
+ */
24
+ export default class ComboboxField extends InputField {
25
+ constructor(options) {
26
+ super({ shadowRender: false, styles: [style], ...options });
27
+ }
28
+
29
+ properties() {
30
+ return {
31
+ ...super.properties(),
32
+ options: [],
33
+ };
34
+ }
35
+
36
+ events() {
37
+ const events = super.events();
38
+ return {
39
+ ...events,
40
+ '[ref=input]': {
41
+ ...events['[ref=input]'],
42
+ // A pick from the suggestions presses no key that the field would hear, and not
43
+ // every browser fires `change` before the control is left.
44
+ input: () => this.onChange(),
45
+ },
46
+ };
47
+ }
48
+
49
+ /**
50
+ * The suggestions of `options`, as the options of the list.
51
+ * @private
52
+ * @returns {Array<{ value: string, label: string | null }>}
53
+ */
54
+ _suggestions() {
55
+ if (!Array.isArray(this.options)) return [];
56
+ return this.options.map((option) => ({
57
+ value: String(option?.value ?? option),
58
+ label: option?.label ?? null,
59
+ }));
60
+ }
61
+
62
+ /**
63
+ * The control names its list. Without suggestions it has none: a list that is empty would
64
+ * still make the control a combobox for a screen reader, one that offers nothing.
65
+ * @private
66
+ */
67
+ _controlAttributes() {
68
+ return { list: this._suggestions().length > 0 ? this._idOf('list') : null };
69
+ }
70
+
71
+ /** @private */
72
+ fieldTemplate() {
73
+ return html`${super.fieldTemplate()} ${this.listTemplate()}`;
74
+ }
75
+
76
+ /**
77
+ * The suggestions, in the list the control names. The id is the one of this field alone, so
78
+ * two fields of a page do not offer the suggestions of each other.
79
+ * @private
80
+ */
81
+ listTemplate() {
82
+ const suggestions = this._suggestions();
83
+ if (suggestions.length === 0) return null;
84
+
85
+ return html`
86
+ <datalist id="${this._idOf('list')}">
87
+ ${suggestions.map(
88
+ (suggestion) => html`<option value="${suggestion.value}" label="${suggestion.label}"></option>`,
89
+ )}
90
+ </datalist>
91
+ `;
92
+ }
93
+ }
94
+
95
+ export function define() {
96
+ defineElement('el-combobox-field', ComboboxField);
97
+ }
@@ -0,0 +1,93 @@
1
+ # ComboboxField
2
+
3
+ `combobox-field` takes a text the user writes, with suggestions the browser offers while they type: a city, a job title, the name of a product. It extends `input-field`, inheriting the label, help text, error message, `required`, `pattern`, the sizes and the touched-state handling.
4
+
5
+ The suggestions are a native `<datalist>`. The browser filters and shows them, and the keyboard and a screen reader work as the browser has them; the field has no list of its own.
6
+
7
+ A suggestion is an offer, not a limit: the value is free text, and the user may write something the list does not have. For a choice from a fixed list use `el-select-field`, for several texts `el-tag-field`.
8
+
9
+ It is headless by default: the control keeps the look of the browser. `styles/native.css` gives it the look of the input of `el-input-field`. The list of the suggestions is drawn by the browser and stays as it is.
10
+
11
+ ## How to use
12
+
13
+ #### Install
14
+
15
+ ```sh
16
+ npm i --save @webtides/element-library
17
+ ```
18
+
19
+ #### Use
20
+
21
+ ```js
22
+ import '@webtides/element-library/combobox-field/define';
23
+ ```
24
+
25
+ ```html
26
+ <el-combobox-field name="city" label="City" options='["Berlin", "Bern", "Bremen", "Brussels"]'></el-combobox-field>
27
+ ```
28
+
29
+ #### The suggestions
30
+
31
+ `options` takes plain strings, or option objects in the shape the other fields have:
32
+
33
+ ```js
34
+ field.options = ['Berlin', 'Bern'];
35
+ field.options = [
36
+ { value: 'Berlin', label: 'Germany' },
37
+ { value: 'Bern', label: 'Switzerland' }
38
+ ];
39
+ ```
40
+
41
+ The `value` of a suggestion is what a pick writes into the control, and so what the form submits. A `label` is a second text for it. What a browser shows of the two, and which of them it filters by, differs between browsers: do not put a value there that the user is not meant to see.
42
+
43
+ Without options the control has no list: it is a plain text input, also for a screen reader.
44
+
45
+ #### Suggestions from a server
46
+
47
+ `options` can change while the user types. Listen for `input-change`, load, and set the new list:
48
+
49
+ ```js
50
+ field.addEventListener('input-change', async (event) => {
51
+ field.options = await search(event.detail);
52
+ });
53
+ ```
54
+
55
+ The browser filters the list by what is in the control, so a list the server has filtered already is filtered twice. That only shows when the server finds by something else than the start or a part of the value.
56
+
57
+ ## API
58
+
59
+ #### Properties/Attributes
60
+
61
+ Inherits all of `input-field`'s properties (`type`, `size`, `placeholder`, `pattern`, `autocomplete`, `inputmode`, `enterkeyhint`, `autocapitalize`, `autocorrect`, `spellcheck`) and of `form-field` (`name`, `value`, `required`, `disabled`, `label`, `labelScreenReaderOnly`, `errorMessage`, `helpMessage`, `valid`, `touched`) and adds:
62
+
63
+ | Name | Type | Default | Description |
64
+ | --------- | ------------------------------------ | ------- | -------------------------------------------- |
65
+ | `options` | `Array<string \| { value, label? }>` | `[]` | The suggestions. As an attribute it is JSON. |
66
+
67
+ A list works with the types that take text: `text` (the default), `search`, `email`, `url`, `tel`. Set `autocomplete="off"` where the suggestions of the browser's own history would stand beside the ones of the page.
68
+
69
+ #### Events
70
+
71
+ | Name | Detail | Description |
72
+ | -------------- | -------------------- | -------------------------------------------------------------------- |
73
+ | `input-change` | `string` (the value) | Fired when the value changes: typed, or picked from the suggestions. |
74
+
75
+ #### CSS States
76
+
77
+ Inherited from `form-field`: `touched`, `valid`, `invalid`.
78
+
79
+ #### CSS Custom Properties
80
+
81
+ Headless by default. The texts read the tokens every field reads (`--el-color-fg`, `--el-color-fg-muted`, `--el-color-danger`, `--el-font-size-sm`, `--el-space-1`, `--el-space-2`). With `styles/native.css` the input has the border, the radius, the padding, the colours, the focus ring and the three sizes of the input of `el-input-field`.
82
+
83
+ The label, the help message, the control and the error message stack in a column, and the texts have one look in every field: see [Layout](../form-field/form-field.readme.md#layout) in the readme of `form-field`.
84
+
85
+ On a touch screen (`@media (any-pointer: coarse)`) the control is at least `--el-touch-target` high. Without that token, and on a fine pointer, the sizes stay as they are.
86
+
87
+ ## Accessibility
88
+
89
+ - The control is a native text input with a list: the browser makes it a combobox for a screen reader, named by the label (`<label for>`), and announces the suggestions as it shows them.
90
+ - The keyboard is the one of the browser: the arrow keys go through the suggestions, Enter takes one, Escape closes the list.
91
+ - Without options the control is a plain text input, with no list to announce.
92
+ - It names the help message in `aria-describedby`, and the error message while that is shown, and says whether it is valid (`aria-invalid`).
93
+ - Validation messages surface only once the field is `touched`. The error message is an alert (`role="alert"`): a screen reader announces it when it appears.
@@ -0,0 +1,56 @@
1
+ import hostStyle from '../../styles/host.style.js';
2
+ import formControlStyle from '../../styles/form-control.style.js';
3
+ import sizeStyle from '../../styles/size.style.js';
4
+
5
+ const css = String.raw;
6
+
7
+ /**
8
+ * The field has the style of `el-input-field`, under its own tag: a field does not get the
9
+ * stylesheet of the class it extends.
10
+ */
11
+ const style = css`
12
+ el-combobox-field {
13
+ .field {
14
+ .validity {
15
+ .valid {
16
+ color: var(--el-color-success, green);
17
+ }
18
+
19
+ .invalid {
20
+ color: var(--el-color-danger, red);
21
+ }
22
+ }
23
+ }
24
+
25
+ /* Touch screens: the control and the clear cross are at least --el-touch-target, whatever
26
+ the size of the field. The mark beside the input keeps that width in both states, so the
27
+ input does not jump when the validity changes. Without the token the sizes stay as they
28
+ are. */
29
+ @media (any-pointer: coarse) {
30
+ input {
31
+ min-height: max(
32
+ calc(var(--el-control-height, 0px) * var(--_el-size-scale, 1)),
33
+ var(--el-touch-target, 0px)
34
+ );
35
+ }
36
+
37
+ .validity,
38
+ [data-clear-input] {
39
+ display: grid;
40
+ place-items: center;
41
+ min-width: var(--el-touch-target, auto);
42
+ }
43
+
44
+ [data-clear-input] {
45
+ min-height: var(--el-touch-target, auto);
46
+ }
47
+ }
48
+ }
49
+ `;
50
+
51
+ export default [
52
+ hostStyle('el-combobox-field'),
53
+ formControlStyle('el-combobox-field'),
54
+ sizeStyle('el-combobox-field'),
55
+ style,
56
+ ].join('\n');
@@ -0,0 +1,24 @@
1
+ # Change Log
2
+
3
+ All notable changes to this component live here. Versions refer to the parent `@webtides/element-library` release (see root [`CHANGELOG.md`](../../../CHANGELOG.md)); components no longer version independently.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/).
6
+
7
+ <!--
8
+ When your PR touches this component, add an entry under Unreleased and
9
+ mirror it (prefixed with the component name) in root CHANGELOG.md.
10
+ Uncomment headings as needed.
11
+ -->
12
+
13
+ ## Unreleased
14
+
15
+ ## [0.3.0] - 2026-11-17
16
+
17
+ ### Added
18
+
19
+ - Initial `el-copy-button`: a button that copies a text to the clipboard and says whether that worked. A native `<button>` that shows an icon and is named by `label`, "Copy" by default. ([#125](https://github.com/webtides/element-library/issues/125))
20
+ - The text is `value`, or with `from` the content of the element with that id: its `value` if it has one, its text without the white space around it otherwise. The element is read at the moment of the press.
21
+ - After a press the icon shows the outcome for `feedback-duration` milliseconds (`1500` by default), a check mark in the success colour or a cross in the danger colour, and a live region tells a screen reader (`success-label`, `error-label`). `status` is `success`, `error` or `idle`, reflected.
22
+ - `copy-button-copy` is fired with the text when it was copied, `copy-button-error` with the reason when it could not be: there was nothing to copy, the page has no clipboard, or the browser refused. `copy()` does the same from a script.
23
+ - `size` is `small`, `medium` or `large`, reflected: a square of the control height of the size, and at least `--el-touch-target` on a touch screen. `disabled` disables it.
24
+ - The slots `copy-icon`, `success-icon` and `error-icon` take other icons.
@@ -0,0 +1,3 @@
1
+ import { define } from './copy-button.js';
2
+
3
+ define();
@@ -0,0 +1,4 @@
1
+ export default {
2
+ COPY: 'copy-button-copy',
3
+ ERROR: 'copy-button-error',
4
+ };