mirror of
https://github.com/angular/angular.git
synced 2026-09-14 13:54:52 +08:00
build: validate CDK public API using ts-api-guardian (#14131)
This commit is contained in:
committed by
Andrew Seguin
parent
096391d317
commit
09f757845c
@@ -90,7 +90,7 @@ jobs:
|
||||
|
||||
# TODO(jelbourn): Update this command to run all tests if the Bazel issues have been fixed.
|
||||
- run: bazel build src/...
|
||||
- run: bazel test src/...
|
||||
- run: bazel test src/... tools/public_api_guard/...
|
||||
|
||||
# ------------------------------------------------------------------------------------------
|
||||
# Job that runs the unit tests on locally installed browsers (Chrome and Firefox headless).
|
||||
|
||||
@@ -17,8 +17,8 @@ http_archive(
|
||||
# Add Angular source and Bazel rules.
|
||||
http_archive(
|
||||
name = "angular",
|
||||
url = "https://github.com/angular/angular/archive/7.0.3.zip",
|
||||
strip_prefix = "angular-7.0.3",
|
||||
url = "https://github.com/angular/angular/archive/2ec05415e24137d44f24b07202c34c5054c968ed.zip",
|
||||
strip_prefix = "angular-2ec05415e24137d44f24b07202c34c5054c968ed",
|
||||
)
|
||||
|
||||
# Add RxJS as repository because those are needed in order to build Angular from source.
|
||||
|
||||
@@ -0,0 +1,9 @@
|
||||
package(default_visibility=["//visibility:public"])
|
||||
|
||||
load(":generate-guard-tests.bzl", "generate_test_targets")
|
||||
|
||||
# TODO(devversion): This currently does not include the CDK portal package because
|
||||
# aliases are not supported by ts-api-guardian. Re-add once we found a solution for that.
|
||||
|
||||
# Generate the API guard test targets for each golden file in the current package.
|
||||
generate_test_targets(glob(["**/*.d.ts"]))
|
||||
Vendored
+178
@@ -0,0 +1,178 @@
|
||||
export declare class A11yModule {
|
||||
}
|
||||
|
||||
export declare class ActiveDescendantKeyManager<T> extends ListKeyManager<Highlightable & T> {
|
||||
setActiveItem(index: number): void;
|
||||
setActiveItem(item: T): void;
|
||||
}
|
||||
|
||||
export declare const ARIA_DESCRIBER_PROVIDER: {
|
||||
provide: typeof AriaDescriber;
|
||||
deps: (Optional[] | InjectionToken<any>)[];
|
||||
useFactory: typeof ARIA_DESCRIBER_PROVIDER_FACTORY;
|
||||
};
|
||||
|
||||
export declare function ARIA_DESCRIBER_PROVIDER_FACTORY(parentDispatcher: AriaDescriber, _document: any): AriaDescriber;
|
||||
|
||||
export declare class AriaDescriber implements OnDestroy {
|
||||
constructor(_document: any);
|
||||
describe(hostElement: Element, message: string): void;
|
||||
ngOnDestroy(): void;
|
||||
removeDescription(hostElement: Element, message: string): void;
|
||||
}
|
||||
|
||||
export declare type AriaLivePoliteness = 'off' | 'polite' | 'assertive';
|
||||
|
||||
export declare const CDK_DESCRIBEDBY_HOST_ATTRIBUTE = "cdk-describedby-host";
|
||||
|
||||
export declare const CDK_DESCRIBEDBY_ID_PREFIX = "cdk-describedby-message";
|
||||
|
||||
export declare class CdkAriaLive implements OnDestroy {
|
||||
politeness: AriaLivePoliteness;
|
||||
constructor(_elementRef: ElementRef, _liveAnnouncer: LiveAnnouncer, _contentObserver: ContentObserver, _ngZone: NgZone);
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare class CdkMonitorFocus implements OnDestroy {
|
||||
cdkFocusChange: EventEmitter<FocusOrigin>;
|
||||
constructor(_elementRef: ElementRef<HTMLElement>, _focusMonitor: FocusMonitor);
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare class CdkTrapFocus implements OnDestroy, AfterContentInit, DoCheck {
|
||||
autoCapture: boolean;
|
||||
enabled: boolean;
|
||||
focusTrap: FocusTrap;
|
||||
constructor(_elementRef: ElementRef<HTMLElement>, _focusTrapFactory: FocusTrapFactory, _document: any);
|
||||
ngAfterContentInit(): void;
|
||||
ngDoCheck(): void;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare const FOCUS_MONITOR_PROVIDER: {
|
||||
provide: typeof FocusMonitor;
|
||||
deps: (Optional[] | typeof NgZone | typeof Platform)[];
|
||||
useFactory: typeof FOCUS_MONITOR_PROVIDER_FACTORY;
|
||||
};
|
||||
|
||||
export declare function FOCUS_MONITOR_PROVIDER_FACTORY(parentDispatcher: FocusMonitor, ngZone: NgZone, platform: Platform): FocusMonitor;
|
||||
|
||||
export interface FocusableOption extends ListKeyManagerOption {
|
||||
focus(origin?: FocusOrigin): void;
|
||||
}
|
||||
|
||||
export declare class FocusKeyManager<T> extends ListKeyManager<FocusableOption & T> {
|
||||
setActiveItem(index: number): void;
|
||||
setActiveItem(item: T): void;
|
||||
setFocusOrigin(origin: FocusOrigin): this;
|
||||
}
|
||||
|
||||
export declare class FocusMonitor implements OnDestroy {
|
||||
constructor(_ngZone: NgZone, _platform: Platform);
|
||||
_onBlur(event: FocusEvent, element: HTMLElement): void;
|
||||
focusVia(element: ElementRef<HTMLElement>, origin: FocusOrigin, options?: FocusOptions): void;
|
||||
focusVia(element: HTMLElement, origin: FocusOrigin, options?: FocusOptions): void;
|
||||
monitor(element: HTMLElement, checkChildren?: boolean): Observable<FocusOrigin>;
|
||||
monitor(element: ElementRef<HTMLElement>, checkChildren?: boolean): Observable<FocusOrigin>;
|
||||
ngOnDestroy(): void;
|
||||
stopMonitoring(element: ElementRef<HTMLElement>): void;
|
||||
stopMonitoring(element: HTMLElement): void;
|
||||
}
|
||||
|
||||
export interface FocusOptions {
|
||||
preventScroll?: boolean;
|
||||
}
|
||||
|
||||
export declare type FocusOrigin = 'touch' | 'mouse' | 'keyboard' | 'program' | null;
|
||||
|
||||
export declare class FocusTrap {
|
||||
enabled: boolean;
|
||||
constructor(_element: HTMLElement, _checker: InteractivityChecker, _ngZone: NgZone, _document: Document, deferAnchors?: boolean);
|
||||
attachAnchors(): boolean;
|
||||
destroy(): void;
|
||||
focusFirstTabbableElement(): boolean;
|
||||
focusFirstTabbableElementWhenReady(): Promise<boolean>;
|
||||
focusInitialElement(): boolean;
|
||||
focusInitialElementWhenReady(): Promise<boolean>;
|
||||
focusLastTabbableElement(): boolean;
|
||||
focusLastTabbableElementWhenReady(): Promise<boolean>;
|
||||
hasAttached(): boolean;
|
||||
}
|
||||
|
||||
export declare class FocusTrapFactory {
|
||||
constructor(_checker: InteractivityChecker, _ngZone: NgZone, _document: any);
|
||||
create(element: HTMLElement, deferCaptureElements?: boolean): FocusTrap;
|
||||
}
|
||||
|
||||
export interface Highlightable extends ListKeyManagerOption {
|
||||
setActiveStyles(): void;
|
||||
setInactiveStyles(): void;
|
||||
}
|
||||
|
||||
export declare class InteractivityChecker {
|
||||
constructor(_platform: Platform);
|
||||
isDisabled(element: HTMLElement): boolean;
|
||||
isFocusable(element: HTMLElement): boolean;
|
||||
isTabbable(element: HTMLElement): boolean;
|
||||
isVisible(element: HTMLElement): boolean;
|
||||
}
|
||||
|
||||
export declare function isFakeMousedownFromScreenReader(event: MouseEvent): boolean;
|
||||
|
||||
export declare class ListKeyManager<T extends ListKeyManagerOption> {
|
||||
readonly activeItem: T | null;
|
||||
readonly activeItemIndex: number | null;
|
||||
change: Subject<number>;
|
||||
tabOut: Subject<void>;
|
||||
constructor(_items: QueryList<T> | T[]);
|
||||
onKeydown(event: KeyboardEvent): void;
|
||||
setActiveItem(index: number): void;
|
||||
setActiveItem(item: T): void;
|
||||
setFirstItemActive(): void;
|
||||
setLastItemActive(): void;
|
||||
setNextItemActive(): void;
|
||||
setPreviousItemActive(): void;
|
||||
skipPredicate(predicate: (item: T) => boolean): this;
|
||||
updateActiveItem(item: T): void;
|
||||
updateActiveItem(index: number): void;
|
||||
updateActiveItemIndex(index: number): void;
|
||||
withAllowedModifierKeys(keys: ListKeyManagerModifierKey[]): this;
|
||||
withHorizontalOrientation(direction: 'ltr' | 'rtl' | null): this;
|
||||
withTypeAhead(debounceInterval?: number): this;
|
||||
withVerticalOrientation(enabled?: boolean): this;
|
||||
withWrap(shouldWrap?: boolean): this;
|
||||
}
|
||||
|
||||
export declare type ListKeyManagerModifierKey = 'altKey' | 'ctrlKey' | 'metaKey' | 'shiftKey';
|
||||
|
||||
export interface ListKeyManagerOption {
|
||||
disabled?: boolean;
|
||||
getLabel?(): string;
|
||||
}
|
||||
|
||||
export declare const LIVE_ANNOUNCER_ELEMENT_TOKEN: InjectionToken<HTMLElement | null>;
|
||||
|
||||
export declare function LIVE_ANNOUNCER_ELEMENT_TOKEN_FACTORY(): null;
|
||||
|
||||
export declare const LIVE_ANNOUNCER_PROVIDER: Provider;
|
||||
|
||||
export declare function LIVE_ANNOUNCER_PROVIDER_FACTORY(parentDispatcher: LiveAnnouncer, liveElement: any, _document: any, ngZone: NgZone): LiveAnnouncer;
|
||||
|
||||
export declare class LiveAnnouncer implements OnDestroy {
|
||||
constructor(elementToken: any, _ngZone: NgZone, _document: any);
|
||||
announce(message: string): Promise<void>;
|
||||
announce(message: string, duration?: number): Promise<void>;
|
||||
announce(message: string, politeness?: AriaLivePoliteness, duration?: number): Promise<void>;
|
||||
announce(message: string, politeness?: AriaLivePoliteness): Promise<void>;
|
||||
clear(): void;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare const MESSAGES_CONTAINER_ID = "cdk-describedby-message-container";
|
||||
|
||||
export interface RegisteredMessage {
|
||||
messageElement: Element;
|
||||
referenceCount: number;
|
||||
}
|
||||
|
||||
export declare const TOUCH_BUFFER_MS = 650;
|
||||
+30
@@ -0,0 +1,30 @@
|
||||
export declare class CdkAccordion implements OnDestroy, OnChanges {
|
||||
readonly _openCloseAllActions: Subject<boolean>;
|
||||
readonly _stateChanges: Subject<SimpleChanges>;
|
||||
readonly id: string;
|
||||
multi: boolean;
|
||||
closeAll(): void;
|
||||
ngOnChanges(changes: SimpleChanges): void;
|
||||
ngOnDestroy(): void;
|
||||
openAll(): void;
|
||||
}
|
||||
|
||||
export declare class CdkAccordionItem implements OnDestroy {
|
||||
protected _expansionDispatcher: UniqueSelectionDispatcher;
|
||||
accordion: CdkAccordion;
|
||||
closed: EventEmitter<void>;
|
||||
destroyed: EventEmitter<void>;
|
||||
disabled: any;
|
||||
expanded: any;
|
||||
expandedChange: EventEmitter<boolean>;
|
||||
readonly id: string;
|
||||
opened: EventEmitter<void>;
|
||||
constructor(accordion: CdkAccordion, _changeDetectorRef: ChangeDetectorRef, _expansionDispatcher: UniqueSelectionDispatcher);
|
||||
close(): void;
|
||||
ngOnDestroy(): void;
|
||||
open(): void;
|
||||
toggle(): void;
|
||||
}
|
||||
|
||||
export declare class CdkAccordionModule {
|
||||
}
|
||||
Vendored
+22
@@ -0,0 +1,22 @@
|
||||
export declare class BidiModule {
|
||||
}
|
||||
|
||||
export declare class Dir implements Directionality, AfterContentInit, OnDestroy {
|
||||
_rawDir: string;
|
||||
change: EventEmitter<Direction>;
|
||||
dir: Direction;
|
||||
readonly value: Direction;
|
||||
ngAfterContentInit(): void;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare const DIR_DOCUMENT: InjectionToken<Document>;
|
||||
|
||||
export declare type Direction = 'ltr' | 'rtl';
|
||||
|
||||
export declare class Directionality implements OnDestroy {
|
||||
readonly change: EventEmitter<Direction>;
|
||||
readonly value: Direction;
|
||||
constructor(_document?: any);
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
Vendored
+1
@@ -0,0 +1 @@
|
||||
export declare const VERSION: Version;
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
export declare function _isNumberValue(value: any): boolean;
|
||||
|
||||
export declare function coerceArray<T>(value: T | T[]): T[];
|
||||
|
||||
export declare function coerceBooleanProperty(value: any): boolean;
|
||||
|
||||
export declare function coerceCssPixelValue(value: any): string;
|
||||
|
||||
export declare function coerceNumberProperty(value: any): number;
|
||||
export declare function coerceNumberProperty<D>(value: any, fallback: D): number | D;
|
||||
+57
@@ -0,0 +1,57 @@
|
||||
export declare class ArrayDataSource<T> extends DataSource<T> {
|
||||
constructor(_data: T[] | ReadonlyArray<T> | Observable<T[] | ReadonlyArray<T>>);
|
||||
connect(): Observable<T[] | ReadonlyArray<T>>;
|
||||
disconnect(): void;
|
||||
}
|
||||
|
||||
export interface CollectionViewer {
|
||||
viewChange: Observable<ListRange>;
|
||||
}
|
||||
|
||||
export declare abstract class DataSource<T> {
|
||||
abstract connect(collectionViewer: CollectionViewer): Observable<T[] | ReadonlyArray<T>>;
|
||||
abstract disconnect(collectionViewer: CollectionViewer): void;
|
||||
}
|
||||
|
||||
export declare function getMultipleValuesInSingleSelectionError(): Error;
|
||||
|
||||
export declare type ListRange = {
|
||||
start: number;
|
||||
end: number;
|
||||
};
|
||||
|
||||
export interface SelectionChange<T> {
|
||||
added: T[];
|
||||
removed: T[];
|
||||
source: SelectionModel<T>;
|
||||
}
|
||||
|
||||
export declare class SelectionModel<T> {
|
||||
changed: Subject<SelectionChange<T>>;
|
||||
onChange: Subject<SelectionChange<T>>;
|
||||
readonly selected: T[];
|
||||
constructor(_multiple?: boolean, initiallySelectedValues?: T[], _emitChanges?: boolean);
|
||||
clear(): void;
|
||||
deselect(...values: T[]): void;
|
||||
hasValue(): boolean;
|
||||
isEmpty(): boolean;
|
||||
isMultipleSelection(): boolean;
|
||||
isSelected(value: T): boolean;
|
||||
select(...values: T[]): void;
|
||||
sort(predicate?: (a: T, b: T) => number): void;
|
||||
toggle(value: T): void;
|
||||
}
|
||||
|
||||
export interface TreeDataNodeFlattener<T> {
|
||||
expandFlattenedNodes(nodes: T[], expansionModel: SelectionModel<T>): T[];
|
||||
flattenNodes(structuredData: any[]): T[];
|
||||
nodeDescendents(node: T, nodes: T[], onlyExpandable: boolean): void;
|
||||
}
|
||||
|
||||
export declare class UniqueSelectionDispatcher implements OnDestroy {
|
||||
listen(listener: UniqueSelectionDispatcherListener): () => void;
|
||||
ngOnDestroy(): void;
|
||||
notify(id: string, name: string): void;
|
||||
}
|
||||
|
||||
export declare type UniqueSelectionDispatcherListener = (id: string, name: string) => void;
|
||||
+183
@@ -0,0 +1,183 @@
|
||||
export declare const CDK_DRAG_CONFIG: InjectionToken<CdkDragConfig>;
|
||||
|
||||
export declare function CDK_DRAG_CONFIG_FACTORY(): CdkDragConfig;
|
||||
|
||||
export declare const CDK_DROP_LIST_CONTAINER: InjectionToken<CdkDropListContainer<any>>;
|
||||
|
||||
export declare class CdkDrag<T = any> implements AfterViewInit, OnDestroy {
|
||||
_handles: QueryList<CdkDragHandle>;
|
||||
_hasStartedDragging: boolean;
|
||||
_placeholderTemplate: CdkDragPlaceholder;
|
||||
_pointerDown: (event: TouchEvent | MouseEvent) => void;
|
||||
_previewTemplate: CdkDragPreview;
|
||||
data: T;
|
||||
dropContainer: CdkDropListContainer;
|
||||
dropped: EventEmitter<CdkDragDrop<any>>;
|
||||
element: ElementRef<HTMLElement>;
|
||||
ended: EventEmitter<CdkDragEnd>;
|
||||
entered: EventEmitter<CdkDragEnter<any>>;
|
||||
exited: EventEmitter<CdkDragExit<any>>;
|
||||
lockAxis: 'x' | 'y';
|
||||
moved: Observable<CdkDragMove<T>>;
|
||||
rootElementSelector: string;
|
||||
started: EventEmitter<CdkDragStart>;
|
||||
constructor(
|
||||
element: ElementRef<HTMLElement>,
|
||||
dropContainer: CdkDropListContainer, document: any, _ngZone: NgZone, _viewContainerRef: ViewContainerRef, _viewportRuler: ViewportRuler, _dragDropRegistry: DragDropRegistry<CdkDrag<T>, CdkDropListContainer>, _config: CdkDragConfig, _dir: Directionality);
|
||||
_isDragging(): boolean;
|
||||
getPlaceholderElement(): HTMLElement;
|
||||
getRootElement(): HTMLElement;
|
||||
ngAfterViewInit(): void;
|
||||
ngOnDestroy(): void;
|
||||
reset(): void;
|
||||
}
|
||||
|
||||
export interface CdkDragConfig {
|
||||
dragStartThreshold: number;
|
||||
pointerDirectionChangeThreshold: number;
|
||||
}
|
||||
|
||||
export interface CdkDragDrop<T, O = T> {
|
||||
container: CdkDropListContainer<T>;
|
||||
currentIndex: number;
|
||||
item: CdkDrag;
|
||||
previousContainer: CdkDropListContainer<O>;
|
||||
previousIndex: number;
|
||||
}
|
||||
|
||||
export interface CdkDragEnd<T = any> {
|
||||
source: CdkDrag<T>;
|
||||
}
|
||||
|
||||
export interface CdkDragEnter<T = any, I = T> {
|
||||
container: CdkDropListContainer<T>;
|
||||
item: CdkDrag<I>;
|
||||
}
|
||||
|
||||
export interface CdkDragExit<T = any, I = T> {
|
||||
container: CdkDropListContainer<T>;
|
||||
item: CdkDrag<I>;
|
||||
}
|
||||
|
||||
export declare class CdkDragHandle {
|
||||
_parentDrag: {} | undefined;
|
||||
element: ElementRef<HTMLElement>;
|
||||
constructor(element: ElementRef<HTMLElement>, parentDrag?: any);
|
||||
}
|
||||
|
||||
export interface CdkDragMove<T = any> {
|
||||
delta: {
|
||||
x: -1 | 0 | 1;
|
||||
y: -1 | 0 | 1;
|
||||
};
|
||||
event: MouseEvent | TouchEvent;
|
||||
pointerPosition: {
|
||||
x: number;
|
||||
y: number;
|
||||
};
|
||||
source: CdkDrag<T>;
|
||||
}
|
||||
|
||||
export declare class CdkDragPlaceholder<T = any> {
|
||||
data: T;
|
||||
templateRef: TemplateRef<T>;
|
||||
constructor(templateRef: TemplateRef<T>);
|
||||
}
|
||||
|
||||
export declare class CdkDragPreview<T = any> {
|
||||
data: T;
|
||||
templateRef: TemplateRef<T>;
|
||||
constructor(templateRef: TemplateRef<T>);
|
||||
}
|
||||
|
||||
export interface CdkDragSortEvent<T = any, I = T> {
|
||||
container: CdkDropListContainer<T>;
|
||||
currentIndex: number;
|
||||
item: CdkDrag<I>;
|
||||
previousIndex: number;
|
||||
}
|
||||
|
||||
export interface CdkDragStart<T = any> {
|
||||
source: CdkDrag<T>;
|
||||
}
|
||||
|
||||
export declare class CdkDropList<T = any> implements OnInit, OnDestroy {
|
||||
_draggables: QueryList<CdkDrag>;
|
||||
_dragging: boolean;
|
||||
connectedTo: (CdkDropList | string)[] | CdkDropList | string;
|
||||
data: T;
|
||||
dropped: EventEmitter<CdkDragDrop<T, any>>;
|
||||
element: ElementRef<HTMLElement>;
|
||||
enterPredicate: (drag: CdkDrag, drop: CdkDropList) => boolean;
|
||||
entered: EventEmitter<CdkDragEnter<T>>;
|
||||
exited: EventEmitter<CdkDragExit<T>>;
|
||||
id: string;
|
||||
lockAxis: 'x' | 'y';
|
||||
orientation: 'horizontal' | 'vertical';
|
||||
sorted: EventEmitter<CdkDragSortEvent<T>>;
|
||||
constructor(element: ElementRef<HTMLElement>, _dragDropRegistry: DragDropRegistry<CdkDrag, CdkDropList<T>>, _changeDetectorRef: ChangeDetectorRef, _dir?: Directionality | undefined, _group?: CdkDropListGroup<CdkDropList<any>> | undefined);
|
||||
_canReturnItem(x: number, y: number): boolean;
|
||||
_getSiblingContainerFromPosition(item: CdkDrag, x: number, y: number): CdkDropList | null;
|
||||
_sortItem(item: CdkDrag, pointerX: number, pointerY: number, pointerDelta: {
|
||||
x: number;
|
||||
y: number;
|
||||
}): void;
|
||||
drop(item: CdkDrag, currentIndex: number, previousContainer: CdkDropList): void;
|
||||
enter(item: CdkDrag, pointerX: number, pointerY: number): void;
|
||||
exit(item: CdkDrag): void;
|
||||
getItemIndex(item: CdkDrag): number;
|
||||
ngOnDestroy(): void;
|
||||
ngOnInit(): void;
|
||||
start(): void;
|
||||
}
|
||||
|
||||
export interface CdkDropListContainer<T = any> {
|
||||
_draggables: QueryList<CdkDrag>;
|
||||
data: T;
|
||||
element: ElementRef<HTMLElement>;
|
||||
id: string;
|
||||
lockAxis: 'x' | 'y';
|
||||
orientation: 'horizontal' | 'vertical';
|
||||
_canReturnItem(x: number, y: number): boolean;
|
||||
_getSiblingContainerFromPosition(item: CdkDrag, x: number, y: number): CdkDropListContainer | null;
|
||||
_sortItem(item: CdkDrag, pointerX: number, pointerY: number, delta: {
|
||||
x: number;
|
||||
y: number;
|
||||
}): void;
|
||||
drop(item: CdkDrag, currentIndex: number, previousContainer?: CdkDropListContainer): void;
|
||||
enter(item: CdkDrag, pointerX: number, pointerY: number): void;
|
||||
exit(item: CdkDrag): void;
|
||||
getItemIndex(item: CdkDrag): number;
|
||||
start(): void;
|
||||
}
|
||||
|
||||
export declare class CdkDropListGroup<T> implements OnDestroy {
|
||||
readonly _items: Set<T>;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare function copyArrayItem<T = any>(currentArray: T[], targetArray: T[], currentIndex: number, targetIndex: number): void;
|
||||
|
||||
export declare class DragDropModule {
|
||||
}
|
||||
|
||||
export declare class DragDropRegistry<I, C extends {
|
||||
id: string;
|
||||
}> implements OnDestroy {
|
||||
readonly pointerMove: Subject<TouchEvent | MouseEvent>;
|
||||
readonly pointerUp: Subject<TouchEvent | MouseEvent>;
|
||||
constructor(_ngZone: NgZone, _document: any);
|
||||
getDropContainer(id: string): C | undefined;
|
||||
isDragging(drag: I): boolean;
|
||||
ngOnDestroy(): void;
|
||||
registerDragItem(drag: I): void;
|
||||
registerDropContainer(drop: C): void;
|
||||
removeDragItem(drag: I): void;
|
||||
removeDropContainer(drop: C): void;
|
||||
startDragging(drag: I, event: TouchEvent | MouseEvent): void;
|
||||
stopDragging(drag: I): void;
|
||||
}
|
||||
|
||||
export declare function moveItemInArray<T = any>(array: T[], fromIndex: number, toIndex: number): void;
|
||||
|
||||
export declare function transferArrayItem<T = any>(currentArray: T[], targetArray: T[], currentIndex: number, targetIndex: number): void;
|
||||
+237
@@ -0,0 +1,237 @@
|
||||
export declare const A = 65;
|
||||
|
||||
export declare const ALT = 18;
|
||||
|
||||
export declare const APOSTROPHE = 192;
|
||||
|
||||
export declare const AT_SIGN = 64;
|
||||
|
||||
export declare const B = 66;
|
||||
|
||||
export declare const BACKSLASH = 220;
|
||||
|
||||
export declare const BACKSPACE = 8;
|
||||
|
||||
export declare const C = 67;
|
||||
|
||||
export declare const CAPS_LOCK = 20;
|
||||
|
||||
export declare const CLOSE_SQUARE_BRACKET = 221;
|
||||
|
||||
export declare const COMMA = 188;
|
||||
|
||||
export declare const CONTEXT_MENU = 93;
|
||||
|
||||
export declare const CONTROL = 17;
|
||||
|
||||
export declare const D = 68;
|
||||
|
||||
export declare const DASH = 189;
|
||||
|
||||
export declare const DELETE = 46;
|
||||
|
||||
export declare const DOWN_ARROW = 40;
|
||||
|
||||
export declare const E = 69;
|
||||
|
||||
export declare const EIGHT = 56;
|
||||
|
||||
export declare const END = 35;
|
||||
|
||||
export declare const ENTER = 13;
|
||||
|
||||
export declare const EQUALS = 187;
|
||||
|
||||
export declare const ESCAPE = 27;
|
||||
|
||||
export declare const F = 70;
|
||||
|
||||
export declare const F1 = 112;
|
||||
|
||||
export declare const F10 = 121;
|
||||
|
||||
export declare const F11 = 122;
|
||||
|
||||
export declare const F12 = 123;
|
||||
|
||||
export declare const F2 = 113;
|
||||
|
||||
export declare const F3 = 114;
|
||||
|
||||
export declare const F4 = 115;
|
||||
|
||||
export declare const F5 = 116;
|
||||
|
||||
export declare const F6 = 117;
|
||||
|
||||
export declare const F7 = 118;
|
||||
|
||||
export declare const F8 = 119;
|
||||
|
||||
export declare const F9 = 120;
|
||||
|
||||
export declare const FF_EQUALS = 61;
|
||||
|
||||
export declare const FF_MINUS = 173;
|
||||
|
||||
export declare const FF_MUTE = 181;
|
||||
|
||||
export declare const FF_SEMICOLON = 59;
|
||||
|
||||
export declare const FF_VOLUME_DOWN = 182;
|
||||
|
||||
export declare const FF_VOLUME_UP = 183;
|
||||
|
||||
export declare const FIRST_MEDIA = 166;
|
||||
|
||||
export declare const FIVE = 53;
|
||||
|
||||
export declare const FOUR = 52;
|
||||
|
||||
export declare const G = 71;
|
||||
|
||||
export declare const H = 72;
|
||||
|
||||
export declare function hasModifierKey(event: KeyboardEvent, ...modifiers: ModifierKey[]): boolean;
|
||||
|
||||
export declare const HOME = 36;
|
||||
|
||||
export declare const I = 73;
|
||||
|
||||
export declare const INSERT = 45;
|
||||
|
||||
export declare const J = 74;
|
||||
|
||||
export declare const K = 75;
|
||||
|
||||
export declare const L = 76;
|
||||
|
||||
export declare const LAST_MEDIA = 183;
|
||||
|
||||
export declare const LEFT_ARROW = 37;
|
||||
|
||||
export declare const M = 77;
|
||||
|
||||
export declare const MAC_ENTER = 3;
|
||||
|
||||
export declare const MAC_META = 224;
|
||||
|
||||
export declare const MAC_WK_CMD_LEFT = 91;
|
||||
|
||||
export declare const MAC_WK_CMD_RIGHT = 93;
|
||||
|
||||
export declare const META = 91;
|
||||
|
||||
export declare const MUTE = 173;
|
||||
|
||||
export declare const N = 78;
|
||||
|
||||
export declare const NINE = 57;
|
||||
|
||||
export declare const NUM_CENTER = 12;
|
||||
|
||||
export declare const NUM_LOCK = 144;
|
||||
|
||||
export declare const NUMPAD_DIVIDE = 111;
|
||||
|
||||
export declare const NUMPAD_EIGHT = 104;
|
||||
|
||||
export declare const NUMPAD_FIVE = 101;
|
||||
|
||||
export declare const NUMPAD_FOUR = 100;
|
||||
|
||||
export declare const NUMPAD_MINUS = 109;
|
||||
|
||||
export declare const NUMPAD_MULTIPLY = 106;
|
||||
|
||||
export declare const NUMPAD_NINE = 105;
|
||||
|
||||
export declare const NUMPAD_ONE = 97;
|
||||
|
||||
export declare const NUMPAD_PERIOD = 110;
|
||||
|
||||
export declare const NUMPAD_PLUS = 107;
|
||||
|
||||
export declare const NUMPAD_SEVEN = 103;
|
||||
|
||||
export declare const NUMPAD_SIX = 102;
|
||||
|
||||
export declare const NUMPAD_THREE = 99;
|
||||
|
||||
export declare const NUMPAD_TWO = 98;
|
||||
|
||||
export declare const NUMPAD_ZERO = 96;
|
||||
|
||||
export declare const O = 79;
|
||||
|
||||
export declare const ONE = 49;
|
||||
|
||||
export declare const OPEN_SQUARE_BRACKET = 219;
|
||||
|
||||
export declare const P = 80;
|
||||
|
||||
export declare const PAGE_DOWN = 34;
|
||||
|
||||
export declare const PAGE_UP = 33;
|
||||
|
||||
export declare const PAUSE = 19;
|
||||
|
||||
export declare const PLUS_SIGN = 43;
|
||||
|
||||
export declare const PRINT_SCREEN = 44;
|
||||
|
||||
export declare const Q = 81;
|
||||
|
||||
export declare const QUESTION_MARK = 63;
|
||||
|
||||
export declare const R = 82;
|
||||
|
||||
export declare const RIGHT_ARROW = 39;
|
||||
|
||||
export declare const S = 83;
|
||||
|
||||
export declare const SCROLL_LOCK = 145;
|
||||
|
||||
export declare const SEMICOLON = 186;
|
||||
|
||||
export declare const SEVEN = 55;
|
||||
|
||||
export declare const SHIFT = 16;
|
||||
|
||||
export declare const SINGLE_QUOTE = 222;
|
||||
|
||||
export declare const SIX = 54;
|
||||
|
||||
export declare const SLASH = 191;
|
||||
|
||||
export declare const SPACE = 32;
|
||||
|
||||
export declare const T = 84;
|
||||
|
||||
export declare const TAB = 9;
|
||||
|
||||
export declare const THREE = 51;
|
||||
|
||||
export declare const TILDE = 192;
|
||||
|
||||
export declare const TWO = 50;
|
||||
|
||||
export declare const U = 85;
|
||||
|
||||
export declare const UP_ARROW = 38;
|
||||
|
||||
export declare const V = 86;
|
||||
|
||||
export declare const VOLUME_DOWN = 174;
|
||||
|
||||
export declare const VOLUME_UP = 175;
|
||||
|
||||
export declare const W = 87;
|
||||
|
||||
export declare const X = 88;
|
||||
|
||||
export declare const Y = 89;
|
||||
|
||||
export declare const Z = 90;
|
||||
|
||||
export declare const ZERO = 48;
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
export declare class BreakpointObserver implements OnDestroy {
|
||||
constructor(mediaMatcher: MediaMatcher, zone: NgZone);
|
||||
isMatched(value: string | string[]): boolean;
|
||||
ngOnDestroy(): void;
|
||||
observe(value: string | string[]): Observable<BreakpointState>;
|
||||
}
|
||||
|
||||
export declare const Breakpoints: {
|
||||
XSmall: string;
|
||||
Small: string;
|
||||
Medium: string;
|
||||
Large: string;
|
||||
XLarge: string;
|
||||
Handset: string;
|
||||
Tablet: string;
|
||||
Web: string;
|
||||
HandsetPortrait: string;
|
||||
TabletPortrait: string;
|
||||
WebPortrait: string;
|
||||
HandsetLandscape: string;
|
||||
TabletLandscape: string;
|
||||
WebLandscape: string;
|
||||
};
|
||||
|
||||
export interface BreakpointState {
|
||||
breakpoints: {
|
||||
[key: string]: boolean;
|
||||
};
|
||||
matches: boolean;
|
||||
}
|
||||
|
||||
export declare class LayoutModule {
|
||||
}
|
||||
|
||||
export declare class MediaMatcher {
|
||||
constructor(platform: Platform);
|
||||
matchMedia(query: string): MediaQueryList;
|
||||
}
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
export declare class CdkObserveContent implements AfterContentInit, OnDestroy {
|
||||
debounce: number;
|
||||
disabled: any;
|
||||
event: EventEmitter<MutationRecord[]>;
|
||||
constructor(_contentObserver: ContentObserver, _elementRef: ElementRef<HTMLElement>, _ngZone: NgZone);
|
||||
ngAfterContentInit(): void;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare class ContentObserver implements OnDestroy {
|
||||
constructor(_mutationObserverFactory: MutationObserverFactory);
|
||||
ngOnDestroy(): void;
|
||||
observe(element: Element): Observable<MutationRecord[]>;
|
||||
observe(element: ElementRef<Element>): Observable<MutationRecord[]>;
|
||||
}
|
||||
|
||||
export declare class MutationObserverFactory {
|
||||
create(callback: MutationCallback): MutationObserver | null;
|
||||
}
|
||||
|
||||
export declare class ObserversModule {
|
||||
}
|
||||
+302
@@ -0,0 +1,302 @@
|
||||
export declare class BlockScrollStrategy implements ScrollStrategy {
|
||||
constructor(_viewportRuler: ViewportRuler, document: any);
|
||||
attach(): void;
|
||||
disable(): void;
|
||||
enable(): void;
|
||||
}
|
||||
|
||||
export declare class CdkConnectedOverlay implements OnDestroy, OnChanges {
|
||||
attach: EventEmitter<void>;
|
||||
backdropClass: string;
|
||||
backdropClick: EventEmitter<MouseEvent>;
|
||||
detach: EventEmitter<void>;
|
||||
readonly dir: Direction;
|
||||
flexibleDimensions: boolean;
|
||||
growAfterOpen: boolean;
|
||||
hasBackdrop: any;
|
||||
height: number | string;
|
||||
lockPosition: any;
|
||||
minHeight: number | string;
|
||||
minWidth: number | string;
|
||||
offsetX: number;
|
||||
offsetY: number;
|
||||
open: boolean;
|
||||
origin: CdkOverlayOrigin;
|
||||
overlayKeydown: EventEmitter<KeyboardEvent>;
|
||||
readonly overlayRef: OverlayRef;
|
||||
panelClass: string | string[];
|
||||
positionChange: EventEmitter<ConnectedOverlayPositionChange>;
|
||||
positions: ConnectedPosition[];
|
||||
push: boolean;
|
||||
scrollStrategy: ScrollStrategy;
|
||||
viewportMargin: number;
|
||||
width: number | string;
|
||||
constructor(_overlay: Overlay, templateRef: TemplateRef<any>, viewContainerRef: ViewContainerRef, scrollStrategyFactory: any, _dir: Directionality);
|
||||
ngOnChanges(changes: SimpleChanges): void;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare class CdkOverlayOrigin {
|
||||
elementRef: ElementRef;
|
||||
constructor(
|
||||
elementRef: ElementRef);
|
||||
}
|
||||
|
||||
export declare class CloseScrollStrategy implements ScrollStrategy {
|
||||
constructor(_scrollDispatcher: ScrollDispatcher, _ngZone: NgZone, _viewportRuler: ViewportRuler, _config?: CloseScrollStrategyConfig | undefined);
|
||||
attach(overlayRef: OverlayReference): void;
|
||||
disable(): void;
|
||||
enable(): void;
|
||||
}
|
||||
|
||||
export declare class ConnectedOverlayPositionChange {
|
||||
connectionPair: ConnectionPositionPair;
|
||||
scrollableViewProperties: ScrollingVisibility;
|
||||
constructor(
|
||||
connectionPair: ConnectionPositionPair,
|
||||
scrollableViewProperties: ScrollingVisibility);
|
||||
}
|
||||
|
||||
export interface ConnectedPosition {
|
||||
offsetX?: number;
|
||||
offsetY?: number;
|
||||
originX: 'start' | 'center' | 'end';
|
||||
originY: 'top' | 'center' | 'bottom';
|
||||
overlayX: 'start' | 'center' | 'end';
|
||||
overlayY: 'top' | 'center' | 'bottom';
|
||||
panelClass?: string | string[];
|
||||
weight?: number;
|
||||
}
|
||||
|
||||
export declare class ConnectedPositionStrategy implements PositionStrategy {
|
||||
readonly _isRtl: boolean;
|
||||
_positionStrategy: FlexibleConnectedPositionStrategy;
|
||||
_preferredPositions: ConnectionPositionPair[];
|
||||
readonly onPositionChange: Observable<ConnectedOverlayPositionChange>;
|
||||
readonly positions: ConnectionPositionPair[];
|
||||
constructor(originPos: OriginConnectionPosition, overlayPos: OverlayConnectionPosition, connectedTo: ElementRef<HTMLElement>, viewportRuler: ViewportRuler, document: Document, platform?: Platform);
|
||||
apply(): void;
|
||||
attach(overlayRef: OverlayReference): void;
|
||||
detach(): void;
|
||||
dispose(): void;
|
||||
recalculateLastPosition(): void;
|
||||
setOrigin(origin: ElementRef): this;
|
||||
withDirection(dir: 'ltr' | 'rtl'): this;
|
||||
withFallbackPosition(originPos: OriginConnectionPosition, overlayPos: OverlayConnectionPosition, offsetX?: number, offsetY?: number): this;
|
||||
withLockedPosition(isLocked: boolean): this;
|
||||
withOffsetX(offset: number): this;
|
||||
withOffsetY(offset: number): this;
|
||||
withPositions(positions: ConnectionPositionPair[]): this;
|
||||
withScrollableContainers(scrollables: CdkScrollable[]): void;
|
||||
}
|
||||
|
||||
export declare class ConnectionPositionPair {
|
||||
offsetX?: number | undefined;
|
||||
offsetY?: number | undefined;
|
||||
originX: HorizontalConnectionPos;
|
||||
originY: VerticalConnectionPos;
|
||||
overlayX: HorizontalConnectionPos;
|
||||
overlayY: VerticalConnectionPos;
|
||||
panelClass?: string | string[] | undefined;
|
||||
constructor(origin: OriginConnectionPosition, overlay: OverlayConnectionPosition,
|
||||
offsetX?: number | undefined,
|
||||
offsetY?: number | undefined,
|
||||
panelClass?: string | string[] | undefined);
|
||||
}
|
||||
|
||||
export declare class FlexibleConnectedPositionStrategy implements PositionStrategy {
|
||||
_preferredPositions: ConnectionPositionPair[];
|
||||
positionChanges: Observable<ConnectedOverlayPositionChange>;
|
||||
readonly positions: ConnectionPositionPair[];
|
||||
constructor(connectedTo: ElementRef | HTMLElement, _viewportRuler: ViewportRuler, _document: Document, _platform?: Platform | undefined, _overlayContainer?: OverlayContainer | undefined);
|
||||
apply(): void;
|
||||
attach(overlayRef: OverlayReference): void;
|
||||
detach(): void;
|
||||
dispose(): void;
|
||||
reapplyLastPosition(): void;
|
||||
setOrigin(origin: ElementRef | HTMLElement): this;
|
||||
withDefaultOffsetX(offset: number): this;
|
||||
withDefaultOffsetY(offset: number): this;
|
||||
withFlexibleDimensions(flexibleDimensions?: boolean): this;
|
||||
withGrowAfterOpen(growAfterOpen?: boolean): this;
|
||||
withLockedPosition(isLocked?: boolean): this;
|
||||
withPositions(positions: ConnectedPosition[]): this;
|
||||
withPush(canPush?: boolean): this;
|
||||
withScrollableContainers(scrollables: CdkScrollable[]): void;
|
||||
withTransformOriginOn(selector: string): this;
|
||||
withViewportMargin(margin: number): this;
|
||||
}
|
||||
|
||||
export declare class FullscreenOverlayContainer extends OverlayContainer implements OnDestroy {
|
||||
constructor(_document: any);
|
||||
protected _createContainer(): void;
|
||||
getFullscreenElement(): Element;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare class GlobalPositionStrategy implements PositionStrategy {
|
||||
apply(): void;
|
||||
attach(overlayRef: OverlayReference): void;
|
||||
bottom(value?: string): this;
|
||||
centerHorizontally(offset?: string): this;
|
||||
centerVertically(offset?: string): this;
|
||||
dispose(): void;
|
||||
height(value?: string): this;
|
||||
left(value?: string): this;
|
||||
right(value?: string): this;
|
||||
top(value?: string): this;
|
||||
width(value?: string): this;
|
||||
}
|
||||
|
||||
export declare type HorizontalConnectionPos = 'start' | 'center' | 'end';
|
||||
|
||||
export declare class NoopScrollStrategy implements ScrollStrategy {
|
||||
attach(): void;
|
||||
disable(): void;
|
||||
enable(): void;
|
||||
}
|
||||
|
||||
export interface OriginConnectionPosition {
|
||||
originX: HorizontalConnectionPos;
|
||||
originY: VerticalConnectionPos;
|
||||
}
|
||||
|
||||
export declare class Overlay {
|
||||
scrollStrategies: ScrollStrategyOptions;
|
||||
constructor(
|
||||
scrollStrategies: ScrollStrategyOptions, _overlayContainer: OverlayContainer, _componentFactoryResolver: ComponentFactoryResolver, _positionBuilder: OverlayPositionBuilder, _keyboardDispatcher: OverlayKeyboardDispatcher, _injector: Injector, _ngZone: NgZone, _document: any, _directionality: Directionality, _location?: Location | undefined);
|
||||
create(config?: OverlayConfig): OverlayRef;
|
||||
position(): OverlayPositionBuilder;
|
||||
}
|
||||
|
||||
export declare const OVERLAY_PROVIDERS: Provider[];
|
||||
|
||||
export declare class OverlayConfig {
|
||||
backdropClass?: string | string[];
|
||||
direction?: Direction | Directionality;
|
||||
disposeOnNavigation?: boolean;
|
||||
hasBackdrop?: boolean;
|
||||
height?: number | string;
|
||||
maxHeight?: number | string;
|
||||
maxWidth?: number | string;
|
||||
minHeight?: number | string;
|
||||
minWidth?: number | string;
|
||||
panelClass?: string | string[];
|
||||
positionStrategy?: PositionStrategy;
|
||||
scrollStrategy?: ScrollStrategy;
|
||||
width?: number | string;
|
||||
constructor(config?: OverlayConfig);
|
||||
}
|
||||
|
||||
export interface OverlayConnectionPosition {
|
||||
overlayX: HorizontalConnectionPos;
|
||||
overlayY: VerticalConnectionPos;
|
||||
}
|
||||
|
||||
export declare class OverlayContainer implements OnDestroy {
|
||||
protected _containerElement: HTMLElement;
|
||||
protected _document: any;
|
||||
constructor(_document: any);
|
||||
protected _createContainer(): void;
|
||||
getContainerElement(): HTMLElement;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare class OverlayKeyboardDispatcher implements OnDestroy {
|
||||
_attachedOverlays: OverlayRef[];
|
||||
constructor(document: any);
|
||||
add(overlayRef: OverlayRef): void;
|
||||
ngOnDestroy(): void;
|
||||
remove(overlayRef: OverlayRef): void;
|
||||
}
|
||||
|
||||
export declare class OverlayModule {
|
||||
}
|
||||
|
||||
export declare class OverlayPositionBuilder {
|
||||
constructor(_viewportRuler: ViewportRuler, _document: any, _platform?: Platform | undefined, _overlayContainer?: OverlayContainer | undefined);
|
||||
connectedTo(elementRef: ElementRef, originPos: OriginConnectionPosition, overlayPos: OverlayConnectionPosition): ConnectedPositionStrategy;
|
||||
flexibleConnectedTo(elementRef: ElementRef | HTMLElement): FlexibleConnectedPositionStrategy;
|
||||
global(): GlobalPositionStrategy;
|
||||
}
|
||||
|
||||
export declare class OverlayRef implements PortalOutlet, OverlayReference {
|
||||
_keydownEventSubscriptions: number;
|
||||
_keydownEvents: Subject<KeyboardEvent>;
|
||||
readonly backdropElement: HTMLElement | null;
|
||||
readonly hostElement: HTMLElement;
|
||||
readonly overlayElement: HTMLElement;
|
||||
constructor(_portalOutlet: PortalOutlet, _host: HTMLElement, _pane: HTMLElement, _config: ImmutableObject<OverlayConfig>, _ngZone: NgZone, _keyboardDispatcher: OverlayKeyboardDispatcher, _document: Document, _location?: Location | undefined);
|
||||
attach<T>(portal: TemplatePortal<T>): EmbeddedViewRef<T>;
|
||||
attach(portal: any): any;
|
||||
attach<T>(portal: ComponentPortal<T>): ComponentRef<T>;
|
||||
attachments(): Observable<void>;
|
||||
backdropClick(): Observable<MouseEvent>;
|
||||
detach(): any;
|
||||
detachBackdrop(): void;
|
||||
detachments(): Observable<void>;
|
||||
dispose(): void;
|
||||
getConfig(): OverlayConfig;
|
||||
getDirection(): Direction;
|
||||
hasAttached(): boolean;
|
||||
keydownEvents(): Observable<KeyboardEvent>;
|
||||
setDirection(dir: Direction | Directionality): void;
|
||||
updatePosition(): void;
|
||||
updatePositionStrategy(strategy: PositionStrategy): void;
|
||||
updateSize(sizeConfig: OverlaySizeConfig): void;
|
||||
}
|
||||
|
||||
export interface OverlaySizeConfig {
|
||||
height?: number | string;
|
||||
maxHeight?: number | string;
|
||||
maxWidth?: number | string;
|
||||
minHeight?: number | string;
|
||||
minWidth?: number | string;
|
||||
width?: number | string;
|
||||
}
|
||||
|
||||
export interface PositionStrategy {
|
||||
apply(): void;
|
||||
attach(overlayRef: OverlayReference): void;
|
||||
detach?(): void;
|
||||
dispose(): void;
|
||||
}
|
||||
|
||||
export declare class RepositionScrollStrategy implements ScrollStrategy {
|
||||
constructor(_scrollDispatcher: ScrollDispatcher, _viewportRuler: ViewportRuler, _ngZone: NgZone, _config?: RepositionScrollStrategyConfig | undefined);
|
||||
attach(overlayRef: OverlayReference): void;
|
||||
disable(): void;
|
||||
enable(): void;
|
||||
}
|
||||
|
||||
export interface RepositionScrollStrategyConfig {
|
||||
autoClose?: boolean;
|
||||
scrollThrottle?: number;
|
||||
}
|
||||
|
||||
export declare class ScrollingVisibility {
|
||||
isOriginClipped: boolean;
|
||||
isOriginOutsideView: boolean;
|
||||
isOverlayClipped: boolean;
|
||||
isOverlayOutsideView: boolean;
|
||||
}
|
||||
|
||||
export interface ScrollStrategy {
|
||||
attach: (overlayRef: OverlayReference) => void;
|
||||
disable: () => void;
|
||||
enable: () => void;
|
||||
}
|
||||
|
||||
export declare class ScrollStrategyOptions {
|
||||
block: () => BlockScrollStrategy;
|
||||
close: (config?: CloseScrollStrategyConfig | undefined) => CloseScrollStrategy;
|
||||
noop: () => NoopScrollStrategy;
|
||||
reposition: (config?: RepositionScrollStrategyConfig | undefined) => RepositionScrollStrategy;
|
||||
constructor(_scrollDispatcher: ScrollDispatcher, _viewportRuler: ViewportRuler, _ngZone: NgZone, document: any);
|
||||
}
|
||||
|
||||
export declare function validateHorizontalPosition(property: string, value: HorizontalConnectionPos): void;
|
||||
|
||||
export declare function validateVerticalPosition(property: string, value: VerticalConnectionPos): void;
|
||||
|
||||
export declare type VerticalConnectionPos = 'top' | 'center' | 'bottom';
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
export declare function getRtlScrollAxisType(): RtlScrollAxisType;
|
||||
|
||||
export declare function getSupportedInputTypes(): Set<string>;
|
||||
|
||||
export declare function normalizePassiveListenerOptions(options: AddEventListenerOptions): AddEventListenerOptions | boolean;
|
||||
|
||||
export declare class Platform {
|
||||
ANDROID: boolean;
|
||||
BLINK: boolean;
|
||||
EDGE: boolean;
|
||||
FIREFOX: boolean;
|
||||
IOS: boolean;
|
||||
SAFARI: boolean;
|
||||
TRIDENT: boolean;
|
||||
WEBKIT: boolean;
|
||||
isBrowser: boolean;
|
||||
constructor(_platformId?: Object | undefined);
|
||||
}
|
||||
|
||||
export declare class PlatformModule {
|
||||
}
|
||||
|
||||
export declare enum RtlScrollAxisType {
|
||||
NORMAL = 0,
|
||||
NEGATED = 1,
|
||||
INVERTED = 2
|
||||
}
|
||||
|
||||
export declare function supportsPassiveEventListeners(): boolean;
|
||||
|
||||
export declare function supportsScrollBehavior(): boolean;
|
||||
+199
@@ -0,0 +1,199 @@
|
||||
export declare type _Bottom = {
|
||||
bottom?: number;
|
||||
};
|
||||
|
||||
export declare type _End = {
|
||||
end?: number;
|
||||
};
|
||||
|
||||
export declare function _fixedSizeVirtualScrollStrategyFactory(fixedSizeDir: CdkFixedSizeVirtualScroll): FixedSizeVirtualScrollStrategy;
|
||||
|
||||
export declare type _Left = {
|
||||
left?: number;
|
||||
};
|
||||
|
||||
export declare type _Right = {
|
||||
right?: number;
|
||||
};
|
||||
|
||||
export declare type _Start = {
|
||||
start?: number;
|
||||
};
|
||||
|
||||
export declare type _Top = {
|
||||
top?: number;
|
||||
};
|
||||
|
||||
export declare type _Without<T> = {
|
||||
[P in keyof T]?: never;
|
||||
};
|
||||
|
||||
export declare type _XAxis = _XOR<_XOR<_Left, _Right>, _XOR<_Start, _End>>;
|
||||
|
||||
export declare type _XOR<T, U> = (_Without<T> & U) | (_Without<U> & T);
|
||||
|
||||
export declare type _YAxis = _XOR<_Top, _Bottom>;
|
||||
|
||||
export declare class CdkFixedSizeVirtualScroll implements OnChanges {
|
||||
_itemSize: number;
|
||||
_maxBufferPx: number;
|
||||
_minBufferPx: number;
|
||||
_scrollStrategy: FixedSizeVirtualScrollStrategy;
|
||||
itemSize: number;
|
||||
maxBufferPx: number;
|
||||
minBufferPx: number;
|
||||
ngOnChanges(): void;
|
||||
}
|
||||
|
||||
export declare class CdkScrollable implements OnInit, OnDestroy {
|
||||
protected dir?: Directionality | undefined;
|
||||
protected elementRef: ElementRef<HTMLElement>;
|
||||
protected ngZone: NgZone;
|
||||
protected scrollDispatcher: ScrollDispatcher;
|
||||
constructor(elementRef: ElementRef<HTMLElement>, scrollDispatcher: ScrollDispatcher, ngZone: NgZone, dir?: Directionality | undefined);
|
||||
elementScrolled(): Observable<Event>;
|
||||
getElementRef(): ElementRef<HTMLElement>;
|
||||
measureScrollOffset(from: 'top' | 'left' | 'right' | 'bottom' | 'start' | 'end'): number;
|
||||
ngOnDestroy(): void;
|
||||
ngOnInit(): void;
|
||||
scrollTo(options: ExtendedScrollToOptions): void;
|
||||
}
|
||||
|
||||
export declare class CdkVirtualForOf<T> implements CollectionViewer, DoCheck, OnDestroy {
|
||||
_cdkVirtualForOf: DataSource<T> | Observable<T[]> | NgIterable<T>;
|
||||
cdkVirtualForOf: DataSource<T> | Observable<T[]> | NgIterable<T>;
|
||||
cdkVirtualForTemplate: TemplateRef<CdkVirtualForOfContext<T>>;
|
||||
cdkVirtualForTemplateCacheSize: number;
|
||||
cdkVirtualForTrackBy: TrackByFunction<T> | undefined;
|
||||
dataStream: Observable<T[] | ReadonlyArray<T>>;
|
||||
viewChange: Subject<ListRange>;
|
||||
constructor(
|
||||
_viewContainerRef: ViewContainerRef,
|
||||
_template: TemplateRef<CdkVirtualForOfContext<T>>,
|
||||
_differs: IterableDiffers,
|
||||
_viewport: CdkVirtualScrollViewport, ngZone: NgZone);
|
||||
measureRangeSize(range: ListRange, orientation: 'horizontal' | 'vertical'): number;
|
||||
ngDoCheck(): void;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare type CdkVirtualForOfContext<T> = {
|
||||
$implicit: T;
|
||||
cdkVirtualForOf: DataSource<T> | Observable<T[]> | NgIterable<T>;
|
||||
index: number;
|
||||
count: number;
|
||||
first: boolean;
|
||||
last: boolean;
|
||||
even: boolean;
|
||||
odd: boolean;
|
||||
};
|
||||
|
||||
export declare class CdkVirtualScrollViewport extends CdkScrollable implements OnInit, OnDestroy {
|
||||
_contentWrapper: ElementRef<HTMLElement>;
|
||||
_totalContentSizeTransform: string;
|
||||
elementRef: ElementRef<HTMLElement>;
|
||||
orientation: 'horizontal' | 'vertical';
|
||||
renderedRangeStream: Observable<ListRange>;
|
||||
scrolledIndexChange: Observable<number>;
|
||||
constructor(elementRef: ElementRef<HTMLElement>, _changeDetectorRef: ChangeDetectorRef, ngZone: NgZone, _scrollStrategy: VirtualScrollStrategy, dir: Directionality, scrollDispatcher: ScrollDispatcher);
|
||||
attach(forOf: CdkVirtualForOf<any>): void;
|
||||
checkViewportSize(): void;
|
||||
detach(): void;
|
||||
getDataLength(): number;
|
||||
getOffsetToRenderedContentStart(): number | null;
|
||||
getRenderedRange(): ListRange;
|
||||
getViewportSize(): number;
|
||||
measureRangeSize(range: ListRange): number;
|
||||
measureRenderedContentSize(): number;
|
||||
measureScrollOffset(from?: 'top' | 'left' | 'right' | 'bottom' | 'start' | 'end'): number;
|
||||
ngOnDestroy(): void;
|
||||
ngOnInit(): void;
|
||||
scrollToIndex(index: number, behavior?: ScrollBehavior): void;
|
||||
scrollToOffset(offset: number, behavior?: ScrollBehavior): void;
|
||||
setRenderedContentOffset(offset: number, to?: 'to-start' | 'to-end'): void;
|
||||
setRenderedRange(range: ListRange): void;
|
||||
setTotalContentSize(size: number): void;
|
||||
}
|
||||
|
||||
export declare const DEFAULT_RESIZE_TIME = 20;
|
||||
|
||||
export declare const DEFAULT_SCROLL_TIME = 20;
|
||||
|
||||
export declare type ExtendedScrollToOptions = _XAxis & _YAxis & ScrollOptions;
|
||||
|
||||
export declare class FixedSizeVirtualScrollStrategy implements VirtualScrollStrategy {
|
||||
scrolledIndexChange: Observable<number>;
|
||||
constructor(itemSize: number, minBufferPx: number, maxBufferPx: number);
|
||||
attach(viewport: CdkVirtualScrollViewport): void;
|
||||
detach(): void;
|
||||
onContentRendered(): void;
|
||||
onContentScrolled(): void;
|
||||
onDataLengthChanged(): void;
|
||||
onRenderedOffsetChanged(): void;
|
||||
scrollToIndex(index: number, behavior: ScrollBehavior): void;
|
||||
updateItemAndBufferSize(itemSize: number, minBufferPx: number, maxBufferPx: number): void;
|
||||
}
|
||||
|
||||
export declare const SCROLL_DISPATCHER_PROVIDER: {
|
||||
provide: typeof ScrollDispatcher;
|
||||
deps: (Optional[] | typeof NgZone | typeof Platform)[];
|
||||
useFactory: typeof SCROLL_DISPATCHER_PROVIDER_FACTORY;
|
||||
};
|
||||
|
||||
export declare function SCROLL_DISPATCHER_PROVIDER_FACTORY(parentDispatcher: ScrollDispatcher, ngZone: NgZone, platform: Platform): ScrollDispatcher;
|
||||
|
||||
export declare class ScrollDispatcher implements OnDestroy {
|
||||
_globalSubscription: Subscription | null;
|
||||
scrollContainers: Map<CdkScrollable, Subscription>;
|
||||
constructor(_ngZone: NgZone, _platform: Platform);
|
||||
ancestorScrolled(elementRef: ElementRef, auditTimeInMs?: number): Observable<CdkScrollable | void>;
|
||||
deregister(scrollable: CdkScrollable): void;
|
||||
getAncestorScrollContainers(elementRef: ElementRef): CdkScrollable[];
|
||||
ngOnDestroy(): void;
|
||||
register(scrollable: CdkScrollable): void;
|
||||
scrolled(auditTimeInMs?: number): Observable<CdkScrollable | void>;
|
||||
}
|
||||
|
||||
export declare class ScrollDispatchModule {
|
||||
}
|
||||
|
||||
export declare class ScrollingModule {
|
||||
}
|
||||
|
||||
export declare const VIEWPORT_RULER_PROVIDER: {
|
||||
provide: typeof ViewportRuler;
|
||||
deps: (Optional[] | typeof NgZone | typeof Platform)[];
|
||||
useFactory: typeof VIEWPORT_RULER_PROVIDER_FACTORY;
|
||||
};
|
||||
|
||||
export declare function VIEWPORT_RULER_PROVIDER_FACTORY(parentRuler: ViewportRuler, platform: Platform, ngZone: NgZone): ViewportRuler;
|
||||
|
||||
export declare class ViewportRuler implements OnDestroy {
|
||||
constructor(_platform: Platform, ngZone: NgZone);
|
||||
change(throttleTime?: number): Observable<Event>;
|
||||
getViewportRect(): ClientRect;
|
||||
getViewportScrollPosition(): ViewportScrollPosition;
|
||||
getViewportSize(): Readonly<{
|
||||
width: number;
|
||||
height: number;
|
||||
}>;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export interface ViewportScrollPosition {
|
||||
left: number;
|
||||
top: number;
|
||||
}
|
||||
|
||||
export declare const VIRTUAL_SCROLL_STRATEGY: InjectionToken<VirtualScrollStrategy>;
|
||||
|
||||
export interface VirtualScrollStrategy {
|
||||
scrolledIndexChange: Observable<number>;
|
||||
attach(viewport: CdkVirtualScrollViewport): void;
|
||||
detach(): void;
|
||||
onContentRendered(): void;
|
||||
onContentScrolled(): void;
|
||||
onDataLengthChanged(): void;
|
||||
onRenderedOffsetChanged(): void;
|
||||
scrollToIndex(index: number, behavior: ScrollBehavior): void;
|
||||
}
|
||||
+99
@@ -0,0 +1,99 @@
|
||||
export declare class CdkStep implements OnChanges {
|
||||
_displayDefaultIndicatorType: boolean;
|
||||
_showError: boolean;
|
||||
ariaLabel: string;
|
||||
ariaLabelledby: string;
|
||||
completed: boolean;
|
||||
content: TemplateRef<any>;
|
||||
editable: boolean;
|
||||
errorMessage: string;
|
||||
hasError: boolean;
|
||||
interacted: boolean;
|
||||
label: string;
|
||||
optional: boolean;
|
||||
state: StepState;
|
||||
stepControl: AbstractControl;
|
||||
stepLabel: CdkStepLabel;
|
||||
constructor(_stepper: CdkStepper, stepperOptions?: StepperOptions);
|
||||
ngOnChanges(): void;
|
||||
reset(): void;
|
||||
select(): void;
|
||||
}
|
||||
|
||||
export declare class CdkStepHeader implements FocusableOption {
|
||||
protected _elementRef: ElementRef<HTMLElement>;
|
||||
constructor(_elementRef: ElementRef<HTMLElement>);
|
||||
focus(): void;
|
||||
}
|
||||
|
||||
export declare class CdkStepLabel {
|
||||
template: TemplateRef<any>;
|
||||
constructor(/** @docs-private */ template: TemplateRef<any>);
|
||||
}
|
||||
|
||||
export declare class CdkStepper implements AfterViewInit, OnDestroy {
|
||||
protected _destroyed: Subject<void>;
|
||||
_groupId: number;
|
||||
protected _orientation: StepperOrientation;
|
||||
_stepHeader: QueryList<FocusableOption>;
|
||||
_steps: QueryList<CdkStep>;
|
||||
linear: boolean;
|
||||
selected: CdkStep;
|
||||
selectedIndex: number;
|
||||
selectionChange: EventEmitter<StepperSelectionEvent>;
|
||||
constructor(_dir: Directionality, _changeDetectorRef: ChangeDetectorRef, _elementRef?: ElementRef<HTMLElement> | undefined, _document?: any);
|
||||
_getAnimationDirection(index: number): StepContentPositionState;
|
||||
_getFocusIndex(): number | null;
|
||||
_getIndicatorType(index: number, state?: StepState): StepState;
|
||||
_getStepContentId(i: number): string;
|
||||
_getStepLabelId(i: number): string;
|
||||
_onKeydown(event: KeyboardEvent): void;
|
||||
_stateChanged(): void;
|
||||
next(): void;
|
||||
ngAfterViewInit(): void;
|
||||
ngOnDestroy(): void;
|
||||
previous(): void;
|
||||
reset(): void;
|
||||
}
|
||||
|
||||
export declare class CdkStepperModule {
|
||||
}
|
||||
|
||||
export declare class CdkStepperNext {
|
||||
_stepper: CdkStepper;
|
||||
type: string;
|
||||
constructor(_stepper: CdkStepper);
|
||||
}
|
||||
|
||||
export declare class CdkStepperPrevious {
|
||||
_stepper: CdkStepper;
|
||||
type: string;
|
||||
constructor(_stepper: CdkStepper);
|
||||
}
|
||||
|
||||
export declare const MAT_STEPPER_GLOBAL_OPTIONS: InjectionToken<StepperOptions>;
|
||||
|
||||
export declare const STEP_STATE: {
|
||||
NUMBER: string;
|
||||
EDIT: string;
|
||||
DONE: string;
|
||||
ERROR: string;
|
||||
};
|
||||
|
||||
export declare type StepContentPositionState = 'previous' | 'current' | 'next';
|
||||
|
||||
export interface StepperOptions {
|
||||
displayDefaultIndicatorType?: boolean;
|
||||
showError?: boolean;
|
||||
}
|
||||
|
||||
export declare type StepperOrientation = 'horizontal' | 'vertical';
|
||||
|
||||
export declare class StepperSelectionEvent {
|
||||
previouslySelectedIndex: number;
|
||||
previouslySelectedStep: CdkStep;
|
||||
selectedIndex: number;
|
||||
selectedStep: CdkStep;
|
||||
}
|
||||
|
||||
export declare type StepState = 'number' | 'edit' | 'done' | 'error' | string;
|
||||
+240
@@ -0,0 +1,240 @@
|
||||
export declare const _CdkColumnDefBase: CanStickCtor & typeof CdkColumnDefBase;
|
||||
|
||||
export declare const _CdkFooterRowDefBase: CanStickCtor & typeof CdkFooterRowDefBase;
|
||||
|
||||
export declare const _CdkHeaderRowDefBase: CanStickCtor & typeof CdkHeaderRowDefBase;
|
||||
|
||||
export declare class BaseCdkCell {
|
||||
constructor(columnDef: CdkColumnDef, elementRef: ElementRef);
|
||||
}
|
||||
|
||||
export declare abstract class BaseRowDef implements OnChanges {
|
||||
protected _columnsDiffer: IterableDiffer<any>;
|
||||
protected _differs: IterableDiffers;
|
||||
columns: Iterable<string>;
|
||||
template: TemplateRef<any>;
|
||||
constructor(/** @docs-private */ template: TemplateRef<any>, _differs: IterableDiffers);
|
||||
extractCellTemplate(column: CdkColumnDef): TemplateRef<any>;
|
||||
getColumnsDiff(): IterableChanges<any> | null;
|
||||
ngOnChanges(changes: SimpleChanges): void;
|
||||
}
|
||||
|
||||
export interface CanStick {
|
||||
_hasStickyChanged: boolean;
|
||||
sticky: boolean;
|
||||
hasStickyChanged(): boolean;
|
||||
resetStickyChanged(): void;
|
||||
}
|
||||
|
||||
export declare type CanStickCtor = Constructor<CanStick>;
|
||||
|
||||
export declare const CDK_ROW_TEMPLATE = "<ng-container cdkCellOutlet></ng-container>";
|
||||
|
||||
export declare const CDK_TABLE_TEMPLATE = "\n <ng-container headerRowOutlet></ng-container>\n <ng-container rowOutlet></ng-container>\n <ng-container footerRowOutlet></ng-container>";
|
||||
|
||||
export declare class CdkCell extends BaseCdkCell {
|
||||
constructor(columnDef: CdkColumnDef, elementRef: ElementRef);
|
||||
}
|
||||
|
||||
export declare class CdkCellDef implements CellDef {
|
||||
template: TemplateRef<any>;
|
||||
constructor(/** @docs-private */ template: TemplateRef<any>);
|
||||
}
|
||||
|
||||
export declare class CdkCellOutlet implements OnDestroy {
|
||||
_viewContainer: ViewContainerRef;
|
||||
cells: CdkCellDef[];
|
||||
context: any;
|
||||
constructor(_viewContainer: ViewContainerRef);
|
||||
ngOnDestroy(): void;
|
||||
static mostRecentCellOutlet: CdkCellOutlet | null;
|
||||
}
|
||||
|
||||
export interface CdkCellOutletMultiRowContext<T> {
|
||||
$implicit?: T;
|
||||
count?: number;
|
||||
dataIndex?: number;
|
||||
even?: boolean;
|
||||
first?: boolean;
|
||||
last?: boolean;
|
||||
odd?: boolean;
|
||||
renderIndex?: number;
|
||||
}
|
||||
|
||||
export interface CdkCellOutletRowContext<T> {
|
||||
$implicit?: T;
|
||||
count?: number;
|
||||
even?: boolean;
|
||||
first?: boolean;
|
||||
index?: number;
|
||||
last?: boolean;
|
||||
odd?: boolean;
|
||||
}
|
||||
|
||||
export declare class CdkColumnDef extends _CdkColumnDefBase implements CanStick {
|
||||
_name: string;
|
||||
_stickyEnd: boolean;
|
||||
cell: CdkCellDef;
|
||||
cssClassFriendlyName: string;
|
||||
footerCell: CdkFooterCellDef;
|
||||
headerCell: CdkHeaderCellDef;
|
||||
name: string;
|
||||
stickyEnd: boolean;
|
||||
}
|
||||
|
||||
export declare class CdkColumnDefBase {
|
||||
}
|
||||
|
||||
export declare class CdkFooterCell extends BaseCdkCell {
|
||||
constructor(columnDef: CdkColumnDef, elementRef: ElementRef);
|
||||
}
|
||||
|
||||
export declare class CdkFooterCellDef implements CellDef {
|
||||
template: TemplateRef<any>;
|
||||
constructor(/** @docs-private */ template: TemplateRef<any>);
|
||||
}
|
||||
|
||||
export declare class CdkFooterRow {
|
||||
}
|
||||
|
||||
export declare class CdkFooterRowDef extends _CdkFooterRowDefBase implements CanStick, OnChanges {
|
||||
constructor(template: TemplateRef<any>, _differs: IterableDiffers);
|
||||
ngOnChanges(changes: SimpleChanges): void;
|
||||
}
|
||||
|
||||
export declare class CdkFooterRowDefBase extends BaseRowDef {
|
||||
}
|
||||
|
||||
export declare class CdkHeaderCell extends BaseCdkCell {
|
||||
constructor(columnDef: CdkColumnDef, elementRef: ElementRef);
|
||||
}
|
||||
|
||||
export declare class CdkHeaderCellDef implements CellDef {
|
||||
template: TemplateRef<any>;
|
||||
constructor(/** @docs-private */ template: TemplateRef<any>);
|
||||
}
|
||||
|
||||
export declare class CdkHeaderRow {
|
||||
}
|
||||
|
||||
export declare class CdkHeaderRowDef extends _CdkHeaderRowDefBase implements CanStick, OnChanges {
|
||||
constructor(template: TemplateRef<any>, _differs: IterableDiffers);
|
||||
ngOnChanges(changes: SimpleChanges): void;
|
||||
}
|
||||
|
||||
export declare class CdkHeaderRowDefBase extends BaseRowDef {
|
||||
}
|
||||
|
||||
export declare class CdkRow {
|
||||
}
|
||||
|
||||
export declare class CdkRowDef<T> extends BaseRowDef {
|
||||
when: (index: number, rowData: T) => boolean;
|
||||
constructor(template: TemplateRef<any>, _differs: IterableDiffers);
|
||||
}
|
||||
|
||||
export declare class CdkTable<T> implements AfterContentChecked, CollectionViewer, OnDestroy, OnInit {
|
||||
protected readonly _changeDetectorRef: ChangeDetectorRef;
|
||||
_contentColumnDefs: QueryList<CdkColumnDef>;
|
||||
_contentFooterRowDefs: QueryList<CdkFooterRowDef>;
|
||||
_contentHeaderRowDefs: QueryList<CdkHeaderRowDef>;
|
||||
_contentRowDefs: QueryList<CdkRowDef<T>>;
|
||||
protected _data: T[] | ReadonlyArray<T>;
|
||||
protected readonly _differs: IterableDiffers;
|
||||
protected readonly _dir: Directionality;
|
||||
protected readonly _elementRef: ElementRef;
|
||||
_footerRowOutlet: FooterRowOutlet;
|
||||
_headerRowOutlet: HeaderRowOutlet;
|
||||
_multiTemplateDataRows: boolean;
|
||||
_rowOutlet: DataRowOutlet;
|
||||
dataSource: CdkTableDataSourceInput<T>;
|
||||
multiTemplateDataRows: boolean;
|
||||
protected stickyCssClass: string;
|
||||
trackBy: TrackByFunction<T>;
|
||||
viewChange: BehaviorSubject<{
|
||||
start: number;
|
||||
end: number;
|
||||
}>;
|
||||
constructor(_differs: IterableDiffers, _changeDetectorRef: ChangeDetectorRef, _elementRef: ElementRef, role: string, _dir: Directionality,
|
||||
_document?: any, _platform?: Platform | undefined);
|
||||
_getRenderedRows(rowOutlet: RowOutlet): HTMLElement[];
|
||||
_getRowDefs(data: T, dataIndex: number): CdkRowDef<T>[];
|
||||
addColumnDef(columnDef: CdkColumnDef): void;
|
||||
addFooterRowDef(footerRowDef: CdkFooterRowDef): void;
|
||||
addHeaderRowDef(headerRowDef: CdkHeaderRowDef): void;
|
||||
addRowDef(rowDef: CdkRowDef<T>): void;
|
||||
ngAfterContentChecked(): void;
|
||||
ngOnDestroy(): void;
|
||||
ngOnInit(): void;
|
||||
removeColumnDef(columnDef: CdkColumnDef): void;
|
||||
removeFooterRowDef(footerRowDef: CdkFooterRowDef): void;
|
||||
removeHeaderRowDef(headerRowDef: CdkHeaderRowDef): void;
|
||||
removeRowDef(rowDef: CdkRowDef<T>): void;
|
||||
renderRows(): void;
|
||||
setFooterRowDef(footerRowDef: CdkFooterRowDef): void;
|
||||
setHeaderRowDef(headerRowDef: CdkHeaderRowDef): void;
|
||||
updateStickyColumnStyles(): void;
|
||||
updateStickyFooterRowStyles(): void;
|
||||
updateStickyHeaderRowStyles(): void;
|
||||
}
|
||||
|
||||
export declare class CdkTableModule {
|
||||
}
|
||||
|
||||
export interface CellDef {
|
||||
template: TemplateRef<any>;
|
||||
}
|
||||
|
||||
export declare type Constructor<T> = new (...args: any[]) => T;
|
||||
|
||||
export declare class DataRowOutlet implements RowOutlet {
|
||||
elementRef: ElementRef;
|
||||
viewContainer: ViewContainerRef;
|
||||
constructor(viewContainer: ViewContainerRef, elementRef: ElementRef);
|
||||
}
|
||||
|
||||
export declare class FooterRowOutlet implements RowOutlet {
|
||||
elementRef: ElementRef;
|
||||
viewContainer: ViewContainerRef;
|
||||
constructor(viewContainer: ViewContainerRef, elementRef: ElementRef);
|
||||
}
|
||||
|
||||
export declare class HeaderRowOutlet implements RowOutlet {
|
||||
elementRef: ElementRef;
|
||||
viewContainer: ViewContainerRef;
|
||||
constructor(viewContainer: ViewContainerRef, elementRef: ElementRef);
|
||||
}
|
||||
|
||||
export declare function mixinHasStickyInput<T extends Constructor<{}>>(base: T): CanStickCtor & T;
|
||||
|
||||
export interface RenderRow<T> {
|
||||
data: T;
|
||||
dataIndex: number;
|
||||
rowDef: CdkRowDef<T>;
|
||||
}
|
||||
|
||||
export interface RowContext<T> extends CdkCellOutletMultiRowContext<T>, CdkCellOutletRowContext<T> {
|
||||
}
|
||||
|
||||
export interface RowOutlet {
|
||||
viewContainer: ViewContainerRef;
|
||||
}
|
||||
|
||||
export declare const STICKY_DIRECTIONS: StickyDirection[];
|
||||
|
||||
export declare type StickyDirection = 'top' | 'bottom' | 'left' | 'right';
|
||||
|
||||
export declare class StickyStyler {
|
||||
direction: Direction;
|
||||
constructor(isNativeHtmlTable: boolean, stickCellCss: string, direction: Direction, _isBrowser?: boolean);
|
||||
_addStickyStyle(element: HTMLElement, dir: StickyDirection, dirValue: number): void;
|
||||
_getCalculatedZIndex(element: HTMLElement): string;
|
||||
_getCellWidths(row: HTMLElement): number[];
|
||||
_getStickyEndColumnPositions(widths: number[], stickyStates: boolean[]): number[];
|
||||
_getStickyStartColumnPositions(widths: number[], stickyStates: boolean[]): number[];
|
||||
_removeStickyStyle(element: HTMLElement, stickyDirections: StickyDirection[]): void;
|
||||
clearStickyPositioning(rows: HTMLElement[], stickyDirections: StickyDirection[]): void;
|
||||
stickRows(rowsToStick: HTMLElement[], stickyStates: boolean[], position: 'top' | 'bottom'): void;
|
||||
updateStickyColumns(rows: HTMLElement[], stickyStartStates: boolean[], stickyEndStates: boolean[]): void;
|
||||
updateStickyFooterContainer(tableElement: Element, stickyStates: boolean[]): void;
|
||||
}
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
export declare type AutofillEvent = {
|
||||
target: Element;
|
||||
isAutofilled: boolean;
|
||||
};
|
||||
|
||||
export declare class AutofillMonitor implements OnDestroy {
|
||||
constructor(_platform: Platform, _ngZone: NgZone);
|
||||
monitor(element: Element): Observable<AutofillEvent>;
|
||||
monitor(element: ElementRef<Element>): Observable<AutofillEvent>;
|
||||
ngOnDestroy(): void;
|
||||
stopMonitoring(element: Element): void;
|
||||
stopMonitoring(element: ElementRef<Element>): void;
|
||||
}
|
||||
|
||||
export declare class CdkAutofill implements OnDestroy, OnInit {
|
||||
cdkAutofill: EventEmitter<AutofillEvent>;
|
||||
constructor(_elementRef: ElementRef<HTMLElement>, _autofillMonitor: AutofillMonitor);
|
||||
ngOnDestroy(): void;
|
||||
ngOnInit(): void;
|
||||
}
|
||||
|
||||
export declare class CdkTextareaAutosize implements AfterViewInit, DoCheck, OnDestroy {
|
||||
enabled: boolean;
|
||||
maxRows: number;
|
||||
minRows: number;
|
||||
constructor(_elementRef: ElementRef<HTMLElement>, _platform: Platform, _ngZone: NgZone);
|
||||
_noopInputHandler(): void;
|
||||
_setMaxHeight(): void;
|
||||
_setMinHeight(): void;
|
||||
ngAfterViewInit(): void;
|
||||
ngDoCheck(): void;
|
||||
ngOnDestroy(): void;
|
||||
reset(): void;
|
||||
resizeToFitContent(force?: boolean): void;
|
||||
}
|
||||
|
||||
export declare class TextFieldModule {
|
||||
}
|
||||
Vendored
+153
@@ -0,0 +1,153 @@
|
||||
export declare abstract class BaseTreeControl<T> implements TreeControl<T> {
|
||||
dataNodes: T[];
|
||||
expansionModel: SelectionModel<T>;
|
||||
getChildren: (dataNode: T) => (Observable<T[]> | T[]);
|
||||
getLevel: (dataNode: T) => number;
|
||||
isExpandable: (dataNode: T) => boolean;
|
||||
collapse(dataNode: T): void;
|
||||
collapseAll(): void;
|
||||
collapseDescendants(dataNode: T): void;
|
||||
expand(dataNode: T): void;
|
||||
abstract expandAll(): void;
|
||||
expandDescendants(dataNode: T): void;
|
||||
abstract getDescendants(dataNode: T): T[];
|
||||
isExpanded(dataNode: T): boolean;
|
||||
toggle(dataNode: T): void;
|
||||
toggleDescendants(dataNode: T): void;
|
||||
}
|
||||
|
||||
export declare class CdkNestedTreeNode<T> extends CdkTreeNode<T> implements AfterContentInit, OnDestroy {
|
||||
protected _children: T[];
|
||||
protected _differs: IterableDiffers;
|
||||
protected _elementRef: ElementRef<HTMLElement>;
|
||||
protected _tree: CdkTree<T>;
|
||||
nodeOutlet: QueryList<CdkTreeNodeOutlet>;
|
||||
constructor(_elementRef: ElementRef<HTMLElement>, _tree: CdkTree<T>, _differs: IterableDiffers);
|
||||
protected _clear(): void;
|
||||
ngAfterContentInit(): void;
|
||||
ngOnDestroy(): void;
|
||||
protected updateChildrenNodes(children?: T[]): void;
|
||||
}
|
||||
|
||||
export declare class CdkTree<T> implements AfterContentChecked, CollectionViewer, OnDestroy, OnInit {
|
||||
_nodeDefs: QueryList<CdkTreeNodeDef<T>>;
|
||||
_nodeOutlet: CdkTreeNodeOutlet;
|
||||
dataSource: DataSource<T> | Observable<T[]> | T[];
|
||||
trackBy: TrackByFunction<T>;
|
||||
treeControl: TreeControl<T>;
|
||||
viewChange: BehaviorSubject<{
|
||||
start: number;
|
||||
end: number;
|
||||
}>;
|
||||
constructor(_differs: IterableDiffers, _changeDetectorRef: ChangeDetectorRef);
|
||||
_getNodeDef(data: T, i: number): CdkTreeNodeDef<T>;
|
||||
insertNode(nodeData: T, index: number, viewContainer?: ViewContainerRef, parentData?: T): void;
|
||||
ngAfterContentChecked(): void;
|
||||
ngOnDestroy(): void;
|
||||
ngOnInit(): void;
|
||||
renderNodeChanges(data: T[] | ReadonlyArray<T>, dataDiffer?: IterableDiffer<T>, viewContainer?: ViewContainerRef, parentData?: T): void;
|
||||
}
|
||||
|
||||
export declare class CdkTreeModule {
|
||||
}
|
||||
|
||||
export declare class CdkTreeNode<T> implements FocusableOption, OnDestroy {
|
||||
protected _data: T;
|
||||
protected _destroyed: Subject<void>;
|
||||
protected _elementRef: ElementRef<HTMLElement>;
|
||||
protected _tree: CdkTree<T>;
|
||||
data: T;
|
||||
readonly isExpanded: boolean;
|
||||
readonly level: number;
|
||||
role: 'treeitem' | 'group';
|
||||
constructor(_elementRef: ElementRef<HTMLElement>, _tree: CdkTree<T>);
|
||||
protected _setRoleFromChildren(children: T[]): void;
|
||||
protected _setRoleFromData(): void;
|
||||
focus(): void;
|
||||
ngOnDestroy(): void;
|
||||
static mostRecentTreeNode: CdkTreeNode<any> | null;
|
||||
}
|
||||
|
||||
export declare class CdkTreeNodeDef<T> {
|
||||
template: TemplateRef<any>;
|
||||
when: (index: number, nodeData: T) => boolean;
|
||||
constructor(template: TemplateRef<any>);
|
||||
}
|
||||
|
||||
export declare class CdkTreeNodeOutlet {
|
||||
viewContainer: ViewContainerRef;
|
||||
constructor(viewContainer: ViewContainerRef);
|
||||
}
|
||||
|
||||
export declare class CdkTreeNodeOutletContext<T> {
|
||||
$implicit: T;
|
||||
count?: number;
|
||||
index?: number;
|
||||
level: number;
|
||||
constructor(data: T);
|
||||
}
|
||||
|
||||
export declare class CdkTreeNodePadding<T> implements OnDestroy {
|
||||
_indent: number;
|
||||
_level: number;
|
||||
indent: number | string;
|
||||
indentUnits: string;
|
||||
level: number;
|
||||
constructor(_treeNode: CdkTreeNode<T>, _tree: CdkTree<T>, _renderer: Renderer2, _element: ElementRef<HTMLElement>, _dir: Directionality);
|
||||
_paddingIndent(): string | null;
|
||||
_setPadding(): void;
|
||||
ngOnDestroy(): void;
|
||||
}
|
||||
|
||||
export declare class CdkTreeNodeToggle<T> {
|
||||
protected _recursive: boolean;
|
||||
protected _tree: CdkTree<T>;
|
||||
protected _treeNode: CdkTreeNode<T>;
|
||||
recursive: boolean;
|
||||
constructor(_tree: CdkTree<T>, _treeNode: CdkTreeNode<T>);
|
||||
_toggle(event: Event): void;
|
||||
}
|
||||
|
||||
export declare class FlatTreeControl<T> extends BaseTreeControl<T> {
|
||||
getLevel: (dataNode: T) => number;
|
||||
isExpandable: (dataNode: T) => boolean;
|
||||
constructor(getLevel: (dataNode: T) => number, isExpandable: (dataNode: T) => boolean);
|
||||
expandAll(): void;
|
||||
getDescendants(dataNode: T): T[];
|
||||
}
|
||||
|
||||
export declare function getTreeControlFunctionsMissingError(): Error;
|
||||
|
||||
export declare function getTreeControlMissingError(): Error;
|
||||
|
||||
export declare function getTreeMissingMatchingNodeDefError(): Error;
|
||||
|
||||
export declare function getTreeMultipleDefaultNodeDefsError(): Error;
|
||||
|
||||
export declare function getTreeNoValidDataSourceError(): Error;
|
||||
|
||||
export declare class NestedTreeControl<T> extends BaseTreeControl<T> {
|
||||
getChildren: (dataNode: T) => (Observable<T[]> | T[]);
|
||||
constructor(getChildren: (dataNode: T) => (Observable<T[]> | T[]));
|
||||
protected _getDescendants(descendants: T[], dataNode: T): void;
|
||||
expandAll(): void;
|
||||
getDescendants(dataNode: T): T[];
|
||||
}
|
||||
|
||||
export interface TreeControl<T> {
|
||||
dataNodes: T[];
|
||||
expansionModel: SelectionModel<T>;
|
||||
readonly getChildren: (dataNode: T) => Observable<T[]> | T[];
|
||||
readonly getLevel: (dataNode: T) => number;
|
||||
readonly isExpandable: (dataNode: T) => boolean;
|
||||
collapse(dataNode: T): void;
|
||||
collapseAll(): void;
|
||||
collapseDescendants(dataNode: T): void;
|
||||
expand(dataNode: T): void;
|
||||
expandAll(): void;
|
||||
expandDescendants(dataNode: T): void;
|
||||
getDescendants(dataNode: T): any[];
|
||||
isExpanded(dataNode: T): boolean;
|
||||
toggle(dataNode: T): void;
|
||||
toggleDescendants(dataNode: T): void;
|
||||
}
|
||||
@@ -0,0 +1,34 @@
|
||||
load("@angular//tools/ts-api-guardian:index.bzl", "ts_api_guardian_test")
|
||||
|
||||
"""
|
||||
Macro for generating ts-api-guardian Bazel test targets. Since there are multiple golden files
|
||||
in this package, we don't want to manually set up all golden files. In order to make this
|
||||
more maintainable, we allow passing a list of golden files that will be automatically verified
|
||||
against the associated source entry point.
|
||||
"""
|
||||
def generate_test_targets(golden_files):
|
||||
for golden_file in golden_files:
|
||||
# Splits the path that is relative to the current directory into the package name and
|
||||
# entry point tail path. The package name is always the first path segment (e.g. "cdk/")
|
||||
[package_name, entry_point_tail] = golden_file.split("/", 1)
|
||||
|
||||
# Name of the entry-point (e.g. "a11y", "drag-drop", "platform")
|
||||
entry_point = entry_point_tail[:-len(".d.ts")]
|
||||
|
||||
# Construct the path to the given entry-point. Note that we also need to find a way to
|
||||
# allow guards for the primary entry-point of a package. e.g. "//src/cdk:cdk" should be also
|
||||
# validated. We achieve this by checking if the package_name is equal to the entry_point name.
|
||||
# For example: "public_api_guard/cdk/cdk.d.ts" will be the golden for the primary entry-point.
|
||||
entry_point_path = "%s" % (package_name if entry_point == package_name
|
||||
else "%s/%s" % (package_name, entry_point))
|
||||
|
||||
# Create the test rule that compares the build output with the golden file.
|
||||
ts_api_guardian_test(
|
||||
name = "%s_%s_api" % (package_name, entry_point),
|
||||
actual = "angular_material/src/%s/index.d.ts" % entry_point_path,
|
||||
data = [golden_file] + [
|
||||
"//src/%s" % (entry_point_path),
|
||||
],
|
||||
golden = "angular_material/tools/public_api_guard/%s" % golden_file,
|
||||
use_angular_tag_rules = False,
|
||||
)
|
||||
@@ -27,6 +27,9 @@
|
||||
// cause ambiguous imports. For example `setTimeout()` will return a Timer instead of a number.
|
||||
"./src/universal-app/prerender.ts",
|
||||
|
||||
// Exclude the API goldens in order to not slow-down IDE's using this tsconfig file
|
||||
"tools/public_api_guard/**/*.d.ts",
|
||||
|
||||
// IDEs should not type-check the different node_modules directories of the different packages.
|
||||
// This would cause the IDEs to be slower and also linters would check the node_modules.
|
||||
"node_modules/"
|
||||
|
||||
@@ -134,6 +134,8 @@
|
||||
},
|
||||
"linterOptions": {
|
||||
"exclude": [
|
||||
// Exclude the API golden files
|
||||
"tools/public_api_guard/**/*.d.ts",
|
||||
// Exclude schematic template files and test cases that can't be linted.
|
||||
"src/lib/schematics/ng-generate/*/files/**/*",
|
||||
"src/cdk/schematics/ng-generate/*/files/**/*",
|
||||
|
||||
Reference in New Issue
Block a user