@dynatrace/strato-geo 0.8.13 → 0.9.17
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.
- package/esm/map/MapView.js +15 -13
- package/esm/map/MapView.js.map +2 -2
- package/esm/map/components/BubbleLayer/BubbleLayer.js.map +2 -2
- package/esm/map/components/BubbleLayer/BubbleLayerTooltip.js.map +1 -1
- package/esm/map/components/BubbleLayer/functions/add-outline-size.js.map +1 -1
- package/esm/map/components/BubbleLayer/functions/build-radius-scale.js +4 -1
- package/esm/map/components/BubbleLayer/functions/build-radius-scale.js.map +2 -2
- package/esm/map/components/BubbleLayer/functions/build-stick-to-distance-expressions.js.map +1 -1
- package/esm/map/components/BubbleLayer/functions/define-radius.js.map +1 -1
- package/esm/map/components/BubbleLayer/functions/parse-bubble-data-to-geo-json.js.map +1 -1
- package/esm/map/components/ChoroplethLayer/ChoroplethLayer.js.map +2 -2
- package/esm/map/components/ChoroplethLayer/ChoroplethLayerTooltip.js.map +1 -1
- package/esm/map/components/ConnectionLayer/ConnectionLayer.js.map +1 -1
- package/esm/map/components/ConnectionLayer/ConnectionLayerDirection.js.map +1 -1
- package/esm/map/components/ConnectionLayer/ConnectionLayerTooltip.js.map +1 -1
- package/esm/map/components/ConnectionLayer/functions/get-arc-line-features.js.map +1 -1
- package/esm/map/components/ConnectionLayer/functions/get-straight-line-features.js.map +1 -1
- package/esm/map/components/ConnectionLayer/functions/parse-connection-data-to-geo-json.js.map +1 -1
- package/esm/map/components/ConnectionLayer/functions/parse-direction-data-to-geo-json.js.map +1 -1
- package/esm/map/components/DefaultTooltip/DefaultTooltip.js.map +1 -1
- package/esm/map/components/DefaultTooltip/utils/handle-copy-to-clipboard.js.map +1 -1
- package/esm/map/components/DotLayer/DotLayer.js +1 -1
- package/esm/map/components/DotLayer/DotLayer.js.map +2 -2
- package/esm/map/components/DotLayer/DotLayerTooltip.js.map +1 -1
- package/esm/map/components/DotLayer/functions/define-bearing.js.map +1 -1
- package/esm/map/components/DotLayer/functions/parse-dot-data-to-geo-json.js.map +1 -1
- package/esm/map/components/MapContent.js.map +2 -2
- package/esm/map/components/legend/CategoricalLegendRenderer.js.map +2 -2
- package/esm/map/components/legend/SequentialLegendRenderer.js.map +1 -1
- package/esm/map/components/legend/ThresholdLegendRenderer.js.map +1 -1
- package/esm/map/components/legend/functions/resolve-color.js.map +1 -1
- package/esm/map/components/toolbar/constants.js.map +1 -1
- package/esm/map/components/toolbar/functions/a11y-toolbar-controls.js.map +1 -1
- package/esm/map/components/toolbar/hooks/use-a11y-toolbar-tab-index.js.map +1 -1
- package/esm/map/constants.js +4 -2
- package/esm/map/constants.js.map +2 -2
- package/esm/map/contexts/a11y-toolbar-tab-index.context.js.map +1 -1
- package/esm/map/contexts/color-scale.context.js.map +1 -1
- package/esm/map/contexts/map-configuration.context.js.map +1 -1
- package/esm/map/contexts/map-initial-view.context.js.map +1 -1
- package/esm/map/functions/__test__/fixtures/business-locations.js.map +1 -1
- package/esm/map/functions/__test__/fixtures/events-locations.js.map +1 -1
- package/esm/map/functions/__test__/fixtures/facilities-locations.js.map +1 -1
- package/esm/map/functions/__test__/fixtures/flight-connections.js.map +1 -1
- package/esm/map/functions/attach-image-from-shape.js.map +1 -1
- package/esm/map/functions/attach-image-from-string.js.map +1 -1
- package/esm/map/functions/attach-image-from-text.js.map +1 -1
- package/esm/map/functions/attach-image-to-map.js.map +1 -1
- package/esm/map/functions/build-categorical-scale.js.map +1 -1
- package/esm/map/functions/extract-layers-data.js.map +1 -1
- package/esm/map/functions/get-client-settings.js.map +1 -1
- package/esm/map/functions/get-data-layers-bounding-box.js.map +1 -1
- package/esm/map/functions/is-valid-shape.js.map +1 -1
- package/esm/map/functions/iterate-config-slots.js +10 -1
- package/esm/map/functions/iterate-config-slots.js.map +2 -2
- package/esm/map/functions/parse-tooltip-data.js.map +1 -1
- package/esm/map/functions/set-layers-id.js +1 -0
- package/esm/map/functions/set-layers-id.js.map +2 -2
- package/esm/map/functions/tooltip-type-guards.js.map +1 -1
- package/esm/map/hooks/use-active-interaction.js.map +1 -1
- package/esm/map/hooks/use-attach-image-from-icon.js.map +2 -2
- package/esm/map/hooks/use-attach-symbol-to-map.js.map +1 -1
- package/esm/map/hooks/use-color-scale.js.map +1 -1
- package/esm/map/hooks/use-hover-interaction.js.map +2 -2
- package/esm/map/hooks/use-initial-view-state.js.map +1 -1
- package/esm/map/hooks/use-legend-interaction-highlighting.js.map +1 -1
- package/esm/map/hooks/use-legend-interaction-visibility.js.map +1 -1
- package/esm/map/hooks/use-load-symbol-into-map.js.map +1 -1
- package/esm/map/hooks/use-map-performance.js +0 -15
- package/esm/map/hooks/use-map-performance.js.map +2 -2
- package/esm/map/hooks/use-overlay-events.js.map +1 -1
- package/esm/map/hooks/use-tooltip-template.js.map +2 -2
- package/esm/map/providers/color-scale.provider.js.map +2 -2
- package/esm/map/providers/layer-color-strategy.provider.js.map +2 -2
- package/esm/map/providers/map-initial-view.provider.js.map +2 -2
- package/esm/map/shapes/shape-picker.js.map +1 -1
- package/esm/map/slots/BubbleLayer.js.map +1 -1
- package/esm/map/slots/BubbleLayerTooltip.js.map +1 -1
- package/esm/map/slots/CategoricalLegend.js.map +1 -1
- package/esm/map/slots/ChartInteractions.js.map +1 -1
- package/esm/map/slots/ChoroplethLayer.js.map +1 -1
- package/esm/map/slots/ChoroplethLayerTooltip.js.map +1 -1
- package/esm/map/slots/ConnectionLayer.js.map +1 -1
- package/esm/map/slots/ConnectionLayerTooltip.js.map +1 -1
- package/esm/map/slots/DotLayer.js.map +1 -1
- package/esm/map/slots/DotLayerTooltip.js.map +1 -1
- package/esm/map/slots/SequentialLegend.js.map +1 -1
- package/esm/map/slots/ThresholdLegend.js.map +1 -1
- package/esm/map/slots/Tooltip.js.map +2 -2
- package/esm/map/slots/states/DisabledState.js.map +2 -2
- package/esm/map/slots/states/ErrorStateSlot.js.map +1 -1
- package/esm/map/store/map-store.context.js +3 -1
- package/esm/map/store/map-store.context.js.map +2 -2
- package/esm/map/store/map-store.provider.js +3 -1
- package/esm/map/store/map-store.provider.js.map +2 -2
- package/esm/map/store/selectors.js.map +1 -1
- package/esm/map/store/store.js.map +1 -1
- package/esm/map/types/bubble-layer.js.map +1 -1
- package/esm/map/types/coloring.js.map +1 -1
- package/map/MapView.d.ts +1 -1
- package/map/MapView.js +14 -8
- package/map/components/BubbleLayer/BubbleLayer.d.ts +3 -3
- package/map/components/BubbleLayer/BubbleLayerTooltip.d.ts +1 -1
- package/map/components/BubbleLayer/functions/add-outline-size.d.ts +1 -1
- package/map/components/BubbleLayer/functions/build-radius-scale.d.ts +2 -2
- package/map/components/BubbleLayer/functions/build-stick-to-distance-expressions.d.ts +1 -1
- package/map/components/BubbleLayer/functions/define-radius.d.ts +1 -1
- package/map/components/BubbleLayer/functions/parse-bubble-data-to-geo-json.d.ts +2 -2
- package/map/components/ChoroplethLayer/ChoroplethLayer.d.ts +2 -2
- package/map/components/ChoroplethLayer/ChoroplethLayerTooltip.d.ts +1 -1
- package/map/components/ConnectionLayer/ConnectionLayer.d.ts +1 -1
- package/map/components/ConnectionLayer/ConnectionLayerDirection.d.ts +1 -1
- package/map/components/ConnectionLayer/ConnectionLayerTooltip.d.ts +1 -1
- package/map/components/ConnectionLayer/functions/get-arc-line-features.d.ts +2 -2
- package/map/components/ConnectionLayer/functions/get-straight-line-features.d.ts +2 -2
- package/map/components/ConnectionLayer/functions/parse-connection-data-to-geo-json.d.ts +1 -1
- package/map/components/ConnectionLayer/functions/parse-direction-data-to-geo-json.d.ts +1 -1
- package/map/components/DefaultTooltip/DefaultTooltip.d.ts +1 -1
- package/map/components/DefaultTooltip/utils/handle-copy-to-clipboard.d.ts +1 -1
- package/map/components/DotLayer/DotLayer.d.ts +3 -3
- package/map/components/DotLayer/DotLayer.js +1 -1
- package/map/components/DotLayer/DotLayerTooltip.d.ts +1 -1
- package/map/components/DotLayer/functions/define-bearing.d.ts +1 -1
- package/map/components/DotLayer/functions/parse-dot-data-to-geo-json.d.ts +1 -1
- package/map/components/MapContent.d.ts +1 -1
- package/map/components/legend/functions/resolve-color.d.ts +1 -1
- package/map/components/toolbar/constants.d.ts +1 -1
- package/map/components/toolbar/functions/a11y-toolbar-controls.d.ts +1 -1
- package/map/components/toolbar/hooks/use-a11y-toolbar-tab-index.d.ts +1 -1
- package/map/constants.d.ts +3 -2
- package/map/constants.js +4 -2
- package/map/contexts/a11y-toolbar-tab-index.context.d.ts +1 -1
- package/map/contexts/color-scale.context.d.ts +1 -1
- package/map/contexts/map-configuration.context.d.ts +1 -1
- package/map/contexts/map-initial-view.context.d.ts +1 -1
- package/map/functions/__test__/fixtures/business-locations.d.ts +1 -1
- package/map/functions/__test__/fixtures/events-locations.d.ts +1 -1
- package/map/functions/__test__/fixtures/facilities-locations.d.ts +1 -1
- package/map/functions/__test__/fixtures/flight-connections.d.ts +1 -1
- package/map/functions/attach-image-from-shape.d.ts +2 -2
- package/map/functions/attach-image-from-string.d.ts +2 -2
- package/map/functions/attach-image-from-text.d.ts +1 -1
- package/map/functions/attach-image-to-map.d.ts +1 -1
- package/map/functions/build-categorical-scale.d.ts +1 -1
- package/map/functions/is-valid-shape.d.ts +2 -2
- package/map/functions/iterate-config-slots.d.ts +1 -1
- package/map/functions/iterate-config-slots.js +5 -0
- package/map/functions/parse-tooltip-data.d.ts +1 -1
- package/map/functions/set-layers-id.js +1 -0
- package/map/functions/tooltip-type-guards.d.ts +1 -1
- package/map/hooks/use-attach-image-from-icon.d.ts +2 -2
- package/map/hooks/use-attach-symbol-to-map.d.ts +2 -2
- package/map/hooks/use-color-scale.d.ts +1 -1
- package/map/hooks/use-initial-view-state.d.ts +1 -1
- package/map/hooks/use-legend-interaction-highlighting.d.ts +4 -4
- package/map/hooks/use-legend-interaction-visibility.d.ts +4 -4
- package/map/hooks/use-load-symbol-into-map.d.ts +2 -2
- package/map/hooks/use-map-performance.d.ts +0 -15
- package/map/hooks/use-map-performance.js +0 -15
- package/map/hooks/use-overlay-events.d.ts +1 -1
- package/map/hooks/use-tooltip-template.d.ts +2 -2
- package/map/providers/color-scale.provider.d.ts +1 -1
- package/map/providers/layer-color-strategy.provider.d.ts +3 -3
- package/map/providers/map-initial-view.provider.d.ts +2 -2
- package/map/shapes/shape-picker.d.ts +1 -1
- package/map/slots/BubbleLayer.d.ts +5 -5
- package/map/slots/BubbleLayerTooltip.d.ts +1 -1
- package/map/slots/CategoricalLegend.d.ts +1 -1
- package/map/slots/ChartInteractions.d.ts +2 -2
- package/map/slots/ChoroplethLayer.d.ts +3 -3
- package/map/slots/ChoroplethLayerTooltip.d.ts +1 -1
- package/map/slots/ConnectionLayer.d.ts +3 -3
- package/map/slots/ConnectionLayerTooltip.d.ts +1 -1
- package/map/slots/DotLayer.d.ts +5 -5
- package/map/slots/DotLayerTooltip.d.ts +1 -1
- package/map/slots/SequentialLegend.d.ts +1 -1
- package/map/slots/ThresholdLegend.d.ts +1 -1
- package/map/slots/Tooltip.d.ts +1 -1
- package/map/slots/states/ErrorStateSlot.d.ts +2 -2
- package/map/store/map-store.context.d.ts +2 -2
- package/map/store/map-store.provider.d.ts +1 -1
- package/map/store/selectors.d.ts +1 -1
- package/map/store/store.d.ts +1 -1
- package/map/types/bubble-layer.d.ts +2 -2
- package/map/types/choropleth-layer.d.ts +1 -1
- package/map/types/coloring.d.ts +1 -1
- package/map/types/configuration.d.ts +2 -2
- package/map/types/connection-layer.d.ts +1 -1
- package/map/types/dot-layer.d.ts +5 -5
- package/map/types/legend.d.ts +3 -25
- package/map/types/map-view.d.ts +3 -3
- package/map/types/state.d.ts +1 -1
- package/map/types/toolbar.d.ts +1 -1
- package/map/types/tooltip.d.ts +2 -2
- package/package.json +3 -3
|
@@ -78,6 +78,8 @@ const iterateConfigSlots = (children) => {
|
|
|
78
78
|
legend: {
|
|
79
79
|
type: "sequential",
|
|
80
80
|
colorPalette: import_constants.DEFAULT_SEQUENTIAL_LEGEND_COLOR_PALETTE,
|
|
81
|
+
position: import_constants.DEFAULT_MAP_POSITION,
|
|
82
|
+
ratio: import_constants.DEFAULT_MAP_LEGEND_RATIO,
|
|
81
83
|
...legend
|
|
82
84
|
}
|
|
83
85
|
};
|
|
@@ -89,6 +91,7 @@ const iterateConfigSlots = (children) => {
|
|
|
89
91
|
...slots,
|
|
90
92
|
legend: {
|
|
91
93
|
type: "categorical",
|
|
94
|
+
position: import_constants.DEFAULT_MAP_POSITION,
|
|
92
95
|
...legend
|
|
93
96
|
}
|
|
94
97
|
};
|
|
@@ -100,6 +103,8 @@ const iterateConfigSlots = (children) => {
|
|
|
100
103
|
...slots,
|
|
101
104
|
legend: {
|
|
102
105
|
type: "threshold",
|
|
106
|
+
position: import_constants.DEFAULT_MAP_POSITION,
|
|
107
|
+
ratio: import_constants.DEFAULT_MAP_LEGEND_RATIO,
|
|
103
108
|
...legend
|
|
104
109
|
}
|
|
105
110
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { BubbleLayerTooltipHandler, ChoroplethLayerTooltipData, ChoroplethLayerTooltipHandler, ConnectionLayerTooltipData, ConnectionLayerTooltipHandler, DotLayerTooltipHandler, LayerTooltipData, LayerTooltipHandler } from '../types/tooltip.js';
|
|
1
|
+
import type { BubbleLayerTooltipHandler, ChoroplethLayerTooltipData, ChoroplethLayerTooltipHandler, ConnectionLayerTooltipData, ConnectionLayerTooltipHandler, DotLayerTooltipHandler, LayerTooltipData, LayerTooltipHandler } from '../types/tooltip.js';
|
|
2
2
|
/**
|
|
3
3
|
* Type guards for tooltip template
|
|
4
4
|
* @param template
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { MapShape } from '../types/shapes.js';
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import type { MapShape } from '../types/shapes.js';
|
|
3
3
|
export declare const useAttachImageFromIcon: (icon: string | MapShape | ReactNode, suffix: string, outputSize?: number) => boolean;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { MapShape } from '../types/shapes.js';
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { MapShape } from '../types/shapes.js';
|
|
3
3
|
export declare const useAttachSymbolToMap: (icon: string | MapShape | ReactNode, suffix?: string, outputSize?: number) => null | undefined;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { ScaleOrdinal, ScaleQuantize, ScaleThreshold } from 'd3-scale';
|
|
1
|
+
import type { ScaleOrdinal, ScaleQuantize, ScaleThreshold } from 'd3-scale';
|
|
2
2
|
export declare function useColorScale(): ScaleQuantize<string> | ScaleThreshold<number, string> | ScaleOrdinal<string, string> | undefined;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { ViewState } from '../types/map-view.js';
|
|
1
|
+
import type { ViewState } from '../types/map-view.js';
|
|
2
2
|
export declare const useInitialViewState: (initialViewState: ViewState | undefined) => [number, number, number, number] | ViewState;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BubbleLayerProps } from '../types/bubble-layer.js';
|
|
2
|
-
import { ChoroplethLayerProps } from '../types/choropleth-layer.js';
|
|
3
|
-
import { DotLayerProps } from '../types/dot-layer.js';
|
|
4
|
-
import { Location } from '../types/location.js';
|
|
1
|
+
import type { BubbleLayerProps } from '../types/bubble-layer.js';
|
|
2
|
+
import type { ChoroplethLayerProps } from '../types/choropleth-layer.js';
|
|
3
|
+
import type { DotLayerProps } from '../types/dot-layer.js';
|
|
4
|
+
import type { Location } from '../types/location.js';
|
|
5
5
|
export declare const useLegendInteractionHighlighting: <L extends Location, R extends Record<string, unknown>>(props: DotLayerProps<L> | BubbleLayerProps<L> | ChoroplethLayerProps<R>, sourceId: string) => void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BubbleLayerProps } from '../types/bubble-layer.js';
|
|
2
|
-
import { ChoroplethLayerProps } from '../types/choropleth-layer.js';
|
|
3
|
-
import { DotLayerProps } from '../types/dot-layer.js';
|
|
4
|
-
import { Location } from '../types/location.js';
|
|
1
|
+
import type { BubbleLayerProps } from '../types/bubble-layer.js';
|
|
2
|
+
import type { ChoroplethLayerProps } from '../types/choropleth-layer.js';
|
|
3
|
+
import type { DotLayerProps } from '../types/dot-layer.js';
|
|
4
|
+
import type { Location } from '../types/location.js';
|
|
5
5
|
export declare const useLegendInteractionVisibility: <L extends Location, R extends Record<string, unknown>>(props: DotLayerProps<L> | BubbleLayerProps<L> | ChoroplethLayerProps<R>, layerId: string) => void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { MapShape, SymbolType } from '../types/shapes.js';
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { MapShape, SymbolType } from '../types/shapes.js';
|
|
3
3
|
export declare const useLoadSymbolIntoMap: (shape: string | MapShape | ReactNode, layerId: string, outputSize?: number) => {
|
|
4
4
|
symbolType: SymbolType;
|
|
5
5
|
symbolName: string;
|
|
@@ -1,18 +1,3 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* @license
|
|
3
|
-
* Copyright 2023 Dynatrace LLC
|
|
4
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
5
|
-
* you may not use this file except in compliance with the License.
|
|
6
|
-
* You may obtain a copy of the License at
|
|
7
|
-
*
|
|
8
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
9
|
-
*
|
|
10
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
11
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
12
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
13
|
-
* See the License for the specific language governing permissions and
|
|
14
|
-
* limitations under the License.
|
|
15
|
-
*/
|
|
16
1
|
export declare const useMapPerformance: (mapContainerRef: React.RefObject<HTMLDivElement>) => {
|
|
17
2
|
onLoadHandler: (() => void) | undefined;
|
|
18
3
|
onRenderHandler: (() => void) | undefined;
|
|
@@ -21,21 +21,6 @@ __export(use_map_performance_exports, {
|
|
|
21
21
|
});
|
|
22
22
|
module.exports = __toCommonJS(use_map_performance_exports);
|
|
23
23
|
var import_react = require("react");
|
|
24
|
-
/**
|
|
25
|
-
* @license
|
|
26
|
-
* Copyright 2023 Dynatrace LLC
|
|
27
|
-
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
28
|
-
* you may not use this file except in compliance with the License.
|
|
29
|
-
* You may obtain a copy of the License at
|
|
30
|
-
*
|
|
31
|
-
* http://www.apache.org/licenses/LICENSE-2.0
|
|
32
|
-
*
|
|
33
|
-
* Unless required by applicable law or agreed to in writing, software
|
|
34
|
-
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
35
|
-
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
36
|
-
* See the License for the specific language governing permissions and
|
|
37
|
-
* limitations under the License.
|
|
38
|
-
*/
|
|
39
24
|
const useMapPerformance = (mapContainerRef) => {
|
|
40
25
|
const isDev = true;
|
|
41
26
|
const isRendered = (0, import_react.useRef)(false);
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React, { ReactNode } from 'react';
|
|
2
|
-
import { LayerTooltipHandler } from '../types/tooltip.js';
|
|
1
|
+
import React, { type ReactNode } from 'react';
|
|
2
|
+
import type { LayerTooltipHandler } from '../types/tooltip.js';
|
|
3
3
|
/**
|
|
4
4
|
* It returns the tooltip template handler or undefined (tooltip disabled).
|
|
5
5
|
*
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ScaleOrdinal, ScaleQuantize, ScaleThreshold } from 'd3-scale';
|
|
2
|
-
import React, { PropsWithChildren } from 'react';
|
|
3
|
-
import { MapLegendConfig } from '../types/legend.js';
|
|
1
|
+
import type { ScaleOrdinal, ScaleQuantize, ScaleThreshold } from 'd3-scale';
|
|
2
|
+
import React, { type PropsWithChildren } from 'react';
|
|
3
|
+
import type { MapLegendConfig } from '../types/legend.js';
|
|
4
4
|
export declare function buildCategoricalScale(scale: ScaleOrdinal<string, string>): (value: string) => string | undefined;
|
|
5
5
|
export declare function buildNumericScale(scale: ScaleThreshold<number, string> | ScaleQuantize<string>): (value: number) => string | undefined;
|
|
6
6
|
export declare function buildClampedScale(legend: MapLegendConfig, scale: ScaleQuantize<string> | ScaleThreshold<number, string> | ScaleOrdinal<string, string>): (value: string | number) => string | undefined;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import React, { PropsWithChildren } from 'react';
|
|
2
|
-
import { ViewState } from '../types/map-view.js';
|
|
1
|
+
import React, { type PropsWithChildren } from 'react';
|
|
2
|
+
import type { ViewState } from '../types/map-view.js';
|
|
3
3
|
/**
|
|
4
4
|
*
|
|
5
5
|
* Since the initial view state can be determined in 2 different ways
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { MapShape } from '../types/shapes.js';
|
|
1
|
+
import type { MapShape } from '../types/shapes.js';
|
|
2
2
|
export declare const getShape: (shape: MapShape) => string;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { BubbleLayerProps } from '../types/bubble-layer.js';
|
|
3
|
-
import { Location } from '../types/location.js';
|
|
1
|
+
import type { PropsWithChildren } from 'react';
|
|
2
|
+
import type { BubbleLayerProps } from '../types/bubble-layer.js';
|
|
3
|
+
import type { Location } from '../types/location.js';
|
|
4
4
|
/**
|
|
5
5
|
* The `BubbleLayer` component renders data points as bubbles on a map, accepting an array of data points
|
|
6
6
|
* with required properties like latitude and longitude. It supports customization of bubble size
|
|
7
7
|
* using the radius prop and optional tooltips for displaying additional information.
|
|
8
8
|
*/
|
|
9
9
|
export declare const BubbleLayer: {
|
|
10
|
-
<T extends Location>(_:
|
|
10
|
+
<T extends Location>(_: PropsWithChildren<BubbleLayerProps<T>>): null;
|
|
11
11
|
Tooltip: {
|
|
12
|
-
({ children, }: import("../types/tooltip.js").BubbleLayerTooltipHandlerProps):
|
|
12
|
+
({ children, }: import("../types/tooltip.js").BubbleLayerTooltipHandlerProps): import("react").JSX.Element;
|
|
13
13
|
displayName: string;
|
|
14
14
|
};
|
|
15
15
|
displayName: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { BubbleLayerTooltipHandlerProps } from '../types/tooltip.js';
|
|
2
|
+
import type { BubbleLayerTooltipHandlerProps } from '../types/tooltip.js';
|
|
3
3
|
export declare const BubbleLayerTooltip: {
|
|
4
4
|
({ children, }: BubbleLayerTooltipHandlerProps): React.JSX.Element;
|
|
5
5
|
displayName: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { PropsWithChildren } from 'react';
|
|
2
|
-
import { ChartInteractionsProps } from '../types/toolbar.js';
|
|
1
|
+
import type { PropsWithChildren } from 'react';
|
|
2
|
+
import type { ChartInteractionsProps } from '../types/toolbar.js';
|
|
3
3
|
/** ChartInteractions interactions slot component */
|
|
4
4
|
export declare const ChartInteractions: {
|
|
5
5
|
(props: PropsWithChildren<ChartInteractionsProps>): null;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { ChoroplethLayerProps } from '../types/choropleth-layer.js';
|
|
1
|
+
import type { PropsWithChildren } from 'react';
|
|
2
|
+
import type { ChoroplethLayerProps } from '../types/choropleth-layer.js';
|
|
3
3
|
/**
|
|
4
4
|
* The `ChoroplethLayer` component allows users to display divided geographical
|
|
5
5
|
* areas or regions that are coloured in relation to a given data. It provides an
|
|
@@ -7,7 +7,7 @@ import { ChoroplethLayerProps } from '../types/choropleth-layer.js';
|
|
|
7
7
|
* the level of variability within a region.
|
|
8
8
|
*/
|
|
9
9
|
export declare const ChoroplethLayer: {
|
|
10
|
-
<T extends Record<string, unknown>>(_:
|
|
10
|
+
<T extends Record<string, unknown>>(_: PropsWithChildren<ChoroplethLayerProps<T>>): null;
|
|
11
11
|
Tooltip: {
|
|
12
12
|
({ children, }: import("../types/tooltip.js").ChoroplethLayerTooltipHandlerProps): null;
|
|
13
13
|
displayName: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChoroplethLayerTooltipHandlerProps } from '../types/tooltip.js';
|
|
1
|
+
import type { ChoroplethLayerTooltipHandlerProps } from '../types/tooltip.js';
|
|
2
2
|
export declare const ChoroplethLayerTooltip: {
|
|
3
3
|
({ children, }: ChoroplethLayerTooltipHandlerProps): null;
|
|
4
4
|
displayName: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { ConnectionLayerProps,
|
|
1
|
+
import type { PropsWithChildren } from 'react';
|
|
2
|
+
import type { ConnectionLayerProps, Connection } from '../types/connection-layer.js';
|
|
3
3
|
/**
|
|
4
4
|
* The `ConnectionLayer` component renders connections between points on a map,
|
|
5
5
|
* accepting an array of `Connection` data points with required properties like
|
|
@@ -7,7 +7,7 @@ import { ConnectionLayerProps, type Connection } from '../types/connection-layer
|
|
|
7
7
|
* direction the connection indicators.
|
|
8
8
|
*/
|
|
9
9
|
export declare const ConnectionLayer: {
|
|
10
|
-
<T extends Connection>(_:
|
|
10
|
+
<T extends Connection>(_: PropsWithChildren<ConnectionLayerProps<T>>): null;
|
|
11
11
|
Tooltip: {
|
|
12
12
|
(_: import("../types/tooltip.js").ConnectionLayerTooltipHandlerProps): null;
|
|
13
13
|
displayName: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ConnectionLayerTooltipHandlerProps } from '../types/tooltip.js';
|
|
1
|
+
import type { ConnectionLayerTooltipHandlerProps } from '../types/tooltip.js';
|
|
2
2
|
export declare const ConnectionLayerTooltip: {
|
|
3
3
|
(_: ConnectionLayerTooltipHandlerProps): null;
|
|
4
4
|
displayName: string;
|
package/map/slots/DotLayer.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import { DotLayerProps } from '../types/dot-layer.js';
|
|
3
|
-
import { Location } from '../types/location.js';
|
|
1
|
+
import type { PropsWithChildren } from 'react';
|
|
2
|
+
import type { DotLayerProps } from '../types/dot-layer.js';
|
|
3
|
+
import type { Location } from '../types/location.js';
|
|
4
4
|
/**
|
|
5
5
|
* The `DotLayer` component renders data points on a map, accepting an array of data points
|
|
6
6
|
* with required properties like latitude and longitude. It provides support
|
|
@@ -9,9 +9,9 @@ import { Location } from '../types/location.js';
|
|
|
9
9
|
* legends for color configuration.
|
|
10
10
|
*/
|
|
11
11
|
export declare const DotLayer: {
|
|
12
|
-
<T extends Location>(_:
|
|
12
|
+
<T extends Location>(_: PropsWithChildren<DotLayerProps<T>>): null;
|
|
13
13
|
Tooltip: {
|
|
14
|
-
({ children }: import("../types/tooltip.js").DotLayerTooltipHandlerProps):
|
|
14
|
+
({ children }: import("../types/tooltip.js").DotLayerTooltipHandlerProps): import("react").JSX.Element;
|
|
15
15
|
displayName: string;
|
|
16
16
|
};
|
|
17
17
|
displayName: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { DotLayerTooltipHandlerProps } from '../types/tooltip.js';
|
|
2
|
+
import type { DotLayerTooltipHandlerProps } from '../types/tooltip.js';
|
|
3
3
|
export declare const DotLayerTooltip: {
|
|
4
4
|
({ children }: DotLayerTooltipHandlerProps): React.JSX.Element;
|
|
5
5
|
displayName: string;
|
package/map/slots/Tooltip.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _ChartTooltipAtomsType as ChartTooltipAtomsType } from '@dynatrace/strato-components-preview/charts';
|
|
1
|
+
import type { _ChartTooltipAtomsType as ChartTooltipAtomsType } from '@dynatrace/strato-components-preview/charts';
|
|
2
2
|
import type { ChartTooltip } from '../types/tooltip.js';
|
|
3
3
|
/**
|
|
4
4
|
* @public
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
2
|
export interface ErrorStateSlotProps {
|
|
3
|
-
children:
|
|
3
|
+
children: ReactNode | ((errorMessage: string) => JSX.Element);
|
|
4
4
|
}
|
|
5
5
|
export declare const ErrorStateSlot: (props: ErrorStateSlotProps) => null;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { Store } from '@dynatrace/strato-components-preview/core';
|
|
3
|
-
import { MapState } from '../types/state.js';
|
|
2
|
+
import { type Store } from '@dynatrace/strato-components-preview/core';
|
|
3
|
+
import type { MapState } from '../types/state.js';
|
|
4
4
|
export declare const initialState: MapState<unknown>;
|
|
5
5
|
export declare const MapStore: React.Context<Store<MapState<unknown>>>;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import React, { PropsWithChildren } from 'react';
|
|
1
|
+
import React, { type PropsWithChildren } from 'react';
|
|
2
2
|
export declare const MapStoreProvider: ({ children }: PropsWithChildren) => React.JSX.Element;
|
package/map/store/selectors.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { MapState } from '../types/state.js';
|
|
1
|
+
import type { MapState } from '../types/state.js';
|
|
2
2
|
export declare const useSelector: <T, O>(selector: (state: MapState<T>) => O) => O;
|
|
3
3
|
export declare const useMapSelectionState: <T>() => import("../types/state.js").MapSelectionState;
|
|
4
4
|
export declare const useMapTooltipState: <T>() => {
|
package/map/store/store.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { MapOverlayState, MapSelectionState, MapTooltipState } from '../types/state.js';
|
|
1
|
+
import type { MapOverlayState, MapSelectionState, MapTooltipState } from '../types/state.js';
|
|
2
2
|
export declare const useSetState: () => (action: import("../types/state.js").MapState<unknown> | ((prev: import("../types/state.js").MapState<unknown>) => import("../types/state.js").MapState<unknown>)) => void;
|
|
3
3
|
export * from './selectors.js';
|
|
4
4
|
export declare const useSetStateSelection: () => (newSelectionState: Partial<MapSelectionState>) => void;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { LegendColorLayerProps, LocationColorProps } from './coloring.js';
|
|
2
|
-
import { Location } from './location.js';
|
|
1
|
+
import type { LegendColorLayerProps, LocationColorProps } from './coloring.js';
|
|
2
|
+
import type { Location } from './location.js';
|
|
3
3
|
/**
|
|
4
4
|
* Base props to configure a BubbleLayer
|
|
5
5
|
* @typeParam T - Object extending Location
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ChoroplethCustomColorProps, LegendColorLayerProps } from './coloring.js';
|
|
1
|
+
import type { ChoroplethCustomColorProps, LegendColorLayerProps } from './coloring.js';
|
|
2
2
|
/**
|
|
3
3
|
* Base props to configure a ChoroplethLayer
|
|
4
4
|
* @typeParam T - Object extending a record of string keys and any type of values
|
package/map/types/coloring.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { MapLegendConfig } from './legend.js';
|
|
2
|
-
import { ChartInteractionsConfig, MapToolbarConfig } from './toolbar.js';
|
|
1
|
+
import type { MapLegendConfig } from './legend.js';
|
|
2
|
+
import type { ChartInteractionsConfig, MapToolbarConfig } from './toolbar.js';
|
|
3
3
|
/**
|
|
4
4
|
* @internal
|
|
5
5
|
*/
|
package/map/types/dot-layer.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { LegendColorLayerProps, LocationColorProps } from './coloring.js';
|
|
3
|
-
import { Location } from './location.js';
|
|
4
|
-
import { MapShape } from './shapes.js';
|
|
1
|
+
import type { ReactNode } from 'react';
|
|
2
|
+
import type { LegendColorLayerProps, LocationColorProps } from './coloring.js';
|
|
3
|
+
import type { Location } from './location.js';
|
|
4
|
+
import type { MapShape } from './shapes.js';
|
|
5
5
|
/**
|
|
6
6
|
* Base props to configure a DotLayer.
|
|
7
7
|
* @typeParam T - Object extending Location
|
|
@@ -13,7 +13,7 @@ export interface DotLayerBaseProps<T extends Location> {
|
|
|
13
13
|
data: T[];
|
|
14
14
|
/**
|
|
15
15
|
* The shape of the dots
|
|
16
|
-
* @defaultValue '
|
|
16
|
+
* @defaultValue 'pin'
|
|
17
17
|
*/
|
|
18
18
|
shape?: string | MapShape | ReactNode;
|
|
19
19
|
/**
|
package/map/types/legend.d.ts
CHANGED
|
@@ -1,17 +1,6 @@
|
|
|
1
|
-
import { ColoredRange, ColorPalette,
|
|
1
|
+
import type { ColoredRange, ColorPalette, LegendProps } from '@dynatrace/strato-components-preview/charts';
|
|
2
2
|
/** The props common to all different legends */
|
|
3
|
-
export
|
|
4
|
-
/**
|
|
5
|
-
* The legend position relative to the map
|
|
6
|
-
* @defaultValue 'auto'
|
|
7
|
-
*/
|
|
8
|
-
position?: LegendPosition;
|
|
9
|
-
/**
|
|
10
|
-
* Hides the legend while keeping the coloring
|
|
11
|
-
* @defaultValue false
|
|
12
|
-
*/
|
|
13
|
-
hidden?: boolean;
|
|
14
|
-
}
|
|
3
|
+
export type BaseLegendProps = Omit<LegendProps, 'resizable'>;
|
|
15
4
|
/** The sequential legend props */
|
|
16
5
|
export interface SequentialLegendProps extends BaseLegendProps {
|
|
17
6
|
/** The min boundary */
|
|
@@ -34,18 +23,7 @@ export interface ThresholdLegendProps extends BaseLegendProps {
|
|
|
34
23
|
ranges: ColoredRange[];
|
|
35
24
|
}
|
|
36
25
|
/** The internal configs common to all different legends */
|
|
37
|
-
export
|
|
38
|
-
/**
|
|
39
|
-
* The legend position relative to the map
|
|
40
|
-
* @defaultValue 'auto'
|
|
41
|
-
*/
|
|
42
|
-
position: LegendPosition;
|
|
43
|
-
/**
|
|
44
|
-
* Hides the legend while keeping the coloring
|
|
45
|
-
* @defaultValue 'false'
|
|
46
|
-
*/
|
|
47
|
-
hidden: boolean;
|
|
48
|
-
}
|
|
26
|
+
export type BaseLegendConfig = Omit<LegendProps, 'resizable'>;
|
|
49
27
|
/** The sequential legend internal config */
|
|
50
28
|
export interface SequentialLegendConfig extends BaseLegendConfig {
|
|
51
29
|
type: 'sequential';
|
package/map/types/map-view.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { Style } from 'maplibre-gl';
|
|
2
|
-
import { CSSProperties } from 'react';
|
|
1
|
+
import type { Style } from 'maplibre-gl';
|
|
2
|
+
import type { CSSProperties } from 'react';
|
|
3
3
|
/**
|
|
4
4
|
* Type to disallow al props in a given type
|
|
5
5
|
*/
|
|
@@ -61,7 +61,7 @@ export interface MapViewBaseProps {
|
|
|
61
61
|
loading?: boolean;
|
|
62
62
|
/**
|
|
63
63
|
* The height of the chart. If a number is passed, it will be treated as px
|
|
64
|
-
* @defaultValue
|
|
64
|
+
* @defaultValue 400px
|
|
65
65
|
*/
|
|
66
66
|
height?: number | string;
|
|
67
67
|
/**
|
package/map/types/state.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { _LegendItem as LegendItem } from '@dynatrace/strato-components-preview/charts';
|
|
1
|
+
import type { _LegendItem as LegendItem } from '@dynatrace/strato-components-preview/charts';
|
|
2
2
|
export interface MapSelectionState {
|
|
3
3
|
highlightedSeries: LegendItem[] | undefined;
|
|
4
4
|
visible: LegendItem[] | undefined;
|
package/map/types/toolbar.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ToolbarPlacement, ZoomChangeHandler } from '@dynatrace/strato-components-preview/charts';
|
|
1
|
+
import type { ToolbarPlacement, ZoomChangeHandler } from '@dynatrace/strato-components-preview/charts';
|
|
2
2
|
export type ToolbarInteractionModes = 'zoom' | 'zoom-to-fit' | 'zoom-in' | 'zoom-out' | 'reset' | 'download-data';
|
|
3
3
|
/** Props for the ChartInteractions component **/
|
|
4
4
|
export interface ChartInteractionsProps {
|
package/map/types/tooltip.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import { _ChartTooltipSlotsType as ChartTooltipSlotsType, _ChartTooltipTemplateType as ChartTooltipTemplateType } from '@dynatrace/strato-components-preview/charts';
|
|
2
|
+
import type { _ChartTooltipSlotsType as ChartTooltipSlotsType, _ChartTooltipTemplateType as ChartTooltipTemplateType } from '@dynatrace/strato-components-preview/charts';
|
|
3
3
|
import type { Connection } from './connection-layer.js';
|
|
4
|
-
import { Location } from './location.js';
|
|
4
|
+
import type { Location } from './location.js';
|
|
5
5
|
/**
|
|
6
6
|
* @internal
|
|
7
7
|
*/
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dynatrace/strato-geo",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.9.17",
|
|
4
4
|
"private": false,
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"lang": "lang/uncompiled",
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"mapbox-gl": "npm:empty-npm-package@1.0.0",
|
|
40
40
|
"maplibre-gl": "^3.1.0",
|
|
41
41
|
"react-map-gl": "^7.1.7",
|
|
42
|
-
"@dynatrace/strato-design-tokens": "0.20.
|
|
42
|
+
"@dynatrace/strato-design-tokens": "0.20.30",
|
|
43
43
|
"@dynatrace/strato-icons": "0.37.0"
|
|
44
44
|
},
|
|
45
45
|
"peerDependencies": {
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
"react-dom": "^18.0.0",
|
|
50
50
|
"react-intl": "^6.0.8",
|
|
51
51
|
"react-is": "^18.0.0",
|
|
52
|
-
"@dynatrace/strato-components-preview": "~0.
|
|
52
|
+
"@dynatrace/strato-components-preview": "~0.115.17"
|
|
53
53
|
},
|
|
54
54
|
"sideEffects": [
|
|
55
55
|
"./map/styles/react-mapgl-styles.css",
|