@angular/material 13.0.0-rc.0 → 13.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (834) hide show
  1. package/autocomplete/autocomplete_public_index.d.ts +4 -0
  2. package/autocomplete/index.d.ts +5 -1
  3. package/autocomplete/package.json +2 -2
  4. package/autocomplete/testing/autocomplete-harness.d.ts +4 -4
  5. package/badge/badge_public_index.d.ts +4 -0
  6. package/badge/index.d.ts +5 -1
  7. package/badge/package.json +2 -2
  8. package/bottom-sheet/bottom-sheet_public_index.d.ts +4 -0
  9. package/bottom-sheet/index.d.ts +5 -1
  10. package/bottom-sheet/package.json +2 -2
  11. package/button/button_public_index.d.ts +4 -0
  12. package/button/index.d.ts +5 -1
  13. package/button/package.json +2 -2
  14. package/button-toggle/button-toggle_public_index.d.ts +4 -0
  15. package/button-toggle/index.d.ts +5 -1
  16. package/button-toggle/package.json +2 -2
  17. package/card/card_public_index.d.ts +4 -0
  18. package/card/index.d.ts +5 -1
  19. package/card/package.json +2 -2
  20. package/checkbox/checkbox_public_index.d.ts +4 -0
  21. package/checkbox/index.d.ts +5 -1
  22. package/checkbox/package.json +2 -2
  23. package/chips/chips_public_index.d.ts +4 -0
  24. package/chips/index.d.ts +5 -1
  25. package/chips/package.json +2 -2
  26. package/core/common-behaviors/index.d.ts +1 -1
  27. package/core/core_public_index.d.ts +4 -0
  28. package/core/index.d.ts +5 -1
  29. package/core/package.json +2 -2
  30. package/datepicker/datepicker_public_index.d.ts +4 -0
  31. package/datepicker/index.d.ts +5 -1
  32. package/datepicker/package.json +2 -2
  33. package/dialog/dialog_public_index.d.ts +4 -0
  34. package/dialog/index.d.ts +5 -1
  35. package/dialog/package.json +2 -2
  36. package/divider/divider_public_index.d.ts +4 -0
  37. package/divider/index.d.ts +5 -1
  38. package/divider/package.json +2 -2
  39. package/esm2020/autocomplete/autocomplete-module.mjs +6 -19
  40. package/esm2020/autocomplete/autocomplete-origin.mjs +7 -7
  41. package/esm2020/autocomplete/autocomplete-trigger.mjs +36 -31
  42. package/esm2020/autocomplete/autocomplete.mjs +15 -15
  43. package/esm2020/autocomplete/autocomplete_public_index.mjs +5 -0
  44. package/esm2020/autocomplete/index.mjs +6 -2
  45. package/esm2020/autocomplete/testing/autocomplete-harness.mjs +7 -8
  46. package/esm2020/badge/badge-module.mjs +6 -13
  47. package/esm2020/badge/badge.mjs +16 -8
  48. package/esm2020/badge/badge_public_index.mjs +5 -0
  49. package/esm2020/badge/index.mjs +6 -2
  50. package/esm2020/badge/testing/badge-harness.mjs +2 -3
  51. package/esm2020/bottom-sheet/bottom-sheet-animations.mjs +2 -2
  52. package/esm2020/bottom-sheet/bottom-sheet-container.mjs +8 -6
  53. package/esm2020/bottom-sheet/bottom-sheet-module.mjs +6 -16
  54. package/esm2020/bottom-sheet/bottom-sheet-ref.mjs +10 -4
  55. package/esm2020/bottom-sheet/bottom-sheet.mjs +12 -11
  56. package/esm2020/bottom-sheet/bottom-sheet_public_index.mjs +5 -0
  57. package/esm2020/bottom-sheet/index.mjs +6 -2
  58. package/esm2020/bottom-sheet/testing/bottom-sheet-harness.mjs +1 -1
  59. package/esm2020/button/button-module.mjs +8 -25
  60. package/esm2020/button/button.mjs +7 -7
  61. package/esm2020/button/button_public_index.mjs +5 -0
  62. package/esm2020/button/index.mjs +6 -2
  63. package/esm2020/button/public-api.mjs +1 -1
  64. package/esm2020/button/testing/button-harness.mjs +2 -3
  65. package/esm2020/button-toggle/button-toggle-module.mjs +5 -5
  66. package/esm2020/button-toggle/button-toggle.mjs +31 -19
  67. package/esm2020/button-toggle/button-toggle_public_index.mjs +5 -0
  68. package/esm2020/button-toggle/index.mjs +6 -2
  69. package/esm2020/button-toggle/public-api.mjs +1 -1
  70. package/esm2020/button-toggle/testing/button-toggle-group-harness-filters.mjs +1 -1
  71. package/esm2020/button-toggle/testing/button-toggle-group-harness.mjs +3 -3
  72. package/esm2020/button-toggle/testing/button-toggle-harness.mjs +2 -2
  73. package/esm2020/card/card-module.mjs +32 -10
  74. package/esm2020/card/card.mjs +56 -56
  75. package/esm2020/card/card_public_index.mjs +5 -0
  76. package/esm2020/card/index.mjs +6 -2
  77. package/esm2020/card/public-api.mjs +1 -1
  78. package/esm2020/card/testing/card-harness.mjs +1 -1
  79. package/esm2020/checkbox/checkbox-config.mjs +2 -2
  80. package/esm2020/checkbox/checkbox-module.mjs +10 -16
  81. package/esm2020/checkbox/checkbox-required-validator.mjs +7 -7
  82. package/esm2020/checkbox/checkbox.mjs +35 -17
  83. package/esm2020/checkbox/checkbox_public_index.mjs +5 -0
  84. package/esm2020/checkbox/index.mjs +6 -2
  85. package/esm2020/checkbox/public-api.mjs +1 -1
  86. package/esm2020/checkbox/testing/checkbox-harness.mjs +3 -3
  87. package/esm2020/chips/chip-default-options.mjs +1 -1
  88. package/esm2020/chips/chip-input.mjs +21 -11
  89. package/esm2020/chips/chip-list.mjs +32 -17
  90. package/esm2020/chips/chip-text-control.mjs +1 -1
  91. package/esm2020/chips/chip.mjs +40 -31
  92. package/esm2020/chips/chips-module.mjs +12 -12
  93. package/esm2020/chips/chips_public_index.mjs +5 -0
  94. package/esm2020/chips/index.mjs +6 -2
  95. package/esm2020/chips/testing/chip-harness.mjs +2 -2
  96. package/esm2020/chips/testing/chip-input-harness.mjs +2 -2
  97. package/esm2020/chips/testing/chip-list-harness.mjs +5 -5
  98. package/esm2020/chips/testing/chip-listbox-harness.mjs +1 -1
  99. package/esm2020/chips/testing/chip-option-harness.mjs +1 -1
  100. package/esm2020/core/animation/animation.mjs +1 -1
  101. package/esm2020/core/common-behaviors/color.mjs +4 -2
  102. package/esm2020/core/common-behaviors/common-module.mjs +14 -9
  103. package/esm2020/core/common-behaviors/constructor.mjs +1 -1
  104. package/esm2020/core/common-behaviors/disable-ripple.mjs +7 -3
  105. package/esm2020/core/common-behaviors/disabled.mjs +7 -3
  106. package/esm2020/core/common-behaviors/error-state.mjs +1 -1
  107. package/esm2020/core/common-behaviors/index.mjs +1 -1
  108. package/esm2020/core/common-behaviors/initialized.mjs +1 -1
  109. package/esm2020/core/common-behaviors/tabindex.mjs +4 -2
  110. package/esm2020/core/core_public_index.mjs +5 -0
  111. package/esm2020/core/datetime/date-adapter.mjs +4 -4
  112. package/esm2020/core/datetime/date-formats.mjs +1 -1
  113. package/esm2020/core/datetime/index.mjs +10 -14
  114. package/esm2020/core/datetime/native-date-adapter.mjs +6 -6
  115. package/esm2020/core/datetime/native-date-formats.mjs +2 -2
  116. package/esm2020/core/error/error-options.mjs +7 -7
  117. package/esm2020/core/index.mjs +6 -2
  118. package/esm2020/core/line/line.mjs +10 -10
  119. package/esm2020/core/option/index.mjs +6 -6
  120. package/esm2020/core/option/optgroup.mjs +8 -8
  121. package/esm2020/core/option/option-parent.mjs +1 -1
  122. package/esm2020/core/option/option.mjs +22 -12
  123. package/esm2020/core/ripple/index.mjs +5 -5
  124. package/esm2020/core/ripple/ripple-ref.mjs +1 -1
  125. package/esm2020/core/ripple/ripple-renderer.mjs +8 -8
  126. package/esm2020/core/ripple/ripple.mjs +13 -9
  127. package/esm2020/core/selection/index.mjs +6 -6
  128. package/esm2020/core/selection/pseudo-checkbox/pseudo-checkbox.mjs +4 -4
  129. package/esm2020/core/testing/optgroup-harness.mjs +2 -3
  130. package/esm2020/core/testing/option-harness.mjs +2 -2
  131. package/esm2020/core/version.mjs +1 -1
  132. package/esm2020/datepicker/calendar-body.mjs +11 -7
  133. package/esm2020/datepicker/calendar.mjs +46 -32
  134. package/esm2020/datepicker/date-range-input-parts.mjs +31 -28
  135. package/esm2020/datepicker/date-range-input.mjs +26 -15
  136. package/esm2020/datepicker/date-range-picker.mjs +5 -5
  137. package/esm2020/datepicker/date-range-selection-strategy.mjs +4 -4
  138. package/esm2020/datepicker/date-selection-model.mjs +15 -14
  139. package/esm2020/datepicker/datepicker-actions.mjs +13 -13
  140. package/esm2020/datepicker/datepicker-animations.mjs +6 -6
  141. package/esm2020/datepicker/datepicker-base.mjs +42 -39
  142. package/esm2020/datepicker/datepicker-errors.mjs +1 -1
  143. package/esm2020/datepicker/datepicker-input-base.mjs +23 -18
  144. package/esm2020/datepicker/datepicker-input.mjs +18 -12
  145. package/esm2020/datepicker/datepicker-intl.mjs +4 -4
  146. package/esm2020/datepicker/datepicker-module.mjs +9 -18
  147. package/esm2020/datepicker/datepicker-toggle.mjs +15 -14
  148. package/esm2020/datepicker/datepicker.mjs +5 -5
  149. package/esm2020/datepicker/datepicker_public_index.mjs +5 -0
  150. package/esm2020/datepicker/index.mjs +6 -2
  151. package/esm2020/datepicker/month-view.mjs +40 -26
  152. package/esm2020/datepicker/multi-year-view.mjs +29 -19
  153. package/esm2020/datepicker/testing/calendar-cell-harness.mjs +1 -1
  154. package/esm2020/datepicker/testing/calendar-harness.mjs +1 -1
  155. package/esm2020/datepicker/testing/date-range-input-harness.mjs +4 -5
  156. package/esm2020/datepicker/testing/datepicker-input-harness-base.mjs +4 -4
  157. package/esm2020/datepicker/testing/datepicker-input-harness.mjs +1 -1
  158. package/esm2020/datepicker/testing/datepicker-toggle-harness.mjs +1 -1
  159. package/esm2020/datepicker/testing/datepicker-trigger-harness-base.mjs +2 -2
  160. package/esm2020/datepicker/year-view.mjs +32 -19
  161. package/esm2020/dialog/dialog-animations.mjs +2 -2
  162. package/esm2020/dialog/dialog-config.mjs +1 -1
  163. package/esm2020/dialog/dialog-container.mjs +14 -11
  164. package/esm2020/dialog/dialog-content-directives.mjs +16 -16
  165. package/esm2020/dialog/dialog-module.mjs +8 -24
  166. package/esm2020/dialog/dialog-ref.mjs +10 -5
  167. package/esm2020/dialog/dialog.mjs +25 -22
  168. package/esm2020/dialog/dialog_public_index.mjs +5 -0
  169. package/esm2020/dialog/index.mjs +6 -2
  170. package/esm2020/dialog/testing/dialog-harness.mjs +3 -3
  171. package/esm2020/divider/divider-module.mjs +5 -5
  172. package/esm2020/divider/divider.mjs +17 -9
  173. package/esm2020/divider/divider_public_index.mjs +5 -0
  174. package/esm2020/divider/index.mjs +6 -2
  175. package/esm2020/divider/testing/divider-harness-filters.mjs +1 -1
  176. package/esm2020/divider/testing/divider-harness.mjs +1 -1
  177. package/esm2020/expansion/accordion-base.mjs +1 -1
  178. package/esm2020/expansion/accordion.mjs +21 -13
  179. package/esm2020/expansion/expansion-animations.mjs +2 -2
  180. package/esm2020/expansion/expansion-module.mjs +5 -5
  181. package/esm2020/expansion/expansion-panel-content.mjs +5 -5
  182. package/esm2020/expansion/expansion-panel-header.mjs +21 -29
  183. package/esm2020/expansion/expansion-panel.mjs +16 -12
  184. package/esm2020/expansion/expansion_public_index.mjs +5 -0
  185. package/esm2020/expansion/index.mjs +6 -2
  186. package/esm2020/expansion/testing/accordion-harness.mjs +1 -1
  187. package/esm2020/expansion/testing/expansion-harness-filters.mjs +1 -1
  188. package/esm2020/expansion/testing/expansion-harness.mjs +3 -3
  189. package/esm2020/form-field/error.mjs +4 -4
  190. package/esm2020/form-field/form-field-animations.mjs +2 -2
  191. package/esm2020/form-field/form-field-control.mjs +4 -4
  192. package/esm2020/form-field/form-field-module.mjs +7 -31
  193. package/esm2020/form-field/form-field.mjs +47 -35
  194. package/esm2020/form-field/form-field_public_index.mjs +5 -0
  195. package/esm2020/form-field/hint.mjs +4 -4
  196. package/esm2020/form-field/index.mjs +6 -2
  197. package/esm2020/form-field/label.mjs +5 -5
  198. package/esm2020/form-field/placeholder.mjs +5 -5
  199. package/esm2020/form-field/prefix.mjs +4 -4
  200. package/esm2020/form-field/suffix.mjs +4 -4
  201. package/esm2020/form-field/testing/form-field-harness.mjs +12 -9
  202. package/esm2020/grid-list/grid-list-module.mjs +8 -8
  203. package/esm2020/grid-list/grid-list.mjs +26 -15
  204. package/esm2020/grid-list/grid-list_public_index.mjs +5 -0
  205. package/esm2020/grid-list/grid-tile.mjs +32 -24
  206. package/esm2020/grid-list/index.mjs +6 -2
  207. package/esm2020/grid-list/testing/grid-list-harness-filters.mjs +1 -1
  208. package/esm2020/grid-list/testing/grid-list-harness.mjs +9 -5
  209. package/esm2020/grid-list/testing/grid-tile-harness.mjs +1 -1
  210. package/esm2020/grid-list/tile-coordinator.mjs +5 -3
  211. package/esm2020/grid-list/tile-styler.mjs +7 -6
  212. package/esm2020/icon/fake-svgs.mjs +2 -2
  213. package/esm2020/icon/icon-module.mjs +5 -5
  214. package/esm2020/icon/icon-registry.mjs +9 -9
  215. package/esm2020/icon/icon.mjs +30 -20
  216. package/esm2020/icon/icon_public_index.mjs +5 -0
  217. package/esm2020/icon/index.mjs +6 -2
  218. package/esm2020/icon/public-api.mjs +1 -1
  219. package/esm2020/icon/testing/fake-icon-registry.mjs +9 -9
  220. package/esm2020/icon/testing/icon-harness-filters.mjs +1 -1
  221. package/esm2020/icon/testing/icon-harness.mjs +2 -2
  222. package/esm2020/icon/testing/index.mjs +6 -2
  223. package/esm2020/icon/testing/testing_public_index.mjs +5 -0
  224. package/esm2020/icon/trusted-types.mjs +1 -1
  225. package/esm2020/input/index.mjs +6 -2
  226. package/esm2020/input/input-module.mjs +6 -16
  227. package/esm2020/input/input-value-accessor.mjs +1 -1
  228. package/esm2020/input/input.mjs +48 -22
  229. package/esm2020/input/input_public_index.mjs +5 -0
  230. package/esm2020/input/public-api.mjs +1 -1
  231. package/esm2020/input/testing/input-harness.mjs +6 -6
  232. package/esm2020/input/testing/native-option-harness.mjs +3 -3
  233. package/esm2020/input/testing/native-select-harness.mjs +4 -4
  234. package/esm2020/list/index.mjs +6 -2
  235. package/esm2020/list/list-module.mjs +7 -7
  236. package/esm2020/list/list.mjs +28 -27
  237. package/esm2020/list/list_public_index.mjs +5 -0
  238. package/esm2020/list/public-api.mjs +1 -1
  239. package/esm2020/list/selection-list.mjs +40 -21
  240. package/esm2020/list/testing/action-list-harness.mjs +1 -1
  241. package/esm2020/list/testing/list-harness-base.mjs +12 -5
  242. package/esm2020/list/testing/list-harness.mjs +1 -1
  243. package/esm2020/list/testing/list-item-harness-base.mjs +5 -7
  244. package/esm2020/list/testing/nav-list-harness.mjs +2 -3
  245. package/esm2020/list/testing/selection-list-harness.mjs +9 -9
  246. package/esm2020/menu/index.mjs +6 -2
  247. package/esm2020/menu/menu-animations.mjs +7 -7
  248. package/esm2020/menu/menu-content.mjs +7 -7
  249. package/esm2020/menu/menu-errors.mjs +1 -1
  250. package/esm2020/menu/menu-item.mjs +4 -4
  251. package/esm2020/menu/menu-module.mjs +8 -21
  252. package/esm2020/menu/menu-panel.mjs +1 -1
  253. package/esm2020/menu/menu-trigger.mjs +31 -22
  254. package/esm2020/menu/menu.mjs +33 -30
  255. package/esm2020/menu/menu_public_index.mjs +5 -0
  256. package/esm2020/menu/public-api.mjs +2 -2
  257. package/esm2020/menu/testing/menu-harness.mjs +4 -5
  258. package/esm2020/paginator/index.mjs +6 -2
  259. package/esm2020/paginator/paginator-intl.mjs +6 -8
  260. package/esm2020/paginator/paginator-module.mjs +6 -22
  261. package/esm2020/paginator/paginator.mjs +30 -19
  262. package/esm2020/paginator/paginator_public_index.mjs +5 -0
  263. package/esm2020/paginator/public-api.mjs +1 -1
  264. package/esm2020/paginator/testing/paginator-harness-filters.mjs +1 -1
  265. package/esm2020/paginator/testing/paginator-harness.mjs +2 -2
  266. package/esm2020/progress-bar/index.mjs +6 -2
  267. package/esm2020/progress-bar/progress-bar-module.mjs +5 -5
  268. package/esm2020/progress-bar/progress-bar.mjs +23 -18
  269. package/esm2020/progress-bar/progress-bar_public_index.mjs +5 -0
  270. package/esm2020/progress-bar/public-api.mjs +1 -1
  271. package/esm2020/progress-bar/testing/progress-bar-harness.mjs +1 -1
  272. package/esm2020/progress-spinner/index.mjs +6 -2
  273. package/esm2020/progress-spinner/progress-spinner-module.mjs +7 -17
  274. package/esm2020/progress-spinner/progress-spinner.mjs +16 -14
  275. package/esm2020/progress-spinner/progress-spinner_public_index.mjs +5 -0
  276. package/esm2020/progress-spinner/testing/progress-spinner-harness.mjs +2 -2
  277. package/esm2020/radio/index.mjs +6 -2
  278. package/esm2020/radio/public-api.mjs +1 -1
  279. package/esm2020/radio/radio-module.mjs +5 -5
  280. package/esm2020/radio/radio.mjs +52 -36
  281. package/esm2020/radio/radio_public_index.mjs +5 -0
  282. package/esm2020/radio/testing/radio-harness.mjs +3 -4
  283. package/esm2020/select/index.mjs +6 -2
  284. package/esm2020/select/public-api.mjs +2 -2
  285. package/esm2020/select/select-animations.mjs +7 -7
  286. package/esm2020/select/select-module.mjs +8 -21
  287. package/esm2020/select/select.mjs +70 -53
  288. package/esm2020/select/select_public_index.mjs +5 -0
  289. package/esm2020/select/testing/select-harness.mjs +9 -6
  290. package/esm2020/sidenav/drawer-animations.mjs +3 -3
  291. package/esm2020/sidenav/drawer.mjs +79 -43
  292. package/esm2020/sidenav/index.mjs +6 -2
  293. package/esm2020/sidenav/sidenav-module.mjs +7 -20
  294. package/esm2020/sidenav/sidenav.mjs +39 -23
  295. package/esm2020/sidenav/sidenav_public_index.mjs +5 -0
  296. package/esm2020/sidenav/testing/drawer-container-harness.mjs +1 -1
  297. package/esm2020/sidenav/testing/drawer-content-harness.mjs +1 -1
  298. package/esm2020/sidenav/testing/drawer-harness.mjs +2 -3
  299. package/esm2020/sidenav/testing/sidenav-container-harness.mjs +1 -1
  300. package/esm2020/sidenav/testing/sidenav-content-harness.mjs +1 -1
  301. package/esm2020/sidenav/testing/sidenav-harness.mjs +2 -3
  302. package/esm2020/slide-toggle/index.mjs +6 -2
  303. package/esm2020/slide-toggle/slide-toggle-config.mjs +2 -2
  304. package/esm2020/slide-toggle/slide-toggle-module.mjs +11 -16
  305. package/esm2020/slide-toggle/slide-toggle-required-validator.mjs +7 -7
  306. package/esm2020/slide-toggle/slide-toggle.mjs +19 -13
  307. package/esm2020/slide-toggle/slide-toggle_public_index.mjs +5 -0
  308. package/esm2020/slide-toggle/testing/slide-toggle-harness.mjs +3 -3
  309. package/esm2020/slider/index.mjs +6 -2
  310. package/esm2020/slider/public-api.mjs +1 -1
  311. package/esm2020/slider/slider-module.mjs +5 -5
  312. package/esm2020/slider/slider.mjs +52 -33
  313. package/esm2020/slider/slider_public_index.mjs +5 -0
  314. package/esm2020/slider/testing/slider-harness.mjs +6 -2
  315. package/esm2020/snack-bar/index.mjs +6 -2
  316. package/esm2020/snack-bar/simple-snack-bar.mjs +4 -4
  317. package/esm2020/snack-bar/snack-bar-animations.mjs +3 -3
  318. package/esm2020/snack-bar/snack-bar-container.mjs +5 -5
  319. package/esm2020/snack-bar/snack-bar-module.mjs +6 -22
  320. package/esm2020/snack-bar/snack-bar-ref.mjs +1 -1
  321. package/esm2020/snack-bar/snack-bar.mjs +14 -11
  322. package/esm2020/snack-bar/snack-bar_public_index.mjs +5 -0
  323. package/esm2020/snack-bar/testing/snack-bar-harness.mjs +5 -6
  324. package/esm2020/sort/index.mjs +6 -2
  325. package/esm2020/sort/sort-animations.mjs +11 -26
  326. package/esm2020/sort/sort-header-intl.mjs +5 -5
  327. package/esm2020/sort/sort-header.mjs +32 -29
  328. package/esm2020/sort/sort-module.mjs +6 -6
  329. package/esm2020/sort/sort.mjs +19 -12
  330. package/esm2020/sort/sort_public_index.mjs +5 -0
  331. package/esm2020/sort/testing/sort-harness-filters.mjs +1 -1
  332. package/esm2020/sort/testing/sort-harness.mjs +1 -1
  333. package/esm2020/sort/testing/sort-header-harness.mjs +1 -1
  334. package/esm2020/stepper/index.mjs +6 -2
  335. package/esm2020/stepper/step-content.mjs +5 -5
  336. package/esm2020/stepper/step-header.mjs +5 -5
  337. package/esm2020/stepper/step-label.mjs +4 -4
  338. package/esm2020/stepper/stepper-animations.mjs +4 -4
  339. package/esm2020/stepper/stepper-button.mjs +9 -9
  340. package/esm2020/stepper/stepper-icon.mjs +4 -4
  341. package/esm2020/stepper/stepper-intl.mjs +5 -5
  342. package/esm2020/stepper/stepper-module.mjs +5 -5
  343. package/esm2020/stepper/stepper.mjs +25 -21
  344. package/esm2020/stepper/stepper_public_index.mjs +5 -0
  345. package/esm2020/stepper/testing/step-harness-filters.mjs +1 -1
  346. package/esm2020/stepper/testing/step-harness.mjs +1 -1
  347. package/esm2020/stepper/testing/stepper-button-harnesses.mjs +3 -5
  348. package/esm2020/stepper/testing/stepper-harness.mjs +5 -5
  349. package/esm2020/table/cell.mjs +33 -29
  350. package/esm2020/table/index.mjs +6 -2
  351. package/esm2020/table/row.mjs +23 -23
  352. package/esm2020/table/table-data-source.mjs +30 -21
  353. package/esm2020/table/table-module.mjs +8 -15
  354. package/esm2020/table/table.mjs +10 -14
  355. package/esm2020/table/table_public_index.mjs +5 -0
  356. package/esm2020/table/testing/cell-harness.mjs +6 -3
  357. package/esm2020/table/testing/row-harness.mjs +2 -2
  358. package/esm2020/table/testing/table-harness-filters.mjs +1 -1
  359. package/esm2020/table/testing/table-harness.mjs +3 -3
  360. package/esm2020/table/text-column.mjs +4 -4
  361. package/esm2020/tabs/index.mjs +6 -2
  362. package/esm2020/tabs/ink-bar.mjs +5 -5
  363. package/esm2020/tabs/paginated-tab-header.mjs +19 -12
  364. package/esm2020/tabs/public-api.mjs +2 -2
  365. package/esm2020/tabs/tab-body.mjs +16 -16
  366. package/esm2020/tabs/tab-content.mjs +5 -6
  367. package/esm2020/tabs/tab-group.mjs +48 -33
  368. package/esm2020/tabs/tab-header.mjs +13 -9
  369. package/esm2020/tabs/tab-label-wrapper.mjs +5 -5
  370. package/esm2020/tabs/tab-label.mjs +4 -4
  371. package/esm2020/tabs/tab-nav-bar/tab-nav-bar.mjs +31 -21
  372. package/esm2020/tabs/tab.mjs +10 -6
  373. package/esm2020/tabs/tabs-animations.mjs +5 -5
  374. package/esm2020/tabs/tabs-module.mjs +5 -5
  375. package/esm2020/tabs/tabs_public_index.mjs +5 -0
  376. package/esm2020/tabs/testing/tab-group-harness.mjs +2 -3
  377. package/esm2020/tabs/testing/tab-harness.mjs +2 -3
  378. package/esm2020/tabs/testing/tab-link-harness.mjs +2 -3
  379. package/esm2020/toolbar/index.mjs +6 -2
  380. package/esm2020/toolbar/public-api.mjs +1 -1
  381. package/esm2020/toolbar/testing/toolbar-harness.mjs +3 -4
  382. package/esm2020/toolbar/toolbar-module.mjs +5 -5
  383. package/esm2020/toolbar/toolbar.mjs +7 -7
  384. package/esm2020/toolbar/toolbar_public_index.mjs +5 -0
  385. package/esm2020/tooltip/index.mjs +6 -2
  386. package/esm2020/tooltip/tooltip-animations.mjs +3 -3
  387. package/esm2020/tooltip/tooltip-module.mjs +7 -20
  388. package/esm2020/tooltip/tooltip.mjs +67 -42
  389. package/esm2020/tooltip/tooltip_public_index.mjs +5 -0
  390. package/esm2020/tree/data-source/flat-data-source.mjs +4 -2
  391. package/esm2020/tree/data-source/nested-data-source.mjs +8 -5
  392. package/esm2020/tree/index.mjs +6 -2
  393. package/esm2020/tree/node.mjs +26 -22
  394. package/esm2020/tree/outlet.mjs +14 -10
  395. package/esm2020/tree/padding.mjs +17 -9
  396. package/esm2020/tree/public-api.mjs +1 -1
  397. package/esm2020/tree/testing/node-harness.mjs +1 -1
  398. package/esm2020/tree/testing/tree-harness-filters.mjs +1 -1
  399. package/esm2020/tree/testing/tree-harness.mjs +2 -2
  400. package/esm2020/tree/toggle.mjs +8 -6
  401. package/esm2020/tree/tree-module.mjs +6 -6
  402. package/esm2020/tree/tree.mjs +4 -4
  403. package/esm2020/tree/tree_public_index.mjs +5 -0
  404. package/expansion/expansion_public_index.d.ts +4 -0
  405. package/expansion/index.d.ts +5 -1
  406. package/expansion/package.json +2 -2
  407. package/fesm2015/autocomplete/testing.mjs +2 -3
  408. package/fesm2015/autocomplete/testing.mjs.map +1 -1
  409. package/fesm2015/autocomplete.mjs +67 -67
  410. package/fesm2015/autocomplete.mjs.map +1 -1
  411. package/fesm2015/badge/testing.mjs +1 -2
  412. package/fesm2015/badge/testing.mjs.map +1 -1
  413. package/fesm2015/badge.mjs +28 -19
  414. package/fesm2015/badge.mjs.map +1 -1
  415. package/fesm2015/bottom-sheet/testing.mjs.map +1 -1
  416. package/fesm2015/bottom-sheet.mjs +41 -34
  417. package/fesm2015/bottom-sheet.mjs.map +1 -1
  418. package/fesm2015/button/testing.mjs +1 -2
  419. package/fesm2015/button/testing.mjs.map +1 -1
  420. package/fesm2015/button-toggle/testing.mjs.map +1 -1
  421. package/fesm2015/button-toggle.mjs +41 -21
  422. package/fesm2015/button-toggle.mjs.map +1 -1
  423. package/fesm2015/button.mjs +21 -30
  424. package/fesm2015/button.mjs.map +1 -1
  425. package/fesm2015/card/testing.mjs.map +1 -1
  426. package/fesm2015/card.mjs +94 -64
  427. package/fesm2015/card.mjs.map +1 -1
  428. package/fesm2015/checkbox/testing.mjs +2 -2
  429. package/fesm2015/checkbox/testing.mjs.map +1 -1
  430. package/fesm2015/checkbox.mjs +56 -36
  431. package/fesm2015/checkbox.mjs.map +1 -1
  432. package/fesm2015/chips/testing.mjs +2 -2
  433. package/fesm2015/chips/testing.mjs.map +1 -1
  434. package/fesm2015/chips.mjs +107 -65
  435. package/fesm2015/chips.mjs.map +1 -1
  436. package/fesm2015/core/testing.mjs +1 -2
  437. package/fesm2015/core/testing.mjs.map +1 -1
  438. package/fesm2015/core.mjs +134 -99
  439. package/fesm2015/core.mjs.map +1 -1
  440. package/fesm2015/datepicker/testing.mjs +5 -6
  441. package/fesm2015/datepicker/testing.mjs.map +1 -1
  442. package/fesm2015/datepicker.mjs +355 -271
  443. package/fesm2015/datepicker.mjs.map +1 -1
  444. package/fesm2015/dialog/testing.mjs +2 -2
  445. package/fesm2015/dialog/testing.mjs.map +1 -1
  446. package/fesm2015/dialog.mjs +75 -72
  447. package/fesm2015/dialog.mjs.map +1 -1
  448. package/fesm2015/divider/testing.mjs.map +1 -1
  449. package/fesm2015/divider.mjs +28 -12
  450. package/fesm2015/divider.mjs.map +1 -1
  451. package/fesm2015/expansion/testing.mjs.map +1 -1
  452. package/fesm2015/expansion.mjs +71 -59
  453. package/fesm2015/expansion.mjs.map +1 -1
  454. package/fesm2015/form-field/testing.mjs +5 -2
  455. package/fesm2015/form-field/testing.mjs.map +1 -1
  456. package/fesm2015/form-field.mjs +83 -87
  457. package/fesm2015/form-field.mjs.map +1 -1
  458. package/fesm2015/grid-list/testing.mjs +8 -4
  459. package/fesm2015/grid-list/testing.mjs.map +1 -1
  460. package/fesm2015/grid-list.mjs +80 -50
  461. package/fesm2015/grid-list.mjs.map +1 -1
  462. package/fesm2015/icon/testing.mjs +16 -8
  463. package/fesm2015/icon/testing.mjs.map +1 -1
  464. package/fesm2015/icon.mjs +49 -31
  465. package/fesm2015/icon.mjs.map +1 -1
  466. package/fesm2015/input/testing.mjs +8 -8
  467. package/fesm2015/input/testing.mjs.map +1 -1
  468. package/fesm2015/input.mjs +59 -35
  469. package/fesm2015/input.mjs.map +1 -1
  470. package/fesm2015/list/testing.mjs +17 -13
  471. package/fesm2015/list/testing.mjs.map +1 -1
  472. package/fesm2015/list.mjs +77 -50
  473. package/fesm2015/list.mjs.map +1 -1
  474. package/fesm2015/menu/testing.mjs +1 -2
  475. package/fesm2015/menu/testing.mjs.map +1 -1
  476. package/fesm2015/menu.mjs +92 -85
  477. package/fesm2015/menu.mjs.map +1 -1
  478. package/fesm2015/paginator/testing.mjs +1 -1
  479. package/fesm2015/paginator/testing.mjs.map +1 -1
  480. package/fesm2015/paginator.mjs +46 -45
  481. package/fesm2015/paginator.mjs.map +1 -1
  482. package/fesm2015/progress-bar/testing.mjs.map +1 -1
  483. package/fesm2015/progress-bar.mjs +34 -21
  484. package/fesm2015/progress-bar.mjs.map +1 -1
  485. package/fesm2015/progress-spinner/testing.mjs +1 -1
  486. package/fesm2015/progress-spinner/testing.mjs.map +1 -1
  487. package/fesm2015/progress-spinner.mjs +29 -29
  488. package/fesm2015/progress-spinner.mjs.map +1 -1
  489. package/fesm2015/radio/testing.mjs +1 -2
  490. package/fesm2015/radio/testing.mjs.map +1 -1
  491. package/fesm2015/radio.mjs +63 -39
  492. package/fesm2015/radio.mjs.map +1 -1
  493. package/fesm2015/select/testing.mjs +4 -1
  494. package/fesm2015/select/testing.mjs.map +1 -1
  495. package/fesm2015/select.mjs +89 -77
  496. package/fesm2015/select.mjs.map +1 -1
  497. package/fesm2015/sidenav/testing.mjs +2 -4
  498. package/fesm2015/sidenav/testing.mjs.map +1 -1
  499. package/fesm2015/sidenav.mjs +130 -83
  500. package/fesm2015/sidenav.mjs.map +1 -1
  501. package/fesm2015/slide-toggle/testing.mjs +2 -2
  502. package/fesm2015/slide-toggle/testing.mjs.map +1 -1
  503. package/fesm2015/slide-toggle.mjs +40 -31
  504. package/fesm2015/slide-toggle.mjs.map +1 -1
  505. package/fesm2015/slider/testing.mjs +5 -1
  506. package/fesm2015/slider/testing.mjs.map +1 -1
  507. package/fesm2015/slider.mjs +62 -35
  508. package/fesm2015/slider.mjs.map +1 -1
  509. package/fesm2015/snack-bar/testing.mjs +1 -2
  510. package/fesm2015/snack-bar/testing.mjs.map +1 -1
  511. package/fesm2015/snack-bar.mjs +35 -40
  512. package/fesm2015/snack-bar.mjs.map +1 -1
  513. package/fesm2015/sort/testing.mjs.map +1 -1
  514. package/fesm2015/sort.mjs +74 -70
  515. package/fesm2015/sort.mjs.map +1 -1
  516. package/fesm2015/stepper/testing.mjs +6 -8
  517. package/fesm2015/stepper/testing.mjs.map +1 -1
  518. package/fesm2015/stepper.mjs +65 -53
  519. package/fesm2015/stepper.mjs.map +1 -1
  520. package/fesm2015/table/testing.mjs +7 -4
  521. package/fesm2015/table/testing.mjs.map +1 -1
  522. package/fesm2015/table.mjs +106 -96
  523. package/fesm2015/table.mjs.map +1 -1
  524. package/fesm2015/tabs/testing.mjs +3 -6
  525. package/fesm2015/tabs/testing.mjs.map +1 -1
  526. package/fesm2015/tabs.mjs +161 -114
  527. package/fesm2015/tabs.mjs.map +1 -1
  528. package/fesm2015/toolbar/testing.mjs +2 -3
  529. package/fesm2015/toolbar/testing.mjs.map +1 -1
  530. package/fesm2015/toolbar.mjs +18 -10
  531. package/fesm2015/toolbar.mjs.map +1 -1
  532. package/fesm2015/tooltip.mjs +82 -62
  533. package/fesm2015/tooltip.mjs.map +1 -1
  534. package/fesm2015/tree/testing.mjs +1 -1
  535. package/fesm2015/tree/testing.mjs.map +1 -1
  536. package/fesm2015/tree.mjs +85 -54
  537. package/fesm2015/tree.mjs.map +1 -1
  538. package/fesm2020/autocomplete/testing.mjs +5 -6
  539. package/fesm2020/autocomplete/testing.mjs.map +1 -1
  540. package/fesm2020/autocomplete.mjs +67 -67
  541. package/fesm2020/autocomplete.mjs.map +1 -1
  542. package/fesm2020/badge/testing.mjs +1 -2
  543. package/fesm2020/badge/testing.mjs.map +1 -1
  544. package/fesm2020/badge.mjs +28 -19
  545. package/fesm2020/badge.mjs.map +1 -1
  546. package/fesm2020/bottom-sheet/testing.mjs.map +1 -1
  547. package/fesm2020/bottom-sheet.mjs +41 -34
  548. package/fesm2020/bottom-sheet.mjs.map +1 -1
  549. package/fesm2020/button/testing.mjs +1 -2
  550. package/fesm2020/button/testing.mjs.map +1 -1
  551. package/fesm2020/button-toggle/testing.mjs +3 -3
  552. package/fesm2020/button-toggle/testing.mjs.map +1 -1
  553. package/fesm2020/button-toggle.mjs +41 -21
  554. package/fesm2020/button-toggle.mjs.map +1 -1
  555. package/fesm2020/button.mjs +21 -30
  556. package/fesm2020/button.mjs.map +1 -1
  557. package/fesm2020/card/testing.mjs.map +1 -1
  558. package/fesm2020/card.mjs +94 -64
  559. package/fesm2020/card.mjs.map +1 -1
  560. package/fesm2020/checkbox/testing.mjs +2 -2
  561. package/fesm2020/checkbox/testing.mjs.map +1 -1
  562. package/fesm2020/checkbox.mjs +56 -36
  563. package/fesm2020/checkbox.mjs.map +1 -1
  564. package/fesm2020/chips/testing.mjs +6 -6
  565. package/fesm2020/chips/testing.mjs.map +1 -1
  566. package/fesm2020/chips.mjs +107 -65
  567. package/fesm2020/chips.mjs.map +1 -1
  568. package/fesm2020/core/testing.mjs +2 -3
  569. package/fesm2020/core/testing.mjs.map +1 -1
  570. package/fesm2020/core.mjs +135 -100
  571. package/fesm2020/core.mjs.map +1 -1
  572. package/fesm2020/datepicker/testing.mjs +6 -7
  573. package/fesm2020/datepicker/testing.mjs.map +1 -1
  574. package/fesm2020/datepicker.mjs +355 -271
  575. package/fesm2020/datepicker.mjs.map +1 -1
  576. package/fesm2020/dialog/testing.mjs +2 -2
  577. package/fesm2020/dialog/testing.mjs.map +1 -1
  578. package/fesm2020/dialog.mjs +75 -72
  579. package/fesm2020/dialog.mjs.map +1 -1
  580. package/fesm2020/divider/testing.mjs.map +1 -1
  581. package/fesm2020/divider.mjs +28 -12
  582. package/fesm2020/divider.mjs.map +1 -1
  583. package/fesm2020/expansion/testing.mjs +2 -2
  584. package/fesm2020/expansion/testing.mjs.map +1 -1
  585. package/fesm2020/expansion.mjs +71 -59
  586. package/fesm2020/expansion.mjs.map +1 -1
  587. package/fesm2020/form-field/testing.mjs +10 -7
  588. package/fesm2020/form-field/testing.mjs.map +1 -1
  589. package/fesm2020/form-field.mjs +83 -87
  590. package/fesm2020/form-field.mjs.map +1 -1
  591. package/fesm2020/grid-list/testing.mjs +8 -4
  592. package/fesm2020/grid-list/testing.mjs.map +1 -1
  593. package/fesm2020/grid-list.mjs +80 -50
  594. package/fesm2020/grid-list.mjs.map +1 -1
  595. package/fesm2020/icon/testing.mjs +17 -9
  596. package/fesm2020/icon/testing.mjs.map +1 -1
  597. package/fesm2020/icon.mjs +49 -31
  598. package/fesm2020/icon.mjs.map +1 -1
  599. package/fesm2020/input/testing.mjs +10 -10
  600. package/fesm2020/input/testing.mjs.map +1 -1
  601. package/fesm2020/input.mjs +59 -35
  602. package/fesm2020/input.mjs.map +1 -1
  603. package/fesm2020/list/testing.mjs +23 -19
  604. package/fesm2020/list/testing.mjs.map +1 -1
  605. package/fesm2020/list.mjs +79 -51
  606. package/fesm2020/list.mjs.map +1 -1
  607. package/fesm2020/menu/testing.mjs +3 -4
  608. package/fesm2020/menu/testing.mjs.map +1 -1
  609. package/fesm2020/menu.mjs +92 -85
  610. package/fesm2020/menu.mjs.map +1 -1
  611. package/fesm2020/paginator/testing.mjs +1 -1
  612. package/fesm2020/paginator/testing.mjs.map +1 -1
  613. package/fesm2020/paginator.mjs +46 -45
  614. package/fesm2020/paginator.mjs.map +1 -1
  615. package/fesm2020/progress-bar/testing.mjs.map +1 -1
  616. package/fesm2020/progress-bar.mjs +34 -21
  617. package/fesm2020/progress-bar.mjs.map +1 -1
  618. package/fesm2020/progress-spinner/testing.mjs +1 -1
  619. package/fesm2020/progress-spinner/testing.mjs.map +1 -1
  620. package/fesm2020/progress-spinner.mjs +29 -29
  621. package/fesm2020/progress-spinner.mjs.map +1 -1
  622. package/fesm2020/radio/testing.mjs +2 -3
  623. package/fesm2020/radio/testing.mjs.map +1 -1
  624. package/fesm2020/radio.mjs +63 -39
  625. package/fesm2020/radio.mjs.map +1 -1
  626. package/fesm2020/select/testing.mjs +8 -5
  627. package/fesm2020/select/testing.mjs.map +1 -1
  628. package/fesm2020/select.mjs +89 -77
  629. package/fesm2020/select.mjs.map +1 -1
  630. package/fesm2020/sidenav/testing.mjs +2 -4
  631. package/fesm2020/sidenav/testing.mjs.map +1 -1
  632. package/fesm2020/sidenav.mjs +130 -83
  633. package/fesm2020/sidenav.mjs.map +1 -1
  634. package/fesm2020/slide-toggle/testing.mjs +2 -2
  635. package/fesm2020/slide-toggle/testing.mjs.map +1 -1
  636. package/fesm2020/slide-toggle.mjs +40 -31
  637. package/fesm2020/slide-toggle.mjs.map +1 -1
  638. package/fesm2020/slider/testing.mjs +5 -1
  639. package/fesm2020/slider/testing.mjs.map +1 -1
  640. package/fesm2020/slider.mjs +62 -35
  641. package/fesm2020/slider.mjs.map +1 -1
  642. package/fesm2020/snack-bar/testing.mjs +4 -5
  643. package/fesm2020/snack-bar/testing.mjs.map +1 -1
  644. package/fesm2020/snack-bar.mjs +35 -40
  645. package/fesm2020/snack-bar.mjs.map +1 -1
  646. package/fesm2020/sort/testing.mjs.map +1 -1
  647. package/fesm2020/sort.mjs +75 -72
  648. package/fesm2020/sort.mjs.map +1 -1
  649. package/fesm2020/stepper/testing.mjs +6 -8
  650. package/fesm2020/stepper/testing.mjs.map +1 -1
  651. package/fesm2020/stepper.mjs +65 -53
  652. package/fesm2020/stepper.mjs.map +1 -1
  653. package/fesm2020/table/testing.mjs +7 -4
  654. package/fesm2020/table/testing.mjs.map +1 -1
  655. package/fesm2020/table.mjs +106 -96
  656. package/fesm2020/table.mjs.map +1 -1
  657. package/fesm2020/tabs/testing.mjs +3 -6
  658. package/fesm2020/tabs/testing.mjs.map +1 -1
  659. package/fesm2020/tabs.mjs +161 -114
  660. package/fesm2020/tabs.mjs.map +1 -1
  661. package/fesm2020/toolbar/testing.mjs +2 -3
  662. package/fesm2020/toolbar/testing.mjs.map +1 -1
  663. package/fesm2020/toolbar.mjs +18 -10
  664. package/fesm2020/toolbar.mjs.map +1 -1
  665. package/fesm2020/tooltip.mjs +82 -62
  666. package/fesm2020/tooltip.mjs.map +1 -1
  667. package/fesm2020/tree/testing.mjs +1 -1
  668. package/fesm2020/tree/testing.mjs.map +1 -1
  669. package/fesm2020/tree.mjs +85 -54
  670. package/fesm2020/tree.mjs.map +1 -1
  671. package/form-field/form-field_public_index.d.ts +4 -0
  672. package/form-field/index.d.ts +5 -1
  673. package/form-field/package.json +2 -2
  674. package/grid-list/grid-list_public_index.d.ts +4 -0
  675. package/grid-list/index.d.ts +5 -1
  676. package/grid-list/package.json +2 -2
  677. package/grid-list/testing/grid-list-harness.d.ts +1 -1
  678. package/icon/icon-registry.d.ts +1 -1
  679. package/icon/icon_public_index.d.ts +4 -0
  680. package/icon/index.d.ts +5 -1
  681. package/icon/package.json +2 -2
  682. package/icon/testing/index.d.ts +5 -1
  683. package/icon/testing/package.json +2 -2
  684. package/icon/testing/testing_public_index.d.ts +4 -0
  685. package/input/_input-theme.scss +8 -6
  686. package/input/index.d.ts +5 -1
  687. package/input/input.d.ts +2 -0
  688. package/input/input_public_index.d.ts +4 -0
  689. package/input/package.json +2 -2
  690. package/list/index.d.ts +5 -1
  691. package/list/list_public_index.d.ts +4 -0
  692. package/list/package.json +2 -2
  693. package/list/testing/list-harness-base.d.ts +2 -2
  694. package/menu/index.d.ts +5 -1
  695. package/menu/menu_public_index.d.ts +4 -0
  696. package/menu/package.json +2 -2
  697. package/menu/public-api.d.ts +1 -1
  698. package/menu/testing/menu-harness.d.ts +2 -2
  699. package/package.json +79 -79
  700. package/paginator/index.d.ts +5 -1
  701. package/paginator/package.json +2 -2
  702. package/paginator/paginator_public_index.d.ts +4 -0
  703. package/prebuilt-themes/deeppurple-amber.css +1 -1
  704. package/prebuilt-themes/indigo-pink.css +1 -1
  705. package/prebuilt-themes/pink-bluegrey.css +1 -1
  706. package/prebuilt-themes/purple-green.css +1 -1
  707. package/progress-bar/index.d.ts +5 -1
  708. package/progress-bar/package.json +2 -2
  709. package/progress-bar/progress-bar_public_index.d.ts +4 -0
  710. package/progress-spinner/index.d.ts +5 -1
  711. package/progress-spinner/package.json +2 -2
  712. package/progress-spinner/progress-spinner_public_index.d.ts +4 -0
  713. package/radio/index.d.ts +5 -1
  714. package/radio/package.json +2 -2
  715. package/radio/radio_public_index.d.ts +4 -0
  716. package/radio/testing/radio-harness.d.ts +2 -2
  717. package/schematics/ng-add/index.js +3 -3
  718. package/schematics/ng-add/index.mjs +3 -3
  719. package/schematics/ng-add/package-config.js +4 -2
  720. package/schematics/ng-add/package-config.mjs +4 -2
  721. package/schematics/ng-add/setup-project.js +2 -3
  722. package/schematics/ng-add/setup-project.mjs +2 -3
  723. package/schematics/ng-add/theming/create-custom-theme.js +1 -1
  724. package/schematics/ng-add/theming/create-custom-theme.mjs +1 -1
  725. package/schematics/ng-add/theming/theming.js +6 -6
  726. package/schematics/ng-add/theming/theming.mjs +6 -6
  727. package/schematics/ng-generate/address-form/index.js +2 -2
  728. package/schematics/ng-generate/address-form/index.mjs +2 -2
  729. package/schematics/ng-generate/dashboard/index.js +2 -2
  730. package/schematics/ng-generate/dashboard/index.mjs +2 -2
  731. package/schematics/ng-generate/navigation/index.js +2 -2
  732. package/schematics/ng-generate/navigation/index.mjs +2 -2
  733. package/schematics/ng-generate/table/index.js +3 -3
  734. package/schematics/ng-generate/table/index.mjs +3 -3
  735. package/schematics/ng-generate/tree/index.js +2 -2
  736. package/schematics/ng-generate/tree/index.mjs +2 -2
  737. package/schematics/ng-update/data/class-names.js +6 -8
  738. package/schematics/ng-update/data/class-names.mjs +6 -8
  739. package/schematics/ng-update/data/constructor-checks.js +33 -32
  740. package/schematics/ng-update/data/constructor-checks.mjs +33 -32
  741. package/schematics/ng-update/data/css-selectors.js +11 -9
  742. package/schematics/ng-update/data/css-selectors.mjs +11 -9
  743. package/schematics/ng-update/data/element-selectors.js +6 -4
  744. package/schematics/ng-update/data/element-selectors.mjs +6 -4
  745. package/schematics/ng-update/data/input-names.js +31 -23
  746. package/schematics/ng-update/data/input-names.mjs +31 -23
  747. package/schematics/ng-update/data/method-call-checks.js +10 -6
  748. package/schematics/ng-update/data/method-call-checks.mjs +10 -6
  749. package/schematics/ng-update/data/property-names.js +62 -50
  750. package/schematics/ng-update/data/property-names.mjs +62 -50
  751. package/schematics/ng-update/data/symbol-removal.js +6 -6
  752. package/schematics/ng-update/data/symbol-removal.mjs +6 -6
  753. package/schematics/ng-update/index.js +1 -1
  754. package/schematics/ng-update/index.mjs +1 -1
  755. package/schematics/ng-update/migrations/hammer-gestures-v9/find-main-module.js +5 -3
  756. package/schematics/ng-update/migrations/hammer-gestures-v9/find-main-module.mjs +5 -3
  757. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-gestures-migration.d.ts +4 -2
  758. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-gestures-migration.js +68 -33
  759. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-gestures-migration.mjs +68 -33
  760. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-template-check.js +38 -7
  761. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-template-check.mjs +38 -7
  762. package/schematics/ng-update/migrations/hammer-gestures-v9/import-manager.js +28 -14
  763. package/schematics/ng-update/migrations/hammer-gestures-v9/import-manager.mjs +28 -14
  764. package/schematics/ng-update/migrations/hammer-gestures-v9/remove-array-element.js +1 -1
  765. package/schematics/ng-update/migrations/hammer-gestures-v9/remove-array-element.mjs +1 -1
  766. package/schematics/ng-update/migrations/hammer-gestures-v9/remove-element-from-html.js +1 -1
  767. package/schematics/ng-update/migrations/hammer-gestures-v9/remove-element-from-html.mjs +1 -1
  768. package/schematics/ng-update/migrations/misc-checks/misc-class-inheritance.js +3 -2
  769. package/schematics/ng-update/migrations/misc-checks/misc-class-inheritance.mjs +3 -2
  770. package/schematics/ng-update/migrations/misc-checks/misc-class-names.js +1 -1
  771. package/schematics/ng-update/migrations/misc-checks/misc-class-names.mjs +1 -1
  772. package/schematics/ng-update/migrations/misc-checks/misc-imports.js +6 -3
  773. package/schematics/ng-update/migrations/misc-checks/misc-imports.mjs +6 -3
  774. package/schematics/ng-update/migrations/misc-checks/misc-property-names.js +1 -1
  775. package/schematics/ng-update/migrations/misc-checks/misc-property-names.mjs +1 -1
  776. package/schematics/ng-update/migrations/misc-checks/misc-template.js +7 -13
  777. package/schematics/ng-update/migrations/misc-checks/misc-template.mjs +7 -13
  778. package/schematics/ng-update/migrations/misc-ripples-v7/ripple-speed-factor-migration.js +1 -1
  779. package/schematics/ng-update/migrations/misc-ripples-v7/ripple-speed-factor-migration.mjs +1 -1
  780. package/schematics/ng-update/migrations/package-imports-v8/secondary-entry-points-migration.js +3 -2
  781. package/schematics/ng-update/migrations/package-imports-v8/secondary-entry-points-migration.mjs +3 -2
  782. package/schematics/ng-update/migrations/theming-api-v12/config.js +59 -10
  783. package/schematics/ng-update/migrations/theming-api-v12/config.mjs +59 -10
  784. package/schematics/ng-update/migrations/theming-api-v12/migration.js +19 -11
  785. package/schematics/ng-update/migrations/theming-api-v12/migration.mjs +19 -11
  786. package/schematics/ng-update/migrations/theming-api-v12/theming-api-migration.d.ts +2 -2
  787. package/schematics/ng-update/migrations/theming-api-v12/theming-api-migration.js +7 -4
  788. package/schematics/ng-update/migrations/theming-api-v12/theming-api-migration.mjs +7 -4
  789. package/schematics/ng-update/typescript/module-specifiers.js +3 -3
  790. package/schematics/ng-update/typescript/module-specifiers.mjs +3 -3
  791. package/select/index.d.ts +5 -1
  792. package/select/package.json +2 -2
  793. package/select/public-api.d.ts +1 -1
  794. package/select/select_public_index.d.ts +4 -0
  795. package/select/testing/select-harness.d.ts +4 -4
  796. package/sidenav/index.d.ts +5 -1
  797. package/sidenav/package.json +2 -2
  798. package/sidenav/sidenav_public_index.d.ts +4 -0
  799. package/slide-toggle/index.d.ts +5 -1
  800. package/slide-toggle/package.json +2 -2
  801. package/slide-toggle/slide-toggle_public_index.d.ts +4 -0
  802. package/slider/index.d.ts +5 -1
  803. package/slider/package.json +2 -2
  804. package/slider/slider_public_index.d.ts +4 -0
  805. package/snack-bar/index.d.ts +5 -1
  806. package/snack-bar/package.json +2 -2
  807. package/snack-bar/snack-bar_public_index.d.ts +4 -0
  808. package/sort/index.d.ts +5 -1
  809. package/sort/package.json +2 -2
  810. package/sort/sort_public_index.d.ts +4 -0
  811. package/stepper/index.d.ts +5 -1
  812. package/stepper/package.json +2 -2
  813. package/stepper/stepper_public_index.d.ts +4 -0
  814. package/table/index.d.ts +5 -1
  815. package/table/package.json +2 -2
  816. package/table/table-data-source.d.ts +3 -3
  817. package/table/table_public_index.d.ts +4 -0
  818. package/table/testing/row-harness.d.ts +2 -2
  819. package/table/testing/table-harness.d.ts +4 -4
  820. package/tabs/_tabs-theme.scss +6 -2
  821. package/tabs/index.d.ts +5 -1
  822. package/tabs/package.json +2 -2
  823. package/tabs/public-api.d.ts +1 -1
  824. package/tabs/tab-content.d.ts +2 -3
  825. package/tabs/tabs_public_index.d.ts +4 -0
  826. package/toolbar/index.d.ts +5 -1
  827. package/toolbar/package.json +2 -2
  828. package/toolbar/toolbar_public_index.d.ts +4 -0
  829. package/tooltip/index.d.ts +5 -1
  830. package/tooltip/package.json +2 -2
  831. package/tooltip/tooltip_public_index.d.ts +4 -0
  832. package/tree/index.d.ts +5 -1
  833. package/tree/package.json +2 -2
  834. package/tree/tree_public_index.d.ts +4 -0
@@ -32,7 +32,7 @@ const matBottomSheetAnimations = {
32
32
  state('visible', style({ transform: 'translateY(0%)' })),
33
33
  transition('visible => void, visible => hidden', animate(`${AnimationDurations.COMPLEX} ${AnimationCurves.ACCELERATION_CURVE}`)),
34
34
  transition('void => visible', animate(`${AnimationDurations.EXITING} ${AnimationCurves.DECELERATION_CURVE}`)),
35
- ])
35
+ ]),
36
36
  };
37
37
 
38
38
  /**
@@ -254,7 +254,9 @@ class MatBottomSheetContainer extends BasePortalOutlet {
254
254
  // non-focusable element like the backdrop was clicked) before moving it. It's possible that
255
255
  // the consumer moved it themselves before the animation was done, in which case we shouldn't
256
256
  // do anything.
257
- if (!activeElement || activeElement === this._document.body || activeElement === element ||
257
+ if (!activeElement ||
258
+ activeElement === this._document.body ||
259
+ activeElement === element ||
258
260
  element.contains(activeElement)) {
259
261
  toFocus.focus();
260
262
  }
@@ -272,9 +274,9 @@ class MatBottomSheetContainer extends BasePortalOutlet {
272
274
  }
273
275
  }
274
276
  }
275
- MatBottomSheetContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheetContainer, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: i1.FocusTrapFactory }, { token: i1.InteractivityChecker }, { token: i0.NgZone }, { token: i2.BreakpointObserver }, { token: DOCUMENT, optional: true }, { token: MatBottomSheetConfig }], target: i0.ɵɵFactoryTarget.Component });
276
- MatBottomSheetContainer.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-next.15", type: MatBottomSheetContainer, selector: "mat-bottom-sheet-container", host: { attributes: { "tabindex": "-1", "role": "dialog", "aria-modal": "true" }, listeners: { "@state.start": "_onAnimationStart($event)", "@state.done": "_onAnimationDone($event)" }, properties: { "attr.aria-label": "bottomSheetConfig?.ariaLabel", "@state": "_animationState" }, classAttribute: "mat-bottom-sheet-container" }, viewQueries: [{ propertyName: "_portalOutlet", first: true, predicate: CdkPortalOutlet, descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<ng-template cdkPortalOutlet></ng-template>\r\n", styles: [".mat-bottom-sheet-container{padding:8px 16px;min-width:100vw;box-sizing:border-box;display:block;outline:0;max-height:80vh;overflow:auto}.cdk-high-contrast-active .mat-bottom-sheet-container{outline:1px solid}.mat-bottom-sheet-container-xlarge,.mat-bottom-sheet-container-large,.mat-bottom-sheet-container-medium{border-top-left-radius:4px;border-top-right-radius:4px}.mat-bottom-sheet-container-medium{min-width:384px;max-width:calc(100vw - 128px)}.mat-bottom-sheet-container-large{min-width:512px;max-width:calc(100vw - 256px)}.mat-bottom-sheet-container-xlarge{min-width:576px;max-width:calc(100vw - 384px)}\n"], directives: [{ type: i4.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], animations: [matBottomSheetAnimations.bottomSheetState], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None });
277
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheetContainer, decorators: [{
277
+ MatBottomSheetContainer.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheetContainer, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: i1.FocusTrapFactory }, { token: i1.InteractivityChecker }, { token: i0.NgZone }, { token: i2.BreakpointObserver }, { token: DOCUMENT, optional: true }, { token: MatBottomSheetConfig }], target: i0.ɵɵFactoryTarget.Component });
278
+ MatBottomSheetContainer.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.0.0-rc.3", type: MatBottomSheetContainer, selector: "mat-bottom-sheet-container", host: { attributes: { "tabindex": "-1", "role": "dialog", "aria-modal": "true" }, listeners: { "@state.start": "_onAnimationStart($event)", "@state.done": "_onAnimationDone($event)" }, properties: { "attr.aria-label": "bottomSheetConfig?.ariaLabel", "@state": "_animationState" }, classAttribute: "mat-bottom-sheet-container" }, viewQueries: [{ propertyName: "_portalOutlet", first: true, predicate: CdkPortalOutlet, descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<ng-template cdkPortalOutlet></ng-template>\r\n", styles: [".mat-bottom-sheet-container{padding:8px 16px;min-width:100vw;box-sizing:border-box;display:block;outline:0;max-height:80vh;overflow:auto}.cdk-high-contrast-active .mat-bottom-sheet-container{outline:1px solid}.mat-bottom-sheet-container-xlarge,.mat-bottom-sheet-container-large,.mat-bottom-sheet-container-medium{border-top-left-radius:4px;border-top-right-radius:4px}.mat-bottom-sheet-container-medium{min-width:384px;max-width:calc(100vw - 128px)}.mat-bottom-sheet-container-large{min-width:512px;max-width:calc(100vw - 256px)}.mat-bottom-sheet-container-xlarge{min-width:576px;max-width:calc(100vw - 384px)}\n"], directives: [{ type: i4.CdkPortalOutlet, selector: "[cdkPortalOutlet]", inputs: ["cdkPortalOutlet"], outputs: ["attached"], exportAs: ["cdkPortalOutlet"] }], animations: [matBottomSheetAnimations.bottomSheetState], changeDetection: i0.ChangeDetectionStrategy.Default, encapsulation: i0.ViewEncapsulation.None });
279
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheetContainer, decorators: [{
278
280
  type: Component,
279
281
  args: [{ selector: 'mat-bottom-sheet-container', changeDetection: ChangeDetectionStrategy.Default, encapsulation: ViewEncapsulation.None, animations: [matBottomSheetAnimations.bottomSheetState], host: {
280
282
  'class': 'mat-bottom-sheet-container',
@@ -284,7 +286,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15",
284
286
  '[attr.aria-label]': 'bottomSheetConfig?.ariaLabel',
285
287
  '[@state]': '_animationState',
286
288
  '(@state.start)': '_onAnimationStart($event)',
287
- '(@state.done)': '_onAnimationDone($event)'
289
+ '(@state.done)': '_onAnimationDone($event)',
288
290
  }, template: "<ng-template cdkPortalOutlet></ng-template>\r\n", styles: [".mat-bottom-sheet-container{padding:8px 16px;min-width:100vw;box-sizing:border-box;display:block;outline:0;max-height:80vh;overflow:auto}.cdk-high-contrast-active .mat-bottom-sheet-container{outline:1px solid}.mat-bottom-sheet-container-xlarge,.mat-bottom-sheet-container-large,.mat-bottom-sheet-container-medium{border-top-left-radius:4px;border-top-right-radius:4px}.mat-bottom-sheet-container-medium{min-width:384px;max-width:calc(100vw - 128px)}.mat-bottom-sheet-container-large{min-width:512px;max-width:calc(100vw - 256px)}.mat-bottom-sheet-container-xlarge{min-width:576px;max-width:calc(100vw - 384px)}\n"] }]
289
291
  }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i0.ChangeDetectorRef }, { type: i1.FocusTrapFactory }, { type: i1.InteractivityChecker }, { type: i0.NgZone }, { type: i2.BreakpointObserver }, { type: undefined, decorators: [{
290
292
  type: Optional
@@ -305,23 +307,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15",
305
307
  */
306
308
  class MatBottomSheetModule {
307
309
  }
308
- MatBottomSheetModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheetModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
309
- MatBottomSheetModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheetModule, declarations: [MatBottomSheetContainer], imports: [OverlayModule,
310
- MatCommonModule,
311
- PortalModule], exports: [MatBottomSheetContainer, MatCommonModule] });
312
- MatBottomSheetModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheetModule, imports: [[
313
- OverlayModule,
314
- MatCommonModule,
315
- PortalModule,
316
- ], MatCommonModule] });
317
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheetModule, decorators: [{
310
+ MatBottomSheetModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheetModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
311
+ MatBottomSheetModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheetModule, declarations: [MatBottomSheetContainer], imports: [OverlayModule, MatCommonModule, PortalModule], exports: [MatBottomSheetContainer, MatCommonModule] });
312
+ MatBottomSheetModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheetModule, imports: [[OverlayModule, MatCommonModule, PortalModule], MatCommonModule] });
313
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheetModule, decorators: [{
318
314
  type: NgModule,
319
315
  args: [{
320
- imports: [
321
- OverlayModule,
322
- MatCommonModule,
323
- PortalModule,
324
- ],
316
+ imports: [OverlayModule, MatCommonModule, PortalModule],
325
317
  exports: [MatBottomSheetContainer, MatCommonModule],
326
318
  declarations: [MatBottomSheetContainer],
327
319
  entryComponents: [MatBottomSheetContainer],
@@ -348,7 +340,8 @@ class MatBottomSheetRef {
348
340
  this.containerInstance = containerInstance;
349
341
  this.disableClose = containerInstance.bottomSheetConfig.disableClose;
350
342
  // Emit when opening animation completes
351
- containerInstance._animationStateChanged.pipe(filter(event => event.phaseName === 'done' && event.toState === 'visible'), take(1))
343
+ containerInstance._animationStateChanged
344
+ .pipe(filter(event => event.phaseName === 'done' && event.toState === 'visible'), take(1))
352
345
  .subscribe(() => {
353
346
  this._afterOpened.next();
354
347
  this._afterOpened.complete();
@@ -360,7 +353,10 @@ class MatBottomSheetRef {
360
353
  clearTimeout(this._closeFallbackTimeout);
361
354
  _overlayRef.dispose();
362
355
  });
363
- _overlayRef.detachments().pipe(take(1)).subscribe(() => {
356
+ _overlayRef
357
+ .detachments()
358
+ .pipe(take(1))
359
+ .subscribe(() => {
364
360
  this._afterDismissed.next(this._result);
365
361
  this._afterDismissed.complete();
366
362
  });
@@ -379,7 +375,9 @@ class MatBottomSheetRef {
379
375
  dismiss(result) {
380
376
  if (!this._afterDismissed.closed) {
381
377
  // Transition the backdrop in parallel to the bottom sheet.
382
- this.containerInstance._animationStateChanged.pipe(filter(event => event.phaseName === 'start'), take(1)).subscribe(event => {
378
+ this.containerInstance._animationStateChanged
379
+ .pipe(filter(event => event.phaseName === 'start'), take(1))
380
+ .subscribe(event => {
383
381
  // The logic that disposes of the overlay depends on the exit animation completing, however
384
382
  // it isn't guaranteed if the parent view is destroyed while it's running. Add a fallback
385
383
  // timeout which will clean everything up if the animation hasn't fired within the specified
@@ -457,7 +455,7 @@ class MatBottomSheet {
457
455
  if (componentOrTemplateRef instanceof TemplateRef) {
458
456
  container.attachTemplatePortal(new TemplatePortal(componentOrTemplateRef, null, {
459
457
  $implicit: _config.data,
460
- bottomSheetRef: ref
458
+ bottomSheetRef: ref,
461
459
  }));
462
460
  }
463
461
  else {
@@ -506,7 +504,7 @@ class MatBottomSheet {
506
504
  const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;
507
505
  const injector = Injector.create({
508
506
  parent: userInjector || this._injector,
509
- providers: [{ provide: MatBottomSheetConfig, useValue: config }]
507
+ providers: [{ provide: MatBottomSheetConfig, useValue: config }],
510
508
  });
511
509
  const containerPortal = new ComponentPortal(MatBottomSheetContainer, config.viewContainerRef, injector);
512
510
  const containerRef = overlayRef.attach(containerPortal);
@@ -523,7 +521,7 @@ class MatBottomSheet {
523
521
  disposeOnNavigation: config.closeOnNavigation,
524
522
  maxWidth: '100%',
525
523
  scrollStrategy: config.scrollStrategy || this._overlay.scrollStrategies.block(),
526
- positionStrategy: this._overlay.position().global().centerHorizontally().bottom('0')
524
+ positionStrategy: this._overlay.position().global().centerHorizontally().bottom('0'),
527
525
  });
528
526
  if (config.backdropClass) {
529
527
  overlayConfig.backdropClass = config.backdropClass;
@@ -539,21 +537,22 @@ class MatBottomSheet {
539
537
  const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;
540
538
  const providers = [
541
539
  { provide: MatBottomSheetRef, useValue: bottomSheetRef },
542
- { provide: MAT_BOTTOM_SHEET_DATA, useValue: config.data }
540
+ { provide: MAT_BOTTOM_SHEET_DATA, useValue: config.data },
543
541
  ];
544
- if (config.direction && (!userInjector ||
545
- !userInjector.get(Directionality, null, InjectFlags.Optional))) {
542
+ if (config.direction &&
543
+ (!userInjector ||
544
+ !userInjector.get(Directionality, null, InjectFlags.Optional))) {
546
545
  providers.push({
547
546
  provide: Directionality,
548
- useValue: { value: config.direction, change: of() }
547
+ useValue: { value: config.direction, change: of() },
549
548
  });
550
549
  }
551
550
  return Injector.create({ parent: userInjector || this._injector, providers });
552
551
  }
553
552
  }
554
- MatBottomSheet.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheet, deps: [{ token: i1$1.Overlay }, { token: i0.Injector }, { token: MatBottomSheet, optional: true, skipSelf: true }, { token: MAT_BOTTOM_SHEET_DEFAULT_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
555
- MatBottomSheet.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheet, providedIn: MatBottomSheetModule });
556
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatBottomSheet, decorators: [{
553
+ MatBottomSheet.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheet, deps: [{ token: i1$1.Overlay }, { token: i0.Injector }, { token: MatBottomSheet, optional: true, skipSelf: true }, { token: MAT_BOTTOM_SHEET_DEFAULT_OPTIONS, optional: true }], target: i0.ɵɵFactoryTarget.Injectable });
554
+ MatBottomSheet.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheet, providedIn: MatBottomSheetModule });
555
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-rc.3", ngImport: i0, type: MatBottomSheet, decorators: [{
557
556
  type: Injectable,
558
557
  args: [{ providedIn: MatBottomSheetModule }]
559
558
  }], ctorParameters: function () { return [{ type: i1$1.Overlay }, { type: i0.Injector }, { type: MatBottomSheet, decorators: [{
@@ -576,6 +575,14 @@ function _applyConfigDefaults(defaults, config) {
576
575
  return { ...defaults, ...config };
577
576
  }
578
577
 
578
+ /**
579
+ * @license
580
+ * Copyright Google LLC All Rights Reserved.
581
+ *
582
+ * Use of this source code is governed by an MIT-style license that can be
583
+ * found in the LICENSE file at https://angular.io/license
584
+ */
585
+
579
586
  /**
580
587
  * @license
581
588
  * Copyright Google LLC All Rights Reserved.
@@ -1 +1 @@
1
- {"version":3,"file":"bottom-sheet.mjs","sources":["../../../../../../src/material/bottom-sheet/bottom-sheet-animations.ts","../../../../../../src/material/bottom-sheet/bottom-sheet-config.ts","../../../../../../src/material/bottom-sheet/bottom-sheet-container.ts","../../../../../../src/material/bottom-sheet/bottom-sheet-container.html","../../../../../../src/material/bottom-sheet/bottom-sheet-module.ts","../../../../../../src/material/bottom-sheet/bottom-sheet-ref.ts","../../../../../../src/material/bottom-sheet/bottom-sheet.ts","../../../../../../src/material/bottom-sheet/public-api.ts","../../../../../../src/material/bottom-sheet/index.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nimport {\n animate,\n state,\n style,\n transition,\n trigger,\n AnimationTriggerMetadata,\n} from '@angular/animations';\nimport {AnimationCurves, AnimationDurations} from '@angular/material/core';\n\n/** Animations used by the Material bottom sheet. */\nexport const matBottomSheetAnimations: {\n readonly bottomSheetState: AnimationTriggerMetadata;\n} = {\n /** Animation that shows and hides a bottom sheet. */\n bottomSheetState: trigger('state', [\n state('void, hidden', style({transform: 'translateY(100%)'})),\n state('visible', style({transform: 'translateY(0%)'})),\n transition('visible => void, visible => hidden',\n animate(`${AnimationDurations.COMPLEX} ${AnimationCurves.ACCELERATION_CURVE}`)),\n transition('void => visible',\n animate(`${AnimationDurations.EXITING} ${AnimationCurves.DECELERATION_CURVE}`)),\n ])\n};\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Direction} from '@angular/cdk/bidi';\nimport {ScrollStrategy} from '@angular/cdk/overlay';\nimport {InjectionToken, ViewContainerRef} from '@angular/core';\n\n/** Options for where to set focus to automatically on dialog open */\nexport type AutoFocusTarget = 'dialog' | 'first-tabbable' | 'first-heading';\n\n/** Injection token that can be used to access the data that was passed in to a bottom sheet. */\nexport const MAT_BOTTOM_SHEET_DATA = new InjectionToken<any>('MatBottomSheetData');\n\n/**\n * Configuration used when opening a bottom sheet.\n */\nexport class MatBottomSheetConfig<D = any> {\n /** The view container to place the overlay for the bottom sheet into. */\n viewContainerRef?: ViewContainerRef;\n\n /** Extra CSS classes to be added to the bottom sheet container. */\n panelClass?: string | string[];\n\n /** Text layout direction for the bottom sheet. */\n direction?: Direction;\n\n /** Data being injected into the child component. */\n data?: D | null = null;\n\n /** Whether the bottom sheet has a backdrop. */\n hasBackdrop?: boolean = true;\n\n /** Custom class for the backdrop. */\n backdropClass?: string;\n\n /** Whether the user can use escape or clicking outside to close the bottom sheet. */\n disableClose?: boolean = false;\n\n /** Aria label to assign to the bottom sheet element. */\n ariaLabel?: string | null = null;\n\n /**\n * Whether the bottom sheet should close when the user goes backwards/forwards in history.\n * Note that this usually doesn't include clicking on links (unless the user is using\n * the `HashLocationStrategy`).\n */\n closeOnNavigation?: boolean = true;\n\n // Note that this is set to 'dialog' by default, because while the a11y recommendations\n // are to focus the first focusable element, doing so prevents screen readers from reading out the\n // rest of the bottom sheet content.\n /**\n * Where the bottom sheet should focus on open.\n * @breaking-change 14.0.0 Remove boolean option from autoFocus. Use string or\n * AutoFocusTarget instead.\n */\n autoFocus?: AutoFocusTarget | string | boolean = 'dialog';\n\n /**\n * Whether the bottom sheet should restore focus to the\n * previously-focused element, after it's closed.\n */\n restoreFocus?: boolean = true;\n\n /** Scroll strategy to be used for the bottom sheet. */\n scrollStrategy?: ScrollStrategy;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {AnimationEvent} from '@angular/animations';\nimport {FocusTrap, FocusTrapFactory, InteractivityChecker} from '@angular/cdk/a11y';\nimport {coerceArray} from '@angular/cdk/coercion';\nimport {BreakpointObserver, Breakpoints} from '@angular/cdk/layout';\nimport {_getFocusedElementPierceShadowDom} from '@angular/cdk/platform';\nimport {\n BasePortalOutlet,\n CdkPortalOutlet,\n ComponentPortal,\n DomPortal,\n TemplatePortal,\n} from '@angular/cdk/portal';\nimport {DOCUMENT} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ComponentRef,\n ElementRef,\n EmbeddedViewRef,\n EventEmitter,\n Inject,\n NgZone,\n OnDestroy,\n Optional,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport {Subscription} from 'rxjs';\nimport {matBottomSheetAnimations} from './bottom-sheet-animations';\nimport {MatBottomSheetConfig} from './bottom-sheet-config';\n\n// TODO(crisbeto): consolidate some logic between this, MatDialog and MatSnackBar\n\n/**\n * Internal component that wraps user-provided bottom sheet content.\n * @docs-private\n */\n@Component({\n selector: 'mat-bottom-sheet-container',\n templateUrl: 'bottom-sheet-container.html',\n styleUrls: ['bottom-sheet-container.css'],\n // In Ivy embedded views will be change detected from their declaration place, rather than where\n // they were stamped out. This means that we can't have the bottom sheet container be OnPush,\n // because it might cause the sheets that were opened from a template not to be out of date.\n // tslint:disable-next-line:validate-decorators\n changeDetection: ChangeDetectionStrategy.Default,\n encapsulation: ViewEncapsulation.None,\n animations: [matBottomSheetAnimations.bottomSheetState],\n host: {\n 'class': 'mat-bottom-sheet-container',\n 'tabindex': '-1',\n 'role': 'dialog',\n 'aria-modal': 'true',\n '[attr.aria-label]': 'bottomSheetConfig?.ariaLabel',\n '[@state]': '_animationState',\n '(@state.start)': '_onAnimationStart($event)',\n '(@state.done)': '_onAnimationDone($event)'\n },\n})\nexport class MatBottomSheetContainer extends BasePortalOutlet implements OnDestroy {\n private _breakpointSubscription: Subscription;\n\n /** The portal outlet inside of this container into which the content will be loaded. */\n @ViewChild(CdkPortalOutlet, {static: true}) _portalOutlet: CdkPortalOutlet;\n\n /** The state of the bottom sheet animations. */\n _animationState: 'void' | 'visible' | 'hidden' = 'void';\n\n /** Emits whenever the state of the animation changes. */\n _animationStateChanged = new EventEmitter<AnimationEvent>();\n\n /** The class that traps and manages focus within the bottom sheet. */\n private _focusTrap: FocusTrap;\n\n /** Element that was focused before the bottom sheet was opened. */\n private _elementFocusedBeforeOpened: HTMLElement | null = null;\n\n /** Server-side rendering-compatible reference to the global document object. */\n private _document: Document;\n\n /** Whether the component has been destroyed. */\n private _destroyed: boolean;\n\n constructor(\n private _elementRef: ElementRef<HTMLElement>,\n private _changeDetectorRef: ChangeDetectorRef,\n private _focusTrapFactory: FocusTrapFactory,\n private readonly _interactivityChecker: InteractivityChecker,\n private readonly _ngZone: NgZone,\n breakpointObserver: BreakpointObserver,\n @Optional() @Inject(DOCUMENT) document: any,\n /** The bottom sheet configuration. */\n public bottomSheetConfig: MatBottomSheetConfig) {\n super();\n\n this._document = document;\n this._breakpointSubscription = breakpointObserver\n .observe([Breakpoints.Medium, Breakpoints.Large, Breakpoints.XLarge])\n .subscribe(() => {\n this._toggleClass('mat-bottom-sheet-container-medium',\n breakpointObserver.isMatched(Breakpoints.Medium));\n this._toggleClass('mat-bottom-sheet-container-large',\n breakpointObserver.isMatched(Breakpoints.Large));\n this._toggleClass('mat-bottom-sheet-container-xlarge',\n breakpointObserver.isMatched(Breakpoints.XLarge));\n });\n }\n\n /** Attach a component portal as content to this bottom sheet container. */\n attachComponentPortal<T>(portal: ComponentPortal<T>): ComponentRef<T> {\n this._validatePortalAttached();\n this._setPanelClass();\n this._savePreviouslyFocusedElement();\n return this._portalOutlet.attachComponentPortal(portal);\n }\n\n /** Attach a template portal as content to this bottom sheet container. */\n attachTemplatePortal<C>(portal: TemplatePortal<C>): EmbeddedViewRef<C> {\n this._validatePortalAttached();\n this._setPanelClass();\n this._savePreviouslyFocusedElement();\n return this._portalOutlet.attachTemplatePortal(portal);\n }\n\n /**\n * Attaches a DOM portal to the bottom sheet container.\n * @deprecated To be turned into a method.\n * @breaking-change 10.0.0\n */\n override attachDomPortal = (portal: DomPortal) => {\n this._validatePortalAttached();\n this._setPanelClass();\n this._savePreviouslyFocusedElement();\n return this._portalOutlet.attachDomPortal(portal);\n }\n\n /** Begin animation of bottom sheet entrance into view. */\n enter(): void {\n if (!this._destroyed) {\n this._animationState = 'visible';\n this._changeDetectorRef.detectChanges();\n }\n }\n\n /** Begin animation of the bottom sheet exiting from view. */\n exit(): void {\n if (!this._destroyed) {\n this._animationState = 'hidden';\n this._changeDetectorRef.markForCheck();\n }\n }\n\n ngOnDestroy() {\n this._breakpointSubscription.unsubscribe();\n this._destroyed = true;\n }\n\n _onAnimationDone(event: AnimationEvent) {\n if (event.toState === 'hidden') {\n this._restoreFocus();\n } else if (event.toState === 'visible') {\n this._trapFocus();\n }\n\n this._animationStateChanged.emit(event);\n }\n\n _onAnimationStart(event: AnimationEvent) {\n this._animationStateChanged.emit(event);\n }\n\n private _toggleClass(cssClass: string, add: boolean) {\n this._elementRef.nativeElement.classList.toggle(cssClass, add);\n }\n\n private _validatePortalAttached() {\n if (this._portalOutlet.hasAttached() && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw Error('Attempting to attach bottom sheet content after content is already attached');\n }\n }\n\n private _setPanelClass() {\n const element: HTMLElement = this._elementRef.nativeElement;\n element.classList.add(...coerceArray(this.bottomSheetConfig.panelClass || []));\n }\n\n /**\n * Focuses the provided element. If the element is not focusable, it will add a tabIndex\n * attribute to forcefully focus it. The attribute is removed after focus is moved.\n * @param element The element to focus.\n */\n private _forceFocus(element: HTMLElement, options?: FocusOptions) {\n if (!this._interactivityChecker.isFocusable(element)) {\n element.tabIndex = -1;\n // The tabindex attribute should be removed to avoid navigating to that element again\n this._ngZone.runOutsideAngular(() => {\n element.addEventListener('blur', () => element.removeAttribute('tabindex'));\n element.addEventListener('mousedown', () => element.removeAttribute('tabindex'));\n });\n }\n element.focus(options);\n }\n\n /**\n * Focuses the first element that matches the given selector within the focus trap.\n * @param selector The CSS selector for the element to set focus to.\n */\n private _focusByCssSelector(selector: string, options?: FocusOptions) {\n let elementToFocus =\n this._elementRef.nativeElement.querySelector(selector) as HTMLElement | null;\n if (elementToFocus) {\n this._forceFocus(elementToFocus, options);\n }\n }\n\n /**\n * Moves the focus inside the focus trap. When autoFocus is not set to 'bottom-sheet',\n * if focus cannot be moved then focus will go to the bottom sheet container.\n */\n private _trapFocus() {\n const element = this._elementRef.nativeElement;\n\n if (!this._focusTrap) {\n this._focusTrap = this._focusTrapFactory.create(element);\n }\n\n // If were to attempt to focus immediately, then the content of the bottom sheet would not\n // yet be ready in instances where change detection has to run first. To deal with this,\n // we simply wait for the microtask queue to be empty when setting focus when autoFocus\n // isn't set to bottom sheet. If the element inside the bottom sheet can't be focused,\n // then the container is focused so the user can't tab into other elements behind it.\n switch (this.bottomSheetConfig.autoFocus) {\n case false:\n case 'dialog':\n const activeElement = _getFocusedElementPierceShadowDom();\n // Ensure that focus is on the bottom sheet container. It's possible that a different\n // component tried to move focus while the open animation was running. See:\n // https://github.com/angular/components/issues/16215. Note that we only want to do this\n // if the focus isn't inside the bottom sheet already, because it's possible that the\n // consumer specified `autoFocus` in order to move focus themselves.\n if (activeElement !== element && !element.contains(activeElement)) {\n element.focus();\n }\n break;\n case true:\n case 'first-tabbable':\n this._focusTrap.focusInitialElementWhenReady();\n break;\n case 'first-heading':\n this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role=\"heading\"]');\n break;\n default:\n this._focusByCssSelector(this.bottomSheetConfig.autoFocus!);\n break;\n }\n }\n\n /** Restores focus to the element that was focused before the bottom sheet was opened. */\n private _restoreFocus() {\n const toFocus = this._elementFocusedBeforeOpened;\n\n // We need the extra check, because IE can set the `activeElement` to null in some cases.\n if (this.bottomSheetConfig.restoreFocus && toFocus && typeof toFocus.focus === 'function') {\n const activeElement = _getFocusedElementPierceShadowDom();\n const element = this._elementRef.nativeElement;\n\n // Make sure that focus is still inside the bottom sheet or is on the body (usually because a\n // non-focusable element like the backdrop was clicked) before moving it. It's possible that\n // the consumer moved it themselves before the animation was done, in which case we shouldn't\n // do anything.\n if (!activeElement || activeElement === this._document.body || activeElement === element ||\n element.contains(activeElement)) {\n toFocus.focus();\n }\n }\n\n if (this._focusTrap) {\n this._focusTrap.destroy();\n }\n }\n\n /** Saves a reference to the element that was focused before the bottom sheet was opened. */\n private _savePreviouslyFocusedElement() {\n this._elementFocusedBeforeOpened = _getFocusedElementPierceShadowDom();\n\n // The `focus` method isn't available during server-side rendering.\n if (this._elementRef.nativeElement.focus) {\n Promise.resolve().then(() => this._elementRef.nativeElement.focus());\n }\n }\n}\n","<ng-template cdkPortalOutlet></ng-template>\r\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {OverlayModule} from '@angular/cdk/overlay';\nimport {PortalModule} from '@angular/cdk/portal';\nimport {NgModule} from '@angular/core';\nimport {MatCommonModule} from '@angular/material/core';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\n\n\n@NgModule({\n imports: [\n OverlayModule,\n MatCommonModule,\n PortalModule,\n ],\n exports: [MatBottomSheetContainer, MatCommonModule],\n declarations: [MatBottomSheetContainer],\n entryComponents: [MatBottomSheetContainer],\n})\nexport class MatBottomSheetModule {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ESCAPE, hasModifierKey} from '@angular/cdk/keycodes';\nimport {OverlayRef} from '@angular/cdk/overlay';\nimport {merge, Observable, Subject} from 'rxjs';\nimport {filter, take} from 'rxjs/operators';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\n\n\n/**\n * Reference to a bottom sheet dispatched from the bottom sheet service.\n */\nexport class MatBottomSheetRef<T = any, R = any> {\n /** Instance of the component making up the content of the bottom sheet. */\n instance: T;\n\n /**\n * Instance of the component into which the bottom sheet content is projected.\n * @docs-private\n */\n containerInstance: MatBottomSheetContainer;\n\n /** Whether the user is allowed to close the bottom sheet. */\n disableClose: boolean | undefined;\n\n /** Subject for notifying the user that the bottom sheet has been dismissed. */\n private readonly _afterDismissed = new Subject<R | undefined>();\n\n /** Subject for notifying the user that the bottom sheet has opened and appeared. */\n private readonly _afterOpened = new Subject<void>();\n\n /** Result to be passed down to the `afterDismissed` stream. */\n private _result: R | undefined;\n\n /** Handle to the timeout that's running as a fallback in case the exit animation doesn't fire. */\n private _closeFallbackTimeout: any;\n\n constructor(\n containerInstance: MatBottomSheetContainer,\n private _overlayRef: OverlayRef) {\n this.containerInstance = containerInstance;\n this.disableClose = containerInstance.bottomSheetConfig.disableClose;\n\n // Emit when opening animation completes\n containerInstance._animationStateChanged.pipe(\n filter(event => event.phaseName === 'done' && event.toState === 'visible'),\n take(1)\n )\n .subscribe(() => {\n this._afterOpened.next();\n this._afterOpened.complete();\n });\n\n // Dispose overlay when closing animation is complete\n containerInstance._animationStateChanged\n .pipe(filter(event => event.phaseName === 'done' && event.toState === 'hidden'), take(1))\n .subscribe(() => {\n clearTimeout(this._closeFallbackTimeout);\n _overlayRef.dispose();\n });\n\n _overlayRef.detachments().pipe(take(1)).subscribe(() => {\n this._afterDismissed.next(this._result);\n this._afterDismissed.complete();\n });\n\n merge(\n _overlayRef.backdropClick(),\n _overlayRef.keydownEvents().pipe(filter(event => event.keyCode === ESCAPE))\n ).subscribe(event => {\n if (!this.disableClose &&\n (event.type !== 'keydown' || !hasModifierKey(event as KeyboardEvent))) {\n event.preventDefault();\n this.dismiss();\n }\n });\n }\n\n /**\n * Dismisses the bottom sheet.\n * @param result Data to be passed back to the bottom sheet opener.\n */\n dismiss(result?: R): void {\n if (!this._afterDismissed.closed) {\n // Transition the backdrop in parallel to the bottom sheet.\n this.containerInstance._animationStateChanged.pipe(\n filter(event => event.phaseName === 'start'),\n take(1)\n ).subscribe(event => {\n // The logic that disposes of the overlay depends on the exit animation completing, however\n // it isn't guaranteed if the parent view is destroyed while it's running. Add a fallback\n // timeout which will clean everything up if the animation hasn't fired within the specified\n // amount of time plus 100ms. We don't need to run this outside the NgZone, because for the\n // vast majority of cases the timeout will have been cleared before it has fired.\n this._closeFallbackTimeout = setTimeout(() => {\n this._overlayRef.dispose();\n }, event.totalTime + 100);\n\n this._overlayRef.detachBackdrop();\n });\n\n this._result = result;\n this.containerInstance.exit();\n }\n }\n\n /** Gets an observable that is notified when the bottom sheet is finished closing. */\n afterDismissed(): Observable<R | undefined> {\n return this._afterDismissed;\n }\n\n /** Gets an observable that is notified when the bottom sheet has opened and appeared. */\n afterOpened(): Observable<void> {\n return this._afterOpened;\n }\n\n /**\n * Gets an observable that emits when the overlay's backdrop has been clicked.\n */\n backdropClick(): Observable<MouseEvent> {\n return this._overlayRef.backdropClick();\n }\n\n /**\n * Gets an observable that emits when keydown events are targeted on the overlay.\n */\n keydownEvents(): Observable<KeyboardEvent> {\n return this._overlayRef.keydownEvents();\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Directionality} from '@angular/cdk/bidi';\nimport {Overlay, OverlayConfig, OverlayRef} from '@angular/cdk/overlay';\nimport {ComponentPortal, ComponentType, TemplatePortal} from '@angular/cdk/portal';\nimport {\n ComponentRef,\n Injectable,\n Injector,\n Optional,\n SkipSelf,\n TemplateRef,\n InjectionToken,\n Inject,\n OnDestroy,\n StaticProvider,\n InjectFlags,\n} from '@angular/core';\nimport {of as observableOf} from 'rxjs';\nimport {MAT_BOTTOM_SHEET_DATA, MatBottomSheetConfig} from './bottom-sheet-config';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\nimport {MatBottomSheetModule} from './bottom-sheet-module';\nimport {MatBottomSheetRef} from './bottom-sheet-ref';\n\n\n/** Injection token that can be used to specify default bottom sheet options. */\nexport const MAT_BOTTOM_SHEET_DEFAULT_OPTIONS =\n new InjectionToken<MatBottomSheetConfig>('mat-bottom-sheet-default-options');\n\n/**\n * Service to trigger Material Design bottom sheets.\n */\n@Injectable({providedIn: MatBottomSheetModule})\nexport class MatBottomSheet implements OnDestroy {\n private _bottomSheetRefAtThisLevel: MatBottomSheetRef<any> | null = null;\n\n /** Reference to the currently opened bottom sheet. */\n get _openedBottomSheetRef(): MatBottomSheetRef<any> | null {\n const parent = this._parentBottomSheet;\n return parent ? parent._openedBottomSheetRef : this._bottomSheetRefAtThisLevel;\n }\n\n set _openedBottomSheetRef(value: MatBottomSheetRef<any> | null) {\n if (this._parentBottomSheet) {\n this._parentBottomSheet._openedBottomSheetRef = value;\n } else {\n this._bottomSheetRefAtThisLevel = value;\n }\n }\n\n constructor(\n private _overlay: Overlay,\n private _injector: Injector,\n @Optional() @SkipSelf() private _parentBottomSheet: MatBottomSheet,\n @Optional() @Inject(MAT_BOTTOM_SHEET_DEFAULT_OPTIONS)\n private _defaultOptions?: MatBottomSheetConfig) {}\n\n /**\n * Opens a bottom sheet containing the given component.\n * @param component Type of the component to load into the bottom sheet.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened bottom sheet.\n */\n open<T, D = any, R = any>(component: ComponentType<T>,\n config?: MatBottomSheetConfig<D>): MatBottomSheetRef<T, R>;\n\n /**\n * Opens a bottom sheet containing the given template.\n * @param template TemplateRef to instantiate as the bottom sheet content.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened bottom sheet.\n */\n open<T, D = any, R = any>(template: TemplateRef<T>,\n config?: MatBottomSheetConfig<D>): MatBottomSheetRef<T, R>;\n\n open<T, D = any, R = any>(componentOrTemplateRef: ComponentType<T> | TemplateRef<T>,\n config?: MatBottomSheetConfig<D>): MatBottomSheetRef<T, R> {\n\n const _config =\n _applyConfigDefaults(this._defaultOptions || new MatBottomSheetConfig(), config);\n const overlayRef = this._createOverlay(_config);\n const container = this._attachContainer(overlayRef, _config);\n const ref = new MatBottomSheetRef<T, R>(container, overlayRef);\n\n if (componentOrTemplateRef instanceof TemplateRef) {\n container.attachTemplatePortal(new TemplatePortal<T>(componentOrTemplateRef, null!, {\n $implicit: _config.data,\n bottomSheetRef: ref\n } as any));\n } else {\n const portal = new ComponentPortal(componentOrTemplateRef, undefined,\n this._createInjector(_config, ref));\n const contentRef = container.attachComponentPortal(portal);\n ref.instance = contentRef.instance;\n }\n\n // When the bottom sheet is dismissed, clear the reference to it.\n ref.afterDismissed().subscribe(() => {\n // Clear the bottom sheet ref if it hasn't already been replaced by a newer one.\n if (this._openedBottomSheetRef == ref) {\n this._openedBottomSheetRef = null;\n }\n });\n\n if (this._openedBottomSheetRef) {\n // If a bottom sheet is already in view, dismiss it and enter the\n // new bottom sheet after exit animation is complete.\n this._openedBottomSheetRef.afterDismissed().subscribe(() => ref.containerInstance.enter());\n this._openedBottomSheetRef.dismiss();\n } else {\n // If no bottom sheet is in view, enter the new bottom sheet.\n ref.containerInstance.enter();\n }\n\n this._openedBottomSheetRef = ref;\n\n return ref;\n }\n\n /**\n * Dismisses the currently-visible bottom sheet.\n * @param result Data to pass to the bottom sheet instance.\n */\n dismiss<R = any>(result?: R): void {\n if (this._openedBottomSheetRef) {\n this._openedBottomSheetRef.dismiss(result);\n }\n }\n\n ngOnDestroy() {\n if (this._bottomSheetRefAtThisLevel) {\n this._bottomSheetRefAtThisLevel.dismiss();\n }\n }\n\n /**\n * Attaches the bottom sheet container component to the overlay.\n */\n private _attachContainer(overlayRef: OverlayRef,\n config: MatBottomSheetConfig): MatBottomSheetContainer {\n\n const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;\n const injector = Injector.create({\n parent: userInjector || this._injector,\n providers: [{provide: MatBottomSheetConfig, useValue: config}]\n });\n\n const containerPortal =\n new ComponentPortal(MatBottomSheetContainer, config.viewContainerRef, injector);\n const containerRef: ComponentRef<MatBottomSheetContainer> = overlayRef.attach(containerPortal);\n return containerRef.instance;\n }\n\n /**\n * Creates a new overlay and places it in the correct location.\n * @param config The user-specified bottom sheet config.\n */\n private _createOverlay(config: MatBottomSheetConfig): OverlayRef {\n const overlayConfig = new OverlayConfig({\n direction: config.direction,\n hasBackdrop: config.hasBackdrop,\n disposeOnNavigation: config.closeOnNavigation,\n maxWidth: '100%',\n scrollStrategy: config.scrollStrategy || this._overlay.scrollStrategies.block(),\n positionStrategy: this._overlay.position().global().centerHorizontally().bottom('0')\n });\n\n if (config.backdropClass) {\n overlayConfig.backdropClass = config.backdropClass;\n }\n\n return this._overlay.create(overlayConfig);\n }\n\n /**\n * Creates an injector to be used inside of a bottom sheet component.\n * @param config Config that was used to create the bottom sheet.\n * @param bottomSheetRef Reference to the bottom sheet.\n */\n private _createInjector<T>(config: MatBottomSheetConfig,\n bottomSheetRef: MatBottomSheetRef<T>): Injector {\n\n const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;\n const providers: StaticProvider[] = [\n {provide: MatBottomSheetRef, useValue: bottomSheetRef},\n {provide: MAT_BOTTOM_SHEET_DATA, useValue: config.data}\n ];\n\n if (config.direction && (!userInjector ||\n !userInjector.get<Directionality | null>(Directionality, null, InjectFlags.Optional))) {\n providers.push({\n provide: Directionality,\n useValue: {value: config.direction, change: observableOf()}\n });\n }\n\n return Injector.create({parent: userInjector || this._injector, providers});\n }\n}\n\n/**\n * Applies default options to the bottom sheet config.\n * @param defaults Object containing the default values to which to fall back.\n * @param config The configuration to which the defaults will be applied.\n * @returns The new configuration object with defaults applied.\n */\nfunction _applyConfigDefaults(defaults: MatBottomSheetConfig,\n config?: MatBottomSheetConfig): MatBottomSheetConfig {\n return {...defaults, ...config};\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './bottom-sheet-module';\nexport * from './bottom-sheet';\nexport * from './bottom-sheet-config';\nexport * from './bottom-sheet-container';\nexport * from './bottom-sheet-animations';\nexport * from './bottom-sheet-ref';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["observableOf"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;;;;;;;AAiBA;MACa,wBAAwB,GAEjC;;IAEF,gBAAgB,EAAE,OAAO,CAAC,OAAO,EAAE;QACjC,KAAK,CAAC,cAAc,EAAE,KAAK,CAAC,EAAC,SAAS,EAAE,kBAAkB,EAAC,CAAC,CAAC;QAC7D,KAAK,CAAC,SAAS,EAAE,KAAK,CAAC,EAAC,SAAS,EAAE,gBAAgB,EAAC,CAAC,CAAC;QACtD,UAAU,CAAC,oCAAoC,EAC3C,OAAO,CAAC,GAAG,kBAAkB,CAAC,OAAO,IAAI,eAAe,CAAC,kBAAkB,EAAE,CAAC,CAAC;QACnF,UAAU,CAAC,iBAAiB,EACxB,OAAO,CAAC,GAAG,kBAAkB,CAAC,OAAO,IAAI,eAAe,CAAC,kBAAkB,EAAE,CAAC,CAAC;KACpF,CAAC;;;AC7BJ;;;;;;;AAeA;MACa,qBAAqB,GAAG,IAAI,cAAc,CAAM,oBAAoB,EAAE;AAEnF;;;MAGa,oBAAoB;IAAjC;;QAWE,SAA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ArB7C,cAAc,cADF,oBAAoB;mGAChC,cAAc;kBAD1B,UAAU;mBAAC,EAAC,UAAU,EAAE,oBAAoB,EAAC;yGAqBY,cAAc;0BAAjE,QAAQ;;0BAAI,QAAQ;;0BACpB,QAAQ;;0BAAI,MAAM;2BAAC,gCAAgC;;AAkJ1D;;;;;;AAMA,SAAS,oBAAoB,CAAC,QAA8B,EAC9B,MAA6B;IACzD,OAAO,EAAC,GAAG,QAAQ,EAAE,GAAG,MAAM,EAAC,CAAC;AAClC;;ACvNA;;;;;;;;ACAA;;;;;;"}
1
+ {"version":3,"file":"bottom-sheet.mjs","sources":["../../../../../../src/material/bottom-sheet/bottom-sheet-animations.ts","../../../../../../src/material/bottom-sheet/bottom-sheet-config.ts","../../../../../../src/material/bottom-sheet/bottom-sheet-container.ts","../../../../../../src/material/bottom-sheet/bottom-sheet-container.html","../../../../../../src/material/bottom-sheet/bottom-sheet-module.ts","../../../../../../src/material/bottom-sheet/bottom-sheet-ref.ts","../../../../../../src/material/bottom-sheet/bottom-sheet.ts","../../../../../../src/material/bottom-sheet/public-api.ts","../../../../../../src/material/bottom-sheet/index.ts","../../../../../../src/material/bottom-sheet/bottom-sheet_public_index.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\nimport {\n animate,\n state,\n style,\n transition,\n trigger,\n AnimationTriggerMetadata,\n} from '@angular/animations';\nimport {AnimationCurves, AnimationDurations} from '@angular/material/core';\n\n/** Animations used by the Material bottom sheet. */\nexport const matBottomSheetAnimations: {\n readonly bottomSheetState: AnimationTriggerMetadata;\n} = {\n /** Animation that shows and hides a bottom sheet. */\n bottomSheetState: trigger('state', [\n state('void, hidden', style({transform: 'translateY(100%)'})),\n state('visible', style({transform: 'translateY(0%)'})),\n transition(\n 'visible => void, visible => hidden',\n animate(`${AnimationDurations.COMPLEX} ${AnimationCurves.ACCELERATION_CURVE}`),\n ),\n transition(\n 'void => visible',\n animate(`${AnimationDurations.EXITING} ${AnimationCurves.DECELERATION_CURVE}`),\n ),\n ]),\n};\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Direction} from '@angular/cdk/bidi';\nimport {ScrollStrategy} from '@angular/cdk/overlay';\nimport {InjectionToken, ViewContainerRef} from '@angular/core';\n\n/** Options for where to set focus to automatically on dialog open */\nexport type AutoFocusTarget = 'dialog' | 'first-tabbable' | 'first-heading';\n\n/** Injection token that can be used to access the data that was passed in to a bottom sheet. */\nexport const MAT_BOTTOM_SHEET_DATA = new InjectionToken<any>('MatBottomSheetData');\n\n/**\n * Configuration used when opening a bottom sheet.\n */\nexport class MatBottomSheetConfig<D = any> {\n /** The view container to place the overlay for the bottom sheet into. */\n viewContainerRef?: ViewContainerRef;\n\n /** Extra CSS classes to be added to the bottom sheet container. */\n panelClass?: string | string[];\n\n /** Text layout direction for the bottom sheet. */\n direction?: Direction;\n\n /** Data being injected into the child component. */\n data?: D | null = null;\n\n /** Whether the bottom sheet has a backdrop. */\n hasBackdrop?: boolean = true;\n\n /** Custom class for the backdrop. */\n backdropClass?: string;\n\n /** Whether the user can use escape or clicking outside to close the bottom sheet. */\n disableClose?: boolean = false;\n\n /** Aria label to assign to the bottom sheet element. */\n ariaLabel?: string | null = null;\n\n /**\n * Whether the bottom sheet should close when the user goes backwards/forwards in history.\n * Note that this usually doesn't include clicking on links (unless the user is using\n * the `HashLocationStrategy`).\n */\n closeOnNavigation?: boolean = true;\n\n // Note that this is set to 'dialog' by default, because while the a11y recommendations\n // are to focus the first focusable element, doing so prevents screen readers from reading out the\n // rest of the bottom sheet content.\n /**\n * Where the bottom sheet should focus on open.\n * @breaking-change 14.0.0 Remove boolean option from autoFocus. Use string or\n * AutoFocusTarget instead.\n */\n autoFocus?: AutoFocusTarget | string | boolean = 'dialog';\n\n /**\n * Whether the bottom sheet should restore focus to the\n * previously-focused element, after it's closed.\n */\n restoreFocus?: boolean = true;\n\n /** Scroll strategy to be used for the bottom sheet. */\n scrollStrategy?: ScrollStrategy;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {AnimationEvent} from '@angular/animations';\nimport {FocusTrap, FocusTrapFactory, InteractivityChecker} from '@angular/cdk/a11y';\nimport {coerceArray} from '@angular/cdk/coercion';\nimport {BreakpointObserver, Breakpoints} from '@angular/cdk/layout';\nimport {_getFocusedElementPierceShadowDom} from '@angular/cdk/platform';\nimport {\n BasePortalOutlet,\n CdkPortalOutlet,\n ComponentPortal,\n DomPortal,\n TemplatePortal,\n} from '@angular/cdk/portal';\nimport {DOCUMENT} from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ComponentRef,\n ElementRef,\n EmbeddedViewRef,\n EventEmitter,\n Inject,\n NgZone,\n OnDestroy,\n Optional,\n ViewChild,\n ViewEncapsulation,\n} from '@angular/core';\nimport {Subscription} from 'rxjs';\nimport {matBottomSheetAnimations} from './bottom-sheet-animations';\nimport {MatBottomSheetConfig} from './bottom-sheet-config';\n\n// TODO(crisbeto): consolidate some logic between this, MatDialog and MatSnackBar\n\n/**\n * Internal component that wraps user-provided bottom sheet content.\n * @docs-private\n */\n@Component({\n selector: 'mat-bottom-sheet-container',\n templateUrl: 'bottom-sheet-container.html',\n styleUrls: ['bottom-sheet-container.css'],\n // In Ivy embedded views will be change detected from their declaration place, rather than where\n // they were stamped out. This means that we can't have the bottom sheet container be OnPush,\n // because it might cause the sheets that were opened from a template not to be out of date.\n // tslint:disable-next-line:validate-decorators\n changeDetection: ChangeDetectionStrategy.Default,\n encapsulation: ViewEncapsulation.None,\n animations: [matBottomSheetAnimations.bottomSheetState],\n host: {\n 'class': 'mat-bottom-sheet-container',\n 'tabindex': '-1',\n 'role': 'dialog',\n 'aria-modal': 'true',\n '[attr.aria-label]': 'bottomSheetConfig?.ariaLabel',\n '[@state]': '_animationState',\n '(@state.start)': '_onAnimationStart($event)',\n '(@state.done)': '_onAnimationDone($event)',\n },\n})\nexport class MatBottomSheetContainer extends BasePortalOutlet implements OnDestroy {\n private _breakpointSubscription: Subscription;\n\n /** The portal outlet inside of this container into which the content will be loaded. */\n @ViewChild(CdkPortalOutlet, {static: true}) _portalOutlet: CdkPortalOutlet;\n\n /** The state of the bottom sheet animations. */\n _animationState: 'void' | 'visible' | 'hidden' = 'void';\n\n /** Emits whenever the state of the animation changes. */\n _animationStateChanged = new EventEmitter<AnimationEvent>();\n\n /** The class that traps and manages focus within the bottom sheet. */\n private _focusTrap: FocusTrap;\n\n /** Element that was focused before the bottom sheet was opened. */\n private _elementFocusedBeforeOpened: HTMLElement | null = null;\n\n /** Server-side rendering-compatible reference to the global document object. */\n private _document: Document;\n\n /** Whether the component has been destroyed. */\n private _destroyed: boolean;\n\n constructor(\n private _elementRef: ElementRef<HTMLElement>,\n private _changeDetectorRef: ChangeDetectorRef,\n private _focusTrapFactory: FocusTrapFactory,\n private readonly _interactivityChecker: InteractivityChecker,\n private readonly _ngZone: NgZone,\n breakpointObserver: BreakpointObserver,\n @Optional() @Inject(DOCUMENT) document: any,\n /** The bottom sheet configuration. */\n public bottomSheetConfig: MatBottomSheetConfig,\n ) {\n super();\n\n this._document = document;\n this._breakpointSubscription = breakpointObserver\n .observe([Breakpoints.Medium, Breakpoints.Large, Breakpoints.XLarge])\n .subscribe(() => {\n this._toggleClass(\n 'mat-bottom-sheet-container-medium',\n breakpointObserver.isMatched(Breakpoints.Medium),\n );\n this._toggleClass(\n 'mat-bottom-sheet-container-large',\n breakpointObserver.isMatched(Breakpoints.Large),\n );\n this._toggleClass(\n 'mat-bottom-sheet-container-xlarge',\n breakpointObserver.isMatched(Breakpoints.XLarge),\n );\n });\n }\n\n /** Attach a component portal as content to this bottom sheet container. */\n attachComponentPortal<T>(portal: ComponentPortal<T>): ComponentRef<T> {\n this._validatePortalAttached();\n this._setPanelClass();\n this._savePreviouslyFocusedElement();\n return this._portalOutlet.attachComponentPortal(portal);\n }\n\n /** Attach a template portal as content to this bottom sheet container. */\n attachTemplatePortal<C>(portal: TemplatePortal<C>): EmbeddedViewRef<C> {\n this._validatePortalAttached();\n this._setPanelClass();\n this._savePreviouslyFocusedElement();\n return this._portalOutlet.attachTemplatePortal(portal);\n }\n\n /**\n * Attaches a DOM portal to the bottom sheet container.\n * @deprecated To be turned into a method.\n * @breaking-change 10.0.0\n */\n override attachDomPortal = (portal: DomPortal) => {\n this._validatePortalAttached();\n this._setPanelClass();\n this._savePreviouslyFocusedElement();\n return this._portalOutlet.attachDomPortal(portal);\n };\n\n /** Begin animation of bottom sheet entrance into view. */\n enter(): void {\n if (!this._destroyed) {\n this._animationState = 'visible';\n this._changeDetectorRef.detectChanges();\n }\n }\n\n /** Begin animation of the bottom sheet exiting from view. */\n exit(): void {\n if (!this._destroyed) {\n this._animationState = 'hidden';\n this._changeDetectorRef.markForCheck();\n }\n }\n\n ngOnDestroy() {\n this._breakpointSubscription.unsubscribe();\n this._destroyed = true;\n }\n\n _onAnimationDone(event: AnimationEvent) {\n if (event.toState === 'hidden') {\n this._restoreFocus();\n } else if (event.toState === 'visible') {\n this._trapFocus();\n }\n\n this._animationStateChanged.emit(event);\n }\n\n _onAnimationStart(event: AnimationEvent) {\n this._animationStateChanged.emit(event);\n }\n\n private _toggleClass(cssClass: string, add: boolean) {\n this._elementRef.nativeElement.classList.toggle(cssClass, add);\n }\n\n private _validatePortalAttached() {\n if (this._portalOutlet.hasAttached() && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw Error('Attempting to attach bottom sheet content after content is already attached');\n }\n }\n\n private _setPanelClass() {\n const element: HTMLElement = this._elementRef.nativeElement;\n element.classList.add(...coerceArray(this.bottomSheetConfig.panelClass || []));\n }\n\n /**\n * Focuses the provided element. If the element is not focusable, it will add a tabIndex\n * attribute to forcefully focus it. The attribute is removed after focus is moved.\n * @param element The element to focus.\n */\n private _forceFocus(element: HTMLElement, options?: FocusOptions) {\n if (!this._interactivityChecker.isFocusable(element)) {\n element.tabIndex = -1;\n // The tabindex attribute should be removed to avoid navigating to that element again\n this._ngZone.runOutsideAngular(() => {\n element.addEventListener('blur', () => element.removeAttribute('tabindex'));\n element.addEventListener('mousedown', () => element.removeAttribute('tabindex'));\n });\n }\n element.focus(options);\n }\n\n /**\n * Focuses the first element that matches the given selector within the focus trap.\n * @param selector The CSS selector for the element to set focus to.\n */\n private _focusByCssSelector(selector: string, options?: FocusOptions) {\n let elementToFocus = this._elementRef.nativeElement.querySelector(\n selector,\n ) as HTMLElement | null;\n if (elementToFocus) {\n this._forceFocus(elementToFocus, options);\n }\n }\n\n /**\n * Moves the focus inside the focus trap. When autoFocus is not set to 'bottom-sheet',\n * if focus cannot be moved then focus will go to the bottom sheet container.\n */\n private _trapFocus() {\n const element = this._elementRef.nativeElement;\n\n if (!this._focusTrap) {\n this._focusTrap = this._focusTrapFactory.create(element);\n }\n\n // If were to attempt to focus immediately, then the content of the bottom sheet would not\n // yet be ready in instances where change detection has to run first. To deal with this,\n // we simply wait for the microtask queue to be empty when setting focus when autoFocus\n // isn't set to bottom sheet. If the element inside the bottom sheet can't be focused,\n // then the container is focused so the user can't tab into other elements behind it.\n switch (this.bottomSheetConfig.autoFocus) {\n case false:\n case 'dialog':\n const activeElement = _getFocusedElementPierceShadowDom();\n // Ensure that focus is on the bottom sheet container. It's possible that a different\n // component tried to move focus while the open animation was running. See:\n // https://github.com/angular/components/issues/16215. Note that we only want to do this\n // if the focus isn't inside the bottom sheet already, because it's possible that the\n // consumer specified `autoFocus` in order to move focus themselves.\n if (activeElement !== element && !element.contains(activeElement)) {\n element.focus();\n }\n break;\n case true:\n case 'first-tabbable':\n this._focusTrap.focusInitialElementWhenReady();\n break;\n case 'first-heading':\n this._focusByCssSelector('h1, h2, h3, h4, h5, h6, [role=\"heading\"]');\n break;\n default:\n this._focusByCssSelector(this.bottomSheetConfig.autoFocus!);\n break;\n }\n }\n\n /** Restores focus to the element that was focused before the bottom sheet was opened. */\n private _restoreFocus() {\n const toFocus = this._elementFocusedBeforeOpened;\n\n // We need the extra check, because IE can set the `activeElement` to null in some cases.\n if (this.bottomSheetConfig.restoreFocus && toFocus && typeof toFocus.focus === 'function') {\n const activeElement = _getFocusedElementPierceShadowDom();\n const element = this._elementRef.nativeElement;\n\n // Make sure that focus is still inside the bottom sheet or is on the body (usually because a\n // non-focusable element like the backdrop was clicked) before moving it. It's possible that\n // the consumer moved it themselves before the animation was done, in which case we shouldn't\n // do anything.\n if (\n !activeElement ||\n activeElement === this._document.body ||\n activeElement === element ||\n element.contains(activeElement)\n ) {\n toFocus.focus();\n }\n }\n\n if (this._focusTrap) {\n this._focusTrap.destroy();\n }\n }\n\n /** Saves a reference to the element that was focused before the bottom sheet was opened. */\n private _savePreviouslyFocusedElement() {\n this._elementFocusedBeforeOpened = _getFocusedElementPierceShadowDom();\n\n // The `focus` method isn't available during server-side rendering.\n if (this._elementRef.nativeElement.focus) {\n Promise.resolve().then(() => this._elementRef.nativeElement.focus());\n }\n }\n}\n","<ng-template cdkPortalOutlet></ng-template>\r\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {OverlayModule} from '@angular/cdk/overlay';\nimport {PortalModule} from '@angular/cdk/portal';\nimport {NgModule} from '@angular/core';\nimport {MatCommonModule} from '@angular/material/core';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\n\n@NgModule({\n imports: [OverlayModule, MatCommonModule, PortalModule],\n exports: [MatBottomSheetContainer, MatCommonModule],\n declarations: [MatBottomSheetContainer],\n entryComponents: [MatBottomSheetContainer],\n})\nexport class MatBottomSheetModule {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ESCAPE, hasModifierKey} from '@angular/cdk/keycodes';\nimport {OverlayRef} from '@angular/cdk/overlay';\nimport {merge, Observable, Subject} from 'rxjs';\nimport {filter, take} from 'rxjs/operators';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\n\n/**\n * Reference to a bottom sheet dispatched from the bottom sheet service.\n */\nexport class MatBottomSheetRef<T = any, R = any> {\n /** Instance of the component making up the content of the bottom sheet. */\n instance: T;\n\n /**\n * Instance of the component into which the bottom sheet content is projected.\n * @docs-private\n */\n containerInstance: MatBottomSheetContainer;\n\n /** Whether the user is allowed to close the bottom sheet. */\n disableClose: boolean | undefined;\n\n /** Subject for notifying the user that the bottom sheet has been dismissed. */\n private readonly _afterDismissed = new Subject<R | undefined>();\n\n /** Subject for notifying the user that the bottom sheet has opened and appeared. */\n private readonly _afterOpened = new Subject<void>();\n\n /** Result to be passed down to the `afterDismissed` stream. */\n private _result: R | undefined;\n\n /** Handle to the timeout that's running as a fallback in case the exit animation doesn't fire. */\n private _closeFallbackTimeout: any;\n\n constructor(containerInstance: MatBottomSheetContainer, private _overlayRef: OverlayRef) {\n this.containerInstance = containerInstance;\n this.disableClose = containerInstance.bottomSheetConfig.disableClose;\n\n // Emit when opening animation completes\n containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'done' && event.toState === 'visible'),\n take(1),\n )\n .subscribe(() => {\n this._afterOpened.next();\n this._afterOpened.complete();\n });\n\n // Dispose overlay when closing animation is complete\n containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'done' && event.toState === 'hidden'),\n take(1),\n )\n .subscribe(() => {\n clearTimeout(this._closeFallbackTimeout);\n _overlayRef.dispose();\n });\n\n _overlayRef\n .detachments()\n .pipe(take(1))\n .subscribe(() => {\n this._afterDismissed.next(this._result);\n this._afterDismissed.complete();\n });\n\n merge(\n _overlayRef.backdropClick(),\n _overlayRef.keydownEvents().pipe(filter(event => event.keyCode === ESCAPE)),\n ).subscribe(event => {\n if (\n !this.disableClose &&\n (event.type !== 'keydown' || !hasModifierKey(event as KeyboardEvent))\n ) {\n event.preventDefault();\n this.dismiss();\n }\n });\n }\n\n /**\n * Dismisses the bottom sheet.\n * @param result Data to be passed back to the bottom sheet opener.\n */\n dismiss(result?: R): void {\n if (!this._afterDismissed.closed) {\n // Transition the backdrop in parallel to the bottom sheet.\n this.containerInstance._animationStateChanged\n .pipe(\n filter(event => event.phaseName === 'start'),\n take(1),\n )\n .subscribe(event => {\n // The logic that disposes of the overlay depends on the exit animation completing, however\n // it isn't guaranteed if the parent view is destroyed while it's running. Add a fallback\n // timeout which will clean everything up if the animation hasn't fired within the specified\n // amount of time plus 100ms. We don't need to run this outside the NgZone, because for the\n // vast majority of cases the timeout will have been cleared before it has fired.\n this._closeFallbackTimeout = setTimeout(() => {\n this._overlayRef.dispose();\n }, event.totalTime + 100);\n\n this._overlayRef.detachBackdrop();\n });\n\n this._result = result;\n this.containerInstance.exit();\n }\n }\n\n /** Gets an observable that is notified when the bottom sheet is finished closing. */\n afterDismissed(): Observable<R | undefined> {\n return this._afterDismissed;\n }\n\n /** Gets an observable that is notified when the bottom sheet has opened and appeared. */\n afterOpened(): Observable<void> {\n return this._afterOpened;\n }\n\n /**\n * Gets an observable that emits when the overlay's backdrop has been clicked.\n */\n backdropClick(): Observable<MouseEvent> {\n return this._overlayRef.backdropClick();\n }\n\n /**\n * Gets an observable that emits when keydown events are targeted on the overlay.\n */\n keydownEvents(): Observable<KeyboardEvent> {\n return this._overlayRef.keydownEvents();\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {Directionality} from '@angular/cdk/bidi';\nimport {Overlay, OverlayConfig, OverlayRef} from '@angular/cdk/overlay';\nimport {ComponentPortal, ComponentType, TemplatePortal} from '@angular/cdk/portal';\nimport {\n ComponentRef,\n Injectable,\n Injector,\n Optional,\n SkipSelf,\n TemplateRef,\n InjectionToken,\n Inject,\n OnDestroy,\n StaticProvider,\n InjectFlags,\n} from '@angular/core';\nimport {of as observableOf} from 'rxjs';\nimport {MAT_BOTTOM_SHEET_DATA, MatBottomSheetConfig} from './bottom-sheet-config';\nimport {MatBottomSheetContainer} from './bottom-sheet-container';\nimport {MatBottomSheetModule} from './bottom-sheet-module';\nimport {MatBottomSheetRef} from './bottom-sheet-ref';\n\n/** Injection token that can be used to specify default bottom sheet options. */\nexport const MAT_BOTTOM_SHEET_DEFAULT_OPTIONS = new InjectionToken<MatBottomSheetConfig>(\n 'mat-bottom-sheet-default-options',\n);\n\n/**\n * Service to trigger Material Design bottom sheets.\n */\n@Injectable({providedIn: MatBottomSheetModule})\nexport class MatBottomSheet implements OnDestroy {\n private _bottomSheetRefAtThisLevel: MatBottomSheetRef<any> | null = null;\n\n /** Reference to the currently opened bottom sheet. */\n get _openedBottomSheetRef(): MatBottomSheetRef<any> | null {\n const parent = this._parentBottomSheet;\n return parent ? parent._openedBottomSheetRef : this._bottomSheetRefAtThisLevel;\n }\n\n set _openedBottomSheetRef(value: MatBottomSheetRef<any> | null) {\n if (this._parentBottomSheet) {\n this._parentBottomSheet._openedBottomSheetRef = value;\n } else {\n this._bottomSheetRefAtThisLevel = value;\n }\n }\n\n constructor(\n private _overlay: Overlay,\n private _injector: Injector,\n @Optional() @SkipSelf() private _parentBottomSheet: MatBottomSheet,\n @Optional()\n @Inject(MAT_BOTTOM_SHEET_DEFAULT_OPTIONS)\n private _defaultOptions?: MatBottomSheetConfig,\n ) {}\n\n /**\n * Opens a bottom sheet containing the given component.\n * @param component Type of the component to load into the bottom sheet.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened bottom sheet.\n */\n open<T, D = any, R = any>(\n component: ComponentType<T>,\n config?: MatBottomSheetConfig<D>,\n ): MatBottomSheetRef<T, R>;\n\n /**\n * Opens a bottom sheet containing the given template.\n * @param template TemplateRef to instantiate as the bottom sheet content.\n * @param config Extra configuration options.\n * @returns Reference to the newly-opened bottom sheet.\n */\n open<T, D = any, R = any>(\n template: TemplateRef<T>,\n config?: MatBottomSheetConfig<D>,\n ): MatBottomSheetRef<T, R>;\n\n open<T, D = any, R = any>(\n componentOrTemplateRef: ComponentType<T> | TemplateRef<T>,\n config?: MatBottomSheetConfig<D>,\n ): MatBottomSheetRef<T, R> {\n const _config = _applyConfigDefaults(\n this._defaultOptions || new MatBottomSheetConfig(),\n config,\n );\n const overlayRef = this._createOverlay(_config);\n const container = this._attachContainer(overlayRef, _config);\n const ref = new MatBottomSheetRef<T, R>(container, overlayRef);\n\n if (componentOrTemplateRef instanceof TemplateRef) {\n container.attachTemplatePortal(\n new TemplatePortal<T>(componentOrTemplateRef, null!, {\n $implicit: _config.data,\n bottomSheetRef: ref,\n } as any),\n );\n } else {\n const portal = new ComponentPortal(\n componentOrTemplateRef,\n undefined,\n this._createInjector(_config, ref),\n );\n const contentRef = container.attachComponentPortal(portal);\n ref.instance = contentRef.instance;\n }\n\n // When the bottom sheet is dismissed, clear the reference to it.\n ref.afterDismissed().subscribe(() => {\n // Clear the bottom sheet ref if it hasn't already been replaced by a newer one.\n if (this._openedBottomSheetRef == ref) {\n this._openedBottomSheetRef = null;\n }\n });\n\n if (this._openedBottomSheetRef) {\n // If a bottom sheet is already in view, dismiss it and enter the\n // new bottom sheet after exit animation is complete.\n this._openedBottomSheetRef.afterDismissed().subscribe(() => ref.containerInstance.enter());\n this._openedBottomSheetRef.dismiss();\n } else {\n // If no bottom sheet is in view, enter the new bottom sheet.\n ref.containerInstance.enter();\n }\n\n this._openedBottomSheetRef = ref;\n\n return ref;\n }\n\n /**\n * Dismisses the currently-visible bottom sheet.\n * @param result Data to pass to the bottom sheet instance.\n */\n dismiss<R = any>(result?: R): void {\n if (this._openedBottomSheetRef) {\n this._openedBottomSheetRef.dismiss(result);\n }\n }\n\n ngOnDestroy() {\n if (this._bottomSheetRefAtThisLevel) {\n this._bottomSheetRefAtThisLevel.dismiss();\n }\n }\n\n /**\n * Attaches the bottom sheet container component to the overlay.\n */\n private _attachContainer(\n overlayRef: OverlayRef,\n config: MatBottomSheetConfig,\n ): MatBottomSheetContainer {\n const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;\n const injector = Injector.create({\n parent: userInjector || this._injector,\n providers: [{provide: MatBottomSheetConfig, useValue: config}],\n });\n\n const containerPortal = new ComponentPortal(\n MatBottomSheetContainer,\n config.viewContainerRef,\n injector,\n );\n const containerRef: ComponentRef<MatBottomSheetContainer> = overlayRef.attach(containerPortal);\n return containerRef.instance;\n }\n\n /**\n * Creates a new overlay and places it in the correct location.\n * @param config The user-specified bottom sheet config.\n */\n private _createOverlay(config: MatBottomSheetConfig): OverlayRef {\n const overlayConfig = new OverlayConfig({\n direction: config.direction,\n hasBackdrop: config.hasBackdrop,\n disposeOnNavigation: config.closeOnNavigation,\n maxWidth: '100%',\n scrollStrategy: config.scrollStrategy || this._overlay.scrollStrategies.block(),\n positionStrategy: this._overlay.position().global().centerHorizontally().bottom('0'),\n });\n\n if (config.backdropClass) {\n overlayConfig.backdropClass = config.backdropClass;\n }\n\n return this._overlay.create(overlayConfig);\n }\n\n /**\n * Creates an injector to be used inside of a bottom sheet component.\n * @param config Config that was used to create the bottom sheet.\n * @param bottomSheetRef Reference to the bottom sheet.\n */\n private _createInjector<T>(\n config: MatBottomSheetConfig,\n bottomSheetRef: MatBottomSheetRef<T>,\n ): Injector {\n const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;\n const providers: StaticProvider[] = [\n {provide: MatBottomSheetRef, useValue: bottomSheetRef},\n {provide: MAT_BOTTOM_SHEET_DATA, useValue: config.data},\n ];\n\n if (\n config.direction &&\n (!userInjector ||\n !userInjector.get<Directionality | null>(Directionality, null, InjectFlags.Optional))\n ) {\n providers.push({\n provide: Directionality,\n useValue: {value: config.direction, change: observableOf()},\n });\n }\n\n return Injector.create({parent: userInjector || this._injector, providers});\n }\n}\n\n/**\n * Applies default options to the bottom sheet config.\n * @param defaults Object containing the default values to which to fall back.\n * @param config The configuration to which the defaults will be applied.\n * @returns The new configuration object with defaults applied.\n */\nfunction _applyConfigDefaults(\n defaults: MatBottomSheetConfig,\n config?: MatBottomSheetConfig,\n): MatBottomSheetConfig {\n return {...defaults, ...config};\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './bottom-sheet-module';\nexport * from './bottom-sheet';\nexport * from './bottom-sheet-config';\nexport * from './bottom-sheet-container';\nexport * from './bottom-sheet-animations';\nexport * from './bottom-sheet-ref';\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './public-api';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["observableOf"],"mappings":";;;;;;;;;;;;;;;;;;;AAAA;;;;;;;AAiBA;MACa,wBAAwB,GAEjC;;IAEF,gBAAgB,EAAE,OAAO,CAAC,OAAO,EAAE;QACjC,KAAK,CAAC,cAAc,EAAE,KAAK,CAAC,EAAC,SAAS,EAAE,kBAAkB,EAAC,CAAC,CAAC;QAC7D,KAAK,CAAC,SAAS,EAAE,KAAK,CAAC,EAAC,SAAS,EAAE,gBAAgB,EAAC,CAAC,CAAC;QACtD,UAAU,CACR,oCAAoC,EACpC,OAAO,CAAC,GAAG,kBAAkB,CAAC,OAAO,IAAI,eAAe,CAAC,kBAAkB,EAAE,CAAC,CAC/E;QACD,UAAU,CACR,iBAAiB,EACjB,OAAO,CAAC,GAAG,kBAAkB,CAAC,OAAO,IAAI,eAAe,CAAC,kBAAkB,EAAE,CAAC,CAC/E;KACF,CAAC;;;ACjCJ;;;;;;;AAeA;MACa,qBAAqB,GAAG,IAAI,cAAc,CAAM,oBAAoB,EAAE;AAEnF;;;MAGa,oBAAoB;IAAjC;;QAWE,SAAI,GAAc,IAAI,CAAC;;QAGvB,gBAAW,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C,UAAU,EAAE,oBAAoB,EAAC;yGAqBU,cAAc;0BAAjE,QAAQ;;0BAAI,QAAQ;;0BACpB,QAAQ;;0BACR,MAAM;2BAAC,gCAAgC;;AAuK5C;;;;;;AAMA,SAAS,oBAAoB,CAC3B,QAA8B,EAC9B,MAA6B;IAE7B,OAAO,EAAC,GAAG,QAAQ,EAAE,GAAG,MAAM,EAAC,CAAC;AAClC;;AC/OA;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;"}
@@ -17,8 +17,7 @@ class MatButtonHarness extends ContentContainerComponentHarness {
17
17
  * @return a `HarnessPredicate` configured with the given options.
18
18
  */
19
19
  static with(options = {}) {
20
- return new HarnessPredicate(MatButtonHarness, options)
21
- .addOption('text', options.text, (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));
20
+ return new HarnessPredicate(MatButtonHarness, options).addOption('text', options.text, (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));
22
21
  }
23
22
  async click(...args) {
24
23
  return (await this.host()).click(...args);
@@ -1 +1 @@
1
- {"version":3,"file":"testing.mjs","sources":["../../../../../../../src/material/button/testing/button-harness.ts","../../../../../../../src/material/button/testing/button-harness-filters.ts","../../../../../../../src/material/button/testing/public-api.ts","../../../../../../../src/material/button/testing/index.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ContentContainerComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {ButtonHarnessFilters} from './button-harness-filters';\n\n\n/** Harness for interacting with a standard mat-button in tests. */\nexport class MatButtonHarness extends ContentContainerComponentHarness {\n // TODO(jelbourn) use a single class, like `.mat-button-base`\n /** The selector for the host element of a `MatButton` instance. */\n static hostSelector = `[mat-button], [mat-raised-button], [mat-flat-button], [mat-icon-button],\n [mat-stroked-button], [mat-fab], [mat-mini-fab]`;\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatButtonHarness` that meets\n * certain criteria.\n * @param options Options for filtering which button instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: ButtonHarnessFilters = {}): HarnessPredicate<MatButtonHarness> {\n return new HarnessPredicate(MatButtonHarness, options)\n .addOption('text', options.text,\n (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));\n }\n\n /**\n * Clicks the button at the given position relative to its top-left.\n * @param relativeX The relative x position of the click.\n * @param relativeY The relative y position of the click.\n */\n click(relativeX: number, relativeY: number): Promise<void>;\n /** Clicks the button at its center. */\n click(location: 'center'): Promise<void>;\n /** Clicks the button. */\n click(): Promise<void>;\n async click(...args: [] | ['center'] | [number, number]): Promise<void> {\n return (await this.host()).click(...(args as []));\n }\n\n /** Whether the button is disabled. */\n async isDisabled(): Promise<boolean> {\n const disabled = (await this.host()).getAttribute('disabled');\n return coerceBooleanProperty(await disabled);\n }\n\n /** Gets the button's label text. */\n async getText(): Promise<string> {\n return (await this.host()).text();\n }\n\n /** Focuses the button. */\n async focus(): Promise<void> {\n return (await this.host()).focus();\n }\n\n /** Blurs the button. */\n async blur(): Promise<void> {\n return (await this.host()).blur();\n }\n\n /** Whether the button is focused. */\n async isFocused(): Promise<boolean> {\n return (await this.host()).isFocused();\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {BaseHarnessFilters} from '@angular/cdk/testing';\n\n/** A set of criteria that can be used to filter a list of `MatButtonHarness` instances. */\nexport interface ButtonHarnessFilters extends BaseHarnessFilters {\n /** Only find instances whose text matches the given value. */\n text?: string | RegExp;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './button-harness';\nexport * from './button-harness-filters';\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;AAAA;;;;;;;AAaA;MACa,gBAAiB,SAAQ,gCAAgC;;;;;;;IAYpE,OAAO,IAAI,CAAC,UAAgC,EAAE;QAC5C,OAAO,IAAI,gBAAgB,CAAC,gBAAgB,EAAE,OAAO,CAAC;aACjD,SAAS,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI,EAC3B,CAAC,OAAO,EAAE,IAAI,KAAK,gBAAgB,CAAC,aAAa,CAAC,OAAO,CAAC,OAAO,EAAE,EAAE,IAAI,CAAC,CAAC,CAAC;KACrF;IAYD,MAAM,KAAK,CAAC,GAAG,IAAwC;QACrD,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,KAAK,CAAC,GAAI,IAAW,CAAC,CAAC;KACnD;;IAGD,MAAM,UAAU;QACd,MAAM,QAAQ,GAAG,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,YAAY,CAAC,UAAU,CAAC,CAAC;QAC9D,OAAO,qBAAqB,CAAC,MAAM,QAAQ,CAAC,CAAC;KAC9C;;IAGD,MAAM,OAAO;QACX,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC;KACnC;;IAGD,MAAM,KAAK;QACT,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,KAAK,EAAE,CAAC;KACpC;;IAGD,MAAM,IAAI;QACR,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC;KACnC;;IAGD,MAAM,SAAS;QACb,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,SAAS,EAAE,CAAC;KACxC;;AAvDD;AACA;AACO,6BAAY,GAAG;yEACiD;;AClBzE;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;;;;;"}
1
+ {"version":3,"file":"testing.mjs","sources":["../../../../../../../src/material/button/testing/button-harness.ts","../../../../../../../src/material/button/testing/button-harness-filters.ts","../../../../../../../src/material/button/testing/public-api.ts","../../../../../../../src/material/button/testing/index.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ContentContainerComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {ButtonHarnessFilters} from './button-harness-filters';\n\n/** Harness for interacting with a standard mat-button in tests. */\nexport class MatButtonHarness extends ContentContainerComponentHarness {\n // TODO(jelbourn) use a single class, like `.mat-button-base`\n /** The selector for the host element of a `MatButton` instance. */\n static hostSelector = `[mat-button], [mat-raised-button], [mat-flat-button], [mat-icon-button],\n [mat-stroked-button], [mat-fab], [mat-mini-fab]`;\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatButtonHarness` that meets\n * certain criteria.\n * @param options Options for filtering which button instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: ButtonHarnessFilters = {}): HarnessPredicate<MatButtonHarness> {\n return new HarnessPredicate(MatButtonHarness, options).addOption(\n 'text',\n options.text,\n (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text),\n );\n }\n\n /**\n * Clicks the button at the given position relative to its top-left.\n * @param relativeX The relative x position of the click.\n * @param relativeY The relative y position of the click.\n */\n click(relativeX: number, relativeY: number): Promise<void>;\n /** Clicks the button at its center. */\n click(location: 'center'): Promise<void>;\n /** Clicks the button. */\n click(): Promise<void>;\n async click(...args: [] | ['center'] | [number, number]): Promise<void> {\n return (await this.host()).click(...(args as []));\n }\n\n /** Whether the button is disabled. */\n async isDisabled(): Promise<boolean> {\n const disabled = (await this.host()).getAttribute('disabled');\n return coerceBooleanProperty(await disabled);\n }\n\n /** Gets the button's label text. */\n async getText(): Promise<string> {\n return (await this.host()).text();\n }\n\n /** Focuses the button. */\n async focus(): Promise<void> {\n return (await this.host()).focus();\n }\n\n /** Blurs the button. */\n async blur(): Promise<void> {\n return (await this.host()).blur();\n }\n\n /** Whether the button is focused. */\n async isFocused(): Promise<boolean> {\n return (await this.host()).isFocused();\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {BaseHarnessFilters} from '@angular/cdk/testing';\n\n/** A set of criteria that can be used to filter a list of `MatButtonHarness` instances. */\nexport interface ButtonHarnessFilters extends BaseHarnessFilters {\n /** Only find instances whose text matches the given value. */\n text?: string | RegExp;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './button-harness';\nexport * from './button-harness-filters';\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;AAAA;;;;;;;AAYA;MACa,gBAAiB,SAAQ,gCAAgC;;;;;;;IAYpE,OAAO,IAAI,CAAC,UAAgC,EAAE;QAC5C,OAAO,IAAI,gBAAgB,CAAC,gBAAgB,EAAE,OAAO,CAAC,CAAC,SAAS,CAC9D,MAAM,EACN,OAAO,CAAC,IAAI,EACZ,CAAC,OAAO,EAAE,IAAI,KAAK,gBAAgB,CAAC,aAAa,CAAC,OAAO,CAAC,OAAO,EAAE,EAAE,IAAI,CAAC,CAC3E,CAAC;KACH;IAYD,MAAM,KAAK,CAAC,GAAG,IAAwC;QACrD,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,KAAK,CAAC,GAAI,IAAW,CAAC,CAAC;KACnD;;IAGD,MAAM,UAAU;QACd,MAAM,QAAQ,GAAG,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,YAAY,CAAC,UAAU,CAAC,CAAC;QAC9D,OAAO,qBAAqB,CAAC,MAAM,QAAQ,CAAC,CAAC;KAC9C;;IAGD,MAAM,OAAO;QACX,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC;KACnC;;IAGD,MAAM,KAAK;QACT,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,KAAK,EAAE,CAAC;KACpC;;IAGD,MAAM,IAAI;QACR,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,IAAI,EAAE,CAAC;KACnC;;IAGD,MAAM,SAAS;QACb,OAAO,CAAC,MAAM,IAAI,CAAC,IAAI,EAAE,EAAE,SAAS,EAAE,CAAC;KACxC;;AAzDD;AACA;AACO,6BAAY,GAAG;yEACiD;;ACjBzE;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;;;;;"}
@@ -57,7 +57,7 @@ class MatButtonToggleHarness extends ComponentHarness {
57
57
  async getAppearance() {
58
58
  const host = await this.host();
59
59
  const className = 'mat-button-toggle-appearance-standard';
60
- return await host.hasClass(className) ? 'standard' : 'legacy';
60
+ return (await host.hasClass(className)) ? 'standard' : 'legacy';
61
61
  }
62
62
  /** Focuses the toggle. */
63
63
  async focus() {
@@ -132,7 +132,7 @@ class MatButtonToggleGroupHarness extends ComponentHarness {
132
132
  }
133
133
  /** Gets whether the button toggle group is disabled. */
134
134
  async isDisabled() {
135
- return await (await this.host()).getAttribute('aria-disabled') === 'true';
135
+ return (await (await this.host()).getAttribute('aria-disabled')) === 'true';
136
136
  }
137
137
  /** Gets whether the button toggle group is laid out vertically. */
138
138
  async isVertical() {
@@ -142,7 +142,7 @@ class MatButtonToggleGroupHarness extends ComponentHarness {
142
142
  async getAppearance() {
143
143
  const host = await this.host();
144
144
  const className = 'mat-button-toggle-group-appearance-standard';
145
- return await host.hasClass(className) ? 'standard' : 'legacy';
145
+ return (await host.hasClass(className)) ? 'standard' : 'legacy';
146
146
  }
147
147
  }
148
148
  /** The selector for the host element of a `MatButton` instance. */
@@ -1 +1 @@
1
- {"version":3,"file":"testing.mjs","sources":["../../../../../../../src/material/button-toggle/testing/button-toggle-harness.ts","../../../../../../../src/material/button-toggle/testing/button-toggle-harness-filters.ts","../../../../../../../src/material/button-toggle/testing/button-toggle-group-harness.ts","../../../../../../../src/material/button-toggle/testing/button-toggle-group-harness-filters.ts","../../../../../../../src/material/button-toggle/testing/public-api.ts","../../../../../../../src/material/button-toggle/testing/index.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {MatButtonToggleAppearance} from '@angular/material/button-toggle';\nimport {ButtonToggleHarnessFilters} from './button-toggle-harness-filters';\n\n\n/** Harness for interacting with a standard mat-button-toggle in tests. */\nexport class MatButtonToggleHarness extends ComponentHarness {\n /** The selector for the host element of a `MatButton` instance. */\n static hostSelector = '.mat-button-toggle';\n\n private _label = this.locatorFor('.mat-button-toggle-label-content');\n private _button = this.locatorFor('.mat-button-toggle-button');\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatButtonToggleHarness` that meets\n * certain criteria.\n * @param options Options for filtering which button toggle instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: ButtonToggleHarnessFilters = {}): HarnessPredicate<MatButtonToggleHarness> {\n return new HarnessPredicate(MatButtonToggleHarness, options)\n .addOption('text', options.text,\n (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text))\n .addOption('name', options.name,\n (harness, name) => HarnessPredicate.stringMatches(harness.getName(), name))\n .addOption('checked', options.checked,\n async (harness, checked) => (await harness.isChecked()) === checked);\n }\n\n /** Gets a boolean promise indicating if the button toggle is checked. */\n async isChecked(): Promise<boolean> {\n const checked = (await this._button()).getAttribute('aria-pressed');\n return coerceBooleanProperty(await checked);\n }\n\n /** Gets a boolean promise indicating if the button toggle is disabled. */\n async isDisabled(): Promise<boolean> {\n const disabled = (await this._button()).getAttribute('disabled');\n return coerceBooleanProperty(await disabled);\n }\n\n /** Gets a promise for the button toggle's name. */\n async getName(): Promise<string | null> {\n return (await this._button()).getAttribute('name');\n }\n\n /** Gets a promise for the button toggle's aria-label. */\n async getAriaLabel(): Promise<string | null> {\n return (await this._button()).getAttribute('aria-label');\n }\n\n /** Gets a promise for the button toggles's aria-labelledby. */\n async getAriaLabelledby(): Promise<string | null> {\n return (await this._button()).getAttribute('aria-labelledby');\n }\n\n /** Gets a promise for the button toggle's text. */\n async getText(): Promise<string> {\n return (await this._label()).text();\n }\n\n /** Gets the appearance that the button toggle is using. */\n async getAppearance(): Promise<MatButtonToggleAppearance> {\n const host = await this.host();\n const className = 'mat-button-toggle-appearance-standard';\n return await host.hasClass(className) ? 'standard' : 'legacy';\n }\n\n /** Focuses the toggle. */\n async focus(): Promise<void> {\n return (await this._button()).focus();\n }\n\n /** Blurs the toggle. */\n async blur(): Promise<void> {\n return (await this._button()).blur();\n }\n\n /** Whether the toggle is focused. */\n async isFocused(): Promise<boolean> {\n return (await this._button()).isFocused();\n }\n\n /** Toggle the checked state of the buttons toggle. */\n async toggle(): Promise<void> {\n return (await this._button()).click();\n }\n\n /**\n * Puts the button toggle in a checked state by toggling it if it's\n * currently unchecked, or doing nothing if it is already checked.\n */\n async check(): Promise<void> {\n if (!(await this.isChecked())) {\n await this.toggle();\n }\n }\n\n /**\n * Puts the button toggle in an unchecked state by toggling it if it's\n * currently checked, or doing nothing if it's already unchecked.\n */\n async uncheck(): Promise<void> {\n if (await this.isChecked()) {\n await this.toggle();\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {BaseHarnessFilters} from '@angular/cdk/testing';\n\n/** Criteria that can be used to filter a list of `MatButtonToggleHarness` instances. */\nexport interface ButtonToggleHarnessFilters extends BaseHarnessFilters {\n /** Only find instances whose text matches the given value. */\n text?: string | RegExp;\n /** Only find instances whose name matches the given value. */\n name?: string | RegExp;\n /** Only find instances that are checked. */\n checked?: boolean;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {MatButtonToggleAppearance} from '@angular/material/button-toggle';\nimport {ButtonToggleGroupHarnessFilters} from './button-toggle-group-harness-filters';\nimport {ButtonToggleHarnessFilters} from './button-toggle-harness-filters';\nimport {MatButtonToggleHarness} from './button-toggle-harness';\n\n\n/** Harness for interacting with a standard mat-button-toggle in tests. */\nexport class MatButtonToggleGroupHarness extends ComponentHarness {\n /** The selector for the host element of a `MatButton` instance. */\n static hostSelector = '.mat-button-toggle-group';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatButtonToggleGroupHarness`\n * that meets certain criteria.\n * @param options Options for filtering which button toggle instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: ButtonToggleGroupHarnessFilters = {}):\n HarnessPredicate<MatButtonToggleGroupHarness> {\n return new HarnessPredicate(MatButtonToggleGroupHarness, options);\n }\n\n /**\n * Gets the button toggles that are inside the group.\n * @param filter Optionally filters which toggles are included.\n */\n async getToggles(filter: ButtonToggleHarnessFilters = {}): Promise<MatButtonToggleHarness[]> {\n return this.locatorForAll(MatButtonToggleHarness.with(filter))();\n }\n\n /** Gets whether the button toggle group is disabled. */\n async isDisabled(): Promise<boolean> {\n return await (await this.host()).getAttribute('aria-disabled') === 'true';\n }\n\n /** Gets whether the button toggle group is laid out vertically. */\n async isVertical(): Promise<boolean> {\n return (await this.host()).hasClass('mat-button-toggle-vertical');\n }\n\n /** Gets the appearance that the group is using. */\n async getAppearance(): Promise<MatButtonToggleAppearance> {\n const host = await this.host();\n const className = 'mat-button-toggle-group-appearance-standard';\n return await host.hasClass(className) ? 'standard' : 'legacy';\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {BaseHarnessFilters} from '@angular/cdk/testing';\n\n/** Criteria that can be used to filter a list of `MatButtonToggleGroupHarness` instances. */\nexport interface ButtonToggleGroupHarnessFilters extends BaseHarnessFilters {\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './button-toggle-harness';\nexport * from './button-toggle-harness-filters';\nexport * from './button-toggle-group-harness';\nexport * from './button-toggle-group-harness-filters';\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;AAAA;;;;;;;AAcA;MACa,sBAAuB,SAAQ,gBAAgB;IAA5D;;QAIU,WAAM,GAAG,IAAI,CAAC,UAAU,CAAC,kCAAkC,CAAC,CAAC;QAC7D,YAAO,GAAG,IAAI,CAAC,UAAU,CAAC,2BAA2B,CAAC,CAAC;KAgGhE;;;;;;;IAxFC,OAAO,IAAI,CAAC,UAAsC,EAAE;QAClD,OAAO,IAAI,gBAAgB,CAAC,sBAAsB,EAAE,OAAO,CAAC;aACvD,SAAS,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI,EAC3B,CAAC,OAAO,EAAE,IAAI,KAAK,gBAAgB,CAAC,aAAa,CAAC,OAAO,CAAC,OAAO,EAAE,EAAE,IAAI,CAAC,CAAC;aAC9E,SAAS,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI,EAC3B,CAAC,OAAO,EAAE,IAAI,KAAK,gBAAgB,CAAC,aAAa,CAAC,OAAO,CAAC,OAAO,EAA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,IAAI,CAAC,IAAI,EAAE,CAAC;QAC/B,MAAM,SAAS,GAAG,6CAA6C,CAAC;QAChE,OAAO,MAAM,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,GAAG,UAAU,GAAG,QAAQ,CAAC;KAC/D;;AArCD;AACO,wCAAY,GAAG,0BAA0B;;AClBlD;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;;;;;"}
1
+ {"version":3,"file":"testing.mjs","sources":["../../../../../../../src/material/button-toggle/testing/button-toggle-harness.ts","../../../../../../../src/material/button-toggle/testing/button-toggle-harness-filters.ts","../../../../../../../src/material/button-toggle/testing/button-toggle-group-harness.ts","../../../../../../../src/material/button-toggle/testing/button-toggle-group-harness-filters.ts","../../../../../../../src/material/button-toggle/testing/public-api.ts","../../../../../../../src/material/button-toggle/testing/index.ts"],"sourcesContent":["/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {MatButtonToggleAppearance} from '@angular/material/button-toggle';\nimport {ButtonToggleHarnessFilters} from './button-toggle-harness-filters';\n\n/** Harness for interacting with a standard mat-button-toggle in tests. */\nexport class MatButtonToggleHarness extends ComponentHarness {\n /** The selector for the host element of a `MatButton` instance. */\n static hostSelector = '.mat-button-toggle';\n\n private _label = this.locatorFor('.mat-button-toggle-label-content');\n private _button = this.locatorFor('.mat-button-toggle-button');\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatButtonToggleHarness` that meets\n * certain criteria.\n * @param options Options for filtering which button toggle instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: ButtonToggleHarnessFilters = {}): HarnessPredicate<MatButtonToggleHarness> {\n return new HarnessPredicate(MatButtonToggleHarness, options)\n .addOption('text', options.text, (harness, text) =>\n HarnessPredicate.stringMatches(harness.getText(), text),\n )\n .addOption('name', options.name, (harness, name) =>\n HarnessPredicate.stringMatches(harness.getName(), name),\n )\n .addOption(\n 'checked',\n options.checked,\n async (harness, checked) => (await harness.isChecked()) === checked,\n );\n }\n\n /** Gets a boolean promise indicating if the button toggle is checked. */\n async isChecked(): Promise<boolean> {\n const checked = (await this._button()).getAttribute('aria-pressed');\n return coerceBooleanProperty(await checked);\n }\n\n /** Gets a boolean promise indicating if the button toggle is disabled. */\n async isDisabled(): Promise<boolean> {\n const disabled = (await this._button()).getAttribute('disabled');\n return coerceBooleanProperty(await disabled);\n }\n\n /** Gets a promise for the button toggle's name. */\n async getName(): Promise<string | null> {\n return (await this._button()).getAttribute('name');\n }\n\n /** Gets a promise for the button toggle's aria-label. */\n async getAriaLabel(): Promise<string | null> {\n return (await this._button()).getAttribute('aria-label');\n }\n\n /** Gets a promise for the button toggles's aria-labelledby. */\n async getAriaLabelledby(): Promise<string | null> {\n return (await this._button()).getAttribute('aria-labelledby');\n }\n\n /** Gets a promise for the button toggle's text. */\n async getText(): Promise<string> {\n return (await this._label()).text();\n }\n\n /** Gets the appearance that the button toggle is using. */\n async getAppearance(): Promise<MatButtonToggleAppearance> {\n const host = await this.host();\n const className = 'mat-button-toggle-appearance-standard';\n return (await host.hasClass(className)) ? 'standard' : 'legacy';\n }\n\n /** Focuses the toggle. */\n async focus(): Promise<void> {\n return (await this._button()).focus();\n }\n\n /** Blurs the toggle. */\n async blur(): Promise<void> {\n return (await this._button()).blur();\n }\n\n /** Whether the toggle is focused. */\n async isFocused(): Promise<boolean> {\n return (await this._button()).isFocused();\n }\n\n /** Toggle the checked state of the buttons toggle. */\n async toggle(): Promise<void> {\n return (await this._button()).click();\n }\n\n /**\n * Puts the button toggle in a checked state by toggling it if it's\n * currently unchecked, or doing nothing if it is already checked.\n */\n async check(): Promise<void> {\n if (!(await this.isChecked())) {\n await this.toggle();\n }\n }\n\n /**\n * Puts the button toggle in an unchecked state by toggling it if it's\n * currently checked, or doing nothing if it's already unchecked.\n */\n async uncheck(): Promise<void> {\n if (await this.isChecked()) {\n await this.toggle();\n }\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {BaseHarnessFilters} from '@angular/cdk/testing';\n\n/** Criteria that can be used to filter a list of `MatButtonToggleHarness` instances. */\nexport interface ButtonToggleHarnessFilters extends BaseHarnessFilters {\n /** Only find instances whose text matches the given value. */\n text?: string | RegExp;\n /** Only find instances whose name matches the given value. */\n name?: string | RegExp;\n /** Only find instances that are checked. */\n checked?: boolean;\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {ComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {MatButtonToggleAppearance} from '@angular/material/button-toggle';\nimport {ButtonToggleGroupHarnessFilters} from './button-toggle-group-harness-filters';\nimport {ButtonToggleHarnessFilters} from './button-toggle-harness-filters';\nimport {MatButtonToggleHarness} from './button-toggle-harness';\n\n/** Harness for interacting with a standard mat-button-toggle in tests. */\nexport class MatButtonToggleGroupHarness extends ComponentHarness {\n /** The selector for the host element of a `MatButton` instance. */\n static hostSelector = '.mat-button-toggle-group';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatButtonToggleGroupHarness`\n * that meets certain criteria.\n * @param options Options for filtering which button toggle instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(\n options: ButtonToggleGroupHarnessFilters = {},\n ): HarnessPredicate<MatButtonToggleGroupHarness> {\n return new HarnessPredicate(MatButtonToggleGroupHarness, options);\n }\n\n /**\n * Gets the button toggles that are inside the group.\n * @param filter Optionally filters which toggles are included.\n */\n async getToggles(filter: ButtonToggleHarnessFilters = {}): Promise<MatButtonToggleHarness[]> {\n return this.locatorForAll(MatButtonToggleHarness.with(filter))();\n }\n\n /** Gets whether the button toggle group is disabled. */\n async isDisabled(): Promise<boolean> {\n return (await (await this.host()).getAttribute('aria-disabled')) === 'true';\n }\n\n /** Gets whether the button toggle group is laid out vertically. */\n async isVertical(): Promise<boolean> {\n return (await this.host()).hasClass('mat-button-toggle-vertical');\n }\n\n /** Gets the appearance that the group is using. */\n async getAppearance(): Promise<MatButtonToggleAppearance> {\n const host = await this.host();\n const className = 'mat-button-toggle-group-appearance-standard';\n return (await host.hasClass(className)) ? 'standard' : 'legacy';\n }\n}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nimport {BaseHarnessFilters} from '@angular/cdk/testing';\n\n/** Criteria that can be used to filter a list of `MatButtonToggleGroupHarness` instances. */\nexport interface ButtonToggleGroupHarnessFilters extends BaseHarnessFilters {}\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './button-toggle-harness';\nexport * from './button-toggle-harness-filters';\nexport * from './button-toggle-group-harness';\nexport * from './button-toggle-group-harness-filters';\n","/**\n * @license\n * Copyright Google LLC All Rights Reserved.\n *\n * Use of this source code is governed by an MIT-style license that can be\n * found in the LICENSE file at https://angular.io/license\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;AAAA;;;;;;;AAaA;MACa,sBAAuB,SAAQ,gBAAgB;IAA5D;;QAIU,WAAM,GAAG,IAAI,CAAC,UAAU,CAAC,kCAAkC,CAAC,CAAC;QAC7D,YAAO,GAAG,IAAI,CAAC,UAAU,CAAC,2BAA2B,CAAC,CAAC;KAqGhE;;;;;;;IA7FC,OAAO,IAAI,CAAC,UAAsC,EAAE;QAClD,OAAO,IAAI,gBAAgB,CAAC,sBAAsB,EAAE,OAAO,CAAC;aACzD,SAAS,CAAC,MAAM,EAAE,OAAO,CAAC,IAAI,EAAE,CAAC,OAAO,EAAE,IAAI,K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