UNPKG

1.34 kBTypeScriptView Raw
1import { EventEmitter, NgZone, OnChanges, OnDestroy, OnInit, SimpleChange } from '@angular/core';
2import { Layer, LeafletEvent } from 'leaflet';
3import { LeafletDirective } from '../core/leaflet.directive';
4import * as i0 from "@angular/core";
5/**
6 * Layer directive
7 *
8 * This directive is used to directly control a single map layer. The purpose of this directive is to
9 * be used as part of a child structural directive of the map element.
10 *
11 */
12export declare class LeafletLayerDirective implements OnChanges, OnDestroy, OnInit {
13 private zone;
14 layer: Layer;
15 onAdd: EventEmitter<LeafletEvent>;
16 onRemove: EventEmitter<LeafletEvent>;
17 private onAddLayerHandler;
18 private onRemoveLayerHandler;
19 private leafletDirective;
20 constructor(leafletDirective: LeafletDirective, zone: NgZone);
21 ngOnInit(): void;
22 ngOnDestroy(): void;
23 ngOnChanges(changes: {
24 [key: string]: SimpleChange;
25 }): void;
26 private addLayerEventListeners;
27 private removeLayerEventListeners;
28 static ɵfac: i0.ɵɵFactoryDeclaration<LeafletLayerDirective, never>;
29 static ɵdir: i0.ɵɵDirectiveDeclaration<LeafletLayerDirective, "[leafletLayer]", never, { "layer": { "alias": "leafletLayer"; "required": false; }; }, { "onAdd": "leafletLayerAdd"; "onRemove": "leafletLayerRemove"; }, never, never, false, never>;
30}