mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2026-10-07 00:07:07 +00:00
Added Control.Locate class
Control.Locate class was added to type definitions in order to access functions in ts.
This commit is contained in:
+7
-1
@@ -8,6 +8,12 @@ import * as L from 'leaflet';
|
||||
|
||||
declare module 'leaflet' {
|
||||
namespace Control {
|
||||
class Locate extends Control {
|
||||
onAdd(map: Map): HTMLElement;
|
||||
start(): void;
|
||||
stop(): void;
|
||||
setView():void;
|
||||
}
|
||||
interface LocateOptions {
|
||||
position?: string;
|
||||
layer?: Layer;
|
||||
@@ -40,6 +46,6 @@ declare module 'leaflet' {
|
||||
/**
|
||||
* Creates a Leaflet.Locate control
|
||||
*/
|
||||
function locate(options?: Control.LocateOptions): Control;
|
||||
function locate(options?: Control.LocateOptions): Control.Locate;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user