source: trip-planner-front/node_modules/@angular/material/bottom-sheet/bottom-sheet.d.ts@ fa375fe

Last change on this file since fa375fe was 6a3a178, checked in by Ema <ema_spirova@…>, 3 years ago

initial commit

  • Property mode set to 100644
File size: 2.7 KB
Line 
1/**
2 * @license
3 * Copyright Google LLC All Rights Reserved.
4 *
5 * Use of this source code is governed by an MIT-style license that can be
6 * found in the LICENSE file at https://angular.io/license
7 */
8import { Overlay } from '@angular/cdk/overlay';
9import { ComponentType } from '@angular/cdk/portal';
10import { Injector, TemplateRef, InjectionToken, OnDestroy } from '@angular/core';
11import { MatBottomSheetConfig } from './bottom-sheet-config';
12import { MatBottomSheetRef } from './bottom-sheet-ref';
13/** Injection token that can be used to specify default bottom sheet options. */
14export declare const MAT_BOTTOM_SHEET_DEFAULT_OPTIONS: InjectionToken<MatBottomSheetConfig<any>>;
15/**
16 * Service to trigger Material Design bottom sheets.
17 */
18export declare class MatBottomSheet implements OnDestroy {
19 private _overlay;
20 private _injector;
21 private _parentBottomSheet;
22 private _defaultOptions?;
23 private _bottomSheetRefAtThisLevel;
24 /** Reference to the currently opened bottom sheet. */
25 get _openedBottomSheetRef(): MatBottomSheetRef<any> | null;
26 set _openedBottomSheetRef(value: MatBottomSheetRef<any> | null);
27 constructor(_overlay: Overlay, _injector: Injector, _parentBottomSheet: MatBottomSheet, _defaultOptions?: MatBottomSheetConfig<any> | undefined);
28 /**
29 * Opens a bottom sheet containing the given component.
30 * @param component Type of the component to load into the bottom sheet.
31 * @param config Extra configuration options.
32 * @returns Reference to the newly-opened bottom sheet.
33 */
34 open<T, D = any, R = any>(component: ComponentType<T>, config?: MatBottomSheetConfig<D>): MatBottomSheetRef<T, R>;
35 /**
36 * Opens a bottom sheet containing the given template.
37 * @param template TemplateRef to instantiate as the bottom sheet content.
38 * @param config Extra configuration options.
39 * @returns Reference to the newly-opened bottom sheet.
40 */
41 open<T, D = any, R = any>(template: TemplateRef<T>, config?: MatBottomSheetConfig<D>): MatBottomSheetRef<T, R>;
42 /**
43 * Dismisses the currently-visible bottom sheet.
44 * @param result Data to pass to the bottom sheet instance.
45 */
46 dismiss<R = any>(result?: R): void;
47 ngOnDestroy(): void;
48 /**
49 * Attaches the bottom sheet container component to the overlay.
50 */
51 private _attachContainer;
52 /**
53 * Creates a new overlay and places it in the correct location.
54 * @param config The user-specified bottom sheet config.
55 */
56 private _createOverlay;
57 /**
58 * Creates an injector to be used inside of a bottom sheet component.
59 * @param config Config that was used to create the bottom sheet.
60 * @param bottomSheetRef Reference to the bottom sheet.
61 */
62 private _createInjector;
63}
Note: See TracBrowser for help on using the repository browser.