|
| 1 | +import * as i0 from '@angular/core'; |
| 2 | +import { InjectionToken, AfterContentInit, OnDestroy, TemplateRef, ElementRef, QueryList, EventEmitter, AfterViewInit, OnChanges, SimpleChanges } from '@angular/core'; |
| 3 | +import * as i2 from '@angular/cdk/overlay'; |
| 4 | +import { ScrollStrategy, Overlay } from '@angular/cdk/overlay'; |
| 5 | +import * as i1 from '@angular/material/core'; |
| 6 | +import { MatOption, ThemePalette, MatOptgroup, MatOptionSelectionChange } from '@angular/material/core'; |
| 7 | +export { MatOptgroup, MatOption } from '@angular/material/core'; |
1 | 8 | import { ActiveDescendantKeyManager } from '@angular/cdk/a11y';
|
2 |
| -import { AfterContentInit } from '@angular/core'; |
3 |
| -import { AfterViewInit } from '@angular/core'; |
4 | 9 | import { ControlValueAccessor } from '@angular/forms';
|
5 |
| -import { ElementRef } from '@angular/core'; |
6 |
| -import { EventEmitter } from '@angular/core'; |
7 |
| -import * as i0 from '@angular/core'; |
8 |
| -import * as i1 from '@angular/cdk/overlay'; |
9 |
| -import * as i2 from '@angular/material/core'; |
10 |
| -import * as i6 from '@angular/cdk/scrolling'; |
11 |
| -import { InjectionToken } from '@angular/core'; |
12 |
| -import { MatOptgroup } from '@angular/material/core'; |
13 |
| -import { MatOption } from '@angular/material/core'; |
14 |
| -import { MatOptionSelectionChange } from '@angular/material/core'; |
15 | 10 | import { Observable } from 'rxjs';
|
16 |
| -import { OnChanges } from '@angular/core'; |
17 |
| -import { OnDestroy } from '@angular/core'; |
18 |
| -import { Overlay } from '@angular/cdk/overlay'; |
19 |
| -import { QueryList } from '@angular/core'; |
20 |
| -import { ScrollStrategy } from '@angular/cdk/overlay'; |
21 |
| -import { SimpleChanges } from '@angular/core'; |
22 |
| -import { TemplateRef } from '@angular/core'; |
23 |
| -import { ThemePalette } from '@angular/material/core'; |
24 |
| - |
25 |
| -/** |
26 |
| - * Creates an error to be thrown when attempting to use an autocomplete trigger without a panel. |
27 |
| - * @docs-private |
28 |
| - */ |
29 |
| -export declare function getMatAutocompleteMissingPanelError(): Error; |
| 11 | +import * as i2$1 from '@angular/cdk/scrolling'; |
30 | 12 |
|
31 |
| -declare namespace i3 { |
32 |
| - export { |
33 |
| - MAT_AUTOCOMPLETE_DEFAULT_OPTIONS_FACTORY, |
34 |
| - MatAutocompleteSelectedEvent, |
35 |
| - MatAutocompleteActivatedEvent, |
36 |
| - MatAutocompleteDefaultOptions, |
37 |
| - MAT_AUTOCOMPLETE_DEFAULT_OPTIONS, |
38 |
| - MatAutocomplete |
39 |
| - } |
| 13 | +/** Event object that is emitted when an autocomplete option is selected. */ |
| 14 | +declare class MatAutocompleteSelectedEvent { |
| 15 | + /** Reference to the autocomplete panel that emitted the event. */ |
| 16 | + source: MatAutocomplete; |
| 17 | + /** Option that was selected. */ |
| 18 | + option: MatOption; |
| 19 | + constructor( |
| 20 | + /** Reference to the autocomplete panel that emitted the event. */ |
| 21 | + source: MatAutocomplete, |
| 22 | + /** Option that was selected. */ |
| 23 | + option: MatOption); |
40 | 24 | }
|
41 |
| - |
42 |
| -declare namespace i4 { |
43 |
| - export { |
44 |
| - getMatAutocompleteMissingPanelError, |
45 |
| - MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY, |
46 |
| - MAT_AUTOCOMPLETE_VALUE_ACCESSOR, |
47 |
| - MAT_AUTOCOMPLETE_SCROLL_STRATEGY, |
48 |
| - MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY_PROVIDER, |
49 |
| - MatAutocompleteTrigger |
50 |
| - } |
| 25 | +/** Event object that is emitted when an autocomplete option is activated. */ |
| 26 | +interface MatAutocompleteActivatedEvent { |
| 27 | + /** Reference to the autocomplete panel that emitted the event. */ |
| 28 | + source: MatAutocomplete; |
| 29 | + /** Option that was selected. */ |
| 30 | + option: MatOption | null; |
51 | 31 | }
|
52 |
| - |
53 |
| -declare namespace i5 { |
54 |
| - export { |
55 |
| - MatAutocompleteOrigin |
56 |
| - } |
| 32 | +/** Default `mat-autocomplete` options that can be overridden. */ |
| 33 | +interface MatAutocompleteDefaultOptions { |
| 34 | + /** Whether the first option should be highlighted when an autocomplete panel is opened. */ |
| 35 | + autoActiveFirstOption?: boolean; |
| 36 | + /** Whether the active option should be selected as the user is navigating. */ |
| 37 | + autoSelectActiveOption?: boolean; |
| 38 | + /** |
| 39 | + * Whether the user is required to make a selection when |
| 40 | + * they're interacting with the autocomplete. |
| 41 | + */ |
| 42 | + requireSelection?: boolean; |
| 43 | + /** Class or list of classes to be applied to the autocomplete's overlay panel. */ |
| 44 | + overlayPanelClass?: string | string[]; |
| 45 | + /** Whether icon indicators should be hidden for single-selection. */ |
| 46 | + hideSingleSelectionIndicator?: boolean; |
57 | 47 | }
|
58 |
| - |
59 | 48 | /** Injection token to be used to override the default options for `mat-autocomplete`. */
|
60 |
| -export declare const MAT_AUTOCOMPLETE_DEFAULT_OPTIONS: InjectionToken<MatAutocompleteDefaultOptions>; |
61 |
| - |
62 |
| -/** @docs-private */ |
63 |
| -export declare function MAT_AUTOCOMPLETE_DEFAULT_OPTIONS_FACTORY(): MatAutocompleteDefaultOptions; |
64 |
| - |
65 |
| -/** Injection token that determines the scroll handling while the autocomplete panel is open. */ |
66 |
| -export declare const MAT_AUTOCOMPLETE_SCROLL_STRATEGY: InjectionToken<() => ScrollStrategy>; |
67 |
| - |
68 |
| -/** @docs-private */ |
69 |
| -export declare function MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY(overlay: Overlay): () => ScrollStrategy; |
70 |
| - |
| 49 | +declare const MAT_AUTOCOMPLETE_DEFAULT_OPTIONS: InjectionToken<MatAutocompleteDefaultOptions>; |
71 | 50 | /** @docs-private */
|
72 |
| -export declare const MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY_PROVIDER: { |
73 |
| - provide: InjectionToken<() => ScrollStrategy>; |
74 |
| - deps: (typeof Overlay)[]; |
75 |
| - useFactory: typeof MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY; |
76 |
| -}; |
77 |
| - |
78 |
| -/** |
79 |
| - * Provider that allows the autocomplete to register as a ControlValueAccessor. |
80 |
| - * @docs-private |
81 |
| - */ |
82 |
| -export declare const MAT_AUTOCOMPLETE_VALUE_ACCESSOR: any; |
83 |
| - |
| 51 | +declare function MAT_AUTOCOMPLETE_DEFAULT_OPTIONS_FACTORY(): MatAutocompleteDefaultOptions; |
84 | 52 | /** Autocomplete component. */
|
85 |
| -export declare class MatAutocomplete implements AfterContentInit, OnDestroy { |
| 53 | +declare class MatAutocomplete implements AfterContentInit, OnDestroy { |
86 | 54 | private _changeDetectorRef;
|
87 | 55 | private _elementRef;
|
88 | 56 | protected _defaults: MatAutocompleteDefaultOptions;
|
@@ -189,63 +157,39 @@ export declare class MatAutocomplete implements AfterContentInit, OnDestroy {
|
189 | 157 | static ngAcceptInputType_hideSingleSelectionIndicator: unknown;
|
190 | 158 | }
|
191 | 159 |
|
192 |
| -/** Event object that is emitted when an autocomplete option is activated. */ |
193 |
| -export declare interface MatAutocompleteActivatedEvent { |
194 |
| - /** Reference to the autocomplete panel that emitted the event. */ |
195 |
| - source: MatAutocomplete; |
196 |
| - /** Option that was selected. */ |
197 |
| - option: MatOption | null; |
198 |
| -} |
199 |
| - |
200 |
| -/** Default `mat-autocomplete` options that can be overridden. */ |
201 |
| -export declare interface MatAutocompleteDefaultOptions { |
202 |
| - /** Whether the first option should be highlighted when an autocomplete panel is opened. */ |
203 |
| - autoActiveFirstOption?: boolean; |
204 |
| - /** Whether the active option should be selected as the user is navigating. */ |
205 |
| - autoSelectActiveOption?: boolean; |
206 |
| - /** |
207 |
| - * Whether the user is required to make a selection when |
208 |
| - * they're interacting with the autocomplete. |
209 |
| - */ |
210 |
| - requireSelection?: boolean; |
211 |
| - /** Class or list of classes to be applied to the autocomplete's overlay panel. */ |
212 |
| - overlayPanelClass?: string | string[]; |
213 |
| - /** Whether icon indicators should be hidden for single-selection. */ |
214 |
| - hideSingleSelectionIndicator?: boolean; |
215 |
| -} |
216 |
| - |
217 |
| -export declare class MatAutocompleteModule { |
218 |
| - static ɵfac: i0.ɵɵFactoryDeclaration<MatAutocompleteModule, never>; |
219 |
| - static ɵmod: i0.ɵɵNgModuleDeclaration<MatAutocompleteModule, never, [typeof i1.OverlayModule, typeof i2.MatOptionModule, typeof i2.MatCommonModule, typeof i3.MatAutocomplete, typeof i4.MatAutocompleteTrigger, typeof i5.MatAutocompleteOrigin], [typeof i6.CdkScrollableModule, typeof i3.MatAutocomplete, typeof i2.MatOptionModule, typeof i2.MatCommonModule, typeof i4.MatAutocompleteTrigger, typeof i5.MatAutocompleteOrigin]>; |
220 |
| - static ɵinj: i0.ɵɵInjectorDeclaration<MatAutocompleteModule>; |
221 |
| -} |
222 |
| - |
223 | 160 | /**
|
224 | 161 | * Directive applied to an element to make it usable
|
225 | 162 | * as a connection point for an autocomplete panel.
|
226 | 163 | */
|
227 |
| -export declare class MatAutocompleteOrigin { |
| 164 | +declare class MatAutocompleteOrigin { |
228 | 165 | elementRef: ElementRef<HTMLElement>;
|
229 | 166 | constructor(...args: unknown[]);
|
230 | 167 | static ɵfac: i0.ɵɵFactoryDeclaration<MatAutocompleteOrigin, never>;
|
231 | 168 | static ɵdir: i0.ɵɵDirectiveDeclaration<MatAutocompleteOrigin, "[matAutocompleteOrigin]", ["matAutocompleteOrigin"], {}, {}, never, never, true, never>;
|
232 | 169 | }
|
233 | 170 |
|
234 |
| -/** Event object that is emitted when an autocomplete option is selected. */ |
235 |
| -export declare class MatAutocompleteSelectedEvent { |
236 |
| - /** Reference to the autocomplete panel that emitted the event. */ |
237 |
| - source: MatAutocomplete; |
238 |
| - /** Option that was selected. */ |
239 |
| - option: MatOption; |
240 |
| - constructor( |
241 |
| - /** Reference to the autocomplete panel that emitted the event. */ |
242 |
| - source: MatAutocomplete, |
243 |
| - /** Option that was selected. */ |
244 |
| - option: MatOption); |
245 |
| -} |
246 |
| - |
| 171 | +/** |
| 172 | + * Provider that allows the autocomplete to register as a ControlValueAccessor. |
| 173 | + * @docs-private |
| 174 | + */ |
| 175 | +declare const MAT_AUTOCOMPLETE_VALUE_ACCESSOR: any; |
| 176 | +/** |
| 177 | + * Creates an error to be thrown when attempting to use an autocomplete trigger without a panel. |
| 178 | + * @docs-private |
| 179 | + */ |
| 180 | +declare function getMatAutocompleteMissingPanelError(): Error; |
| 181 | +/** Injection token that determines the scroll handling while the autocomplete panel is open. */ |
| 182 | +declare const MAT_AUTOCOMPLETE_SCROLL_STRATEGY: InjectionToken<() => ScrollStrategy>; |
| 183 | +/** @docs-private */ |
| 184 | +declare function MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY(overlay: Overlay): () => ScrollStrategy; |
| 185 | +/** @docs-private */ |
| 186 | +declare const MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY_PROVIDER: { |
| 187 | + provide: InjectionToken<() => ScrollStrategy>; |
| 188 | + deps: (typeof Overlay)[]; |
| 189 | + useFactory: typeof MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY; |
| 190 | +}; |
247 | 191 | /** Base class with all of the `MatAutocompleteTrigger` functionality. */
|
248 |
| -export declare class MatAutocompleteTrigger implements ControlValueAccessor, AfterViewInit, OnChanges, OnDestroy { |
| 192 | +declare class MatAutocompleteTrigger implements ControlValueAccessor, AfterViewInit, OnChanges, OnDestroy { |
249 | 193 | private _environmentInjector;
|
250 | 194 | private _element;
|
251 | 195 | private _overlay;
|
@@ -463,8 +407,10 @@ export declare class MatAutocompleteTrigger implements ControlValueAccessor, Aft
|
463 | 407 | static ngAcceptInputType_autocompleteDisabled: unknown;
|
464 | 408 | }
|
465 | 409 |
|
466 |
| -export { MatOptgroup } |
467 |
| - |
468 |
| -export { MatOption } |
| 410 | +declare class MatAutocompleteModule { |
| 411 | + static ɵfac: i0.ɵɵFactoryDeclaration<MatAutocompleteModule, never>; |
| 412 | + static ɵmod: i0.ɵɵNgModuleDeclaration<MatAutocompleteModule, never, [typeof i2.OverlayModule, typeof i1.MatOptionModule, typeof i1.MatCommonModule, typeof MatAutocomplete, typeof MatAutocompleteTrigger, typeof MatAutocompleteOrigin], [typeof i2$1.CdkScrollableModule, typeof MatAutocomplete, typeof i1.MatOptionModule, typeof i1.MatCommonModule, typeof MatAutocompleteTrigger, typeof MatAutocompleteOrigin]>; |
| 413 | + static ɵinj: i0.ɵɵInjectorDeclaration<MatAutocompleteModule>; |
| 414 | +} |
469 | 415 |
|
470 |
| -export { } |
| 416 | +export { MAT_AUTOCOMPLETE_DEFAULT_OPTIONS, MAT_AUTOCOMPLETE_DEFAULT_OPTIONS_FACTORY, MAT_AUTOCOMPLETE_SCROLL_STRATEGY, MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY, MAT_AUTOCOMPLETE_SCROLL_STRATEGY_FACTORY_PROVIDER, MAT_AUTOCOMPLETE_VALUE_ACCESSOR, MatAutocomplete, type MatAutocompleteActivatedEvent, type MatAutocompleteDefaultOptions, MatAutocompleteModule, MatAutocompleteOrigin, MatAutocompleteSelectedEvent, MatAutocompleteTrigger, getMatAutocompleteMissingPanelError }; |
0 commit comments