From 4e6d6e05532f82ea79e28e9c79ef0103b12866b8 Mon Sep 17 00:00:00 2001 From: Georg Kaspar Date: Wed, 3 Jan 2018 15:46:00 +0100 Subject: [PATCH] Added Control.Locate class Control.Locate class was added to type definitions in order to access functions in ts. --- types/leaflet.locatecontrol/index.d.ts | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/types/leaflet.locatecontrol/index.d.ts b/types/leaflet.locatecontrol/index.d.ts index 35c88be5be..3ed9c7968a 100644 --- a/types/leaflet.locatecontrol/index.d.ts +++ b/types/leaflet.locatecontrol/index.d.ts @@ -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; } }