2023-04-06 16:56:41 +00:00
|
|
|
import type { LatLngBoundsExpression } from 'leaflet/src/geo/LatLngBounds';
|
|
|
|
import type { LatLngExpression } from 'leaflet/src/geo/LatLng';
|
|
|
|
import type { Layer } from 'leaflet/src/layer/Layer';
|
|
|
|
import type { CRS } from 'leaflet/src/geo/crs/CRS';
|
2023-03-31 12:54:15 +00:00
|
|
|
|
2023-04-06 16:56:41 +00:00
|
|
|
export interface MapOptions {
|
|
|
|
preferCanvas?: boolean | undefined;
|
2023-03-31 12:54:15 +00:00
|
|
|
|
2023-04-06 16:56:41 +00:00
|
|
|
// Control options
|
|
|
|
attributionControl?: boolean | undefined;
|
|
|
|
zoomControl?: boolean | undefined;
|
|
|
|
|
|
|
|
// Interaction options
|
|
|
|
closePopupOnClick?: boolean | undefined;
|
|
|
|
zoomSnap?: number | undefined;
|
|
|
|
zoomDelta?: number | undefined;
|
|
|
|
trackResize?: boolean | undefined;
|
|
|
|
boxZoom?: boolean | undefined;
|
|
|
|
// doubleClickZoom?: Zoom | undefined;
|
|
|
|
dragging?: boolean | undefined;
|
|
|
|
|
|
|
|
// Map state options
|
|
|
|
crs?: CRS | undefined;
|
|
|
|
center?: LatLngExpression | undefined;
|
|
|
|
zoom?: number | undefined;
|
|
|
|
minZoom?: number | undefined;
|
|
|
|
maxZoom?: number | undefined;
|
|
|
|
layers?: Layer[] | undefined;
|
|
|
|
maxBounds?: LatLngBoundsExpression | undefined;
|
|
|
|
// renderer?: Renderer | undefined;
|
|
|
|
|
|
|
|
// Animation options
|
|
|
|
fadeAnimation?: boolean | undefined;
|
|
|
|
markerZoomAnimation?: boolean | undefined;
|
|
|
|
transform3DLimit?: number | undefined;
|
|
|
|
zoomAnimation?: boolean | undefined;
|
|
|
|
zoomAnimationThreshold?: number | undefined;
|
2023-03-31 12:54:15 +00:00
|
|
|
|
2023-04-06 16:56:41 +00:00
|
|
|
// Panning inertia options
|
|
|
|
inertia?: boolean | undefined;
|
|
|
|
inertiaDeceleration?: number | undefined;
|
|
|
|
inertiaMaxSpeed?: number | undefined;
|
|
|
|
easeLinearity?: number | undefined;
|
|
|
|
worldCopyJump?: boolean | undefined;
|
|
|
|
maxBoundsViscosity?: number | undefined;
|
2023-03-31 12:54:15 +00:00
|
|
|
|
2023-04-06 16:56:41 +00:00
|
|
|
// Keyboard navigation options
|
|
|
|
keyboard?: boolean | undefined;
|
|
|
|
keyboardPanDelta?: number | undefined;
|
|
|
|
|
|
|
|
// Mousewheel options
|
|
|
|
// scrollWheelZoom?: Zoom | undefined;
|
|
|
|
wheelDebounceTime?: number | undefined;
|
|
|
|
wheelPxPerZoomLevel?: number | undefined;
|
|
|
|
|
|
|
|
// Touch interaction options
|
|
|
|
tap?: boolean | undefined;
|
|
|
|
tapTolerance?: number | undefined;
|
|
|
|
// touchZoom?: Zoom | undefined;
|
|
|
|
bounceAtZoomLimits?: boolean | undefined;
|
|
|
|
}
|