source: trip-planner-front/node_modules/@angular/cdk/overlay/overlay-directives.d.ts@ eed0bf8

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

initial commit

  • Property mode set to 100644
File size: 8.5 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 { Direction, Directionality } from '@angular/cdk/bidi';
9import { BooleanInput } from '@angular/cdk/coercion';
10import { ElementRef, EventEmitter, InjectionToken, OnChanges, OnDestroy, SimpleChanges, TemplateRef, ViewContainerRef } from '@angular/core';
11import { Overlay } from './overlay';
12import { OverlayRef } from './overlay-ref';
13import { ConnectedOverlayPositionChange } from './position/connected-position';
14import { ConnectedPosition, FlexibleConnectedPositionStrategy } from './position/flexible-connected-position-strategy';
15import { RepositionScrollStrategy, ScrollStrategy } from './scroll/index';
16/** Injection token that determines the scroll handling while the connected overlay is open. */
17import * as ɵngcc0 from '@angular/core';
18export declare const CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY: InjectionToken<() => ScrollStrategy>;
19/**
20 * Directive applied to an element to make it usable as an origin for an Overlay using a
21 * ConnectedPositionStrategy.
22 */
23export declare class CdkOverlayOrigin {
24 /** Reference to the element on which the directive is applied. */
25 elementRef: ElementRef;
26 constructor(
27 /** Reference to the element on which the directive is applied. */
28 elementRef: ElementRef);
29 static ɵfac: ɵngcc0.ɵɵFactoryDeclaration<CdkOverlayOrigin, never>;
30 static ɵdir: ɵngcc0.ɵɵDirectiveDeclaration<CdkOverlayOrigin, "[cdk-overlay-origin], [overlay-origin], [cdkOverlayOrigin]", ["cdkOverlayOrigin"], {}, {}, never>;
31}
32/**
33 * Directive to facilitate declarative creation of an
34 * Overlay using a FlexibleConnectedPositionStrategy.
35 */
36export declare class CdkConnectedOverlay implements OnDestroy, OnChanges {
37 private _overlay;
38 private _dir;
39 private _overlayRef;
40 private _templatePortal;
41 private _hasBackdrop;
42 private _lockPosition;
43 private _growAfterOpen;
44 private _flexibleDimensions;
45 private _push;
46 private _backdropSubscription;
47 private _attachSubscription;
48 private _detachSubscription;
49 private _positionSubscription;
50 private _offsetX;
51 private _offsetY;
52 private _position;
53 private _scrollStrategyFactory;
54 /** Origin for the connected overlay. */
55 origin: CdkOverlayOrigin;
56 /** Registered connected position pairs. */
57 positions: ConnectedPosition[];
58 /**
59 * This input overrides the positions input if specified. It lets users pass
60 * in arbitrary positioning strategies.
61 */
62 positionStrategy: FlexibleConnectedPositionStrategy;
63 /** The offset in pixels for the overlay connection point on the x-axis */
64 get offsetX(): number;
65 set offsetX(offsetX: number);
66 /** The offset in pixels for the overlay connection point on the y-axis */
67 get offsetY(): number;
68 set offsetY(offsetY: number);
69 /** The width of the overlay panel. */
70 width: number | string;
71 /** The height of the overlay panel. */
72 height: number | string;
73 /** The min width of the overlay panel. */
74 minWidth: number | string;
75 /** The min height of the overlay panel. */
76 minHeight: number | string;
77 /** The custom class to be set on the backdrop element. */
78 backdropClass: string;
79 /** The custom class to add to the overlay pane element. */
80 panelClass: string | string[];
81 /** Margin between the overlay and the viewport edges. */
82 viewportMargin: number;
83 /** Strategy to be used when handling scroll events while the overlay is open. */
84 scrollStrategy: ScrollStrategy;
85 /** Whether the overlay is open. */
86 open: boolean;
87 /** Whether the overlay can be closed by user interaction. */
88 disableClose: boolean;
89 /** CSS selector which to set the transform origin. */
90 transformOriginSelector: string;
91 /** Whether or not the overlay should attach a backdrop. */
92 get hasBackdrop(): any;
93 set hasBackdrop(value: any);
94 /** Whether or not the overlay should be locked when scrolling. */
95 get lockPosition(): any;
96 set lockPosition(value: any);
97 /** Whether the overlay's width and height can be constrained to fit within the viewport. */
98 get flexibleDimensions(): boolean;
99 set flexibleDimensions(value: boolean);
100 /** Whether the overlay can grow after the initial open when flexible positioning is turned on. */
101 get growAfterOpen(): boolean;
102 set growAfterOpen(value: boolean);
103 /** Whether the overlay can be pushed on-screen if none of the provided positions fit. */
104 get push(): boolean;
105 set push(value: boolean);
106 /** Event emitted when the backdrop is clicked. */
107 readonly backdropClick: EventEmitter<MouseEvent>;
108 /** Event emitted when the position has changed. */
109 readonly positionChange: EventEmitter<ConnectedOverlayPositionChange>;
110 /** Event emitted when the overlay has been attached. */
111 readonly attach: EventEmitter<void>;
112 /** Event emitted when the overlay has been detached. */
113 readonly detach: EventEmitter<void>;
114 /** Emits when there are keyboard events that are targeted at the overlay. */
115 readonly overlayKeydown: EventEmitter<KeyboardEvent>;
116 /** Emits when there are mouse outside click events that are targeted at the overlay. */
117 readonly overlayOutsideClick: EventEmitter<MouseEvent>;
118 constructor(_overlay: Overlay, templateRef: TemplateRef<any>, viewContainerRef: ViewContainerRef, scrollStrategyFactory: any, _dir: Directionality);
119 /** The associated overlay reference. */
120 get overlayRef(): OverlayRef;
121 /** The element's layout direction. */
122 get dir(): Direction;
123 ngOnDestroy(): void;
124 ngOnChanges(changes: SimpleChanges): void;
125 /** Creates an overlay */
126 private _createOverlay;
127 /** Builds the overlay config based on the directive's inputs */
128 private _buildConfig;
129 /** Updates the state of a position strategy, based on the values of the directive inputs. */
130 private _updatePositionStrategy;
131 /** Returns the position strategy of the overlay to be set on the overlay config */
132 private _createPositionStrategy;
133 /** Attaches the overlay and subscribes to backdrop clicks if backdrop exists */
134 private _attachOverlay;
135 /** Detaches the overlay and unsubscribes to backdrop clicks if backdrop exists */
136 private _detachOverlay;
137 static ngAcceptInputType_hasBackdrop: BooleanInput;
138 static ngAcceptInputType_lockPosition: BooleanInput;
139 static ngAcceptInputType_flexibleDimensions: BooleanInput;
140 static ngAcceptInputType_growAfterOpen: BooleanInput;
141 static ngAcceptInputType_push: BooleanInput;
142 static ɵfac: ɵngcc0.ɵɵFactoryDeclaration<CdkConnectedOverlay, [null, null, null, null, { optional: true; }]>;
143 static ɵdir: ɵngcc0.ɵɵDirectiveDeclaration<CdkConnectedOverlay, "[cdk-connected-overlay], [connected-overlay], [cdkConnectedOverlay]", ["cdkConnectedOverlay"], { "viewportMargin": "cdkConnectedOverlayViewportMargin"; "open": "cdkConnectedOverlayOpen"; "disableClose": "cdkConnectedOverlayDisableClose"; "scrollStrategy": "cdkConnectedOverlayScrollStrategy"; "offsetX": "cdkConnectedOverlayOffsetX"; "offsetY": "cdkConnectedOverlayOffsetY"; "hasBackdrop": "cdkConnectedOverlayHasBackdrop"; "lockPosition": "cdkConnectedOverlayLockPosition"; "flexibleDimensions": "cdkConnectedOverlayFlexibleDimensions"; "growAfterOpen": "cdkConnectedOverlayGrowAfterOpen"; "push": "cdkConnectedOverlayPush"; "positions": "cdkConnectedOverlayPositions"; "origin": "cdkConnectedOverlayOrigin"; "positionStrategy": "cdkConnectedOverlayPositionStrategy"; "width": "cdkConnectedOverlayWidth"; "height": "cdkConnectedOverlayHeight"; "minWidth": "cdkConnectedOverlayMinWidth"; "minHeight": "cdkConnectedOverlayMinHeight"; "backdropClass": "cdkConnectedOverlayBackdropClass"; "panelClass": "cdkConnectedOverlayPanelClass"; "transformOriginSelector": "cdkConnectedOverlayTransformOriginOn"; }, { "backdropClick": "backdropClick"; "positionChange": "positionChange"; "attach": "attach"; "detach": "detach"; "overlayKeydown": "overlayKeydown"; "overlayOutsideClick": "overlayOutsideClick"; }, never>;
144}
145/** @docs-private */
146export declare function CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER_FACTORY(overlay: Overlay): () => RepositionScrollStrategy;
147/** @docs-private */
148export declare const CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER: {
149 provide: InjectionToken<() => ScrollStrategy>;
150 deps: (typeof Overlay)[];
151 useFactory: typeof CDK_CONNECTED_OVERLAY_SCROLL_STRATEGY_PROVIDER_FACTORY;
152};
153
154//# sourceMappingURL=overlay-directives.d.ts.map
Note: See TracBrowser for help on using the repository browser.