@angular/material 18.0.3 → 18.0.5

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 (136) hide show
  1. package/autocomplete/index.d.ts +3 -0
  2. package/bottom-sheet/index.d.ts +0 -1
  3. package/button/_button-base.scss +3 -1
  4. package/button/index.d.ts +7 -1
  5. package/button-toggle/index.d.ts +2 -2
  6. package/checkbox/index.d.ts +5 -3
  7. package/chips/index.d.ts +9 -5
  8. package/core/_core-theme.scss +8 -14
  9. package/core/_core.scss +18 -4
  10. package/core/style/_vendor-prefixes.scss +5 -0
  11. package/core/tokens/_density.scss +2 -1
  12. package/core/tokens/m2/_index.scss +2 -2
  13. package/core/tokens/m2/mat/_app.scss +13 -1
  14. package/core/tokens/m2/mat/_menu.scss +3 -0
  15. package/core/tokens/m2/mat/_paginator.scss +1 -0
  16. package/core/tokens/m2/mdc/{_tab.scss → _secondary-navigation-tab.scss} +1 -1
  17. package/core/tokens/m3/_index.scss +2 -2
  18. package/core/tokens/m3/mat/_app.scss +9 -0
  19. package/core/tokens/m3/mat/_menu.scss +3 -0
  20. package/core/tokens/m3/mdc/{_tab.scss → _secondary-navigation-tab.scss} +1 -1
  21. package/datepicker/index.d.ts +17 -1
  22. package/esm2022/autocomplete/autocomplete-trigger.mjs +28 -1
  23. package/esm2022/bottom-sheet/bottom-sheet-container.mjs +6 -7
  24. package/esm2022/button/button-base.mjs +1 -1
  25. package/esm2022/button/button.mjs +4 -4
  26. package/esm2022/button/fab.mjs +8 -8
  27. package/esm2022/button/icon-button.mjs +4 -4
  28. package/esm2022/button-toggle/button-toggle.mjs +30 -21
  29. package/esm2022/checkbox/checkbox.mjs +1 -1
  30. package/esm2022/chips/chip-grid.mjs +11 -4
  31. package/esm2022/chips/chip-row.mjs +8 -13
  32. package/esm2022/chips/chip-set.mjs +7 -3
  33. package/esm2022/chips/chip.mjs +1 -1
  34. package/esm2022/core/option/optgroup.mjs +2 -2
  35. package/esm2022/core/option/option.mjs +3 -3
  36. package/esm2022/core/version.mjs +1 -1
  37. package/esm2022/datepicker/calendar.mjs +6 -3
  38. package/esm2022/datepicker/date-range-input-parts.mjs +14 -10
  39. package/esm2022/datepicker/date-range-input.mjs +17 -7
  40. package/esm2022/datepicker/datepicker-base.mjs +5 -1
  41. package/esm2022/datepicker/datepicker-input.mjs +16 -5
  42. package/esm2022/form-field/form-field.mjs +12 -6
  43. package/esm2022/icon/icon.mjs +8 -2
  44. package/esm2022/list/list-option.mjs +10 -4
  45. package/esm2022/list/selection-list.mjs +9 -2
  46. package/esm2022/menu/menu.mjs +13 -4
  47. package/esm2022/paginator/paginator.mjs +3 -3
  48. package/esm2022/progress-bar/progress-bar.mjs +10 -4
  49. package/esm2022/progress-spinner/progress-spinner.mjs +8 -2
  50. package/esm2022/radio/radio.mjs +12 -6
  51. package/esm2022/sidenav/drawer.mjs +4 -1
  52. package/esm2022/slide-toggle/slide-toggle-config.mjs +1 -1
  53. package/esm2022/slide-toggle/slide-toggle.mjs +1 -1
  54. package/esm2022/slider/slider.mjs +1 -1
  55. package/esm2022/stepper/step-header.mjs +1 -1
  56. package/esm2022/stepper/stepper.mjs +1 -1
  57. package/esm2022/tabs/tab-group.mjs +9 -4
  58. package/esm2022/tabs/tab-header.mjs +3 -3
  59. package/esm2022/tabs/tab-nav-bar/tab-nav-bar.mjs +19 -7
  60. package/esm2022/toolbar/toolbar.mjs +1 -1
  61. package/esm2022/tooltip/tooltip.mjs +3 -3
  62. package/fesm2022/autocomplete.mjs +27 -0
  63. package/fesm2022/autocomplete.mjs.map +1 -1
  64. package/fesm2022/bottom-sheet.mjs +5 -6
  65. package/fesm2022/bottom-sheet.mjs.map +1 -1
  66. package/fesm2022/button-toggle.mjs +29 -20
  67. package/fesm2022/button-toggle.mjs.map +1 -1
  68. package/fesm2022/button.mjs +16 -16
  69. package/fesm2022/button.mjs.map +1 -1
  70. package/fesm2022/checkbox.mjs.map +1 -1
  71. package/fesm2022/chips.mjs +15 -9
  72. package/fesm2022/chips.mjs.map +1 -1
  73. package/fesm2022/core.mjs +5 -5
  74. package/fesm2022/core.mjs.map +1 -1
  75. package/fesm2022/datepicker.mjs +42 -10
  76. package/fesm2022/datepicker.mjs.map +1 -1
  77. package/fesm2022/form-field.mjs +9 -3
  78. package/fesm2022/form-field.mjs.map +1 -1
  79. package/fesm2022/icon.mjs +7 -1
  80. package/fesm2022/icon.mjs.map +1 -1
  81. package/fesm2022/list.mjs +17 -4
  82. package/fesm2022/list.mjs.map +1 -1
  83. package/fesm2022/menu.mjs +12 -3
  84. package/fesm2022/menu.mjs.map +1 -1
  85. package/fesm2022/paginator.mjs +2 -2
  86. package/fesm2022/paginator.mjs.map +1 -1
  87. package/fesm2022/progress-bar.mjs +9 -3
  88. package/fesm2022/progress-bar.mjs.map +1 -1
  89. package/fesm2022/progress-spinner.mjs +7 -1
  90. package/fesm2022/progress-spinner.mjs.map +1 -1
  91. package/fesm2022/radio.mjs +11 -5
  92. package/fesm2022/radio.mjs.map +1 -1
  93. package/fesm2022/sidenav.mjs +4 -1
  94. package/fesm2022/sidenav.mjs.map +1 -1
  95. package/fesm2022/slide-toggle.mjs.map +1 -1
  96. package/fesm2022/slider.mjs.map +1 -1
  97. package/fesm2022/stepper.mjs.map +1 -1
  98. package/fesm2022/tabs.mjs +28 -11
  99. package/fesm2022/tabs.mjs.map +1 -1
  100. package/fesm2022/toolbar.mjs.map +1 -1
  101. package/fesm2022/tooltip.mjs +2 -2
  102. package/fesm2022/tooltip.mjs.map +1 -1
  103. package/form-field/index.d.ts +12 -2
  104. package/icon/index.d.ts +14 -2
  105. package/list/_list-theme.scss +8 -5
  106. package/list/index.d.ts +15 -2
  107. package/package.json +2 -2
  108. package/paginator/index.d.ts +7 -1
  109. package/prebuilt-themes/azure-blue.css +1 -1
  110. package/prebuilt-themes/cyan-orange.css +1 -1
  111. package/prebuilt-themes/deeppurple-amber.css +1 -1
  112. package/prebuilt-themes/indigo-pink.css +1 -1
  113. package/prebuilt-themes/magenta-violet.css +1 -1
  114. package/prebuilt-themes/pink-bluegrey.css +1 -1
  115. package/prebuilt-themes/purple-green.css +1 -1
  116. package/prebuilt-themes/rose-red.css +1 -1
  117. package/progress-bar/_progress-bar-theme.scss +10 -7
  118. package/progress-bar/index.d.ts +14 -2
  119. package/progress-spinner/index.d.ts +14 -2
  120. package/radio/_radio-common.scss +238 -0
  121. package/radio/_radio-theme.scss +25 -32
  122. package/radio/index.d.ts +21 -2
  123. package/schematics/ng-add/index.js +1 -1
  124. package/schematics/ng-add/index.mjs +1 -1
  125. package/schematics/ng-generate/m3-theme/index_bundled.js +2 -2
  126. package/schematics/ng-generate/table/files/__path__/__name@dasherize@if-flat__/__name@dasherize__.component.html.template +1 -1
  127. package/schematics/ng-update/index_bundled.js +31 -31
  128. package/sidenav/index.d.ts +1 -0
  129. package/slide-toggle/index.d.ts +14 -2
  130. package/slider/index.d.ts +7 -1
  131. package/stepper/index.d.ts +21 -3
  132. package/tabs/_tabs-common.scss +94 -36
  133. package/tabs/_tabs-theme.scss +33 -25
  134. package/tabs/index.d.ts +27 -4
  135. package/toolbar/index.d.ts +7 -1
  136. package/tooltip/_tooltip-theme.scss +18 -16
@@ -289,6 +289,9 @@ export declare class MatAutocompleteTrigger implements ControlValueAccessor, Aft
289
289
  private _closingActionsSubscription;
290
290
  /** Subscription to viewport size changes. */
291
291
  private _viewportSubscription;
292
+ /** Implements BreakpointObserver to be used to detect handset landscape */
293
+ private _breakpointObserver;
294
+ private _handsetLandscapeSubscription;
292
295
  /**
293
296
  * Whether the autocomplete can open the next time it is focused. Used to prevent a focused,
294
297
  * closed autocomplete from being reopened if the user switches to another browser tab and then
@@ -148,7 +148,6 @@ export declare class MatBottomSheetContainer extends CdkDialogContainer implemen
148
148
  _onAnimationDone(event: AnimationEvent_2): void;
149
149
  _onAnimationStart(event: AnimationEvent_2): void;
150
150
  protected _captureInitialFocus(): void;
151
- private _toggleClass;
152
151
  static ɵfac: i0.ɵɵFactoryDeclaration<MatBottomSheetContainer, [null, null, { optional: true; }, null, null, null, null, null, null]>;
153
152
  static ɵcmp: i0.ɵɵComponentDeclaration<MatBottomSheetContainer, "mat-bottom-sheet-container", never, {}, {}, never, never, true, never>;
154
153
  }
@@ -44,8 +44,10 @@
44
44
 
45
45
  // The content should appear over the state and ripple layers, otherwise they may adversely affect
46
46
  // the accessibility of the text content.
47
- .mdc-button__label {
47
+ .mdc-button__label,
48
+ .mat-icon {
48
49
  z-index: 1;
50
+ position: relative;
49
51
  }
50
52
 
51
53
  // The focus indicator should match the bounds of the entire button.
package/button/index.d.ts CHANGED
@@ -114,7 +114,13 @@ declare class MatButtonBase implements AfterViewInit, OnDestroy {
114
114
  */
115
115
  get ripple(): MatRipple;
116
116
  set ripple(v: MatRipple);
117
- /** Theme color palette of the button */
117
+ /**
118
+ * Theme color of the button. This API is supported in M2 themes only, it has
119
+ * no effect in M3 themes.
120
+ *
121
+ * For information on applying color variants in M3, see
122
+ * https://material.angular.io/guide/theming#using-component-color-variants.
123
+ */
118
124
  color?: string | null;
119
125
  /** Whether the ripple effect is disabled or not. */
120
126
  get disableRipple(): boolean;
@@ -243,8 +243,8 @@ export declare class MatButtonToggleGroup implements ControlValueAccessor, OnIni
243
243
  _isPrechecked(toggle: MatButtonToggle): boolean;
244
244
  /** Initializes the tabindex attribute using the radio pattern. */
245
245
  private _initializeTabIndex;
246
- /** Obtain the subsequent index to which the focus shifts. */
247
- private _getNextIndex;
246
+ /** Obtain the subsequent toggle to which the focus shifts. */
247
+ private _getNextButton;
248
248
  /** Updates the selection state of the toggles in the group based on a value. */
249
249
  private _setSelectionByValue;
250
250
  /** Clears the selected toggles. */
@@ -110,9 +110,11 @@ export declare class MatCheckbox implements AfterViewInit, OnChanges, ControlVal
110
110
  /** Tabindex for the checkbox. */
111
111
  tabIndex: number;
112
112
  /**
113
- * Palette color of the checkbox. This API is supported in M2 themes only, it has no effect in M3
114
- * themes. For information on applying color variants in M3, see
115
- * https://material.angular.io/guide/theming#using-component-color-variants
113
+ * Theme color of the checkbox. This API is supported in M2 themes only, it
114
+ * has no effect in M3 themes.
115
+ *
116
+ * For information on applying color variants in M3, see
117
+ * https://material.angular.io/guide/theming#using-component-color-variants.
116
118
  */
117
119
  color: string | undefined;
118
120
  /**
package/chips/index.d.ts CHANGED
@@ -13,6 +13,7 @@ import { FormGroupDirective } from '@angular/forms';
13
13
  import * as i0 from '@angular/core';
14
14
  import * as i1 from '@angular/material/core';
15
15
  import { InjectionToken } from '@angular/core';
16
+ import { Injector } from '@angular/core';
16
17
  import { MatFormField } from '@angular/material/form-field';
17
18
  import { MatFormFieldControl } from '@angular/material/form-field';
18
19
  import { MatRipple } from '@angular/material/core';
@@ -185,9 +186,11 @@ export declare class MatChip implements OnInit, AfterViewInit, AfterContentInit,
185
186
  set value(value: any);
186
187
  protected _value: any;
187
188
  /**
188
- * Theme color palette of the chip. This API is supported in M2 themes only, it has no effect in
189
- * M3 themes. For information on applying color variants in M3, see
190
- * https://material.angular.io/guide/theming#using-component-color-variants
189
+ * Theme color of the chip. This API is supported in M2 themes only, it has no
190
+ * effect in M3 themes.
191
+ *
192
+ * For information on applying color variants in M3, see
193
+ * https://material.angular.io/guide/theming#using-component-color-variants.
191
194
  */
192
195
  color?: string | null;
193
196
  /**
@@ -230,7 +233,7 @@ export declare class MatChip implements OnInit, AfterViewInit, AfterContentInit,
230
233
  * Used to improve initial load time of large applications.
231
234
  */
232
235
  _rippleLoader: MatRippleLoader;
233
- private _injector;
236
+ protected _injector: Injector;
234
237
  constructor(_changeDetectorRef: ChangeDetectorRef, _elementRef: ElementRef<HTMLElement>, _ngZone: NgZone, _focusMonitor: FocusMonitor, _document: any, animationMode?: string, _globalRippleOptions?: RippleGlobalOptions | undefined, tabIndex?: string);
235
238
  ngOnInit(): void;
236
239
  ngAfterViewInit(): void;
@@ -358,7 +361,7 @@ export declare interface MatChipEvent {
358
361
  * An extension of the MatChipSet component used with MatChipRow chips and
359
362
  * the matChipInputFor directive.
360
363
  */
361
- export declare class MatChipGrid extends MatChipSet implements AfterContentInit, AfterViewInit, ControlValueAccessor, DoCheck, MatFormFieldControl<any>, OnDestroy {
364
+ export declare class MatChipGrid extends MatChipSet implements AfterContentInit, AfterViewInit, ControlValueAccessor, DoCheck, MatFormFieldControl<any>, OnDestroy, OnInit {
362
365
  ngControl: NgControl;
363
366
  /**
364
367
  * Implemented as part of MatFormFieldControl.
@@ -451,6 +454,7 @@ export declare class MatChipGrid extends MatChipSet implements AfterContentInit,
451
454
  get errorState(): boolean;
452
455
  set errorState(value: boolean);
453
456
  constructor(elementRef: ElementRef, changeDetectorRef: ChangeDetectorRef, dir: Directionality, parentForm: NgForm, parentFormGroup: FormGroupDirective, defaultErrorStateMatcher: ErrorStateMatcher, ngControl: NgControl);
457
+ ngOnInit(): void;
454
458
  ngAfterContentInit(): void;
455
459
  ngAfterViewInit(): void;
456
460
  ngDoCheck(): void;
@@ -1,18 +1,17 @@
1
1
  @use './theming/theming';
2
2
  @use './theming/inspection';
3
3
  @use './theming/validation';
4
- @use './style/private';
5
4
  @use './ripple/ripple-theme';
6
5
  @use './option/option-theme';
7
6
  @use './option/optgroup-theme';
8
7
  @use './selection/pseudo-checkbox/pseudo-checkbox-theme';
9
- @use './style/elevation';
10
8
  @use './style/sass-utils';
11
9
  @use './typography/typography';
12
10
  @use './tokens/token-utils';
13
11
  @use './tokens/m2/mat/app' as tokens-mat-app;
14
12
  @use './tokens/m2/mat/ripple' as tokens-mat-ripple;
15
13
  @use './tokens/m2/mat/option' as tokens-mat-option;
14
+ @use './tokens/m2/mat/optgroup' as tokens-mat-optgroup;
16
15
  @use './tokens/m2/mat/full-pseudo-checkbox' as tokens-mat-full-pseudo-checkbox;
17
16
  @use './tokens/m2/mat/minimal-pseudo-checkbox' as tokens-mat-minimal-pseudo-checkbox;
18
17
 
@@ -41,6 +40,10 @@ $_has-inserted-loaded-marker: false;
41
40
  @include option-theme.base($theme);
42
41
  @include optgroup-theme.base($theme);
43
42
  @include pseudo-checkbox-theme.base($theme);
43
+ @include sass-utils.current-selector-or-root() {
44
+ @include token-utils.create-token-values(tokens-mat-app.$prefix,
45
+ tokens-mat-app.get-unthemable-tokens());
46
+ }
44
47
  }
45
48
 
46
49
  // The marker is a concrete style no matter which Material version we're targeting.
@@ -60,18 +63,6 @@ $_has-inserted-loaded-marker: false;
60
63
  @include token-utils.create-token-values(tokens-mat-app.$prefix,
61
64
  tokens-mat-app.get-color-tokens($theme));
62
65
  }
63
-
64
- // Provides external CSS classes for each elevation value. Each CSS class is formatted as
65
- // `mat-elevation-z$zValue` where `$zValue` corresponds to the z-space to which the element is
66
- // elevated.
67
- @for $zValue from 0 through 24 {
68
- $selector: elevation.$prefix + $zValue;
69
- // We need the `mat-mdc-elevation-specific`, because some MDC mixins
70
- // come with elevation baked in and we don't have a way of removing it.
71
- .#{$selector}, .mat-mdc-elevation-specific.#{$selector} {
72
- @include private.private-theme-elevation($zValue, $theme);
73
- }
74
- }
75
66
  }
76
67
  }
77
68
 
@@ -149,6 +140,8 @@ $_has-inserted-loaded-marker: false;
149
140
  $mat-app-tokens: token-utils.get-tokens-for($tokens, tokens-mat-app.$prefix, $options...);
150
141
  $mat-ripple-tokens: token-utils.get-tokens-for($tokens, tokens-mat-ripple.$prefix, $options...);
151
142
  $mat-option-tokens: token-utils.get-tokens-for($tokens, tokens-mat-option.$prefix, $options...);
143
+ $mat-optgroup-tokens:
144
+ token-utils.get-tokens-for($tokens, tokens-mat-optgroup.$prefix, $options...);
152
145
  $mat-full-pseudo-checkbox-tokens: token-utils.get-tokens-for($tokens,
153
146
  tokens-mat-full-pseudo-checkbox.$prefix, $options...);
154
147
  $mat-minimal-pseudo-checkbox-tokens: token-utils.get-tokens-for($tokens,
@@ -157,6 +150,7 @@ $_has-inserted-loaded-marker: false;
157
150
  @include token-utils.create-token-values(tokens-mat-app.$prefix, $mat-app-tokens);
158
151
  @include token-utils.create-token-values(tokens-mat-ripple.$prefix, $mat-ripple-tokens);
159
152
  @include token-utils.create-token-values(tokens-mat-option.$prefix, $mat-option-tokens);
153
+ @include token-utils.create-token-values(tokens-mat-optgroup.$prefix, $mat-optgroup-tokens);
160
154
  @include token-utils.create-token-values(tokens-mat-full-pseudo-checkbox.$prefix,
161
155
  $mat-full-pseudo-checkbox-tokens);
162
156
  @include token-utils.create-token-values(tokens-mat-minimal-pseudo-checkbox.$prefix,
package/core/_core.scss CHANGED
@@ -2,6 +2,7 @@
2
2
  @use './tokens/m2/mat/app' as tokens-mat-app;
3
3
  @use './tokens/token-utils';
4
4
  @use './ripple/ripple';
5
+ @use './style/elevation';
5
6
  @use './focus-indicators/private';
6
7
  @use './mdc-helpers/mdc-helpers';
7
8
 
@@ -18,13 +19,26 @@
18
19
  // Wrapper element that provides the theme background when the
19
20
  // user's content isn't inside of a `mat-sidenav-container`.
20
21
  @at-root {
21
- .mat-app-background {
22
- @include mdc-helpers.disable-mdc-fallback-declarations {
23
- @include token-utils.use-tokens(tokens-mat-app.$prefix, tokens-mat-app.get-token-slots()) {
24
- // Note: we need to emit fallback values here to avoid errors in internal builds.
22
+ // Note: we need to emit fallback values here to avoid errors in internal builds.
23
+ @include mdc-helpers.disable-mdc-fallback-declarations {
24
+ @include token-utils.use-tokens(tokens-mat-app.$prefix, tokens-mat-app.get-token-slots()) {
25
+ .mat-app-background {
25
26
  @include token-utils.create-token-slot(background-color, background-color, transparent);
26
27
  @include token-utils.create-token-slot(color, text-color, inherit);
27
28
  }
29
+
30
+ // Provides external CSS classes for each elevation value. Each CSS class is formatted as
31
+ // `mat-elevation-z$zValue` where `$zValue` corresponds to the z-space to which the element
32
+ // is elevated.
33
+ @for $zValue from 0 through 24 {
34
+ $selector: elevation.$prefix + $zValue;
35
+ // We need the `mat-mdc-elevation-specific`, because some MDC mixins
36
+ // come with elevation baked in and we don't have a way of removing it.
37
+ .#{$selector}, .mat-mdc-elevation-specific.#{$selector} {
38
+ @include token-utils.create-token-slot(box-shadow, 'elevation-shadow-level-#{$zValue}',
39
+ none);
40
+ }
41
+ }
28
42
  }
29
43
  }
30
44
  }
@@ -48,4 +48,9 @@
48
48
  -moz-osx-font-smoothing: grayscale;
49
49
  -webkit-font-smoothing: antialiased;
50
50
  }
51
+
52
+ @mixin mask-image($value) {
53
+ -webkit-mask-image: $value;
54
+ mask-image: $value;
55
+ }
51
56
  // stylelint-enable
@@ -60,7 +60,7 @@ $_density-tokens: (
60
60
  (mdc, slider): (),
61
61
  (mdc, snackbar): (),
62
62
  (mdc, switch): (),
63
- (mdc, tab): (
63
+ (mdc, secondary-navigation-tab): (
64
64
  container-height: (48px, 44px, 40px, 36px, 32px)
65
65
  ),
66
66
  (mdc, tab-indicator): (),
@@ -120,6 +120,7 @@ $_density-tokens: (
120
120
  container-size: (56px, 52px, 48px, 40px),
121
121
  form-field-container-height: (40px, 40px, 40px, 40px, 40px, 36px),
122
122
  form-field-container-vertical-padding: (8px, 8px, 8px, 8px, 8px, 6px),
123
+ touch-target-display: (block, block, none, none),
123
124
  ),
124
125
  (mat, radio): (
125
126
  touch-target-display: (block, block, none, none),
@@ -67,7 +67,7 @@
67
67
  @use './mdc/slider' as tokens-mdc-slider;
68
68
  @use './mdc/snack-bar' as tokens-mdc-snack-bar;
69
69
  @use './mdc/switch' as tokens-mdc-switch;
70
- @use './mdc/tab' as tokens-mdc-tab;
70
+ @use './mdc/secondary-navigation-tab' as tokens-mdc-secondary-navigation-tab;
71
71
  @use './mdc/tab-indicator' as tokens-mdc-tab-indicator;
72
72
  @use '../../theming/inspection';
73
73
 
@@ -179,7 +179,7 @@
179
179
  _get-tokens-for-module($theme, tokens-mdc-snack-bar),
180
180
  _get-tokens-for-module($theme, tokens-mdc-switch),
181
181
  _get-tokens-for-module($theme, tokens-mdc-tab-indicator),
182
- _get-tokens-for-module($theme, tokens-mdc-tab),
182
+ _get-tokens-for-module($theme, tokens-mdc-secondary-navigation-tab),
183
183
  _get-tokens-for-module($theme, tokens-mdc-text-button)
184
184
  );
185
185
  }
@@ -1,6 +1,9 @@
1
+ @use '@material/elevation/elevation-theme' as mdc-elevation;
2
+ @use 'sass:map';
1
3
  @use '../../token-utils';
2
4
  @use '../../../theming/inspection';
3
5
  @use '../../../style/sass-utils';
6
+ @use '../../../style/elevation';
4
7
 
5
8
  // The prefix used to generate the fully qualified name for tokens in this file.
6
9
  $prefix: (mat, app);
@@ -13,10 +16,19 @@ $prefix: (mat, app);
13
16
 
14
17
  // Tokens that can be configured through Angular Material's color theming API.
15
18
  @function get-color-tokens($theme) {
16
- @return (
19
+ $tokens: (
17
20
  background-color: inspection.get-theme-color($theme, background, background),
18
21
  text-color: inspection.get-theme-color($theme, foreground, text),
19
22
  );
23
+
24
+ @for $zValue from 0 through 24 {
25
+ $elevation-color: inspection.get-theme-color($theme, foreground, elevation);
26
+ $shadow: mdc-elevation.elevation-box-shadow($zValue,
27
+ if($elevation-color == null, elevation.$color, $elevation-color));
28
+ $tokens: map.set($tokens, 'elevation-shadow-level-#{$zValue}', $shadow);
29
+ }
30
+
31
+ @return $tokens;
20
32
  }
21
33
 
22
34
  // Tokens that can be configured through Angular Material's typography theming API.
@@ -18,6 +18,9 @@ $prefix: (mat, menu);
18
18
  item-trailing-spacing: 16px,
19
19
  item-with-icon-leading-spacing: 16px,
20
20
  item-with-icon-trailing-spacing: 16px,
21
+ // Note that this uses a value, rather than a computed box-shadow, because we use
22
+ // the value at runtime to determine which shadow to set based on the menu's depth.
23
+ base-elevation-level: 8,
21
24
  );
22
25
  }
23
26
 
@@ -69,6 +69,7 @@ $prefix: (mat, paginator);
69
69
  container-size: map.get($size-scale, $density-scale),
70
70
  form-field-container-height: $form-field-height,
71
71
  form-field-container-vertical-padding: $form-field-vertical-padding,
72
+ touch-target-display: if($density-scale < -2, none, block),
72
73
  );
73
74
  }
74
75
 
@@ -5,7 +5,7 @@
5
5
  @use '../../token-utils';
6
6
 
7
7
  // The prefix used to generate the fully qualified name for tokens in this file.
8
- $prefix: (mdc, tab);
8
+ $prefix: (mdc, secondary-navigation-tab);
9
9
 
10
10
  // Tokens that can't be configured through Angular Material's current theming API,
11
11
  // but may be in a future version of the theming API.
@@ -65,7 +65,7 @@
65
65
  @use './mdc/slider' as tokens-mdc-slider;
66
66
  @use './mdc/snack-bar' as tokens-mdc-snack-bar;
67
67
  @use './mdc/switch' as tokens-mdc-switch;
68
- @use './mdc/tab' as tokens-mdc-tab;
68
+ @use './mdc/secondary-navigation-tab' as tokens-mdc-secondary-navigation-tab;
69
69
  @use './mdc/tab-indicator' as tokens-mdc-tab-indicator;
70
70
 
71
71
  $_module-names: (
@@ -137,7 +137,7 @@ $_module-names: (
137
137
  tokens-mdc-slider,
138
138
  tokens-mdc-snack-bar,
139
139
  tokens-mdc-switch,
140
- tokens-mdc-tab,
140
+ tokens-mdc-secondary-navigation-tab,
141
141
  tokens-mdc-tab-indicator
142
142
  );
143
143
 
@@ -1,4 +1,5 @@
1
1
  @use 'sass:map';
2
+ @use '@material/elevation' as mdc-elevation;
2
3
  @use '../../token-utils';
3
4
 
4
5
  // The prefix used to generate the fully qualified name for tokens in this file.
@@ -10,10 +11,18 @@ $prefix: (mat, app);
10
11
  /// @param {Map} $token-slots Possible token slots
11
12
  /// @return {Map} A set of custom tokens for the app
12
13
  @function get-tokens($systems, $exclude-hardcoded, $token-slots) {
14
+ $shadow-color: map.get($systems, md-sys-color, shadow);
13
15
  $tokens: (
14
16
  background-color: map.get($systems, md-sys-color, background),
15
17
  text-color: map.get($systems, md-sys-color, on-background),
16
18
  );
17
19
 
20
+ @if ($shadow-color) {
21
+ @for $zValue from 0 through 24 {
22
+ $shadow: mdc-elevation.elevation-box-shadow($zValue, $shadow-color);
23
+ $tokens: map.set($tokens, 'elevation-shadow-level-#{$zValue}', $shadow);
24
+ }
25
+ }
26
+
18
27
  @return token-utils.namespace-tokens($prefix, $tokens, $token-slots);
19
28
  }
@@ -35,6 +35,9 @@ $prefix: (mat, menu);
35
35
  item-with-icon-leading-spacing: token-utils.hardcode(12px, $exclude-hardcoded),
36
36
  item-with-icon-trailing-spacing: token-utils.hardcode(12px, $exclude-hardcoded),
37
37
  container-color: map.get($systems, md-sys-color, surface-container),
38
+ // Note that this uses a value, rather than a computed box-shadow, because we use
39
+ // the value at runtime to determine which shadow to set based on the menu's depth.
40
+ base-elevation-level: token-utils.hardcode(2, $exclude-hardcoded),
38
41
  )
39
42
  );
40
43
 
@@ -1,7 +1,7 @@
1
1
  @use '../../token-utils';
2
2
 
3
3
  // The prefix used to generate the fully qualified name for tokens in this file.
4
- $prefix: (mdc, tab);
4
+ $prefix: (mdc, secondary-navigation-tab);
5
5
 
6
6
  /// Generates the tokens for MDC tab
7
7
  /// @param {Map} $systems The MDC system tokens
@@ -40,6 +40,7 @@ import { OnInit } from '@angular/core';
40
40
  import { Overlay } from '@angular/cdk/overlay';
41
41
  import { Portal } from '@angular/cdk/portal';
42
42
  import { ScrollStrategy } from '@angular/cdk/overlay';
43
+ import { Signal } from '@angular/core';
43
44
  import { SimpleChanges } from '@angular/core';
44
45
  import { Subject } from 'rxjs';
45
46
  import { TemplatePortal } from '@angular/cdk/portal';
@@ -49,6 +50,7 @@ import { ValidationErrors } from '@angular/forms';
49
50
  import { Validator } from '@angular/forms';
50
51
  import { ValidatorFn } from '@angular/forms';
51
52
  import { ViewContainerRef } from '@angular/core';
53
+ import { WritableSignal } from '@angular/core';
52
54
 
53
55
  /** Function that can be used to filter out dates from a calendar. */
54
56
  export declare type DateFilterFn<D> = (date: D | null) => boolean;
@@ -773,6 +775,7 @@ declare abstract class MatDatepickerBase<C extends MatDatepickerControl<D>, S, D
773
775
  /** Emits when the datepicker's state changes. */
774
776
  readonly stateChanges: Subject<void>;
775
777
  private _injector;
778
+ private readonly _changeDetectorRef;
776
779
  constructor(_overlay: Overlay,
777
780
  /**
778
781
  * @deprecated parameter is unused and will be removed
@@ -858,7 +861,13 @@ export declare class MatDatepickerContent<S, D = ExtractDateTypeFromSelection<S>
858
861
  private _model;
859
862
  /** Reference to the internal calendar component. */
860
863
  _calendar: MatCalendar<D>;
861
- /** Palette color of the internal calendar. */
864
+ /**
865
+ * Theme color of the internal calendar. This API is supported in M2 themes
866
+ * only, it has no effect in M3 themes.
867
+ *
868
+ * For information on applying color variants in M3, see
869
+ * https://material.angular.io/guide/theming#using-component-color-variants.
870
+ */
862
871
  color: ThemePalette;
863
872
  /** Reference to the datepicker that created the overlay. */
864
873
  datepicker: MatDatepickerBase<any, S, D>;
@@ -926,9 +935,12 @@ export declare interface MatDatepickerControl<D> {
926
935
  export declare class MatDatepickerInput<D> extends MatDatepickerInputBase<D | null, D> implements MatDatepickerControl<D | null>, OnDestroy {
927
936
  private _formField?;
928
937
  private _closedSubscription;
938
+ private _openedSubscription;
929
939
  /** The datepicker that this input is associated with. */
930
940
  set matDatepicker(datepicker: MatDatepickerPanel<MatDatepickerControl<D>, D | null, D>);
931
941
  _datepicker: MatDatepickerPanel<MatDatepickerControl<D>, D | null, D>;
942
+ /** The id of the panel owned by this input. */
943
+ protected _ariaOwns: WritableSignal<string | null>;
932
944
  /** The minimum valid date. */
933
945
  get min(): D | null;
934
946
  set min(value: D | null);
@@ -1215,6 +1227,7 @@ export declare class MatDateRangeInput<D> implements MatFormFieldControl<DateRan
1215
1227
  private _dateAdapter;
1216
1228
  private _formField?;
1217
1229
  private _closedSubscription;
1230
+ private _openedSubscription;
1218
1231
  /** Current value of the range input. */
1219
1232
  get value(): DateRange<D> | null;
1220
1233
  /** Unique ID for the group. */
@@ -1235,6 +1248,8 @@ export declare class MatDateRangeInput<D> implements MatFormFieldControl<DateRan
1235
1248
  get rangePicker(): MatDatepickerPanel<MatDatepickerControl<D>, DateRange<D>, D>;
1236
1249
  set rangePicker(rangePicker: MatDatepickerPanel<MatDatepickerControl<D>, DateRange<D>, D>);
1237
1250
  private _rangePicker;
1251
+ /** The id of the panel owned by this input. */
1252
+ _ariaOwns: WritableSignal<string | null>;
1238
1253
  /** Whether the input is required. */
1239
1254
  get required(): boolean;
1240
1255
  set required(value: boolean);
@@ -1344,6 +1359,7 @@ declare interface MatDateRangeInputParent<D> {
1344
1359
  opened: boolean;
1345
1360
  id: string;
1346
1361
  };
1362
+ _ariaOwns?: Signal<string | null>;
1347
1363
  _startInput: MatDateRangeInputPartBase<D>;
1348
1364
  _endInput: MatDateRangeInputPartBase<D>;
1349
1365
  _groupDisabled: boolean;