UNPKG

hmpps-open-layers-map

Version:

A native Web Component for displaying maps using OpenLayers.

34 lines (33 loc) 1.08 kB
import VectorLayer from 'ol/layer/Vector'; import VectorSource from 'ol/source/Vector'; import type Feature from 'ol/Feature'; import type Geometry from 'ol/geom/Geometry'; import type { FeatureCollection } from 'geojson'; import type { ComposableLayer } from './base'; import type { MapAdapter } from '../map-adapter'; type OLVecSource = VectorSource<Feature<Geometry>>; type OLVecLayer = VectorLayer<OLVecSource>; export type NumberingLayerOptions = { id?: string; title?: string; visible?: boolean; zIndex?: number; font?: string; fillColor?: string; strokeColor?: string; strokeWidth?: number; offsetX?: number; offsetY?: number; numberProperty?: string; geoJson: FeatureCollection; }; export declare class NumberingLayer implements ComposableLayer<OLVecLayer> { readonly id: string; private readonly options; private olLayer?; constructor(options: NumberingLayerOptions); getNativeLayer(): OLVecLayer | undefined; attach(adapter: MapAdapter): void; detach(adapter: MapAdapter): void; } export {};