leaflet-polydraw
Version:
Advanced polygon drawing and editing plugin for Leaflet with drag-and-drop, smart merging, and comprehensive editing tools
27 lines • 1.14 kB
TypeScript
import { PolygonInfo, PolygonDrawStates } from './polygon-helpers';
import { MapStateService } from './map-state';
import * as L from 'leaflet';
/**
* Service for managing polygon information and draw states.
*/
export declare class PolygonInformationService {
mapStateService: MapStateService;
private polygonInfoListeners;
private polygonDrawStateListeners;
polygonInformationStorage: PolygonInfo[];
constructor(mapStateService: MapStateService);
onPolygonInfoUpdated(callback: (info: PolygonInfo[]) => void): void;
private emitPolygonInfoUpdated;
onPolygonDrawStateUpdated(callback: (state: PolygonDrawStates) => void): void;
private emitPolygonDrawStateUpdated;
/**
* Updates the polygons and notifies the map state service.
*/
updatePolygons(): void;
saveCurrentState(): void;
deleteTrashcan(polygon: L.LatLngLiteral[][]): void;
deleteTrashCanOnMulti(polygon: L.LatLngLiteral[][][]): void;
deletePolygonInformationStorage(): void;
createPolygonInformationStorage(arrayOfFeatureGroups: any[]): void;
}
//# sourceMappingURL=polygon-information.service.d.ts.map