@momentum-design/components 0.134.20 → 0.134.22

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 (390) hide show
  1. package/dist/browser/index.js +481 -458
  2. package/dist/browser/index.js.map +4 -4
  3. package/dist/components/accordion/accordion.component.d.ts +15 -5
  4. package/dist/components/accordionbutton/accordionbutton.component.d.ts +14 -26
  5. package/dist/components/accordionbutton/accordionbutton.component.js +0 -22
  6. package/dist/components/accordiongroup/accordiongroup.component.d.ts +12 -16
  7. package/dist/components/accordiongroup/accordiongroup.component.js +0 -14
  8. package/dist/components/alertchip/alertchip.component.d.ts +15 -11
  9. package/dist/components/alertchip/alertchip.component.js +0 -7
  10. package/dist/components/animation/animation.component.d.ts +14 -6
  11. package/dist/components/animation/animation.component.js +0 -5
  12. package/dist/components/announcementdialog/announcementdialog.component.d.ts +18 -25
  13. package/dist/components/announcementdialog/announcementdialog.component.js +1 -20
  14. package/dist/components/appheader/appheader.component.d.ts +13 -12
  15. package/dist/components/appheader/appheader.component.js +0 -9
  16. package/dist/components/avatar/avatar.component.d.ts +14 -34
  17. package/dist/components/avatar/avatar.component.js +1 -31
  18. package/dist/components/avatarbutton/avatarbutton.component.d.ts +15 -14
  19. package/dist/components/avatarbutton/avatarbutton.component.js +1 -10
  20. package/dist/components/badge/badge.component.d.ts +16 -20
  21. package/dist/components/badge/badge.component.js +1 -17
  22. package/dist/components/banner/banner.component.d.ts +17 -17
  23. package/dist/components/banner/banner.component.js +1 -13
  24. package/dist/components/brandvisual/brandvisual.component.d.ts +15 -12
  25. package/dist/components/brandvisual/brandvisual.component.js +0 -10
  26. package/dist/components/bullet/bullet.component.d.ts +15 -16
  27. package/dist/components/bullet/bullet.component.js +0 -15
  28. package/dist/components/button/button.component.d.ts +21 -52
  29. package/dist/components/button/button.component.js +1 -47
  30. package/dist/components/buttongroup/buttongroup.component.d.ts +17 -20
  31. package/dist/components/buttongroup/buttongroup.component.js +0 -17
  32. package/dist/components/buttonlink/buttonlink.component.d.ts +19 -16
  33. package/dist/components/buttonlink/buttonlink.component.js +1 -11
  34. package/dist/components/buttonsimple/buttonsimple.component.d.ts +16 -25
  35. package/dist/components/buttonsimple/buttonsimple.component.js +0 -22
  36. package/dist/components/calendar/calendar.component.d.ts +17 -11
  37. package/dist/components/calendar/calendar.component.js +0 -8
  38. package/dist/components/card/card.component.d.ts +18 -17
  39. package/dist/components/card/card.component.js +0 -13
  40. package/dist/components/cardbutton/cardbutton.component.d.ts +20 -14
  41. package/dist/components/cardbutton/cardbutton.component.js +0 -9
  42. package/dist/components/cardcheckbox/cardcheckbox.component.d.ts +20 -19
  43. package/dist/components/cardcheckbox/cardcheckbox.component.js +0 -14
  44. package/dist/components/cardradio/cardradio.component.d.ts +20 -20
  45. package/dist/components/cardradio/cardradio.component.js +0 -15
  46. package/dist/components/checkbox/checkbox.component.d.ts +22 -26
  47. package/dist/components/checkbox/checkbox.component.js +1 -22
  48. package/dist/components/chip/chip.component.d.ts +20 -13
  49. package/dist/components/chip/chip.component.js +0 -9
  50. package/dist/components/coachmark/coachmark.component.d.ts +22 -22
  51. package/dist/components/coachmark/coachmark.component.js +1 -18
  52. package/dist/components/combobox/combobox.component.d.ts +27 -37
  53. package/dist/components/combobox/combobox.component.js +1 -32
  54. package/dist/components/controltypeprovider/controltypeprovider.component.d.ts +19 -11
  55. package/dist/components/controltypeprovider/controltypeprovider.component.js +0 -10
  56. package/dist/components/datepicker/datepicker.component.d.ts +25 -14
  57. package/dist/components/datepicker/datepicker.component.js +96 -35
  58. package/dist/components/dialog/dialog.component.d.ts +25 -40
  59. package/dist/components/dialog/dialog.component.js +1 -35
  60. package/dist/components/divider/divider.component.d.ts +23 -25
  61. package/dist/components/divider/divider.component.js +0 -23
  62. package/dist/components/filterchip/filterchip.component.d.ts +20 -9
  63. package/dist/components/filterchip/filterchip.component.js +0 -5
  64. package/dist/components/formfieldgroup/formfieldgroup.component.d.ts +18 -19
  65. package/dist/components/formfieldgroup/formfieldgroup.component.js +0 -15
  66. package/dist/components/formfieldwrapper/formfieldwrapper.component.d.ts +16 -8
  67. package/dist/components/formfieldwrapper/formfieldwrapper.component.js +0 -4
  68. package/dist/components/icon/icon.component.d.ts +16 -41
  69. package/dist/components/icon/icon.component.js +0 -39
  70. package/dist/components/iconprovider/iconprovider.component.d.ts +14 -24
  71. package/dist/components/iconprovider/iconprovider.component.js +0 -23
  72. package/dist/components/illustration/illustration.component.d.ts +16 -32
  73. package/dist/components/illustration/illustration.component.js +0 -30
  74. package/dist/components/illustrationprovider/illustrationprovider.component.d.ts +14 -24
  75. package/dist/components/illustrationprovider/illustrationprovider.component.js +0 -23
  76. package/dist/components/input/input.component.d.ts +21 -16
  77. package/dist/components/input/input.component.js +0 -11
  78. package/dist/components/inputchip/inputchip.component.d.ts +19 -13
  79. package/dist/components/inputchip/inputchip.component.js +0 -7
  80. package/dist/components/link/link.component.d.ts +18 -12
  81. package/dist/components/link/link.component.js +1 -9
  82. package/dist/components/linkbutton/linkbutton.component.d.ts +19 -12
  83. package/dist/components/linkbutton/linkbutton.component.js +1 -8
  84. package/dist/components/linksimple/linksimple.component.d.ts +17 -10
  85. package/dist/components/linksimple/linksimple.component.js +0 -7
  86. package/dist/components/list/list.component.d.ts +17 -7
  87. package/dist/components/list/list.component.js +0 -5
  88. package/dist/components/listbox/listbox.component.d.ts +21 -16
  89. package/dist/components/listbox/listbox.component.js +1 -11
  90. package/dist/components/listheader/listheader.component.d.ts +14 -6
  91. package/dist/components/listheader/listheader.component.js +0 -3
  92. package/dist/components/listitem/listitem.component.d.ts +20 -18
  93. package/dist/components/listitem/listitem.component.js +0 -13
  94. package/dist/components/marker/marker.component.d.ts +15 -16
  95. package/dist/components/marker/marker.component.js +0 -15
  96. package/dist/components/menubar/menubar.component.d.ts +12 -19
  97. package/dist/components/menubar/menubar.component.js +2 -20
  98. package/dist/components/menuitem/menuitem.component.d.ts +18 -19
  99. package/dist/components/menuitem/menuitem.component.js +1 -15
  100. package/dist/components/menuitemcheckbox/menuitemcheckbox.component.d.ts +19 -30
  101. package/dist/components/menuitemcheckbox/menuitemcheckbox.component.js +1 -25
  102. package/dist/components/menuitemradio/menuitemradio.component.d.ts +18 -31
  103. package/dist/components/menuitemradio/menuitemradio.component.js +1 -26
  104. package/dist/components/menupopover/menupopover.component.d.ts +17 -39
  105. package/dist/components/menupopover/menupopover.component.js +4 -38
  106. package/dist/components/menusection/menusection.component.d.ts +16 -12
  107. package/dist/components/menusection/menusection.component.js +0 -8
  108. package/dist/components/navmenuitem/navmenuitem.component.d.ts +47 -16
  109. package/dist/components/navmenuitem/navmenuitem.component.js +146 -20
  110. package/dist/components/navmenuitem/navmenuitem.constants.d.ts +1 -0
  111. package/dist/components/navmenuitem/navmenuitem.constants.js +1 -0
  112. package/dist/components/navmenuitem/navmenuitem.styles.js +16 -5
  113. package/dist/components/optgroup/optgroup.component.d.ts +17 -7
  114. package/dist/components/optgroup/optgroup.component.js +1 -3
  115. package/dist/components/option/option.component.d.ts +17 -19
  116. package/dist/components/option/option.component.js +1 -15
  117. package/dist/components/password/password.component.d.ts +18 -17
  118. package/dist/components/password/password.component.js +0 -11
  119. package/dist/components/popover/popover.component.d.ts +20 -52
  120. package/dist/components/popover/popover.component.js +1 -47
  121. package/dist/components/presence/presence.component.d.ts +17 -10
  122. package/dist/components/presence/presence.component.js +1 -7
  123. package/dist/components/progressbar/progressbar.component.d.ts +17 -13
  124. package/dist/components/progressbar/progressbar.component.js +0 -9
  125. package/dist/components/progressspinner/progressspinner.component.d.ts +14 -19
  126. package/dist/components/progressspinner/progressspinner.component.js +0 -17
  127. package/dist/components/radio/radio.component.d.ts +19 -41
  128. package/dist/components/radio/radio.component.js +1 -37
  129. package/dist/components/radiogroup/radiogroup.component.d.ts +12 -5
  130. package/dist/components/radiogroup/radiogroup.component.js +0 -4
  131. package/dist/components/responsivesettingsprovider/responsivesettingsprovider.component.d.ts +11 -29
  132. package/dist/components/responsivesettingsprovider/responsivesettingsprovider.component.js +0 -29
  133. package/dist/components/screenreaderannouncer/screenreaderannouncer.component.d.ts +12 -51
  134. package/dist/components/screenreaderannouncer/screenreaderannouncer.component.js +0 -51
  135. package/dist/components/searchfield/searchfield.component.d.ts +16 -24
  136. package/dist/components/searchfield/searchfield.component.js +0 -20
  137. package/dist/components/searchpopover/searchpopover.component.d.ts +16 -20
  138. package/dist/components/searchpopover/searchpopover.component.js +0 -16
  139. package/dist/components/select/select.component.d.ts +23 -19
  140. package/dist/components/select/select.component.js +1 -14
  141. package/dist/components/selectlistbox/selectlistbox.component.d.ts +12 -8
  142. package/dist/components/selectlistbox/selectlistbox.component.js +0 -7
  143. package/dist/components/sidenavigation/sidenavigation.component.d.ts +64 -44
  144. package/dist/components/sidenavigation/sidenavigation.component.js +241 -43
  145. package/dist/components/sidenavigation/sidenavigation.constants.d.ts +6 -1
  146. package/dist/components/sidenavigation/sidenavigation.constants.js +6 -1
  147. package/dist/components/sidenavigation/sidenavigation.context.d.ts +6 -1
  148. package/dist/components/sidenavigation/sidenavigation.context.js +36 -11
  149. package/dist/components/sidenavigation/sidenavigation.types.d.ts +3 -2
  150. package/dist/components/sidenavigation/sidenavigationbase.d.ts +8 -0
  151. package/dist/components/sidenavigation/sidenavigationbase.js +7 -0
  152. package/dist/components/skeleton/skeleton.component.d.ts +14 -15
  153. package/dist/components/skeleton/skeleton.component.js +0 -13
  154. package/dist/components/slider/slider.component.d.ts +17 -15
  155. package/dist/components/slider/slider.component.js +0 -11
  156. package/dist/components/spatialnavigationprovider/spatialnavigationprovider.component.d.ts +15 -215
  157. package/dist/components/spatialnavigationprovider/spatialnavigationprovider.component.js +1 -215
  158. package/dist/components/spinner/spinner.component.d.ts +15 -27
  159. package/dist/components/spinner/spinner.component.js +0 -25
  160. package/dist/components/staticcheckbox/staticcheckbox.component.d.ts +16 -21
  161. package/dist/components/staticcheckbox/staticcheckbox.component.js +0 -17
  162. package/dist/components/staticchip/staticchip.component.d.ts +17 -8
  163. package/dist/components/staticchip/staticchip.component.js +0 -5
  164. package/dist/components/staticradio/staticradio.component.d.ts +15 -19
  165. package/dist/components/staticradio/staticradio.component.js +0 -16
  166. package/dist/components/statictoggle/statictoggle.component.d.ts +16 -21
  167. package/dist/components/statictoggle/statictoggle.component.js +0 -17
  168. package/dist/components/stepper/stepper.component.d.ts +13 -5
  169. package/dist/components/stepper/stepper.component.js +0 -3
  170. package/dist/components/stepperconnector/stepperconnector.component.d.ts +13 -6
  171. package/dist/components/stepperconnector/stepperconnector.component.js +0 -4
  172. package/dist/components/stepperitem/stepperitem.component.d.ts +16 -14
  173. package/dist/components/stepperitem/stepperitem.component.js +1 -10
  174. package/dist/components/tab/tab.component.d.ts +20 -23
  175. package/dist/components/tab/tab.component.js +1 -16
  176. package/dist/components/tablist/tablist.component.d.ts +18 -30
  177. package/dist/components/tablist/tablist.component.js +0 -24
  178. package/dist/components/text/text.component.d.ts +12 -13
  179. package/dist/components/text/text.component.js +0 -12
  180. package/dist/components/textarea/textarea.component.d.ts +17 -39
  181. package/dist/components/textarea/textarea.component.js +0 -34
  182. package/dist/components/themeprovider/themeprovider.component.d.ts +13 -27
  183. package/dist/components/themeprovider/themeprovider.component.js +0 -25
  184. package/dist/components/timepicker/timepicker.component.d.ts +17 -19
  185. package/dist/components/timepicker/timepicker.component.js +0 -14
  186. package/dist/components/toast/toast.component.d.ts +20 -12
  187. package/dist/components/toast/toast.component.js +1 -7
  188. package/dist/components/toggle/toggle.component.d.ts +18 -24
  189. package/dist/components/toggle/toggle.component.js +1 -21
  190. package/dist/components/toggletip/toggletip.component.d.ts +18 -28
  191. package/dist/components/toggletip/toggletip.component.js +1 -24
  192. package/dist/components/tooltip/tooltip.component.d.ts +16 -16
  193. package/dist/components/tooltip/tooltip.component.js +0 -13
  194. package/dist/components/typewriter/typewriter.component.d.ts +18 -34
  195. package/dist/components/typewriter/typewriter.component.js +1 -31
  196. package/dist/components/verticaltablist/verticaltablist.component.d.ts +17 -30
  197. package/dist/components/verticaltablist/verticaltablist.component.js +0 -26
  198. package/dist/components/virtualizedlist/virtualizedlist.component.d.ts +16 -58
  199. package/dist/components/virtualizedlist/virtualizedlist.component.js +0 -55
  200. package/dist/custom-elements.json +334 -191
  201. package/dist/models/provider/provider.component.d.ts +2 -2
  202. package/dist/models/provider/provider.component.js +13 -0
  203. package/dist/react/accordion/index.d.ts +15 -5
  204. package/dist/react/accordionbutton/index.d.ts +14 -26
  205. package/dist/react/accordionbutton/index.js +0 -22
  206. package/dist/react/accordiongroup/index.d.ts +12 -16
  207. package/dist/react/accordiongroup/index.js +0 -14
  208. package/dist/react/alertchip/index.d.ts +15 -11
  209. package/dist/react/alertchip/index.js +0 -7
  210. package/dist/react/animation/index.d.ts +14 -6
  211. package/dist/react/animation/index.js +0 -5
  212. package/dist/react/announcementdialog/index.d.ts +18 -25
  213. package/dist/react/announcementdialog/index.js +1 -20
  214. package/dist/react/appheader/index.d.ts +13 -12
  215. package/dist/react/appheader/index.js +0 -9
  216. package/dist/react/avatar/index.d.ts +14 -34
  217. package/dist/react/avatar/index.js +1 -31
  218. package/dist/react/avatarbutton/index.d.ts +15 -14
  219. package/dist/react/avatarbutton/index.js +1 -10
  220. package/dist/react/badge/index.d.ts +16 -20
  221. package/dist/react/badge/index.js +1 -17
  222. package/dist/react/banner/index.d.ts +17 -17
  223. package/dist/react/banner/index.js +1 -13
  224. package/dist/react/brandvisual/index.d.ts +15 -12
  225. package/dist/react/brandvisual/index.js +0 -10
  226. package/dist/react/bullet/index.d.ts +15 -16
  227. package/dist/react/bullet/index.js +0 -15
  228. package/dist/react/button/index.d.ts +21 -52
  229. package/dist/react/button/index.js +1 -47
  230. package/dist/react/buttongroup/index.d.ts +17 -20
  231. package/dist/react/buttongroup/index.js +0 -17
  232. package/dist/react/buttonlink/index.d.ts +19 -16
  233. package/dist/react/buttonlink/index.js +1 -11
  234. package/dist/react/buttonsimple/index.d.ts +16 -25
  235. package/dist/react/buttonsimple/index.js +0 -22
  236. package/dist/react/calendar/index.d.ts +17 -11
  237. package/dist/react/calendar/index.js +0 -8
  238. package/dist/react/card/index.d.ts +18 -17
  239. package/dist/react/card/index.js +0 -13
  240. package/dist/react/cardbutton/index.d.ts +20 -14
  241. package/dist/react/cardbutton/index.js +0 -9
  242. package/dist/react/cardcheckbox/index.d.ts +20 -19
  243. package/dist/react/cardcheckbox/index.js +0 -14
  244. package/dist/react/cardradio/index.d.ts +20 -20
  245. package/dist/react/cardradio/index.js +0 -15
  246. package/dist/react/checkbox/index.d.ts +22 -26
  247. package/dist/react/checkbox/index.js +1 -22
  248. package/dist/react/chip/index.d.ts +20 -13
  249. package/dist/react/chip/index.js +0 -9
  250. package/dist/react/coachmark/index.d.ts +22 -22
  251. package/dist/react/coachmark/index.js +1 -18
  252. package/dist/react/combobox/index.d.ts +27 -37
  253. package/dist/react/combobox/index.js +1 -32
  254. package/dist/react/controltypeprovider/index.d.ts +19 -11
  255. package/dist/react/controltypeprovider/index.js +0 -10
  256. package/dist/react/datepicker/index.d.ts +20 -14
  257. package/dist/react/datepicker/index.js +0 -9
  258. package/dist/react/dialog/index.d.ts +25 -40
  259. package/dist/react/dialog/index.js +1 -35
  260. package/dist/react/divider/index.d.ts +23 -25
  261. package/dist/react/divider/index.js +0 -23
  262. package/dist/react/filterchip/index.d.ts +20 -9
  263. package/dist/react/filterchip/index.js +0 -5
  264. package/dist/react/formfieldgroup/index.d.ts +18 -19
  265. package/dist/react/formfieldgroup/index.js +0 -15
  266. package/dist/react/formfieldwrapper/index.d.ts +16 -8
  267. package/dist/react/formfieldwrapper/index.js +0 -4
  268. package/dist/react/icon/index.d.ts +16 -41
  269. package/dist/react/icon/index.js +0 -39
  270. package/dist/react/iconprovider/index.d.ts +14 -24
  271. package/dist/react/iconprovider/index.js +0 -23
  272. package/dist/react/illustration/index.d.ts +16 -32
  273. package/dist/react/illustration/index.js +0 -30
  274. package/dist/react/illustrationprovider/index.d.ts +14 -24
  275. package/dist/react/illustrationprovider/index.js +0 -23
  276. package/dist/react/input/index.d.ts +21 -16
  277. package/dist/react/input/index.js +0 -11
  278. package/dist/react/inputchip/index.d.ts +19 -13
  279. package/dist/react/inputchip/index.js +0 -7
  280. package/dist/react/link/index.d.ts +18 -12
  281. package/dist/react/link/index.js +1 -9
  282. package/dist/react/linkbutton/index.d.ts +19 -12
  283. package/dist/react/linkbutton/index.js +1 -8
  284. package/dist/react/linksimple/index.d.ts +17 -10
  285. package/dist/react/linksimple/index.js +0 -7
  286. package/dist/react/list/index.d.ts +17 -7
  287. package/dist/react/list/index.js +0 -5
  288. package/dist/react/listbox/index.d.ts +21 -16
  289. package/dist/react/listbox/index.js +1 -11
  290. package/dist/react/listheader/index.d.ts +14 -6
  291. package/dist/react/listheader/index.js +0 -3
  292. package/dist/react/listitem/index.d.ts +20 -18
  293. package/dist/react/listitem/index.js +0 -13
  294. package/dist/react/marker/index.d.ts +15 -16
  295. package/dist/react/marker/index.js +0 -15
  296. package/dist/react/menubar/index.d.ts +12 -19
  297. package/dist/react/menubar/index.js +0 -19
  298. package/dist/react/menuitem/index.d.ts +18 -19
  299. package/dist/react/menuitem/index.js +1 -15
  300. package/dist/react/menuitemcheckbox/index.d.ts +19 -30
  301. package/dist/react/menuitemcheckbox/index.js +1 -25
  302. package/dist/react/menuitemradio/index.d.ts +18 -31
  303. package/dist/react/menuitemradio/index.js +1 -26
  304. package/dist/react/menupopover/index.d.ts +16 -38
  305. package/dist/react/menupopover/index.js +0 -34
  306. package/dist/react/menusection/index.d.ts +16 -12
  307. package/dist/react/menusection/index.js +0 -8
  308. package/dist/react/navmenuitem/index.d.ts +19 -16
  309. package/dist/react/navmenuitem/index.js +3 -12
  310. package/dist/react/optgroup/index.d.ts +17 -7
  311. package/dist/react/optgroup/index.js +1 -3
  312. package/dist/react/option/index.d.ts +17 -19
  313. package/dist/react/option/index.js +1 -15
  314. package/dist/react/password/index.d.ts +18 -17
  315. package/dist/react/password/index.js +0 -11
  316. package/dist/react/popover/index.d.ts +20 -52
  317. package/dist/react/popover/index.js +1 -47
  318. package/dist/react/presence/index.d.ts +17 -10
  319. package/dist/react/presence/index.js +1 -7
  320. package/dist/react/progressbar/index.d.ts +17 -13
  321. package/dist/react/progressbar/index.js +0 -9
  322. package/dist/react/progressspinner/index.d.ts +14 -19
  323. package/dist/react/progressspinner/index.js +0 -17
  324. package/dist/react/radio/index.d.ts +19 -41
  325. package/dist/react/radio/index.js +1 -37
  326. package/dist/react/radiogroup/index.d.ts +12 -5
  327. package/dist/react/radiogroup/index.js +0 -4
  328. package/dist/react/responsivesettingsprovider/index.d.ts +11 -29
  329. package/dist/react/responsivesettingsprovider/index.js +0 -29
  330. package/dist/react/screenreaderannouncer/index.d.ts +12 -51
  331. package/dist/react/screenreaderannouncer/index.js +0 -51
  332. package/dist/react/searchfield/index.d.ts +16 -24
  333. package/dist/react/searchfield/index.js +0 -20
  334. package/dist/react/searchpopover/index.d.ts +16 -20
  335. package/dist/react/searchpopover/index.js +0 -16
  336. package/dist/react/select/index.d.ts +23 -19
  337. package/dist/react/select/index.js +1 -14
  338. package/dist/react/selectlistbox/index.d.ts +12 -8
  339. package/dist/react/selectlistbox/index.js +0 -7
  340. package/dist/react/sidenavigation/index.d.ts +21 -41
  341. package/dist/react/sidenavigation/index.js +1 -35
  342. package/dist/react/skeleton/index.d.ts +14 -15
  343. package/dist/react/skeleton/index.js +0 -13
  344. package/dist/react/slider/index.d.ts +17 -15
  345. package/dist/react/slider/index.js +0 -11
  346. package/dist/react/spatialnavigationprovider/index.d.ts +15 -215
  347. package/dist/react/spatialnavigationprovider/index.js +1 -214
  348. package/dist/react/spinner/index.d.ts +15 -27
  349. package/dist/react/spinner/index.js +0 -25
  350. package/dist/react/staticcheckbox/index.d.ts +16 -21
  351. package/dist/react/staticcheckbox/index.js +0 -17
  352. package/dist/react/staticchip/index.d.ts +17 -8
  353. package/dist/react/staticchip/index.js +0 -5
  354. package/dist/react/staticradio/index.d.ts +15 -19
  355. package/dist/react/staticradio/index.js +0 -16
  356. package/dist/react/statictoggle/index.d.ts +16 -21
  357. package/dist/react/statictoggle/index.js +0 -17
  358. package/dist/react/stepper/index.d.ts +13 -5
  359. package/dist/react/stepper/index.js +0 -3
  360. package/dist/react/stepperconnector/index.d.ts +13 -6
  361. package/dist/react/stepperconnector/index.js +0 -4
  362. package/dist/react/stepperitem/index.d.ts +16 -14
  363. package/dist/react/stepperitem/index.js +1 -10
  364. package/dist/react/tab/index.d.ts +20 -23
  365. package/dist/react/tab/index.js +1 -16
  366. package/dist/react/tablist/index.d.ts +18 -30
  367. package/dist/react/tablist/index.js +0 -24
  368. package/dist/react/text/index.d.ts +12 -13
  369. package/dist/react/text/index.js +0 -12
  370. package/dist/react/textarea/index.d.ts +17 -39
  371. package/dist/react/textarea/index.js +0 -34
  372. package/dist/react/themeprovider/index.d.ts +13 -27
  373. package/dist/react/themeprovider/index.js +0 -25
  374. package/dist/react/timepicker/index.d.ts +17 -19
  375. package/dist/react/timepicker/index.js +0 -14
  376. package/dist/react/toast/index.d.ts +20 -12
  377. package/dist/react/toast/index.js +1 -7
  378. package/dist/react/toggle/index.d.ts +18 -24
  379. package/dist/react/toggle/index.js +1 -21
  380. package/dist/react/toggletip/index.d.ts +18 -28
  381. package/dist/react/toggletip/index.js +1 -24
  382. package/dist/react/tooltip/index.d.ts +16 -16
  383. package/dist/react/tooltip/index.js +0 -13
  384. package/dist/react/typewriter/index.d.ts +18 -34
  385. package/dist/react/typewriter/index.js +1 -31
  386. package/dist/react/verticaltablist/index.d.ts +17 -30
  387. package/dist/react/verticaltablist/index.js +0 -26
  388. package/dist/react/virtualizedlist/index.d.ts +16 -58
  389. package/dist/react/virtualizedlist/index.js +0 -55
  390. package/package.json +1 -1
@@ -3,27 +3,34 @@ import Buttonsimple from '../buttonsimple/buttonsimple.component';
3
3
  import type { ColorType } from '../staticchip/staticchip.types';
4
4
  declare const Chip_base: import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/IconNameMixin").IconNameMixinInterface> & typeof Buttonsimple;
5
5
  /**
6
- * mdc-chip is an interactive element that can be used to represent a chip. It supports a leading icon along with label.
7
- * Consumers can wrap this component around a tooltip to provide additional context.
8
- *
9
- * It is recommended to keep the label text for the chip component concise and compact.<br/>
10
- * For best results, we recommend limiting the <b>maximum length of the label text to 20 characters</b>,
11
- * including empty spaces to split words.
12
- *
13
- * This component is built by extending `Buttonsimple`.
14
- *
6
+ * The chip is a compact interactive surface that renders an optional leading icon and a short label. It behaves like a button (single tap or `Enter`/`Space` activation, focus, hover, and disabled states) and is commonly used to represent a tag, attribute, filter trigger, or quick action.
7
+ *
8
+ * Keep the label short — we recommend a maximum of **20 characters** (including spaces). Chips can be connected to an `mdc-tooltip` (via the tooltip's `triggerid` pointing at the chip's `id`) to surface additional context when the label is truncated or needs explanation.
9
+ *
10
+ * **When to use**
11
+ *
12
+ * - Use `mdc-chip` to represent an attribute, tag, or quick action that fits in a single, short word or phrase.
13
+ * - Use it inside a horizontal row or wrap of chips when several short actions or attributes share the same visual weight.
14
+ *
15
+ * **When not to use**
16
+ *
17
+ * - Use `mdc-button` when the action needs more visual weight, more text, or icon-only treatment beyond a compact tag.
18
+ * - Use `mdc-filterchip` when the chip should reflect an applied filter that can be toggled and removed.
19
+ * - Use `mdc-alertchip` when the chip should communicate a status (information, warning, error) rather than trigger an action.
20
+ * - Use `mdc-staticchip` when the chip is purely decorative and should not be interactive (e.g. inside a list item that owns the click target).
21
+ *
15
22
  * @tagname mdc-chip
16
- *
23
+ *
17
24
  * @dependency mdc-icon
18
25
  * @dependency mdc-text
19
- *
26
+ *
20
27
  * @cssproperty --mdc-chip-color - The color of the chip.
21
28
  * @cssproperty --mdc-chip-border-color - The border color of the chip.
22
29
  * @cssproperty --mdc-chip-background-color - The background color of the chip.
23
- *
30
+ *
24
31
  * @csspart icon - The icon part of the chip.
25
32
  * @csspart label - The label part of the chip.
26
- *
33
+ *
27
34
  * @event click - (React: onClick) This event is dispatched when the chip is clicked.
28
35
  * @event keydown - (React: onKeyDown) This event is dispatched when a key is pressed down on the chip.
29
36
  * @event keyup - (React: onKeyUp) This event is dispatched when a key is released on the chip.
@@ -15,15 +15,6 @@ import StaticChip from '../staticchip/staticchip.component';
15
15
  import { DEFAULTS } from './chip.constants';
16
16
  import styles from './chip.styles';
17
17
  /**
18
- * mdc-chip is an interactive element that can be used to represent a chip. It supports a leading icon along with label.
19
- * Consumers can wrap this component around a tooltip to provide additional context.
20
- *
21
- * It is recommended to keep the label text for the chip component concise and compact.<br/>
22
- * For best results, we recommend limiting the <b>maximum length of the label text to 20 characters</b>,
23
- * including empty spaces to split words.
24
- *
25
- * This component is built by extending `Buttonsimple`.
26
- *
27
18
  * @tagname mdc-chip
28
19
  *
29
20
  * @dependency mdc-icon
@@ -1,33 +1,33 @@
1
1
  import Popover from '../popover/popover.component';
2
2
  import type { PopoverTrigger } from '../popover/popover.types';
3
3
  /**
4
- * A Coachmark is a contextual guidance component used to highlight a specific UI element and explain its purpose or functionality.
5
- * It is typically shown as part of onboarding, feature discovery, or progressive education within the product.
6
- *
7
- * Coachmark component based on top of the popover component,
8
- * with the default value of certain properties changed.
9
- * Coachmark component will always have an arrow attached to it.
10
- * The color of the coachmark is contrast.
11
- *
12
- * ## When to use
13
- * - Introducing a new or complex feature to users.
14
- * - Drawing attention to a UI element that might otherwise be missed.
15
- * - Providing step-by-step guidance in an onboarding or walkthrough flow.
16
- *
17
- * ## Accessibility
18
- * - The default role of coachmark is `"dialog"`, which can be changed via the `role` attribute.
19
- * - aria-label or aria-labelledby can be provided to give the coachmark an accessible name.
20
- *
21
- * @dependency mdc-popover
22
- *
4
+ * A coachmark is a contextual guidance overlay used to highlight a specific UI element and explain its purpose. It is typically shown as part of onboarding, feature discovery, or step-by-step walkthroughs.
5
+ *
6
+ * It renders as a high-contrast bubble anchored to a trigger element with a visible arrow and a close button. Unlike a tooltip, the coachmark stays open until the user dismisses it (or the consumer toggles it programmatically), making it suitable for explanatory copy rather than a quick hover hint.
7
+ *
8
+ * **When to use**
9
+ *
10
+ * - Introducing a new or complex feature when users land on a screen for the first time.
11
+ * - Drawing attention to a UI element that might otherwise be overlooked (a secondary action, a settings entry point).
12
+ * - Providing step-by-step guidance in an onboarding flow or guided tour.
13
+ *
14
+ * **When not to use**
15
+ *
16
+ * - Use `mdc-tooltip` for a short, hover-triggered hint about a control that does not need a close affordance.
17
+ * - Use `mdc-toggletip` when a small piece of contextual help should appear on click and dismiss on outside interaction without a persistent step-flow.
18
+ * - Use `mdc-popover` directly when a generic dismissible overlay is needed and the onboarding-styled contrast bubble + arrow + close button defaults are not desired.
19
+ * - Use `mdc-dialog` (or `mdc-announcementdialog`) when the message is modal, must block the rest of the UI, or is not anchored to a specific element.
20
+ *
23
21
  * @tagname mdc-coachmark
24
- *
22
+ *
23
+ * @dependency mdc-popover
24
+ *
25
25
  * @event shown - (React: onShown) This event is dispatched when the coachmark is shown
26
26
  * @event hidden - (React: onHidden) This event is dispatched when the coachmark is hidden
27
27
  * @event created - (React: onCreated) This event is dispatched when the coachmark is created (added to the DOM)
28
28
  * @event destroyed - (React: onDestroyed) This event is dispatched when the coachmark is
29
29
  * destroyed (removed from the DOM)
30
- *
30
+ *
31
31
  * @cssproperty --mdc-popover-arrow-border-radius - radius of the arrow border
32
32
  * @cssproperty --mdc-popover-arrow-border - border of the arrow
33
33
  * @cssproperty --mdc-popover-primary-background-color - primary background color of the popover
@@ -36,7 +36,7 @@ import type { PopoverTrigger } from '../popover/popover.types';
36
36
  * @cssproperty --mdc-popover-inverted-border-color - inverted border color of the popover
37
37
  * @cssproperty --mdc-popover-inverted-text-color - inverted text color of the popover
38
38
  * @cssproperty --mdc-popover-elevation-3 - elevation of the popover
39
- *
39
+ *
40
40
  * @slot - Default slot for modal container
41
41
  */
42
42
  declare class Coachmark extends Popover {
@@ -11,27 +11,10 @@ import { property } from 'lit/decorators.js';
11
11
  import Popover from '../popover/popover.component';
12
12
  import { DEFAULTS } from './coachmark.constants';
13
13
  /**
14
- * A Coachmark is a contextual guidance component used to highlight a specific UI element and explain its purpose or functionality.
15
- * It is typically shown as part of onboarding, feature discovery, or progressive education within the product.
16
- *
17
- * Coachmark component based on top of the popover component,
18
- * with the default value of certain properties changed.
19
- * Coachmark component will always have an arrow attached to it.
20
- * The color of the coachmark is contrast.
21
- *
22
- * ## When to use
23
- * - Introducing a new or complex feature to users.
24
- * - Drawing attention to a UI element that might otherwise be missed.
25
- * - Providing step-by-step guidance in an onboarding or walkthrough flow.
26
- *
27
- * ## Accessibility
28
- * - The default role of coachmark is `"dialog"`, which can be changed via the `role` attribute.
29
- * - aria-label or aria-labelledby can be provided to give the coachmark an accessible name.
14
+ * @tagname mdc-coachmark
30
15
  *
31
16
  * @dependency mdc-popover
32
17
  *
33
- * @tagname mdc-coachmark
34
- *
35
18
  * @event shown - (React: onShown) This event is dispatched when the coachmark is shown
36
19
  * @event hidden - (React: onHidden) This event is dispatched when the coachmark is hidden
37
20
  * @event created - (React: onCreated) This event is dispatched when the coachmark is created (added to the DOM)
@@ -6,57 +6,47 @@ import type { PopoverStrategy } from '../popover/popover.types';
6
6
  import type { ComboboxFilter, Placement } from './combobox.types';
7
7
  declare const Combobox_base: import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/KeyDownHandledMixin").KeyDownHandledMixinInterface> & import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/KeyToActionMixin").KeyToActionInterface> & import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/lifecycle/CaptureDestroyEventForChildElement").CaptureDestroyEventForChildElementInterface> & import("../../utils/mixins/index.types").Constructor<import("../../models").Component & import("../../utils/mixins/AutoFocusOnMountMixin").AutoFocusOnMountMixinInterface> & import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/FormInternalsMixin").FormInternalsMixinInterface> & import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/DataAriaLabelMixin").DataAriaLabelMixinInterface> & import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/ControlTypeMixin").ControlTypeMixinInterface> & typeof FormfieldWrapper;
8
8
  /**
9
- * The Combobox component is a text-based dropdown control that allows users to select an option from a predefined list.
10
- * Users can type text to filter the options and select their desired choice.
11
- *
12
- * When the user starts typing, the filter uses a "starts with" search and displays options based on the text entered by the user.
13
- * If the user entered text that doesn't match with any of the options, then the text in the `no-result-text` attribute will be displayed.
14
- *
15
- * The `filter` attribute controls how options are narrowed as the user types.
16
- * The default `'match-starts-with'` strategy shows options whose label starts with the typed text.
17
- * Setting `filter="none"` disables internal filtering, which is useful when the consumer manages
18
- * filtering externally (e.g., fetching results from an API) and dynamically updates the slotted options.
19
- * A custom function can also be provided via the `filter` property for full control over the logic.
20
- *
21
- * If there is no text in the `no-result-text` attribute then nothing will be shown.
22
- *
23
- * Combobox is designed to work with `mdc-option` for individual options and `mdc-optgroup` for grouping related options.
24
- * The component ensures accessibility and usability while handling various use cases, including long text truncation with tooltip support.
25
- *
26
- * Every mdc-option should have a `value` attribute set to ensure proper form submission.
27
- *
28
- * To set a default option, use the `selected` attribute on the `mdc-option` element.
29
- *
30
- * When the combobox `control-type` attribute is "controlled", then the value should be set by the parent only, and the combobox will emit `change` and `input` events
31
- * with the selected option details when the user makes a selection or types in the input, but it won't update the selected value internally.
32
- * The parent component is expected to listen to these events and update the `value` property of the combobox accordingly to reflect the changes in the UI.
33
- *
34
- * **Note:** Make sure to add `mdc-selectlistbox` as a child of `mdc-combobox` and wrap options/optgroup in it to ensure proper accessibility functionality. Read more about it in SelectListBox documentation.
35
- *
36
- * If you need to use `mdc-tooltip` with any options, make sure to place the tooltip component outside the `mdc-selectlistbox` element. Read more about it in Options documentation.
37
- *
38
- * To understand more about combobox and its patterns, refer to this [WCAG example](https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-autocomplete-list/).
39
- *
9
+ * The combobox is a text-based dropdown control that lets the user type to filter a predefined list of options, then pick one. Typing narrows the visible options based on the configured `filter` strategy; clicking the trigger button or pressing arrow keys opens the dropdown without filtering.
10
+ *
11
+ * The component is form-associated and participates in native form submission, validation, and reset.
12
+ *
13
+ * It is designed to be used with `mdc-option` (individual options) and `mdc-optgroup` (grouped options) placed inside an `mdc-selectlistbox` slotted child — `mdc-selectlistbox` owns the `role="listbox"` and is required for correct screen-reader behaviour.
14
+ *
15
+ * When the consumer needs to drive the value externally (e.g. server-side filtering), set `control-type="controlled"` on a wrapping `mdc-controltypeprovider` (or use `filter="none"`): the combobox will emit `input` and `change` events but will not mutate its own `value` — the parent component is expected to update `value` to reflect the selection.
16
+ *
17
+ * **When to use**
18
+ *
19
+ * - Use `mdc-combobox` when the user must pick a single value from a long list and typing to filter is faster than scanning.
20
+ * - Use it when a predictive "starts with" filter (or a custom filter function) genuinely helps the user — short lists rarely justify a combobox.
21
+ * - Use it when the option list is fetched dynamically (set `filter="none"` and update slotted options as data arrives).
22
+ *
23
+ * **When not to use**
24
+ *
25
+ * - Use `mdc-select` when the user should only pick from a fixed list without typing.
26
+ * - Use `mdc-searchfield` when the user is searching for content rather than picking a single value from a known set.
27
+ * - Use `mdc-input` when free-form text is the goal and no constrained option list applies.
28
+ * - Use `mdc-radiogroup` when there are only a handful of options and they should all be visible at once.
29
+ *
30
+ * @tagname mdc-combobox
31
+ *
40
32
  * @dependency mdc-buttonsimple
41
33
  * @dependency mdc-icon
42
34
  * @dependency mdc-input
43
35
  * @dependency mdc-listitem
44
36
  * @dependency mdc-popover
45
- *
46
- * @tagname mdc-combobox
47
- *
37
+ *
48
38
  * @slot default - This is a default/unnamed slot for Selectlistbox including options and/or option group.
49
39
  * @slot label - Slot for the label element. If not provided, the `label` property will be used to render the label.
50
40
  * @slot toggletip - Slot for the toggletip info icon button. If not provided, the `toggletip-text` property will be used to render the info icon button and toggletip.
51
41
  * @slot help-icon - Slot for the helper/validation icon. If not provided, the icon will be rendered based on the `helpTextType` property.
52
42
  * @slot help-text - Slot for the helper/validation text. If not provided, the `helpText` property will be used to render the helper/validation text.
53
- *
43
+ *
54
44
  * @event click - (React: onClick) This event is dispatched when the combobox is clicked.
55
45
  * @event change - (React: onChange) This event is dispatched when the combobox is changed.
56
46
  * @event input - (React: onInput) This event is dispatched when the combobox is changed.
57
47
  * @event keydown - (React: onKeyDown) This event is dispatched when a key is pressed down on the combobox.
58
48
  * @event focus - (React: onFocus) This event is dispatched when the combobox receives focus.
59
- *
49
+ *
60
50
  * @cssproperty --mdc-combobox-border-color - The border color of the combobox
61
51
  * @cssproperty --mdc-combobox-height - The height of the combobox trigger control
62
52
  * @cssproperty --mdc-combobox-icon-color - The icon color of the combobox
@@ -73,7 +63,7 @@ declare const Combobox_base: import("../../utils/mixins/index.types").Constructo
73
63
  * @cssproperty --mdc-help-text-line-height - Line height for the help text.
74
64
  * @cssproperty --mdc-help-text-color - Color for the help text.
75
65
  * @cssproperty --mdc-required-indicator-color - Color for the required indicator text.
76
- *
66
+ *
77
67
  * @csspart label - The label element.
78
68
  * @csspart label-text - The container for the label and required indicator elements.
79
69
  * @csspart required-indicator - The required indicator element that is displayed next to the label when the `required` property is set to true.
@@ -34,36 +34,7 @@ import { AUTOCOMPLETE_LIST, FILTER, ICON_NAME, TRIGGER_ID } from './combobox.con
34
34
  import { ComboboxEventManager } from './combobox.events';
35
35
  import styles from './combobox.styles';
36
36
  /**
37
- * The Combobox component is a text-based dropdown control that allows users to select an option from a predefined list.
38
- * Users can type text to filter the options and select their desired choice.
39
- *
40
- * When the user starts typing, the filter uses a "starts with" search and displays options based on the text entered by the user.
41
- * If the user entered text that doesn't match with any of the options, then the text in the `no-result-text` attribute will be displayed.
42
- *
43
- * The `filter` attribute controls how options are narrowed as the user types.
44
- * The default `'match-starts-with'` strategy shows options whose label starts with the typed text.
45
- * Setting `filter="none"` disables internal filtering, which is useful when the consumer manages
46
- * filtering externally (e.g., fetching results from an API) and dynamically updates the slotted options.
47
- * A custom function can also be provided via the `filter` property for full control over the logic.
48
- *
49
- * If there is no text in the `no-result-text` attribute then nothing will be shown.
50
- *
51
- * Combobox is designed to work with `mdc-option` for individual options and `mdc-optgroup` for grouping related options.
52
- * The component ensures accessibility and usability while handling various use cases, including long text truncation with tooltip support.
53
- *
54
- * Every mdc-option should have a `value` attribute set to ensure proper form submission.
55
- *
56
- * To set a default option, use the `selected` attribute on the `mdc-option` element.
57
- *
58
- * When the combobox `control-type` attribute is "controlled", then the value should be set by the parent only, and the combobox will emit `change` and `input` events
59
- * with the selected option details when the user makes a selection or types in the input, but it won't update the selected value internally.
60
- * The parent component is expected to listen to these events and update the `value` property of the combobox accordingly to reflect the changes in the UI.
61
- *
62
- * **Note:** Make sure to add `mdc-selectlistbox` as a child of `mdc-combobox` and wrap options/optgroup in it to ensure proper accessibility functionality. Read more about it in SelectListBox documentation.
63
- *
64
- * If you need to use `mdc-tooltip` with any options, make sure to place the tooltip component outside the `mdc-selectlistbox` element. Read more about it in Options documentation.
65
- *
66
- * To understand more about combobox and its patterns, refer to this [WCAG example](https://www.w3.org/WAI/ARIA/apg/patterns/combobox/examples/combobox-autocomplete-list/).
37
+ * @tagname mdc-combobox
67
38
  *
68
39
  * @dependency mdc-buttonsimple
69
40
  * @dependency mdc-icon
@@ -71,8 +42,6 @@ import styles from './combobox.styles';
71
42
  * @dependency mdc-listitem
72
43
  * @dependency mdc-popover
73
44
  *
74
- * @tagname mdc-combobox
75
- *
76
45
  * @slot default - This is a default/unnamed slot for Selectlistbox including options and/or option group.
77
46
  * @slot label - Slot for the label element. If not provided, the `label` property will be used to render the label.
78
47
  * @slot toggletip - Slot for the toggletip info icon button. If not provided, the `toggletip-text` property will be used to render the info icon button and toggletip.
@@ -1,18 +1,26 @@
1
1
  import { Provider } from '../../models';
2
2
  import type { ControlType } from './controltypeprovider.types';
3
3
  /**
4
- * ContolTypeProvider component, which allows to be consumed from sub components
5
- * (see `providerUtils.consume` for how to consume)
6
- *
7
- * attribute 'control-type' sets the default control type for all consumers
8
- - 'controlled' the consumer component will not handle any interaction itself, e.g. toggling a checkbox.
9
- - 'uncontrolled' the consumer component will handle interactions
10
- *
11
- * ControlTypeMixin allows components to consume this context
12
- * note that this is intended to be set once, ControlTypeMixin will not update on changes to control-type
13
- *
4
+ * The control type provider is a context provider used to set whether descendant form controls operate as **controlled** or **uncontrolled** components.
5
+ *
6
+ * - `uncontrolled` (default) — each control manages its own state. Toggling a checkbox, picking a combobox option, or moving a slider updates the control's internal value and dispatches a `change` event.
7
+ * - `controlled` — each control delegates state to its parent. The control emits `input` and `change` with the requested new value but does not update its own value; the parent component is expected to update the control's `value` attribute in response.
8
+ *
9
+ * This mirrors the React controlled/uncontrolled pattern at the web-component level so the same component can be embedded in either consumer style without forking the API.
10
+ *
11
+ * It is rendered as a transparent wrapper — the provider does not produce any visible UI.
12
+ *
13
+ * **When to use**
14
+ *
15
+ * - Wrap a tree of form controls (combobox, select, checkbox, etc.) in `mdc-controltypeprovider control-type="controlled"` when the parent owns the canonical state and the controls must always reflect what the parent passes in.
16
+ * - Use it when integrating with state-management libraries (React, Redux, signals, etc.) that need every user interaction to flow through the consumer's update cycle.
17
+ *
18
+ * **When not to use**
19
+ *
20
+ * - Leave the provider out (or rely on the default `uncontrolled`) when each control should own its own state and the consumer just listens to `change`.
21
+ * - Do not nest providers to switch modes mid-tree unless absolutely necessary — descendant controls subscribe to the context once and do not re-subscribe when the value changes.
22
+ *
14
23
  * @tagname mdc-controltypeprovider
15
- *
16
24
  */
17
25
  declare class ControlTypeProvider extends Provider<ControlType> {
18
26
  constructor();
@@ -12,16 +12,6 @@ import { Provider } from '../../models';
12
12
  import ControlTypeProviderContext from './controltypeprovider.context';
13
13
  import { DEFAULTS, VALID_VALUES } from './controltypeprovider.constants';
14
14
  /**
15
- * ContolTypeProvider component, which allows to be consumed from sub components
16
- * (see `providerUtils.consume` for how to consume)
17
- *
18
- * attribute 'control-type' sets the default control type for all consumers
19
- - 'controlled' the consumer component will not handle any interaction itself, e.g. toggling a checkbox.
20
- - 'uncontrolled' the consumer component will handle interactions
21
- *
22
- * ControlTypeMixin allows components to consume this context
23
- * note that this is intended to be set once, ControlTypeMixin will not update on changes to control-type
24
- *
25
15
  * @tagname mdc-controltypeprovider
26
16
  *
27
17
  */
@@ -6,40 +6,46 @@ import type { SelectionMode } from '../calendar/calendar.types';
6
6
  import type { DatePickerVariant, Placement } from './datepicker.types';
7
7
  declare const DatePicker_base: import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/FormInternalsMixin").FormInternalsMixinInterface> & import("../../utils/mixins/index.types").Constructor<import("../../utils/mixins/DataAriaLabelMixin").DataAriaLabelMixinInterface> & typeof FormfieldWrapper;
8
8
  /**
9
- * mdc-datepicker is a component that allows users to select a date
10
- * or enter a date manually. It supports two variants:
11
- *
12
- * - `input`: Manual date entry with spinbutton inputs for month, day, and year
13
- * - `default`: A select-like trigger that opens a calendar for date range selection
14
- *
15
- * The component uses `mdc-calendar` inside a popover for date selection
16
- * and supports localization via a BCP 47 locale string.
17
- *
9
+ * The datepicker lets users pick a date either by typing it directly into month/day/year spinbutton fields or by opening an `mdc-calendar` inside a popover. It supports BCP 47 locale strings to drive field order, separators, placeholders, and localised accessible labels.
10
+ *
11
+ * The component is form-associated and participates in native form submission, validation, and reset. When a range or week is selected, both the start (`value`) and end (`end-value`) dates are submitted together using the configured `name`.
12
+ *
13
+ * **When to use**
14
+ *
15
+ * - Use `mdc-datepicker` with `variant="input"` when the user typically knows the date and entering it digit-by-digit is fastest.
16
+ * - Use `mdc-datepicker` with `variant="default"` when picking from a calendar (range or week) is the primary interaction.
17
+ * - Use it when the value needs to be locale-aware (field order, separator, formatting) and accessible to spinbutton-aware screen readers.
18
+ *
19
+ * **When not to use**
20
+ *
21
+ * - Use `mdc-input` when free-form text is the goal and date semantics are not required.
22
+ * - Use `mdc-calendar` directly when the calendar should always be visible (e.g. embedded in a sidebar) without a popover trigger.
23
+ *
18
24
  * @tagname mdc-datepicker
19
- *
25
+ *
20
26
  * @dependency mdc-button
21
27
  * @dependency mdc-calendar
22
28
  * @dependency mdc-icon
23
29
  * @dependency mdc-popover
24
30
  * @dependency mdc-text
25
31
  * @dependency mdc-toggletip
26
- *
32
+ *
27
33
  * @event input - (React: onInput) This event is dispatched when the date value changes.
28
34
  * @event change - (React: onChange) This event is dispatched when the date value is committed.
29
35
  * @event focus - (React: onFocus) This event is dispatched when the datepicker receives focus.
30
36
  * @event blur - (React: onBlur) This event is dispatched when the datepicker loses focus.
31
- *
37
+ *
32
38
  * @slot label - Slot for the label element.
33
39
  * @slot toggletip - Slot for the toggletip info icon button.
34
40
  * @slot help-icon - Slot for the helper/validation icon.
35
41
  * @slot help-text - Slot for the helper/validation text.
36
- *
42
+ *
37
43
  * @cssproperty --mdc-datepicker-background-color - Background color of the datepicker input.
38
44
  * @cssproperty --mdc-datepicker-border-color - Border color of the datepicker input.
39
45
  * @cssproperty --mdc-datepicker-text-color - Text color of the datepicker input.
40
46
  * @cssproperty --mdc-datepicker-height - The height of the datepicker trigger control.
41
47
  * @cssproperty --mdc-datepicker-width - Width of the datepicker component.
42
- *
48
+ *
43
49
  * @csspart label - The label element.
44
50
  * @csspart label-text - The container for the label and required indicator elements.
45
51
  * @csspart required-indicator - The required indicator element.
@@ -169,6 +175,11 @@ declare class DatePicker extends DatePicker_base implements AssociatedFormContro
169
175
  protected willUpdate(changedProperties: PropertyValueMap<any> | Map<PropertyKey, unknown>): void;
170
176
  private parseValueToInternal;
171
177
  private internalToValue;
178
+ private getParsedMin;
179
+ private getParsedMax;
180
+ private clampValueToRange;
181
+ private getFieldRange;
182
+ private getNextSpinbuttonValue;
172
183
  private syncFormValue;
173
184
  private commitValue;
174
185
  private notifyValueChange;
@@ -22,15 +22,6 @@ import { CALENDAR_ICON, DEFAULTS, TRIGGER_ID, VARIANT } from './datepicker.const
22
22
  import styles from './datepicker.styles';
23
23
  import { buildISODate, getDateSeparator, getFieldMax, getFieldMin, getFieldOrder, getPlaceholder, parseISODate, } from './datepicker.utils';
24
24
  /**
25
- * mdc-datepicker is a component that allows users to select a date
26
- * or enter a date manually. It supports two variants:
27
- *
28
- * - `input`: Manual date entry with spinbutton inputs for month, day, and year
29
- * - `default`: A select-like trigger that opens a calendar for date range selection
30
- *
31
- * The component uses `mdc-calendar` inside a popover for date selection
32
- * and supports localization via a BCP 47 locale string.
33
- *
34
25
  * @tagname mdc-datepicker
35
26
  *
36
27
  * @dependency mdc-button
@@ -188,8 +179,8 @@ class DatePicker extends FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper)
188
179
  this.syncFormValue();
189
180
  }
190
181
  }
191
- parseValueToInternal() {
192
- const parts = parseISODate(this.value);
182
+ parseValueToInternal(value = this.value) {
183
+ const parts = parseISODate(value);
193
184
  if (parts) {
194
185
  this.internalMonth = parts.month;
195
186
  this.internalDay = parts.day;
@@ -204,6 +195,86 @@ class DatePicker extends FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper)
204
195
  internalToValue() {
205
196
  return buildISODate(this.internalMonth, this.internalDay, this.internalYear);
206
197
  }
198
+ // AI-Assisted: keep input spinbuttons aligned with valid min/max date boundaries.
199
+ getParsedMin() {
200
+ var _a;
201
+ return this.min ? (_a = parseISO(this.min)) !== null && _a !== void 0 ? _a : undefined : undefined;
202
+ }
203
+ getParsedMax() {
204
+ var _a;
205
+ return this.max ? (_a = parseISO(this.max)) !== null && _a !== void 0 ? _a : undefined : undefined;
206
+ }
207
+ clampValueToRange(value) {
208
+ var _a, _b;
209
+ const dt = parseISO(value);
210
+ if (!dt)
211
+ return value;
212
+ const minDt = this.getParsedMin();
213
+ const maxDt = this.getParsedMax();
214
+ if (minDt && isBefore(dt, minDt))
215
+ return (_a = this.min) !== null && _a !== void 0 ? _a : value;
216
+ if (maxDt && isAfter(dt, maxDt))
217
+ return (_b = this.max) !== null && _b !== void 0 ? _b : value;
218
+ return value;
219
+ }
220
+ getFieldRange(field) {
221
+ const currentMonth = parseInt(this.internalMonth, 10) || undefined;
222
+ const currentYear = parseInt(this.internalYear, 10) || undefined;
223
+ const baseMin = getFieldMin(field);
224
+ const baseMax = getFieldMax(field, currentMonth, currentYear);
225
+ let min = baseMin;
226
+ let max = baseMax;
227
+ const minDt = this.getParsedMin();
228
+ const maxDt = this.getParsedMax();
229
+ if (field === 'year') {
230
+ if (minDt)
231
+ min = Math.max(min, minDt.getFullYear());
232
+ if (maxDt)
233
+ max = Math.min(max, maxDt.getFullYear());
234
+ }
235
+ else if (field === 'month' && currentYear) {
236
+ if (minDt && currentYear === minDt.getFullYear())
237
+ min = Math.max(min, minDt.getMonth() + 1);
238
+ if (maxDt && currentYear === maxDt.getFullYear())
239
+ max = Math.min(max, maxDt.getMonth() + 1);
240
+ }
241
+ else if (field === 'day' && currentMonth && currentYear) {
242
+ if (minDt &&
243
+ currentYear === minDt.getFullYear() &&
244
+ currentMonth === minDt.getMonth() + 1) {
245
+ min = Math.max(min, minDt.getDate());
246
+ }
247
+ if (maxDt &&
248
+ currentYear === maxDt.getFullYear() &&
249
+ currentMonth === maxDt.getMonth() + 1) {
250
+ max = Math.min(max, maxDt.getDate());
251
+ }
252
+ }
253
+ if (min > max) {
254
+ return { min: baseMin, max: baseMax, isMinConstrained: false, isMaxConstrained: false };
255
+ }
256
+ return {
257
+ min,
258
+ max,
259
+ isMinConstrained: min !== baseMin,
260
+ isMaxConstrained: max !== baseMax,
261
+ };
262
+ }
263
+ getNextSpinbuttonValue(currentValue, range, increment) {
264
+ if (increment) {
265
+ if (currentValue < range.min)
266
+ return range.min;
267
+ if (currentValue >= range.max)
268
+ return range.isMaxConstrained ? range.max : range.min;
269
+ return currentValue + 1;
270
+ }
271
+ if (currentValue > range.max)
272
+ return range.max;
273
+ if (currentValue <= range.min)
274
+ return range.isMinConstrained ? range.min : range.max;
275
+ return currentValue - 1;
276
+ }
277
+ // End AI-Assisted
207
278
  syncFormValue() {
208
279
  const val = this.value || this.internalToValue();
209
280
  if (this.internals) {
@@ -220,17 +291,13 @@ class DatePicker extends FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper)
220
291
  }
221
292
  commitValue() {
222
293
  const newVal = this.internalToValue();
223
- if (newVal && newVal !== this.value) {
224
- const dt = parseISO(newVal);
225
- if (dt) {
226
- const minDt = this.min ? parseISO(this.min) : undefined;
227
- const maxDt = this.max ? parseISO(this.max) : undefined;
228
- if (minDt && isBefore(dt, minDt))
229
- return;
230
- if (maxDt && isAfter(dt, maxDt))
231
- return;
232
- }
233
- this.value = newVal;
294
+ if (newVal) {
295
+ const clampedVal = this.clampValueToRange(newVal);
296
+ if (clampedVal !== newVal)
297
+ this.parseValueToInternal(clampedVal);
298
+ if (clampedVal === this.value)
299
+ return;
300
+ this.value = clampedVal;
234
301
  this.syncFormValue();
235
302
  this.notifyValueChange();
236
303
  }
@@ -373,22 +440,19 @@ class DatePicker extends FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper)
373
440
  handleSpinbuttonKeydown(event, field) {
374
441
  if (this.readonly)
375
442
  return;
376
- const currentMonth = parseInt(this.internalMonth, 10) || undefined;
377
- const currentYear = parseInt(this.internalYear, 10) || undefined;
378
- const minVal = getFieldMin(field);
379
- const maxVal = getFieldMax(field, currentMonth, currentYear);
443
+ const range = this.getFieldRange(field);
380
444
  const currentVal = parseInt(this.getFieldValue(field), 10) || 0;
381
445
  switch (event.key) {
382
446
  case KEYS.ARROW_UP: {
383
447
  event.preventDefault();
384
- const newVal = currentVal >= maxVal ? minVal : currentVal + 1;
448
+ const newVal = this.getNextSpinbuttonValue(currentVal, range, true);
385
449
  this.setFieldValue(field, newVal);
386
450
  this.commitValue();
387
451
  break;
388
452
  }
389
453
  case KEYS.ARROW_DOWN: {
390
454
  event.preventDefault();
391
- const newVal = currentVal <= minVal ? maxVal : currentVal - 1;
455
+ const newVal = this.getNextSpinbuttonValue(currentVal, range, false);
392
456
  this.setFieldValue(field, newVal);
393
457
  this.commitValue();
394
458
  break;
@@ -408,7 +472,7 @@ class DatePicker extends FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper)
408
472
  default: {
409
473
  if (/^\d$/.test(event.key)) {
410
474
  event.preventDefault();
411
- this.handleDigitInput(event.key, field, minVal, maxVal);
475
+ this.handleDigitInput(event.key, field, range.min, range.max);
412
476
  }
413
477
  else {
414
478
  event.preventDefault();
@@ -558,10 +622,7 @@ class DatePicker extends FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper)
558
622
  // -- Render methods --
559
623
  renderSpinbutton(field) {
560
624
  const value = this.getFieldValue(field);
561
- const currentMonth = parseInt(this.internalMonth, 10) || undefined;
562
- const currentYear = parseInt(this.internalYear, 10) || undefined;
563
- const minVal = getFieldMin(field);
564
- const maxVal = getFieldMax(field, currentMonth, currentYear);
625
+ const range = this.getFieldRange(field);
565
626
  const labelMap = {
566
627
  month: this.localeMonthLabel,
567
628
  day: this.localeDayLabel,
@@ -578,8 +639,8 @@ class DatePicker extends FormInternalsMixin(DataAriaLabelMixin(FormfieldWrapper)
578
639
  part="spinbutton spinbutton-${field}"
579
640
  role="spinbutton"
580
641
  aria-label="${labelMap[field]}"
581
- aria-valuemin="${minVal}"
582
- aria-valuemax="${maxVal}"
642
+ aria-valuemin="${range.min}"
643
+ aria-valuemax="${range.max}"
583
644
  aria-valuenow="${ifDefined(value ? parseInt(value, 10) : undefined)}"
584
645
  aria-description="${this.localeSpinbuttonDescription}"
585
646
  .value="${value}"