material 3.2.5 → 3.2.7

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 (564) hide show
  1. package/README.md +2 -2
  2. package/dist/components/badge/badge.d.ts +0 -59
  3. package/dist/components/badge/constants.d.ts +0 -15
  4. package/dist/components/badge/index.d.ts +0 -6
  5. package/dist/components/badge/types.d.ts +0 -244
  6. package/dist/components/bottom-app-bar/bottom-app-bar.d.ts +0 -10
  7. package/dist/components/bottom-app-bar/constants.d.ts +0 -9
  8. package/dist/components/bottom-app-bar/index.d.ts +0 -4
  9. package/dist/components/bottom-app-bar/types.d.ts +0 -76
  10. package/dist/components/bottom-sheet/bottom-sheet.d.ts +0 -21
  11. package/dist/components/bottom-sheet/constants.d.ts +0 -29
  12. package/dist/components/bottom-sheet/types.d.ts +0 -89
  13. package/dist/components/button/button.d.ts +0 -62
  14. package/dist/components/button/constants.d.ts +0 -41
  15. package/dist/components/button/index.d.ts +0 -4
  16. package/dist/components/button/types.d.ts +0 -347
  17. package/dist/components/button-group/button-group.d.ts +0 -51
  18. package/dist/components/button-group/constants.d.ts +0 -83
  19. package/dist/components/button-group/index.d.ts +0 -10
  20. package/dist/components/button-group/types.d.ts +0 -234
  21. package/dist/components/card/card.d.ts +0 -64
  22. package/dist/components/card/constants.d.ts +0 -33
  23. package/dist/components/card/content.d.ts +0 -86
  24. package/dist/components/card/index.d.ts +0 -66
  25. package/dist/components/card/types.d.ts +0 -366
  26. package/dist/components/carousel/carousel.d.ts +0 -22
  27. package/dist/components/carousel/constants.d.ts +0 -16
  28. package/dist/components/carousel/types.d.ts +0 -29
  29. package/dist/components/checkbox/checkbox.d.ts +0 -61
  30. package/dist/components/checkbox/constants.d.ts +0 -33
  31. package/dist/components/checkbox/index.d.ts +0 -25
  32. package/dist/components/checkbox/types.d.ts +0 -206
  33. package/dist/components/chips/chips.d.ts +0 -14
  34. package/dist/components/chips/constants.d.ts +0 -1
  35. package/dist/components/chips/factories.d.ts +0 -4
  36. package/dist/components/chips/types.d.ts +0 -278
  37. package/dist/components/datepicker/constants.d.ts +0 -56
  38. package/dist/components/datepicker/datepicker.d.ts +0 -5
  39. package/dist/components/datepicker/types.d.ts +12 -257
  40. package/dist/components/dialog/constants.d.ts +0 -65
  41. package/dist/components/dialog/dialog.d.ts +0 -86
  42. package/dist/components/dialog/index.d.ts +0 -12
  43. package/dist/components/dialog/types.d.ts +0 -511
  44. package/dist/components/divider/config.d.ts +0 -130
  45. package/dist/components/divider/constants.d.ts +0 -27
  46. package/dist/components/divider/divider.d.ts +0 -36
  47. package/dist/components/divider/index.d.ts +0 -29
  48. package/dist/components/divider/types.d.ts +0 -126
  49. package/dist/components/drawer/constants.d.ts +0 -53
  50. package/dist/components/drawer/drawer.d.ts +0 -56
  51. package/dist/components/drawer/features/items.js +3 -2
  52. package/dist/components/drawer/index.d.ts +0 -4
  53. package/dist/components/drawer/types.d.ts +0 -200
  54. package/dist/components/extended-fab/constants.d.ts +0 -46
  55. package/dist/components/extended-fab/extended-fab.d.ts +0 -58
  56. package/dist/components/extended-fab/index.d.ts +0 -34
  57. package/dist/components/extended-fab/types.d.ts +0 -654
  58. package/dist/components/fab/constants.d.ts +0 -40
  59. package/dist/components/fab/fab.d.ts +0 -42
  60. package/dist/components/fab/index.d.ts +0 -33
  61. package/dist/components/fab/types.d.ts +0 -543
  62. package/dist/components/fab-menu/constants.d.ts +0 -22
  63. package/dist/components/fab-menu/fab-menu.d.ts +0 -36
  64. package/dist/components/fab-menu/types.d.ts +0 -80
  65. package/dist/components/icon-button/constants.d.ts +0 -90
  66. package/dist/components/icon-button/icon-button.d.ts +0 -83
  67. package/dist/components/icon-button/index.d.ts +0 -44
  68. package/dist/components/icon-button/types.d.ts +0 -314
  69. package/dist/components/index.d.ts +0 -9
  70. package/dist/components/list/constants.d.ts +0 -47
  71. package/dist/components/list/index.d.ts +0 -1
  72. package/dist/components/list/list.d.ts +0 -26
  73. package/dist/components/list/types.d.ts +0 -263
  74. package/dist/components/loading-indicator/constants.d.ts +0 -35
  75. package/dist/components/loading-indicator/features/renderer.d.ts +0 -14
  76. package/dist/components/loading-indicator/loading-indicator.d.ts +0 -6
  77. package/dist/components/loading-indicator/types.d.ts +0 -35
  78. package/dist/components/menu/constants.d.ts +0 -79
  79. package/dist/components/menu/index.d.ts +0 -25
  80. package/dist/components/menu/inner.d.ts +0 -3
  81. package/dist/components/menu/menu.d.ts +0 -26
  82. package/dist/components/menu/types.d.ts +0 -423
  83. package/dist/components/navigation-bar/navigation-bar.d.ts +0 -7
  84. package/dist/components/navigation-bar/types.d.ts +0 -25
  85. package/dist/components/navigation-rail/constants.d.ts +0 -2
  86. package/dist/components/navigation-rail/navigation-rail.d.ts +0 -5
  87. package/dist/components/navigation-rail/types.d.ts +0 -22
  88. package/dist/components/progress/constants.d.ts +24 -56
  89. package/dist/components/progress/progress.d.ts +0 -21
  90. package/dist/components/progress/types.d.ts +0 -251
  91. package/dist/components/radios/constants.d.ts +0 -22
  92. package/dist/components/radios/radios.d.ts +0 -5
  93. package/dist/components/radios/types.d.ts +0 -142
  94. package/dist/components/search/constants.d.ts +0 -59
  95. package/dist/components/search/search.d.ts +0 -32
  96. package/dist/components/search/types.d.ts +0 -159
  97. package/dist/components/select/constants.d.ts +0 -60
  98. package/dist/components/select/index.d.ts +0 -22
  99. package/dist/components/select/select.d.ts +0 -33
  100. package/dist/components/select/types.d.ts +0 -241
  101. package/dist/components/side-sheet/constants.d.ts +0 -28
  102. package/dist/components/side-sheet/side-sheet.d.ts +0 -21
  103. package/dist/components/side-sheet/types.d.ts +0 -82
  104. package/dist/components/slider/constants.d.ts +0 -86
  105. package/dist/components/slider/slider.d.ts +0 -16
  106. package/dist/components/slider/types.d.ts +0 -184
  107. package/dist/components/snackbar/constants.d.ts +0 -73
  108. package/dist/components/snackbar/snackbar.d.ts +0 -13
  109. package/dist/components/snackbar/types.d.ts +0 -147
  110. package/dist/components/split-button/constants.d.ts +0 -33
  111. package/dist/components/split-button/split-button.d.ts +0 -21
  112. package/dist/components/split-button/types.d.ts +0 -81
  113. package/dist/components/switch/constants.d.ts +0 -49
  114. package/dist/components/switch/switch.d.ts +0 -5
  115. package/dist/components/switch/types.d.ts +0 -80
  116. package/dist/components/tabs/constants.d.ts +0 -76
  117. package/dist/components/tabs/indicator.d.ts +0 -27
  118. package/dist/components/tabs/responsive.d.ts +0 -30
  119. package/dist/components/tabs/tab.d.ts +0 -13
  120. package/dist/components/tabs/tab.js +26 -3
  121. package/dist/components/tabs/tabs.d.ts +0 -24
  122. package/dist/components/tabs/types.d.ts +0 -335
  123. package/dist/components/tabs/utils.d.ts +0 -66
  124. package/dist/components/text-field/constants.d.ts +0 -82
  125. package/dist/components/text-field/features/trailing-icon.d.ts +0 -61
  126. package/dist/components/text-field/text-field.d.ts +0 -33
  127. package/dist/components/text-field/types.d.ts +0 -123
  128. package/dist/components/timepicker/constants.d.ts +0 -88
  129. package/dist/components/timepicker/types.d.ts +0 -268
  130. package/dist/components/toolbar/constants.d.ts +0 -27
  131. package/dist/components/toolbar/toolbar.d.ts +0 -25
  132. package/dist/components/toolbar/types.d.ts +0 -102
  133. package/dist/components/tooltip/constants.d.ts +0 -58
  134. package/dist/components/tooltip/tooltip.d.ts +0 -5
  135. package/dist/components/tooltip/types.d.ts +0 -140
  136. package/dist/components/top-app-bar/constants.d.ts +0 -41
  137. package/dist/components/top-app-bar/index.d.ts +0 -4
  138. package/dist/components/top-app-bar/top-app-bar.d.ts +0 -10
  139. package/dist/components/top-app-bar/types.d.ts +0 -94
  140. package/dist/core/canvas/animation.d.ts +0 -13
  141. package/dist/core/canvas/drawing.d.ts +18 -55
  142. package/dist/core/canvas/index.d.ts +0 -4
  143. package/dist/core/canvas/resize.d.ts +0 -13
  144. package/dist/core/canvas/utils.d.ts +0 -62
  145. package/dist/core/compose/base.d.ts +0 -22
  146. package/dist/core/compose/cleanup.d.ts +0 -2
  147. package/dist/core/compose/component.d.ts +0 -31
  148. package/dist/core/compose/features/badge.d.ts +0 -25
  149. package/dist/core/compose/features/badge.js +45 -0
  150. package/dist/core/compose/features/checkable.d.ts +0 -36
  151. package/dist/core/compose/features/debounce.d.ts +0 -57
  152. package/dist/core/compose/features/disabled.d.ts +0 -31
  153. package/dist/core/compose/features/events.d.ts +0 -38
  154. package/dist/core/compose/features/icon.d.ts +0 -49
  155. package/dist/core/compose/features/input.d.ts +0 -82
  156. package/dist/core/compose/features/lifecycle.d.ts +0 -36
  157. package/dist/core/compose/features/position.d.ts +0 -27
  158. package/dist/core/compose/features/ripple.d.ts +0 -29
  159. package/dist/core/compose/features/size.d.ts +0 -9
  160. package/dist/core/compose/features/style.d.ts +0 -9
  161. package/dist/core/compose/features/text.d.ts +0 -45
  162. package/dist/core/compose/features/textinput.d.ts +0 -88
  163. package/dist/core/compose/features/textlabel.d.ts +0 -44
  164. package/dist/core/compose/features/throttle.d.ts +0 -54
  165. package/dist/core/compose/features/track.d.ts +0 -34
  166. package/dist/core/compose/features/variant.d.ts +0 -9
  167. package/dist/core/compose/features/withEvents.d.ts +0 -30
  168. package/dist/core/compose/index.d.ts +0 -4
  169. package/dist/core/compose/pipe.d.ts +0 -55
  170. package/dist/core/compose/utils/type-guards.d.ts +0 -15
  171. package/dist/core/config/component.d.ts +0 -45
  172. package/dist/core/config/global.d.ts +0 -43
  173. package/dist/core/config.d.ts +0 -59
  174. package/dist/core/dom/attributes.d.ts +0 -41
  175. package/dist/core/dom/classes.d.ts +0 -49
  176. package/dist/core/dom/create.d.ts +0 -98
  177. package/dist/core/dom/events.d.ts +0 -52
  178. package/dist/core/dom/focus.d.ts +0 -32
  179. package/dist/core/dom/html.d.ts +0 -24
  180. package/dist/core/dom/layer.d.ts +0 -98
  181. package/dist/core/dom/roving.d.ts +0 -19
  182. package/dist/core/index.d.ts +0 -9
  183. package/dist/core/navigation/destinations.d.ts +0 -14
  184. package/dist/core/navigation/destinations.js +18 -5
  185. package/dist/core/shapes/cubic.d.ts +24 -19
  186. package/dist/core/shapes/material.d.ts +0 -64
  187. package/dist/core/shapes/polygon.d.ts +6 -16
  188. package/dist/core/state/emitter.d.ts +0 -36
  189. package/dist/core/state/events.d.ts +0 -29
  190. package/dist/core/state/store.d.ts +0 -70
  191. package/dist/core/theme/index.d.ts +0 -3
  192. package/dist/core/theme/shape.d.ts +0 -7
  193. package/dist/core/theme/tokens.d.ts +48 -32
  194. package/dist/core/utils/background.d.ts +0 -29
  195. package/dist/core/utils/color.d.ts +0 -13
  196. package/dist/core/utils/index.d.ts +0 -11
  197. package/dist/core/utils/mobile.d.ts +0 -31
  198. package/dist/core/utils/object.d.ts +0 -11
  199. package/dist/core/utils/performance.d.ts +0 -70
  200. package/dist/core/utils/theme.d.ts +0 -36
  201. package/dist/core/utils/url.d.ts +0 -17
  202. package/dist/elements/adapter.d.ts +13 -62
  203. package/dist/elements/badge.d.ts +0 -17
  204. package/dist/elements/bottom-app-bar.d.ts +7 -17
  205. package/dist/elements/bottom-sheet.d.ts +9 -38
  206. package/dist/elements/button-group.d.ts +0 -31
  207. package/dist/elements/button.d.ts +0 -18
  208. package/dist/elements/card.d.ts +8 -24
  209. package/dist/elements/carousel.d.ts +5 -29
  210. package/dist/elements/checkbox.d.ts +5 -15
  211. package/dist/elements/chips.d.ts +0 -33
  212. package/dist/elements/css/badge.css +1 -1
  213. package/dist/elements/css/badge.js +1 -1
  214. package/dist/elements/css/navigation-rail.css +1 -1
  215. package/dist/elements/css/navigation-rail.js +1 -1
  216. package/dist/elements/datepicker.d.ts +4 -48
  217. package/dist/elements/define.d.ts +3 -161
  218. package/dist/elements/dialog.d.ts +8 -39
  219. package/dist/elements/divider.d.ts +0 -14
  220. package/dist/elements/drawer.d.ts +0 -35
  221. package/dist/elements/extended-fab.d.ts +6 -18
  222. package/dist/elements/fab-menu.d.ts +5 -30
  223. package/dist/elements/fab.d.ts +4 -17
  224. package/dist/elements/icon-button.d.ts +5 -26
  225. package/dist/elements/index.d.ts +0 -16
  226. package/dist/elements/list.d.ts +0 -34
  227. package/dist/elements/loading-indicator.d.ts +4 -13
  228. package/dist/elements/menu.d.ts +5 -51
  229. package/dist/elements/navigation-bar.d.ts +4 -29
  230. package/dist/elements/navigation-rail.d.ts +8 -49
  231. package/dist/elements/preupgrade/badge.css +2 -2
  232. package/dist/elements/preupgrade/bottom-app-bar.css +1 -1
  233. package/dist/elements/preupgrade/bottom-sheet.css +1 -1
  234. package/dist/elements/preupgrade/button-group.css +1 -1
  235. package/dist/elements/preupgrade/button.css +1 -1
  236. package/dist/elements/preupgrade/card.css +1 -1
  237. package/dist/elements/preupgrade/carousel.css +1 -1
  238. package/dist/elements/preupgrade/checkbox.css +1 -1
  239. package/dist/elements/preupgrade/chips.css +1 -1
  240. package/dist/elements/preupgrade/datepicker.css +1 -1
  241. package/dist/elements/preupgrade/dialog.css +1 -1
  242. package/dist/elements/preupgrade/divider.css +1 -1
  243. package/dist/elements/preupgrade/drawer.css +1 -1
  244. package/dist/elements/preupgrade/extended-fab.css +1 -1
  245. package/dist/elements/preupgrade/fab-menu.css +1 -1
  246. package/dist/elements/preupgrade/fab.css +1 -1
  247. package/dist/elements/preupgrade/icon-button.css +1 -1
  248. package/dist/elements/preupgrade/list.css +1 -1
  249. package/dist/elements/preupgrade/loading-indicator.css +1 -1
  250. package/dist/elements/preupgrade/menu.css +1 -1
  251. package/dist/elements/preupgrade/navigation-bar.css +1 -1
  252. package/dist/elements/preupgrade/navigation-rail.css +1 -1
  253. package/dist/elements/preupgrade/progress.css +1 -1
  254. package/dist/elements/preupgrade/radios.css +1 -1
  255. package/dist/elements/preupgrade/search.css +1 -1
  256. package/dist/elements/preupgrade/select.css +1 -1
  257. package/dist/elements/preupgrade/side-sheet.css +1 -1
  258. package/dist/elements/preupgrade/slider.css +1 -1
  259. package/dist/elements/preupgrade/snackbar.css +1 -1
  260. package/dist/elements/preupgrade/split-button.css +1 -1
  261. package/dist/elements/preupgrade/switch.css +1 -1
  262. package/dist/elements/preupgrade/tabs.css +1 -1
  263. package/dist/elements/preupgrade/text-field.css +1 -1
  264. package/dist/elements/preupgrade/timepicker.css +1 -1
  265. package/dist/elements/preupgrade/toolbar.css +1 -1
  266. package/dist/elements/preupgrade/tooltip.css +1 -1
  267. package/dist/elements/preupgrade/top-app-bar.css +1 -1
  268. package/dist/elements/preupgrade.css +2 -2
  269. package/dist/elements/preupgrade.d.ts +0 -1
  270. package/dist/elements/preupgrade.js +1 -1
  271. package/dist/elements/progress.d.ts +0 -15
  272. package/dist/elements/radios.d.ts +0 -22
  273. package/dist/elements/search.d.ts +5 -53
  274. package/dist/elements/select.d.ts +0 -31
  275. package/dist/elements/side-sheet.d.ts +7 -29
  276. package/dist/elements/slider.d.ts +3 -22
  277. package/dist/elements/snackbar.d.ts +4 -28
  278. package/dist/elements/split-button.d.ts +0 -30
  279. package/dist/elements/styles.d.ts +0 -63
  280. package/dist/elements/switch.d.ts +5 -17
  281. package/dist/elements/tabs.d.ts +0 -22
  282. package/dist/elements/text-field.d.ts +4 -38
  283. package/dist/elements/timepicker.d.ts +4 -44
  284. package/dist/elements/toolbar.d.ts +8 -25
  285. package/dist/elements/tooltip.d.ts +4 -30
  286. package/dist/elements/top-app-bar.d.ts +7 -23
  287. package/dist/index.d.ts +0 -11
  288. package/dist/package.json +1 -1
  289. package/dist/react/create.d.ts +0 -42
  290. package/dist/react/index.d.ts +0 -6
  291. package/dist/react/jsx.d.ts +0 -13
  292. package/dist/solid/create.d.ts +0 -48
  293. package/dist/solid/index.d.ts +0 -6
  294. package/dist/solid/jsx.d.ts +0 -9
  295. package/dist/ssr/index.d.ts +0 -49
  296. package/dist/ssr/solid.d.ts +0 -4
  297. package/dist/ssr/svelte.d.ts +0 -4
  298. package/dist/ssr/vue.d.ts +0 -4
  299. package/dist/styles/badge.css +2 -2
  300. package/dist/styles/base.css +1 -1
  301. package/dist/styles/bottom-app-bar.css +1 -1
  302. package/dist/styles/bottom-sheet.css +1 -1
  303. package/dist/styles/button-group.css +1 -1
  304. package/dist/styles/button.css +1 -1
  305. package/dist/styles/card.css +1 -1
  306. package/dist/styles/carousel.css +1 -1
  307. package/dist/styles/checkbox.css +1 -1
  308. package/dist/styles/chips.css +1 -1
  309. package/dist/styles/contrast.css +1 -1
  310. package/dist/styles/datepicker.css +1 -1
  311. package/dist/styles/dialog.css +1 -1
  312. package/dist/styles/divider.css +1 -1
  313. package/dist/styles/drawer.css +1 -1
  314. package/dist/styles/extended-fab.css +1 -1
  315. package/dist/styles/fab-menu.css +1 -1
  316. package/dist/styles/fab.css +1 -1
  317. package/dist/styles/icon-button.css +1 -1
  318. package/dist/styles/list.css +1 -1
  319. package/dist/styles/loading-indicator.css +1 -1
  320. package/dist/styles/menu.css +1 -1
  321. package/dist/styles/navigation-bar.css +1 -1
  322. package/dist/styles/navigation-rail.css +2 -2
  323. package/dist/styles/progress.css +1 -1
  324. package/dist/styles/radios.css +1 -1
  325. package/dist/styles/search.css +1 -1
  326. package/dist/styles/select.css +1 -1
  327. package/dist/styles/side-sheet.css +1 -1
  328. package/dist/styles/slider.css +1 -1
  329. package/dist/styles/snackbar.css +1 -1
  330. package/dist/styles/split-button.css +1 -1
  331. package/dist/styles/switch.css +1 -1
  332. package/dist/styles/tabs.css +1 -1
  333. package/dist/styles/text-field.css +1 -1
  334. package/dist/styles/timepicker.css +1 -1
  335. package/dist/styles/toolbar.css +1 -1
  336. package/dist/styles/tooltip.css +1 -1
  337. package/dist/styles/top-app-bar.css +1 -1
  338. package/dist/styles/typography.css +1 -1
  339. package/dist/styles/utilities.css +1 -1
  340. package/dist/styles.css +2 -2
  341. package/dist/svelte/runtime.d.ts +8 -62
  342. package/dist/themes/autumn-contrast.css +1 -1
  343. package/dist/themes/autumn.css +1 -1
  344. package/dist/themes/baseline-contrast.css +1 -1
  345. package/dist/themes/baseline.css +1 -1
  346. package/dist/themes/brownbeige-contrast.css +1 -1
  347. package/dist/themes/brownbeige.css +1 -1
  348. package/dist/themes/content-contrast.css +1 -1
  349. package/dist/themes/content.css +1 -1
  350. package/dist/themes/desert-contrast.css +1 -1
  351. package/dist/themes/desert.css +1 -1
  352. package/dist/themes/expressive-contrast.css +1 -1
  353. package/dist/themes/expressive.css +1 -1
  354. package/dist/themes/fidelity-contrast.css +1 -1
  355. package/dist/themes/fidelity.css +1 -1
  356. package/dist/themes/forest-contrast.css +1 -1
  357. package/dist/themes/forest.css +1 -1
  358. package/dist/themes/fruit-salad-contrast.css +1 -1
  359. package/dist/themes/fruit-salad.css +1 -1
  360. package/dist/themes/highcontrast-contrast.css +1 -1
  361. package/dist/themes/highcontrast.css +1 -1
  362. package/dist/themes/monochrome-contrast.css +1 -1
  363. package/dist/themes/monochrome.css +1 -1
  364. package/dist/themes/neutral-contrast.css +1 -1
  365. package/dist/themes/neutral.css +1 -1
  366. package/dist/themes/ocean-contrast.css +1 -1
  367. package/dist/themes/ocean.css +1 -1
  368. package/dist/themes/rainbow-contrast.css +1 -1
  369. package/dist/themes/rainbow.css +1 -1
  370. package/dist/themes/sageivory-contrast.css +1 -1
  371. package/dist/themes/sageivory.css +1 -1
  372. package/dist/themes/spring-contrast.css +1 -1
  373. package/dist/themes/spring.css +1 -1
  374. package/dist/themes/summer-contrast.css +1 -1
  375. package/dist/themes/summer.css +1 -1
  376. package/dist/themes/sunset-contrast.css +1 -1
  377. package/dist/themes/sunset.css +1 -1
  378. package/dist/themes/tealcaramel-contrast.css +1 -1
  379. package/dist/themes/tealcaramel.css +1 -1
  380. package/dist/themes/vibrant-contrast.css +1 -1
  381. package/dist/themes/vibrant.css +1 -1
  382. package/dist/vue/create.d.ts +15 -58
  383. package/dist/vue/index.d.ts +0 -6
  384. package/package.json +1 -1
  385. package/src/styles/components/_badge.scss +75 -38
  386. package/src/styles/components/_navigation-rail.scss +9 -6
  387. package/src/styles/elements/_badge.scss +65 -4
  388. package/dist/components/badge/api.d.ts +0 -41
  389. package/dist/components/badge/config.d.ts +0 -631
  390. package/dist/components/badge/features.d.ts +0 -38
  391. package/dist/components/bottom-app-bar/config.d.ts +0 -16
  392. package/dist/components/bottom-sheet/api.d.ts +0 -44
  393. package/dist/components/bottom-sheet/config.d.ts +0 -547
  394. package/dist/components/bottom-sheet/features/drag.d.ts +0 -35
  395. package/dist/components/bottom-sheet/features/index.d.ts +0 -3
  396. package/dist/components/bottom-sheet/features/state.d.ts +0 -31
  397. package/dist/components/bottom-sheet/features/structure.d.ts +0 -26
  398. package/dist/components/button/api.d.ts +0 -68
  399. package/dist/components/button/config.d.ts +0 -594
  400. package/dist/components/button/features/progress.d.ts +0 -43
  401. package/dist/components/button/features/toggle.d.ts +0 -43
  402. package/dist/components/button-group/config.d.ts +0 -147
  403. package/dist/components/card/api.d.ts +0 -24
  404. package/dist/components/card/config.d.ts +0 -635
  405. package/dist/components/card/features.d.ts +0 -124
  406. package/dist/components/carousel/api.d.ts +0 -20
  407. package/dist/components/carousel/arrangement.d.ts +0 -23
  408. package/dist/components/carousel/config.d.ts +0 -540
  409. package/dist/components/carousel/features/index.d.ts +0 -2
  410. package/dist/components/carousel/features/scroll.d.ts +0 -20
  411. package/dist/components/carousel/features/slides.d.ts +0 -18
  412. package/dist/components/carousel/keylines.d.ts +0 -68
  413. package/dist/components/carousel/strategy.d.ts +0 -36
  414. package/dist/components/checkbox/api.d.ts +0 -7
  415. package/dist/components/checkbox/config.d.ts +0 -568
  416. package/dist/components/chips/api.d.ts +0 -62
  417. package/dist/components/chips/chip/chip.d.ts +0 -4
  418. package/dist/components/chips/chip/constants.d.ts +0 -38
  419. package/dist/components/chips/chip/index.d.ts +0 -1
  420. package/dist/components/chips/config.d.ts +0 -583
  421. package/dist/components/chips/features/chip-items.d.ts +0 -39
  422. package/dist/components/chips/features/container.d.ts +0 -75
  423. package/dist/components/chips/features/controller.d.ts +0 -61
  424. package/dist/components/chips/features/dom.d.ts +0 -24
  425. package/dist/components/chips/features/index.d.ts +0 -4
  426. package/dist/components/chips/schema.d.ts +0 -35
  427. package/dist/components/datepicker/api.d.ts +0 -7
  428. package/dist/components/datepicker/config.d.ts +0 -542
  429. package/dist/components/datepicker/render.d.ts +0 -3
  430. package/dist/components/datepicker/utils.d.ts +0 -84
  431. package/dist/components/dialog/api.d.ts +0 -66
  432. package/dist/components/dialog/config.d.ts +0 -583
  433. package/dist/components/dialog/features.d.ts +0 -42
  434. package/dist/components/divider/features.d.ts +0 -6
  435. package/dist/components/drawer/api.d.ts +0 -55
  436. package/dist/components/drawer/config.d.ts +0 -620
  437. package/dist/components/drawer/features/headline.d.ts +0 -27
  438. package/dist/components/drawer/features/index.d.ts +0 -3
  439. package/dist/components/drawer/features/items.d.ts +0 -32
  440. package/dist/components/drawer/features/state.d.ts +0 -22
  441. package/dist/components/extended-fab/api.d.ts +0 -96
  442. package/dist/components/extended-fab/config.d.ts +0 -600
  443. package/dist/components/fab/api.d.ts +0 -74
  444. package/dist/components/fab/config.d.ts +0 -596
  445. package/dist/components/fab-menu/config.d.ts +0 -11
  446. package/dist/components/fab-menu/stagger.d.ts +0 -10
  447. package/dist/components/icon-button/api.d.ts +0 -84
  448. package/dist/components/icon-button/config.d.ts +0 -624
  449. package/dist/components/icon-button/features/toggle.d.ts +0 -133
  450. package/dist/components/list/api.d.ts +0 -156
  451. package/dist/components/list/config.d.ts +0 -625
  452. package/dist/components/list/features/anatomy.d.ts +0 -6
  453. package/dist/components/list/features/index.d.ts +0 -2
  454. package/dist/components/list/features/renderer.d.ts +0 -8
  455. package/dist/components/list/features/selection.d.ts +0 -3
  456. package/dist/components/loading-indicator/api.d.ts +0 -14
  457. package/dist/components/loading-indicator/config.d.ts +0 -557
  458. package/dist/components/loading-indicator/features/motion.d.ts +0 -22
  459. package/dist/components/menu/api.d.ts +0 -63
  460. package/dist/components/menu/config.d.ts +0 -576
  461. package/dist/components/menu/features/controller.d.ts +0 -15
  462. package/dist/components/menu/features/index.d.ts +0 -5
  463. package/dist/components/menu/features/keyboard.d.ts +0 -23
  464. package/dist/components/menu/features/layer.d.ts +0 -15
  465. package/dist/components/menu/features/loader.d.ts +0 -35
  466. package/dist/components/menu/features/opener.d.ts +0 -16
  467. package/dist/components/menu/features/position.d.ts +0 -18
  468. package/dist/components/menu/features/registry.d.ts +0 -37
  469. package/dist/components/menu/features/submenu.d.ts +0 -28
  470. package/dist/components/menu/features/tasks.d.ts +0 -9
  471. package/dist/components/navigation-bar/config.d.ts +0 -2
  472. package/dist/components/navigation-rail/config.d.ts +0 -2
  473. package/dist/components/progress/api.d.ts +0 -81
  474. package/dist/components/progress/config.d.ts +0 -620
  475. package/dist/components/progress/features/canvas.d.ts +0 -60
  476. package/dist/components/progress/features/circular.d.ts +0 -19
  477. package/dist/components/progress/features/colors.d.ts +0 -17
  478. package/dist/components/progress/features/index.d.ts +0 -8
  479. package/dist/components/progress/features/linear.d.ts +0 -25
  480. package/dist/components/progress/features/motion.d.ts +0 -43
  481. package/dist/components/progress/features/resize-observer.d.ts +0 -5
  482. package/dist/components/progress/features/state.d.ts +0 -44
  483. package/dist/components/radios/api.d.ts +0 -37
  484. package/dist/components/radios/config.d.ts +0 -568
  485. package/dist/components/radios/radio.d.ts +0 -26
  486. package/dist/components/search/api.d.ts +0 -63
  487. package/dist/components/search/config.d.ts +0 -657
  488. package/dist/components/search/features/index.d.ts +0 -4
  489. package/dist/components/search/features/input.d.ts +0 -93
  490. package/dist/components/search/features/states.d.ts +0 -111
  491. package/dist/components/search/features/structure.d.ts +0 -16
  492. package/dist/components/search/features/suggestions.d.ts +0 -60
  493. package/dist/components/select/api.d.ts +0 -8
  494. package/dist/components/select/config.d.ts +0 -18
  495. package/dist/components/select/features.d.ts +0 -14
  496. package/dist/components/side-sheet/api.d.ts +0 -34
  497. package/dist/components/side-sheet/config.d.ts +0 -547
  498. package/dist/components/side-sheet/features/index.d.ts +0 -2
  499. package/dist/components/side-sheet/features/state.d.ts +0 -28
  500. package/dist/components/side-sheet/features/structure.d.ts +0 -21
  501. package/dist/components/slider/api.d.ts +0 -65
  502. package/dist/components/slider/config.d.ts +0 -605
  503. package/dist/components/slider/features/axis.d.ts +0 -42
  504. package/dist/components/slider/features/controller.d.ts +0 -528
  505. package/dist/components/slider/features/dom.d.ts +0 -22
  506. package/dist/components/slider/features/handlers.d.ts +0 -16
  507. package/dist/components/slider/features/index.d.ts +0 -5
  508. package/dist/components/slider/features/range.d.ts +0 -14
  509. package/dist/components/slider/features/states.d.ts +0 -76
  510. package/dist/components/slider/features/tracks.d.ts +0 -50
  511. package/dist/components/snackbar/api.d.ts +0 -7
  512. package/dist/components/snackbar/config.d.ts +0 -596
  513. package/dist/components/snackbar/features.d.ts +0 -26
  514. package/dist/components/snackbar/layer.d.ts +0 -23
  515. package/dist/components/snackbar/position.d.ts +0 -16
  516. package/dist/components/snackbar/queue.d.ts +0 -15
  517. package/dist/components/split-button/api.d.ts +0 -14
  518. package/dist/components/split-button/config.d.ts +0 -553
  519. package/dist/components/split-button/features/buttons.d.ts +0 -8
  520. package/dist/components/split-button/features/menu.d.ts +0 -10
  521. package/dist/components/switch/api.d.ts +0 -7
  522. package/dist/components/switch/config.d.ts +0 -558
  523. package/dist/components/switch/features.d.ts +0 -63
  524. package/dist/components/tabs/api.d.ts +0 -54
  525. package/dist/components/tabs/config.d.ts +0 -31
  526. package/dist/components/tabs/features.d.ts +0 -131
  527. package/dist/components/tabs/scroll-indicators.d.ts +0 -18
  528. package/dist/components/tabs/state.d.ts +0 -48
  529. package/dist/components/text-field/api.d.ts +0 -29
  530. package/dist/components/text-field/config.d.ts +0 -560
  531. package/dist/components/text-field/features/counter.d.ts +0 -29
  532. package/dist/components/text-field/features/density.d.ts +0 -28
  533. package/dist/components/text-field/features/error.d.ts +0 -55
  534. package/dist/components/text-field/features/field.d.ts +0 -37
  535. package/dist/components/text-field/features/index.d.ts +0 -20
  536. package/dist/components/text-field/features/leading-icon.d.ts +0 -68
  537. package/dist/components/text-field/features/placement.d.ts +0 -30
  538. package/dist/components/text-field/features/prefix-text.d.ts +0 -67
  539. package/dist/components/text-field/features/required.d.ts +0 -33
  540. package/dist/components/text-field/features/suffix-text.d.ts +0 -67
  541. package/dist/components/text-field/features/supporting-text.d.ts +0 -59
  542. package/dist/components/timepicker/api.d.ts +0 -26
  543. package/dist/components/timepicker/config.d.ts +0 -570
  544. package/dist/components/timepicker/dial.d.ts +0 -35
  545. package/dist/components/timepicker/render.d.ts +0 -9
  546. package/dist/components/timepicker/utils.d.ts +0 -55
  547. package/dist/components/toolbar/config.d.ts +0 -19
  548. package/dist/components/tooltip/api.d.ts +0 -18
  549. package/dist/components/tooltip/config.d.ts +0 -563
  550. package/dist/components/top-app-bar/config.d.ts +0 -16
  551. package/dist/core/compose/features/constants.d.ts +0 -8
  552. package/dist/core/dom/direction.d.ts +0 -16
  553. package/dist/core/dom/form-value.d.ts +0 -24
  554. package/dist/core/dom/utils.d.ts +0 -33
  555. package/dist/core/navigation/ripple.d.ts +0 -2
  556. package/dist/core/utils/attributes.d.ts +0 -29
  557. package/dist/core/utils/validate.d.ts +0 -73
  558. package/dist/core/utils/warn.d.ts +0 -16
  559. package/dist/elements/form-button.d.ts +0 -29
  560. package/dist/elements/lifecycle.d.ts +0 -4
  561. package/dist/elements/sheet.d.ts +0 -44
  562. package/dist/react/shadow.d.ts +0 -2
  563. package/dist/solid/shadow.d.ts +0 -3
  564. package/dist/vue/shadow.d.ts +0 -7
@@ -1,50 +1,6 @@
1
- /**
2
- * `<m-datepicker>`: the date picker as a form-associated custom element.
3
- *
4
- * The factory renders its own field, a text input with a calendar button:
5
- * that field is the trigger. A click on the button (or on the input of a
6
- * modal variant), ArrowDown in the input, the `open` attribute or `show()`
7
- * opens the calendar. The modal variants (`modal`, `modal-input`,
8
- * `fullscreen`) are a native `<dialog>` in the element's shadow root shown
9
- * with `showModal()`: the page outside is inert and Save commits, Cancel,
10
- * Escape and the backdrop do not. The docked calendar opens beside the field
11
- * (`show()`, not modal) and commits each date chosen.
12
- *
13
- * The value is an ISO date, `YYYY-MM-DD`, as on `<input type=date>`. With
14
- * `selection-mode="range"` a complete range is an ISO 8601 interval,
15
- * `YYYY-MM-DD/YYYY-MM-DD`: one string for the form, with a separator no date
16
- * contains. A lone date in range mode is a one-day range, `d/d`, as the
17
- * factory holds it. Empty is `""`. A value that is not one of these, or
18
- * that `min`, `max` or the mode rule out, empties the picker (the factory
19
- * keeps no such date).
20
- *
21
- * The `value` attribute is the default and the `value` property the live
22
- * value, as on a native input: the attribute moves the value until the user
23
- * or script changes it, and a form reset returns to it. `change` is
24
- * dispatched with `{ value }` when a date is committed. `open` reflects the
25
- * calendar's state, as on `<dialog open>`; `open` and `close` are dispatched
26
- * as it opens and closes (not when the attribute is what changed).
27
- *
28
- * `initial-view` is the view the calendar first opens on: `day`, `month` or
29
- * `year` (the full-screen variant has the days only). `close-on-select`
30
- * closes the calendar on a date chosen, committing it: a modal variant then
31
- * needs no Save. The factory reads both once: a change recreates the picker.
32
- *
33
- * The input of a modal variant is read-only, which takes it out of constraint
34
- * validation: the element reports the factory's `required` check as
35
- * `valueMissing`. `readonly` is the factory's: the value stays and the
36
- * calendar closed. `supporting-text` is the factory's supporting text.
37
- *
38
- * Parts: `datepicker`, `label`, `anchor`, `input`, `trigger`, `help`, `error`, `calendar`,
39
- * `header`, `navigation`, `prev`, `next`, `weekday`, `day`, among others.
40
- *
41
- * @module elements
42
- */
43
1
  import type { DatePickerComponent } from "../components/datepicker/types.js";
44
2
  import { type DefineOptions, type ElementHost, type ElementInstance } from "./define.js";
45
- /** The date picker, with what the element adds to it. */
46
3
  export interface DatepickerElementComponent extends DatePickerComponent {
47
- /** Opens the calendar, unless the picker is disabled or read-only. */
48
4
  show: () => void;
49
5
  }
50
6
  declare const datepickerSpec: {
@@ -122,7 +78,10 @@ declare const datepickerSpec: {
122
78
  };
123
79
  };
124
80
  model: "value";
125
- methods: readonly ["show", "close"];
81
+ methods: readonly [
82
+ "show",
83
+ "close"
84
+ ];
126
85
  events: {
127
86
  change: {
128
87
  detail: (payload: unknown) => {
@@ -151,12 +110,9 @@ declare const datepickerSpec: {
151
110
  };
152
111
  export declare const datepickerElement: import("./define.js").ElementDefinition<DatepickerElementComponent>;
153
112
  export type DatepickerSpec = typeof datepickerSpec;
154
- /** `<m-datepicker>` as a ref or a query returns it. */
155
113
  export type DatepickerElement = ElementInstance<DatepickerSpec, DatepickerElementComponent>;
156
- /** Registers `<m-datepicker>` (or `<prefix-datepicker>`). */
157
114
  export declare const defineDatepicker: (options?: DefineOptions) => string;
158
115
  declare global {
159
- /** `document.querySelector("m-…")` and `createElement` return the element's type (the default prefix). */
160
116
  interface HTMLElementTagNameMap {
161
117
  "m-datepicker": DatepickerElement;
162
118
  }
@@ -1,26 +1,4 @@
1
- /**
2
- * `defineElement` turns a component factory into a custom element.
3
- *
4
- * The element owns one factory instance, built inside its shadow root on first
5
- * connection. Attributes are the component's defaults, as on native controls;
6
- * properties carry its live state. The model's attribute (`checked`, `value`)
7
- * moves the live state until the state is dirty: changed by the user or set by
8
- * script, as a native input's dirty value and checkedness flags. Factory
9
- * events are re-dispatched from the host under the same names.
10
- *
11
- * Every piece of the component is a CSS part named after its BEM class
12
- * without the prefix: the block by its name (`mtrl-button` is
13
- * `::part(button)`), an element by its element name (`mtrl-switch__track` is
14
- * `::part(track)`). The piece holding the slot also takes the slot
15
- * attribute's name, so `m-button::part(label)` is the button's label.
16
- *
17
- * Nothing here touches the DOM at import time: the element class is built on
18
- * first use, so every element module can be imported on a server.
19
- *
20
- * @module elements
21
- */
22
1
  import { DEFAULT_PREFIX } from "./styles.js";
23
- /** The part of a component the element relies on. */
24
2
  export interface ElementComponent {
25
3
  element: HTMLElement;
26
4
  destroy: () => void;
@@ -30,164 +8,65 @@ export type AttributeValue = string | boolean | number | null;
30
8
  export type Config = Record<string, unknown>;
31
9
  export interface AttributeSpec<C> {
32
10
  type: AttributeType;
33
- /** Config key the attribute feeds at creation. Omitted: the attribute is not passed to the factory. */
34
11
  config?: string;
35
- /** Applies a change after creation. Omitted: the component is recreated. */
36
12
  update?: (component: C, value: AttributeValue, host: HTMLElement) => void;
37
13
  }
38
14
  export interface PropertySpec<C> {
39
15
  get: (component: C) => unknown;
40
16
  set: (component: C, value: unknown) => void;
41
- /** Config key a value set before creation feeds. */
42
17
  config?: string;
43
18
  }
44
19
  export interface EventSpec {
45
- /** Maps the factory payload to the event's `detail`. Default: the payload. */
46
20
  detail?: (payload: unknown) => unknown;
47
- /**
48
- * The event reports a change of state beside the model (`open`,
49
- * `expanded`), not of the model: dispatching it leaves the element clean.
50
- */
51
21
  state?: boolean;
52
- /** @internal Development diagnostic for a direct application listener. */
53
22
  listen?: (host: HTMLElement) => void;
54
23
  }
55
24
  export interface SlotSpec {
56
- /** Attribute whose text is the slot's fallback content. */
57
25
  attribute: string;
58
- /**
59
- * The config key that takes the text or a node (`text`, `label`): the
60
- * element passes its `<slot>` there and the factory places it.
61
- */
62
26
  config: string;
63
27
  }
64
28
  export interface FormSpec<C> {
65
- /**
66
- * The value submitted with the form under the host's `name`; FormData
67
- * submits its own entries instead (several values); null submits nothing.
68
- */
69
29
  value: (component: C, host: HTMLElement) => string | FormData | null;
70
- /** The inner control whose validity the element reports. */
71
30
  control?: (component: C) => HTMLInputElement | HTMLTextAreaElement | null;
72
- /** Events after which the form value is read again. */
73
31
  events?: readonly string[];
74
- /** Called when a `<label for>` or the host itself is clicked. */
75
32
  activate?: (component: C) => void;
76
- /**
77
- * The state the browser keeps for the control, to hand back through
78
- * `restore` when it restores the form (history navigation, autofill).
79
- */
80
33
  state?: (component: C) => string;
81
34
  restore?: (component: C, state: string) => void;
82
35
  disable?: (component: C, disabled: boolean) => void;
83
36
  }
84
- /** What a spec's `setup` sees of the element. */
85
37
  export interface ElementHost<C extends ElementComponent> extends HTMLElement {
86
- /** The factory instance, while connected. */
87
38
  readonly component: C | null;
88
39
  readonly internals: ElementInternals | null;
89
- /** The model was changed by the user or by script: its attributes no longer move it. */
90
40
  readonly dirty: boolean;
91
41
  }
92
- /**
93
- * What `defineElement` builds an element from: its name, the factory, the
94
- * styles its shadow root adopts, and how attributes, properties, slots,
95
- * events and the form map onto the component.
96
- *
97
- * @experimental The element authoring API (`defineElement`, `ElementSpec`,
98
- * `registerStyles`, `hasStyles`, `SHADOW_BASE_STYLES`) is outside semantic
99
- * versioning in 3.x: it may change in a minor release. The elements the
100
- * library defines, and their attributes, properties and events, are not.
101
- */
102
42
  export interface ElementSpec<C extends ElementComponent> {
103
- /** Name after the prefix: "switch" registers `<m-switch>`. */
104
43
  name: string;
105
44
  create: (config: Config) => C;
106
- /**
107
- * Whether renderElement may build this element's shadow root. Defaults to
108
- * true. False emits only the host and light DOM; a synchronous predicate
109
- * can opt out based on the authored host. Browser upgrade is unchanged.
110
- */
111
45
  ssr?: boolean | ((host: HTMLElement) => boolean);
112
- /** Style entries, in cascade order. */
113
46
  styles: readonly string[];
114
- /** CSS for the host, after the shared host rules. */
115
47
  hostStyles?: string;
116
- /**
117
- * A boolean attribute the host carries from the moment it connects, whatever
118
- * the tag prefix it was registered under. The library's sheets are built
119
- * once and cannot know the prefix a page chose, so a compound selector
120
- * that must recognise one of its own hosts — `::slotted([data-…])` in
121
- * another element's sheet, which cannot spell the tag — matches this
122
- * instead. Server rendering writes it into the declarative markup too, so
123
- * it is there at first paint, before upgrade. The attribute is the
124
- * library's own, in its reserved `data-mtrl-*` namespace: it is set on
125
- * connection (and again on reconnect) but not observed, so a consumer that
126
- * removes it while the host stays connected also removes the matching until
127
- * the host reconnects. Do not mutate it.
128
- *
129
- * @internal Not part of the public API and may change without notice.
130
- */
131
48
  marker?: string;
132
49
  attributes?: Record<string, AttributeSpec<C>>;
133
50
  properties?: Record<string, PropertySpec<C>>;
134
51
  methods?: readonly string[];
135
- /**
136
- * The live property two-way binding drives (`v-model`, Svelte's `bind:`).
137
- * Its attribute (the kebab-cased name) is its default: see `defaults`.
138
- */
139
52
  model?: string;
140
- /**
141
- * Live properties beyond `model` whose attribute is their default the same
142
- * way (the slider's `secondValue` and `second-value`). A change of such an
143
- * attribute moves the live state until the element is dirty, and a form
144
- * reset returns to it.
145
- */
146
53
  defaults?: readonly string[];
147
54
  events?: Record<string, EventSpec>;
148
55
  slot?: SlotSpec;
149
- /**
150
- * The named slots the element reads: a child with `slot="<name>"` goes
151
- * there. Declared `as const`, so the adapters type them (a Svelte snippet,
152
- * a Vue slot) and describe() lists them. check-elements proves each is
153
- * read and none other is.
154
- */
155
56
  slots?: readonly string[];
156
57
  form?: FormSpec<C>;
157
- /** Extra config read from the host, such as children. */
158
58
  config?: (host: HTMLElement) => Config;
159
- /** Wiring that lives as long as one component; returns its cleanup. */
160
59
  setup?: (host: ElementHost<C>, component: C) => (() => void) | void;
161
- /**
162
- * React to the host's children changing. `true` recreates the component; a
163
- * function updates it in place and returns false when it cannot, which
164
- * falls back to recreating.
165
- */
166
60
  observeChildren?: boolean | ((host: ElementHost<C>, component: C) => boolean);
167
61
  }
168
62
  export interface DefineOptions {
169
- /** Tag prefix, without the dash. Default "m". */
170
63
  prefix?: string;
171
64
  }
172
65
  export { DEFAULT_PREFIX };
173
- /**
174
- * Global base styles components rely on, which a shadow root does not inherit.
175
- * Registered under these names like the component entries.
176
- *
177
- * @experimental The element authoring API (`defineElement`, `ElementSpec`,
178
- * `registerStyles`, `hasStyles`, `SHADOW_BASE_STYLES`) is outside semantic
179
- * versioning in 3.x: it may change in a minor release. The elements the
180
- * library defines, and their attributes, properties and events, are not.
181
- */
182
- export declare const SHADOW_BASE_STYLES: readonly ["ripple"];
66
+ export declare const SHADOW_BASE_STYLES: readonly [
67
+ "ripple"
68
+ ];
183
69
  export declare const BASE_HOST_STYLES: string;
184
- /**
185
- * Internal shared host CSS, in browser cascade order. Beside a bare `:host`
186
- * display rule the base display declaration is dead (the later rule wins at
187
- * equal specificity) and would ride in every server-rendered root's inline
188
- * sheet, so it is not shipped for such an element — today the button (#42)
189
- * and the switch, whose inline-flex rule has made it dead since it landed.
190
- */
191
70
  export declare const hostStyleText: (spec: {
192
71
  hostStyles?: string;
193
72
  }) => string;
@@ -196,28 +75,21 @@ type ValueOf<T> = T extends "boolean" ? boolean : T extends "number" ? number :
196
75
  type Get<S, K extends string> = S extends {
197
76
  [P in K]: infer V;
198
77
  } ? V : Record<never, never>;
199
- /** Attributes as properties, camelCased: `supporting-text` is `supportingText`. */
200
78
  export type ElementAttributes<S> = {
201
79
  [K in keyof Get<S, "attributes"> & string as Camel<K>]?: Get<S, "attributes">[K] extends {
202
80
  type: infer T;
203
81
  } ? ValueOf<T> : never;
204
82
  };
205
- /**
206
- * Attributes as markup writes them (`supporting-text`), for a bare `m-*` tag
207
- * in JSX (`material/react/jsx`, `material/solid/jsx`).
208
- */
209
83
  export type ElementMarkup<S> = {
210
84
  [K in keyof Get<S, "attributes"> & string]?: Get<S, "attributes">[K] extends {
211
85
  type: infer T;
212
86
  } ? ValueOf<T> : never;
213
87
  } & ElementSlotText<S>;
214
- /** Live-state properties, typed by their getter. */
215
88
  export type ElementProperties<S> = {
216
89
  [K in keyof Get<S, "properties"> & string]?: Get<S, "properties">[K] extends {
217
90
  get: (c: never) => infer R;
218
91
  } ? R : unknown;
219
92
  };
220
- /** The slot's fallback-text attribute, when the spec has one. */
221
93
  export type ElementSlotText<S> = S extends {
222
94
  slot: {
223
95
  attribute: infer A extends string;
@@ -225,59 +97,29 @@ export type ElementSlotText<S> = S extends {
225
97
  } ? string extends A ? Record<never, never> : {
226
98
  [K in A]?: string;
227
99
  } : Record<never, never>;
228
- /** Event names to their `CustomEvent`, typed by the spec's `detail` mapper. */
229
100
  export type ElementEvents<S> = {
230
101
  [K in keyof Get<S, "events"> & string]: CustomEvent<Get<S, "events">[K] extends {
231
102
  detail: (p: never) => infer D;
232
103
  } ? D : unknown>;
233
104
  };
234
- /** Methods the element forwards to its component. */
235
105
  export type ElementMethods<S, C> = S extends {
236
106
  methods: readonly (infer M)[];
237
107
  } ? string extends M ? Record<never, never> : {
238
108
  [K in M & keyof C & string]: C[K] extends (...args: infer A) => unknown ? (...args: A) => unknown : never;
239
109
  } : Record<never, never>;
240
- /**
241
- * Every property an element instance has, beyond HTMLElement's. A live-state
242
- * property replaces the attribute of the same name: the `checked` property is
243
- * the switch's current state, the `checked` attribute only its default.
244
- */
245
110
  export type ElementProps<S> = Omit<ElementAttributes<S>, keyof ElementProperties<S>> & ElementProperties<S> & ElementSlotText<S>;
246
- /** The names of the element's named slots, from its spec's `slots`. */
247
111
  export type ElementSlots<S> = S extends {
248
112
  slots: readonly (infer N extends string)[];
249
113
  } ? N : never;
250
- /** A named slot as a prop name (`header-action` → `headerAction`), for adapters whose slots are props. */
251
114
  export type ElementSlotProp<S> = Camel<ElementSlots<S>>;
252
- /** An element instance, as a ref or `document.querySelector` returns it. */
253
115
  export type ElementInstance<S, C extends ElementComponent> = ElementHost<C> & ElementProps<S> & ElementMethods<S, C>;
254
- /** The element class for a spec. Called on first use, never at import. */
255
116
  export declare const createElementClass: <C extends ElementComponent>(spec: ElementSpec<C>) => CustomElementConstructor;
256
- /**
257
- * The class of a declaration element (`<m-tab>`): it renders nothing, and each
258
- * declared attribute has a property that reads and writes it. Frameworks that set
259
- * a custom element's props as properties (Solid always does) then reach the
260
- * attributes its parent reads, as frameworks that set attributes already did.
261
- * Called on first use, never at import.
262
- */
263
117
  export declare const createDeclarationClass: (attributes: Record<string, {
264
118
  type: AttributeType;
265
119
  }>) => CustomElementConstructor;
266
- /** A spec with its element class and registration. */
267
120
  export interface ElementDefinition<C extends ElementComponent> {
268
121
  spec: ElementSpec<C>;
269
- /** The element class, built on first access. Browser only. */
270
122
  readonly element: CustomElementConstructor;
271
- /** Registers the element; a repeated call is a no-op. Returns the tag. Browser only. */
272
123
  define: (options?: DefineOptions) => string;
273
124
  }
274
- /**
275
- * Creates the definition for a spec. Nothing is built or registered until
276
- * `element` or `define()` is used, so the module can be imported on a server.
277
- *
278
- * @experimental The element authoring API (`defineElement`, `ElementSpec`,
279
- * `registerStyles`, `hasStyles`, `SHADOW_BASE_STYLES`) is outside semantic
280
- * versioning in 3.x: it may change in a minor release. The elements the
281
- * library defines, and their attributes, properties and events, are not.
282
- */
283
125
  export declare const defineElement: <C extends ElementComponent>(spec: ElementSpec<C>) => ElementDefinition<C>;
@@ -1,45 +1,14 @@
1
- /**
2
- * `<m-dialog>`: the dialog as a custom element. It is the factory's top-layer
3
- * dialog (`layer: "top"`): a native `<dialog>` in the element's shadow root,
4
- * shown with `showModal()`, so it sits above every z-index and outside any
5
- * clipping ancestor, the page outside is inert, and the scrim is its
6
- * `::backdrop`. Its regions are slots:
7
- *
8
- * - `headline`: the headline, which names the dialog (the `headline`
9
- * attribute is its fallback text); without one, `aria-label` names it;
10
- * - the default slot: the supporting content, which describes it;
11
- * - `actions`: the buttons, at the end.
12
- *
13
- * `open` shows it and reflects its state, as on `<dialog open>`: Escape, a
14
- * click on the backdrop, the full-screen close button and `close()` remove
15
- * it. `show()` and `close()` are its methods. `open` and `close` are
16
- * dispatched as it opens and closes (not when the attribute is what changed),
17
- * and `cancel` when Escape asks it to close, which `preventDefault()` refuses.
18
- * `size` is the factory's (`small`, `medium`, `large`, `fullwidth`,
19
- * `fullscreen`), and `fullscreen` the full-screen dialog whatever `size`
20
- * says; a full-screen dialog has the close button, which `close-button`
21
- * gives any size. `subtitle` is the text below the headline, `divider`
22
- * draws the dividers above and below the content, and `footer-alignment`
23
- * places the actions (`right`, `left`, `center`, `space-between`).
24
- * `animation` is the factory's (`scale`, `slide-up`, `slide-down`, `fade`);
25
- * the factory reads it once, so a change recreates the dialog.
26
- * `no-close-on-scrim-click` and `no-close-on-escape` keep it open on a click
27
- * on the backdrop and on Escape (the factory's `closeOnOverlayClick` and
28
- * `closeOnEscape`); `cancel` is still dispatched on Escape.
29
- *
30
- * Parts: `dialog`, `header`, `header-content`, `header-title`, `content`, `footer`.
31
- *
32
- * @module elements
33
- */
34
1
  import type { DialogComponent } from "../components/dialog/types.js";
35
2
  import { type DefineOptions, type ElementInstance } from "./define.js";
36
- /** The dialog with the `show()` the element names after `<dialog>`'s. */
37
3
  export interface DialogElementComponent extends DialogComponent {
38
4
  show: () => DialogComponent;
39
5
  }
40
6
  declare const dialogSpec: {
41
7
  name: string;
42
- slots: readonly ["headline", "actions"];
8
+ slots: readonly [
9
+ "headline",
10
+ "actions"
11
+ ];
43
12
  create: (config: import("./define.js").Config) => DialogElementComponent;
44
13
  styles: string[];
45
14
  hostStyles: string;
@@ -96,7 +65,10 @@ declare const dialogSpec: {
96
65
  update: (c: DialogElementComponent, _v: import("./define.js").AttributeValue, host: HTMLElement) => void;
97
66
  };
98
67
  };
99
- methods: readonly ["show", "close"];
68
+ methods: readonly [
69
+ "show",
70
+ "close"
71
+ ];
100
72
  events: {
101
73
  open: {
102
74
  detail: () => null;
@@ -114,12 +86,9 @@ declare const dialogSpec: {
114
86
  };
115
87
  export declare const dialogElement: import("./define.js").ElementDefinition<DialogElementComponent>;
116
88
  export type DialogSpec = typeof dialogSpec;
117
- /** `<m-dialog>` as a ref or a query returns it. */
118
89
  export type DialogElement = ElementInstance<DialogSpec, DialogElementComponent>;
119
- /** Registers `<m-dialog>` (or `<prefix-dialog>`). */
120
90
  export declare const defineDialog: (options?: DefineOptions) => string;
121
91
  declare global {
122
- /** `document.querySelector("m-…")` and `createElement` return the element's type (the default prefix). */
123
92
  interface HTMLElementTagNameMap {
124
93
  "m-dialog": DialogElement;
125
94
  }
@@ -1,14 +1,3 @@
1
- /**
2
- * `<m-divider>`: the divider as a custom element. The factory renders an
3
- * `<hr>`, a separator, with `aria-orientation` when vertical.
4
- *
5
- * A horizontal divider fills its line; a vertical one stretches with its flex
6
- * or grid row.
7
- *
8
- * Parts: `divider`.
9
- *
10
- * @module elements
11
- */
12
1
  import type { DividerComponent } from "../components/divider/types.js";
13
2
  import { type DefineOptions, type ElementInstance } from "./define.js";
14
3
  declare const dividerSpec: {
@@ -49,12 +38,9 @@ declare const dividerSpec: {
49
38
  };
50
39
  export declare const dividerElement: import("./define.js").ElementDefinition<DividerComponent>;
51
40
  export type DividerSpec = typeof dividerSpec;
52
- /** `<m-divider>` as a ref or a query returns it. */
53
41
  export type DividerElement = ElementInstance<DividerSpec, DividerComponent>;
54
- /** Registers `<m-divider>` (or `<prefix-divider>`). */
55
42
  export declare const defineDivider: (options?: DefineOptions) => string;
56
43
  declare global {
57
- /** `document.querySelector("m-…")` and `createElement` return the element's type (the default prefix). */
58
44
  interface HTMLElementTagNameMap {
59
45
  "m-divider": DividerElement;
60
46
  }
@@ -1,30 +1,3 @@
1
- /**
2
- * `<m-drawer>` with `<m-drawer-item>` children: the standard (in-page)
3
- * navigation drawer.
4
- *
5
- * Each `<m-drawer-item>` declares one destination (`value`, `icon`, `badge`,
6
- * `disabled`, and its text as the label), or with `type="section"` a section
7
- * headline (its text) and with `type="divider"` a divider. The drawer reads
8
- * them into the factory's config and updates in place when they change; the
9
- * children stay where the framework put them. `value` on the drawer is the
10
- * default destination, which moves the live one until the user or script
11
- * changes it; the `value` property is the live one.
12
- *
13
- * `open` shows the drawer, as on the factory: without it the drawer is
14
- * collapsed to no width and inert. `modal` makes it the modal drawer in the
15
- * factory's top layer (`layer: "top"`): a native `<dialog>` in the element's
16
- * shadow root, shown with `showModal()`, above every z-index, the page
17
- * outside inert, the scrim its `::backdrop`. Escape and a click on the
18
- * backdrop close it, and `open` then reflects its state;
19
- * `no-close-on-scrim-click` and `no-close-on-escape` keep it open instead. `open` and `close`
20
- * are dispatched as it opens and closes (not when the attribute is what
21
- * changed).
22
- *
23
- * Parts: `drawer`, `sheet`, `items`, `item`, `active-indicator`, `item-icon`, `item-label`,
24
- * `ripple`.
25
- *
26
- * @module elements
27
- */
28
1
  import type { DrawerComponent } from "../components/drawer/types.js";
29
2
  import { type Config, type DefineOptions, type ElementAttributes, type ElementHost, type ElementInstance } from "./define.js";
30
3
  declare const drawerSpec: {
@@ -105,12 +78,7 @@ declare const drawerSpec: {
105
78
  };
106
79
  export declare const drawerElement: import("./define.js").ElementDefinition<DrawerComponent>;
107
80
  export type DrawerSpec = typeof drawerSpec;
108
- /** `<m-drawer>` as a ref or a query returns it. */
109
81
  export type DrawerElement = ElementInstance<DrawerSpec, DrawerComponent>;
110
- /**
111
- * `<m-drawer-item>` declares one destination, section headline or divider,
112
- * and renders nothing. Its text content is the label unless `label` is set.
113
- */
114
82
  export declare const drawerItemDeclaration: {
115
83
  readonly name: "drawer-item";
116
84
  readonly attributes: {
@@ -123,7 +91,6 @@ export declare const drawerItemDeclaration: {
123
91
  readonly label: {
124
92
  readonly type: "string";
125
93
  };
126
- /** Markup (HTML). Not sanitized by default: see Markup and sanitizing. */
127
94
  readonly icon: {
128
95
  readonly type: "string";
129
96
  };
@@ -136,10 +103,8 @@ export declare const drawerItemDeclaration: {
136
103
  };
137
104
  };
138
105
  export type DrawerItemAttributes = ElementAttributes<typeof drawerItemDeclaration>;
139
- /** Registers `<m-drawer>` and `<m-drawer-item>` (or with another prefix). */
140
106
  export declare const defineDrawer: (options?: DefineOptions) => string;
141
107
  declare global {
142
- /** `document.querySelector("m-…")` and `createElement` return the element's type (the default prefix). */
143
108
  interface HTMLElementTagNameMap {
144
109
  "m-drawer": DrawerElement;
145
110
  "m-drawer-item": HTMLElement & DrawerItemAttributes;
@@ -1,16 +1,3 @@
1
- /**
2
- * `<m-extended-fab>`: the extended floating action button as a custom
3
- * element. Children are the label.
4
- *
5
- * `variant`, `size`, `width`, `icon-position`, `position`,
6
- * `collapse-on-scroll` and `aria-label` have no setter on the extended FAB:
7
- * changing one recreates it. `type="submit"` and `type="reset"` act on the
8
- * host's form.
9
- *
10
- * Parts: `extended-fab`, `icon`, `label` (also `text`), `ripple`.
11
- *
12
- * @module elements
13
- */
14
1
  import type { ExtendedFabComponent } from "../components/extended-fab/types.js";
15
2
  import { type DefineOptions, type ElementInstance } from "./define.js";
16
3
  declare const extendedFabSpec: {
@@ -36,7 +23,6 @@ declare const extendedFabSpec: {
36
23
  config: string;
37
24
  update: (c: ExtendedFabComponent, v: import("./define.js").AttributeValue) => undefined;
38
25
  };
39
- /** Markup (HTML). Not sanitized by default: see Markup and sanitizing. */
40
26
  icon: {
41
27
  type: "string";
42
28
  config: string;
@@ -68,7 +54,12 @@ declare const extendedFabSpec: {
68
54
  config: string;
69
55
  };
70
56
  };
71
- methods: readonly ["lower", "raise", "collapse", "expand"];
57
+ methods: readonly [
58
+ "lower",
59
+ "raise",
60
+ "collapse",
61
+ "expand"
62
+ ];
72
63
  events: {
73
64
  collapse: {
74
65
  detail: () => null;
@@ -86,12 +77,9 @@ declare const extendedFabSpec: {
86
77
  };
87
78
  export declare const extendedFabElement: import("./define.js").ElementDefinition<ExtendedFabComponent>;
88
79
  export type ExtendedFabSpec = typeof extendedFabSpec;
89
- /** `<m-extended-fab>` as a ref or a query returns it. */
90
80
  export type ExtendedFabElement = ElementInstance<ExtendedFabSpec, ExtendedFabComponent>;
91
- /** Registers `<m-extended-fab>` (or `<prefix-extended-fab>`). */
92
81
  export declare const defineExtendedFab: (options?: DefineOptions) => string;
93
82
  declare global {
94
- /** `document.querySelector("m-…")` and `createElement` return the element's type (the default prefix). */
95
83
  interface HTMLElementTagNameMap {
96
84
  "m-extended-fab": ExtendedFabElement;
97
85
  }
@@ -1,30 +1,7 @@
1
- /**
2
- * `<m-fab-menu>` with `<m-fab-menu-item>` children.
3
- *
4
- * Each `<m-fab-menu-item>` declares one action: its text (or `label`),
5
- * `value` and `icon`. The FAB takes `icon` and `aria-label`, which names the
6
- * menu it opens. `color`, `size`, `presentation` and `placement` are the
7
- * factory's options: the expressive list below 600px, the baseline menu from
8
- * 600px, unless `presentation` says otherwise.
9
- *
10
- * `open` is state, as on `<m-menu>`: the attribute reflects whether the menu
11
- * is open, and setting or removing it opens or closes it. `show()`, `hide()`
12
- * and `toggle()` do the same. `open` and `close` are dispatched as it opens
13
- * and closes, by those methods or the user (not when the attribute or the
14
- * property is what changed: that is applied at once, and quietly), and
15
- * `select` with the item's value when one is chosen.
16
- *
17
- * Parts: `fab-menu`, `fab`, `list`, `item`.
18
- *
19
- * @module elements
20
- */
21
1
  import type { FabMenuComponent } from "../components/fab-menu/types.js";
22
2
  import { type Config, type DefineOptions, type ElementAttributes, type ElementInstance } from "./define.js";
23
- /** The FAB menu, with the methods the element adds to it. */
24
3
  export type FabMenuElementComponent = FabMenuComponent & {
25
- /** Opens the menu. */
26
4
  show: () => void;
27
- /** Closes the menu. */
28
5
  hide: () => void;
29
6
  };
30
7
  declare const fabMenuSpec: {
@@ -37,7 +14,6 @@ declare const fabMenuSpec: {
37
14
  type: "boolean";
38
15
  update: (c: FabMenuElementComponent, v: import("./define.js").AttributeValue) => void;
39
16
  };
40
- /** Markup (HTML). Not sanitized by default: see Markup and sanitizing. The menu opts out of server rendering, so the server leaves this escaped until the component upgrades. */
41
17
  icon: {
42
18
  type: "string";
43
19
  config: string;
@@ -64,7 +40,11 @@ declare const fabMenuSpec: {
64
40
  config: string;
65
41
  };
66
42
  };
67
- methods: readonly ["show", "hide", "toggle"];
43
+ methods: readonly [
44
+ "show",
45
+ "hide",
46
+ "toggle"
47
+ ];
68
48
  events: {
69
49
  open: {
70
50
  detail: () => {};
@@ -86,9 +66,7 @@ declare const fabMenuSpec: {
86
66
  };
87
67
  export declare const fabMenuElement: import("./define.js").ElementDefinition<FabMenuElementComponent>;
88
68
  export type FabMenuSpec = typeof fabMenuSpec;
89
- /** `<m-fab-menu>` as a ref or a query returns it. */
90
69
  export type FabMenuElement = ElementInstance<FabMenuSpec, FabMenuElementComponent>;
91
- /** `<m-fab-menu-item>` declares one action and renders nothing. Its text is the label unless `label` is set. */
92
70
  export declare const fabMenuItemDeclaration: {
93
71
  readonly name: "fab-menu-item";
94
72
  readonly attributes: {
@@ -98,17 +76,14 @@ export declare const fabMenuItemDeclaration: {
98
76
  readonly label: {
99
77
  readonly type: "string";
100
78
  };
101
- /** Markup (HTML). Not sanitized by default: see Markup and sanitizing. The menu opts out of server rendering, so the server leaves this escaped until the component upgrades. */
102
79
  readonly icon: {
103
80
  readonly type: "string";
104
81
  };
105
82
  };
106
83
  };
107
84
  export type FabMenuItemAttributes = ElementAttributes<typeof fabMenuItemDeclaration>;
108
- /** Registers `<m-fab-menu>` and `<m-fab-menu-item>` (or with another prefix). */
109
85
  export declare const defineFabMenu: (options?: DefineOptions) => string;
110
86
  declare global {
111
- /** `document.querySelector("m-…")` and `createElement` return the element's type (the default prefix). */
112
87
  interface HTMLElementTagNameMap {
113
88
  "m-fab-menu": FabMenuElement;
114
89
  "m-fab-menu-item": HTMLElement & FabMenuItemAttributes;