@angular/material 16.0.2 → 16.1.0-next.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.
- package/autocomplete/index.d.ts +28 -0
- package/autocomplete/testing/index.d.ts +3 -1
- package/chips/_chips-theme.scss +44 -60
- package/core/mdc-helpers/_mdc-helpers.scss +6 -6
- package/core/tokens/m2/mdc/_chip.scss +313 -0
- package/core/tokens/m2/mdc/_plain-tooltip.scss +80 -0
- package/esm2022/autocomplete/autocomplete-trigger.mjs +58 -3
- package/esm2022/autocomplete/testing/autocomplete-harness.mjs +5 -1
- package/esm2022/chips/chip-option.mjs +2 -2
- package/esm2022/chips/chip-row.mjs +2 -2
- package/esm2022/chips/chip.mjs +2 -2
- package/esm2022/core/option/option.mjs +3 -3
- package/esm2022/core/version.mjs +1 -1
- package/esm2022/form-field/directives/floating-label.mjs +66 -5
- package/esm2022/form-field/directives/notched-outline.mjs +14 -16
- package/esm2022/form-field/form-field.mjs +30 -36
- package/esm2022/legacy-tooltip/testing/tooltip-harness.mjs +2 -1
- package/esm2022/legacy-tooltip/tooltip.mjs +3 -2
- package/esm2022/select/select.mjs +60 -4
- package/esm2022/snack-bar/snack-bar-container.mjs +4 -2
- package/esm2022/tabs/tab-group.mjs +3 -2
- package/esm2022/tabs/tab-header.mjs +2 -2
- package/esm2022/tabs/tab-nav-bar/tab-nav-bar.mjs +12 -3
- package/esm2022/tooltip/testing/tooltip-harness.mjs +7 -1
- package/esm2022/tooltip/tooltip.mjs +5 -4
- package/fesm2022/autocomplete/testing.mjs +4 -0
- package/fesm2022/autocomplete/testing.mjs.map +1 -1
- package/fesm2022/autocomplete.mjs +57 -3
- package/fesm2022/autocomplete.mjs.map +1 -1
- package/fesm2022/chips.mjs +6 -6
- package/fesm2022/chips.mjs.map +1 -1
- package/fesm2022/core.mjs +3 -3
- package/fesm2022/core.mjs.map +1 -1
- package/fesm2022/form-field.mjs +102 -50
- package/fesm2022/form-field.mjs.map +1 -1
- package/fesm2022/legacy-tooltip/testing.mjs +1 -0
- package/fesm2022/legacy-tooltip/testing.mjs.map +1 -1
- package/fesm2022/legacy-tooltip.mjs +2 -1
- package/fesm2022/legacy-tooltip.mjs.map +1 -1
- package/fesm2022/select.mjs +59 -3
- package/fesm2022/select.mjs.map +1 -1
- package/fesm2022/snack-bar.mjs +3 -1
- package/fesm2022/snack-bar.mjs.map +1 -1
- package/fesm2022/tabs.mjs +15 -5
- package/fesm2022/tabs.mjs.map +1 -1
- package/fesm2022/tooltip/testing.mjs +6 -0
- package/fesm2022/tooltip/testing.mjs.map +1 -1
- package/fesm2022/tooltip.mjs +4 -3
- package/fesm2022/tooltip.mjs.map +1 -1
- package/form-field/index.d.ts +44 -12
- package/legacy-tooltip/testing/index.d.ts +1 -0
- package/package.json +7 -7
- package/prebuilt-themes/deeppurple-amber.css +1 -1
- package/prebuilt-themes/indigo-pink.css +1 -1
- package/prebuilt-themes/pink-bluegrey.css +1 -1
- package/prebuilt-themes/purple-green.css +1 -1
- package/schematics/ng-add/index.js +2 -2
- package/schematics/ng-add/index.mjs +2 -2
- package/select/index.d.ts +28 -0
- package/tabs/_tabs-common.scss +4 -0
- package/tabs/index.d.ts +4 -1
- package/tooltip/_tooltip-theme.scss +18 -22
- package/tooltip/testing/index.d.ts +4 -0
package/select/index.d.ts
CHANGED
|
@@ -287,6 +287,34 @@ export declare abstract class _MatSelectBase<C> extends _MatSelectMixinBase impl
|
|
|
287
287
|
toggle(): void;
|
|
288
288
|
/** Opens the overlay panel. */
|
|
289
289
|
open(): void;
|
|
290
|
+
/**
|
|
291
|
+
* Track which modal we have modified the `aria-owns` attribute of. When the combobox trigger is
|
|
292
|
+
* inside an aria-modal, we apply aria-owns to the parent modal with the `id` of the options
|
|
293
|
+
* panel. Track the modal we have changed so we can undo the changes on destroy.
|
|
294
|
+
*/
|
|
295
|
+
private _trackedModal;
|
|
296
|
+
/**
|
|
297
|
+
* If the autocomplete trigger is inside of an `aria-modal` element, connect
|
|
298
|
+
* that modal to the options panel with `aria-owns`.
|
|
299
|
+
*
|
|
300
|
+
* For some browser + screen reader combinations, when navigation is inside
|
|
301
|
+
* of an `aria-modal` element, the screen reader treats everything outside
|
|
302
|
+
* of that modal as hidden or invisible.
|
|
303
|
+
*
|
|
304
|
+
* This causes a problem when the combobox trigger is _inside_ of a modal, because the
|
|
305
|
+
* options panel is rendered _outside_ of that modal, preventing screen reader navigation
|
|
306
|
+
* from reaching the panel.
|
|
307
|
+
*
|
|
308
|
+
* We can work around this issue by applying `aria-owns` to the modal with the `id` of
|
|
309
|
+
* the options panel. This effectively communicates to assistive technology that the
|
|
310
|
+
* options panel is part of the same interaction as the modal.
|
|
311
|
+
*
|
|
312
|
+
* At time of this writing, this issue is present in VoiceOver.
|
|
313
|
+
* See https://github.com/angular/components/issues/20694
|
|
314
|
+
*/
|
|
315
|
+
private _applyModalPanelOwnership;
|
|
316
|
+
/** Clears the reference to the listbox overlay element from the modal it was added to. */
|
|
317
|
+
private _clearFromModal;
|
|
290
318
|
/** Closes the overlay panel and focuses the host element. */
|
|
291
319
|
close(): void;
|
|
292
320
|
/**
|
package/tabs/_tabs-common.scss
CHANGED
|
@@ -217,6 +217,10 @@ $mat-tab-animation-duration: 500ms !default;
|
|
|
217
217
|
tokens-mat-tab-header.$prefix, tokens-mat-tab-header.get-unthemable-tokens());
|
|
218
218
|
}
|
|
219
219
|
|
|
220
|
+
.mdc-tab-indicator .mdc-tab-indicator__content {
|
|
221
|
+
transition-duration: var(--mat-tab-animation-duration, 250ms);
|
|
222
|
+
}
|
|
223
|
+
|
|
220
224
|
.mat-mdc-tab-header-pagination {
|
|
221
225
|
@include vendor-prefixes.user-select(none);
|
|
222
226
|
position: relative;
|
package/tabs/index.d.ts
CHANGED
|
@@ -896,6 +896,9 @@ export declare class MatTabNav extends _MatTabNavBase implements AfterContentIni
|
|
|
896
896
|
get stretchTabs(): boolean;
|
|
897
897
|
set stretchTabs(v: BooleanInput);
|
|
898
898
|
private _stretchTabs;
|
|
899
|
+
get animationDuration(): string;
|
|
900
|
+
set animationDuration(value: NumberInput);
|
|
901
|
+
private _animationDuration;
|
|
899
902
|
_items: QueryList<MatTabLink>;
|
|
900
903
|
_tabListContainer: ElementRef;
|
|
901
904
|
_tabList: ElementRef;
|
|
@@ -907,7 +910,7 @@ export declare class MatTabNav extends _MatTabNavBase implements AfterContentIni
|
|
|
907
910
|
ngAfterContentInit(): void;
|
|
908
911
|
ngAfterViewInit(): void;
|
|
909
912
|
static ɵfac: i0.ɵɵFactoryDeclaration<MatTabNav, [null, { optional: true; }, null, null, null, null, { optional: true; }, { optional: true; }]>;
|
|
910
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<MatTabNav, "[mat-tab-nav-bar]", ["matTabNavBar", "matTabNav"], { "color": { "alias": "color"; "required": false; }; "fitInkBarToContent": { "alias": "fitInkBarToContent"; "required": false; }; "stretchTabs": { "alias": "mat-stretch-tabs"; "required": false; }; }, {}, ["_items"], ["*"], false, never>;
|
|
913
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<MatTabNav, "[mat-tab-nav-bar]", ["matTabNavBar", "matTabNav"], { "color": { "alias": "color"; "required": false; }; "fitInkBarToContent": { "alias": "fitInkBarToContent"; "required": false; }; "stretchTabs": { "alias": "mat-stretch-tabs"; "required": false; }; "animationDuration": { "alias": "animationDuration"; "required": false; }; }, {}, ["_items"], ["*"], false, never>;
|
|
911
914
|
}
|
|
912
915
|
|
|
913
916
|
/**
|
|
@@ -1,41 +1,37 @@
|
|
|
1
|
-
@use '
|
|
2
|
-
@use '@material/tooltip/plain-tooltip-theme';
|
|
3
|
-
@use '@material/theme/theme-color' as mdc-theme-color;
|
|
4
|
-
@use '@material/typography/typography' as mdc-typography;
|
|
1
|
+
@use '@material/tooltip/plain-tooltip-theme' as mdc-plain-tooltip-theme;
|
|
5
2
|
@use '../core/theming/theming';
|
|
6
|
-
@use '../core/theming/palette';
|
|
7
|
-
@use '../core/mdc-helpers/mdc-helpers';
|
|
8
3
|
@use '../core/typography/typography';
|
|
4
|
+
@use '../core/tokens/m2/mdc/plain-tooltip' as m2-mdc-plain-tooltip;
|
|
9
5
|
|
|
10
6
|
@mixin color($config-or-theme) {
|
|
11
7
|
$config: theming.get-color-config($config-or-theme);
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
));
|
|
18
|
-
}
|
|
8
|
+
$mdc-tooltip-color-tokens: m2-mdc-plain-tooltip.get-color-tokens($config);
|
|
9
|
+
|
|
10
|
+
// Add values for MDC tooltip tokens.
|
|
11
|
+
.mat-mdc-tooltip {
|
|
12
|
+
@include mdc-plain-tooltip-theme.theme($mdc-tooltip-color-tokens);
|
|
19
13
|
}
|
|
20
14
|
}
|
|
21
15
|
|
|
22
16
|
@mixin typography($config-or-theme) {
|
|
23
17
|
$config: typography.private-typography-to-2018-config(
|
|
24
18
|
theming.get-typography-config($config-or-theme));
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
supporting-text-weight: mdc-typography.get-weight(caption),
|
|
31
|
-
supporting-text-tracking: mdc-typography.get-tracking(caption),
|
|
32
|
-
));
|
|
33
|
-
}
|
|
19
|
+
$mdc-tooltip-typography-tokens: m2-mdc-plain-tooltip.get-typography-tokens($config);
|
|
20
|
+
|
|
21
|
+
// Add values for MDC tooltip tokens.
|
|
22
|
+
.mat-mdc-tooltip {
|
|
23
|
+
@include mdc-plain-tooltip-theme.theme($mdc-tooltip-typography-tokens);
|
|
34
24
|
}
|
|
35
25
|
}
|
|
36
26
|
|
|
37
27
|
@mixin density($config-or-theme) {
|
|
38
28
|
$density-scale: theming.get-density-config($config-or-theme);
|
|
29
|
+
$mdc-tooltip-density-tokens: m2-mdc-plain-tooltip.get-density-tokens($density-scale);
|
|
30
|
+
|
|
31
|
+
// Add values for MDC tooltip tokens.
|
|
32
|
+
.mat-mdc-tooltip {
|
|
33
|
+
@include mdc-plain-tooltip-theme.theme($mdc-tooltip-density-tokens);
|
|
34
|
+
}
|
|
39
35
|
}
|
|
40
36
|
|
|
41
37
|
@mixin theme($theme-or-color-config) {
|
|
@@ -10,6 +10,7 @@ export declare class MatTooltipHarness extends _MatTooltipHarnessBase {
|
|
|
10
10
|
protected _optionalPanel: AsyncFactoryFn<TestElement | null>;
|
|
11
11
|
static hostSelector: string;
|
|
12
12
|
protected _hiddenClass: string;
|
|
13
|
+
protected _disabledClass: string;
|
|
13
14
|
protected _showAnimationName: string;
|
|
14
15
|
protected _hideAnimationName: string;
|
|
15
16
|
/**
|
|
@@ -24,6 +25,7 @@ export declare class MatTooltipHarness extends _MatTooltipHarnessBase {
|
|
|
24
25
|
export declare abstract class _MatTooltipHarnessBase extends ComponentHarness {
|
|
25
26
|
protected abstract _optionalPanel: AsyncFactoryFn<TestElement | null>;
|
|
26
27
|
protected abstract _hiddenClass: string;
|
|
28
|
+
protected abstract _disabledClass: string;
|
|
27
29
|
protected abstract _showAnimationName: string;
|
|
28
30
|
protected abstract _hideAnimationName: string;
|
|
29
31
|
/** Shows the tooltip. */
|
|
@@ -32,6 +34,8 @@ export declare abstract class _MatTooltipHarnessBase extends ComponentHarness {
|
|
|
32
34
|
hide(): Promise<void>;
|
|
33
35
|
/** Gets whether the tooltip is open. */
|
|
34
36
|
isOpen(): Promise<boolean>;
|
|
37
|
+
/** Gets whether the tooltip is disabled */
|
|
38
|
+
isDisabled(): Promise<boolean>;
|
|
35
39
|
/** Gets a promise for the tooltip panel's text. */
|
|
36
40
|
getTooltipText(): Promise<string>;
|
|
37
41
|
}
|