@opengeoweb/store 8.0.0 → 8.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (128) hide show
  1. package/README.md +0 -0
  2. package/index.esm.d.ts +0 -0
  3. package/index.esm.js +226 -148
  4. package/package.json +4 -4
  5. package/src/index.d.ts +0 -0
  6. package/src/store/app/config.d.ts +0 -0
  7. package/src/store/app/index.d.ts +0 -0
  8. package/src/store/app/reducer.d.ts +0 -0
  9. package/src/store/app/reducer.spec.d.ts +0 -0
  10. package/src/store/app/types.d.ts +0 -0
  11. package/src/store/coreModuleConfig.d.ts +0 -0
  12. package/src/store/drawingtool/config.d.ts +0 -0
  13. package/src/store/drawingtool/index.d.ts +0 -0
  14. package/src/store/drawingtool/reducer.d.ts +0 -0
  15. package/src/store/drawingtool/reducer.spec.d.ts +0 -0
  16. package/src/store/drawingtool/sagas.d.ts +0 -0
  17. package/src/store/drawingtool/sagas.spec.d.ts +0 -0
  18. package/src/store/drawingtool/selectors.d.ts +0 -0
  19. package/src/store/drawingtool/selectors.spec.d.ts +0 -0
  20. package/src/store/drawingtool/testUtils.d.ts +0 -0
  21. package/src/store/drawingtool/utils.d.ts +0 -0
  22. package/src/store/drawingtool/utils.spec.d.ts +0 -0
  23. package/src/store/generic/actions.d.ts +0 -0
  24. package/src/store/generic/config.d.ts +0 -0
  25. package/src/store/generic/index.d.ts +0 -0
  26. package/src/store/generic/sagas.d.ts +1 -0
  27. package/src/store/generic/sagas.spec.d.ts +0 -0
  28. package/src/store/generic/selectors.d.ts +0 -0
  29. package/src/store/generic/selectors.spec.d.ts +0 -0
  30. package/src/store/generic/synchronizationActions/actions.d.ts +0 -0
  31. package/src/store/generic/synchronizationActions/types.d.ts +0 -0
  32. package/src/store/generic/synchronizationGroups/__mocks__/mockState.d.ts +0 -0
  33. package/src/store/generic/synchronizationGroups/constants.d.ts +0 -0
  34. package/src/store/generic/synchronizationGroups/index.d.ts +0 -0
  35. package/src/store/generic/synchronizationGroups/reducer.d.ts +0 -0
  36. package/src/store/generic/synchronizationGroups/reducer.spec.d.ts +0 -0
  37. package/src/store/generic/synchronizationGroups/sagas.d.ts +0 -0
  38. package/src/store/generic/synchronizationGroups/sagas.spec.d.ts +0 -0
  39. package/src/store/generic/synchronizationGroups/selector.d.ts +0 -0
  40. package/src/store/generic/synchronizationGroups/selectors.d.ts +0 -0
  41. package/src/store/generic/synchronizationGroups/selectors.spec.d.ts +0 -0
  42. package/src/store/generic/synchronizationGroups/types.d.ts +0 -0
  43. package/src/store/generic/synchronizationGroups/utils.d.ts +0 -0
  44. package/src/store/generic/synchronizationGroups/utils.spec.d.ts +0 -0
  45. package/src/store/generic/types.d.ts +0 -0
  46. package/src/store/generic/utils.d.ts +0 -0
  47. package/src/store/generic/utils.spec.d.ts +0 -0
  48. package/src/store/index.d.ts +0 -0
  49. package/src/store/layerSelect/config.d.ts +0 -0
  50. package/src/store/layerSelect/index.d.ts +0 -0
  51. package/src/store/layerSelect/localStorage.d.ts +0 -0
  52. package/src/store/layerSelect/localStorage.spec.d.ts +0 -0
  53. package/src/store/layerSelect/reducer.d.ts +0 -0
  54. package/src/store/layerSelect/reducer.spec.d.ts +0 -0
  55. package/src/store/layerSelect/sagas.d.ts +0 -0
  56. package/src/store/layerSelect/sagas.spec.d.ts +0 -0
  57. package/src/store/layerSelect/selectors.d.ts +0 -0
  58. package/src/store/layerSelect/selectors.spec.d.ts +0 -0
  59. package/src/store/layerSelect/types.d.ts +0 -0
  60. package/src/store/layerSelect/utils.d.ts +0 -0
  61. package/src/store/layerSelect/utils.spec.d.ts +0 -0
  62. package/src/store/mapStore/config.d.ts +5 -0
  63. package/src/store/mapStore/index.d.ts +1 -0
  64. package/src/store/mapStore/layers/index.d.ts +0 -0
  65. package/src/store/mapStore/layers/reducer.d.ts +3 -1
  66. package/src/store/mapStore/layers/reducer.spec.d.ts +0 -0
  67. package/src/store/mapStore/layers/selectors.d.ts +13 -0
  68. package/src/store/mapStore/layers/selectors.spec.d.ts +0 -0
  69. package/src/store/mapStore/layers/types.d.ts +7 -1
  70. package/src/store/mapStore/layers/utils.d.ts +0 -0
  71. package/src/store/mapStore/layers/utils.spec.d.ts +0 -0
  72. package/src/store/mapStore/map/actions.d.ts +0 -0
  73. package/src/store/mapStore/map/constants.d.ts +0 -0
  74. package/src/store/mapStore/map/enums.d.ts +0 -0
  75. package/src/store/mapStore/map/filterLayers.d.ts +0 -0
  76. package/src/store/mapStore/map/filterLayers.spec.d.ts +0 -0
  77. package/src/store/mapStore/map/index.d.ts +0 -0
  78. package/src/store/mapStore/map/reducer.d.ts +0 -0
  79. package/src/store/mapStore/map/reducer.spec.d.ts +0 -0
  80. package/src/store/mapStore/map/replaceLayerIdsToEnsureUniqueLayerIdsInStore.d.ts +0 -0
  81. package/src/store/mapStore/map/replaceLayerIdsToEnsureUniqueLayerIdsInStore.spec.d.ts +0 -0
  82. package/src/store/mapStore/map/sagas.d.ts +0 -0
  83. package/src/store/mapStore/map/sagas.spec.d.ts +0 -0
  84. package/src/store/mapStore/map/selectors.d.ts +0 -0
  85. package/src/store/mapStore/map/selectors.spec.d.ts +0 -0
  86. package/src/store/mapStore/map/types.d.ts +0 -0
  87. package/src/store/mapStore/map/utils.d.ts +0 -0
  88. package/src/store/mapStore/map/utils.spec.d.ts +0 -0
  89. package/src/store/mapStore/service/WMS111GetCapabilitiesGeoServicesRADAR.d.ts +0 -0
  90. package/src/store/mapStore/service/index.d.ts +0 -0
  91. package/src/store/mapStore/service/reducer.d.ts +0 -0
  92. package/src/store/mapStore/service/reducer.spec.d.ts +0 -0
  93. package/src/store/mapStore/service/sagas.d.ts +0 -0
  94. package/src/store/mapStore/service/sagas.spec.d.ts +0 -0
  95. package/src/store/mapStore/service/selectors.d.ts +0 -0
  96. package/src/store/mapStore/service/selectors.spec.d.ts +0 -0
  97. package/src/store/mapStore/service/types.d.ts +0 -0
  98. package/src/store/mapStore/storeTestSettings.d.ts +0 -0
  99. package/src/store/mapStore/storeTestUtils.d.ts +0 -0
  100. package/src/store/mapStore/types.d.ts +0 -0
  101. package/src/store/router/config.d.ts +0 -0
  102. package/src/store/router/index.d.ts +0 -0
  103. package/src/store/router/reducer.d.ts +0 -0
  104. package/src/store/router/reducer.spec.d.ts +0 -0
  105. package/src/store/router/sagas.d.ts +0 -0
  106. package/src/store/router/sagas.spec.d.ts +0 -0
  107. package/src/store/router/types.d.ts +0 -0
  108. package/src/store/router/utils.d.ts +0 -0
  109. package/src/store/snackbar/config.d.ts +0 -0
  110. package/src/store/snackbar/index.d.ts +2 -0
  111. package/src/store/snackbar/reducer.d.ts +0 -0
  112. package/src/store/snackbar/reducer.spec.d.ts +0 -0
  113. package/src/store/snackbar/sagas.d.ts +0 -0
  114. package/src/store/snackbar/sagas.spec.d.ts +0 -0
  115. package/src/store/snackbar/selectors.d.ts +0 -0
  116. package/src/store/snackbar/selectors.spec.d.ts +0 -0
  117. package/src/store/snackbar/types.d.ts +0 -0
  118. package/src/store/types.d.ts +0 -0
  119. package/src/store/ui/config.d.ts +0 -0
  120. package/src/store/ui/index.d.ts +0 -0
  121. package/src/store/ui/reducer.d.ts +0 -0
  122. package/src/store/ui/reducer.spec.d.ts +0 -0
  123. package/src/store/ui/sagas.d.ts +0 -0
  124. package/src/store/ui/sagas.test.d.ts +0 -0
  125. package/src/store/ui/selectors.d.ts +0 -0
  126. package/src/store/ui/selectors.spec.d.ts +0 -0
  127. package/src/store/ui/types.d.ts +2 -1
  128. package/src/store/utils.d.ts +0 -0
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@opengeoweb/store",
3
- "version": "8.0.0",
3
+ "version": "8.2.0",
4
4
  "description": "GeoWeb Store library for the opengeoweb project",
5
5
  "license": "Apache-2.0",
6
6
  "repository": {
@@ -12,9 +12,9 @@
12
12
  "main": "./index.esm.js",
13
13
  "dependencies": {},
14
14
  "peerDependencies": {
15
- "@opengeoweb/shared": "8.0.0",
16
- "@opengeoweb/webmap": "8.0.0",
17
- "@opengeoweb/webmap-react": "8.0.0",
15
+ "@opengeoweb/shared": "8.2.0",
16
+ "@opengeoweb/webmap": "8.2.0",
17
+ "@opengeoweb/webmap-react": "8.2.0",
18
18
  "@redux-eggs/core": "2.2.0",
19
19
  "@redux-eggs/redux-toolkit": "2.2.0",
20
20
  "@redux-eggs/saga-extension": "2.2.0",
package/src/index.d.ts CHANGED
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -6,6 +6,7 @@ export declare function setTimeSaga({ payload, }: ReturnType<typeof setTime>): S
6
6
  export declare function setBBoxSaga({ payload, }: ReturnType<typeof setBbox>): SagaIterator;
7
7
  export declare function layerActionsSaga({ payload, type, }: LayerActions): SagaIterator;
8
8
  export declare function addLayerActionsSaga({ payload, type, }: ReturnType<typeof layerActions.addLayer>): SagaIterator;
9
+ export declare function duplicateMapLayerActionsSaga({ payload, }: ReturnType<typeof layerActions.duplicateMapLayer>): SagaIterator;
9
10
  export declare function deleteLayerActionsSaga({ payload, type, }: ReturnType<typeof layerActions.layerDelete>): SagaIterator;
10
11
  export declare function moveLayerActionsSaga({ payload, type, }: ReturnType<typeof mapActions.layerMoveLayer>): SagaIterator;
11
12
  export declare function setAutoLayerIdActionsSaga({ payload, type, }: ReturnType<typeof mapActions.setAutoLayerId>): SagaIterator;
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -1,4 +1,9 @@
1
1
  import { Egg } from '@redux-eggs/core';
2
2
  import { Store } from '@reduxjs/toolkit';
3
3
  import { WebMapStateModuleState } from './types';
4
+ export declare const mapStoreReducers: {
5
+ webmap: import("redux").Reducer<import("./types").WebMapState, import("redux").AnyAction>;
6
+ services: import("redux").Reducer<import("./types").ServiceState, import("redux").AnyAction>;
7
+ layers: import("redux").Reducer<import("./types").LayerState, import("redux").AnyAction>;
8
+ };
4
9
  export declare const mapStoreModuleConfig: Egg<Store<WebMapStateModuleState>>;
@@ -45,6 +45,7 @@ export declare const mapStoreActions: {
45
45
  toggleMapPinIsVisible: import("@reduxjs/toolkit").ActionCreatorWithPayload<import("./types").ToggleMapPinIsVisiblePayload, "mapReducer/toggleMapPinIsVisible">;
46
46
  setDockedLayerManagerSize: import("@reduxjs/toolkit").ActionCreatorWithPayload<import("./types").SetDockedLayerManagerSize, "mapReducer/setDockedLayerManagerSize">;
47
47
  addLayer: import("@reduxjs/toolkit").ActionCreatorWithPayload<import("./types").AddLayerPayload, "layerReducer/addLayer">;
48
+ duplicateMapLayer: import("@reduxjs/toolkit").ActionCreatorWithPayload<import("./types").DuplicateMapLayerPayload, "layerReducer/duplicateMapLayer">;
48
49
  layerChangeDimension: import("@reduxjs/toolkit").ActionCreatorWithPayload<import("./types").SetLayerDimensionPayload, "layerReducer/layerChangeDimension">;
49
50
  layerChangeEnabled: import("@reduxjs/toolkit").ActionCreatorWithPayload<import("./types").SetLayerEnabledPayload, "layerReducer/layerChangeEnabled">;
50
51
  layerChangeOpacity: import("@reduxjs/toolkit").ActionCreatorWithPayload<import("./types").SetLayerOpacityPayload, "layerReducer/layerChangeOpacity">;
File without changes
@@ -1,10 +1,11 @@
1
1
  import { Draft, PayloadAction } from '@reduxjs/toolkit';
2
2
  import { SetLayerDimensionsPayload, SetLayerStylePayload, UpdateLayerInfoPayload } from '@opengeoweb/webmap-react';
3
- import { LayerState, Layer, AddLayerPayload, SetLayerDimensionPayload, SetLayerEnabledPayload, SetLayerOpacityPayload, SetLayerNamePayload, SetLayerGeojsonPayload, DeleteLayerPayload, ErrorLayerPayload, SetLayersPayload, SetBaseLayersPayload, AddBaseLayerPayload, AddAvailableBaseLayerPayload, AddAvailableBaseLayersPayload, SetAvailableBaseLayersPayload, SetSelectedFeaturePayload, UpdateFeaturePayload, ExitFeatureDrawModePayload, ToggleFeatureModePayload, UpdateFeaturePropertiesPayload } from './types';
3
+ import { LayerState, Layer, AddLayerPayload, SetLayerDimensionPayload, SetLayerEnabledPayload, SetLayerOpacityPayload, SetLayerNamePayload, SetLayerGeojsonPayload, DeleteLayerPayload, ErrorLayerPayload, SetLayersPayload, SetBaseLayersPayload, AddBaseLayerPayload, AddAvailableBaseLayerPayload, AddAvailableBaseLayersPayload, SetAvailableBaseLayersPayload, SetSelectedFeaturePayload, UpdateFeaturePayload, ExitFeatureDrawModePayload, ToggleFeatureModePayload, UpdateFeaturePropertiesPayload, DuplicateMapLayerPayload } from './types';
4
4
  export declare const createLayer: ({ id, opacity, acceptanceTimeInMinutes, enabled, layerType, status, ...props }: Layer) => Layer;
5
5
  export declare const initialState: LayerState;
6
6
  export declare const slice: import("@reduxjs/toolkit").Slice<LayerState, {
7
7
  addLayer: (draft: Draft<LayerState>, action: PayloadAction<AddLayerPayload>) => void;
8
+ duplicateMapLayer: (draft: Draft<LayerState>, action: PayloadAction<DuplicateMapLayerPayload>) => void;
8
9
  layerChangeDimension: (draft: Draft<LayerState>, action: PayloadAction<SetLayerDimensionPayload>) => void;
9
10
  layerChangeEnabled: (draft: Draft<LayerState>, action: PayloadAction<SetLayerEnabledPayload>) => void;
10
11
  layerChangeOpacity: (draft: Draft<LayerState>, action: PayloadAction<SetLayerOpacityPayload>) => void;
@@ -35,6 +36,7 @@ export declare const slice: import("@reduxjs/toolkit").Slice<LayerState, {
35
36
  export declare const reducer: import("redux").Reducer<LayerState, import("redux").AnyAction>;
36
37
  export declare const layerActions: import("@reduxjs/toolkit").CaseReducerActions<{
37
38
  addLayer: (draft: Draft<LayerState>, action: PayloadAction<AddLayerPayload>) => void;
39
+ duplicateMapLayer: (draft: Draft<LayerState>, action: PayloadAction<DuplicateMapLayerPayload>) => void;
38
40
  layerChangeDimension: (draft: Draft<LayerState>, action: PayloadAction<SetLayerDimensionPayload>) => void;
39
41
  layerChangeEnabled: (draft: Draft<LayerState>, action: PayloadAction<SetLayerEnabledPayload>) => void;
40
42
  layerChangeOpacity: (draft: Draft<LayerState>, action: PayloadAction<SetLayerOpacityPayload>) => void;
File without changes
@@ -146,6 +146,19 @@ export declare const getLayerTimeDimension: ((state: CoreAppStore, layerId?: str
146
146
  }> & {
147
147
  clearCache: () => void;
148
148
  };
149
+ /**
150
+ * Returns a boolean indicating whether the layer has a time dimension
151
+ *
152
+ * Example: layerHasTimeDimension = getLayerHasTimeDimension(store, 'layerId_1')
153
+ * @param {object} store store: object - object from which the layers state will be extracted
154
+ * @param {string} layerId layerId: string - Id of the layer
155
+ * @returns {boolean} returnType: boolean - boolean indicating whether the layer has a time dimension
156
+ */
157
+ export declare const getLayerHasTimeDimension: ((state: CoreAppStore, layerId?: string | undefined) => boolean) & import("reselect").OutputSelectorFields<(args_0: Dimension | undefined) => boolean, {
158
+ clearCache: () => void;
159
+ }> & {
160
+ clearCache: () => void;
161
+ };
149
162
  export declare const getLayerCurrentTime: ((state: CoreAppStore, layerId?: string | undefined) => string | undefined) & import("reselect").OutputSelectorFields<(args_0: Dimension | undefined) => string | undefined, {
150
163
  clearCache: () => void;
151
164
  }> & {
File without changes
@@ -95,6 +95,12 @@ export interface AddLayerPayload {
95
95
  layer: Layer;
96
96
  origin: string;
97
97
  }
98
+ export interface DuplicateMapLayerPayload {
99
+ mapId: string;
100
+ oldLayerId: string;
101
+ newLayerId: string;
102
+ origin: string;
103
+ }
98
104
  export interface AddBaseLayerPayload {
99
105
  mapId: string;
100
106
  layerId: string;
@@ -120,7 +126,7 @@ export interface UpdateLayerInfo extends Action {
120
126
  payload: UpdateLayerInfoPayload;
121
127
  }
122
128
  export interface SetSelectedFeaturePayload extends LayerPayload {
123
- selectedFeatureIndex: number;
129
+ selectedFeatureIndex?: number;
124
130
  }
125
131
  export interface UpdateFeaturePayload extends LayerPayload {
126
132
  geojson: GeoJSON.FeatureCollection;
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -2,3 +2,5 @@ export { snackbarActions } from './reducer';
2
2
  export * as snackbarSelectors from './selectors';
3
3
  export * as snackbarTypes from './types';
4
4
  export * from './config';
5
+ export { reducer as snackbarReducer } from './reducer';
6
+ export { rootSaga as snackbarSaga } from './sagas';
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
@@ -15,7 +15,8 @@ export declare enum DialogTypes {
15
15
  DrawingTool = "drawingTool",
16
16
  DockedLayerManager = "dockedLayerManager",
17
17
  DockedDrawingTool = "dockedDrawingTool",
18
- ObjectManager = "objectManager"
18
+ ObjectManager = "objectManager",
19
+ PublicWarnings = "publicWarnings"
19
20
  }
20
21
  export type DialogType = DialogTypes | LegendDialogType | GetFeatureInfoDialogType;
21
22
  export type { Source };
File without changes