@angular/cdk-experimental 21.0.0-next.5 → 21.0.0-next.8
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/fesm2022/{polyfill.mjs → _polyfill-chunk.mjs} +1 -1
- package/fesm2022/_polyfill-chunk.mjs.map +1 -0
- package/fesm2022/cdk-experimental.mjs +1 -1
- package/fesm2022/cdk-experimental.mjs.map +1 -1
- package/fesm2022/column-resize.mjs +1 -1
- package/fesm2022/popover-edit.mjs +1 -1
- package/package.json +10 -45
- package/{column-resize/index.d.ts → types/column-resize.d.ts} +37 -37
- package/{popover-edit/index.d.ts → types/popover-edit.d.ts} +30 -30
- package/{scrolling/index.d.ts → types/scrolling.d.ts} +6 -6
- package/{selection/index.d.ts → types/selection.d.ts} +14 -14
- package/{table-scroll-container/index.d.ts → types/table-scroll-container.d.ts} +6 -6
- package/accordion/index.d.ts +0 -94
- package/accordion.d.d.ts +0 -89
- package/combobox/index.d.ts +0 -94
- package/deferred-content/index.d.ts +0 -37
- package/expansion.d.d.ts +0 -71
- package/fesm2022/accordion.mjs +0 -194
- package/fesm2022/accordion.mjs.map +0 -1
- package/fesm2022/accordion2.mjs +0 -152
- package/fesm2022/accordion2.mjs.map +0 -1
- package/fesm2022/combobox.mjs +0 -340
- package/fesm2022/combobox.mjs.map +0 -1
- package/fesm2022/deferred-content.mjs +0 -59
- package/fesm2022/deferred-content.mjs.map +0 -1
- package/fesm2022/expansion.mjs +0 -87
- package/fesm2022/expansion.mjs.map +0 -1
- package/fesm2022/list-navigation.mjs +0 -261
- package/fesm2022/list-navigation.mjs.map +0 -1
- package/fesm2022/list.mjs +0 -370
- package/fesm2022/list.mjs.map +0 -1
- package/fesm2022/listbox.mjs +0 -163
- package/fesm2022/listbox.mjs.map +0 -1
- package/fesm2022/option.mjs +0 -231
- package/fesm2022/option.mjs.map +0 -1
- package/fesm2022/polyfill.mjs.map +0 -1
- package/fesm2022/radio-group.mjs +0 -205
- package/fesm2022/radio-group.mjs.map +0 -1
- package/fesm2022/radio-group2.mjs +0 -143
- package/fesm2022/radio-group2.mjs.map +0 -1
- package/fesm2022/tabs.mjs +0 -302
- package/fesm2022/tabs.mjs.map +0 -1
- package/fesm2022/tabs2.mjs +0 -211
- package/fesm2022/tabs2.mjs.map +0 -1
- package/fesm2022/toolbar.mjs +0 -171
- package/fesm2022/toolbar.mjs.map +0 -1
- package/fesm2022/toolbar2.mjs +0 -224
- package/fesm2022/toolbar2.mjs.map +0 -1
- package/fesm2022/tree.mjs +0 -620
- package/fesm2022/tree.mjs.map +0 -1
- package/fesm2022/ui-patterns.mjs +0 -21
- package/fesm2022/ui-patterns.mjs.map +0 -1
- package/list.d.d.ts +0 -207
- package/listbox/index.d.ts +0 -89
- package/listbox.d.d.ts +0 -101
- package/pointer-event-manager.d.d.ts +0 -190
- package/radio-group/index.d.ts +0 -87
- package/radio-group.d.d.ts +0 -80
- package/tabs/index.d.ts +0 -159
- package/tabs.d.d.ts +0 -137
- package/toolbar/index.d.ts +0 -91
- package/toolbar.d.d.ts +0 -136
- package/tree/index.d.ts +0 -275
- package/ui-patterns/index.d.ts +0 -9
- /package/{index.d.ts → types/cdk-experimental.d.ts} +0 -0
package/toolbar/index.d.ts
DELETED
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
import * as _angular_core from '@angular/core';
|
|
2
|
-
import { Signal, OnInit, OnDestroy } from '@angular/core';
|
|
3
|
-
import * as _angular_cdk_bidi from '@angular/cdk/bidi';
|
|
4
|
-
import { RadioButtonPattern, ToolbarWidgetPattern, ToolbarPattern } from '../toolbar.d.js';
|
|
5
|
-
import '../pointer-event-manager.d.js';
|
|
6
|
-
import '../list.d.js';
|
|
7
|
-
|
|
8
|
-
/** Interface for a radio button that can be used with a toolbar. Based on radio-button in ui-patterns */
|
|
9
|
-
interface CdkRadioButtonInterface<V> {
|
|
10
|
-
/** The HTML element associated with the radio button. */
|
|
11
|
-
element: Signal<HTMLElement>;
|
|
12
|
-
/** Whether the radio button is disabled. */
|
|
13
|
-
disabled: Signal<boolean>;
|
|
14
|
-
pattern: RadioButtonPattern<V>;
|
|
15
|
-
}
|
|
16
|
-
/**
|
|
17
|
-
* A toolbar widget container.
|
|
18
|
-
*
|
|
19
|
-
* Widgets such as radio groups or buttons are nested within a toolbar to allow for a single
|
|
20
|
-
* place of reference for focus and navigation. The CdkToolbar is meant to be used in conjunction
|
|
21
|
-
* with CdkToolbarWidget and CdkRadioGroup as follows:
|
|
22
|
-
*
|
|
23
|
-
* ```html
|
|
24
|
-
* <div cdkToolbar>
|
|
25
|
-
* <button cdkToolbarWidget>Button</button>
|
|
26
|
-
* <div cdkRadioGroup>
|
|
27
|
-
* <label cdkRadioButton value="1">Option 1</label>
|
|
28
|
-
* <label cdkRadioButton value="2">Option 2</label>
|
|
29
|
-
* <label cdkRadioButton value="3">Option 3</label>
|
|
30
|
-
* </div>
|
|
31
|
-
* </div>
|
|
32
|
-
* ```
|
|
33
|
-
*/
|
|
34
|
-
declare class CdkToolbar<V> {
|
|
35
|
-
/** A reference to the toolbar element. */
|
|
36
|
-
private readonly _elementRef;
|
|
37
|
-
/** The CdkTabList nested inside of the container. */
|
|
38
|
-
private readonly _cdkWidgets;
|
|
39
|
-
/** A signal wrapper for directionality. */
|
|
40
|
-
textDirection: _angular_core.WritableSignal<_angular_cdk_bidi.Direction>;
|
|
41
|
-
/** Sorted UIPatterns of the child widgets */
|
|
42
|
-
items: Signal<(RadioButtonPattern<V> | ToolbarWidgetPattern)[]>;
|
|
43
|
-
/** Whether the toolbar is vertically or horizontally oriented. */
|
|
44
|
-
orientation: _angular_core.InputSignal<"vertical" | "horizontal">;
|
|
45
|
-
/** Whether disabled items in the group should be skipped when navigating. */
|
|
46
|
-
skipDisabled: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
47
|
-
/** Whether the toolbar is disabled. */
|
|
48
|
-
disabled: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
49
|
-
/** Whether focus should wrap when navigating. */
|
|
50
|
-
readonly wrap: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
51
|
-
/** The toolbar UIPattern. */
|
|
52
|
-
pattern: ToolbarPattern<V>;
|
|
53
|
-
/** Whether the toolbar has received focus yet. */
|
|
54
|
-
private _hasFocused;
|
|
55
|
-
onFocus(): void;
|
|
56
|
-
constructor();
|
|
57
|
-
register(widget: CdkRadioButtonInterface<V> | CdkToolbarWidget): void;
|
|
58
|
-
unregister(widget: CdkRadioButtonInterface<V> | CdkToolbarWidget): void;
|
|
59
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<CdkToolbar<any>, never>;
|
|
60
|
-
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<CdkToolbar<any>, "[cdkToolbar]", ["cdkToolbar"], { "orientation": { "alias": "orientation"; "required": false; "isSignal": true; }; "skipDisabled": { "alias": "skipDisabled"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "wrap": { "alias": "wrap"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
61
|
-
}
|
|
62
|
-
/**
|
|
63
|
-
* A widget within a toolbar.
|
|
64
|
-
*
|
|
65
|
-
* A widget is anything that is within a toolbar. It should be applied to any native HTML element
|
|
66
|
-
* that has the purpose of acting as a widget navigatable within a toolbar.
|
|
67
|
-
*/
|
|
68
|
-
declare class CdkToolbarWidget implements OnInit, OnDestroy {
|
|
69
|
-
/** A reference to the widget element. */
|
|
70
|
-
private readonly _elementRef;
|
|
71
|
-
/** The parent CdkToolbar. */
|
|
72
|
-
private readonly _cdkToolbar;
|
|
73
|
-
/** A unique identifier for the widget. */
|
|
74
|
-
private readonly _generatedId;
|
|
75
|
-
/** A unique identifier for the widget. */
|
|
76
|
-
protected id: Signal<string>;
|
|
77
|
-
/** The parent Toolbar UIPattern. */
|
|
78
|
-
protected parentToolbar: Signal<ToolbarPattern<any>>;
|
|
79
|
-
/** A reference to the widget element to be focused on navigation. */
|
|
80
|
-
element: Signal<any>;
|
|
81
|
-
/** Whether the widget is disabled. */
|
|
82
|
-
disabled: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
83
|
-
readonly hardDisabled: Signal<boolean>;
|
|
84
|
-
pattern: ToolbarWidgetPattern;
|
|
85
|
-
ngOnInit(): void;
|
|
86
|
-
ngOnDestroy(): void;
|
|
87
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<CdkToolbarWidget, never>;
|
|
88
|
-
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<CdkToolbarWidget, "[cdkToolbarWidget]", ["cdkToolbarWidget"], { "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
export { CdkToolbar, CdkToolbarWidget };
|
package/toolbar.d.d.ts
DELETED
|
@@ -1,136 +0,0 @@
|
|
|
1
|
-
import * as _angular_core from '@angular/core';
|
|
2
|
-
import { SignalLike, KeyboardEventManager, PointerEventManager } from './pointer-event-manager.d.js';
|
|
3
|
-
import { ListItem, List, ListInputs } from './list.d.js';
|
|
4
|
-
|
|
5
|
-
/**
|
|
6
|
-
* Represents the properties exposed by a toolbar widget that need to be accessed by a radio group.
|
|
7
|
-
* This exists to avoid circular dependency errors between the toolbar and radio button.
|
|
8
|
-
*/
|
|
9
|
-
type ToolbarWidgetLike = {
|
|
10
|
-
id: SignalLike<string>;
|
|
11
|
-
index: SignalLike<number>;
|
|
12
|
-
element: SignalLike<HTMLElement>;
|
|
13
|
-
disabled: SignalLike<boolean>;
|
|
14
|
-
searchTerm: SignalLike<any>;
|
|
15
|
-
value: SignalLike<any>;
|
|
16
|
-
};
|
|
17
|
-
/**
|
|
18
|
-
* Represents the properties exposed by a radio group that need to be accessed by a radio button.
|
|
19
|
-
* This exists to avoid circular dependency errors between the radio group and radio button.
|
|
20
|
-
*/
|
|
21
|
-
interface RadioGroupLike<V> {
|
|
22
|
-
/** The list behavior for the radio group. */
|
|
23
|
-
listBehavior: List<RadioButtonPattern<V> | ToolbarWidgetLike, V>;
|
|
24
|
-
/** Whether the list is readonly */
|
|
25
|
-
readonly: SignalLike<boolean>;
|
|
26
|
-
/** Whether the radio group is disabled. */
|
|
27
|
-
disabled: SignalLike<boolean>;
|
|
28
|
-
}
|
|
29
|
-
/** Represents the required inputs for a radio button in a radio group. */
|
|
30
|
-
interface RadioButtonInputs<V> extends Omit<ListItem<V>, 'searchTerm' | 'index'> {
|
|
31
|
-
/** A reference to the parent radio group. */
|
|
32
|
-
group: SignalLike<RadioGroupLike<V> | undefined>;
|
|
33
|
-
}
|
|
34
|
-
/** Represents a radio button within a radio group. */
|
|
35
|
-
declare class RadioButtonPattern<V> {
|
|
36
|
-
readonly inputs: RadioButtonInputs<V>;
|
|
37
|
-
/** A unique identifier for the radio button. */
|
|
38
|
-
id: SignalLike<string>;
|
|
39
|
-
/** The value associated with the radio button. */
|
|
40
|
-
value: SignalLike<V>;
|
|
41
|
-
/** The position of the radio button within the group. */
|
|
42
|
-
index: SignalLike<number>;
|
|
43
|
-
/** Whether the radio button is currently the active one (focused). */
|
|
44
|
-
active: _angular_core.Signal<boolean>;
|
|
45
|
-
/** Whether the radio button is selected. */
|
|
46
|
-
selected: SignalLike<boolean>;
|
|
47
|
-
/** Whether the radio button is disabled. */
|
|
48
|
-
disabled: SignalLike<boolean>;
|
|
49
|
-
/** A reference to the parent radio group. */
|
|
50
|
-
group: SignalLike<RadioGroupLike<V> | undefined>;
|
|
51
|
-
/** The tabindex of the radio button. */
|
|
52
|
-
tabindex: _angular_core.Signal<0 | -1 | undefined>;
|
|
53
|
-
/** The HTML element associated with the radio button. */
|
|
54
|
-
element: SignalLike<HTMLElement>;
|
|
55
|
-
/** The search term for typeahead. */
|
|
56
|
-
readonly searchTerm: () => string;
|
|
57
|
-
constructor(inputs: RadioButtonInputs<V>);
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
/** Represents the required inputs for a toolbar. */
|
|
61
|
-
type ToolbarInputs<V> = Omit<ListInputs<ToolbarWidgetPattern | RadioButtonPattern<V>, V>, 'multi' | 'typeaheadDelay' | 'value' | 'selectionMode'>;
|
|
62
|
-
/** Controls the state of a toolbar. */
|
|
63
|
-
declare class ToolbarPattern<V> {
|
|
64
|
-
readonly inputs: ToolbarInputs<V>;
|
|
65
|
-
/** The list behavior for the toolbar. */
|
|
66
|
-
listBehavior: List<ToolbarWidgetPattern | RadioButtonPattern<V>, V>;
|
|
67
|
-
/** Whether the tablist is vertically or horizontally oriented. */
|
|
68
|
-
readonly orientation: SignalLike<'vertical' | 'horizontal'>;
|
|
69
|
-
/** Whether the toolbar is disabled. */
|
|
70
|
-
disabled: _angular_core.Signal<boolean>;
|
|
71
|
-
/** The tabindex of the toolbar (if using activedescendant). */
|
|
72
|
-
tabindex: _angular_core.Signal<0 | -1>;
|
|
73
|
-
/** The id of the current active widget (if using activedescendant). */
|
|
74
|
-
activedescendant: _angular_core.Signal<string | undefined>;
|
|
75
|
-
/** The key used to navigate to the previous widget. */
|
|
76
|
-
prevKey: _angular_core.Signal<"ArrowUp" | "ArrowRight" | "ArrowLeft">;
|
|
77
|
-
/** The key used to navigate to the next widget. */
|
|
78
|
-
nextKey: _angular_core.Signal<"ArrowRight" | "ArrowLeft" | "ArrowDown">;
|
|
79
|
-
/** The alternate key used to navigate to the previous widget */
|
|
80
|
-
altPrevKey: _angular_core.Signal<"ArrowUp" | "ArrowRight" | "ArrowLeft">;
|
|
81
|
-
/** The alternate key used to navigate to the next widget. */
|
|
82
|
-
altNextKey: _angular_core.Signal<"ArrowRight" | "ArrowLeft" | "ArrowDown">;
|
|
83
|
-
/** The keydown event manager for the toolbar. */
|
|
84
|
-
keydown: _angular_core.Signal<KeyboardEventManager<KeyboardEvent>>;
|
|
85
|
-
selectRadioButton(): void;
|
|
86
|
-
/** The pointerdown event manager for the toolbar. */
|
|
87
|
-
pointerdown: _angular_core.Signal<PointerEventManager<PointerEvent>>;
|
|
88
|
-
/** Navigates to the widget associated with the given pointer event. */
|
|
89
|
-
goto(event: PointerEvent): void;
|
|
90
|
-
/** Handles keydown events for the toolbar. */
|
|
91
|
-
onKeydown(event: KeyboardEvent): void;
|
|
92
|
-
/** Handles pointerdown events for the toolbar. */
|
|
93
|
-
onPointerdown(event: PointerEvent): void;
|
|
94
|
-
/** Finds the Toolbar Widget associated with a pointer event target. */
|
|
95
|
-
private _getItem;
|
|
96
|
-
constructor(inputs: ToolbarInputs<V>);
|
|
97
|
-
/**
|
|
98
|
-
* Sets the toolbar to its default initial state.
|
|
99
|
-
*
|
|
100
|
-
* Sets the active index to the selected widget if one exists and is focusable.
|
|
101
|
-
* Otherwise, sets the active index to the first focusable widget.
|
|
102
|
-
*/
|
|
103
|
-
setDefaultState(): void;
|
|
104
|
-
/** Validates the state of the toolbar and returns a list of accessibility violations. */
|
|
105
|
-
validate(): string[];
|
|
106
|
-
}
|
|
107
|
-
/** Represents the required inputs for a toolbar widget in a toolbar. */
|
|
108
|
-
interface ToolbarWidgetInputs extends Omit<ListItem<any>, 'searchTerm' | 'value' | 'index'> {
|
|
109
|
-
/** A reference to the parent toolbar. */
|
|
110
|
-
parentToolbar: SignalLike<ToolbarPattern<null>>;
|
|
111
|
-
}
|
|
112
|
-
declare class ToolbarWidgetPattern {
|
|
113
|
-
readonly inputs: ToolbarWidgetInputs;
|
|
114
|
-
/** A unique identifier for the widget. */
|
|
115
|
-
id: SignalLike<string>;
|
|
116
|
-
/** The html element that should receive focus. */
|
|
117
|
-
readonly element: SignalLike<HTMLElement>;
|
|
118
|
-
/** Whether the widget is disabled. */
|
|
119
|
-
disabled: SignalLike<boolean>;
|
|
120
|
-
/** A reference to the parent toolbar. */
|
|
121
|
-
parentToolbar: SignalLike<ToolbarPattern<null> | undefined>;
|
|
122
|
-
/** The tabindex of the widgdet. */
|
|
123
|
-
tabindex: _angular_core.Signal<0 | -1>;
|
|
124
|
-
/** The text used by the typeahead search. */
|
|
125
|
-
readonly searchTerm: () => string;
|
|
126
|
-
/** The value associated with the widget. */
|
|
127
|
-
readonly value: () => any;
|
|
128
|
-
/** The position of the widget within the toolbar. */
|
|
129
|
-
index: _angular_core.Signal<number>;
|
|
130
|
-
/** Whether the widget is currently the active one (focused). */
|
|
131
|
-
active: _angular_core.Signal<boolean>;
|
|
132
|
-
constructor(inputs: ToolbarWidgetInputs);
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
export { RadioButtonPattern, ToolbarPattern, ToolbarWidgetPattern };
|
|
136
|
-
export type { RadioButtonInputs, ToolbarInputs, ToolbarWidgetInputs };
|
package/tree/index.d.ts
DELETED
|
@@ -1,275 +0,0 @@
|
|
|
1
|
-
import * as _angular_cdk_bidi from '@angular/cdk/bidi';
|
|
2
|
-
import * as _angular_core from '@angular/core';
|
|
3
|
-
import { OnInit, OnDestroy, Signal } from '@angular/core';
|
|
4
|
-
import { SignalLike, KeyboardEventManager, PointerEventManager } from '../pointer-event-manager.d.js';
|
|
5
|
-
import { List, ListItem, ListInputs } from '../list.d.js';
|
|
6
|
-
import { ExpansionItem, ListExpansion, ExpansionControl } from '../expansion.d.js';
|
|
7
|
-
import * as i1 from '@angular/cdk-experimental/deferred-content';
|
|
8
|
-
|
|
9
|
-
/** Represents the required inputs for a tree item. */
|
|
10
|
-
interface TreeItemInputs<V> extends Omit<ListItem<V>, 'index'> {
|
|
11
|
-
/** The parent item. */
|
|
12
|
-
parent: SignalLike<TreeItemPattern<V> | TreePattern<V>>;
|
|
13
|
-
/** Whether this item has children. Children can be lazily loaded. */
|
|
14
|
-
hasChildren: SignalLike<boolean>;
|
|
15
|
-
/** The children items. */
|
|
16
|
-
children: SignalLike<TreeItemPattern<V>[]>;
|
|
17
|
-
/** The tree pattern this item belongs to. */
|
|
18
|
-
tree: SignalLike<TreePattern<V>>;
|
|
19
|
-
}
|
|
20
|
-
interface TreeItemPattern<V> extends TreeItemInputs<V> {
|
|
21
|
-
}
|
|
22
|
-
/**
|
|
23
|
-
* Represents an item in a Tree.
|
|
24
|
-
*/
|
|
25
|
-
declare class TreeItemPattern<V> implements ExpansionItem {
|
|
26
|
-
readonly inputs: TreeItemInputs<V>;
|
|
27
|
-
/** The position of this item among its siblings. */
|
|
28
|
-
readonly index: _angular_core.Signal<number>;
|
|
29
|
-
/** The unique identifier used by the expansion behavior. */
|
|
30
|
-
readonly expansionId: SignalLike<string>;
|
|
31
|
-
/** Controls expansion for child items. */
|
|
32
|
-
readonly expansionManager: ListExpansion;
|
|
33
|
-
/** Controls expansion for this item. */
|
|
34
|
-
readonly expansion: ExpansionControl;
|
|
35
|
-
/** Whether the item is expandable. It's expandable if children item exist. */
|
|
36
|
-
readonly expandable: SignalLike<boolean>;
|
|
37
|
-
/** The level of the current item in a tree. */
|
|
38
|
-
readonly level: SignalLike<number>;
|
|
39
|
-
/** Whether this item is currently expanded. */
|
|
40
|
-
readonly expanded: _angular_core.Signal<boolean>;
|
|
41
|
-
/** Whether this item is visible. */
|
|
42
|
-
readonly visible: _angular_core.Signal<boolean>;
|
|
43
|
-
/** The number of items under the same parent at the same level. */
|
|
44
|
-
readonly setsize: _angular_core.Signal<number>;
|
|
45
|
-
/** The position of this item among its siblings (1-based). */
|
|
46
|
-
readonly posinset: _angular_core.Signal<number>;
|
|
47
|
-
/** Whether the item is active. */
|
|
48
|
-
readonly active: _angular_core.Signal<boolean>;
|
|
49
|
-
/** The tabindex of the item. */
|
|
50
|
-
readonly tabindex: _angular_core.Signal<0 | -1>;
|
|
51
|
-
/** Whether the item is selected. */
|
|
52
|
-
readonly selected: _angular_core.Signal<boolean | undefined>;
|
|
53
|
-
/** The current type of this item. */
|
|
54
|
-
readonly current: _angular_core.Signal<"page" | "step" | "location" | "date" | "time" | "true" | "false" | undefined>;
|
|
55
|
-
constructor(inputs: TreeItemInputs<V>);
|
|
56
|
-
}
|
|
57
|
-
/** The selection operations that the tree can perform. */
|
|
58
|
-
interface SelectOptions {
|
|
59
|
-
toggle?: boolean;
|
|
60
|
-
selectOne?: boolean;
|
|
61
|
-
selectRange?: boolean;
|
|
62
|
-
anchor?: boolean;
|
|
63
|
-
}
|
|
64
|
-
/** Represents the required inputs for a tree. */
|
|
65
|
-
interface TreeInputs<V> extends Omit<ListInputs<TreeItemPattern<V>, V>, 'items'> {
|
|
66
|
-
/** All items in the tree, in document order (DFS-like, a flattened list). */
|
|
67
|
-
allItems: SignalLike<TreeItemPattern<V>[]>;
|
|
68
|
-
/** Whether the tree is in navigation mode. */
|
|
69
|
-
nav: SignalLike<boolean>;
|
|
70
|
-
/** The aria-current type. */
|
|
71
|
-
currentType: SignalLike<'page' | 'step' | 'location' | 'date' | 'time' | 'true' | 'false'>;
|
|
72
|
-
}
|
|
73
|
-
interface TreePattern<V> extends TreeInputs<V> {
|
|
74
|
-
}
|
|
75
|
-
/** Controls the state and interactions of a tree view. */
|
|
76
|
-
declare class TreePattern<V> {
|
|
77
|
-
readonly inputs: TreeInputs<V>;
|
|
78
|
-
/** The list behavior for the tree. */
|
|
79
|
-
readonly listBehavior: List<TreeItemPattern<V>, V>;
|
|
80
|
-
/** Controls expansion for direct children of the tree root (top-level items). */
|
|
81
|
-
readonly expansionManager: ListExpansion;
|
|
82
|
-
/** The root level is 0. */
|
|
83
|
-
readonly level: () => number;
|
|
84
|
-
/** The root is always expanded. */
|
|
85
|
-
readonly expanded: () => boolean;
|
|
86
|
-
/** The tabindex of the tree. */
|
|
87
|
-
readonly tabindex: _angular_core.Signal<0 | -1>;
|
|
88
|
-
/** The id of the current active item. */
|
|
89
|
-
readonly activedescendant: _angular_core.Signal<string | undefined>;
|
|
90
|
-
/** The direct children of the root (top-level tree items). */
|
|
91
|
-
readonly children: _angular_core.Signal<TreeItemPattern<V>[]>;
|
|
92
|
-
/** All currently visible tree items. An item is visible if their parent is expanded. */
|
|
93
|
-
readonly visibleItems: _angular_core.Signal<TreeItemPattern<V>[]>;
|
|
94
|
-
/** Whether the tree selection follows focus. */
|
|
95
|
-
readonly followFocus: _angular_core.Signal<boolean>;
|
|
96
|
-
/** The key for navigating to the previous item. */
|
|
97
|
-
readonly prevKey: _angular_core.Signal<"ArrowUp" | "ArrowRight" | "ArrowLeft">;
|
|
98
|
-
/** The key for navigating to the next item. */
|
|
99
|
-
readonly nextKey: _angular_core.Signal<"ArrowRight" | "ArrowLeft" | "ArrowDown">;
|
|
100
|
-
/** The key for collapsing an item or moving to its parent. */
|
|
101
|
-
readonly collapseKey: _angular_core.Signal<"ArrowUp" | "ArrowRight" | "ArrowLeft">;
|
|
102
|
-
/** The key for expanding an item or moving to its first child. */
|
|
103
|
-
readonly expandKey: _angular_core.Signal<"ArrowRight" | "ArrowLeft" | "ArrowDown">;
|
|
104
|
-
/** Represents the space key. Does nothing when the user is actively using typeahead. */
|
|
105
|
-
readonly dynamicSpaceKey: _angular_core.Signal<"" | " ">;
|
|
106
|
-
/** Regular expression to match characters for typeahead. */
|
|
107
|
-
readonly typeaheadRegexp: RegExp;
|
|
108
|
-
/** The keydown event manager for the tree. */
|
|
109
|
-
readonly keydown: _angular_core.Signal<KeyboardEventManager<KeyboardEvent>>;
|
|
110
|
-
/** The pointerdown event manager for the tree. */
|
|
111
|
-
pointerdown: _angular_core.Signal<PointerEventManager<PointerEvent>>;
|
|
112
|
-
constructor(inputs: TreeInputs<V>);
|
|
113
|
-
/**
|
|
114
|
-
* Sets the tree to it's default initial state.
|
|
115
|
-
*
|
|
116
|
-
* Sets the active index of the tree to the first focusable selected tree item if one exists.
|
|
117
|
-
* Otherwise, sets focus to the first focusable tree item.
|
|
118
|
-
*/
|
|
119
|
-
setDefaultState(): void;
|
|
120
|
-
/** Handles keydown events on the tree. */
|
|
121
|
-
onKeydown(event: KeyboardEvent): void;
|
|
122
|
-
/** Handles pointerdown events on the tree. */
|
|
123
|
-
onPointerdown(event: PointerEvent): void;
|
|
124
|
-
/** Navigates to the given tree item in the tree. */
|
|
125
|
-
goto(e: PointerEvent, opts?: SelectOptions): void;
|
|
126
|
-
/** Toggles to expand or collapse a tree item. */
|
|
127
|
-
toggleExpansion(item?: TreeItemPattern<V>): void;
|
|
128
|
-
/** Expands a tree item. */
|
|
129
|
-
expand(opts?: SelectOptions): void;
|
|
130
|
-
/** Expands all sibling tree items including itself. */
|
|
131
|
-
expandSiblings(item?: TreeItemPattern<V>): void;
|
|
132
|
-
/** Collapses a tree item. */
|
|
133
|
-
collapse(opts?: SelectOptions): void;
|
|
134
|
-
/** Retrieves the TreeItemPattern associated with a DOM event, if any. */
|
|
135
|
-
private _getItem;
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
interface HasElement {
|
|
139
|
-
element: Signal<HTMLElement>;
|
|
140
|
-
}
|
|
141
|
-
/**
|
|
142
|
-
* A Tree container.
|
|
143
|
-
*
|
|
144
|
-
* Transforms nested lists into an accessible, ARIA-compliant tree structure.
|
|
145
|
-
*
|
|
146
|
-
* ```html
|
|
147
|
-
* <ul cdkTree [(value)]="selectedItems" [multi]="true">
|
|
148
|
-
* <li cdkTreeItem [value]="'leaf1'">Leaf Item 1</li>
|
|
149
|
-
* <li cdkTreeItem [value]="'parent1'">
|
|
150
|
-
* Parent Item 1
|
|
151
|
-
* <ul cdkTreeItemGroup [value]="'parent1'">
|
|
152
|
-
* <ng-template cdkTreeItemGroupContent>
|
|
153
|
-
* <li cdkTreeItem [value]="'child1.1'">Child Item 1.1</li>
|
|
154
|
-
* <li cdkTreeItem [value]="'child1.2'">Child Item 1.2</li>
|
|
155
|
-
* </ng-template>
|
|
156
|
-
* </ul>
|
|
157
|
-
* </li>
|
|
158
|
-
* <li cdkTreeItem [value]="'leaf2'" [disabled]="true">Disabled Leaf Item 2</li>
|
|
159
|
-
* </ul>
|
|
160
|
-
* ```
|
|
161
|
-
*/
|
|
162
|
-
declare class CdkTree<V> {
|
|
163
|
-
/** A reference to the tree element. */
|
|
164
|
-
private readonly _elementRef;
|
|
165
|
-
/** All CdkTreeItem instances within this tree. */
|
|
166
|
-
private readonly _unorderedItems;
|
|
167
|
-
/** Orientation of the tree. */
|
|
168
|
-
readonly orientation: _angular_core.InputSignal<"vertical" | "horizontal">;
|
|
169
|
-
/** Whether multi-selection is allowed. */
|
|
170
|
-
readonly multi: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
171
|
-
/** Whether the tree is disabled. */
|
|
172
|
-
readonly disabled: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
173
|
-
/** The selection strategy used by the tree. */
|
|
174
|
-
readonly selectionMode: _angular_core.InputSignal<"explicit" | "follow">;
|
|
175
|
-
/** The focus strategy used by the tree. */
|
|
176
|
-
readonly focusMode: _angular_core.InputSignal<"roving" | "activedescendant">;
|
|
177
|
-
/** Whether navigation wraps. */
|
|
178
|
-
readonly wrap: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
179
|
-
/** Whether to skip disabled items during navigation. */
|
|
180
|
-
readonly skipDisabled: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
181
|
-
/** Typeahead delay. */
|
|
182
|
-
readonly typeaheadDelay: _angular_core.InputSignal<number>;
|
|
183
|
-
/** Selected item values. */
|
|
184
|
-
readonly value: _angular_core.ModelSignal<V[]>;
|
|
185
|
-
/** Text direction. */
|
|
186
|
-
readonly textDirection: _angular_core.WritableSignal<_angular_cdk_bidi.Direction>;
|
|
187
|
-
/** Whether the tree is in navigation mode. */
|
|
188
|
-
readonly nav: _angular_core.InputSignal<boolean>;
|
|
189
|
-
/** The aria-current type. */
|
|
190
|
-
readonly currentType: _angular_core.InputSignal<"page" | "step" | "location" | "date" | "time" | "true" | "false">;
|
|
191
|
-
/** The UI pattern for the tree. */
|
|
192
|
-
readonly pattern: TreePattern<V>;
|
|
193
|
-
/** Whether the tree has received focus yet. */
|
|
194
|
-
private _hasFocused;
|
|
195
|
-
constructor();
|
|
196
|
-
onFocus(): void;
|
|
197
|
-
register(child: CdkTreeItem<V>): void;
|
|
198
|
-
unregister(child: CdkTreeItem<V>): void;
|
|
199
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<CdkTree<any>, never>;
|
|
200
|
-
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<CdkTree<any>, "[cdkTree]", ["cdkTree"], { "orientation": { "alias": "orientation"; "required": false; "isSignal": true; }; "multi": { "alias": "multi"; "required": false; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "selectionMode": { "alias": "selectionMode"; "required": false; "isSignal": true; }; "focusMode": { "alias": "focusMode"; "required": false; "isSignal": true; }; "wrap": { "alias": "wrap"; "required": false; "isSignal": true; }; "skipDisabled": { "alias": "skipDisabled"; "required": false; "isSignal": true; }; "typeaheadDelay": { "alias": "typeaheadDelay"; "required": false; "isSignal": true; }; "value": { "alias": "value"; "required": false; "isSignal": true; }; "nav": { "alias": "nav"; "required": false; "isSignal": true; }; "currentType": { "alias": "currentType"; "required": false; "isSignal": true; }; }, { "value": "valueChange"; }, never, never, true, never>;
|
|
201
|
-
}
|
|
202
|
-
/**
|
|
203
|
-
* A selectable and expandable Tree Item in a Tree.
|
|
204
|
-
*/
|
|
205
|
-
declare class CdkTreeItem<V> implements OnInit, OnDestroy, HasElement {
|
|
206
|
-
/** A reference to the tree item element. */
|
|
207
|
-
private readonly _elementRef;
|
|
208
|
-
/** A unique identifier for the tree item. */
|
|
209
|
-
private readonly _id;
|
|
210
|
-
/** The owned tree item group. */
|
|
211
|
-
private readonly _group;
|
|
212
|
-
/** The id of the owned group. */
|
|
213
|
-
readonly ownsId: Signal<string | undefined>;
|
|
214
|
-
/** The host native element. */
|
|
215
|
-
readonly element: Signal<any>;
|
|
216
|
-
/** The value of the tree item. */
|
|
217
|
-
readonly value: _angular_core.InputSignal<V>;
|
|
218
|
-
/** The parent tree root or tree item group. */
|
|
219
|
-
readonly parent: _angular_core.InputSignal<CdkTreeItemGroup<V> | CdkTree<V>>;
|
|
220
|
-
/** Whether the tree item is disabled. */
|
|
221
|
-
readonly disabled: _angular_core.InputSignalWithTransform<boolean, unknown>;
|
|
222
|
-
/** Optional label for typeahead. Defaults to the element's textContent. */
|
|
223
|
-
readonly label: _angular_core.InputSignal<string | undefined>;
|
|
224
|
-
/** Search term for typeahead. */
|
|
225
|
-
readonly searchTerm: Signal<any>;
|
|
226
|
-
/** The tree root. */
|
|
227
|
-
readonly tree: Signal<CdkTree<V>>;
|
|
228
|
-
/** The UI pattern for this item. */
|
|
229
|
-
pattern: TreeItemPattern<V>;
|
|
230
|
-
constructor();
|
|
231
|
-
ngOnInit(): void;
|
|
232
|
-
ngOnDestroy(): void;
|
|
233
|
-
register(group: CdkTreeItemGroup<V>): void;
|
|
234
|
-
unregister(): void;
|
|
235
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<CdkTreeItem<any>, never>;
|
|
236
|
-
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<CdkTreeItem<any>, "[cdkTreeItem]", ["cdkTreeItem"], { "value": { "alias": "value"; "required": true; "isSignal": true; }; "parent": { "alias": "parent"; "required": true; "isSignal": true; }; "disabled": { "alias": "disabled"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
237
|
-
}
|
|
238
|
-
/**
|
|
239
|
-
* Container that designates content as a group.
|
|
240
|
-
*/
|
|
241
|
-
declare class CdkTreeItemGroup<V> implements OnInit, OnDestroy, HasElement {
|
|
242
|
-
/** A reference to the group element. */
|
|
243
|
-
private readonly _elementRef;
|
|
244
|
-
/** The DeferredContentAware host directive. */
|
|
245
|
-
private readonly _deferredContentAware;
|
|
246
|
-
/** All groupable items that are descendants of the group. */
|
|
247
|
-
private readonly _unorderedItems;
|
|
248
|
-
/** The host native element. */
|
|
249
|
-
readonly element: Signal<any>;
|
|
250
|
-
/** Unique ID for the group. */
|
|
251
|
-
readonly id: string;
|
|
252
|
-
/** Whether the group is visible. */
|
|
253
|
-
readonly visible: _angular_core.WritableSignal<boolean>;
|
|
254
|
-
/** Child items within this group. */
|
|
255
|
-
readonly children: Signal<CdkTreeItem<V>[]>;
|
|
256
|
-
/** Tree item that owns the group. */
|
|
257
|
-
readonly ownedBy: _angular_core.InputSignal<CdkTreeItem<V>>;
|
|
258
|
-
constructor();
|
|
259
|
-
ngOnInit(): void;
|
|
260
|
-
ngOnDestroy(): void;
|
|
261
|
-
register(child: CdkTreeItem<V>): void;
|
|
262
|
-
unregister(child: CdkTreeItem<V>): void;
|
|
263
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<CdkTreeItemGroup<any>, never>;
|
|
264
|
-
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<CdkTreeItemGroup<any>, "[cdkTreeItemGroup]", ["cdkTreeItemGroup"], { "ownedBy": { "alias": "ownedBy"; "required": true; "isSignal": true; }; }, {}, never, never, true, [{ directive: typeof i1.DeferredContentAware; inputs: { "preserveContent": "preserveContent"; }; outputs: {}; }]>;
|
|
265
|
-
}
|
|
266
|
-
/**
|
|
267
|
-
* A structural directive that marks the `ng-template` to be used as the content
|
|
268
|
-
* for a `CdkTreeItemGroup`. This content can be lazily loaded.
|
|
269
|
-
*/
|
|
270
|
-
declare class CdkTreeItemGroupContent {
|
|
271
|
-
static ɵfac: _angular_core.ɵɵFactoryDeclaration<CdkTreeItemGroupContent, never>;
|
|
272
|
-
static ɵdir: _angular_core.ɵɵDirectiveDeclaration<CdkTreeItemGroupContent, "ng-template[cdkTreeItemGroupContent]", never, {}, {}, never, never, true, [{ directive: typeof i1.DeferredContent; inputs: {}; outputs: {}; }]>;
|
|
273
|
-
}
|
|
274
|
-
|
|
275
|
-
export { CdkTree, CdkTreeItem, CdkTreeItemGroup, CdkTreeItemGroupContent };
|
package/ui-patterns/index.d.ts
DELETED
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
export { ListboxInputs, ListboxPattern, OptionInputs, OptionPattern } from '../listbox.d.js';
|
|
2
|
-
export { RadioGroupInputs, RadioGroupPattern, ToolbarLike } from '../radio-group.d.js';
|
|
3
|
-
export { RadioButtonInputs, RadioButtonPattern, ToolbarInputs, ToolbarPattern, ToolbarWidgetInputs, ToolbarWidgetPattern } from '../toolbar.d.js';
|
|
4
|
-
export { SignalLike, WritableSignalLike, convertGetterSetterToWritableSignalLike } from '../pointer-event-manager.d.js';
|
|
5
|
-
export { TabInputs, TabListInputs, TabListPattern, TabPanelInputs, TabPanelPattern, TabPattern } from '../tabs.d.js';
|
|
6
|
-
export { AccordionGroupInputs, AccordionGroupPattern, AccordionPanelInputs, AccordionPanelPattern, AccordionTriggerInputs, AccordionTriggerPattern } from '../accordion.d.js';
|
|
7
|
-
import '@angular/core';
|
|
8
|
-
import '../list.d.js';
|
|
9
|
-
import '../expansion.d.js';
|
|
File without changes
|