add leaflet-fullscreen definitions

This commit is contained in:
William Comartin
2016-01-05 16:55:22 -05:00
parent 0078ccfafc
commit ed81eab201
2 changed files with 43 additions and 0 deletions
@@ -0,0 +1,12 @@
/// <reference path="leaflet-fullscreen.d.ts" />
var map: L.Map;
var icon: L.Control.Fullcircle = new L.control.fullcircle({
position: 'topleft',
title: 'Full Screen',
titleCancel: 'Exit Full Screen',
forceSeparateButton: false,
forcePseudoFullscreen: false
});
icon.addTo(map);
+31
View File
@@ -0,0 +1,31 @@
// Type definitions for Leaflet.fullscreen v1.3.0
// Project: https://github.com/brunob/leaflet.fullscreen
// Definitions by: William Comartin <https://github.com/wcomartin>
// Definitions: https://github.com/borisyankov/DefinitelyTyped
/// <reference path="../leaflet/leaflet.d.ts" />
declare module L {
namespace Control {
export interface Fullscreen extends L.Control {}
export interface FullscreenOptions {
position: string,
title: string,
titleCancel: string,
forceSeparateButton: boolean,
forcePseudoFullscreen: boolean
}
}
namespace control {
/**
* Creates a fullscreen control.
*/
export function fullscreen(options?: Control.FullscreenOptions): L.Control.Fullscreen;
}
}