@angular/material 13.0.0-rc.0 → 13.0.0-rc.1

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 (642) hide show
  1. package/autocomplete/testing/autocomplete-harness.d.ts +4 -4
  2. package/core/common-behaviors/index.d.ts +1 -1
  3. package/esm2020/autocomplete/autocomplete-module.mjs +4 -17
  4. package/esm2020/autocomplete/autocomplete-origin.mjs +1 -1
  5. package/esm2020/autocomplete/autocomplete-trigger.mjs +30 -25
  6. package/esm2020/autocomplete/autocomplete.mjs +10 -10
  7. package/esm2020/autocomplete/testing/autocomplete-harness.mjs +7 -8
  8. package/esm2020/badge/badge-module.mjs +4 -11
  9. package/esm2020/badge/badge.mjs +13 -5
  10. package/esm2020/badge/testing/badge-harness.mjs +2 -3
  11. package/esm2020/bottom-sheet/bottom-sheet-animations.mjs +2 -2
  12. package/esm2020/bottom-sheet/bottom-sheet-container.mjs +5 -3
  13. package/esm2020/bottom-sheet/bottom-sheet-module.mjs +4 -14
  14. package/esm2020/bottom-sheet/bottom-sheet-ref.mjs +10 -4
  15. package/esm2020/bottom-sheet/bottom-sheet.mjs +9 -8
  16. package/esm2020/bottom-sheet/testing/bottom-sheet-harness.mjs +1 -1
  17. package/esm2020/button/button-module.mjs +6 -23
  18. package/esm2020/button/button.mjs +1 -1
  19. package/esm2020/button/public-api.mjs +1 -1
  20. package/esm2020/button/testing/button-harness.mjs +2 -3
  21. package/esm2020/button-toggle/button-toggle-module.mjs +1 -1
  22. package/esm2020/button-toggle/button-toggle.mjs +25 -13
  23. package/esm2020/button-toggle/public-api.mjs +1 -1
  24. package/esm2020/button-toggle/testing/button-toggle-group-harness-filters.mjs +1 -1
  25. package/esm2020/button-toggle/testing/button-toggle-group-harness.mjs +3 -3
  26. package/esm2020/button-toggle/testing/button-toggle-harness.mjs +2 -2
  27. package/esm2020/card/card-module.mjs +29 -7
  28. package/esm2020/card/card.mjs +14 -14
  29. package/esm2020/card/public-api.mjs +1 -1
  30. package/esm2020/card/testing/card-harness.mjs +1 -1
  31. package/esm2020/checkbox/checkbox-config.mjs +2 -2
  32. package/esm2020/checkbox/checkbox-module.mjs +3 -9
  33. package/esm2020/checkbox/checkbox-required-validator.mjs +4 -4
  34. package/esm2020/checkbox/checkbox.mjs +32 -14
  35. package/esm2020/checkbox/public-api.mjs +1 -1
  36. package/esm2020/checkbox/testing/checkbox-harness.mjs +3 -3
  37. package/esm2020/chips/chip-default-options.mjs +1 -1
  38. package/esm2020/chips/chip-input.mjs +18 -8
  39. package/esm2020/chips/chip-list.mjs +29 -14
  40. package/esm2020/chips/chip-text-control.mjs +1 -1
  41. package/esm2020/chips/chip.mjs +28 -19
  42. package/esm2020/chips/chips-module.mjs +8 -8
  43. package/esm2020/chips/testing/chip-harness.mjs +2 -2
  44. package/esm2020/chips/testing/chip-input-harness.mjs +2 -2
  45. package/esm2020/chips/testing/chip-list-harness.mjs +5 -5
  46. package/esm2020/chips/testing/chip-listbox-harness.mjs +1 -1
  47. package/esm2020/chips/testing/chip-option-harness.mjs +1 -1
  48. package/esm2020/core/animation/animation.mjs +1 -1
  49. package/esm2020/core/common-behaviors/color.mjs +4 -2
  50. package/esm2020/core/common-behaviors/common-module.mjs +10 -5
  51. package/esm2020/core/common-behaviors/constructor.mjs +1 -1
  52. package/esm2020/core/common-behaviors/disable-ripple.mjs +7 -3
  53. package/esm2020/core/common-behaviors/disabled.mjs +7 -3
  54. package/esm2020/core/common-behaviors/error-state.mjs +1 -1
  55. package/esm2020/core/common-behaviors/index.mjs +1 -1
  56. package/esm2020/core/common-behaviors/initialized.mjs +1 -1
  57. package/esm2020/core/common-behaviors/tabindex.mjs +4 -2
  58. package/esm2020/core/datetime/date-adapter.mjs +4 -4
  59. package/esm2020/core/datetime/date-formats.mjs +1 -1
  60. package/esm2020/core/datetime/index.mjs +3 -7
  61. package/esm2020/core/datetime/native-date-adapter.mjs +3 -3
  62. package/esm2020/core/datetime/native-date-formats.mjs +2 -2
  63. package/esm2020/core/line/line.mjs +3 -3
  64. package/esm2020/core/option/index.mjs +2 -2
  65. package/esm2020/core/option/optgroup.mjs +2 -2
  66. package/esm2020/core/option/option-parent.mjs +1 -1
  67. package/esm2020/core/option/option.mjs +16 -6
  68. package/esm2020/core/ripple/ripple-ref.mjs +1 -1
  69. package/esm2020/core/ripple/ripple-renderer.mjs +8 -8
  70. package/esm2020/core/ripple/ripple.mjs +10 -6
  71. package/esm2020/core/selection/index.mjs +2 -2
  72. package/esm2020/core/selection/pseudo-checkbox/pseudo-checkbox.mjs +1 -1
  73. package/esm2020/core/testing/optgroup-harness.mjs +2 -3
  74. package/esm2020/core/testing/option-harness.mjs +2 -2
  75. package/esm2020/core/version.mjs +1 -1
  76. package/esm2020/datepicker/calendar-body.mjs +8 -4
  77. package/esm2020/datepicker/calendar.mjs +40 -26
  78. package/esm2020/datepicker/date-range-input-parts.mjs +22 -19
  79. package/esm2020/datepicker/date-range-input.mjs +23 -12
  80. package/esm2020/datepicker/date-range-picker.mjs +2 -2
  81. package/esm2020/datepicker/date-range-selection-strategy.mjs +1 -1
  82. package/esm2020/datepicker/date-selection-model.mjs +6 -5
  83. package/esm2020/datepicker/datepicker-actions.mjs +4 -4
  84. package/esm2020/datepicker/datepicker-animations.mjs +6 -6
  85. package/esm2020/datepicker/datepicker-base.mjs +37 -34
  86. package/esm2020/datepicker/datepicker-errors.mjs +1 -1
  87. package/esm2020/datepicker/datepicker-input-base.mjs +20 -15
  88. package/esm2020/datepicker/datepicker-input.mjs +15 -9
  89. package/esm2020/datepicker/datepicker-intl.mjs +1 -1
  90. package/esm2020/datepicker/datepicker-module.mjs +6 -15
  91. package/esm2020/datepicker/datepicker-toggle.mjs +9 -8
  92. package/esm2020/datepicker/datepicker.mjs +2 -2
  93. package/esm2020/datepicker/month-view.mjs +37 -23
  94. package/esm2020/datepicker/multi-year-view.mjs +26 -16
  95. package/esm2020/datepicker/testing/calendar-cell-harness.mjs +1 -1
  96. package/esm2020/datepicker/testing/calendar-harness.mjs +1 -1
  97. package/esm2020/datepicker/testing/date-range-input-harness.mjs +4 -5
  98. package/esm2020/datepicker/testing/datepicker-input-harness-base.mjs +4 -4
  99. package/esm2020/datepicker/testing/datepicker-input-harness.mjs +1 -1
  100. package/esm2020/datepicker/testing/datepicker-toggle-harness.mjs +1 -1
  101. package/esm2020/datepicker/testing/datepicker-trigger-harness-base.mjs +2 -2
  102. package/esm2020/datepicker/year-view.mjs +29 -16
  103. package/esm2020/dialog/dialog-animations.mjs +2 -2
  104. package/esm2020/dialog/dialog-config.mjs +1 -1
  105. package/esm2020/dialog/dialog-container.mjs +8 -5
  106. package/esm2020/dialog/dialog-content-directives.mjs +4 -4
  107. package/esm2020/dialog/dialog-module.mjs +5 -21
  108. package/esm2020/dialog/dialog-ref.mjs +10 -5
  109. package/esm2020/dialog/dialog.mjs +19 -16
  110. package/esm2020/dialog/testing/dialog-harness.mjs +3 -3
  111. package/esm2020/divider/divider-module.mjs +1 -1
  112. package/esm2020/divider/divider.mjs +14 -6
  113. package/esm2020/divider/testing/divider-harness-filters.mjs +1 -1
  114. package/esm2020/divider/testing/divider-harness.mjs +1 -1
  115. package/esm2020/expansion/accordion-base.mjs +1 -1
  116. package/esm2020/expansion/accordion.mjs +19 -11
  117. package/esm2020/expansion/expansion-animations.mjs +2 -2
  118. package/esm2020/expansion/expansion-module.mjs +1 -1
  119. package/esm2020/expansion/expansion-panel-content.mjs +2 -2
  120. package/esm2020/expansion/expansion-panel-header.mjs +13 -21
  121. package/esm2020/expansion/expansion-panel.mjs +10 -6
  122. package/esm2020/expansion/testing/accordion-harness.mjs +1 -1
  123. package/esm2020/expansion/testing/expansion-harness-filters.mjs +1 -1
  124. package/esm2020/expansion/testing/expansion-harness.mjs +3 -3
  125. package/esm2020/form-field/form-field-animations.mjs +2 -2
  126. package/esm2020/form-field/form-field-control.mjs +1 -1
  127. package/esm2020/form-field/form-field-module.mjs +5 -29
  128. package/esm2020/form-field/form-field.mjs +45 -33
  129. package/esm2020/form-field/label.mjs +2 -2
  130. package/esm2020/form-field/placeholder.mjs +2 -2
  131. package/esm2020/form-field/testing/form-field-harness.mjs +12 -9
  132. package/esm2020/grid-list/grid-list-module.mjs +4 -4
  133. package/esm2020/grid-list/grid-list.mjs +24 -13
  134. package/esm2020/grid-list/grid-tile.mjs +17 -9
  135. package/esm2020/grid-list/testing/grid-list-harness-filters.mjs +1 -1
  136. package/esm2020/grid-list/testing/grid-list-harness.mjs +9 -5
  137. package/esm2020/grid-list/testing/grid-tile-harness.mjs +1 -1
  138. package/esm2020/grid-list/tile-coordinator.mjs +5 -3
  139. package/esm2020/grid-list/tile-styler.mjs +7 -6
  140. package/esm2020/icon/fake-svgs.mjs +2 -2
  141. package/esm2020/icon/icon-module.mjs +1 -1
  142. package/esm2020/icon/icon-registry.mjs +6 -6
  143. package/esm2020/icon/icon.mjs +26 -16
  144. package/esm2020/icon/public-api.mjs +1 -1
  145. package/esm2020/icon/testing/fake-icon-registry.mjs +2 -2
  146. package/esm2020/icon/testing/icon-harness-filters.mjs +1 -1
  147. package/esm2020/icon/testing/icon-harness.mjs +2 -2
  148. package/esm2020/icon/trusted-types.mjs +1 -1
  149. package/esm2020/input/input-module.mjs +4 -14
  150. package/esm2020/input/input-value-accessor.mjs +1 -1
  151. package/esm2020/input/input.mjs +46 -20
  152. package/esm2020/input/public-api.mjs +1 -1
  153. package/esm2020/input/testing/input-harness.mjs +6 -6
  154. package/esm2020/input/testing/native-option-harness.mjs +3 -3
  155. package/esm2020/input/testing/native-select-harness.mjs +4 -4
  156. package/esm2020/list/list-module.mjs +3 -3
  157. package/esm2020/list/list.mjs +10 -9
  158. package/esm2020/list/public-api.mjs +1 -1
  159. package/esm2020/list/selection-list.mjs +34 -15
  160. package/esm2020/list/testing/action-list-harness.mjs +1 -1
  161. package/esm2020/list/testing/list-harness-base.mjs +12 -5
  162. package/esm2020/list/testing/list-harness.mjs +1 -1
  163. package/esm2020/list/testing/list-item-harness-base.mjs +5 -7
  164. package/esm2020/list/testing/nav-list-harness.mjs +2 -3
  165. package/esm2020/list/testing/selection-list-harness.mjs +9 -9
  166. package/esm2020/menu/menu-animations.mjs +7 -7
  167. package/esm2020/menu/menu-content.mjs +1 -1
  168. package/esm2020/menu/menu-errors.mjs +1 -1
  169. package/esm2020/menu/menu-item.mjs +1 -1
  170. package/esm2020/menu/menu-module.mjs +6 -19
  171. package/esm2020/menu/menu-panel.mjs +1 -1
  172. package/esm2020/menu/menu-trigger.mjs +25 -16
  173. package/esm2020/menu/menu.mjs +28 -25
  174. package/esm2020/menu/public-api.mjs +2 -2
  175. package/esm2020/menu/testing/menu-harness.mjs +4 -5
  176. package/esm2020/paginator/paginator-intl.mjs +3 -5
  177. package/esm2020/paginator/paginator-module.mjs +4 -20
  178. package/esm2020/paginator/paginator.mjs +24 -13
  179. package/esm2020/paginator/public-api.mjs +1 -1
  180. package/esm2020/paginator/testing/paginator-harness-filters.mjs +1 -1
  181. package/esm2020/paginator/testing/paginator-harness.mjs +2 -2
  182. package/esm2020/progress-bar/progress-bar-module.mjs +1 -1
  183. package/esm2020/progress-bar/progress-bar.mjs +20 -15
  184. package/esm2020/progress-bar/public-api.mjs +1 -1
  185. package/esm2020/progress-bar/testing/progress-bar-harness.mjs +1 -1
  186. package/esm2020/progress-spinner/progress-spinner-module.mjs +4 -14
  187. package/esm2020/progress-spinner/progress-spinner.mjs +10 -8
  188. package/esm2020/progress-spinner/testing/progress-spinner-harness.mjs +2 -2
  189. package/esm2020/radio/public-api.mjs +1 -1
  190. package/esm2020/radio/radio-module.mjs +1 -1
  191. package/esm2020/radio/radio.mjs +40 -24
  192. package/esm2020/radio/testing/radio-harness.mjs +3 -4
  193. package/esm2020/select/public-api.mjs +2 -2
  194. package/esm2020/select/select-animations.mjs +7 -7
  195. package/esm2020/select/select-module.mjs +6 -19
  196. package/esm2020/select/select.mjs +61 -44
  197. package/esm2020/select/testing/select-harness.mjs +9 -6
  198. package/esm2020/sidenav/drawer-animations.mjs +3 -3
  199. package/esm2020/sidenav/drawer.mjs +71 -35
  200. package/esm2020/sidenav/sidenav-module.mjs +4 -17
  201. package/esm2020/sidenav/sidenav.mjs +31 -15
  202. package/esm2020/sidenav/testing/drawer-container-harness.mjs +1 -1
  203. package/esm2020/sidenav/testing/drawer-content-harness.mjs +1 -1
  204. package/esm2020/sidenav/testing/drawer-harness.mjs +2 -3
  205. package/esm2020/sidenav/testing/sidenav-container-harness.mjs +1 -1
  206. package/esm2020/sidenav/testing/sidenav-content-harness.mjs +1 -1
  207. package/esm2020/sidenav/testing/sidenav-harness.mjs +2 -3
  208. package/esm2020/slide-toggle/slide-toggle-config.mjs +2 -2
  209. package/esm2020/slide-toggle/slide-toggle-module.mjs +3 -8
  210. package/esm2020/slide-toggle/slide-toggle-required-validator.mjs +4 -4
  211. package/esm2020/slide-toggle/slide-toggle.mjs +16 -10
  212. package/esm2020/slide-toggle/testing/slide-toggle-harness.mjs +3 -3
  213. package/esm2020/slider/public-api.mjs +1 -1
  214. package/esm2020/slider/slider-module.mjs +1 -1
  215. package/esm2020/slider/slider.mjs +49 -30
  216. package/esm2020/slider/testing/slider-harness.mjs +6 -2
  217. package/esm2020/snack-bar/simple-snack-bar.mjs +1 -1
  218. package/esm2020/snack-bar/snack-bar-animations.mjs +3 -3
  219. package/esm2020/snack-bar/snack-bar-container.mjs +2 -2
  220. package/esm2020/snack-bar/snack-bar-module.mjs +4 -20
  221. package/esm2020/snack-bar/snack-bar-ref.mjs +1 -1
  222. package/esm2020/snack-bar/snack-bar.mjs +11 -8
  223. package/esm2020/snack-bar/testing/snack-bar-harness.mjs +5 -6
  224. package/esm2020/sort/sort-animations.mjs +11 -26
  225. package/esm2020/sort/sort-header-intl.mjs +2 -2
  226. package/esm2020/sort/sort-header.mjs +29 -26
  227. package/esm2020/sort/sort-module.mjs +2 -2
  228. package/esm2020/sort/sort.mjs +16 -9
  229. package/esm2020/sort/testing/sort-harness-filters.mjs +1 -1
  230. package/esm2020/sort/testing/sort-harness.mjs +1 -1
  231. package/esm2020/sort/testing/sort-header-harness.mjs +1 -1
  232. package/esm2020/stepper/step-content.mjs +2 -2
  233. package/esm2020/stepper/step-header.mjs +2 -2
  234. package/esm2020/stepper/stepper-animations.mjs +4 -4
  235. package/esm2020/stepper/stepper-button.mjs +3 -3
  236. package/esm2020/stepper/stepper-intl.mjs +2 -2
  237. package/esm2020/stepper/stepper-module.mjs +1 -1
  238. package/esm2020/stepper/stepper.mjs +10 -6
  239. package/esm2020/stepper/testing/step-harness-filters.mjs +1 -1
  240. package/esm2020/stepper/testing/step-harness.mjs +1 -1
  241. package/esm2020/stepper/testing/stepper-button-harnesses.mjs +3 -5
  242. package/esm2020/stepper/testing/stepper-harness.mjs +5 -5
  243. package/esm2020/table/cell.mjs +12 -8
  244. package/esm2020/table/row.mjs +2 -2
  245. package/esm2020/table/table-data-source.mjs +30 -21
  246. package/esm2020/table/table-module.mjs +5 -12
  247. package/esm2020/table/table.mjs +5 -9
  248. package/esm2020/table/testing/cell-harness.mjs +6 -3
  249. package/esm2020/table/testing/row-harness.mjs +2 -2
  250. package/esm2020/table/testing/table-harness-filters.mjs +1 -1
  251. package/esm2020/table/testing/table-harness.mjs +3 -3
  252. package/esm2020/table/text-column.mjs +1 -1
  253. package/esm2020/tabs/ink-bar.mjs +2 -2
  254. package/esm2020/tabs/paginated-tab-header.mjs +16 -9
  255. package/esm2020/tabs/public-api.mjs +2 -2
  256. package/esm2020/tabs/tab-body.mjs +7 -7
  257. package/esm2020/tabs/tab-content.mjs +2 -3
  258. package/esm2020/tabs/tab-group.mjs +43 -28
  259. package/esm2020/tabs/tab-header.mjs +7 -3
  260. package/esm2020/tabs/tab-label-wrapper.mjs +2 -2
  261. package/esm2020/tabs/tab-label.mjs +1 -1
  262. package/esm2020/tabs/tab-nav-bar/tab-nav-bar.mjs +19 -9
  263. package/esm2020/tabs/tab.mjs +7 -3
  264. package/esm2020/tabs/tabs-animations.mjs +5 -5
  265. package/esm2020/tabs/tabs-module.mjs +1 -1
  266. package/esm2020/tabs/testing/tab-group-harness.mjs +2 -3
  267. package/esm2020/tabs/testing/tab-harness.mjs +2 -3
  268. package/esm2020/tabs/testing/tab-link-harness.mjs +2 -3
  269. package/esm2020/toolbar/public-api.mjs +1 -1
  270. package/esm2020/toolbar/testing/toolbar-harness.mjs +3 -4
  271. package/esm2020/toolbar/toolbar-module.mjs +1 -1
  272. package/esm2020/toolbar/toolbar.mjs +1 -1
  273. package/esm2020/tooltip/tooltip-animations.mjs +3 -3
  274. package/esm2020/tooltip/tooltip-module.mjs +5 -18
  275. package/esm2020/tooltip/tooltip.mjs +55 -30
  276. package/esm2020/tree/data-source/flat-data-source.mjs +4 -2
  277. package/esm2020/tree/data-source/nested-data-source.mjs +8 -5
  278. package/esm2020/tree/node.mjs +17 -13
  279. package/esm2020/tree/outlet.mjs +12 -8
  280. package/esm2020/tree/padding.mjs +14 -6
  281. package/esm2020/tree/public-api.mjs +1 -1
  282. package/esm2020/tree/testing/node-harness.mjs +1 -1
  283. package/esm2020/tree/testing/tree-harness-filters.mjs +1 -1
  284. package/esm2020/tree/testing/tree-harness.mjs +2 -2
  285. package/esm2020/tree/toggle.mjs +5 -3
  286. package/esm2020/tree/tree-module.mjs +2 -2
  287. package/esm2020/tree/tree.mjs +1 -1
  288. package/fesm2015/autocomplete/testing.mjs +2 -3
  289. package/fesm2015/autocomplete/testing.mjs.map +1 -1
  290. package/fesm2015/autocomplete.mjs +40 -48
  291. package/fesm2015/autocomplete.mjs.map +1 -1
  292. package/fesm2015/badge/testing.mjs +1 -2
  293. package/fesm2015/badge/testing.mjs.map +1 -1
  294. package/fesm2015/badge.mjs +15 -14
  295. package/fesm2015/badge.mjs.map +1 -1
  296. package/fesm2015/bottom-sheet/testing.mjs.map +1 -1
  297. package/fesm2015/bottom-sheet.mjs +25 -26
  298. package/fesm2015/bottom-sheet.mjs.map +1 -1
  299. package/fesm2015/button/testing.mjs +1 -2
  300. package/fesm2015/button/testing.mjs.map +1 -1
  301. package/fesm2015/button-toggle/testing.mjs.map +1 -1
  302. package/fesm2015/button-toggle.mjs +23 -11
  303. package/fesm2015/button-toggle.mjs.map +1 -1
  304. package/fesm2015/button.mjs +5 -22
  305. package/fesm2015/button.mjs.map +1 -1
  306. package/fesm2015/card/testing.mjs.map +1 -1
  307. package/fesm2015/card.mjs +41 -19
  308. package/fesm2015/card.mjs.map +1 -1
  309. package/fesm2015/checkbox/testing.mjs +2 -2
  310. package/fesm2015/checkbox/testing.mjs.map +1 -1
  311. package/fesm2015/checkbox.mjs +35 -23
  312. package/fesm2015/checkbox.mjs.map +1 -1
  313. package/fesm2015/chips/testing.mjs +2 -2
  314. package/fesm2015/chips/testing.mjs.map +1 -1
  315. package/fesm2015/chips.mjs +77 -43
  316. package/fesm2015/chips.mjs.map +1 -1
  317. package/fesm2015/core/testing.mjs +1 -2
  318. package/fesm2015/core/testing.mjs.map +1 -1
  319. package/fesm2015/core.mjs +69 -42
  320. package/fesm2015/core.mjs.map +1 -1
  321. package/fesm2015/datepicker/testing.mjs +5 -6
  322. package/fesm2015/datepicker/testing.mjs.map +1 -1
  323. package/fesm2015/datepicker.mjs +267 -191
  324. package/fesm2015/datepicker.mjs.map +1 -1
  325. package/fesm2015/dialog/testing.mjs +2 -2
  326. package/fesm2015/dialog/testing.mjs.map +1 -1
  327. package/fesm2015/dialog.mjs +40 -45
  328. package/fesm2015/dialog.mjs.map +1 -1
  329. package/fesm2015/divider/testing.mjs.map +1 -1
  330. package/fesm2015/divider.mjs +13 -5
  331. package/fesm2015/divider.mjs.map +1 -1
  332. package/fesm2015/expansion/testing.mjs.map +1 -1
  333. package/fesm2015/expansion.mjs +40 -36
  334. package/fesm2015/expansion.mjs.map +1 -1
  335. package/fesm2015/form-field/testing.mjs +5 -2
  336. package/fesm2015/form-field/testing.mjs.map +1 -1
  337. package/fesm2015/form-field.mjs +50 -62
  338. package/fesm2015/form-field.mjs.map +1 -1
  339. package/fesm2015/grid-list/testing.mjs +8 -4
  340. package/fesm2015/grid-list/testing.mjs.map +1 -1
  341. package/fesm2015/grid-list.mjs +51 -29
  342. package/fesm2015/grid-list.mjs.map +1 -1
  343. package/fesm2015/icon/testing.mjs +1 -1
  344. package/fesm2015/icon/testing.mjs.map +1 -1
  345. package/fesm2015/icon.mjs +30 -20
  346. package/fesm2015/icon.mjs.map +1 -1
  347. package/fesm2015/input/testing.mjs +8 -8
  348. package/fesm2015/input/testing.mjs.map +1 -1
  349. package/fesm2015/input.mjs +47 -31
  350. package/fesm2015/input.mjs.map +1 -1
  351. package/fesm2015/list/testing.mjs +17 -13
  352. package/fesm2015/list/testing.mjs.map +1 -1
  353. package/fesm2015/list.mjs +41 -22
  354. package/fesm2015/list.mjs.map +1 -1
  355. package/fesm2015/menu/testing.mjs +1 -2
  356. package/fesm2015/menu/testing.mjs.map +1 -1
  357. package/fesm2015/menu.mjs +62 -63
  358. package/fesm2015/menu.mjs.map +1 -1
  359. package/fesm2015/paginator/testing.mjs +1 -1
  360. package/fesm2015/paginator/testing.mjs.map +1 -1
  361. package/fesm2015/paginator.mjs +27 -34
  362. package/fesm2015/paginator.mjs.map +1 -1
  363. package/fesm2015/progress-bar/testing.mjs.map +1 -1
  364. package/fesm2015/progress-bar.mjs +19 -14
  365. package/fesm2015/progress-bar.mjs.map +1 -1
  366. package/fesm2015/progress-spinner/testing.mjs +1 -1
  367. package/fesm2015/progress-spinner/testing.mjs.map +1 -1
  368. package/fesm2015/progress-spinner.mjs +12 -20
  369. package/fesm2015/progress-spinner.mjs.map +1 -1
  370. package/fesm2015/radio/testing.mjs +1 -2
  371. package/fesm2015/radio/testing.mjs.map +1 -1
  372. package/fesm2015/radio.mjs +39 -23
  373. package/fesm2015/radio.mjs.map +1 -1
  374. package/fesm2015/select/testing.mjs +4 -1
  375. package/fesm2015/select/testing.mjs.map +1 -1
  376. package/fesm2015/select.mjs +70 -66
  377. package/fesm2015/select.mjs.map +1 -1
  378. package/fesm2015/sidenav/testing.mjs +2 -4
  379. package/fesm2015/sidenav/testing.mjs.map +1 -1
  380. package/fesm2015/sidenav.mjs +103 -64
  381. package/fesm2015/sidenav.mjs.map +1 -1
  382. package/fesm2015/slide-toggle/testing.mjs +2 -2
  383. package/fesm2015/slide-toggle/testing.mjs.map +1 -1
  384. package/fesm2015/slide-toggle.mjs +18 -17
  385. package/fesm2015/slide-toggle.mjs.map +1 -1
  386. package/fesm2015/slider/testing.mjs +5 -1
  387. package/fesm2015/slider/testing.mjs.map +1 -1
  388. package/fesm2015/slider.mjs +47 -28
  389. package/fesm2015/slider.mjs.map +1 -1
  390. package/fesm2015/snack-bar/testing.mjs +1 -2
  391. package/fesm2015/snack-bar/testing.mjs.map +1 -1
  392. package/fesm2015/snack-bar.mjs +16 -29
  393. package/fesm2015/snack-bar.mjs.map +1 -1
  394. package/fesm2015/sort/testing.mjs.map +1 -1
  395. package/fesm2015/sort.mjs +53 -57
  396. package/fesm2015/sort.mjs.map +1 -1
  397. package/fesm2015/stepper/testing.mjs +6 -8
  398. package/fesm2015/stepper/testing.mjs.map +1 -1
  399. package/fesm2015/stepper.mjs +17 -13
  400. package/fesm2015/stepper.mjs.map +1 -1
  401. package/fesm2015/table/testing.mjs +7 -4
  402. package/fesm2015/table/testing.mjs.map +1 -1
  403. package/fesm2015/table.mjs +45 -43
  404. package/fesm2015/table.mjs.map +1 -1
  405. package/fesm2015/tabs/testing.mjs +3 -6
  406. package/fesm2015/tabs/testing.mjs.map +1 -1
  407. package/fesm2015/tabs.mjs +99 -60
  408. package/fesm2015/tabs.mjs.map +1 -1
  409. package/fesm2015/toolbar/testing.mjs +2 -3
  410. package/fesm2015/toolbar/testing.mjs.map +1 -1
  411. package/fesm2015/toolbar.mjs.map +1 -1
  412. package/fesm2015/tooltip.mjs +60 -48
  413. package/fesm2015/tooltip.mjs.map +1 -1
  414. package/fesm2015/tree/testing.mjs +1 -1
  415. package/fesm2015/tree/testing.mjs.map +1 -1
  416. package/fesm2015/tree.mjs +53 -30
  417. package/fesm2015/tree.mjs.map +1 -1
  418. package/fesm2020/autocomplete/testing.mjs +5 -6
  419. package/fesm2020/autocomplete/testing.mjs.map +1 -1
  420. package/fesm2020/autocomplete.mjs +40 -48
  421. package/fesm2020/autocomplete.mjs.map +1 -1
  422. package/fesm2020/badge/testing.mjs +1 -2
  423. package/fesm2020/badge/testing.mjs.map +1 -1
  424. package/fesm2020/badge.mjs +15 -14
  425. package/fesm2020/badge.mjs.map +1 -1
  426. package/fesm2020/bottom-sheet/testing.mjs.map +1 -1
  427. package/fesm2020/bottom-sheet.mjs +25 -26
  428. package/fesm2020/bottom-sheet.mjs.map +1 -1
  429. package/fesm2020/button/testing.mjs +1 -2
  430. package/fesm2020/button/testing.mjs.map +1 -1
  431. package/fesm2020/button-toggle/testing.mjs +3 -3
  432. package/fesm2020/button-toggle/testing.mjs.map +1 -1
  433. package/fesm2020/button-toggle.mjs +23 -11
  434. package/fesm2020/button-toggle.mjs.map +1 -1
  435. package/fesm2020/button.mjs +5 -22
  436. package/fesm2020/button.mjs.map +1 -1
  437. package/fesm2020/card/testing.mjs.map +1 -1
  438. package/fesm2020/card.mjs +41 -19
  439. package/fesm2020/card.mjs.map +1 -1
  440. package/fesm2020/checkbox/testing.mjs +2 -2
  441. package/fesm2020/checkbox/testing.mjs.map +1 -1
  442. package/fesm2020/checkbox.mjs +35 -23
  443. package/fesm2020/checkbox.mjs.map +1 -1
  444. package/fesm2020/chips/testing.mjs +6 -6
  445. package/fesm2020/chips/testing.mjs.map +1 -1
  446. package/fesm2020/chips.mjs +77 -43
  447. package/fesm2020/chips.mjs.map +1 -1
  448. package/fesm2020/core/testing.mjs +2 -3
  449. package/fesm2020/core/testing.mjs.map +1 -1
  450. package/fesm2020/core.mjs +70 -43
  451. package/fesm2020/core.mjs.map +1 -1
  452. package/fesm2020/datepicker/testing.mjs +6 -7
  453. package/fesm2020/datepicker/testing.mjs.map +1 -1
  454. package/fesm2020/datepicker.mjs +267 -191
  455. package/fesm2020/datepicker.mjs.map +1 -1
  456. package/fesm2020/dialog/testing.mjs +2 -2
  457. package/fesm2020/dialog/testing.mjs.map +1 -1
  458. package/fesm2020/dialog.mjs +40 -45
  459. package/fesm2020/dialog.mjs.map +1 -1
  460. package/fesm2020/divider/testing.mjs.map +1 -1
  461. package/fesm2020/divider.mjs +13 -5
  462. package/fesm2020/divider.mjs.map +1 -1
  463. package/fesm2020/expansion/testing.mjs +2 -2
  464. package/fesm2020/expansion/testing.mjs.map +1 -1
  465. package/fesm2020/expansion.mjs +40 -36
  466. package/fesm2020/expansion.mjs.map +1 -1
  467. package/fesm2020/form-field/testing.mjs +10 -7
  468. package/fesm2020/form-field/testing.mjs.map +1 -1
  469. package/fesm2020/form-field.mjs +50 -62
  470. package/fesm2020/form-field.mjs.map +1 -1
  471. package/fesm2020/grid-list/testing.mjs +8 -4
  472. package/fesm2020/grid-list/testing.mjs.map +1 -1
  473. package/fesm2020/grid-list.mjs +51 -29
  474. package/fesm2020/grid-list.mjs.map +1 -1
  475. package/fesm2020/icon/testing.mjs +2 -2
  476. package/fesm2020/icon/testing.mjs.map +1 -1
  477. package/fesm2020/icon.mjs +30 -20
  478. package/fesm2020/icon.mjs.map +1 -1
  479. package/fesm2020/input/testing.mjs +10 -10
  480. package/fesm2020/input/testing.mjs.map +1 -1
  481. package/fesm2020/input.mjs +47 -31
  482. package/fesm2020/input.mjs.map +1 -1
  483. package/fesm2020/list/testing.mjs +23 -19
  484. package/fesm2020/list/testing.mjs.map +1 -1
  485. package/fesm2020/list.mjs +43 -23
  486. package/fesm2020/list.mjs.map +1 -1
  487. package/fesm2020/menu/testing.mjs +3 -4
  488. package/fesm2020/menu/testing.mjs.map +1 -1
  489. package/fesm2020/menu.mjs +62 -63
  490. package/fesm2020/menu.mjs.map +1 -1
  491. package/fesm2020/paginator/testing.mjs +1 -1
  492. package/fesm2020/paginator/testing.mjs.map +1 -1
  493. package/fesm2020/paginator.mjs +27 -34
  494. package/fesm2020/paginator.mjs.map +1 -1
  495. package/fesm2020/progress-bar/testing.mjs.map +1 -1
  496. package/fesm2020/progress-bar.mjs +19 -14
  497. package/fesm2020/progress-bar.mjs.map +1 -1
  498. package/fesm2020/progress-spinner/testing.mjs +1 -1
  499. package/fesm2020/progress-spinner/testing.mjs.map +1 -1
  500. package/fesm2020/progress-spinner.mjs +12 -20
  501. package/fesm2020/progress-spinner.mjs.map +1 -1
  502. package/fesm2020/radio/testing.mjs +2 -3
  503. package/fesm2020/radio/testing.mjs.map +1 -1
  504. package/fesm2020/radio.mjs +39 -23
  505. package/fesm2020/radio.mjs.map +1 -1
  506. package/fesm2020/select/testing.mjs +8 -5
  507. package/fesm2020/select/testing.mjs.map +1 -1
  508. package/fesm2020/select.mjs +70 -66
  509. package/fesm2020/select.mjs.map +1 -1
  510. package/fesm2020/sidenav/testing.mjs +2 -4
  511. package/fesm2020/sidenav/testing.mjs.map +1 -1
  512. package/fesm2020/sidenav.mjs +103 -64
  513. package/fesm2020/sidenav.mjs.map +1 -1
  514. package/fesm2020/slide-toggle/testing.mjs +2 -2
  515. package/fesm2020/slide-toggle/testing.mjs.map +1 -1
  516. package/fesm2020/slide-toggle.mjs +18 -17
  517. package/fesm2020/slide-toggle.mjs.map +1 -1
  518. package/fesm2020/slider/testing.mjs +5 -1
  519. package/fesm2020/slider/testing.mjs.map +1 -1
  520. package/fesm2020/slider.mjs +47 -28
  521. package/fesm2020/slider.mjs.map +1 -1
  522. package/fesm2020/snack-bar/testing.mjs +4 -5
  523. package/fesm2020/snack-bar/testing.mjs.map +1 -1
  524. package/fesm2020/snack-bar.mjs +16 -29
  525. package/fesm2020/snack-bar.mjs.map +1 -1
  526. package/fesm2020/sort/testing.mjs.map +1 -1
  527. package/fesm2020/sort.mjs +54 -59
  528. package/fesm2020/sort.mjs.map +1 -1
  529. package/fesm2020/stepper/testing.mjs +6 -8
  530. package/fesm2020/stepper/testing.mjs.map +1 -1
  531. package/fesm2020/stepper.mjs +17 -13
  532. package/fesm2020/stepper.mjs.map +1 -1
  533. package/fesm2020/table/testing.mjs +7 -4
  534. package/fesm2020/table/testing.mjs.map +1 -1
  535. package/fesm2020/table.mjs +45 -43
  536. package/fesm2020/table.mjs.map +1 -1
  537. package/fesm2020/tabs/testing.mjs +3 -6
  538. package/fesm2020/tabs/testing.mjs.map +1 -1
  539. package/fesm2020/tabs.mjs +99 -60
  540. package/fesm2020/tabs.mjs.map +1 -1
  541. package/fesm2020/toolbar/testing.mjs +2 -3
  542. package/fesm2020/toolbar/testing.mjs.map +1 -1
  543. package/fesm2020/toolbar.mjs.map +1 -1
  544. package/fesm2020/tooltip.mjs +60 -48
  545. package/fesm2020/tooltip.mjs.map +1 -1
  546. package/fesm2020/tree/testing.mjs +1 -1
  547. package/fesm2020/tree/testing.mjs.map +1 -1
  548. package/fesm2020/tree.mjs +53 -30
  549. package/fesm2020/tree.mjs.map +1 -1
  550. package/grid-list/testing/grid-list-harness.d.ts +1 -1
  551. package/icon/icon-registry.d.ts +1 -1
  552. package/input/_input-theme.scss +8 -6
  553. package/input/input.d.ts +2 -0
  554. package/list/testing/list-harness-base.d.ts +2 -2
  555. package/menu/public-api.d.ts +1 -1
  556. package/menu/testing/menu-harness.d.ts +2 -2
  557. package/package.json +2 -2
  558. package/prebuilt-themes/deeppurple-amber.css +1 -1
  559. package/prebuilt-themes/indigo-pink.css +1 -1
  560. package/prebuilt-themes/pink-bluegrey.css +1 -1
  561. package/prebuilt-themes/purple-green.css +1 -1
  562. package/radio/testing/radio-harness.d.ts +2 -2
  563. package/schematics/ng-add/index.js +2 -2
  564. package/schematics/ng-add/index.mjs +2 -2
  565. package/schematics/ng-add/package-config.js +4 -2
  566. package/schematics/ng-add/package-config.mjs +4 -2
  567. package/schematics/ng-add/setup-project.js +2 -3
  568. package/schematics/ng-add/setup-project.mjs +2 -3
  569. package/schematics/ng-add/theming/create-custom-theme.js +1 -1
  570. package/schematics/ng-add/theming/create-custom-theme.mjs +1 -1
  571. package/schematics/ng-add/theming/theming.js +6 -6
  572. package/schematics/ng-add/theming/theming.mjs +6 -6
  573. package/schematics/ng-generate/address-form/index.js +2 -2
  574. package/schematics/ng-generate/address-form/index.mjs +2 -2
  575. package/schematics/ng-generate/dashboard/index.js +2 -2
  576. package/schematics/ng-generate/dashboard/index.mjs +2 -2
  577. package/schematics/ng-generate/navigation/index.js +2 -2
  578. package/schematics/ng-generate/navigation/index.mjs +2 -2
  579. package/schematics/ng-generate/table/index.js +3 -3
  580. package/schematics/ng-generate/table/index.mjs +3 -3
  581. package/schematics/ng-generate/tree/index.js +2 -2
  582. package/schematics/ng-generate/tree/index.mjs +2 -2
  583. package/schematics/ng-update/data/class-names.js +6 -8
  584. package/schematics/ng-update/data/class-names.mjs +6 -8
  585. package/schematics/ng-update/data/constructor-checks.js +33 -32
  586. package/schematics/ng-update/data/constructor-checks.mjs +33 -32
  587. package/schematics/ng-update/data/css-selectors.js +11 -9
  588. package/schematics/ng-update/data/css-selectors.mjs +11 -9
  589. package/schematics/ng-update/data/element-selectors.js +6 -4
  590. package/schematics/ng-update/data/element-selectors.mjs +6 -4
  591. package/schematics/ng-update/data/input-names.js +31 -23
  592. package/schematics/ng-update/data/input-names.mjs +31 -23
  593. package/schematics/ng-update/data/method-call-checks.js +10 -6
  594. package/schematics/ng-update/data/method-call-checks.mjs +10 -6
  595. package/schematics/ng-update/data/property-names.js +62 -50
  596. package/schematics/ng-update/data/property-names.mjs +62 -50
  597. package/schematics/ng-update/data/symbol-removal.js +6 -6
  598. package/schematics/ng-update/data/symbol-removal.mjs +6 -6
  599. package/schematics/ng-update/index.js +1 -1
  600. package/schematics/ng-update/index.mjs +1 -1
  601. package/schematics/ng-update/migrations/hammer-gestures-v9/find-main-module.js +5 -3
  602. package/schematics/ng-update/migrations/hammer-gestures-v9/find-main-module.mjs +5 -3
  603. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-gestures-migration.js +53 -27
  604. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-gestures-migration.mjs +53 -27
  605. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-template-check.js +38 -7
  606. package/schematics/ng-update/migrations/hammer-gestures-v9/hammer-template-check.mjs +38 -7
  607. package/schematics/ng-update/migrations/hammer-gestures-v9/import-manager.js +28 -14
  608. package/schematics/ng-update/migrations/hammer-gestures-v9/import-manager.mjs +28 -14
  609. package/schematics/ng-update/migrations/hammer-gestures-v9/remove-array-element.js +1 -1
  610. package/schematics/ng-update/migrations/hammer-gestures-v9/remove-array-element.mjs +1 -1
  611. package/schematics/ng-update/migrations/hammer-gestures-v9/remove-element-from-html.js +1 -1
  612. package/schematics/ng-update/migrations/hammer-gestures-v9/remove-element-from-html.mjs +1 -1
  613. package/schematics/ng-update/migrations/misc-checks/misc-class-inheritance.js +3 -2
  614. package/schematics/ng-update/migrations/misc-checks/misc-class-inheritance.mjs +3 -2
  615. package/schematics/ng-update/migrations/misc-checks/misc-class-names.js +1 -1
  616. package/schematics/ng-update/migrations/misc-checks/misc-class-names.mjs +1 -1
  617. package/schematics/ng-update/migrations/misc-checks/misc-imports.js +6 -3
  618. package/schematics/ng-update/migrations/misc-checks/misc-imports.mjs +6 -3
  619. package/schematics/ng-update/migrations/misc-checks/misc-property-names.js +1 -1
  620. package/schematics/ng-update/migrations/misc-checks/misc-property-names.mjs +1 -1
  621. package/schematics/ng-update/migrations/misc-checks/misc-template.js +7 -13
  622. package/schematics/ng-update/migrations/misc-checks/misc-template.mjs +7 -13
  623. package/schematics/ng-update/migrations/misc-ripples-v7/ripple-speed-factor-migration.js +1 -1
  624. package/schematics/ng-update/migrations/misc-ripples-v7/ripple-speed-factor-migration.mjs +1 -1
  625. package/schematics/ng-update/migrations/package-imports-v8/secondary-entry-points-migration.js +3 -2
  626. package/schematics/ng-update/migrations/package-imports-v8/secondary-entry-points-migration.mjs +3 -2
  627. package/schematics/ng-update/migrations/theming-api-v12/config.js +59 -10
  628. package/schematics/ng-update/migrations/theming-api-v12/config.mjs +59 -10
  629. package/schematics/ng-update/migrations/theming-api-v12/migration.js +19 -11
  630. package/schematics/ng-update/migrations/theming-api-v12/migration.mjs +19 -11
  631. package/schematics/ng-update/migrations/theming-api-v12/theming-api-migration.js +6 -3
  632. package/schematics/ng-update/migrations/theming-api-v12/theming-api-migration.mjs +6 -3
  633. package/schematics/ng-update/typescript/module-specifiers.js +3 -3
  634. package/schematics/ng-update/typescript/module-specifiers.mjs +3 -3
  635. package/select/public-api.d.ts +1 -1
  636. package/select/testing/select-harness.d.ts +4 -4
  637. package/table/table-data-source.d.ts +3 -3
  638. package/table/testing/row-harness.d.ts +2 -2
  639. package/table/testing/table-harness.d.ts +4 -4
  640. package/tabs/_tabs-theme.scss +6 -2
  641. package/tabs/public-api.d.ts +1 -1
  642. package/tabs/tab-content.d.ts +2 -3
package/fesm2020/sort.mjs CHANGED
@@ -65,9 +65,13 @@ class MatSort extends _MatSortBase {
65
65
  this.sortChange = new EventEmitter();
66
66
  }
67
67
  /** The sort direction of the currently active MatSortable. */
68
- get direction() { return this._direction; }
68
+ get direction() {
69
+ return this._direction;
70
+ }
69
71
  set direction(direction) {
70
- if (direction && direction !== 'asc' && direction !== 'desc' &&
72
+ if (direction &&
73
+ direction !== 'asc' &&
74
+ direction !== 'desc' &&
71
75
  (typeof ngDevMode === 'undefined' || ngDevMode)) {
72
76
  throw getSortInvalidDirectionError(direction);
73
77
  }
@@ -77,8 +81,12 @@ class MatSort extends _MatSortBase {
77
81
  * Whether to disable the user from clearing the sort by finishing the sort direction cycle.
78
82
  * May be overriden by the MatSortable's disable clear input.
79
83
  */
80
- get disableClear() { return this._disableClear; }
81
- set disableClear(v) { this._disableClear = coerceBooleanProperty(v); }
84
+ get disableClear() {
85
+ return this._disableClear;
86
+ }
87
+ set disableClear(v) {
88
+ this._disableClear = coerceBooleanProperty(v);
89
+ }
82
90
  /**
83
91
  * Register function to be used by the contained MatSortables. Adds the MatSortable to the
84
92
  * collection of MatSortables.
@@ -118,8 +126,7 @@ class MatSort extends _MatSortBase {
118
126
  return '';
119
127
  }
120
128
  // Get the sort direction cycle with the potential sortable overrides.
121
- const disableClear = sortable?.disableClear ??
122
- this.disableClear ?? !!this._defaultOptions?.disableClear;
129
+ const disableClear = sortable?.disableClear ?? this.disableClear ?? !!this._defaultOptions?.disableClear;
123
130
  let sortDirectionCycle = getSortDirectionCycle(sortable.start || this.start, disableClear);
124
131
  // Get and return the next direction in the cycle
125
132
  let nextDirectionIndex = sortDirectionCycle.indexOf(this.direction) + 1;
@@ -146,7 +153,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15",
146
153
  selector: '[matSort]',
147
154
  exportAs: 'matSort',
148
155
  host: { 'class': 'mat-sort' },
149
- inputs: ['disabled: matSortDisabled']
156
+ inputs: ['disabled: matSortDisabled'],
150
157
  }]
151
158
  }], ctorParameters: function () { return [{ type: undefined, decorators: [{
152
159
  type: Optional
@@ -188,8 +195,7 @@ function getSortDirectionCycle(start, disableClear) {
188
195
  * Use of this source code is governed by an MIT-style license that can be
189
196
  * found in the LICENSE file at https://angular.io/license
190
197
  */
191
- const SORT_ANIMATION_TRANSITION = AnimationDurations.ENTERING + ' ' +
192
- AnimationCurves.STANDARD_CURVE;
198
+ const SORT_ANIMATION_TRANSITION = AnimationDurations.ENTERING + ' ' + AnimationCurves.STANDARD_CURVE;
193
199
  /**
194
200
  * Animations used by MatSort.
195
201
  * @docs-private
@@ -200,24 +206,24 @@ const matSortAnimations = {
200
206
  state('active-asc, asc', style({ transform: 'translateY(0px)' })),
201
207
  // 10px is the height of the sort indicator, minus the width of the pointers
202
208
  state('active-desc, desc', style({ transform: 'translateY(10px)' })),
203
- transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION))
209
+ transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION)),
204
210
  ]),
205
211
  /** Animation that rotates the left pointer of the indicator based on the sorting direction. */
206
212
  leftPointer: trigger('leftPointer', [
207
213
  state('active-asc, asc', style({ transform: 'rotate(-45deg)' })),
208
214
  state('active-desc, desc', style({ transform: 'rotate(45deg)' })),
209
- transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION))
215
+ transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION)),
210
216
  ]),
211
217
  /** Animation that rotates the right pointer of the indicator based on the sorting direction. */
212
218
  rightPointer: trigger('rightPointer', [
213
219
  state('active-asc, asc', style({ transform: 'rotate(45deg)' })),
214
220
  state('active-desc, desc', style({ transform: 'rotate(-45deg)' })),
215
- transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION))
221
+ transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION)),
216
222
  ]),
217
223
  /** Animation that controls the arrow opacity. */
218
224
  arrowOpacity: trigger('arrowOpacity', [
219
225
  state('desc-to-active, asc-to-active, active', style({ opacity: 1 })),
220
- state('desc-to-hint, asc-to-hint, hint', style({ opacity: .54 })),
226
+ state('desc-to-hint, asc-to-hint, hint', style({ opacity: 0.54 })),
221
227
  state('hint-to-desc, active-to-desc, desc, hint-to-asc, active-to-asc, asc, void', style({ opacity: 0 })),
222
228
  // Transition between all states except for immediate transitions
223
229
  transition('* => asc, * => desc, * => active, * => hint, * => void', animate('0ms')),
@@ -232,34 +238,20 @@ const matSortAnimations = {
232
238
  */
233
239
  arrowPosition: trigger('arrowPosition', [
234
240
  // Hidden Above => Hint Center
235
- transition('* => desc-to-hint, * => desc-to-active', animate(SORT_ANIMATION_TRANSITION, keyframes([
236
- style({ transform: 'translateY(-25%)' }),
237
- style({ transform: 'translateY(0)' })
238
- ]))),
241
+ transition('* => desc-to-hint, * => desc-to-active', animate(SORT_ANIMATION_TRANSITION, keyframes([style({ transform: 'translateY(-25%)' }), style({ transform: 'translateY(0)' })]))),
239
242
  // Hint Center => Hidden Below
240
- transition('* => hint-to-desc, * => active-to-desc', animate(SORT_ANIMATION_TRANSITION, keyframes([
241
- style({ transform: 'translateY(0)' }),
242
- style({ transform: 'translateY(25%)' })
243
- ]))),
243
+ transition('* => hint-to-desc, * => active-to-desc', animate(SORT_ANIMATION_TRANSITION, keyframes([style({ transform: 'translateY(0)' }), style({ transform: 'translateY(25%)' })]))),
244
244
  // Hidden Below => Hint Center
245
- transition('* => asc-to-hint, * => asc-to-active', animate(SORT_ANIMATION_TRANSITION, keyframes([
246
- style({ transform: 'translateY(25%)' }),
247
- style({ transform: 'translateY(0)' })
248
- ]))),
245
+ transition('* => asc-to-hint, * => asc-to-active', animate(SORT_ANIMATION_TRANSITION, keyframes([style({ transform: 'translateY(25%)' }), style({ transform: 'translateY(0)' })]))),
249
246
  // Hint Center => Hidden Above
250
- transition('* => hint-to-asc, * => active-to-asc', animate(SORT_ANIMATION_TRANSITION, keyframes([
251
- style({ transform: 'translateY(0)' }),
252
- style({ transform: 'translateY(-25%)' })
253
- ]))),
247
+ transition('* => hint-to-asc, * => active-to-asc', animate(SORT_ANIMATION_TRANSITION, keyframes([style({ transform: 'translateY(0)' }), style({ transform: 'translateY(-25%)' })]))),
254
248
  state('desc-to-hint, asc-to-hint, hint, desc-to-active, asc-to-active, active', style({ transform: 'translateY(0)' })),
255
249
  state('hint-to-desc, active-to-desc, desc', style({ transform: 'translateY(-25%)' })),
256
250
  state('hint-to-asc, active-to-asc, asc', style({ transform: 'translateY(25%)' })),
257
251
  ]),
258
252
  /** Necessary trigger that calls animate on children animations. */
259
253
  allowChildren: trigger('allowChildren', [
260
- transition('* <=> *', [
261
- query('@*', animateChild(), { optional: true })
262
- ])
254
+ transition('* <=> *', [query('@*', animateChild(), { optional: true })]),
263
255
  ]),
264
256
  };
265
257
 
@@ -298,7 +290,7 @@ const MAT_SORT_HEADER_INTL_PROVIDER = {
298
290
  // If there is already an MatSortHeaderIntl available, use that. Otherwise, provide a new one.
299
291
  provide: MatSortHeaderIntl,
300
292
  deps: [[new Optional(), new SkipSelf(), MatSortHeaderIntl]],
301
- useFactory: MAT_SORT_HEADER_INTL_PROVIDER_FACTORY
293
+ useFactory: MAT_SORT_HEADER_INTL_PROVIDER_FACTORY,
302
294
  };
303
295
 
304
296
  /**
@@ -384,15 +376,21 @@ class MatSortHeader extends _MatSortHeaderBase {
384
376
  this._updateSortActionDescription(value);
385
377
  }
386
378
  /** Overrides the disable clear value of the containing MatSort for this MatSortable. */
387
- get disableClear() { return this._disableClear; }
388
- set disableClear(v) { this._disableClear = coerceBooleanProperty(v); }
379
+ get disableClear() {
380
+ return this._disableClear;
381
+ }
382
+ set disableClear(v) {
383
+ this._disableClear = coerceBooleanProperty(v);
384
+ }
389
385
  ngOnInit() {
390
386
  if (!this.id && this._columnDef) {
391
387
  this.id = this._columnDef.name;
392
388
  }
393
389
  // Initialize the direction of the arrow and set the view state to be immediately that state.
394
390
  this._updateArrowDirection();
395
- this._setAnimationTransitionState({ toState: this._isSorted() ? 'active' : this._arrowDirection });
391
+ this._setAnimationTransitionState({
392
+ toState: this._isSorted() ? 'active' : this._arrowDirection,
393
+ });
396
394
  this._sort.register(this);
397
395
  this._sortButton = this._elementRef.nativeElement.querySelector('[role="button"]');
398
396
  this._updateSortActionDescription(this._sortActionDescription);
@@ -467,8 +465,8 @@ class MatSortHeader extends _MatSortHeaderBase {
467
465
  }
468
466
  /** Whether this MatSortHeader is currently sorted in either ascending or descending order. */
469
467
  _isSorted() {
470
- return this._sort.active == this.id &&
471
- (this._sort.direction === 'asc' || this._sort.direction === 'desc');
468
+ return (this._sort.active == this.id &&
469
+ (this._sort.direction === 'asc' || this._sort.direction === 'desc'));
472
470
  }
473
471
  /** Returns the animation state for the arrow direction (indicator and pointers). */
474
472
  _getArrowDirectionState() {
@@ -490,9 +488,7 @@ class MatSortHeader extends _MatSortHeaderBase {
490
488
  * only be changed once the arrow displays again (hint or activation).
491
489
  */
492
490
  _updateArrowDirection() {
493
- this._arrowDirection = this._isSorted() ?
494
- this._sort.direction :
495
- (this.start || this._sort.start);
491
+ this._arrowDirection = this._isSorted() ? this._sort.direction : this.start || this._sort.start;
496
492
  }
497
493
  _isDisabled() {
498
494
  return this._sort.disabled || this.disabled;
@@ -529,24 +525,23 @@ class MatSortHeader extends _MatSortHeaderBase {
529
525
  }
530
526
  /** Handles changes in the sorting state. */
531
527
  _handleStateChanges() {
532
- this._rerenderSubscription =
533
- merge(this._sort.sortChange, this._sort._stateChanges, this._intl.changes).subscribe(() => {
534
- if (this._isSorted()) {
535
- this._updateArrowDirection();
536
- // Do not show the animation if the header was already shown in the right position.
537
- if (this._viewState.toState === 'hint' || this._viewState.toState === 'active') {
538
- this._disableViewStateAnimation = true;
539
- }
540
- this._setAnimationTransitionState({ fromState: this._arrowDirection, toState: 'active' });
541
- this._showIndicatorHint = false;
528
+ this._rerenderSubscription = merge(this._sort.sortChange, this._sort._stateChanges, this._intl.changes).subscribe(() => {
529
+ if (this._isSorted()) {
530
+ this._updateArrowDirection();
531
+ // Do not show the animation if the header was already shown in the right position.
532
+ if (this._viewState.toState === 'hint' || this._viewState.toState === 'active') {
533
+ this._disableViewStateAnimation = true;
542
534
  }
543
- // If this header was recently active and now no longer sorted, animate away the arrow.
544
- if (!this._isSorted() && this._viewState && this._viewState.toState === 'active') {
545
- this._disableViewStateAnimation = false;
546
- this._setAnimationTransitionState({ fromState: 'active', toState: this._arrowDirection });
547
- }
548
- this._changeDetectorRef.markForCheck();
549
- });
535
+ this._setAnimationTransitionState({ fromState: this._arrowDirection, toState: 'active' });
536
+ this._showIndicatorHint = false;
537
+ }
538
+ // If this header was recently active and now no longer sorted, animate away the arrow.
539
+ if (!this._isSorted() && this._viewState && this._viewState.toState === 'active') {
540
+ this._disableViewStateAnimation = false;
541
+ this._setAnimationTransitionState({ fromState: 'active', toState: this._arrowDirection });
542
+ }
543
+ this._changeDetectorRef.markForCheck();
544
+ });
550
545
  }
551
546
  }
552
547
  MatSortHeader.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.0.0-next.15", ngImport: i0, type: MatSortHeader, deps: [{ token: MatSortHeaderIntl }, { token: i0.ChangeDetectorRef }, { token: MatSort, optional: true }, { token: 'MAT_SORT_HEADER_COLUMN_DEF', optional: true }, { token: i3.FocusMonitor }, { token: i0.ElementRef }, { token: i3.AriaDescriber, optional: true }], target: i0.ɵɵFactoryTarget.Component });
@@ -616,7 +611,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.0.0-next.15",
616
611
  imports: [CommonModule, MatCommonModule],
617
612
  exports: [MatSort, MatSortHeader],
618
613
  declarations: [MatSort, MatSortHeader],
619
- providers: [MAT_SORT_HEADER_INTL_PROVIDER]
614
+ providers: [MAT_SORT_HEADER_INTL_PROVIDER],
620
615
  }]
621
616
  }] });
622
617
 
@@ -1 +1 @@
1
- {"version":3,"file":"sort.mjs","sources":["../../../../../../src/material/sort/sort-errors.ts","../../../../../../src/material/sort/sort.ts","../../../../../../src/material/sort/sort-animations.ts","../../../../../../src/material/sort/sort-header-intl.ts","../../../../../../src/material/sort/sort-header.ts","../../../../../../src/material/sort/sort-header.html","../../../../../../src/material/sort/sort-module.ts","../../../../../../src/material/sort/sort-direction.ts","../../../../../../src/material/sort/public-api.ts","../../../../../../src/material/sort/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\n/** @docs-private */\nexport function getSortDuplicateSortableIdError(id: string): Error {\n return Error(`Cannot have two MatSortables with the same id (${id}).`);\n}\n\n/** @docs-private */\nexport function getSortHeaderNotContainedWithinSortError(): Error {\n return Error(`MatSortHeader must be placed within a parent element with the MatSort directive.`);\n}\n\n/** @docs-private */\nexport function getSortHeaderMissingIdError(): Error {\n return Error(`MatSortHeader must be provided with a unique id.`);\n}\n\n/** @docs-private */\nexport function getSortInvalidDirectionError(direction: string): Error {\n return Error(`${direction} is not a valid sort direction ('asc' or 'desc').`);\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 {BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {\n Directive,\n EventEmitter,\n Inject,\n InjectionToken,\n Input,\n OnChanges,\n OnDestroy,\n OnInit,\n Optional,\n Output,\n} from '@angular/core';\nimport {\n CanDisable,\n HasInitialized,\n mixinDisabled,\n mixinInitialized,\n} from '@angular/material/core';\nimport {Subject} from 'rxjs';\nimport {SortDirection} from './sort-direction';\nimport {\n getSortDuplicateSortableIdError,\n getSortHeaderMissingIdError,\n getSortInvalidDirectionError,\n} from './sort-errors';\n\n/** Interface for a directive that holds sorting state consumed by `MatSortHeader`. */\nexport interface MatSortable {\n /** The id of the column being sorted. */\n id: string;\n\n /** Starting sort direction. */\n start: 'asc' | 'desc';\n\n /** Whether to disable clearing the sorting state. */\n disableClear: boolean;\n}\n\n/** The current sort state. */\nexport interface Sort {\n /** The id of the column being sorted. */\n active: string;\n\n /** The sort direction. */\n direction: SortDirection;\n}\n\n/** Default options for `mat-sort`. */\nexport interface MatSortDefaultOptions {\n /** Whether to disable clearing the sorting state. */\n disableClear?: boolean;\n}\n\n/** Injection token to be used to override the default options for `mat-sort`. */\nexport const MAT_SORT_DEFAULT_OPTIONS =\n new InjectionToken<MatSortDefaultOptions>('MAT_SORT_DEFAULT_OPTIONS');\n\n\n// Boilerplate for applying mixins to MatSort.\n/** @docs-private */\nconst _MatSortBase = mixinInitialized(mixinDisabled(class {}));\n\n/** Container for MatSortables to manage the sort state and provide default sort parameters. */\n@Directive({\n selector: '[matSort]',\n exportAs: 'matSort',\n host: {'class': 'mat-sort'},\n inputs: ['disabled: matSortDisabled']\n})\nexport class MatSort extends _MatSortBase\n implements CanDisable, HasInitialized, OnChanges, OnDestroy, OnInit {\n /** Collection of all registered sortables that this directive manages. */\n sortables = new Map<string, MatSortable>();\n\n /** Used to notify any child components listening to state changes. */\n readonly _stateChanges = new Subject<void>();\n\n /** The id of the most recently sorted MatSortable. */\n @Input('matSortActive') active: string;\n\n /**\n * The direction to set when an MatSortable is initially sorted.\n * May be overriden by the MatSortable's sort start.\n */\n @Input('matSortStart') start: 'asc' | 'desc' = 'asc';\n\n /** The sort direction of the currently active MatSortable. */\n @Input('matSortDirection')\n get direction(): SortDirection { return this._direction; }\n set direction(direction: SortDirection) {\n if (direction && direction !== 'asc' && direction !== 'desc' &&\n (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getSortInvalidDirectionError(direction);\n }\n this._direction = direction;\n }\n private _direction: SortDirection = '';\n\n /**\n * Whether to disable the user from clearing the sort by finishing the sort direction cycle.\n * May be overriden by the MatSortable's disable clear input.\n */\n @Input('matSortDisableClear')\n get disableClear(): boolean { return this._disableClear; }\n set disableClear(v: boolean) { this._disableClear = coerceBooleanProperty(v); }\n private _disableClear: boolean;\n\n /** Event emitted when the user changes either the active sort or sort direction. */\n @Output('matSortChange') readonly sortChange: EventEmitter<Sort> = new EventEmitter<Sort>();\n\n constructor(@Optional() @Inject(MAT_SORT_DEFAULT_OPTIONS)\n private _defaultOptions?: MatSortDefaultOptions) {\n super();\n }\n\n /**\n * Register function to be used by the contained MatSortables. Adds the MatSortable to the\n * collection of MatSortables.\n */\n register(sortable: MatSortable): void {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (!sortable.id) {\n throw getSortHeaderMissingIdError();\n }\n\n if (this.sortables.has(sortable.id)) {\n throw getSortDuplicateSortableIdError(sortable.id);\n }\n }\n\n this.sortables.set(sortable.id, sortable);\n }\n\n /**\n * Unregister function to be used by the contained MatSortables. Removes the MatSortable from the\n * collection of contained MatSortables.\n */\n deregister(sortable: MatSortable): void {\n this.sortables.delete(sortable.id);\n }\n\n /** Sets the active sort id and determines the new sort direction. */\n sort(sortable: MatSortable): void {\n if (this.active != sortable.id) {\n this.active = sortable.id;\n this.direction = sortable.start ? sortable.start : this.start;\n } else {\n this.direction = this.getNextSortDirection(sortable);\n }\n\n this.sortChange.emit({active: this.active, direction: this.direction});\n }\n\n /** Returns the next sort direction of the active sortable, checking for potential overrides. */\n getNextSortDirection(sortable: MatSortable): SortDirection {\n if (!sortable) { return ''; }\n\n // Get the sort direction cycle with the potential sortable overrides.\n const disableClear = sortable?.disableClear ??\n this.disableClear ?? !!this._defaultOptions?.disableClear;\n let sortDirectionCycle = getSortDirectionCycle(sortable.start || this.start, disableClear);\n\n // Get and return the next direction in the cycle\n let nextDirectionIndex = sortDirectionCycle.indexOf(this.direction) + 1;\n if (nextDirectionIndex >= sortDirectionCycle.length) { nextDirectionIndex = 0; }\n return sortDirectionCycle[nextDirectionIndex];\n }\n\n ngOnInit() {\n this._markInitialized();\n }\n\n ngOnChanges() {\n this._stateChanges.next();\n }\n\n ngOnDestroy() {\n this._stateChanges.complete();\n }\n\n static ngAcceptInputType_disableClear: BooleanInput;\n static ngAcceptInputType_disabled: BooleanInput;\n}\n\n/** Returns the sort direction cycle to use given the provided parameters of order and clear. */\nfunction getSortDirectionCycle(start: 'asc' | 'desc',\n disableClear: boolean): SortDirection[] {\n let sortOrder: SortDirection[] = ['asc', 'desc'];\n if (start == 'desc') { sortOrder.reverse(); }\n if (!disableClear) { sortOrder.push(''); }\n\n return sortOrder;\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 */\nimport {\n animate,\n state,\n style,\n transition,\n trigger,\n keyframes,\n AnimationTriggerMetadata, query, animateChild,\n} from '@angular/animations';\nimport {AnimationCurves, AnimationDurations} from '@angular/material/core';\n\nconst SORT_ANIMATION_TRANSITION = AnimationDurations.ENTERING + ' ' +\n AnimationCurves.STANDARD_CURVE;\n\n/**\n * Animations used by MatSort.\n * @docs-private\n */\nexport const matSortAnimations: {\n readonly indicator: AnimationTriggerMetadata;\n readonly leftPointer: AnimationTriggerMetadata;\n readonly rightPointer: AnimationTriggerMetadata;\n readonly arrowOpacity: AnimationTriggerMetadata;\n readonly arrowPosition: AnimationTriggerMetadata;\n readonly allowChildren: AnimationTriggerMetadata;\n} = {\n /** Animation that moves the sort indicator. */\n indicator: trigger('indicator', [\n state('active-asc, asc', style({transform: 'translateY(0px)'})),\n // 10px is the height of the sort indicator, minus the width of the pointers\n state('active-desc, desc', style({transform: 'translateY(10px)'})),\n transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION))\n ]),\n\n /** Animation that rotates the left pointer of the indicator based on the sorting direction. */\n leftPointer: trigger('leftPointer', [\n state('active-asc, asc', style({transform: 'rotate(-45deg)'})),\n state('active-desc, desc', style({transform: 'rotate(45deg)'})),\n transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION))\n ]),\n\n /** Animation that rotates the right pointer of the indicator based on the sorting direction. */\n rightPointer: trigger('rightPointer', [\n state('active-asc, asc', style({transform: 'rotate(45deg)'})),\n state('active-desc, desc', style({transform: 'rotate(-45deg)'})),\n transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION))\n ]),\n\n /** Animation that controls the arrow opacity. */\n arrowOpacity: trigger('arrowOpacity', [\n state('desc-to-active, asc-to-active, active', style({opacity: 1})),\n state('desc-to-hint, asc-to-hint, hint', style({opacity: .54})),\n state('hint-to-desc, active-to-desc, desc, hint-to-asc, active-to-asc, asc, void',\n style({opacity: 0})),\n // Transition between all states except for immediate transitions\n transition('* => asc, * => desc, * => active, * => hint, * => void', animate('0ms')),\n transition('* <=> *', animate(SORT_ANIMATION_TRANSITION)),\n ]),\n\n /**\n * Animation for the translation of the arrow as a whole. States are separated into two\n * groups: ones with animations and others that are immediate. Immediate states are asc, desc,\n * peek, and active. The other states define a specific animation (source-to-destination)\n * and are determined as a function of their prev user-perceived state and what the next state\n * should be.\n */\n arrowPosition: trigger('arrowPosition', [\n // Hidden Above => Hint Center\n transition('* => desc-to-hint, * => desc-to-active',\n animate(SORT_ANIMATION_TRANSITION, keyframes([\n style({transform: 'translateY(-25%)'}),\n style({transform: 'translateY(0)'})\n ]))),\n // Hint Center => Hidden Below\n transition('* => hint-to-desc, * => active-to-desc',\n animate(SORT_ANIMATION_TRANSITION, keyframes([\n style({transform: 'translateY(0)'}),\n style({transform: 'translateY(25%)'})\n ]))),\n // Hidden Below => Hint Center\n transition('* => asc-to-hint, * => asc-to-active',\n animate(SORT_ANIMATION_TRANSITION, keyframes([\n style({transform: 'translateY(25%)'}),\n style({transform: 'translateY(0)'})\n ]))),\n // Hint Center => Hidden Above\n transition('* => hint-to-asc, * => active-to-asc',\n animate(SORT_ANIMATION_TRANSITION, keyframes([\n style({transform: 'translateY(0)'}),\n style({transform: 'translateY(-25%)'})\n ]))),\n state('desc-to-hint, asc-to-hint, hint, desc-to-active, asc-to-active, active',\n style({transform: 'translateY(0)'})),\n state('hint-to-desc, active-to-desc, desc',\n style({transform: 'translateY(-25%)'})),\n state('hint-to-asc, active-to-asc, asc',\n style({transform: 'translateY(25%)'})),\n ]),\n\n /** Necessary trigger that calls animate on children animations. */\n allowChildren: trigger('allowChildren', [\n transition('* <=> *', [\n query('@*', animateChild(), {optional: true})\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 {Injectable, SkipSelf, Optional} from '@angular/core';\nimport {Subject} from 'rxjs';\n\n/**\n * To modify the labels and text displayed, create a new instance of MatSortHeaderIntl and\n * include it in a custom provider.\n */\n@Injectable({providedIn: 'root'})\nexport class MatSortHeaderIntl {\n /**\n * Stream that emits whenever the labels here are changed. Use this to notify\n * components if the labels have changed after initialization.\n */\n readonly changes: Subject<void> = new Subject<void>();\n}\n\n/** @docs-private */\nexport function MAT_SORT_HEADER_INTL_PROVIDER_FACTORY(parentIntl: MatSortHeaderIntl) {\n return parentIntl || new MatSortHeaderIntl();\n}\n\n/** @docs-private */\nexport const MAT_SORT_HEADER_INTL_PROVIDER = {\n // If there is already an MatSortHeaderIntl available, use that. Otherwise, provide a new one.\n provide: MatSortHeaderIntl,\n deps: [[new Optional(), new SkipSelf(), MatSortHeaderIntl]],\n useFactory: MAT_SORT_HEADER_INTL_PROVIDER_FACTORY\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 {AriaDescriber, FocusMonitor} from '@angular/cdk/a11y';\nimport {BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {ENTER, SPACE} from '@angular/cdk/keycodes';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional,\n ViewEncapsulation,\n} from '@angular/core';\nimport {CanDisable, mixinDisabled} from '@angular/material/core';\nimport {merge, Subscription} from 'rxjs';\nimport {MatSort, MatSortable} from './sort';\nimport {matSortAnimations} from './sort-animations';\nimport {SortDirection} from './sort-direction';\nimport {getSortHeaderNotContainedWithinSortError} from './sort-errors';\nimport {MatSortHeaderIntl} from './sort-header-intl';\n\n\n// Boilerplate for applying mixins to the sort header.\n/** @docs-private */\nconst _MatSortHeaderBase = mixinDisabled(class {});\n\n/**\n * Valid positions for the arrow to be in for its opacity and translation. If the state is a\n * sort direction, the position of the arrow will be above/below and opacity 0. If the state is\n * hint, the arrow will be in the center with a slight opacity. Active state means the arrow will\n * be fully opaque in the center.\n *\n * @docs-private\n */\nexport type ArrowViewState = SortDirection | 'hint' | 'active';\n\n/**\n * States describing the arrow's animated position (animating fromState to toState).\n * If the fromState is not defined, there will be no animated transition to the toState.\n * @docs-private\n */\nexport interface ArrowViewStateTransition {\n fromState?: ArrowViewState;\n toState?: ArrowViewState;\n}\n\n/** Column definition associated with a `MatSortHeader`. */\ninterface MatSortHeaderColumnDef {\n name: string;\n}\n\n/**\n * Applies sorting behavior (click to change sort) and styles to an element, including an\n * arrow to display the current sort direction.\n *\n * Must be provided with an id and contained within a parent MatSort directive.\n *\n * If used on header cells in a CdkTable, it will automatically default its id from its containing\n * column definition.\n */\n@Component({\n selector: '[mat-sort-header]',\n exportAs: 'matSortHeader',\n templateUrl: 'sort-header.html',\n styleUrls: ['sort-header.css'],\n host: {\n 'class': 'mat-sort-header',\n '(click)': '_handleClick()',\n '(keydown)': '_handleKeydown($event)',\n '(mouseenter)': '_setIndicatorHintVisible(true)',\n '(mouseleave)': '_setIndicatorHintVisible(false)',\n '[attr.aria-sort]': '_getAriaSortAttribute()',\n '[class.mat-sort-header-disabled]': '_isDisabled()',\n },\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n inputs: ['disabled'],\n animations: [\n matSortAnimations.indicator,\n matSortAnimations.leftPointer,\n matSortAnimations.rightPointer,\n matSortAnimations.arrowOpacity,\n matSortAnimations.arrowPosition,\n matSortAnimations.allowChildren,\n ]\n})\nexport class MatSortHeader extends _MatSortHeaderBase\n implements CanDisable, MatSortable, OnDestroy, OnInit, AfterViewInit {\n private _rerenderSubscription: Subscription;\n\n /**\n * The element with role=\"button\" inside this component's view. We need this\n * in order to apply a description with AriaDescriber.\n */\n private _sortButton: HTMLElement;\n\n /**\n * Flag set to true when the indicator should be displayed while the sort is not active. Used to\n * provide an affordance that the header is sortable by showing on focus and hover.\n */\n _showIndicatorHint: boolean = false;\n\n /**\n * The view transition state of the arrow (translation/ opacity) - indicates its `from` and `to`\n * position through the animation. If animations are currently disabled, the fromState is removed\n * so that there is no animation displayed.\n */\n _viewState: ArrowViewStateTransition = { };\n\n /** The direction the arrow should be facing according to the current state. */\n _arrowDirection: SortDirection = '';\n\n /**\n * Whether the view state animation should show the transition between the `from` and `to` states.\n */\n _disableViewStateAnimation = false;\n\n /**\n * ID of this sort header. If used within the context of a CdkColumnDef, this will default to\n * the column's name.\n */\n @Input('mat-sort-header') id: string;\n\n /** Sets the position of the arrow that displays when sorted. */\n @Input() arrowPosition: 'before' | 'after' = 'after';\n\n /** Overrides the sort start value of the containing MatSort for this MatSortable. */\n @Input() start: 'asc' | 'desc';\n\n /**\n * Description applied to MatSortHeader's button element with aria-describedby. This text should\n * describe the action that will occur when the user clicks the sort header.\n */\n @Input()\n get sortActionDescription(): string {\n return this._sortActionDescription;\n }\n set sortActionDescription(value: string) {\n this._updateSortActionDescription(value);\n }\n // Default the action description to \"Sort\" because it's better than nothing.\n // Without a description, the button's label comes from the sort header text content,\n // which doesn't give any indication that it performs a sorting operation.\n private _sortActionDescription: string = 'Sort';\n\n /** Overrides the disable clear value of the containing MatSort for this MatSortable. */\n @Input()\n get disableClear(): boolean { return this._disableClear; }\n set disableClear(v) { this._disableClear = coerceBooleanProperty(v); }\n private _disableClear: boolean;\n\n constructor(\n /**\n * @deprecated `_intl` parameter isn't being used anymore and it'll be removed.\n * @breaking-change 13.0.0\n */\n public _intl: MatSortHeaderIntl,\n private _changeDetectorRef: ChangeDetectorRef,\n // `MatSort` is not optionally injected, but just asserted manually w/ better error.\n // tslint:disable-next-line: lightweight-tokens\n @Optional() public _sort: MatSort,\n @Inject('MAT_SORT_HEADER_COLUMN_DEF') @Optional()\n public _columnDef: MatSortHeaderColumnDef,\n private _focusMonitor: FocusMonitor,\n private _elementRef: ElementRef<HTMLElement>,\n /** @breaking-change 14.0.0 _ariaDescriber will be required. */\n @Optional() private _ariaDescriber?: AriaDescriber | null) {\n // Note that we use a string token for the `_columnDef`, because the value is provided both by\n // `material/table` and `cdk/table` and we can't have the CDK depending on Material,\n // and we want to avoid having the sort header depending on the CDK table because\n // of this single reference.\n super();\n\n if (!_sort && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getSortHeaderNotContainedWithinSortError();\n }\n\n this._handleStateChanges();\n }\n\n ngOnInit() {\n if (!this.id && this._columnDef) {\n this.id = this._columnDef.name;\n }\n\n // Initialize the direction of the arrow and set the view state to be immediately that state.\n this._updateArrowDirection();\n this._setAnimationTransitionState(\n {toState: this._isSorted() ? 'active' : this._arrowDirection});\n\n this._sort.register(this);\n\n this._sortButton = this._elementRef.nativeElement.querySelector('[role=\"button\"]')!;\n this._updateSortActionDescription(this._sortActionDescription);\n }\n\n ngAfterViewInit() {\n // We use the focus monitor because we also want to style\n // things differently based on the focus origin.\n this._focusMonitor.monitor(this._elementRef, true).subscribe(origin => {\n const newState = !!origin;\n if (newState !== this._showIndicatorHint) {\n this._setIndicatorHintVisible(newState);\n this._changeDetectorRef.markForCheck();\n }\n });\n }\n\n ngOnDestroy() {\n this._focusMonitor.stopMonitoring(this._elementRef);\n this._sort.deregister(this);\n this._rerenderSubscription.unsubscribe();\n }\n\n /**\n * Sets the \"hint\" state such that the arrow will be semi-transparently displayed as a hint to the\n * user showing what the active sort will become. If set to false, the arrow will fade away.\n */\n _setIndicatorHintVisible(visible: boolean) {\n // No-op if the sort header is disabled - should not make the hint visible.\n if (this._isDisabled() && visible) { return; }\n\n this._showIndicatorHint = visible;\n\n if (!this._isSorted()) {\n this._updateArrowDirection();\n if (this._showIndicatorHint) {\n this._setAnimationTransitionState({fromState: this._arrowDirection, toState: 'hint'});\n } else {\n this._setAnimationTransitionState({fromState: 'hint', toState: this._arrowDirection});\n }\n }\n }\n\n /**\n * Sets the animation transition view state for the arrow's position and opacity. If the\n * `disableViewStateAnimation` flag is set to true, the `fromState` will be ignored so that\n * no animation appears.\n */\n _setAnimationTransitionState(viewState: ArrowViewStateTransition) {\n this._viewState = viewState || { };\n\n // If the animation for arrow position state (opacity/translation) should be disabled,\n // remove the fromState so that it jumps right to the toState.\n if (this._disableViewStateAnimation) {\n this._viewState = {toState: viewState.toState};\n }\n }\n\n /** Triggers the sort on this sort header and removes the indicator hint. */\n _toggleOnInteraction() {\n this._sort.sort(this);\n\n // Do not show the animation if the header was already shown in the right position.\n if (this._viewState.toState === 'hint' || this._viewState.toState === 'active') {\n this._disableViewStateAnimation = true;\n }\n }\n\n _handleClick() {\n if (!this._isDisabled()) {\n this._sort.sort(this);\n }\n }\n\n _handleKeydown(event: KeyboardEvent) {\n if (!this._isDisabled() && (event.keyCode === SPACE || event.keyCode === ENTER)) {\n event.preventDefault();\n this._toggleOnInteraction();\n }\n }\n\n /** Whether this MatSortHeader is currently sorted in either ascending or descending order. */\n _isSorted() {\n return this._sort.active == this.id &&\n (this._sort.direction === 'asc' || this._sort.direction === 'desc');\n }\n\n /** Returns the animation state for the arrow direction (indicator and pointers). */\n _getArrowDirectionState() {\n return `${this._isSorted() ? 'active-' : ''}${this._arrowDirection}`;\n }\n\n /** Returns the arrow position state (opacity, translation). */\n _getArrowViewState() {\n const fromState = this._viewState.fromState;\n return (fromState ? `${fromState}-to-` : '') + this._viewState.toState;\n }\n\n /**\n * Updates the direction the arrow should be pointing. If it is not sorted, the arrow should be\n * facing the start direction. Otherwise if it is sorted, the arrow should point in the currently\n * active sorted direction. The reason this is updated through a function is because the direction\n * should only be changed at specific times - when deactivated but the hint is displayed and when\n * the sort is active and the direction changes. Otherwise the arrow's direction should linger\n * in cases such as the sort becoming deactivated but we want to animate the arrow away while\n * preserving its direction, even though the next sort direction is actually different and should\n * only be changed once the arrow displays again (hint or activation).\n */\n _updateArrowDirection() {\n this._arrowDirection = this._isSorted() ?\n this._sort.direction :\n (this.start || this._sort.start);\n }\n\n _isDisabled() {\n return this._sort.disabled || this.disabled;\n }\n\n /**\n * Gets the aria-sort attribute that should be applied to this sort header. If this header\n * is not sorted, returns null so that the attribute is removed from the host element. Aria spec\n * says that the aria-sort property should only be present on one header at a time, so removing\n * ensures this is true.\n */\n _getAriaSortAttribute() {\n if (!this._isSorted()) {\n return 'none';\n }\n\n return this._sort.direction == 'asc' ? 'ascending' : 'descending';\n }\n\n /** Whether the arrow inside the sort header should be rendered. */\n _renderArrow() {\n return !this._isDisabled() || this._isSorted();\n }\n\n private _updateSortActionDescription(newDescription: string) {\n // We use AriaDescriber for the sort button instead of setting an `aria-label` because some\n // screen readers (notably VoiceOver) will read both the column header *and* the button's label\n // for every *cell* in the table, creating a lot of unnecessary noise.\n\n // If _sortButton is undefined, the component hasn't been initialized yet so there's\n // nothing to update in the DOM.\n if (this._sortButton) {\n // removeDescription will no-op if there is no existing message.\n // TODO(jelbourn): remove optional chaining when AriaDescriber is required.\n this._ariaDescriber?.removeDescription(this._sortButton, this._sortActionDescription);\n this._ariaDescriber?.describe(this._sortButton, newDescription);\n }\n\n this._sortActionDescription = newDescription;\n }\n\n /** Handles changes in the sorting state. */\n private _handleStateChanges() {\n this._rerenderSubscription =\n merge(this._sort.sortChange, this._sort._stateChanges, this._intl.changes).subscribe(() => {\n if (this._isSorted()) {\n this._updateArrowDirection();\n\n // Do not show the animation if the header was already shown in the right position.\n if (this._viewState.toState === 'hint' || this._viewState.toState === 'active') {\n this._disableViewStateAnimation = true;\n }\n\n this._setAnimationTransitionState({fromState: this._arrowDirection, toState: 'active'});\n this._showIndicatorHint = false;\n }\n\n // If this header was recently active and now no longer sorted, animate away the arrow.\n if (!this._isSorted() && this._viewState && this._viewState.toState === 'active') {\n this._disableViewStateAnimation = false;\n this._setAnimationTransitionState({fromState: 'active', toState: this._arrowDirection});\n }\n\n this._changeDetectorRef.markForCheck();\n });\n }\n\n static ngAcceptInputType_disableClear: BooleanInput;\n static ngAcceptInputType_disabled: BooleanInput;\n}\n","<!--\n We set the `tabindex` on an element inside the table header, rather than the header itself,\n because of a bug in NVDA where having a `tabindex` on a `th` breaks keyboard navigation in the\n table (see https://github.com/nvaccess/nvda/issues/7718). This allows for the header to both\n be focusable, and have screen readers read out its `aria-sort` state. We prefer this approach\n over having a button with an `aria-label` inside the header, because the button's `aria-label`\n will be read out as the user is navigating the table's cell (see #13012).\n\n The approach is based off of: https://dequeuniversity.com/library/aria/tables/sf-sortable-grid\n-->\n<div class=\"mat-sort-header-container mat-focus-indicator\"\n [class.mat-sort-header-sorted]=\"_isSorted()\"\n [class.mat-sort-header-position-before]=\"arrowPosition == 'before'\"\n [attr.tabindex]=\"_isDisabled() ? null : 0\"\n role=\"button\">\n\n <!--\n TODO(crisbeto): this div isn't strictly necessary, but we have to keep it due to a large\n number of screenshot diff failures. It should be removed eventually. Note that the difference\n isn't visible with a shorter header, but once it breaks up into multiple lines, this element\n causes it to be center-aligned, whereas removing it will keep the text to the left.\n -->\n <div class=\"mat-sort-header-content\">\n <ng-content></ng-content>\n </div>\n\n <!-- Disable animations while a current animation is running -->\n <div class=\"mat-sort-header-arrow\"\n *ngIf=\"_renderArrow()\"\n [@arrowOpacity]=\"_getArrowViewState()\"\n [@arrowPosition]=\"_getArrowViewState()\"\n [@allowChildren]=\"_getArrowDirectionState()\"\n (@arrowPosition.start)=\"_disableViewStateAnimation = true\"\n (@arrowPosition.done)=\"_disableViewStateAnimation = false\">\n <div class=\"mat-sort-header-stem\"></div>\n <div class=\"mat-sort-header-indicator\" [@indicator]=\"_getArrowDirectionState()\">\n <div class=\"mat-sort-header-pointer-left\" [@leftPointer]=\"_getArrowDirectionState()\"></div>\n <div class=\"mat-sort-header-pointer-right\" [@rightPointer]=\"_getArrowDirectionState()\"></div>\n <div class=\"mat-sort-header-pointer-middle\"></div>\n </div>\n </div>\n</div>\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 {NgModule} from '@angular/core';\nimport {MatSortHeader} from './sort-header';\nimport {MatSort} from './sort';\nimport {MAT_SORT_HEADER_INTL_PROVIDER} from './sort-header-intl';\nimport {CommonModule} from '@angular/common';\nimport {MatCommonModule} from '@angular/material/core';\n\n\n@NgModule({\n imports: [CommonModule, MatCommonModule],\n exports: [MatSort, MatSortHeader],\n declarations: [MatSort, MatSortHeader],\n providers: [MAT_SORT_HEADER_INTL_PROVIDER]\n})\nexport class MatSortModule {}\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 type SortDirection = 'asc' | 'desc' | '';\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 './sort-module';\nexport * from './sort-direction';\nexport * from './sort-header';\nexport * from './sort-header-intl';\nexport * from './sort';\nexport * from './sort-animations';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;AAAA;;;;;;;AAQA;SACgB,+BAA+B,CAAC,EAAU;IACxD,OAAO,KAAK,CAAC,kDAAkD,EAAE,IAAI,CAAC,CAAC;AACzE,CAAC;AAED;SACgB,wCAAwC;IACtD,OAAO,KAAK,CAAC,kFAAkF,CAAC,CAAC;AACnG,CAAC;AAED;SACgB,2BAA2B;IACzC,OAAO,KAAK,CAAC,kDAAkD,CAAC,CAAC;AACnE,CAAC;AAED;SACgB,4BAA4B,CAAC,SAAiB;IAC5D,OAAO,KAAK,CAAC,GAAG,SAAS,mDAAmD,CAAC,CAAC;AAChF;;AC1BA;;;;;;;AA8DA;MACa,wBAAwB,GACjC,IAAI,cAAc,CAAwB,0BAA0B,EAAE;AAG1E;AACA;AACA,MAAM,YAAY,GAAG,gBAAgB,CAAC,aAAa,CAAC;CAAQ,CAAC,CAAC,CAAC;AAE/D;MAOa,OAAQ,SAAQ,YAAY;IAyCvC,YACoB,eAAuC;QACzD,KAAK,EAAE,CAAC;QADU,oBAAe,GAAf,eAAe,CAAwB;;QAvC3D,cAAS,GAAG,IAAI,GAAG,EAAuB,CAAC;;QAGlC,kBAAa,GAAG,IAAI,OAAO,EAAQ,CAAC;;;;;QAStB,UAAK,GAAmB,KAAK,CAAC;QAY7C,eAAU,GAAkB,EAAE,CAAC;;QAYL,eAAU,GAAuB,IAAI,YAAY,EAAQ,CAAC;KAK3F;;IA1BD,IACI,SAAS,KAAoB,OAAO,IAAI,CAAC,UAAU,CAAC,EAAE;IAC1D,IAAI,SAAS,CAAC,SAAwB;QACpC,IAAI,SAAS,IAAI,SAAS,KAAK,KAAK,IAAI,SAAS,KAAK,MAAM;aACzD,OAAO,SAAS,KAAK,WAAW,IAAI,SAAS,CAAC,EAAE;YACjD,MAAM,4BAA4B,CAAC,SAAS,CAAC,CAAC;SAC/C;QACD,IAAI,CAAC,UAAU,GAAG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CAAC;iBAC3C;;;ACrBD;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;"}
1
+ {"version":3,"file":"sort.mjs","sources":["../../../../../../src/material/sort/sort-errors.ts","../../../../../../src/material/sort/sort.ts","../../../../../../src/material/sort/sort-animations.ts","../../../../../../src/material/sort/sort-header-intl.ts","../../../../../../src/material/sort/sort-header.ts","../../../../../../src/material/sort/sort-header.html","../../../../../../src/material/sort/sort-module.ts","../../../../../../src/material/sort/sort-direction.ts","../../../../../../src/material/sort/public-api.ts","../../../../../../src/material/sort/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\n/** @docs-private */\nexport function getSortDuplicateSortableIdError(id: string): Error {\n return Error(`Cannot have two MatSortables with the same id (${id}).`);\n}\n\n/** @docs-private */\nexport function getSortHeaderNotContainedWithinSortError(): Error {\n return Error(`MatSortHeader must be placed within a parent element with the MatSort directive.`);\n}\n\n/** @docs-private */\nexport function getSortHeaderMissingIdError(): Error {\n return Error(`MatSortHeader must be provided with a unique id.`);\n}\n\n/** @docs-private */\nexport function getSortInvalidDirectionError(direction: string): Error {\n return Error(`${direction} is not a valid sort direction ('asc' or 'desc').`);\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 {BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {\n Directive,\n EventEmitter,\n Inject,\n InjectionToken,\n Input,\n OnChanges,\n OnDestroy,\n OnInit,\n Optional,\n Output,\n} from '@angular/core';\nimport {CanDisable, HasInitialized, mixinDisabled, mixinInitialized} from '@angular/material/core';\nimport {Subject} from 'rxjs';\nimport {SortDirection} from './sort-direction';\nimport {\n getSortDuplicateSortableIdError,\n getSortHeaderMissingIdError,\n getSortInvalidDirectionError,\n} from './sort-errors';\n\n/** Interface for a directive that holds sorting state consumed by `MatSortHeader`. */\nexport interface MatSortable {\n /** The id of the column being sorted. */\n id: string;\n\n /** Starting sort direction. */\n start: 'asc' | 'desc';\n\n /** Whether to disable clearing the sorting state. */\n disableClear: boolean;\n}\n\n/** The current sort state. */\nexport interface Sort {\n /** The id of the column being sorted. */\n active: string;\n\n /** The sort direction. */\n direction: SortDirection;\n}\n\n/** Default options for `mat-sort`. */\nexport interface MatSortDefaultOptions {\n /** Whether to disable clearing the sorting state. */\n disableClear?: boolean;\n}\n\n/** Injection token to be used to override the default options for `mat-sort`. */\nexport const MAT_SORT_DEFAULT_OPTIONS = new InjectionToken<MatSortDefaultOptions>(\n 'MAT_SORT_DEFAULT_OPTIONS',\n);\n\n// Boilerplate for applying mixins to MatSort.\n/** @docs-private */\nconst _MatSortBase = mixinInitialized(mixinDisabled(class {}));\n\n/** Container for MatSortables to manage the sort state and provide default sort parameters. */\n@Directive({\n selector: '[matSort]',\n exportAs: 'matSort',\n host: {'class': 'mat-sort'},\n inputs: ['disabled: matSortDisabled'],\n})\nexport class MatSort\n extends _MatSortBase\n implements CanDisable, HasInitialized, OnChanges, OnDestroy, OnInit\n{\n /** Collection of all registered sortables that this directive manages. */\n sortables = new Map<string, MatSortable>();\n\n /** Used to notify any child components listening to state changes. */\n readonly _stateChanges = new Subject<void>();\n\n /** The id of the most recently sorted MatSortable. */\n @Input('matSortActive') active: string;\n\n /**\n * The direction to set when an MatSortable is initially sorted.\n * May be overriden by the MatSortable's sort start.\n */\n @Input('matSortStart') start: 'asc' | 'desc' = 'asc';\n\n /** The sort direction of the currently active MatSortable. */\n @Input('matSortDirection')\n get direction(): SortDirection {\n return this._direction;\n }\n set direction(direction: SortDirection) {\n if (\n direction &&\n direction !== 'asc' &&\n direction !== 'desc' &&\n (typeof ngDevMode === 'undefined' || ngDevMode)\n ) {\n throw getSortInvalidDirectionError(direction);\n }\n this._direction = direction;\n }\n private _direction: SortDirection = '';\n\n /**\n * Whether to disable the user from clearing the sort by finishing the sort direction cycle.\n * May be overriden by the MatSortable's disable clear input.\n */\n @Input('matSortDisableClear')\n get disableClear(): boolean {\n return this._disableClear;\n }\n set disableClear(v: boolean) {\n this._disableClear = coerceBooleanProperty(v);\n }\n private _disableClear: boolean;\n\n /** Event emitted when the user changes either the active sort or sort direction. */\n @Output('matSortChange') readonly sortChange: EventEmitter<Sort> = new EventEmitter<Sort>();\n\n constructor(\n @Optional()\n @Inject(MAT_SORT_DEFAULT_OPTIONS)\n private _defaultOptions?: MatSortDefaultOptions,\n ) {\n super();\n }\n\n /**\n * Register function to be used by the contained MatSortables. Adds the MatSortable to the\n * collection of MatSortables.\n */\n register(sortable: MatSortable): void {\n if (typeof ngDevMode === 'undefined' || ngDevMode) {\n if (!sortable.id) {\n throw getSortHeaderMissingIdError();\n }\n\n if (this.sortables.has(sortable.id)) {\n throw getSortDuplicateSortableIdError(sortable.id);\n }\n }\n\n this.sortables.set(sortable.id, sortable);\n }\n\n /**\n * Unregister function to be used by the contained MatSortables. Removes the MatSortable from the\n * collection of contained MatSortables.\n */\n deregister(sortable: MatSortable): void {\n this.sortables.delete(sortable.id);\n }\n\n /** Sets the active sort id and determines the new sort direction. */\n sort(sortable: MatSortable): void {\n if (this.active != sortable.id) {\n this.active = sortable.id;\n this.direction = sortable.start ? sortable.start : this.start;\n } else {\n this.direction = this.getNextSortDirection(sortable);\n }\n\n this.sortChange.emit({active: this.active, direction: this.direction});\n }\n\n /** Returns the next sort direction of the active sortable, checking for potential overrides. */\n getNextSortDirection(sortable: MatSortable): SortDirection {\n if (!sortable) {\n return '';\n }\n\n // Get the sort direction cycle with the potential sortable overrides.\n const disableClear =\n sortable?.disableClear ?? this.disableClear ?? !!this._defaultOptions?.disableClear;\n let sortDirectionCycle = getSortDirectionCycle(sortable.start || this.start, disableClear);\n\n // Get and return the next direction in the cycle\n let nextDirectionIndex = sortDirectionCycle.indexOf(this.direction) + 1;\n if (nextDirectionIndex >= sortDirectionCycle.length) {\n nextDirectionIndex = 0;\n }\n return sortDirectionCycle[nextDirectionIndex];\n }\n\n ngOnInit() {\n this._markInitialized();\n }\n\n ngOnChanges() {\n this._stateChanges.next();\n }\n\n ngOnDestroy() {\n this._stateChanges.complete();\n }\n\n static ngAcceptInputType_disableClear: BooleanInput;\n static ngAcceptInputType_disabled: BooleanInput;\n}\n\n/** Returns the sort direction cycle to use given the provided parameters of order and clear. */\nfunction getSortDirectionCycle(start: 'asc' | 'desc', disableClear: boolean): SortDirection[] {\n let sortOrder: SortDirection[] = ['asc', 'desc'];\n if (start == 'desc') {\n sortOrder.reverse();\n }\n if (!disableClear) {\n sortOrder.push('');\n }\n\n return sortOrder;\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 */\nimport {\n animate,\n state,\n style,\n transition,\n trigger,\n keyframes,\n AnimationTriggerMetadata,\n query,\n animateChild,\n} from '@angular/animations';\nimport {AnimationCurves, AnimationDurations} from '@angular/material/core';\n\nconst SORT_ANIMATION_TRANSITION =\n AnimationDurations.ENTERING + ' ' + AnimationCurves.STANDARD_CURVE;\n\n/**\n * Animations used by MatSort.\n * @docs-private\n */\nexport const matSortAnimations: {\n readonly indicator: AnimationTriggerMetadata;\n readonly leftPointer: AnimationTriggerMetadata;\n readonly rightPointer: AnimationTriggerMetadata;\n readonly arrowOpacity: AnimationTriggerMetadata;\n readonly arrowPosition: AnimationTriggerMetadata;\n readonly allowChildren: AnimationTriggerMetadata;\n} = {\n /** Animation that moves the sort indicator. */\n indicator: trigger('indicator', [\n state('active-asc, asc', style({transform: 'translateY(0px)'})),\n // 10px is the height of the sort indicator, minus the width of the pointers\n state('active-desc, desc', style({transform: 'translateY(10px)'})),\n transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION)),\n ]),\n\n /** Animation that rotates the left pointer of the indicator based on the sorting direction. */\n leftPointer: trigger('leftPointer', [\n state('active-asc, asc', style({transform: 'rotate(-45deg)'})),\n state('active-desc, desc', style({transform: 'rotate(45deg)'})),\n transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION)),\n ]),\n\n /** Animation that rotates the right pointer of the indicator based on the sorting direction. */\n rightPointer: trigger('rightPointer', [\n state('active-asc, asc', style({transform: 'rotate(45deg)'})),\n state('active-desc, desc', style({transform: 'rotate(-45deg)'})),\n transition('active-asc <=> active-desc', animate(SORT_ANIMATION_TRANSITION)),\n ]),\n\n /** Animation that controls the arrow opacity. */\n arrowOpacity: trigger('arrowOpacity', [\n state('desc-to-active, asc-to-active, active', style({opacity: 1})),\n state('desc-to-hint, asc-to-hint, hint', style({opacity: 0.54})),\n state(\n 'hint-to-desc, active-to-desc, desc, hint-to-asc, active-to-asc, asc, void',\n style({opacity: 0}),\n ),\n // Transition between all states except for immediate transitions\n transition('* => asc, * => desc, * => active, * => hint, * => void', animate('0ms')),\n transition('* <=> *', animate(SORT_ANIMATION_TRANSITION)),\n ]),\n\n /**\n * Animation for the translation of the arrow as a whole. States are separated into two\n * groups: ones with animations and others that are immediate. Immediate states are asc, desc,\n * peek, and active. The other states define a specific animation (source-to-destination)\n * and are determined as a function of their prev user-perceived state and what the next state\n * should be.\n */\n arrowPosition: trigger('arrowPosition', [\n // Hidden Above => Hint Center\n transition(\n '* => desc-to-hint, * => desc-to-active',\n animate(\n SORT_ANIMATION_TRANSITION,\n keyframes([style({transform: 'translateY(-25%)'}), style({transform: 'translateY(0)'})]),\n ),\n ),\n // Hint Center => Hidden Below\n transition(\n '* => hint-to-desc, * => active-to-desc',\n animate(\n SORT_ANIMATION_TRANSITION,\n keyframes([style({transform: 'translateY(0)'}), style({transform: 'translateY(25%)'})]),\n ),\n ),\n // Hidden Below => Hint Center\n transition(\n '* => asc-to-hint, * => asc-to-active',\n animate(\n SORT_ANIMATION_TRANSITION,\n keyframes([style({transform: 'translateY(25%)'}), style({transform: 'translateY(0)'})]),\n ),\n ),\n // Hint Center => Hidden Above\n transition(\n '* => hint-to-asc, * => active-to-asc',\n animate(\n SORT_ANIMATION_TRANSITION,\n keyframes([style({transform: 'translateY(0)'}), style({transform: 'translateY(-25%)'})]),\n ),\n ),\n state(\n 'desc-to-hint, asc-to-hint, hint, desc-to-active, asc-to-active, active',\n style({transform: 'translateY(0)'}),\n ),\n state('hint-to-desc, active-to-desc, desc', style({transform: 'translateY(-25%)'})),\n state('hint-to-asc, active-to-asc, asc', style({transform: 'translateY(25%)'})),\n ]),\n\n /** Necessary trigger that calls animate on children animations. */\n allowChildren: trigger('allowChildren', [\n transition('* <=> *', [query('@*', animateChild(), {optional: true})]),\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 {Injectable, SkipSelf, Optional} from '@angular/core';\nimport {Subject} from 'rxjs';\n\n/**\n * To modify the labels and text displayed, create a new instance of MatSortHeaderIntl and\n * include it in a custom provider.\n */\n@Injectable({providedIn: 'root'})\nexport class MatSortHeaderIntl {\n /**\n * Stream that emits whenever the labels here are changed. Use this to notify\n * components if the labels have changed after initialization.\n */\n readonly changes: Subject<void> = new Subject<void>();\n}\n\n/** @docs-private */\nexport function MAT_SORT_HEADER_INTL_PROVIDER_FACTORY(parentIntl: MatSortHeaderIntl) {\n return parentIntl || new MatSortHeaderIntl();\n}\n\n/** @docs-private */\nexport const MAT_SORT_HEADER_INTL_PROVIDER = {\n // If there is already an MatSortHeaderIntl available, use that. Otherwise, provide a new one.\n provide: MatSortHeaderIntl,\n deps: [[new Optional(), new SkipSelf(), MatSortHeaderIntl]],\n useFactory: MAT_SORT_HEADER_INTL_PROVIDER_FACTORY,\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 {AriaDescriber, FocusMonitor} from '@angular/cdk/a11y';\nimport {BooleanInput, coerceBooleanProperty} from '@angular/cdk/coercion';\nimport {ENTER, SPACE} from '@angular/cdk/keycodes';\nimport {\n AfterViewInit,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n Inject,\n Input,\n OnDestroy,\n OnInit,\n Optional,\n ViewEncapsulation,\n} from '@angular/core';\nimport {CanDisable, mixinDisabled} from '@angular/material/core';\nimport {merge, Subscription} from 'rxjs';\nimport {MatSort, MatSortable} from './sort';\nimport {matSortAnimations} from './sort-animations';\nimport {SortDirection} from './sort-direction';\nimport {getSortHeaderNotContainedWithinSortError} from './sort-errors';\nimport {MatSortHeaderIntl} from './sort-header-intl';\n\n// Boilerplate for applying mixins to the sort header.\n/** @docs-private */\nconst _MatSortHeaderBase = mixinDisabled(class {});\n\n/**\n * Valid positions for the arrow to be in for its opacity and translation. If the state is a\n * sort direction, the position of the arrow will be above/below and opacity 0. If the state is\n * hint, the arrow will be in the center with a slight opacity. Active state means the arrow will\n * be fully opaque in the center.\n *\n * @docs-private\n */\nexport type ArrowViewState = SortDirection | 'hint' | 'active';\n\n/**\n * States describing the arrow's animated position (animating fromState to toState).\n * If the fromState is not defined, there will be no animated transition to the toState.\n * @docs-private\n */\nexport interface ArrowViewStateTransition {\n fromState?: ArrowViewState;\n toState?: ArrowViewState;\n}\n\n/** Column definition associated with a `MatSortHeader`. */\ninterface MatSortHeaderColumnDef {\n name: string;\n}\n\n/**\n * Applies sorting behavior (click to change sort) and styles to an element, including an\n * arrow to display the current sort direction.\n *\n * Must be provided with an id and contained within a parent MatSort directive.\n *\n * If used on header cells in a CdkTable, it will automatically default its id from its containing\n * column definition.\n */\n@Component({\n selector: '[mat-sort-header]',\n exportAs: 'matSortHeader',\n templateUrl: 'sort-header.html',\n styleUrls: ['sort-header.css'],\n host: {\n 'class': 'mat-sort-header',\n '(click)': '_handleClick()',\n '(keydown)': '_handleKeydown($event)',\n '(mouseenter)': '_setIndicatorHintVisible(true)',\n '(mouseleave)': '_setIndicatorHintVisible(false)',\n '[attr.aria-sort]': '_getAriaSortAttribute()',\n '[class.mat-sort-header-disabled]': '_isDisabled()',\n },\n encapsulation: ViewEncapsulation.None,\n changeDetection: ChangeDetectionStrategy.OnPush,\n inputs: ['disabled'],\n animations: [\n matSortAnimations.indicator,\n matSortAnimations.leftPointer,\n matSortAnimations.rightPointer,\n matSortAnimations.arrowOpacity,\n matSortAnimations.arrowPosition,\n matSortAnimations.allowChildren,\n ],\n})\nexport class MatSortHeader\n extends _MatSortHeaderBase\n implements CanDisable, MatSortable, OnDestroy, OnInit, AfterViewInit\n{\n private _rerenderSubscription: Subscription;\n\n /**\n * The element with role=\"button\" inside this component's view. We need this\n * in order to apply a description with AriaDescriber.\n */\n private _sortButton: HTMLElement;\n\n /**\n * Flag set to true when the indicator should be displayed while the sort is not active. Used to\n * provide an affordance that the header is sortable by showing on focus and hover.\n */\n _showIndicatorHint: boolean = false;\n\n /**\n * The view transition state of the arrow (translation/ opacity) - indicates its `from` and `to`\n * position through the animation. If animations are currently disabled, the fromState is removed\n * so that there is no animation displayed.\n */\n _viewState: ArrowViewStateTransition = {};\n\n /** The direction the arrow should be facing according to the current state. */\n _arrowDirection: SortDirection = '';\n\n /**\n * Whether the view state animation should show the transition between the `from` and `to` states.\n */\n _disableViewStateAnimation = false;\n\n /**\n * ID of this sort header. If used within the context of a CdkColumnDef, this will default to\n * the column's name.\n */\n @Input('mat-sort-header') id: string;\n\n /** Sets the position of the arrow that displays when sorted. */\n @Input() arrowPosition: 'before' | 'after' = 'after';\n\n /** Overrides the sort start value of the containing MatSort for this MatSortable. */\n @Input() start: 'asc' | 'desc';\n\n /**\n * Description applied to MatSortHeader's button element with aria-describedby. This text should\n * describe the action that will occur when the user clicks the sort header.\n */\n @Input()\n get sortActionDescription(): string {\n return this._sortActionDescription;\n }\n set sortActionDescription(value: string) {\n this._updateSortActionDescription(value);\n }\n // Default the action description to \"Sort\" because it's better than nothing.\n // Without a description, the button's label comes from the sort header text content,\n // which doesn't give any indication that it performs a sorting operation.\n private _sortActionDescription: string = 'Sort';\n\n /** Overrides the disable clear value of the containing MatSort for this MatSortable. */\n @Input()\n get disableClear(): boolean {\n return this._disableClear;\n }\n set disableClear(v) {\n this._disableClear = coerceBooleanProperty(v);\n }\n private _disableClear: boolean;\n\n constructor(\n /**\n * @deprecated `_intl` parameter isn't being used anymore and it'll be removed.\n * @breaking-change 13.0.0\n */\n public _intl: MatSortHeaderIntl,\n private _changeDetectorRef: ChangeDetectorRef,\n // `MatSort` is not optionally injected, but just asserted manually w/ better error.\n // tslint:disable-next-line: lightweight-tokens\n @Optional() public _sort: MatSort,\n @Inject('MAT_SORT_HEADER_COLUMN_DEF')\n @Optional()\n public _columnDef: MatSortHeaderColumnDef,\n private _focusMonitor: FocusMonitor,\n private _elementRef: ElementRef<HTMLElement>,\n /** @breaking-change 14.0.0 _ariaDescriber will be required. */\n @Optional() private _ariaDescriber?: AriaDescriber | null,\n ) {\n // Note that we use a string token for the `_columnDef`, because the value is provided both by\n // `material/table` and `cdk/table` and we can't have the CDK depending on Material,\n // and we want to avoid having the sort header depending on the CDK table because\n // of this single reference.\n super();\n\n if (!_sort && (typeof ngDevMode === 'undefined' || ngDevMode)) {\n throw getSortHeaderNotContainedWithinSortError();\n }\n\n this._handleStateChanges();\n }\n\n ngOnInit() {\n if (!this.id && this._columnDef) {\n this.id = this._columnDef.name;\n }\n\n // Initialize the direction of the arrow and set the view state to be immediately that state.\n this._updateArrowDirection();\n this._setAnimationTransitionState({\n toState: this._isSorted() ? 'active' : this._arrowDirection,\n });\n\n this._sort.register(this);\n\n this._sortButton = this._elementRef.nativeElement.querySelector('[role=\"button\"]')!;\n this._updateSortActionDescription(this._sortActionDescription);\n }\n\n ngAfterViewInit() {\n // We use the focus monitor because we also want to style\n // things differently based on the focus origin.\n this._focusMonitor.monitor(this._elementRef, true).subscribe(origin => {\n const newState = !!origin;\n if (newState !== this._showIndicatorHint) {\n this._setIndicatorHintVisible(newState);\n this._changeDetectorRef.markForCheck();\n }\n });\n }\n\n ngOnDestroy() {\n this._focusMonitor.stopMonitoring(this._elementRef);\n this._sort.deregister(this);\n this._rerenderSubscription.unsubscribe();\n }\n\n /**\n * Sets the \"hint\" state such that the arrow will be semi-transparently displayed as a hint to the\n * user showing what the active sort will become. If set to false, the arrow will fade away.\n */\n _setIndicatorHintVisible(visible: boolean) {\n // No-op if the sort header is disabled - should not make the hint visible.\n if (this._isDisabled() && visible) {\n return;\n }\n\n this._showIndicatorHint = visible;\n\n if (!this._isSorted()) {\n this._updateArrowDirection();\n if (this._showIndicatorHint) {\n this._setAnimationTransitionState({fromState: this._arrowDirection, toState: 'hint'});\n } else {\n this._setAnimationTransitionState({fromState: 'hint', toState: this._arrowDirection});\n }\n }\n }\n\n /**\n * Sets the animation transition view state for the arrow's position and opacity. If the\n * `disableViewStateAnimation` flag is set to true, the `fromState` will be ignored so that\n * no animation appears.\n */\n _setAnimationTransitionState(viewState: ArrowViewStateTransition) {\n this._viewState = viewState || {};\n\n // If the animation for arrow position state (opacity/translation) should be disabled,\n // remove the fromState so that it jumps right to the toState.\n if (this._disableViewStateAnimation) {\n this._viewState = {toState: viewState.toState};\n }\n }\n\n /** Triggers the sort on this sort header and removes the indicator hint. */\n _toggleOnInteraction() {\n this._sort.sort(this);\n\n // Do not show the animation if the header was already shown in the right position.\n if (this._viewState.toState === 'hint' || this._viewState.toState === 'active') {\n this._disableViewStateAnimation = true;\n }\n }\n\n _handleClick() {\n if (!this._isDisabled()) {\n this._sort.sort(this);\n }\n }\n\n _handleKeydown(event: KeyboardEvent) {\n if (!this._isDisabled() && (event.keyCode === SPACE || event.keyCode === ENTER)) {\n event.preventDefault();\n this._toggleOnInteraction();\n }\n }\n\n /** Whether this MatSortHeader is currently sorted in either ascending or descending order. */\n _isSorted() {\n return (\n this._sort.active == this.id &&\n (this._sort.direction === 'asc' || this._sort.direction === 'desc')\n );\n }\n\n /** Returns the animation state for the arrow direction (indicator and pointers). */\n _getArrowDirectionState() {\n return `${this._isSorted() ? 'active-' : ''}${this._arrowDirection}`;\n }\n\n /** Returns the arrow position state (opacity, translation). */\n _getArrowViewState() {\n const fromState = this._viewState.fromState;\n return (fromState ? `${fromState}-to-` : '') + this._viewState.toState;\n }\n\n /**\n * Updates the direction the arrow should be pointing. If it is not sorted, the arrow should be\n * facing the start direction. Otherwise if it is sorted, the arrow should point in the currently\n * active sorted direction. The reason this is updated through a function is because the direction\n * should only be changed at specific times - when deactivated but the hint is displayed and when\n * the sort is active and the direction changes. Otherwise the arrow's direction should linger\n * in cases such as the sort becoming deactivated but we want to animate the arrow away while\n * preserving its direction, even though the next sort direction is actually different and should\n * only be changed once the arrow displays again (hint or activation).\n */\n _updateArrowDirection() {\n this._arrowDirection = this._isSorted() ? this._sort.direction : this.start || this._sort.start;\n }\n\n _isDisabled() {\n return this._sort.disabled || this.disabled;\n }\n\n /**\n * Gets the aria-sort attribute that should be applied to this sort header. If this header\n * is not sorted, returns null so that the attribute is removed from the host element. Aria spec\n * says that the aria-sort property should only be present on one header at a time, so removing\n * ensures this is true.\n */\n _getAriaSortAttribute() {\n if (!this._isSorted()) {\n return 'none';\n }\n\n return this._sort.direction == 'asc' ? 'ascending' : 'descending';\n }\n\n /** Whether the arrow inside the sort header should be rendered. */\n _renderArrow() {\n return !this._isDisabled() || this._isSorted();\n }\n\n private _updateSortActionDescription(newDescription: string) {\n // We use AriaDescriber for the sort button instead of setting an `aria-label` because some\n // screen readers (notably VoiceOver) will read both the column header *and* the button's label\n // for every *cell* in the table, creating a lot of unnecessary noise.\n\n // If _sortButton is undefined, the component hasn't been initialized yet so there's\n // nothing to update in the DOM.\n if (this._sortButton) {\n // removeDescription will no-op if there is no existing message.\n // TODO(jelbourn): remove optional chaining when AriaDescriber is required.\n this._ariaDescriber?.removeDescription(this._sortButton, this._sortActionDescription);\n this._ariaDescriber?.describe(this._sortButton, newDescription);\n }\n\n this._sortActionDescription = newDescription;\n }\n\n /** Handles changes in the sorting state. */\n private _handleStateChanges() {\n this._rerenderSubscription = merge(\n this._sort.sortChange,\n this._sort._stateChanges,\n this._intl.changes,\n ).subscribe(() => {\n if (this._isSorted()) {\n this._updateArrowDirection();\n\n // Do not show the animation if the header was already shown in the right position.\n if (this._viewState.toState === 'hint' || this._viewState.toState === 'active') {\n this._disableViewStateAnimation = true;\n }\n\n this._setAnimationTransitionState({fromState: this._arrowDirection, toState: 'active'});\n this._showIndicatorHint = false;\n }\n\n // If this header was recently active and now no longer sorted, animate away the arrow.\n if (!this._isSorted() && this._viewState && this._viewState.toState === 'active') {\n this._disableViewStateAnimation = false;\n this._setAnimationTransitionState({fromState: 'active', toState: this._arrowDirection});\n }\n\n this._changeDetectorRef.markForCheck();\n });\n }\n\n static ngAcceptInputType_disableClear: BooleanInput;\n static ngAcceptInputType_disabled: BooleanInput;\n}\n","<!--\n We set the `tabindex` on an element inside the table header, rather than the header itself,\n because of a bug in NVDA where having a `tabindex` on a `th` breaks keyboard navigation in the\n table (see https://github.com/nvaccess/nvda/issues/7718). This allows for the header to both\n be focusable, and have screen readers read out its `aria-sort` state. We prefer this approach\n over having a button with an `aria-label` inside the header, because the button's `aria-label`\n will be read out as the user is navigating the table's cell (see #13012).\n\n The approach is based off of: https://dequeuniversity.com/library/aria/tables/sf-sortable-grid\n-->\n<div class=\"mat-sort-header-container mat-focus-indicator\"\n [class.mat-sort-header-sorted]=\"_isSorted()\"\n [class.mat-sort-header-position-before]=\"arrowPosition == 'before'\"\n [attr.tabindex]=\"_isDisabled() ? null : 0\"\n role=\"button\">\n\n <!--\n TODO(crisbeto): this div isn't strictly necessary, but we have to keep it due to a large\n number of screenshot diff failures. It should be removed eventually. Note that the difference\n isn't visible with a shorter header, but once it breaks up into multiple lines, this element\n causes it to be center-aligned, whereas removing it will keep the text to the left.\n -->\n <div class=\"mat-sort-header-content\">\n <ng-content></ng-content>\n </div>\n\n <!-- Disable animations while a current animation is running -->\n <div class=\"mat-sort-header-arrow\"\n *ngIf=\"_renderArrow()\"\n [@arrowOpacity]=\"_getArrowViewState()\"\n [@arrowPosition]=\"_getArrowViewState()\"\n [@allowChildren]=\"_getArrowDirectionState()\"\n (@arrowPosition.start)=\"_disableViewStateAnimation = true\"\n (@arrowPosition.done)=\"_disableViewStateAnimation = false\">\n <div class=\"mat-sort-header-stem\"></div>\n <div class=\"mat-sort-header-indicator\" [@indicator]=\"_getArrowDirectionState()\">\n <div class=\"mat-sort-header-pointer-left\" [@leftPointer]=\"_getArrowDirectionState()\"></div>\n <div class=\"mat-sort-header-pointer-right\" [@rightPointer]=\"_getArrowDirectionState()\"></div>\n <div class=\"mat-sort-header-pointer-middle\"></div>\n </div>\n </div>\n</div>\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 {NgModule} from '@angular/core';\nimport {MatSortHeader} from './sort-header';\nimport {MatSort} from './sort';\nimport {MAT_SORT_HEADER_INTL_PROVIDER} from './sort-header-intl';\nimport {CommonModule} from '@angular/common';\nimport {MatCommonModule} from '@angular/material/core';\n\n@NgModule({\n imports: [CommonModule, MatCommonModule],\n exports: [MatSort, MatSortHeader],\n declarations: [MatSort, MatSortHeader],\n providers: [MAT_SORT_HEADER_INTL_PROVIDER],\n})\nexport class MatSortModule {}\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 type SortDirection = 'asc' | 'desc' | '';\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 './sort-module';\nexport * from './sort-direction';\nexport * from './sort-header';\nexport * from './sort-header-intl';\nexport * from './sort';\nexport * from './sort-animations';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;AAAA;;;;;;;AAQA;SACgB,+BAA+B,CAAC,EAAU;IACxD,OAAO,KAAK,CAAC,kDAAk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iCAAiC;wBACjD,kBAAkB,EAAE,yBAAyB;wBAC7C,kCAAkC,EAAE,eAAe;qBACpD,iBACc,iBAAiB,CAAC,IAAI,mBACpB,uBAAuB,CAAC,MAAM,UACvC,CAAC,UAAU,CAAC,cACR;wBACV,iBAAiB,CAAC,SAAS;wBAC3B,iBAAiB,CAAC,WAAW;wBAC7B,iBAAiB,CAAC,YAAY;wBAC9B,iBAAiB,CAAC,YAAY;wBAC9B,iBAAiB,CAAC,aAAa;wBAC/B,iBAAiB,CAAC,aAAa;qBAChC;;0BAkFE,QAAQ;;0BACR,MAAM;2BAAC,4BAA4B;;0BACnC,QAAQ;;0BAKR,QAAQ;4CAlDe,EAAE;sBAA3B,KAAK;uBAAC,iBAAiB;gBAGf,aAAa;sBAArB,KAAK;gBAGG,KAAK;sBAAb,KAAK;gBAOF,qBAAqB;sBADxB,KAAK;gBAcF,YAAY;sBADf,KAAK;;;AE9JR;;;;;;;MAqBa,aAAa;;kHAAb,aAAa;mHAAb,aAAa,iBAHT,OAAO,EAAE,aAAa,aAF3B,YAAY,EAAE,eAAe,aAC7B,OAAO,EAAE,aAAa;mHAIrB,aAAa,aAFb,CAAC,6BAA6B,CAAC,YAHjC,CAAC,YAAY,EAAE,eAAe,CAAC;mGAK7B,aAAa;kBANzB,QAAQ;mBAAC;oBACR,OAAO,EAAE,CAAC,YAAY,EAAE,eAAe,CAAC;oBACxC,OAAO,EAAE,CAAC,OAAO,EAAE,aAAa,CAAC;oBACjC,YAAY,EAAE,CAAC,OAAO,EAAE,aAAa,CAAC;oBACtC,SAAS,EAAE,CAAC,6BAA6B,CAAC;iBAC3C;;;ACpBD;;;;;;;;ACAA;;;;;;;;ACAA;;;;;;"}
@@ -105,8 +105,7 @@ class MatStepperHarness extends ComponentHarness {
105
105
  * @return a `HarnessPredicate` configured with the given options.
106
106
  */
107
107
  static with(options = {}) {
108
- return new HarnessPredicate(MatStepperHarness, options)
109
- .addOption('orientation', options.orientation, async (harness, orientation) => (await harness.getOrientation()) === orientation);
108
+ return new HarnessPredicate(MatStepperHarness, options).addOption('orientation', options.orientation, async (harness, orientation) => (await harness.getOrientation()) === orientation);
110
109
  }
111
110
  /**
112
111
  * Gets the list of steps in the stepper.
@@ -118,8 +117,9 @@ class MatStepperHarness extends ComponentHarness {
118
117
  /** Gets the orientation of the stepper. */
119
118
  async getOrientation() {
120
119
  const host = await this.host();
121
- return (await host.hasClass('mat-stepper-horizontal')) ?
122
- 0 /* HORIZONTAL */ : 1 /* VERTICAL */;
120
+ return (await host.hasClass('mat-stepper-horizontal'))
121
+ ? 0 /* HORIZONTAL */
122
+ : 1 /* VERTICAL */;
123
123
  }
124
124
  /**
125
125
  * Selects a step in this stepper.
@@ -164,8 +164,7 @@ class MatStepperNextHarness extends StepperButtonHarness {
164
164
  * @return a `HarnessPredicate` configured with the given options.
165
165
  */
166
166
  static with(options = {}) {
167
- return new HarnessPredicate(MatStepperNextHarness, options)
168
- .addOption('text', options.text, (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));
167
+ return new HarnessPredicate(MatStepperNextHarness, options).addOption('text', options.text, (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));
169
168
  }
170
169
  }
171
170
  /** The selector for the host element of a `MatStep` instance. */
@@ -179,8 +178,7 @@ class MatStepperPreviousHarness extends StepperButtonHarness {
179
178
  * @return a `HarnessPredicate` configured with the given options.
180
179
  */
181
180
  static with(options = {}) {
182
- return new HarnessPredicate(MatStepperPreviousHarness, options)
183
- .addOption('text', options.text, (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));
181
+ return new HarnessPredicate(MatStepperPreviousHarness, options).addOption('text', options.text, (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));
184
182
  }
185
183
  }
186
184
  /** The selector for the host element of a `MatStep` instance. */
@@ -1 +1 @@
1
- {"version":3,"file":"testing.mjs","sources":["../../../../../../../src/material/stepper/testing/step-harness.ts","../../../../../../../src/material/stepper/testing/stepper-harness.ts","../../../../../../../src/material/stepper/testing/stepper-button-harnesses.ts","../../../../../../../src/material/stepper/testing/public-api.ts","../../../../../../../src/material/stepper/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 {\n ContentContainerComponentHarness,\n HarnessPredicate,\n HarnessLoader,\n} from '@angular/cdk/testing';\nimport {StepHarnessFilters} from './step-harness-filters';\n\n/** Harness for interacting with a standard Angular Material step in tests. */\nexport class MatStepHarness extends ContentContainerComponentHarness<string> {\n /** The selector for the host element of a `MatStep` instance. */\n static hostSelector = '.mat-step-header';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatStepHarness` that meets\n * certain criteria.\n * @param options Options for filtering which steps are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: StepHarnessFilters = {}): HarnessPredicate<MatStepHarness> {\n return new HarnessPredicate(MatStepHarness, options)\n .addOption('label', options.label,\n (harness, label) => HarnessPredicate.stringMatches(harness.getLabel(), label))\n .addOption('selected', options.selected,\n async (harness, selected) => (await harness.isSelected()) === selected)\n .addOption('completed', options.completed,\n async (harness, completed) => (await harness.isCompleted()) === completed)\n .addOption('invalid', options.invalid,\n async (harness, invalid) => (await harness.hasErrors()) === invalid);\n }\n\n /** Gets the label of the step. */\n async getLabel(): Promise<string> {\n return (await this.locatorFor('.mat-step-text-label')()).text();\n }\n\n /** Gets the `aria-label` of the step. */\n async getAriaLabel(): Promise<string|null> {\n return (await this.host()).getAttribute('aria-label');\n }\n\n /** Gets the value of the `aria-labelledby` attribute. */\n async getAriaLabelledby(): Promise<string|null> {\n return (await this.host()).getAttribute('aria-labelledby');\n }\n\n /** Whether the step is selected. */\n async isSelected(): Promise<boolean> {\n const host = await this.host();\n return (await host.getAttribute('aria-selected')) === 'true';\n }\n\n /** Whether the step has been filled out. */\n async isCompleted(): Promise<boolean> {\n const state = await this._getIconState();\n return state === 'done' || (state === 'edit' && !(await this.isSelected()));\n }\n\n /**\n * Whether the step is currently showing its error state. Note that this doesn't mean that there\n * are or aren't any invalid form controls inside the step, but that the step is showing its\n * error-specific styling which depends on there being invalid controls, as well as the\n * `ErrorStateMatcher` determining that an error should be shown and that the `showErrors`\n * option was enabled through the `STEPPER_GLOBAL_OPTIONS` injection token.\n */\n async hasErrors(): Promise<boolean> {\n return (await this._getIconState()) === 'error';\n }\n\n /** Whether the step is optional. */\n async isOptional(): Promise<boolean> {\n // If the node with the optional text is present, it means that the step is optional.\n const optionalNode = await this.locatorForOptional('.mat-step-optional')();\n return !!optionalNode;\n }\n\n /**\n * Selects the given step by clicking on the label. The step may not be selected\n * if the stepper doesn't allow it (e.g. if there are validation errors).\n */\n async select(): Promise<void> {\n await (await this.host()).click();\n }\n\n protected override async getRootHarnessLoader(): Promise<HarnessLoader> {\n const contentId = await (await this.host()).getAttribute('aria-controls');\n return this.documentRootLocatorFactory().harnessLoaderFor(`#${contentId}`);\n }\n\n /**\n * Gets the state of the step. Note that we have a `StepState` which we could use to type the\n * return value, but it's basically the same as `string`, because the type has `| string`.\n */\n private async _getIconState(): Promise<string> {\n // The state is exposed on the icon with a class that looks like `mat-step-icon-state-{{state}}`\n const icon = await this.locatorFor('.mat-step-icon')();\n const classes = (await icon.getAttribute('class'))!;\n const match = classes.match(/mat-step-icon-state-([a-z]+)/);\n\n if (!match) {\n throw Error(`Could not determine step state from \"${classes}\".`);\n }\n\n return match[1];\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 {ComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {MatStepHarness} from './step-harness';\nimport {\n StepperHarnessFilters,\n StepHarnessFilters,\n StepperOrientation,\n} from './step-harness-filters';\n\n/** Harness for interacting with a standard Material stepper in tests. */\nexport class MatStepperHarness extends ComponentHarness {\n /** The selector for the host element of a `MatStepper` instance. */\n static hostSelector = '.mat-stepper-horizontal, .mat-stepper-vertical';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatStepperHarness` that meets\n * certain criteria.\n * @param options Options for filtering which stepper instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: StepperHarnessFilters = {}): HarnessPredicate<MatStepperHarness> {\n return new HarnessPredicate(MatStepperHarness, options)\n .addOption('orientation', options.orientation,\n async (harness, orientation) => (await harness.getOrientation()) === orientation);\n }\n\n /**\n * Gets the list of steps in the stepper.\n * @param filter Optionally filters which steps are included.\n */\n async getSteps(filter: StepHarnessFilters = {}): Promise<MatStepHarness[]> {\n return this.locatorForAll(MatStepHarness.with(filter))();\n }\n\n /** Gets the orientation of the stepper. */\n async getOrientation(): Promise<StepperOrientation> {\n const host = await this.host();\n return (await host.hasClass('mat-stepper-horizontal')) ?\n StepperOrientation.HORIZONTAL : StepperOrientation.VERTICAL;\n }\n\n /**\n * Selects a step in this stepper.\n * @param filter An optional filter to apply to the child steps. The first step matching the\n * filter will be selected.\n */\n async selectStep(filter: StepHarnessFilters = {}): Promise<void> {\n const steps = await this.getSteps(filter);\n if (!steps.length) {\n throw Error(`Cannot find mat-step matching filter ${JSON.stringify(filter)}`);\n }\n await steps[0].select();\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 {ComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {StepperButtonHarnessFilters} from './step-harness-filters';\n\n/** Base class for stepper button harnesses. */\nabstract class StepperButtonHarness extends ComponentHarness {\n /** Gets the text of the button. */\n async getText(): Promise<string> {\n return (await this.host()).text();\n }\n\n /** Clicks the button. */\n async click(): Promise<void> {\n return (await this.host()).click();\n }\n}\n\n/** Harness for interacting with a standard Angular Material stepper next button in tests. */\nexport class MatStepperNextHarness extends StepperButtonHarness {\n /** The selector for the host element of a `MatStep` instance. */\n static hostSelector = '.mat-stepper-next';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatStepperNextHarness` that meets\n * certain criteria.\n * @param options Options for filtering which steps are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: StepperButtonHarnessFilters = {}): HarnessPredicate<MatStepperNextHarness> {\n return new HarnessPredicate(MatStepperNextHarness, options)\n .addOption('text', options.text,\n (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));\n }\n}\n\n\n/** Harness for interacting with a standard Angular Material stepper previous button in tests. */\nexport class MatStepperPreviousHarness extends StepperButtonHarness {\n /** The selector for the host element of a `MatStep` instance. */\n static hostSelector = '.mat-stepper-previous';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatStepperPreviousHarness`\n * that meets certain criteria.\n * @param options Options for filtering which steps are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: StepperButtonHarnessFilters = {}):\n HarnessPredicate<MatStepperPreviousHarness> {\n return new HarnessPredicate(MatStepperPreviousHarness, options)\n .addOption('text', options.text,\n (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text));\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\nexport * from './stepper-harness';\nexport * from './step-harness';\nexport * from './step-harness-filters';\nexport * from './stepper-button-harnesses';\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;;;;;;;AAeA;MACa,cAAe,SAAQ,gCAAwC;;;;;;;IAU1E,OAAO,IAAI,CAAC,UAA8B,EAAE;QAC1C,OAAO,IAAI,gBAAgB,CAAC,cAAc,EAAE,OAAO,CAAC;aAC/C,SAAS,CAAC,OAAO,EAAE,OAAO,CAAC,KAAK,EAC7B,CAAC,OAAO,EAAE,KAAK,KAAK,gBAAg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E,EAAE,IAAI,CAAC,CAAC,CAAC;KACrF;;AAbD;AACO,kCAAY,GAAG,mBAAmB,CAAC;AAgB5C;MACa,yBAA0B,SAAQ,oBAAoB;;;;;;;IAUjE,OAAO,IAAI,CAAC,UAAuC,EAAE;QAEnD,OAAO,IAAI,gBAAgB,CAAC,yBAAyB,EAAE,OAAO,CAAC;aAC1D,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;;AAdD;AACO,sCAAY,GAAG,uBAAuB;;AC9C/C;;;;;;;;ACAA;;;;;;;;;;"}
1
+ {"version":3,"file":"testing.mjs","sources":["../../../../../../../src/material/stepper/testing/step-harness.ts","../../../../../../../src/material/stepper/testing/stepper-harness.ts","../../../../../../../src/material/stepper/testing/stepper-button-harnesses.ts","../../../../../../../src/material/stepper/testing/public-api.ts","../../../../../../../src/material/stepper/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 {\n ContentContainerComponentHarness,\n HarnessPredicate,\n HarnessLoader,\n} from '@angular/cdk/testing';\nimport {StepHarnessFilters} from './step-harness-filters';\n\n/** Harness for interacting with a standard Angular Material step in tests. */\nexport class MatStepHarness extends ContentContainerComponentHarness<string> {\n /** The selector for the host element of a `MatStep` instance. */\n static hostSelector = '.mat-step-header';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatStepHarness` that meets\n * certain criteria.\n * @param options Options for filtering which steps are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: StepHarnessFilters = {}): HarnessPredicate<MatStepHarness> {\n return new HarnessPredicate(MatStepHarness, options)\n .addOption('label', options.label, (harness, label) =>\n HarnessPredicate.stringMatches(harness.getLabel(), label),\n )\n .addOption(\n 'selected',\n options.selected,\n async (harness, selected) => (await harness.isSelected()) === selected,\n )\n .addOption(\n 'completed',\n options.completed,\n async (harness, completed) => (await harness.isCompleted()) === completed,\n )\n .addOption(\n 'invalid',\n options.invalid,\n async (harness, invalid) => (await harness.hasErrors()) === invalid,\n );\n }\n\n /** Gets the label of the step. */\n async getLabel(): Promise<string> {\n return (await this.locatorFor('.mat-step-text-label')()).text();\n }\n\n /** Gets the `aria-label` of the step. */\n async getAriaLabel(): Promise<string | null> {\n return (await this.host()).getAttribute('aria-label');\n }\n\n /** Gets the value of the `aria-labelledby` attribute. */\n async getAriaLabelledby(): Promise<string | null> {\n return (await this.host()).getAttribute('aria-labelledby');\n }\n\n /** Whether the step is selected. */\n async isSelected(): Promise<boolean> {\n const host = await this.host();\n return (await host.getAttribute('aria-selected')) === 'true';\n }\n\n /** Whether the step has been filled out. */\n async isCompleted(): Promise<boolean> {\n const state = await this._getIconState();\n return state === 'done' || (state === 'edit' && !(await this.isSelected()));\n }\n\n /**\n * Whether the step is currently showing its error state. Note that this doesn't mean that there\n * are or aren't any invalid form controls inside the step, but that the step is showing its\n * error-specific styling which depends on there being invalid controls, as well as the\n * `ErrorStateMatcher` determining that an error should be shown and that the `showErrors`\n * option was enabled through the `STEPPER_GLOBAL_OPTIONS` injection token.\n */\n async hasErrors(): Promise<boolean> {\n return (await this._getIconState()) === 'error';\n }\n\n /** Whether the step is optional. */\n async isOptional(): Promise<boolean> {\n // If the node with the optional text is present, it means that the step is optional.\n const optionalNode = await this.locatorForOptional('.mat-step-optional')();\n return !!optionalNode;\n }\n\n /**\n * Selects the given step by clicking on the label. The step may not be selected\n * if the stepper doesn't allow it (e.g. if there are validation errors).\n */\n async select(): Promise<void> {\n await (await this.host()).click();\n }\n\n protected override async getRootHarnessLoader(): Promise<HarnessLoader> {\n const contentId = await (await this.host()).getAttribute('aria-controls');\n return this.documentRootLocatorFactory().harnessLoaderFor(`#${contentId}`);\n }\n\n /**\n * Gets the state of the step. Note that we have a `StepState` which we could use to type the\n * return value, but it's basically the same as `string`, because the type has `| string`.\n */\n private async _getIconState(): Promise<string> {\n // The state is exposed on the icon with a class that looks like `mat-step-icon-state-{{state}}`\n const icon = await this.locatorFor('.mat-step-icon')();\n const classes = (await icon.getAttribute('class'))!;\n const match = classes.match(/mat-step-icon-state-([a-z]+)/);\n\n if (!match) {\n throw Error(`Could not determine step state from \"${classes}\".`);\n }\n\n return match[1];\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 {ComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {MatStepHarness} from './step-harness';\nimport {\n StepperHarnessFilters,\n StepHarnessFilters,\n StepperOrientation,\n} from './step-harness-filters';\n\n/** Harness for interacting with a standard Material stepper in tests. */\nexport class MatStepperHarness extends ComponentHarness {\n /** The selector for the host element of a `MatStepper` instance. */\n static hostSelector = '.mat-stepper-horizontal, .mat-stepper-vertical';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatStepperHarness` that meets\n * certain criteria.\n * @param options Options for filtering which stepper instances are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: StepperHarnessFilters = {}): HarnessPredicate<MatStepperHarness> {\n return new HarnessPredicate(MatStepperHarness, options).addOption(\n 'orientation',\n options.orientation,\n async (harness, orientation) => (await harness.getOrientation()) === orientation,\n );\n }\n\n /**\n * Gets the list of steps in the stepper.\n * @param filter Optionally filters which steps are included.\n */\n async getSteps(filter: StepHarnessFilters = {}): Promise<MatStepHarness[]> {\n return this.locatorForAll(MatStepHarness.with(filter))();\n }\n\n /** Gets the orientation of the stepper. */\n async getOrientation(): Promise<StepperOrientation> {\n const host = await this.host();\n return (await host.hasClass('mat-stepper-horizontal'))\n ? StepperOrientation.HORIZONTAL\n : StepperOrientation.VERTICAL;\n }\n\n /**\n * Selects a step in this stepper.\n * @param filter An optional filter to apply to the child steps. The first step matching the\n * filter will be selected.\n */\n async selectStep(filter: StepHarnessFilters = {}): Promise<void> {\n const steps = await this.getSteps(filter);\n if (!steps.length) {\n throw Error(`Cannot find mat-step matching filter ${JSON.stringify(filter)}`);\n }\n await steps[0].select();\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 {ComponentHarness, HarnessPredicate} from '@angular/cdk/testing';\nimport {StepperButtonHarnessFilters} from './step-harness-filters';\n\n/** Base class for stepper button harnesses. */\nabstract class StepperButtonHarness extends ComponentHarness {\n /** Gets the text of the button. */\n async getText(): Promise<string> {\n return (await this.host()).text();\n }\n\n /** Clicks the button. */\n async click(): Promise<void> {\n return (await this.host()).click();\n }\n}\n\n/** Harness for interacting with a standard Angular Material stepper next button in tests. */\nexport class MatStepperNextHarness extends StepperButtonHarness {\n /** The selector for the host element of a `MatStep` instance. */\n static hostSelector = '.mat-stepper-next';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatStepperNextHarness` that meets\n * certain criteria.\n * @param options Options for filtering which steps are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(options: StepperButtonHarnessFilters = {}): HarnessPredicate<MatStepperNextHarness> {\n return new HarnessPredicate(MatStepperNextHarness, options).addOption(\n 'text',\n options.text,\n (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text),\n );\n }\n}\n\n/** Harness for interacting with a standard Angular Material stepper previous button in tests. */\nexport class MatStepperPreviousHarness extends StepperButtonHarness {\n /** The selector for the host element of a `MatStep` instance. */\n static hostSelector = '.mat-stepper-previous';\n\n /**\n * Gets a `HarnessPredicate` that can be used to search for a `MatStepperPreviousHarness`\n * that meets certain criteria.\n * @param options Options for filtering which steps are considered a match.\n * @return a `HarnessPredicate` configured with the given options.\n */\n static with(\n options: StepperButtonHarnessFilters = {},\n ): HarnessPredicate<MatStepperPreviousHarness> {\n return new HarnessPredicate(MatStepperPreviousHarness, options).addOption(\n 'text',\n options.text,\n (harness, text) => HarnessPredicate.stringMatches(harness.getText(), text),\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\nexport * from './stepper-harness';\nexport * from './step-harness';\nexport * from './step-harness-filters';\nexport * from './stepper-button-harnesses';\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;;;;;;;AAeA;MACa,cAAe,SAAQ,gCAAwC;;;;;;;IAU1E,OAAO,IAAI,CAAC,UAA8B,EAAE;QAC1C,OAAO,IAAI,gBAAgB,CAAC,cAAc,EAAE,OAAO,CAAC;aACjD,SAAS,CAAC,OAAO,EAAE,OAAO,CAAC,KAAK,EAAE,CAAC,OAAO,EAAE,KAAK,KAChD,gBAAgB,CAAC,aAAa,CAAC,OAAO,CAAC,QAAQ,EAAE,EAAE,KAAK,CAAC,CAC1D;aACA,SAAS,CACR,UAAU,EACV,OAAO,CAAC,QAAQ,EAChB,OAAO,OAAO,EAAE,QAAQ,KAAK,CAAC,MAAM,OAAO,CAAC,UAAU,EAAE,MAAM,QAAQ,CACvE;aACA,SAAS,CACR,WAAW,EACX,OAAO,CAAC,SAAS,EACjB,OAAO,OAAO,EAAE,SAAS,KAAK,CAAC,MAAM,OAAO,CAAC,WAAW,EAAE,MAAM,SAAS,CAC1E;aACA,SAAS,CACR,SAAS,EACT,OAAO,CAAC,OAAO,EACf,OAAO,OAAO,EAAE,OAAO,KAAK,CAAC,MAAM,OAAO,CAAC,SAAS,EAAE,MAAM,OAAO,CACpE,CAAC;KACL;;IAGD,MAAM,QAAQ;QACZ,OAAO,CAAC,MAAM,IAAI,CAAC,UAAU,CAAC,sBAAsB,CAAC,EAAE,EAAE,IAAI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