Add layerswitcher

This commit is contained in:
Willem Dantuma
2020-02-17 18:31:23 +01:00
parent fd28af2f6c
commit a8b079b72b
9 changed files with 341 additions and 132 deletions

View File

@@ -35,6 +35,7 @@ export const SELECTOVERLAYLAYER = '[Map] SelectOverlayLayers';
export const ZOOMTOEXTENT = '[Map] ZoomToExtent';
export const DOQUERY = '[Map] DoQuery';
export const SETSTYLE = '[Map] SetStyle';
export const SHOWLAYERSWITCHER = '[Map] ShowLayerSwitcher';
export class SetState implements Action {
readonly type = SETSTATE;
@@ -210,6 +211,11 @@ export class SetStyle implements Action {
constructor(public itemType:string,public style: Style | (Feature)) { }
}
export class ShowLayerSwitcher implements Action {
readonly type = SHOWLAYERSWITCHER;
constructor(public show:boolean) {}
}
export type Actions = SetMapState
| Init
| SetParent
@@ -238,5 +244,6 @@ export type Actions = SetMapState
| SetState
| SetViewExtent
| DoQuery
| SetStyle;
| SetStyle
| ShowLayerSwitcher;