@angular/cdk 19.1.0-next.3 → 19.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/a11y/index.d.ts +3 -4
- package/drag-drop/index.d.ts +0 -4
- package/fesm2022/a11y.mjs +81 -82
- package/fesm2022/a11y.mjs.map +1 -1
- package/fesm2022/accordion.mjs +10 -10
- package/fesm2022/accordion.mjs.map +1 -1
- package/fesm2022/bidi.mjs +10 -10
- package/fesm2022/bidi.mjs.map +1 -1
- package/fesm2022/cdk.mjs +1 -1
- package/fesm2022/cdk.mjs.map +1 -1
- package/fesm2022/clipboard.mjs +10 -10
- package/fesm2022/clipboard.mjs.map +1 -1
- package/fesm2022/collections.mjs +3 -3
- package/fesm2022/collections.mjs.map +1 -1
- package/fesm2022/dialog.mjs +10 -10
- package/fesm2022/dialog.mjs.map +1 -1
- package/fesm2022/drag-drop.mjs +93 -86
- package/fesm2022/drag-drop.mjs.map +1 -1
- package/fesm2022/layout.mjs +10 -10
- package/fesm2022/layout.mjs.map +1 -1
- package/fesm2022/listbox.mjs +10 -10
- package/fesm2022/listbox.mjs.map +1 -1
- package/fesm2022/menu.mjs +78 -52
- package/fesm2022/menu.mjs.map +1 -1
- package/fesm2022/observers/private.mjs +3 -3
- package/fesm2022/observers/private.mjs.map +1 -1
- package/fesm2022/observers.mjs +13 -13
- package/fesm2022/observers.mjs.map +1 -1
- package/fesm2022/overlay.mjs +58 -51
- package/fesm2022/overlay.mjs.map +1 -1
- package/fesm2022/platform.mjs +7 -7
- package/fesm2022/platform.mjs.map +1 -1
- package/fesm2022/portal.mjs +16 -16
- package/fesm2022/portal.mjs.map +1 -1
- package/fesm2022/private.mjs +6 -6
- package/fesm2022/private.mjs.map +1 -1
- package/fesm2022/scrolling.mjs +36 -35
- package/fesm2022/scrolling.mjs.map +1 -1
- package/fesm2022/stepper.mjs +22 -22
- package/fesm2022/stepper.mjs.map +1 -1
- package/fesm2022/table.mjs +226 -182
- package/fesm2022/table.mjs.map +1 -1
- package/fesm2022/text-field.mjs +33 -29
- package/fesm2022/text-field.mjs.map +1 -1
- package/fesm2022/tree.mjs +47 -29
- package/fesm2022/tree.mjs.map +1 -1
- package/menu/index.d.ts +7 -1
- package/overlay/index.d.ts +1 -2
- package/package.json +3 -3
- package/schematics/ng-add/index.js +1 -1
- package/schematics/ng-add/index.mjs +1 -1
- package/table/index.d.ts +12 -1
- package/text-field/index.d.ts +0 -1
- package/tree/index.d.ts +2 -0
package/fesm2022/menu.mjs
CHANGED
|
@@ -4,7 +4,7 @@ import { Overlay, OverlayConfig, STANDARD_DROPDOWN_BELOW_POSITIONS, STANDARD_DRO
|
|
|
4
4
|
import { ENTER, SPACE, UP_ARROW, hasModifierKey, DOWN_ARROW, LEFT_ARROW, RIGHT_ARROW, TAB, ESCAPE } from '@angular/cdk/keycodes';
|
|
5
5
|
import { startWith, debounceTime, distinctUntilChanged, takeUntil, mergeMap, mapTo, mergeAll, switchMap, skipWhile, skip } from 'rxjs/operators';
|
|
6
6
|
import { UniqueSelectionDispatcher } from '@angular/cdk/collections';
|
|
7
|
-
import { _IdGenerator, InputModalityDetector, FocusKeyManager } from '@angular/cdk/a11y';
|
|
7
|
+
import { _IdGenerator, InputModalityDetector, FocusMonitor, FocusKeyManager } from '@angular/cdk/a11y';
|
|
8
8
|
import { Subject, merge, partition } from 'rxjs';
|
|
9
9
|
import { TemplatePortal } from '@angular/cdk/portal';
|
|
10
10
|
import { Directionality } from '@angular/cdk/bidi';
|
|
@@ -14,10 +14,10 @@ import { _getEventTarget } from '@angular/cdk/platform';
|
|
|
14
14
|
* A grouping container for `CdkMenuItemRadio` instances, similar to a `role="radiogroup"` element.
|
|
15
15
|
*/
|
|
16
16
|
class CdkMenuGroup {
|
|
17
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
18
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-
|
|
17
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuGroup, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
18
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkMenuGroup, isStandalone: true, selector: "[cdkMenuGroup]", host: { attributes: { "role": "group" }, classAttribute: "cdk-menu-group" }, providers: [{ provide: UniqueSelectionDispatcher, useClass: UniqueSelectionDispatcher }], exportAs: ["cdkMenuGroup"], ngImport: i0 });
|
|
19
19
|
}
|
|
20
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
20
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuGroup, decorators: [{
|
|
21
21
|
type: Directive,
|
|
22
22
|
args: [{
|
|
23
23
|
selector: '[cdkMenuGroup]',
|
|
@@ -174,10 +174,10 @@ class MenuStack {
|
|
|
174
174
|
setHasFocus(hasFocus) {
|
|
175
175
|
this._hasFocus.next(hasFocus);
|
|
176
176
|
}
|
|
177
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
178
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-
|
|
177
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: MenuStack, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
178
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: MenuStack });
|
|
179
179
|
}
|
|
180
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
180
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: MenuStack, decorators: [{
|
|
181
181
|
type: Injectable
|
|
182
182
|
}] });
|
|
183
183
|
|
|
@@ -286,10 +286,10 @@ class CdkMenuTriggerBase {
|
|
|
286
286
|
});
|
|
287
287
|
return this._childMenuInjector;
|
|
288
288
|
}
|
|
289
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
290
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-
|
|
289
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuTriggerBase, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
290
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkMenuTriggerBase, isStandalone: true, host: { properties: { "attr.aria-controls": "childMenu?.id", "attr.data-cdk-menu-stack-id": "menuStack.id" } }, ngImport: i0 });
|
|
291
291
|
}
|
|
292
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
292
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuTriggerBase, decorators: [{
|
|
293
293
|
type: Directive,
|
|
294
294
|
args: [{
|
|
295
295
|
host: {
|
|
@@ -491,10 +491,10 @@ class TargetMenuAim {
|
|
|
491
491
|
});
|
|
492
492
|
});
|
|
493
493
|
}
|
|
494
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
495
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-
|
|
494
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: TargetMenuAim, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
495
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: TargetMenuAim });
|
|
496
496
|
}
|
|
497
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
497
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: TargetMenuAim, decorators: [{
|
|
498
498
|
type: Injectable
|
|
499
499
|
}] });
|
|
500
500
|
/**
|
|
@@ -502,10 +502,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3",
|
|
|
502
502
|
* element with either the `cdkMenu` or `cdkMenuBar` directive and child menu items.
|
|
503
503
|
*/
|
|
504
504
|
class CdkTargetMenuAim {
|
|
505
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
506
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-
|
|
505
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkTargetMenuAim, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
506
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkTargetMenuAim, isStandalone: true, selector: "[cdkTargetMenuAim]", providers: [{ provide: MENU_AIM, useClass: TargetMenuAim }], exportAs: ["cdkTargetMenuAim"], ngImport: i0 });
|
|
507
507
|
}
|
|
508
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
508
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkTargetMenuAim, decorators: [{
|
|
509
509
|
type: Directive,
|
|
510
510
|
args: [{
|
|
511
511
|
selector: '[cdkTargetMenuAim]',
|
|
@@ -592,6 +592,11 @@ class CdkMenuTrigger extends CdkMenuTriggerBase {
|
|
|
592
592
|
getMenu() {
|
|
593
593
|
return this.childMenu;
|
|
594
594
|
}
|
|
595
|
+
ngOnChanges(changes) {
|
|
596
|
+
if (changes['menuPosition'] && this.overlayRef) {
|
|
597
|
+
this.overlayRef.updatePositionStrategy(this._getOverlayPositionStrategy());
|
|
598
|
+
}
|
|
599
|
+
}
|
|
595
600
|
ngOnDestroy() {
|
|
596
601
|
this._cleanupMouseenter();
|
|
597
602
|
super.ngOnDestroy();
|
|
@@ -796,13 +801,13 @@ class CdkMenuTrigger extends CdkMenuTriggerBase {
|
|
|
796
801
|
element.setAttribute('type', 'button');
|
|
797
802
|
}
|
|
798
803
|
}
|
|
799
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
800
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-
|
|
804
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuTrigger, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
805
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkMenuTrigger, isStandalone: true, selector: "[cdkMenuTriggerFor]", inputs: { menuTemplateRef: ["cdkMenuTriggerFor", "menuTemplateRef"], menuPosition: ["cdkMenuPosition", "menuPosition"], menuData: ["cdkMenuTriggerData", "menuData"] }, outputs: { opened: "cdkMenuOpened", closed: "cdkMenuClosed" }, host: { listeners: { "focusin": "_setHasFocus(true)", "focusout": "_setHasFocus(false)", "keydown": "_toggleOnKeydown($event)", "click": "_handleClick()" }, properties: { "attr.aria-haspopup": "menuTemplateRef ? \"menu\" : null", "attr.aria-expanded": "menuTemplateRef == null ? null : isOpen()" }, classAttribute: "cdk-menu-trigger" }, providers: [
|
|
801
806
|
{ provide: MENU_TRIGGER, useExisting: CdkMenuTrigger },
|
|
802
807
|
PARENT_OR_NEW_MENU_STACK_PROVIDER,
|
|
803
|
-
], exportAs: ["cdkMenuTriggerFor"], usesInheritance: true, ngImport: i0 });
|
|
808
|
+
], exportAs: ["cdkMenuTriggerFor"], usesInheritance: true, usesOnChanges: true, ngImport: i0 });
|
|
804
809
|
}
|
|
805
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
810
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuTrigger, decorators: [{
|
|
806
811
|
type: Directive,
|
|
807
812
|
args: [{
|
|
808
813
|
selector: '[cdkMenuTriggerFor]',
|
|
@@ -955,6 +960,12 @@ class CdkMenuItem {
|
|
|
955
960
|
case ENTER:
|
|
956
961
|
// Skip events that will trigger clicks so the handler doesn't get triggered twice.
|
|
957
962
|
if (!hasModifierKey(event) && !eventDispatchesNativeClick(this._elementRef, event)) {
|
|
963
|
+
const nodeName = this._elementRef.nativeElement.nodeName;
|
|
964
|
+
// Avoid repeat events on non-native elements (see #30250). Note that we don't do this
|
|
965
|
+
// on the native elements so we don't interfere with their behavior (see #26296).
|
|
966
|
+
if (nodeName !== 'A' && nodeName !== 'BUTTON') {
|
|
967
|
+
event.preventDefault();
|
|
968
|
+
}
|
|
958
969
|
this.trigger({ keepOpen: event.keyCode === SPACE && !this.closeOnSpacebarTrigger });
|
|
959
970
|
}
|
|
960
971
|
break;
|
|
@@ -1054,10 +1065,10 @@ class CdkMenuItem {
|
|
|
1054
1065
|
element.setAttribute('type', 'button');
|
|
1055
1066
|
}
|
|
1056
1067
|
}
|
|
1057
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1058
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "19.1.0-
|
|
1068
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuItem, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1069
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "19.1.0-rc.0", type: CdkMenuItem, isStandalone: true, selector: "[cdkMenuItem]", inputs: { disabled: ["cdkMenuItemDisabled", "disabled", booleanAttribute], typeaheadLabel: ["cdkMenuitemTypeaheadLabel", "typeaheadLabel"] }, outputs: { triggered: "cdkMenuItemTriggered" }, host: { attributes: { "role": "menuitem" }, listeners: { "blur": "_resetTabIndex()", "focus": "_setTabIndex()", "click": "trigger()", "keydown": "_onKeydown($event)" }, properties: { "tabindex": "_tabindex", "attr.aria-disabled": "disabled || null" }, classAttribute: "cdk-menu-item" }, exportAs: ["cdkMenuItem"], ngImport: i0 });
|
|
1059
1070
|
}
|
|
1060
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1071
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuItem, decorators: [{
|
|
1061
1072
|
type: Directive,
|
|
1062
1073
|
args: [{
|
|
1063
1074
|
selector: '[cdkMenuItem]',
|
|
@@ -1144,6 +1155,7 @@ class PointerFocusTracker {
|
|
|
1144
1155
|
* This class can be extended to create custom menu types.
|
|
1145
1156
|
*/
|
|
1146
1157
|
class CdkMenuBase extends CdkMenuGroup {
|
|
1158
|
+
_focusMonitor = inject(FocusMonitor);
|
|
1147
1159
|
ngZone = inject(NgZone);
|
|
1148
1160
|
_renderer = inject(Renderer2);
|
|
1149
1161
|
/** The menu's native DOM host element. */
|
|
@@ -1184,12 +1196,14 @@ class CdkMenuBase extends CdkMenuGroup {
|
|
|
1184
1196
|
this.menuStack.push(this);
|
|
1185
1197
|
}
|
|
1186
1198
|
this._setKeyManager();
|
|
1199
|
+
this._handleFocus();
|
|
1187
1200
|
this._subscribeToMenuStackHasFocus();
|
|
1188
1201
|
this._subscribeToMenuOpen();
|
|
1189
1202
|
this._subscribeToMenuStackClosed();
|
|
1190
1203
|
this._setUpPointerTracker();
|
|
1191
1204
|
}
|
|
1192
1205
|
ngOnDestroy() {
|
|
1206
|
+
this._focusMonitor.stopMonitoring(this.nativeElement);
|
|
1193
1207
|
this.keyManager?.destroy();
|
|
1194
1208
|
this.destroyed.next();
|
|
1195
1209
|
this.destroyed.complete();
|
|
@@ -1290,10 +1304,23 @@ class CdkMenuBase extends CdkMenuGroup {
|
|
|
1290
1304
|
this.menuAim.initialize(this, this.pointerTracker);
|
|
1291
1305
|
}
|
|
1292
1306
|
}
|
|
1293
|
-
|
|
1294
|
-
|
|
1307
|
+
/** Handles focus landing on the host element of the menu. */
|
|
1308
|
+
_handleFocus() {
|
|
1309
|
+
this._focusMonitor
|
|
1310
|
+
.monitor(this.nativeElement, false)
|
|
1311
|
+
.pipe(takeUntil(this.destroyed))
|
|
1312
|
+
.subscribe(origin => {
|
|
1313
|
+
// Don't forward focus on mouse interactions, because it can
|
|
1314
|
+
// mess with the user's scroll position. See #30130.
|
|
1315
|
+
if (origin !== null && origin !== 'mouse') {
|
|
1316
|
+
this.focusFirstItem(origin);
|
|
1317
|
+
}
|
|
1318
|
+
});
|
|
1319
|
+
}
|
|
1320
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuBase, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1321
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkMenuBase, isStandalone: true, inputs: { id: "id" }, host: { attributes: { "role": "menu" }, listeners: { "focusin": "menuStack.setHasFocus(true)", "focusout": "menuStack.setHasFocus(false)" }, properties: { "tabindex": "_getTabIndex()", "id": "id", "attr.aria-orientation": "orientation", "attr.data-cdk-menu-stack-id": "menuStack.id" } }, queries: [{ propertyName: "items", predicate: CdkMenuItem, descendants: true }], usesInheritance: true, ngImport: i0 });
|
|
1295
1322
|
}
|
|
1296
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1323
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuBase, decorators: [{
|
|
1297
1324
|
type: Directive,
|
|
1298
1325
|
args: [{
|
|
1299
1326
|
host: {
|
|
@@ -1303,7 +1330,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-next.3",
|
|
|
1303
1330
|
'[id]': 'id',
|
|
1304
1331
|
'[attr.aria-orientation]': 'orientation',
|
|
1305
1332
|
'[attr.data-cdk-menu-stack-id]': 'menuStack.id',
|
|
1306
|
-
'(focus)': 'focusFirstItem()',
|
|
1307
1333
|
'(focusin)': 'menuStack.setHasFocus(true)',
|
|
1308
1334
|
'(focusout)': 'menuStack.setHasFocus(false)',
|
|
1309
1335
|
},
|
|
@@ -1405,14 +1431,14 @@ class CdkMenu extends CdkMenuBase {
|
|
|
1405
1431
|
.pipe(takeUntil(this.destroyed))
|
|
1406
1432
|
.subscribe(event => this._toggleMenuFocus(event));
|
|
1407
1433
|
}
|
|
1408
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1409
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-
|
|
1434
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenu, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1435
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkMenu, isStandalone: true, selector: "[cdkMenu]", outputs: { closed: "closed" }, host: { attributes: { "role": "menu" }, listeners: { "keydown": "_handleKeyEvent($event)" }, properties: { "class.cdk-menu-inline": "isInline" }, classAttribute: "cdk-menu" }, providers: [
|
|
1410
1436
|
{ provide: CdkMenuGroup, useExisting: CdkMenu },
|
|
1411
1437
|
{ provide: CDK_MENU, useExisting: CdkMenu },
|
|
1412
1438
|
PARENT_OR_NEW_INLINE_MENU_STACK_PROVIDER('vertical'),
|
|
1413
1439
|
], exportAs: ["cdkMenu"], usesInheritance: true, ngImport: i0 });
|
|
1414
1440
|
}
|
|
1415
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1441
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenu, decorators: [{
|
|
1416
1442
|
type: Directive,
|
|
1417
1443
|
args: [{
|
|
1418
1444
|
selector: '[cdkMenu]',
|
|
@@ -1523,14 +1549,14 @@ class CdkMenuBar extends CdkMenuBase {
|
|
|
1523
1549
|
.pipe(takeUntil(this.destroyed))
|
|
1524
1550
|
.subscribe(event => this._toggleOpenMenu(event));
|
|
1525
1551
|
}
|
|
1526
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1527
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-
|
|
1552
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuBar, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1553
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkMenuBar, isStandalone: true, selector: "[cdkMenuBar]", host: { attributes: { "role": "menubar" }, listeners: { "keydown": "_handleKeyEvent($event)" }, classAttribute: "cdk-menu-bar" }, providers: [
|
|
1528
1554
|
{ provide: CdkMenuGroup, useExisting: CdkMenuBar },
|
|
1529
1555
|
{ provide: CDK_MENU, useExisting: CdkMenuBar },
|
|
1530
1556
|
{ provide: MENU_STACK, useFactory: () => MenuStack.inline('horizontal') },
|
|
1531
1557
|
], exportAs: ["cdkMenuBar"], usesInheritance: true, ngImport: i0 });
|
|
1532
1558
|
}
|
|
1533
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1559
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuBar, decorators: [{
|
|
1534
1560
|
type: Directive,
|
|
1535
1561
|
args: [{
|
|
1536
1562
|
selector: '[cdkMenuBar]',
|
|
@@ -1554,10 +1580,10 @@ class CdkMenuItemSelectable extends CdkMenuItem {
|
|
|
1554
1580
|
checked = false;
|
|
1555
1581
|
/** Whether the item should close the menu if triggered by the spacebar. */
|
|
1556
1582
|
closeOnSpacebarTrigger = false;
|
|
1557
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1558
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "19.1.0-
|
|
1583
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuItemSelectable, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1584
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "19.1.0-rc.0", type: CdkMenuItemSelectable, isStandalone: true, inputs: { checked: ["cdkMenuItemChecked", "checked", booleanAttribute] }, host: { properties: { "attr.aria-checked": "!!checked", "attr.aria-disabled": "disabled || null" } }, usesInheritance: true, ngImport: i0 });
|
|
1559
1585
|
}
|
|
1560
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1586
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuItemSelectable, decorators: [{
|
|
1561
1587
|
type: Directive,
|
|
1562
1588
|
args: [{
|
|
1563
1589
|
host: {
|
|
@@ -1607,13 +1633,13 @@ class CdkMenuItemRadio extends CdkMenuItemSelectable {
|
|
|
1607
1633
|
this.checked = this._id === id;
|
|
1608
1634
|
});
|
|
1609
1635
|
}
|
|
1610
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1611
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-
|
|
1636
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuItemRadio, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1637
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkMenuItemRadio, isStandalone: true, selector: "[cdkMenuItemRadio]", host: { attributes: { "role": "menuitemradio" }, properties: { "class.cdk-menu-item-radio": "true" } }, providers: [
|
|
1612
1638
|
{ provide: CdkMenuItemSelectable, useExisting: CdkMenuItemRadio },
|
|
1613
1639
|
{ provide: CdkMenuItem, useExisting: CdkMenuItemSelectable },
|
|
1614
1640
|
], exportAs: ["cdkMenuItemRadio"], usesInheritance: true, ngImport: i0 });
|
|
1615
1641
|
}
|
|
1616
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1642
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuItemRadio, decorators: [{
|
|
1617
1643
|
type: Directive,
|
|
1618
1644
|
args: [{
|
|
1619
1645
|
selector: '[cdkMenuItemRadio]',
|
|
@@ -1645,13 +1671,13 @@ class CdkMenuItemCheckbox extends CdkMenuItemSelectable {
|
|
|
1645
1671
|
this.checked = !this.checked;
|
|
1646
1672
|
}
|
|
1647
1673
|
}
|
|
1648
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1649
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-
|
|
1674
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuItemCheckbox, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
1675
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "19.1.0-rc.0", type: CdkMenuItemCheckbox, isStandalone: true, selector: "[cdkMenuItemCheckbox]", host: { attributes: { "role": "menuitemcheckbox" }, properties: { "class.cdk-menu-item-checkbox": "true" } }, providers: [
|
|
1650
1676
|
{ provide: CdkMenuItemSelectable, useExisting: CdkMenuItemCheckbox },
|
|
1651
1677
|
{ provide: CdkMenuItem, useExisting: CdkMenuItemSelectable },
|
|
1652
1678
|
], exportAs: ["cdkMenuItemCheckbox"], usesInheritance: true, ngImport: i0 });
|
|
1653
1679
|
}
|
|
1654
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1680
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuItemCheckbox, decorators: [{
|
|
1655
1681
|
type: Directive,
|
|
1656
1682
|
args: [{
|
|
1657
1683
|
selector: '[cdkMenuItemCheckbox]',
|
|
@@ -1689,10 +1715,10 @@ class ContextMenuTracker {
|
|
|
1689
1715
|
ContextMenuTracker._openContextMenuTrigger = trigger;
|
|
1690
1716
|
}
|
|
1691
1717
|
}
|
|
1692
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1693
|
-
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-
|
|
1718
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: ContextMenuTracker, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
1719
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: ContextMenuTracker, providedIn: 'root' });
|
|
1694
1720
|
}
|
|
1695
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1721
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: ContextMenuTracker, decorators: [{
|
|
1696
1722
|
type: Injectable,
|
|
1697
1723
|
args: [{ providedIn: 'root' }]
|
|
1698
1724
|
}] });
|
|
@@ -1842,13 +1868,13 @@ class CdkContextMenuTrigger extends CdkMenuTriggerBase {
|
|
|
1842
1868
|
this._subscribeToOutsideClicks(userEvent);
|
|
1843
1869
|
}
|
|
1844
1870
|
}
|
|
1845
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1846
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "19.1.0-
|
|
1871
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkContextMenuTrigger, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
1872
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "16.1.0", version: "19.1.0-rc.0", type: CdkContextMenuTrigger, isStandalone: true, selector: "[cdkContextMenuTriggerFor]", inputs: { menuTemplateRef: ["cdkContextMenuTriggerFor", "menuTemplateRef"], menuPosition: ["cdkContextMenuPosition", "menuPosition"], menuData: ["cdkContextMenuTriggerData", "menuData"], disabled: ["cdkContextMenuDisabled", "disabled", booleanAttribute] }, outputs: { opened: "cdkContextMenuOpened", closed: "cdkContextMenuClosed" }, host: { listeners: { "contextmenu": "_openOnContextMenu($event)" }, properties: { "attr.data-cdk-menu-stack-id": "null" } }, providers: [
|
|
1847
1873
|
{ provide: MENU_TRIGGER, useExisting: CdkContextMenuTrigger },
|
|
1848
1874
|
{ provide: MENU_STACK, useClass: MenuStack },
|
|
1849
1875
|
], exportAs: ["cdkContextMenuTriggerFor"], usesInheritance: true, ngImport: i0 });
|
|
1850
1876
|
}
|
|
1851
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1877
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkContextMenuTrigger, decorators: [{
|
|
1852
1878
|
type: Directive,
|
|
1853
1879
|
args: [{
|
|
1854
1880
|
selector: '[cdkContextMenuTriggerFor]',
|
|
@@ -1886,8 +1912,8 @@ const MENU_DIRECTIVES = [
|
|
|
1886
1912
|
];
|
|
1887
1913
|
/** Module that declares components and directives for the CDK menu. */
|
|
1888
1914
|
class CdkMenuModule {
|
|
1889
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-
|
|
1890
|
-
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.1.0-
|
|
1915
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
1916
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuModule, imports: [OverlayModule, CdkMenuBar,
|
|
1891
1917
|
CdkMenu,
|
|
1892
1918
|
CdkMenuItem,
|
|
1893
1919
|
CdkMenuItemRadio,
|
|
@@ -1904,9 +1930,9 @@ class CdkMenuModule {
|
|
|
1904
1930
|
CdkMenuGroup,
|
|
1905
1931
|
CdkContextMenuTrigger,
|
|
1906
1932
|
CdkTargetMenuAim] });
|
|
1907
|
-
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.1.0-
|
|
1933
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuModule, imports: [OverlayModule] });
|
|
1908
1934
|
}
|
|
1909
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-
|
|
1935
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.0-rc.0", ngImport: i0, type: CdkMenuModule, decorators: [{
|
|
1910
1936
|
type: NgModule,
|
|
1911
1937
|
args: [{
|
|
1912
1938
|
imports: [OverlayModule, ...MENU_DIRECTIVES],
|