1 | import { AnimationEvent as AnimationEvent_2 } from '@angular/animations';
|
2 | import { AnimationTriggerMetadata } from '@angular/animations';
|
3 | import { BreakpointObserver } from '@angular/cdk/layout';
|
4 | import { CdkDialogContainer } from '@angular/cdk/dialog';
|
5 | import { ChangeDetectorRef } from '@angular/core';
|
6 | import { ComponentType } from '@angular/cdk/portal';
|
7 | import { DialogConfig } from '@angular/cdk/dialog';
|
8 | import { DialogRef } from '@angular/cdk/dialog';
|
9 | import { Direction } from '@angular/cdk/bidi';
|
10 | import { ElementRef } from '@angular/core';
|
11 | import { EventEmitter } from '@angular/core';
|
12 | import { FocusMonitor } from '@angular/cdk/a11y';
|
13 | import { FocusTrapFactory } from '@angular/cdk/a11y';
|
14 | import * as i0 from '@angular/core';
|
15 | import * as i2 from '@angular/cdk/dialog';
|
16 | import * as i3 from '@angular/material/core';
|
17 | import * as i4 from '@angular/cdk/portal';
|
18 | import { InjectionToken } from '@angular/core';
|
19 | import { Injector } from '@angular/core';
|
20 | import { InteractivityChecker } from '@angular/cdk/a11y';
|
21 | import { NgZone } from '@angular/core';
|
22 | import { Observable } from 'rxjs';
|
23 | import { OnDestroy } from '@angular/core';
|
24 | import { Overlay } from '@angular/cdk/overlay';
|
25 | import { OverlayRef } from '@angular/cdk/overlay';
|
26 | import { ScrollStrategy } from '@angular/cdk/overlay';
|
27 | import { TemplateRef } from '@angular/core';
|
28 | import { ViewContainerRef } from '@angular/core';
|
29 |
|
30 |
|
31 | export declare type AutoFocusTarget = 'dialog' | 'first-tabbable' | 'first-heading';
|
32 |
|
33 | declare namespace i1 {
|
34 | export {
|
35 | MatBottomSheetContainer
|
36 | }
|
37 | }
|
38 |
|
39 |
|
40 | export declare const MAT_BOTTOM_SHEET_DATA: InjectionToken<any>;
|
41 |
|
42 |
|
43 | export declare const MAT_BOTTOM_SHEET_DEFAULT_OPTIONS: InjectionToken<MatBottomSheetConfig<any>>;
|
44 |
|
45 |
|
46 |
|
47 |
|
48 | export declare class MatBottomSheet implements OnDestroy {
|
49 | private _overlay;
|
50 | private _parentBottomSheet;
|
51 | private _defaultOptions?;
|
52 | private _bottomSheetRefAtThisLevel;
|
53 | private _dialog;
|
54 |
|
55 | get _openedBottomSheetRef(): MatBottomSheetRef<any> | null;
|
56 | set _openedBottomSheetRef(value: MatBottomSheetRef<any> | null);
|
57 | constructor(_overlay: Overlay, injector: Injector, _parentBottomSheet: MatBottomSheet, _defaultOptions?: MatBottomSheetConfig<any> | undefined);
|
58 | /**
|
59 | * Opens a bottom sheet containing the given component.
|
60 | * @param component Type of the component to load into the bottom sheet.
|
61 | * @param config Extra configuration options.
|
62 | * @returns Reference to the newly-opened bottom sheet.
|
63 | */
|
64 | open<T, D = any, R = any>(component: ComponentType<T>, config?: MatBottomSheetConfig<D>): MatBottomSheetRef<T, R>;
|
65 | /**
|
66 | * Opens a bottom sheet containing the given template.
|
67 | * @param template TemplateRef to instantiate as the bottom sheet content.
|
68 | * @param config Extra configuration options.
|
69 | * @returns Reference to the newly-opened bottom sheet.
|
70 | */
|
71 | open<T, D = any, R = any>(template: TemplateRef<T>, config?: MatBottomSheetConfig<D>): MatBottomSheetRef<T, R>;
|
72 | /**
|
73 | * Dismisses the currently-visible bottom sheet.
|
74 | * @param result Data to pass to the bottom sheet instance.
|
75 | */
|
76 | dismiss<R = any>(result?: R): void;
|
77 | ngOnDestroy(): void;
|
78 | static ɵfac: i0.ɵɵFactoryDeclaration<MatBottomSheet, [null, null, { optional: true; skipSelf: true; }, { optional: true; }]>;
|
79 | static ɵprov: i0.ɵɵInjectableDeclaration<MatBottomSheet>;
|
80 | }
|
81 |
|
82 |
|
83 | export declare const matBottomSheetAnimations: {
|
84 | readonly bottomSheetState: AnimationTriggerMetadata;
|
85 | };
|
86 |
|
87 |
|
88 |
|
89 |
|
90 | export declare class MatBottomSheetConfig<D = any> {
|
91 |
|
92 | viewContainerRef?: ViewContainerRef;
|
93 |
|
94 | panelClass?: string | string[];
|
95 |
|
96 | direction?: Direction;
|
97 |
|
98 | data?: D | null;
|
99 |
|
100 | hasBackdrop?: boolean;
|
101 |
|
102 | backdropClass?: string;
|
103 |
|
104 | disableClose?: boolean;
|
105 |
|
106 | ariaLabel?: string | null;
|
107 |
|
108 | ariaModal?: boolean;
|
109 | |
110 |
|
111 |
|
112 |
|
113 |
|
114 | closeOnNavigation?: boolean;
|
115 | |
116 |
|
117 |
|
118 |
|
119 |
|
120 | autoFocus?: AutoFocusTarget | string | boolean;
|
121 | |
122 |
|
123 |
|
124 |
|
125 | restoreFocus?: boolean;
|
126 |
|
127 | scrollStrategy?: ScrollStrategy;
|
128 | }
|
129 |
|
130 |
|
131 |
|
132 |
|
133 |
|
134 | export declare class MatBottomSheetContainer extends CdkDialogContainer implements OnDestroy {
|
135 | private _changeDetectorRef;
|
136 | private _breakpointSubscription;
|
137 |
|
138 | _animationState: 'void' | 'visible' | 'hidden';
|
139 |
|
140 | _animationStateChanged: EventEmitter<AnimationEvent_2>;
|
141 |
|
142 | private _destroyed;
|
143 | constructor(elementRef: ElementRef, focusTrapFactory: FocusTrapFactory, document: any, config: DialogConfig, checker: InteractivityChecker, ngZone: NgZone, overlayRef: OverlayRef, breakpointObserver: BreakpointObserver, _changeDetectorRef: ChangeDetectorRef, focusMonitor?: FocusMonitor);
|
144 | /** Begin animation of bottom sheet entrance into view. */
|
145 | enter(): void;
|
146 | /** Begin animation of the bottom sheet exiting from view. */
|
147 | exit(): void;
|
148 | ngOnDestroy(): void;
|
149 | _onAnimationDone(event: AnimationEvent_2): void;
|
150 | _onAnimationStart(event: AnimationEvent_2): void;
|
151 | protected _captureInitialFocus(): void;
|
152 | private _toggleClass;
|
153 | static ɵfac: i0.ɵɵFactoryDeclaration<MatBottomSheetContainer, [null, null, { optional: true; }, null, null, null, null, null, null, null]>;
|
154 | static ɵcmp: i0.ɵɵComponentDeclaration<MatBottomSheetContainer, "mat-bottom-sheet-container", never, {}, {}, never, never, false, never>;
|
155 | }
|
156 |
|
157 | export declare class MatBottomSheetModule {
|
158 | static ɵfac: i0.ɵɵFactoryDeclaration<MatBottomSheetModule, never>;
|
159 | static ɵmod: i0.ɵɵNgModuleDeclaration<MatBottomSheetModule, [typeof i1.MatBottomSheetContainer], [typeof i2.DialogModule, typeof i3.MatCommonModule, typeof i4.PortalModule], [typeof i1.MatBottomSheetContainer, typeof i3.MatCommonModule]>;
|
160 | static ɵinj: i0.ɵɵInjectorDeclaration<MatBottomSheetModule>;
|
161 | }
|
162 |
|
163 |
|
164 |
|
165 |
|
166 | export declare class MatBottomSheetRef<T = any, R = any> {
|
167 | private _ref;
|
168 |
|
169 | get instance(): T;
|
170 | |
171 |
|
172 |
|
173 |
|
174 | containerInstance: MatBottomSheetContainer;
|
175 |
|
176 | disableClose: boolean | undefined;
|
177 |
|
178 | private readonly _afterOpened;
|
179 |
|
180 | private _result;
|
181 |
|
182 | private _closeFallbackTimeout;
|
183 | constructor(_ref: DialogRef<R, T>, config: MatBottomSheetConfig, containerInstance: MatBottomSheetContainer);
|
184 | /**
|
185 | * Dismisses the bottom sheet.
|
186 | * @param result Data to be passed back to the bottom sheet opener.
|
187 | */
|
188 | dismiss(result?: R): void;
|
189 | /** Gets an observable that is notified when the bottom sheet is finished closing. */
|
190 | afterDismissed(): Observable<R | undefined>;
|
191 | /** Gets an observable that is notified when the bottom sheet has opened and appeared. */
|
192 | afterOpened(): Observable<void>;
|
193 | /**
|
194 | * Gets an observable that emits when the overlay's backdrop has been clicked.
|
195 | */
|
196 | backdropClick(): Observable<MouseEvent>;
|
197 | /**
|
198 | * Gets an observable that emits when keydown events are targeted on the overlay.
|
199 | */
|
200 | keydownEvents(): Observable<KeyboardEvent>;
|
201 | }
|
202 |
|
203 | export { }
|