@yaga/leaflet-ng2
Version:
Angular2 module for Leaflet
128 lines (127 loc) • 5.45 kB
TypeScript
import { EventEmitter } from "@angular/core";
import { Icon, LeafletEvent, Point } from "leaflet";
import { MarkerProvider } from "./marker.provider";
import * as i0 from "@angular/core";
/**
* Angular2 directive for Leaflet icons.
*
* *You can use this directive in an Angular2 template after importing `YagaModule`.*
*
* How to use in a template:
* ```html
* <yaga-map>
* <yaga-marker>
* <yaga-icon
* [iconAnchor]="..."
* [iconSize]="..."
* [popupAnchor]="..."
* [className]="..."
* [iconUrl]="..."
* [iconRetinaUrl]="..."
* [iconSize]="..."
* [iconAnchor]="..."
* [popupAnchor]="..."
* [tooltipAnchor]="..."
* [shadowUrl]="..."
* [shadowRetinaUrl]="..."
* [shadowSize]="..."
* [shadowAnchor]="...">
* </yaga-icon>
* </yaga-marker>
* </yaga-map>
* ```
*
* @link http://leafletjs.com/reference-1.2.0.html#icon Original Leaflet documentation
* @link https://leaflet-ng2.yagajs.org/latest/browser-test?grep=Icon%20Directive Unit-Test
* @link https://leaflet-ng2.yagajs.org/latest/coverage/lcov-report/lib/icon.directive.js.html Test coverage
* @link https://leaflet-ng2.yagajs.org/latest/typedoc/classes/icondirective.html API documentation
* @example https://leaflet-ng2.yagajs.org/latest/examples/icon-directive/
*/
export declare class IconDirective extends Icon {
markerProvider: MarkerProvider;
/**
* This is an EventEmitter used to notify on any change in this object. It is mainly created to provide reactions
* of the marker directive on changes.
*/
updateEvent: EventEmitter<LeafletEvent>;
constructor(markerProvider: MarkerProvider);
/**
* Input for the DOM class name.
* Use it with `<yaga-icon [className]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-classname Original Leaflet documentation
*/
set className(val: string | undefined);
get className(): string | undefined;
/**
* Input for the icon-url.
* Use it with `<yaga-icon [iconUrl]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-iconurl Original Leaflet documentation
*/
set iconUrl(val: string);
get iconUrl(): string;
/**
* Input for the icon-retina-url.
* Use it with `<yaga-icon [iconRetinaUrl]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-iconretinaurl Original Leaflet documentation
*/
set iconRetinaUrl(val: string | undefined);
get iconRetinaUrl(): string | undefined;
/**
* Input for the icon-size.
* Use it with `<yaga-icon [iconSize]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-iconsize Original Leaflet documentation
*/
set iconSize(val: Point);
get iconSize(): Point;
/**
* Input for the icon-anchor.
* Use it with `<yaga-icon [iconAnchor]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-iconanchor Original Leaflet documentation
*/
set iconAnchor(val: Point);
get iconAnchor(): Point;
/**
* Input for the popup-anchor.
* Use it with `<yaga-icon [popupAnchor]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-popupanchor Original Leaflet documentation
*/
set popupAnchor(val: Point);
get popupAnchor(): Point;
/**
* Input for the tooltip-anchor.
* Use it with `<yaga-icon [tooltipAnchor]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-tooltipanchor Original Leaflet documentation
*/
set tooltipAnchor(val: Point);
get tooltipAnchor(): Point;
/**
* Input for the shadow-url.
* Use it with `<yaga-icon [shadowUrl]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-shadowurl Original Leaflet documentation
*/
set shadowUrl(val: string | undefined);
get shadowUrl(): string | undefined;
/**
* Input for the shadow-url for retina displays.
* Use it with `<yaga-icon [shadowUrl]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-shadowretinaurl Original Leaflet documentation
*/
set shadowRetinaUrl(val: string | undefined);
get shadowRetinaUrl(): string | undefined;
/**
* Input for the shadow-size.
* Use it with `<yaga-icon [shadowSize]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-shadowsize Original Leaflet documentation
*/
set shadowSize(val: Point);
get shadowSize(): Point;
/**
* Input for the shadow-anchor.
* Use it with `<yaga-icon [shadowAnchor]="someValue">`
* @link http://leafletjs.com/reference-1.2.0.html#icon-shadowanchor Original Leaflet documentation
*/
set shadowAnchor(val: Point);
get shadowAnchor(): Point;
static ɵfac: i0.ɵɵFactoryDeclaration<IconDirective, never>;
static ɵdir: i0.ɵɵDirectiveDeclaration<IconDirective, "yaga-icon", never, { "className": "className"; "iconUrl": "iconUrl"; "iconRetinaUrl": "iconRetinaUrl"; "iconSize": "iconSize"; "iconAnchor": "iconAnchor"; "popupAnchor": "popupAnchor"; "tooltipAnchor": "tooltipAnchor"; "shadowUrl": "shadowUrl"; "shadowRetinaUrl": "shadowRetinaUrl"; "shadowSize": "shadowSize"; "shadowAnchor": "shadowAnchor"; }, { "updateEvent": "update"; }, never>;
}