@splunk/visualizations 28.3.0 → 28.5.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.
- package/Area/Area.d.ts.map +1 -1
- package/Area.config.js +28 -8
- package/Area.config.js.map +2 -2
- package/Area.js +583 -120
- package/Area.js.map +3 -3
- package/Bar/Bar.d.ts.map +1 -1
- package/Bar.config.js +28 -8
- package/Bar.config.js.map +2 -2
- package/Bar.js +593 -120
- package/Bar.js.map +3 -3
- package/Bubble.config.js +4 -5
- package/Bubble.config.js.map +2 -2
- package/Bubble.js +554 -98
- package/Bubble.js.map +3 -3
- package/CHANGELOG.external.md +165 -0
- package/ChoroplethSvg/ChoroplethSvg.d.ts +4 -3
- package/ChoroplethSvg/ChoroplethSvg.d.ts.map +1 -1
- package/ChoroplethSvg.config.js +1 -3
- package/ChoroplethSvg.config.js.map +2 -2
- package/ChoroplethSvg.js +595 -111
- package/ChoroplethSvg.js.map +4 -4
- package/Column/Column.d.ts.map +1 -1
- package/Column.config.js +28 -8
- package/Column.config.js.map +2 -2
- package/Column.js +583 -120
- package/Column.js.map +3 -3
- package/Ellipse/config.d.ts.map +1 -1
- package/Ellipse.config.js +14 -5
- package/Ellipse.config.js.map +4 -4
- package/Ellipse.js +640 -159
- package/Ellipse.js.map +4 -4
- package/Events/PureEvents/PureEvents.d.ts.map +1 -1
- package/Events.js +668 -157
- package/Events.js.map +4 -4
- package/FillerGauge/FillerGauge.d.ts.map +1 -1
- package/FillerGauge/PureFillerGauge/FillerGauge.d.ts.map +1 -1
- package/FillerGauge.js +751 -169
- package/FillerGauge.js.map +4 -4
- package/Image/Image.d.ts.map +1 -1
- package/Image.js +620 -116
- package/Image.js.map +4 -4
- package/Line/Line.d.ts.map +1 -1
- package/Line/lineUtils.d.ts.map +1 -1
- package/Line/mockdata/LineData.d.ts +154 -0
- package/Line/mockdata/LineData.d.ts.map +1 -1
- package/Line.config.js +28 -8
- package/Line.config.js.map +2 -2
- package/Line.js +704 -122
- package/Line.js.map +3 -3
- package/LinkGraph/PureLinkGraph/PureLinkGraph.d.ts +5 -0
- package/LinkGraph/PureLinkGraph/PureLinkGraph.d.ts.map +1 -1
- package/LinkGraph/PureLinkGraph/PureLinkGraphUtils.d.ts.map +1 -1
- package/LinkGraph/PureLinkGraph/components/Graph.d.ts +9 -1
- package/LinkGraph/PureLinkGraph/components/Graph.d.ts.map +1 -1
- package/LinkGraph/PureLinkGraph/components/GraphStyles.d.ts.map +1 -1
- package/LinkGraph/PureLinkGraph/components/Node.d.ts +1 -0
- package/LinkGraph/PureLinkGraph/components/Node.d.ts.map +1 -1
- package/LinkGraph/PureLinkGraph/components/Nodes.d.ts +1 -0
- package/LinkGraph/PureLinkGraph/components/Nodes.d.ts.map +1 -1
- package/LinkGraph/PureLinkGraph/measurementUtils.d.ts +16 -0
- package/LinkGraph/PureLinkGraph/measurementUtils.d.ts.map +1 -0
- package/LinkGraph/PureLinkGraph/utils/iconLoader.d.ts.map +1 -1
- package/LinkGraph/config.d.ts.map +1 -1
- package/LinkGraph.config.js +15 -1
- package/LinkGraph.config.js.map +2 -2
- package/LinkGraph.js +1411 -662
- package/LinkGraph.js.map +4 -4
- package/Map/Map.d.ts +2 -2
- package/Map/Map.d.ts.map +1 -1
- package/Map/PureMap/BubbleLayer.d.ts +5 -0
- package/Map/PureMap/BubbleLayer.d.ts.map +1 -1
- package/Map/PureMap/ClusterLayer.d.ts.map +1 -1
- package/Map/PureMap/LocalChoroplethLayer.d.ts.map +1 -1
- package/Map/PureMap/MapUtils.d.ts +2 -2
- package/Map/PureMap/MapUtils.d.ts.map +1 -1
- package/Map/PureMap/PureMap.d.ts.map +1 -1
- package/Map/PureMap/PureMapContainer.d.ts.map +1 -1
- package/Map/PureMap/Tooltip.d.ts.map +1 -1
- package/Map/config.d.ts.map +1 -1
- package/Map.config.js +0 -1
- package/Map.config.js.map +2 -2
- package/Map.js +831 -247
- package/Map.js.map +4 -4
- package/Markdown/Markdown.d.ts.map +1 -1
- package/Markdown/config.d.ts.map +1 -1
- package/Markdown.config.js +14 -5
- package/Markdown.config.js.map +4 -4
- package/Markdown.js +619 -109
- package/Markdown.js.map +4 -4
- package/MarkerGauge/MarkerGauge.d.ts +5 -1
- package/MarkerGauge/MarkerGauge.d.ts.map +1 -1
- package/MarkerGauge/PureMarkerGauge/MarkerGauge.d.ts +4 -0
- package/MarkerGauge/PureMarkerGauge/MarkerGauge.d.ts.map +1 -1
- package/MarkerGauge/config.d.ts.map +1 -1
- package/MarkerGauge.config.js +121 -3
- package/MarkerGauge.config.js.map +3 -3
- package/MarkerGauge.js +1535 -172
- package/MarkerGauge.js.map +4 -4
- package/NetworkGraph/NetworkGraph.d.ts +22 -0
- package/NetworkGraph/NetworkGraph.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/PureNetworkGraph.d.ts +60 -0
- package/NetworkGraph/PureNetworkGraph/PureNetworkGraph.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/components/Link.d.ts +19 -0
- package/NetworkGraph/PureNetworkGraph/components/Link.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/components/NetworkGraphSvg.d.ts +29 -0
- package/NetworkGraph/PureNetworkGraph/components/NetworkGraphSvg.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/components/Node.d.ts +27 -0
- package/NetworkGraph/PureNetworkGraph/components/Node.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/components/Tooltip.d.ts +12 -0
- package/NetworkGraph/PureNetworkGraph/components/Tooltip.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/components/ZoomControls.d.ts +13 -0
- package/NetworkGraph/PureNetworkGraph/components/ZoomControls.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/mockdata/data.d.ts +140 -0
- package/NetworkGraph/PureNetworkGraph/mockdata/data.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/mockdata/datasource.d.ts +89 -0
- package/NetworkGraph/PureNetworkGraph/mockdata/datasource.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/utils/dragUtils.d.ts +78 -0
- package/NetworkGraph/PureNetworkGraph/utils/dragUtils.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/utils/forceLayout.d.ts +47 -0
- package/NetworkGraph/PureNetworkGraph/utils/forceLayout.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/utils/iconLoader.d.ts +78 -0
- package/NetworkGraph/PureNetworkGraph/utils/iconLoader.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/utils/networkGraphShared.d.ts +111 -0
- package/NetworkGraph/PureNetworkGraph/utils/networkGraphShared.d.ts.map +1 -0
- package/NetworkGraph/PureNetworkGraph/utils/networkGraphUtils.d.ts +122 -0
- package/NetworkGraph/PureNetworkGraph/utils/networkGraphUtils.d.ts.map +1 -0
- package/NetworkGraph/config.d.ts +4 -0
- package/NetworkGraph/config.d.ts.map +1 -0
- package/NetworkGraph/index.d.ts +3 -0
- package/NetworkGraph/index.d.ts.map +1 -0
- package/NetworkGraph.config.js +938 -0
- package/NetworkGraph.config.js.map +7 -0
- package/NetworkGraph.js +7053 -0
- package/NetworkGraph.js.map +7 -0
- package/PERFORMANCE.md +23 -0
- package/ParallelCoordinates/ParallelCoordinates.d.ts +1 -46
- package/ParallelCoordinates/ParallelCoordinates.d.ts.map +1 -1
- package/ParallelCoordinates/PureParallelCoordinates/PureParallelCoordinates.d.ts +12 -58
- package/ParallelCoordinates/PureParallelCoordinates/PureParallelCoordinates.d.ts.map +1 -1
- package/ParallelCoordinates/PureParallelCoordinates/src/ParallelCoordinatesChart.d.ts +1 -0
- package/ParallelCoordinates/PureParallelCoordinates/src/ParallelCoordinatesChart.d.ts.map +1 -1
- package/ParallelCoordinates.js +664 -228
- package/ParallelCoordinates.js.map +4 -4
- package/Pie/Pie.d.ts.map +1 -1
- package/Pie/config.d.ts.map +1 -1
- package/Pie/pieUtils.d.ts +4 -0
- package/Pie/pieUtils.d.ts.map +1 -1
- package/Pie.config.js +16 -0
- package/Pie.config.js.map +2 -2
- package/Pie.js +610 -118
- package/Pie.js.map +3 -3
- package/Punchcard.js +579 -92
- package/Punchcard.js.map +4 -4
- package/Rectangle/config.d.ts.map +1 -1
- package/Rectangle.config.js +14 -5
- package/Rectangle.config.js.map +4 -4
- package/Rectangle.js +611 -130
- package/Rectangle.js.map +4 -4
- package/Sankey/PureSankey/PureSankey.d.ts +26 -72
- package/Sankey/PureSankey/PureSankey.d.ts.map +1 -1
- package/Sankey/PureSankey/SankeyLink.d.ts +3 -19
- package/Sankey/PureSankey/SankeyLink.d.ts.map +1 -1
- package/Sankey/PureSankey/SankeyNode.d.ts +3 -20
- package/Sankey/PureSankey/SankeyNode.d.ts.map +1 -1
- package/Sankey/PureSankey/SankeyTooltip.d.ts +3 -24
- package/Sankey/PureSankey/SankeyTooltip.d.ts.map +1 -1
- package/Sankey.js +814 -429
- package/Sankey.js.map +4 -4
- package/Scatter/Scatter.d.ts.map +1 -1
- package/Scatter.config.js +168 -148
- package/Scatter.config.js.map +4 -4
- package/Scatter.js +733 -260
- package/Scatter.js.map +4 -4
- package/SingleValue/SingleValue.d.ts.map +1 -1
- package/SingleValue/config.d.ts.map +1 -1
- package/SingleValue.config.js +15 -2
- package/SingleValue.config.js.map +2 -2
- package/SingleValue.js +733 -229
- package/SingleValue.js.map +3 -3
- package/SingleValueBasic.js.map +1 -1
- package/SingleValueIcon/SingleValueIcon.d.ts.map +1 -1
- package/SingleValueIcon/config.d.ts.map +1 -1
- package/SingleValueIcon.config.js +14 -6
- package/SingleValueIcon.config.js.map +4 -4
- package/SingleValueIcon.js +612 -182
- package/SingleValueIcon.js.map +4 -4
- package/SingleValueRadial/PureSingleValueRadial/GaugeGraph.d.ts.map +1 -1
- package/SingleValueRadial/PureSingleValueRadial/utils/gaugeUtils.d.ts +0 -8
- package/SingleValueRadial/PureSingleValueRadial/utils/gaugeUtils.d.ts.map +1 -1
- package/SingleValueRadial/SingleValueRadial.d.ts.map +1 -1
- package/SingleValueRadial.config.js +0 -1
- package/SingleValueRadial.config.js.map +2 -2
- package/SingleValueRadial.js +594 -182
- package/SingleValueRadial.js.map +4 -4
- package/SparkLine.js +46 -8
- package/SparkLine.js.map +2 -2
- package/Table/PureTable.d.ts +10 -0
- package/Table/PureTable.d.ts.map +1 -1
- package/Table/Table.d.ts.map +1 -1
- package/Table/cells/SparklineCell.d.ts.map +1 -1
- package/Table/config.d.ts.map +1 -1
- package/Table/hooks.d.ts +6 -0
- package/Table/hooks.d.ts.map +1 -1
- package/Table.config.js +1 -1
- package/Table.config.js.map +2 -2
- package/Table.js +836 -253
- package/Table.js.map +4 -4
- package/Timeline/PureTimeline/PureTimeline.d.ts.map +1 -1
- package/Timeline/PureTimeline/src/CursorPlugin.d.ts.map +1 -1
- package/Timeline/PureTimeline/src/TimelineLegend.d.ts.map +1 -1
- package/Timeline/PureTimeline/src/TimelinePlugin.d.ts.map +1 -1
- package/Timeline/PureTimeline/src/TimelineYAxis.d.ts.map +1 -1
- package/Timeline/PureTimeline/src/utils/timelineUtils.d.ts +2 -1
- package/Timeline/PureTimeline/src/utils/timelineUtils.d.ts.map +1 -1
- package/Timeline/config.d.ts.map +1 -1
- package/Timeline.config.js +31 -12
- package/Timeline.config.js.map +4 -4
- package/Timeline.js +785 -247
- package/Timeline.js.map +4 -4
- package/common/Charting.d.ts +5 -0
- package/common/Charting.d.ts.map +1 -1
- package/common/Charting.js +12 -0
- package/common/Charting.js.map +2 -2
- package/common/GaugeMajorTicks.js +150 -13
- package/common/GaugeMajorTicks.js.map +4 -4
- package/common/GaugeValueMarker.js +84 -17
- package/common/GaugeValueMarker.js.map +4 -4
- package/common/OptionsDoc.js.map +1 -1
- package/common/OverviewDoc.d.ts.map +1 -1
- package/common/OverviewDoc.js +2 -2
- package/common/OverviewDoc.js.map +2 -2
- package/common/ThemesDoc.js +0 -1
- package/common/ThemesDoc.js.map +2 -2
- package/common/TimeSeriesChartWrapper.d.ts +24 -11
- package/common/TimeSeriesChartWrapper.d.ts.map +1 -1
- package/common/TimeSeriesChartWrapper.js +617 -91
- package/common/TimeSeriesChartWrapper.js.map +4 -4
- package/common/chartingUtils.d.ts +52 -6
- package/common/chartingUtils.d.ts.map +1 -1
- package/common/chartingUtils.js +116 -17
- package/common/chartingUtils.js.map +3 -3
- package/common/editorConfig/AxesChartDataConfig.d.ts +3 -3
- package/common/editorConfig/AxesChartDataConfig.d.ts.map +1 -1
- package/common/editorConfig/AxesChartDataDisplay.d.ts +4 -0
- package/common/editorConfig/AxesChartDataDisplay.d.ts.map +1 -1
- package/common/editorConfig/AxesChartLegend.d.ts.map +1 -1
- package/common/gaugeUtils.d.ts +37 -0
- package/common/gaugeUtils.d.ts.map +1 -1
- package/common/gaugeUtils.js +152 -2
- package/common/gaugeUtils.js.map +4 -4
- package/common/hocs/mockdata/trellisData.d.ts +119 -0
- package/common/hocs/mockdata/trellisData.d.ts.map +1 -1
- package/common/hocs/withTrellis.d.ts.map +1 -1
- package/common/interfaces/DashboardVizProps.d.ts +0 -3
- package/common/interfaces/DashboardVizProps.d.ts.map +1 -1
- package/common/interfaces/DataSource.d.ts +1 -1
- package/common/interfaces/DataSource.d.ts.map +1 -1
- package/common/interfaces/Overview.d.ts +1 -0
- package/common/interfaces/Overview.d.ts.map +1 -1
- package/common/interfaces/VizConfig.d.ts +2 -1
- package/common/interfaces/VizConfig.d.ts.map +1 -1
- package/common/shapeUtils.js +5 -20
- package/common/shapeUtils.js.map +2 -2
- package/common/utils/dataUtils.d.ts.map +1 -1
- package/common/utils/dataUtils.js +5 -4
- package/common/utils/dataUtils.js.map +2 -2
- package/common/utils/mapUtils.js +16 -9
- package/common/utils/mapUtils.js.map +2 -2
- package/common/utils/singleValueUtils.js +17 -18
- package/common/utils/singleValueUtils.js.map +2 -2
- package/common/utils/textUtils.d.ts +20 -0
- package/common/utils/textUtils.d.ts.map +1 -0
- package/common/utils/textUtils.js +76 -0
- package/common/utils/textUtils.js.map +7 -0
- package/common/utils/trellisUtils.d.ts.map +1 -1
- package/common/utils/trellisUtils.js +16 -20
- package/common/utils/trellisUtils.js.map +2 -2
- package/common/withDashboardViz.d.ts.map +1 -1
- package/common/withDashboardViz.js +600 -92
- package/common/withDashboardViz.js.map +4 -4
- package/package.json +46 -39
- package/common/utils/styleUtils.d.ts +0 -2
- package/common/utils/styleUtils.d.ts.map +0 -1
- package/common/utils/styleUtils.js +0 -30
- package/common/utils/styleUtils.js.map +0 -7
package/SingleValueRadial.js
CHANGED
|
@@ -331,7 +331,6 @@ var computeText = ({
|
|
|
331
331
|
}) => {
|
|
332
332
|
let text = (0, numberUtils_exports.isNumerial)(value) ? (0, numberUtils_exports.formatNumber)(value, numberPrecision, {
|
|
333
333
|
useThousandSeparators: shouldUseThousandSeparators,
|
|
334
|
-
// todo: need update formatNumber
|
|
335
334
|
useTrendUnits: shouldAbbreviateValue
|
|
336
335
|
}) : value;
|
|
337
336
|
text = text || "";
|
|
@@ -610,16 +609,19 @@ var changeColor = (color, ratio) => {
|
|
|
610
609
|
};
|
|
611
610
|
var lighten = (color) => changeColor(color, 1.3);
|
|
612
611
|
var darken = (color) => changeColor(color, 0.5);
|
|
613
|
-
var handleValueClickCallback = (ev, majorValue, majorValueField, trendValue, onValueClick,
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
612
|
+
var handleValueClickCallback = (ev, majorValue, majorValueField, trendValue, onValueClick, trellisContext = {}) => {
|
|
613
|
+
const { trellisEnabled = false, trellisSplitBy = "", trellisKey = "" } = trellisContext;
|
|
614
|
+
return onValueClick(__spreadProps(__spreadValues({}, ev), {
|
|
615
|
+
payload: __spreadValues({
|
|
616
|
+
trendValue,
|
|
617
|
+
value: majorValue,
|
|
618
|
+
name: majorValueField
|
|
619
|
+
}, trellisEnabled && {
|
|
620
|
+
"trellis.name": trellisSplitBy,
|
|
621
|
+
"trellis.value": trellisKey
|
|
622
|
+
})
|
|
623
|
+
}));
|
|
624
|
+
};
|
|
623
625
|
var getTrendColorWithPercent = (options) => {
|
|
624
626
|
const shouldUsePercentTrendColor = options.trendColor === "> trendValue | rangeValue(trendColorEditorConfig)" && options.trendDisplay === "percent";
|
|
625
627
|
return shouldUsePercentTrendColor ? {
|
|
@@ -909,8 +911,8 @@ var SingleValueBasic_default = SingleValueBasic;
|
|
|
909
911
|
|
|
910
912
|
// src/SingleValueRadial/PureSingleValueRadial/RadialGraph.jsx
|
|
911
913
|
var RadialGraph = ({
|
|
912
|
-
progress,
|
|
913
|
-
strokeWidth,
|
|
914
|
+
progress = 0,
|
|
915
|
+
strokeWidth = 12,
|
|
914
916
|
backgroundColor = colorConstants_exports.RADIAL_BACKGROUND_COLOR,
|
|
915
917
|
progressColor = colorConstants_exports.RADIAL_STROKE_COLOR,
|
|
916
918
|
width = 200,
|
|
@@ -959,10 +961,6 @@ RadialGraph.propTypes = {
|
|
|
959
961
|
width: prop_types_default.number,
|
|
960
962
|
height: prop_types_default.number
|
|
961
963
|
};
|
|
962
|
-
RadialGraph.defaultProps = {
|
|
963
|
-
progress: 0,
|
|
964
|
-
strokeWidth: 12
|
|
965
|
-
};
|
|
966
964
|
var RadialGraph_default = RadialGraph;
|
|
967
965
|
|
|
968
966
|
// src/SingleValueRadial/PureSingleValueRadial/utils/displayUtils.js
|
|
@@ -1039,13 +1037,6 @@ var getProgressWidth = (value, minValue, maxValue, circumference) => {
|
|
|
1039
1037
|
const progressWidth = progress50 / 100 * circumference;
|
|
1040
1038
|
return progressWidth;
|
|
1041
1039
|
};
|
|
1042
|
-
var computeTextWidth = (text, font) => {
|
|
1043
|
-
const canvas = document.createElement("canvas");
|
|
1044
|
-
const context = canvas.getContext("2d");
|
|
1045
|
-
context.font = font;
|
|
1046
|
-
const measure = context.measureText(text);
|
|
1047
|
-
return measure.width;
|
|
1048
|
-
};
|
|
1049
1040
|
var getVerticalLabelOffset = (theta, textHeight, maxOffset) => {
|
|
1050
1041
|
if (theta > 90) {
|
|
1051
1042
|
return (-(maxOffset / 90) * (180 - theta) + maxOffset) * textHeight;
|
|
@@ -1113,11 +1104,20 @@ var getFormattedGaugeRanges = (gaugeRanges, minValue, maxValue) => {
|
|
|
1113
1104
|
return formattedGaugeRanges;
|
|
1114
1105
|
};
|
|
1115
1106
|
|
|
1107
|
+
// src/common/utils/textUtils.ts
|
|
1108
|
+
var computeTextWidth = (text, font) => {
|
|
1109
|
+
const canvas = document.createElement("canvas");
|
|
1110
|
+
const context = canvas.getContext("2d");
|
|
1111
|
+
context.font = font;
|
|
1112
|
+
const measure = context.measureText(text);
|
|
1113
|
+
return measure.width;
|
|
1114
|
+
};
|
|
1115
|
+
|
|
1116
1116
|
// src/SingleValueRadial/PureSingleValueRadial/GaugeGraph.tsx
|
|
1117
1117
|
var GaugeGraph = ({
|
|
1118
1118
|
width = 200,
|
|
1119
1119
|
height = 200,
|
|
1120
|
-
strokeWidth =
|
|
1120
|
+
strokeWidth = 12,
|
|
1121
1121
|
radialBackgroundColor = colorConstants_exports.RADIAL_BACKGROUND_COLOR,
|
|
1122
1122
|
fontColor,
|
|
1123
1123
|
formattedGaugeRanges,
|
|
@@ -1151,7 +1151,7 @@ var GaugeGraph = ({
|
|
|
1151
1151
|
const cy = semicircleRadius + strokeWidth / 2 + cyOffset;
|
|
1152
1152
|
let majorValue;
|
|
1153
1153
|
if (typeof propMajorValue === "string") {
|
|
1154
|
-
majorValue =
|
|
1154
|
+
majorValue = parseFloat(propMajorValue);
|
|
1155
1155
|
} else {
|
|
1156
1156
|
majorValue = propMajorValue;
|
|
1157
1157
|
}
|
|
@@ -1349,11 +1349,6 @@ GaugeGraph.propTypes = {
|
|
|
1349
1349
|
minValue: prop_types_exports.number,
|
|
1350
1350
|
showRadialGraph: prop_types_exports.bool
|
|
1351
1351
|
};
|
|
1352
|
-
GaugeGraph.defaultProps = {
|
|
1353
|
-
strokeWidth: 12,
|
|
1354
|
-
formattedGaugeRanges: [],
|
|
1355
|
-
majorValue: "N/A"
|
|
1356
|
-
};
|
|
1357
1352
|
var GaugeGraph_default = GaugeGraph;
|
|
1358
1353
|
|
|
1359
1354
|
// src/SingleValueRadial/PureSingleValueRadial/RadialLayout.jsx
|
|
@@ -1576,25 +1571,26 @@ var Container = styled_components_default.div`
|
|
|
1576
1571
|
var SingleValueRadial = (_a) => {
|
|
1577
1572
|
var props = __objRest(_a, []);
|
|
1578
1573
|
const {
|
|
1579
|
-
width,
|
|
1574
|
+
width = "100%",
|
|
1580
1575
|
height = 250,
|
|
1581
1576
|
style,
|
|
1582
1577
|
isGaugeOn,
|
|
1583
1578
|
gaugeRanges,
|
|
1584
1579
|
majorFontSize,
|
|
1585
|
-
majorValue,
|
|
1580
|
+
majorValue = "N/A",
|
|
1586
1581
|
majorValueDisplay,
|
|
1587
|
-
majorValueField,
|
|
1588
|
-
minValue,
|
|
1589
|
-
maxValue,
|
|
1582
|
+
majorValueField = "",
|
|
1583
|
+
minValue = 0,
|
|
1584
|
+
maxValue = 100,
|
|
1590
1585
|
trendValue,
|
|
1591
1586
|
trendFontSize,
|
|
1592
|
-
unitPosition,
|
|
1593
|
-
numberPrecision,
|
|
1594
|
-
shouldUseThousandSeparators,
|
|
1595
|
-
shouldAbbreviateTrendValue,
|
|
1596
|
-
shouldAbbreviateMajorValue,
|
|
1597
|
-
onValueClick
|
|
1587
|
+
unitPosition = "after",
|
|
1588
|
+
numberPrecision = 0,
|
|
1589
|
+
shouldUseThousandSeparators = true,
|
|
1590
|
+
shouldAbbreviateTrendValue = false,
|
|
1591
|
+
shouldAbbreviateMajorValue = false,
|
|
1592
|
+
onValueClick = () => {
|
|
1593
|
+
},
|
|
1598
1594
|
splitByLayout,
|
|
1599
1595
|
trellisKey = "",
|
|
1600
1596
|
trellisSplitBy = ""
|
|
@@ -1630,16 +1626,11 @@ var SingleValueRadial = (_a) => {
|
|
|
1630
1626
|
const radialStrokeColor = props.radialStrokeColor || radialColors.stroke;
|
|
1631
1627
|
const trellisEnabled = useTrellisEnabled(splitByLayout);
|
|
1632
1628
|
const handleValueClick = (0, react_exports.useCallback)(
|
|
1633
|
-
(ev) => handleValueClickCallback(
|
|
1634
|
-
ev,
|
|
1635
|
-
majorValue,
|
|
1636
|
-
majorValueField,
|
|
1637
|
-
trendValue,
|
|
1638
|
-
onValueClick,
|
|
1629
|
+
(ev) => handleValueClickCallback(ev, majorValue, majorValueField, trendValue, onValueClick, {
|
|
1639
1630
|
trellisEnabled,
|
|
1640
1631
|
trellisSplitBy,
|
|
1641
1632
|
trellisKey
|
|
1642
|
-
),
|
|
1633
|
+
}),
|
|
1643
1634
|
[onValueClick, majorValue, majorValueField, trendValue, trellisEnabled, trellisSplitBy, trellisKey]
|
|
1644
1635
|
);
|
|
1645
1636
|
const sortedGaugeRanges = gaugeRanges && getSortedGaugeRanges(gaugeRanges);
|
|
@@ -1650,7 +1641,7 @@ var SingleValueRadial = (_a) => {
|
|
|
1650
1641
|
return null;
|
|
1651
1642
|
}
|
|
1652
1643
|
const { underLabel } = props;
|
|
1653
|
-
let { trendDisplay, unit } = props;
|
|
1644
|
+
let { trendDisplay = "absolute", unit } = props;
|
|
1654
1645
|
let { width: graphWidth, height: graphHeight } = getRadialGraphDimensions({
|
|
1655
1646
|
width: containerWidth,
|
|
1656
1647
|
height: containerHeight
|
|
@@ -1779,25 +1770,6 @@ SingleValueRadial.propTypes = {
|
|
|
1779
1770
|
gaugeComponent: prop_types_exports.element,
|
|
1780
1771
|
gaugeRanges: prop_types_exports.array
|
|
1781
1772
|
};
|
|
1782
|
-
SingleValueRadial.defaultProps = {
|
|
1783
|
-
width: "100%",
|
|
1784
|
-
height: 250,
|
|
1785
|
-
majorValue: "N/A",
|
|
1786
|
-
majorValueField: "",
|
|
1787
|
-
minValue: 0,
|
|
1788
|
-
maxValue: 100,
|
|
1789
|
-
trendDisplay: "absolute",
|
|
1790
|
-
trendIndicatorPosition: "standard",
|
|
1791
|
-
shouldAbbreviateTrendValue: false,
|
|
1792
|
-
shouldAbbreviateMajorValue: false,
|
|
1793
|
-
unitPosition: "after",
|
|
1794
|
-
numberPrecision: 0,
|
|
1795
|
-
shouldUseThousandSeparators: true,
|
|
1796
|
-
onValueClick: () => {
|
|
1797
|
-
},
|
|
1798
|
-
trellisKey: "",
|
|
1799
|
-
trellisSplitBy: ""
|
|
1800
|
-
};
|
|
1801
1773
|
var SingleValueRadial_default = (0, styled_components_exports.withTheme)(SingleValueRadial);
|
|
1802
1774
|
|
|
1803
1775
|
// esm-externals:@splunk/themes/getSettingsFromThemedProps
|
|
@@ -2144,7 +2116,7 @@ var Cover = styled_components_default.div`
|
|
|
2144
2116
|
bottom: 0;
|
|
2145
2117
|
`;
|
|
2146
2118
|
var Blocker = styled_components_default.div.attrs({
|
|
2147
|
-
"data-splunk-visualization-version": "28.
|
|
2119
|
+
"data-splunk-visualization-version": "28.5.0 - b192418b7"
|
|
2148
2120
|
})`
|
|
2149
2121
|
position: relative;
|
|
2150
2122
|
width: 100%;
|
|
@@ -2225,7 +2197,7 @@ var withFixedSizeContainer = (Viz) => {
|
|
|
2225
2197
|
FixSizeItem,
|
|
2226
2198
|
{
|
|
2227
2199
|
"data-test": "fix-size-item",
|
|
2228
|
-
"data-splunk-visualization-version": "28.
|
|
2200
|
+
"data-splunk-visualization-version": "28.5.0 - b192418b7",
|
|
2229
2201
|
width,
|
|
2230
2202
|
height,
|
|
2231
2203
|
backgroundColor
|
|
@@ -2312,6 +2284,7 @@ var withPlaceholder = (Visualization, useIconPlaceholder = shouldShowIconPlaceho
|
|
|
2312
2284
|
var withPlaceholder_default = withPlaceholder;
|
|
2313
2285
|
|
|
2314
2286
|
// src/common/utils/dataUtils.ts
|
|
2287
|
+
var getFieldName = (field) => typeof field === "string" ? field : field.name;
|
|
2315
2288
|
var largestTriangleThreeBuckets = (data, threshold, preferredDownsampleIndices) => {
|
|
2316
2289
|
const dataLength = data.length;
|
|
2317
2290
|
const downsampledIndices = [];
|
|
@@ -2428,9 +2401,9 @@ var tryToCoerceAllDisplayedFields = (ds, xField, yFields, fieldTypes, options) =
|
|
|
2428
2401
|
let xColumn = [];
|
|
2429
2402
|
const yColumns = [];
|
|
2430
2403
|
const canDownsample = !ds.data.fields.some((field, index) => {
|
|
2431
|
-
var _a
|
|
2432
|
-
const fieldName = (
|
|
2433
|
-
const fieldType = (
|
|
2404
|
+
var _a;
|
|
2405
|
+
const fieldName = getFieldName(field);
|
|
2406
|
+
const fieldType = (_a = fieldTypes[index]) != null ? _a : "unknown";
|
|
2434
2407
|
const column = ds.data.columns[index];
|
|
2435
2408
|
let hasDisplayedColumnThatCantBeDownsampled = false;
|
|
2436
2409
|
if (fieldName === xField) {
|
|
@@ -2717,7 +2690,7 @@ var trellisUtils_default = "default" in defaultImport33 ? defaultImport33.defaul
|
|
|
2717
2690
|
var AGGREGATIONS = "aggregations";
|
|
2718
2691
|
var dataSourcesSplitByAggregationsUnknown = (dataSource) => {
|
|
2719
2692
|
var _a, _b, _c, _d;
|
|
2720
|
-
const fields = (_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields;
|
|
2693
|
+
const fields = toFieldEntries((_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields);
|
|
2721
2694
|
const columns = (_d = (_c = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _c.data) == null ? void 0 : _d.columns;
|
|
2722
2695
|
let splitDataSources = null;
|
|
2723
2696
|
let errorCode = null;
|
|
@@ -2738,7 +2711,7 @@ var dataSourcesSplitByAggregationsUnknown = (dataSource) => {
|
|
|
2738
2711
|
}
|
|
2739
2712
|
return { splitDataSources, errorCode };
|
|
2740
2713
|
};
|
|
2741
|
-
var toFieldEntries = (fields) => {
|
|
2714
|
+
var toFieldEntries = (fields = []) => {
|
|
2742
2715
|
return fields.map((field) => {
|
|
2743
2716
|
if (typeof field === "string") {
|
|
2744
2717
|
return { name: field };
|
|
@@ -2753,7 +2726,7 @@ var dataSourcesSplitByAggregationsTimechartAndChart = (dataSource) => {
|
|
|
2753
2726
|
let splitDataSources = null;
|
|
2754
2727
|
let splitByFields = [];
|
|
2755
2728
|
let errorCode = null;
|
|
2756
|
-
if (
|
|
2729
|
+
if (fields.length > 0) {
|
|
2757
2730
|
splitByFields = (0, trellisUtils_exports.extractDataSourceAggregationKeysChart)(fields);
|
|
2758
2731
|
}
|
|
2759
2732
|
if (splitByFields && splitByFields.length > 0) {
|
|
@@ -2791,12 +2764,12 @@ var dataSourcesSplitByAggregationsTimechartAndChart = (dataSource) => {
|
|
|
2791
2764
|
};
|
|
2792
2765
|
var dataSourcesSplitByAggregationsStats = (dataSource) => {
|
|
2793
2766
|
var _a, _b, _c, _d;
|
|
2794
|
-
const fields = (_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields;
|
|
2767
|
+
const fields = toFieldEntries((_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields);
|
|
2795
2768
|
const columns = (_d = (_c = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _c.data) == null ? void 0 : _d.columns;
|
|
2796
2769
|
let splitDataSources = null;
|
|
2797
2770
|
let splitByFields = [];
|
|
2798
2771
|
let errorCode = null;
|
|
2799
|
-
if (
|
|
2772
|
+
if (fields.length > 0) {
|
|
2800
2773
|
splitByFields = (0, trellisUtils_exports.extractDataSourceAggregationKeysStats)(fields);
|
|
2801
2774
|
}
|
|
2802
2775
|
if (splitByFields && splitByFields.length > 0) {
|
|
@@ -2820,12 +2793,12 @@ var dataSourcesSplitByAggregationsStats = (dataSource) => {
|
|
|
2820
2793
|
};
|
|
2821
2794
|
var dataSourcesSplitByModeTimechart = (dataSource, splitBy) => {
|
|
2822
2795
|
var _a, _b, _c, _d, _e;
|
|
2823
|
-
const fields = (_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields;
|
|
2796
|
+
const fields = toFieldEntries((_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields);
|
|
2824
2797
|
const columns = (_d = (_c = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _c.data) == null ? void 0 : _d.columns;
|
|
2825
2798
|
let splitDataSources = null;
|
|
2826
2799
|
let splitByFields = [];
|
|
2827
2800
|
let errorCode = null;
|
|
2828
|
-
if (
|
|
2801
|
+
if (fields.length > 0) {
|
|
2829
2802
|
splitByFields = (0, trellisUtils_exports.extractSplitByFieldsChartFields)(fields);
|
|
2830
2803
|
}
|
|
2831
2804
|
if (splitByFields && splitByFields.indexOf(splitBy) > -1) {
|
|
@@ -2841,16 +2814,14 @@ var dataSourcesSplitByModeTimechart = (dataSource, splitBy) => {
|
|
|
2841
2814
|
splitDataSources[val] = (0, lodash_exports.cloneDeep)(
|
|
2842
2815
|
(0, lodash_exports.omit)(dataSource, ["primary.data.fields", "primary.data.columns"])
|
|
2843
2816
|
);
|
|
2844
|
-
splitDataSources[val].primary.data.fields = [
|
|
2845
|
-
{ name: fields[0].name },
|
|
2846
|
-
...dataSourceKeys.map((k) => ({
|
|
2847
|
-
name: k
|
|
2848
|
-
}))
|
|
2849
|
-
];
|
|
2817
|
+
splitDataSources[val].primary.data.fields = [{ name: fields[0].name }];
|
|
2850
2818
|
splitDataSources[val].primary.data.columns = [[...columns[0]]];
|
|
2851
2819
|
dataSourceKeys.forEach((dsKey) => {
|
|
2852
2820
|
fields.forEach((field, idx) => {
|
|
2853
2821
|
if (field.data_source === dsKey && (field.splitby_value === val || field.name === val)) {
|
|
2822
|
+
splitDataSources[val].primary.data.fields.push({
|
|
2823
|
+
name: dsKey
|
|
2824
|
+
});
|
|
2854
2825
|
splitDataSources[val].primary.data.columns.push([...columns[idx]]);
|
|
2855
2826
|
}
|
|
2856
2827
|
});
|
|
@@ -2863,12 +2834,12 @@ var dataSourcesSplitByModeTimechart = (dataSource, splitBy) => {
|
|
|
2863
2834
|
};
|
|
2864
2835
|
var dataSourcesSplitByModeChart = (dataSource, splitBy) => {
|
|
2865
2836
|
var _a, _b, _c, _d;
|
|
2866
|
-
const fields = (_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields;
|
|
2837
|
+
const fields = toFieldEntries((_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields);
|
|
2867
2838
|
const columns = (_d = (_c = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _c.data) == null ? void 0 : _d.columns;
|
|
2868
2839
|
let splitDataSources = null;
|
|
2869
2840
|
let splitByFields = [];
|
|
2870
2841
|
let errorCode = null;
|
|
2871
|
-
if (
|
|
2842
|
+
if (fields.length > 0) {
|
|
2872
2843
|
splitByFields = (0, trellisUtils_exports.extractSplitByFieldsChartFields)(fields);
|
|
2873
2844
|
}
|
|
2874
2845
|
if (splitByFields && splitByFields.indexOf(splitBy) > -1) {
|
|
@@ -2956,17 +2927,15 @@ var dataSourcesSplitByModeChart = (dataSource, splitBy) => {
|
|
|
2956
2927
|
};
|
|
2957
2928
|
var dataSourcesSplitByModeStatsorUnknown = (dataSource, splitBy, splitMode) => {
|
|
2958
2929
|
var _a, _b, _c, _d, _e, _f;
|
|
2959
|
-
const fields = (_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields;
|
|
2930
|
+
const fields = toFieldEntries((_b = (_a = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _a.data) == null ? void 0 : _b.fields);
|
|
2960
2931
|
const columns = (_d = (_c = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _c.data) == null ? void 0 : _d.columns;
|
|
2961
2932
|
let splitDataSources = null;
|
|
2962
2933
|
let splitByFields = [];
|
|
2963
2934
|
let errorCode = null;
|
|
2964
|
-
if (
|
|
2935
|
+
if (fields.length > 0) {
|
|
2965
2936
|
splitByFields = splitMode !== trellisUtils_exports.UNKNOWN ? (0, trellisUtils_exports.extractSplitByFieldsForStats)(fields) : (0, trellisUtils_exports.extractSplitByFieldsForUnknown)(fields);
|
|
2966
2937
|
}
|
|
2967
|
-
const splitByIndex = fields
|
|
2968
|
-
(field) => field === splitBy || field.name === splitBy
|
|
2969
|
-
);
|
|
2938
|
+
const splitByIndex = fields.findIndex((field) => field.name === splitBy);
|
|
2970
2939
|
if (splitByFields && splitByFields.indexOf(splitBy) > -1) {
|
|
2971
2940
|
const splitByColumn = (_f = (_e = dataSource == null ? void 0 : dataSource.primary) == null ? void 0 : _e.data) == null ? void 0 : _f.columns[splitByIndex];
|
|
2972
2941
|
splitDataSources = {};
|
|
@@ -3101,6 +3070,16 @@ var triangleEventAnnotationRenderer = ({
|
|
|
3101
3070
|
eventColor: eventWithColor.color
|
|
3102
3071
|
});
|
|
3103
3072
|
};
|
|
3073
|
+
var shouldEnableSearchZoom = (eventHandlers = [], xField = "") => {
|
|
3074
|
+
const rangeSelectEventHandler = eventHandlers.find(
|
|
3075
|
+
(eventHandler) => {
|
|
3076
|
+
var _a;
|
|
3077
|
+
return (_a = eventHandler.options.events) == null ? void 0 : _a.includes("range.select");
|
|
3078
|
+
}
|
|
3079
|
+
);
|
|
3080
|
+
const xAxisIsTime = xField === "_time";
|
|
3081
|
+
return !!rangeSelectEventHandler && xAxisIsTime;
|
|
3082
|
+
};
|
|
3104
3083
|
var canvasSupportedTimeSeriesCharts = ["splunk.line"];
|
|
3105
3084
|
var isTimeSeriesCanvasRenderSupported = (vizConfigKey) => {
|
|
3106
3085
|
return canvasSupportedTimeSeriesCharts.indexOf(vizConfigKey) > -1;
|
|
@@ -3121,17 +3100,34 @@ var filterChartDataFromInternalFields = (chartData) => {
|
|
|
3121
3100
|
var convert2DArrayToNumbers = (arr) => {
|
|
3122
3101
|
return arr.map((subArray) => subArray.map((element2) => parseFloat(element2)));
|
|
3123
3102
|
};
|
|
3124
|
-
var
|
|
3125
|
-
|
|
3103
|
+
var parseAxisValue = (val) => {
|
|
3104
|
+
if (val === void 0 || val === null || val === "auto" || val === "") {
|
|
3105
|
+
return void 0;
|
|
3106
|
+
}
|
|
3107
|
+
const num = typeof val === "number" ? val : Number.parseFloat(val);
|
|
3108
|
+
return Number.isNaN(num) ? void 0 : num;
|
|
3109
|
+
};
|
|
3110
|
+
var parseXAxisLineVisibility = (visibility) => {
|
|
3111
|
+
if (visibility === "hide") return false;
|
|
3112
|
+
if (visibility === "show") return true;
|
|
3113
|
+
return void 0;
|
|
3114
|
+
};
|
|
3126
3115
|
var getLegend = (props) => {
|
|
3127
3116
|
const legendPlacement = props == null ? void 0 : props.legendDisplay;
|
|
3117
|
+
const { isSeriesCompare, legendTruncation } = props;
|
|
3118
|
+
const commonLegendProps = {
|
|
3119
|
+
center: true,
|
|
3120
|
+
fontSize: 12,
|
|
3121
|
+
largerTiles: true,
|
|
3122
|
+
hideSeriesValue: !isSeriesCompare,
|
|
3123
|
+
// Show values if in seriesCompare mode
|
|
3124
|
+
legendTruncation
|
|
3125
|
+
};
|
|
3128
3126
|
switch (legendPlacement) {
|
|
3129
3127
|
case "off":
|
|
3130
3128
|
return false;
|
|
3131
3129
|
case "left":
|
|
3132
|
-
return (0, visualization_canvas_exports.LeftLegendFactory)(__spreadValues({
|
|
3133
|
-
width: SideLegendWidth
|
|
3134
|
-
}, commonLegendProps));
|
|
3130
|
+
return (0, visualization_canvas_exports.LeftLegendFactory)(__spreadValues({}, commonLegendProps));
|
|
3135
3131
|
case "bottom":
|
|
3136
3132
|
return (0, visualization_canvas_exports.BottomLegendFactory)(__spreadValues({
|
|
3137
3133
|
wrap: true
|
|
@@ -3141,9 +3137,7 @@ var getLegend = (props) => {
|
|
|
3141
3137
|
wrap: true
|
|
3142
3138
|
}, commonLegendProps));
|
|
3143
3139
|
default:
|
|
3144
|
-
return (0, visualization_canvas_exports.SideLegendFactory)(__spreadValues({
|
|
3145
|
-
width: SideLegendWidth
|
|
3146
|
-
}, commonLegendProps));
|
|
3140
|
+
return (0, visualization_canvas_exports.SideLegendFactory)(__spreadValues({}, commonLegendProps));
|
|
3147
3141
|
}
|
|
3148
3142
|
};
|
|
3149
3143
|
var getComputedAxisTitles = (inputAxisTitle, fields, axisTitleVisibility) => {
|
|
@@ -3178,22 +3172,25 @@ var ellipsisAxisTitle = (axisTitle, containerSpacing, fontSize = 12) => {
|
|
|
3178
3172
|
const end = axisTitle.slice(-halfChars);
|
|
3179
3173
|
return `${start}...${end}`;
|
|
3180
3174
|
};
|
|
3181
|
-
var
|
|
3175
|
+
var getFieldName2 = (field) => {
|
|
3182
3176
|
const fieldName = typeof field === "object" ? field == null ? void 0 : field.name : field;
|
|
3183
3177
|
return fieldName;
|
|
3184
3178
|
};
|
|
3185
3179
|
var getFieldNames = (fields) => {
|
|
3186
|
-
return fields.map((field) =>
|
|
3180
|
+
return fields.map((field) => getFieldName2(field));
|
|
3187
3181
|
};
|
|
3188
|
-
var getXScaleConfig = (label, xAxisLabelVisibility) => {
|
|
3182
|
+
var getXScaleConfig = (label, xAxisLabelVisibility, xAxisLabelRotation) => {
|
|
3189
3183
|
const xConfig = { x: {} };
|
|
3190
3184
|
xConfig.x.label = label;
|
|
3191
3185
|
if (xAxisLabelVisibility === "hide") {
|
|
3192
3186
|
xConfig.x.hideLabels = true;
|
|
3193
3187
|
}
|
|
3188
|
+
if (xAxisLabelRotation !== void 0) {
|
|
3189
|
+
xConfig.x.labelRotation = xAxisLabelRotation;
|
|
3190
|
+
}
|
|
3194
3191
|
return xConfig;
|
|
3195
3192
|
};
|
|
3196
|
-
var getYScaleConfig = (label, yAxisAbbreviation, yAxisScale, yAxisLabelVisibility) => {
|
|
3193
|
+
var getYScaleConfig = (label, yAxisAbbreviation, yAxisScale, yAxisLabelVisibility, yAxisMin, yAxisMax) => {
|
|
3197
3194
|
const scaleType = yAxisScale != null ? yAxisScale : "linear";
|
|
3198
3195
|
const yConfig = { y: {} };
|
|
3199
3196
|
yConfig.y.label = label;
|
|
@@ -3201,34 +3198,46 @@ var getYScaleConfig = (label, yAxisAbbreviation, yAxisScale, yAxisLabelVisibilit
|
|
|
3201
3198
|
if (yAxisAbbreviation !== "none") {
|
|
3202
3199
|
yConfig.y.tickFmt = (v) => (0, visualization_canvas_exports.shortenNumber)(v, 1);
|
|
3203
3200
|
}
|
|
3204
|
-
if (yAxisAbbreviation
|
|
3205
|
-
yConfig.y.width = 55;
|
|
3206
|
-
} else {
|
|
3201
|
+
if (yAxisAbbreviation !== "none") {
|
|
3207
3202
|
yConfig.y.width = label && label.length > 0 ? 30 : 10;
|
|
3208
3203
|
}
|
|
3209
3204
|
if (yAxisLabelVisibility === "hide") {
|
|
3210
3205
|
yConfig.y.hideLabels = true;
|
|
3211
3206
|
}
|
|
3207
|
+
if (yAxisMin !== void 0 || yAxisMax !== void 0) {
|
|
3208
|
+
yConfig.y.range = (u, dataMin, dataMax) => {
|
|
3209
|
+
const min = yAxisMin != null ? yAxisMin : dataMin;
|
|
3210
|
+
const max = yAxisMax != null ? yAxisMax : dataMax;
|
|
3211
|
+
return [min, max];
|
|
3212
|
+
};
|
|
3213
|
+
}
|
|
3212
3214
|
return yConfig;
|
|
3213
3215
|
};
|
|
3214
|
-
var getY2ScaleConfig = (label, axisAbbreviation, axisScale, roundAxisLabelsToInteger, y2AxisLabelVisibility) => {
|
|
3216
|
+
var getY2ScaleConfig = (label, axisAbbreviation, axisScale, roundAxisLabelsToInteger, y2AxisLabelVisibility, y2AxisMin, y2AxisMax) => {
|
|
3215
3217
|
const y2Config = { y2: {} };
|
|
3216
3218
|
const scaleType = axisScale != null ? axisScale : "linear";
|
|
3217
3219
|
y2Config.y2.label = label;
|
|
3218
3220
|
y2Config.y2.side = "right";
|
|
3219
|
-
y2Config.y2.showGrid = false;
|
|
3220
3221
|
y2Config.y2.type = scaleType;
|
|
3221
3222
|
if (axisAbbreviation !== "none") {
|
|
3222
3223
|
y2Config.y2.tickFmt = (v) => (0, visualization_canvas_exports.shortenNumber)(v, 1, roundAxisLabelsToInteger);
|
|
3224
|
+
y2Config.y2.width = label && label.length > 0 ? 50 : 10;
|
|
3223
3225
|
} else if (roundAxisLabelsToInteger) {
|
|
3224
3226
|
y2Config.y2.tickFmt = (v) => roundAxisLabelsToInteger ? Math.round(v).toString() : v.toString();
|
|
3225
3227
|
}
|
|
3226
3228
|
if (y2AxisLabelVisibility === "hide") {
|
|
3227
3229
|
y2Config.y2.hideLabels = true;
|
|
3228
3230
|
}
|
|
3231
|
+
if (y2AxisMin !== void 0 || y2AxisMax !== void 0) {
|
|
3232
|
+
y2Config.y2.range = (u, dataMin, dataMax) => {
|
|
3233
|
+
const min = y2AxisMin != null ? y2AxisMin : dataMin;
|
|
3234
|
+
const max = y2AxisMax != null ? y2AxisMax : dataMax;
|
|
3235
|
+
return [min, max];
|
|
3236
|
+
};
|
|
3237
|
+
}
|
|
3229
3238
|
return y2Config;
|
|
3230
3239
|
};
|
|
3231
|
-
var getSeriesOverrides = (yfields, y2fields, lineWidth, overlayFields, y2Enabled, nullValueMode, markerDisplay) => {
|
|
3240
|
+
var getSeriesOverrides = (yfields, y2fields, lineWidth, overlayFields, y2Enabled, nullValueMode, markerDisplay, lineDashStyle, lineDashStylesByField, stepPosition, stepPositionsByField) => {
|
|
3232
3241
|
const seriesConfig = {};
|
|
3233
3242
|
let spanGaps;
|
|
3234
3243
|
let replaceNullsWithZero;
|
|
@@ -3255,6 +3264,8 @@ var getSeriesOverrides = (yfields, y2fields, lineWidth, overlayFields, y2Enabled
|
|
|
3255
3264
|
);
|
|
3256
3265
|
if (shouldAssignToY2) {
|
|
3257
3266
|
seriesConfig[field].overrides.scale = "y2";
|
|
3267
|
+
} else {
|
|
3268
|
+
seriesConfig[field].overrides.scale = "y";
|
|
3258
3269
|
}
|
|
3259
3270
|
}
|
|
3260
3271
|
if (overlayFields == null ? void 0 : overlayFields.includes(field)) {
|
|
@@ -3263,12 +3274,50 @@ var getSeriesOverrides = (yfields, y2fields, lineWidth, overlayFields, y2Enabled
|
|
|
3263
3274
|
if (markerDisplay !== void 0) {
|
|
3264
3275
|
seriesConfig[field].markerDisplay = markerDisplay;
|
|
3265
3276
|
}
|
|
3277
|
+
const fieldDashStyle = (lineDashStylesByField == null ? void 0 : lineDashStylesByField[field]) || lineDashStyle;
|
|
3278
|
+
if (fieldDashStyle) {
|
|
3279
|
+
seriesConfig[field].lineDashStyle = fieldDashStyle;
|
|
3280
|
+
}
|
|
3281
|
+
const hasFieldStepPosition = Object.hasOwn(stepPositionsByField || {}, field);
|
|
3282
|
+
const fieldStepPosition = hasFieldStepPosition ? stepPositionsByField == null ? void 0 : stepPositionsByField[field] : stepPosition;
|
|
3283
|
+
if (fieldStepPosition && fieldStepPosition !== "off") {
|
|
3284
|
+
seriesConfig[field].stepPosition = fieldStepPosition;
|
|
3285
|
+
}
|
|
3266
3286
|
if (replaceNullsWithZero !== void 0) {
|
|
3267
3287
|
seriesConfig[field].replaceNullsWithZero = replaceNullsWithZero;
|
|
3268
3288
|
}
|
|
3269
3289
|
});
|
|
3270
3290
|
return seriesConfig;
|
|
3271
3291
|
};
|
|
3292
|
+
var findRangeIndices = (xData, startValue, endValue) => {
|
|
3293
|
+
let startXIndex = -1;
|
|
3294
|
+
let endXIndex = -1;
|
|
3295
|
+
const xDataEpoch = xData.map((val) => {
|
|
3296
|
+
if (typeof val === "string") {
|
|
3297
|
+
return new Date(val).getTime() / 1e3;
|
|
3298
|
+
}
|
|
3299
|
+
return val;
|
|
3300
|
+
});
|
|
3301
|
+
for (let i = 0; i < xDataEpoch.length; i += 1) {
|
|
3302
|
+
if (xDataEpoch[i] >= startValue) {
|
|
3303
|
+
startXIndex = i;
|
|
3304
|
+
break;
|
|
3305
|
+
}
|
|
3306
|
+
}
|
|
3307
|
+
if (startXIndex === -1 && xDataEpoch.length > 0) {
|
|
3308
|
+
startXIndex = xDataEpoch.length - 1;
|
|
3309
|
+
}
|
|
3310
|
+
for (let i = xDataEpoch.length - 1; i >= 0; i -= 1) {
|
|
3311
|
+
if (xDataEpoch[i] <= endValue) {
|
|
3312
|
+
endXIndex = i;
|
|
3313
|
+
break;
|
|
3314
|
+
}
|
|
3315
|
+
}
|
|
3316
|
+
if (endXIndex === -1 && xDataEpoch.length > 0) {
|
|
3317
|
+
endXIndex = 0;
|
|
3318
|
+
}
|
|
3319
|
+
return { startXIndex, endXIndex };
|
|
3320
|
+
};
|
|
3272
3321
|
|
|
3273
3322
|
// src/common/TimeSeriesChartWrapper.tsx
|
|
3274
3323
|
var TimeSeriesChartContainer = styled_components_default.div`
|
|
@@ -3279,38 +3328,123 @@ var TimeSeriesChartContainer = styled_components_default.div`
|
|
|
3279
3328
|
position: absolute !important; // This is needed for canvas element export pdf/png to work correctly
|
|
3280
3329
|
}
|
|
3281
3330
|
`;
|
|
3282
|
-
var
|
|
3331
|
+
var appendTrellisToPayload = (payload, trellisKey, trellisSplitBy) => {
|
|
3332
|
+
const result = __spreadValues({}, payload);
|
|
3333
|
+
if (trellisSplitBy) {
|
|
3334
|
+
result["trellis.name"] = trellisSplitBy;
|
|
3335
|
+
}
|
|
3336
|
+
if (trellisKey) {
|
|
3337
|
+
result["trellis.value"] = trellisKey;
|
|
3338
|
+
}
|
|
3339
|
+
return result;
|
|
3340
|
+
};
|
|
3341
|
+
var hasMouseoverPayloadChanged = (currentPayload, previousPayload) => {
|
|
3342
|
+
if (!previousPayload) {
|
|
3343
|
+
return true;
|
|
3344
|
+
}
|
|
3345
|
+
if (currentPayload.index !== previousPayload.index) {
|
|
3346
|
+
return true;
|
|
3347
|
+
}
|
|
3348
|
+
if (currentPayload.seriesIndex !== previousPayload.seriesIndex) {
|
|
3349
|
+
return true;
|
|
3350
|
+
}
|
|
3351
|
+
if (currentPayload["trellis.name"] !== previousPayload["trellis.name"]) {
|
|
3352
|
+
return true;
|
|
3353
|
+
}
|
|
3354
|
+
if (currentPayload["trellis.value"] !== previousPayload["trellis.value"]) {
|
|
3355
|
+
return true;
|
|
3356
|
+
}
|
|
3357
|
+
return false;
|
|
3358
|
+
};
|
|
3359
|
+
var handleClick = (chartEvent, onClick, trellisKey, trellisSplitBy) => {
|
|
3283
3360
|
const payload = __spreadProps(__spreadValues({}, (0, lodash_exports.pick)(chartEvent, "value", "seriesKey")), {
|
|
3284
3361
|
name: chartEvent.seriesKey
|
|
3285
3362
|
});
|
|
3286
3363
|
delete payload.seriesKey;
|
|
3287
3364
|
if (chartEvent.rowContext) {
|
|
3288
|
-
Object.
|
|
3289
|
-
payload
|
|
3290
|
-
|
|
3365
|
+
Object.assign(
|
|
3366
|
+
payload,
|
|
3367
|
+
Object.keys(chartEvent.rowContext).reduce((acc, fieldName) => {
|
|
3368
|
+
acc[`row.${fieldName}.value`] = chartEvent.rowContext[fieldName];
|
|
3369
|
+
return acc;
|
|
3370
|
+
}, {})
|
|
3371
|
+
);
|
|
3291
3372
|
}
|
|
3373
|
+
const updatedPayload = appendTrellisToPayload(payload, trellisKey, trellisSplitBy);
|
|
3292
3374
|
if (onClick) {
|
|
3293
3375
|
onClick({
|
|
3294
3376
|
type: "point.click",
|
|
3295
3377
|
originalEvent: chartEvent,
|
|
3296
|
-
payload
|
|
3378
|
+
payload: updatedPayload
|
|
3297
3379
|
});
|
|
3298
3380
|
}
|
|
3299
3381
|
};
|
|
3300
|
-
var handleLegendClick = (chartEvent, onClick) => {
|
|
3382
|
+
var handleLegendClick = (chartEvent, onClick, trellisKey, trellisSplitBy) => {
|
|
3301
3383
|
const payload = {
|
|
3302
3384
|
name: chartEvent
|
|
3303
3385
|
};
|
|
3386
|
+
const updatedPayload = appendTrellisToPayload(payload, trellisKey, trellisSplitBy);
|
|
3304
3387
|
if (onClick) {
|
|
3305
3388
|
onClick({
|
|
3306
3389
|
type: "legend.click",
|
|
3307
3390
|
originalEvent: chartEvent,
|
|
3308
|
-
payload
|
|
3391
|
+
payload: updatedPayload
|
|
3309
3392
|
});
|
|
3310
3393
|
}
|
|
3311
3394
|
};
|
|
3395
|
+
var handleRangeSelection = (rangeEvent, onSelect, chartData, trellisKey, trellisSplitBy) => {
|
|
3396
|
+
var _a;
|
|
3397
|
+
if (!rangeEvent) {
|
|
3398
|
+
return;
|
|
3399
|
+
}
|
|
3400
|
+
const xData = ((_a = chartData == null ? void 0 : chartData.columns) == null ? void 0 : _a[0]) || [];
|
|
3401
|
+
const { startXIndex, endXIndex } = findRangeIndices(xData, rangeEvent.start, rangeEvent.end);
|
|
3402
|
+
const payload = {
|
|
3403
|
+
startXIndex,
|
|
3404
|
+
startXValue: rangeEvent.start,
|
|
3405
|
+
endXIndex,
|
|
3406
|
+
endXValue: rangeEvent.end
|
|
3407
|
+
};
|
|
3408
|
+
const updatedPayload = appendTrellisToPayload(payload, trellisKey, trellisSplitBy);
|
|
3409
|
+
if (onSelect) {
|
|
3410
|
+
onSelect({
|
|
3411
|
+
type: "range.selectBeforeZoom",
|
|
3412
|
+
originalEvent: rangeEvent,
|
|
3413
|
+
payload: updatedPayload
|
|
3414
|
+
});
|
|
3415
|
+
}
|
|
3416
|
+
};
|
|
3417
|
+
var handleRangeZoom = (rangeEvent, onSelect, chartData, trellisKey, trellisSplitBy) => {
|
|
3418
|
+
var _a;
|
|
3419
|
+
const xData = ((_a = chartData == null ? void 0 : chartData.columns) == null ? void 0 : _a[0]) || [];
|
|
3420
|
+
const { startXIndex, endXIndex } = findRangeIndices(xData, rangeEvent.start, rangeEvent.end);
|
|
3421
|
+
const payload = {
|
|
3422
|
+
startXIndex,
|
|
3423
|
+
startXValue: rangeEvent.start,
|
|
3424
|
+
endXIndex,
|
|
3425
|
+
endXValue: rangeEvent.end
|
|
3426
|
+
};
|
|
3427
|
+
const updatedPayload = appendTrellisToPayload(payload, trellisKey, trellisSplitBy);
|
|
3428
|
+
if (onSelect) {
|
|
3429
|
+
onSelect({
|
|
3430
|
+
type: "range.select",
|
|
3431
|
+
originalEvent: rangeEvent,
|
|
3432
|
+
payload: updatedPayload
|
|
3433
|
+
});
|
|
3434
|
+
}
|
|
3435
|
+
};
|
|
3436
|
+
var parseArrayOption = (value) => {
|
|
3437
|
+
if (Array.isArray(value)) {
|
|
3438
|
+
return value;
|
|
3439
|
+
}
|
|
3440
|
+
if (value) {
|
|
3441
|
+
return JSON.parse(value);
|
|
3442
|
+
}
|
|
3443
|
+
return void 0;
|
|
3444
|
+
};
|
|
3312
3445
|
var TimeSeriesChartWrapper = (props) => {
|
|
3313
|
-
|
|
3446
|
+
var _b, _c, _d;
|
|
3447
|
+
const _a = props, {
|
|
3314
3448
|
width,
|
|
3315
3449
|
height,
|
|
3316
3450
|
chartData,
|
|
@@ -3323,12 +3457,57 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3323
3457
|
markerDisplay,
|
|
3324
3458
|
onClick,
|
|
3325
3459
|
onPointMouseOver,
|
|
3326
|
-
onPointMouseOut
|
|
3327
|
-
|
|
3328
|
-
|
|
3460
|
+
onPointMouseOut,
|
|
3461
|
+
onSelect,
|
|
3462
|
+
splitByLayout,
|
|
3463
|
+
trellisKey,
|
|
3464
|
+
trellisSplitBy,
|
|
3329
3465
|
backgroundColor,
|
|
3466
|
+
defaultFontColor,
|
|
3467
|
+
additionalTooltipValues,
|
|
3468
|
+
xAxisLineVisibility: xAxisLineVisibility,
|
|
3469
|
+
yAxisLineVisibility,
|
|
3470
|
+
y2AxisLineVisibility,
|
|
3471
|
+
showYAxisWithZero: showYAxisWithZeroFromProps,
|
|
3472
|
+
showY2AxisWithZero: showY2AxisWithZeroFromProps
|
|
3473
|
+
} = _a, otherOptions = __objRest(_a, [
|
|
3474
|
+
"width",
|
|
3475
|
+
"height",
|
|
3476
|
+
"chartData",
|
|
3477
|
+
"options",
|
|
3478
|
+
"userLocale",
|
|
3479
|
+
"annotationX",
|
|
3480
|
+
"annotationLabel",
|
|
3481
|
+
"annotationColor",
|
|
3482
|
+
"legendDisplay",
|
|
3483
|
+
"markerDisplay",
|
|
3484
|
+
"onClick",
|
|
3485
|
+
"onPointMouseOver",
|
|
3486
|
+
"onPointMouseOut",
|
|
3487
|
+
"onSelect",
|
|
3488
|
+
"splitByLayout",
|
|
3489
|
+
"trellisKey",
|
|
3490
|
+
"trellisSplitBy",
|
|
3491
|
+
"backgroundColor",
|
|
3492
|
+
"defaultFontColor",
|
|
3493
|
+
"additionalTooltipValues",
|
|
3494
|
+
// Extract axis line visibility options from props
|
|
3495
|
+
"xAxisLineVisibility",
|
|
3496
|
+
"yAxisLineVisibility",
|
|
3497
|
+
"y2AxisLineVisibility",
|
|
3498
|
+
// Extract showYAxisWithZero directly from props for accelerated render mode
|
|
3499
|
+
"showYAxisWithZero",
|
|
3500
|
+
"showY2AxisWithZero"
|
|
3501
|
+
]);
|
|
3502
|
+
const { eventHandlers, xField: xFieldFromProps } = otherOptions;
|
|
3503
|
+
const trellisEnabled = useTrellisEnabled(splitByLayout);
|
|
3504
|
+
const {
|
|
3505
|
+
backgroundColor: bgColorFromOptions,
|
|
3330
3506
|
seriesColors: seriesColorsStr,
|
|
3331
3507
|
fieldColors,
|
|
3508
|
+
legendLabels: legendLabelsStr,
|
|
3509
|
+
legendMode,
|
|
3510
|
+
legendTruncation,
|
|
3332
3511
|
"axisTitleX.text": xAxisTitleText,
|
|
3333
3512
|
"axisTitleY.text": yAxisTitleText,
|
|
3334
3513
|
"axisTitleY2.text": y2AxisTitleText,
|
|
@@ -3336,8 +3515,12 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3336
3515
|
"axisTitleY.visibility": yAxisTitleVisibility,
|
|
3337
3516
|
"axisTitleY2.visibility": y2AxisTitleVisibility,
|
|
3338
3517
|
"axisLabelsX.majorLabelVisibility": xAxisLabelVisibility,
|
|
3518
|
+
"axisLabelsX.majorLabelStyle.rotation": xAxisLabelRotation,
|
|
3519
|
+
"axisLabelsX.maxLabelParts": xAxisMaxLabelParts,
|
|
3339
3520
|
"axisLabelsY.majorLabelVisibility": yAxisLabelVisibility,
|
|
3521
|
+
"axisLabelsY.majorUnit": yAxisMajorUnitFromSimpleXML,
|
|
3340
3522
|
"axisLabelsY2.majorLabelVisibility": y2AxisLabelVisibility,
|
|
3523
|
+
"axisLabelsY2.majorUnit": y2AxisMajorUnitFromSimpleXML,
|
|
3341
3524
|
"axisY.abbreviation": yAxisAbbreviation,
|
|
3342
3525
|
"axisY.scale": yAxisScale,
|
|
3343
3526
|
"axisY2.abbreviation": y2AxisAbbreviation,
|
|
@@ -3347,10 +3530,73 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3347
3530
|
"axisLabelsY2.integerUnits": y2IntegerUnits,
|
|
3348
3531
|
"chart.overlayFields": overlayFieldsStr,
|
|
3349
3532
|
"chart.nullValueMode": nullValueMode,
|
|
3350
|
-
|
|
3533
|
+
"chart.showDataLabels": showDataLabels,
|
|
3534
|
+
lineWidth,
|
|
3535
|
+
lineDashStyle,
|
|
3536
|
+
fieldDashStyles: lineDashStylesByFieldStr,
|
|
3537
|
+
stepPosition,
|
|
3538
|
+
fieldStepPositions: stepPositionsByFieldStr,
|
|
3539
|
+
yAxisMin: yAxisMinRaw,
|
|
3540
|
+
yAxisMax: yAxisMaxRaw,
|
|
3541
|
+
y2AxisMin: y2AxisMinRaw,
|
|
3542
|
+
y2AxisMax: y2AxisMaxRaw,
|
|
3543
|
+
showXMajorGridLines,
|
|
3544
|
+
showYMajorGridLines,
|
|
3545
|
+
showY2MajorGridLines,
|
|
3546
|
+
showYMinorGridLines,
|
|
3547
|
+
showY2MinorGridLines,
|
|
3548
|
+
showLineSmoothing,
|
|
3549
|
+
xAxisMajorTickVisibility,
|
|
3550
|
+
xAxisMajorTickSize,
|
|
3551
|
+
yAxisMajorTickVisibility,
|
|
3552
|
+
y2AxisMajorTickVisibility,
|
|
3553
|
+
yAxisMajorTickSize,
|
|
3554
|
+
y2AxisMajorTickSize,
|
|
3555
|
+
yAxisMajorTickInterval,
|
|
3556
|
+
y2AxisMajorTickInterval,
|
|
3557
|
+
yAxisMinorTickVisibility,
|
|
3558
|
+
y2AxisMinorTickVisibility,
|
|
3559
|
+
yAxisMinorTickSize,
|
|
3560
|
+
y2AxisMinorTickSize,
|
|
3561
|
+
showYAxisWithZero: showYAxisWithZeroFromOptions,
|
|
3562
|
+
showY2AxisWithZero: showY2AxisWithZeroFromOptions
|
|
3351
3563
|
} = options;
|
|
3564
|
+
const dataValuesDisplay = showDataLabels === "none" ? "off" : showDataLabels;
|
|
3565
|
+
const showYAxisWithZero = showYAxisWithZeroFromProps != null ? showYAxisWithZeroFromProps : showYAxisWithZeroFromOptions;
|
|
3566
|
+
const showY2AxisWithZero = showY2AxisWithZeroFromProps != null ? showY2AxisWithZeroFromProps : showY2AxisWithZeroFromOptions;
|
|
3567
|
+
const showXMajorTicks = xAxisMajorTickVisibility !== "hide";
|
|
3568
|
+
const showYMajorTicks = yAxisMajorTickVisibility === "show";
|
|
3569
|
+
const showY2MajorTicks = y2AxisMajorTickVisibility === "show";
|
|
3570
|
+
const showYMinorTicks = yAxisMinorTickVisibility === "show";
|
|
3571
|
+
const showY2MinorTicks = y2AxisMinorTickVisibility === "show";
|
|
3572
|
+
const showXAxisLine = parseXAxisLineVisibility(xAxisLineVisibility);
|
|
3573
|
+
const showYAxisLine = yAxisLineVisibility === "show";
|
|
3574
|
+
const showY2AxisLine = y2AxisLineVisibility === "show";
|
|
3575
|
+
const yAxisMin = parseAxisValue(yAxisMinRaw);
|
|
3576
|
+
const yAxisMax = parseAxisValue(yAxisMaxRaw);
|
|
3577
|
+
const y2AxisMin = parseAxisValue(y2AxisMinRaw);
|
|
3578
|
+
const y2AxisMax = parseAxisValue(y2AxisMaxRaw);
|
|
3579
|
+
const parseTickInterval = (simpleXMLValue, canvasValue) => {
|
|
3580
|
+
if (simpleXMLValue) return Number(simpleXMLValue);
|
|
3581
|
+
if (canvasValue) return Number(canvasValue);
|
|
3582
|
+
return void 0;
|
|
3583
|
+
};
|
|
3584
|
+
const yAxisMajorTickIntervalNum = parseTickInterval(yAxisMajorUnitFromSimpleXML, yAxisMajorTickInterval);
|
|
3585
|
+
const y2AxisMajorTickIntervalNum = parseTickInterval(
|
|
3586
|
+
y2AxisMajorUnitFromSimpleXML,
|
|
3587
|
+
y2AxisMajorTickInterval
|
|
3588
|
+
);
|
|
3589
|
+
const xAxisMajorTickSizeNum = xAxisMajorTickSize != null ? Number(xAxisMajorTickSize) : void 0;
|
|
3590
|
+
const yAxisMajorTickSizeNum = yAxisMajorTickSize != null ? Number(yAxisMajorTickSize) : void 0;
|
|
3591
|
+
const y2AxisMajorTickSizeNum = y2AxisMajorTickSize != null ? Number(y2AxisMajorTickSize) : void 0;
|
|
3592
|
+
const yAxisMinorTickSizeNum = yAxisMinorTickSize != null ? Number(yAxisMinorTickSize) : void 0;
|
|
3593
|
+
const y2AxisMinorTickSizeNum = y2AxisMinorTickSize != null ? Number(y2AxisMinorTickSize) : void 0;
|
|
3352
3594
|
const seriesColors = seriesColorsStr ? JSON.parse(seriesColorsStr) : void 0;
|
|
3353
3595
|
const seriesColorsByField = fieldColors ? JSON.parse(fieldColors) : void 0;
|
|
3596
|
+
const lineDashStylesByField = lineDashStylesByFieldStr ? JSON.parse(lineDashStylesByFieldStr) : void 0;
|
|
3597
|
+
const stepPositionsByField = stepPositionsByFieldStr ? JSON.parse(stepPositionsByFieldStr) : void 0;
|
|
3598
|
+
const legendLabels = parseArrayOption(legendLabelsStr);
|
|
3599
|
+
const bgColor = backgroundColor || bgColorFromOptions;
|
|
3354
3600
|
const [containerWidth, setContainerWidth] = react_exports.useState(Number(props.width));
|
|
3355
3601
|
const [containerHeight, setContainerHeight] = react_exports.useState(Number(props.height));
|
|
3356
3602
|
const cachedHandleResize = react_exports.useCallback((w, h) => {
|
|
@@ -3361,31 +3607,64 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3361
3607
|
fields: chartData.fields,
|
|
3362
3608
|
columns: chartData.seriesList
|
|
3363
3609
|
});
|
|
3364
|
-
const xField =
|
|
3610
|
+
const xField = getFieldName2(filteredChartData.fields[0]);
|
|
3365
3611
|
const yFields = getFieldNames(
|
|
3366
3612
|
filteredChartData.fields.length > 1 ? filteredChartData.fields.slice(1) : []
|
|
3367
3613
|
);
|
|
3368
|
-
const y2Fields =
|
|
3369
|
-
|
|
3614
|
+
const y2Fields = (0, react_exports.useMemo)(
|
|
3615
|
+
() => y2FieldsStr ? y2FieldsStr.split(",").map((f) => f.trim()) : [],
|
|
3616
|
+
[y2FieldsStr]
|
|
3617
|
+
);
|
|
3618
|
+
const overlayFields = (0, react_exports.useMemo)(
|
|
3619
|
+
() => overlayFieldsStr ? overlayFieldsStr.split(",").map((f) => f.trim()) : [],
|
|
3620
|
+
[overlayFieldsStr]
|
|
3621
|
+
);
|
|
3370
3622
|
let xAxisTitle = getComputedAxisTitles(xAxisTitleText, [xField], xAxisTitleVisibility);
|
|
3371
3623
|
xAxisTitle = ellipsisAxisTitle(xAxisTitle, containerWidth);
|
|
3372
|
-
|
|
3624
|
+
const yFieldsForTitle = y2Enabled ? yFields.filter((field) => !y2Fields.includes(field)) : yFields;
|
|
3625
|
+
let yAxisTitle = getComputedAxisTitles(yAxisTitleText, yFieldsForTitle, yAxisTitleVisibility);
|
|
3373
3626
|
yAxisTitle = ellipsisAxisTitle(yAxisTitle, containerHeight);
|
|
3374
3627
|
const fieldsForY2Axis = y2Fields.length > 0 ? y2Fields : overlayFields;
|
|
3375
3628
|
let y2AxisTitle = getComputedAxisTitles(y2AxisTitleText, fieldsForY2Axis, y2AxisTitleVisibility);
|
|
3376
3629
|
y2AxisTitle = ellipsisAxisTitle(y2AxisTitle, containerHeight);
|
|
3377
|
-
const xScaleConfig =
|
|
3378
|
-
|
|
3379
|
-
|
|
3380
|
-
|
|
3381
|
-
|
|
3382
|
-
|
|
3383
|
-
|
|
3384
|
-
|
|
3385
|
-
|
|
3386
|
-
|
|
3387
|
-
|
|
3388
|
-
|
|
3630
|
+
const xScaleConfig = (0, react_exports.useMemo)(
|
|
3631
|
+
() => getXScaleConfig(xAxisTitle, xAxisLabelVisibility, xAxisLabelRotation),
|
|
3632
|
+
[xAxisTitle, xAxisLabelVisibility, xAxisLabelRotation]
|
|
3633
|
+
);
|
|
3634
|
+
const yScaleConfig = (0, react_exports.useMemo)(
|
|
3635
|
+
() => getYScaleConfig(
|
|
3636
|
+
yAxisTitle,
|
|
3637
|
+
yAxisAbbreviation,
|
|
3638
|
+
yAxisScale,
|
|
3639
|
+
yAxisLabelVisibility,
|
|
3640
|
+
yAxisMin,
|
|
3641
|
+
yAxisMax
|
|
3642
|
+
),
|
|
3643
|
+
[yAxisTitle, yAxisAbbreviation, yAxisScale, yAxisLabelVisibility, yAxisMin, yAxisMax]
|
|
3644
|
+
);
|
|
3645
|
+
const y2ScaleConfig = (0, react_exports.useMemo)(() => {
|
|
3646
|
+
if (y2Enabled) {
|
|
3647
|
+
return getY2ScaleConfig(
|
|
3648
|
+
y2AxisTitle,
|
|
3649
|
+
y2AxisAbbreviation,
|
|
3650
|
+
y2AxisScale,
|
|
3651
|
+
y2IntegerUnits,
|
|
3652
|
+
y2AxisLabelVisibility,
|
|
3653
|
+
y2AxisMin,
|
|
3654
|
+
y2AxisMax
|
|
3655
|
+
);
|
|
3656
|
+
}
|
|
3657
|
+
return {};
|
|
3658
|
+
}, [
|
|
3659
|
+
y2Enabled,
|
|
3660
|
+
y2AxisTitle,
|
|
3661
|
+
y2AxisAbbreviation,
|
|
3662
|
+
y2AxisScale,
|
|
3663
|
+
y2IntegerUnits,
|
|
3664
|
+
y2AxisLabelVisibility,
|
|
3665
|
+
y2AxisMin,
|
|
3666
|
+
y2AxisMax
|
|
3667
|
+
]);
|
|
3389
3668
|
const uplotContainerElement = (0, react_exports.useRef)(null);
|
|
3390
3669
|
const seriesDataFormatted = [
|
|
3391
3670
|
filteredChartData.columns[0],
|
|
@@ -3401,9 +3680,25 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3401
3680
|
overlayFields,
|
|
3402
3681
|
y2Enabled,
|
|
3403
3682
|
nullValueMode,
|
|
3404
|
-
markerDisplay
|
|
3683
|
+
markerDisplay,
|
|
3684
|
+
lineDashStyle,
|
|
3685
|
+
lineDashStylesByField,
|
|
3686
|
+
stepPosition,
|
|
3687
|
+
stepPositionsByField
|
|
3405
3688
|
),
|
|
3406
|
-
[
|
|
3689
|
+
[
|
|
3690
|
+
yFields,
|
|
3691
|
+
y2Fields,
|
|
3692
|
+
lineWidth,
|
|
3693
|
+
overlayFields,
|
|
3694
|
+
y2Enabled,
|
|
3695
|
+
nullValueMode,
|
|
3696
|
+
markerDisplay,
|
|
3697
|
+
lineDashStyle,
|
|
3698
|
+
lineDashStylesByField,
|
|
3699
|
+
stepPosition,
|
|
3700
|
+
stepPositionsByField
|
|
3701
|
+
]
|
|
3407
3702
|
);
|
|
3408
3703
|
const chartingEventAnnotations = (0, react_exports.useMemo)(
|
|
3409
3704
|
() => getAnnotationsForCanvas({
|
|
@@ -3417,25 +3712,59 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3417
3712
|
() => __spreadValues(__spreadValues(__spreadValues({}, xScaleConfig), yScaleConfig), y2ScaleConfig),
|
|
3418
3713
|
[xScaleConfig, yScaleConfig, y2ScaleConfig]
|
|
3419
3714
|
);
|
|
3420
|
-
const
|
|
3715
|
+
const isSeriesCompare = legendMode === "seriesCompare";
|
|
3716
|
+
const legend = (0, react_exports.useMemo)(
|
|
3717
|
+
() => getLegend({
|
|
3718
|
+
legendDisplay: isSeriesCompare && legendDisplay !== "off" ? "right" : legendDisplay,
|
|
3719
|
+
isSeriesCompare,
|
|
3720
|
+
legendTruncation
|
|
3721
|
+
}),
|
|
3722
|
+
[legendDisplay, isSeriesCompare, legendTruncation]
|
|
3723
|
+
);
|
|
3421
3724
|
const handleChartClick = react_exports.useCallback(
|
|
3422
3725
|
(event) => {
|
|
3423
3726
|
if (onClick) {
|
|
3424
|
-
handleClick(event, onClick);
|
|
3727
|
+
handleClick(event, onClick, trellisKey, trellisSplitBy);
|
|
3425
3728
|
}
|
|
3426
3729
|
},
|
|
3427
|
-
[onClick]
|
|
3730
|
+
[onClick, trellisKey, trellisSplitBy]
|
|
3428
3731
|
);
|
|
3429
3732
|
const handleChartLegendClick = react_exports.useCallback(
|
|
3430
3733
|
(event) => {
|
|
3431
3734
|
if (onClick) {
|
|
3432
|
-
handleLegendClick(event, onClick);
|
|
3735
|
+
handleLegendClick(event, onClick, trellisKey, trellisSplitBy);
|
|
3736
|
+
}
|
|
3737
|
+
},
|
|
3738
|
+
[onClick, trellisKey, trellisSplitBy]
|
|
3739
|
+
);
|
|
3740
|
+
const handleChartRangeSelection = react_exports.useCallback(
|
|
3741
|
+
(range2) => {
|
|
3742
|
+
if (onSelect) {
|
|
3743
|
+
handleRangeSelection(range2, onSelect, chartData, trellisKey, trellisSplitBy);
|
|
3433
3744
|
}
|
|
3434
3745
|
},
|
|
3435
|
-
[
|
|
3746
|
+
[onSelect, chartData, trellisKey, trellisSplitBy]
|
|
3747
|
+
);
|
|
3748
|
+
const handleChartRangeZoom = react_exports.useCallback(
|
|
3749
|
+
(range2) => {
|
|
3750
|
+
if (onSelect) {
|
|
3751
|
+
handleRangeZoom(range2, onSelect, chartData, trellisKey, trellisSplitBy);
|
|
3752
|
+
}
|
|
3753
|
+
},
|
|
3754
|
+
[onSelect, chartData, trellisKey, trellisSplitBy]
|
|
3755
|
+
);
|
|
3756
|
+
const xFieldToUse = xFieldFromProps || xField;
|
|
3757
|
+
const enableSearchZoom = react_exports.useMemo(
|
|
3758
|
+
() => shouldEnableSearchZoom(eventHandlers, xFieldToUse),
|
|
3759
|
+
[eventHandlers, xFieldToUse]
|
|
3436
3760
|
);
|
|
3437
3761
|
const lastPayloadRef = react_exports.useRef(null);
|
|
3438
3762
|
const lastOriginalEventRef = react_exports.useRef(null);
|
|
3763
|
+
const previousMouseoverPayloadRef = react_exports.useRef(null);
|
|
3764
|
+
const additionalTooltipValuesRef = react_exports.useRef(additionalTooltipValues);
|
|
3765
|
+
react_exports.useEffect(() => {
|
|
3766
|
+
additionalTooltipValuesRef.current = additionalTooltipValues;
|
|
3767
|
+
}, [additionalTooltipValues]);
|
|
3439
3768
|
const handleChartCrosshairChange = react_exports.useCallback(
|
|
3440
3769
|
(event) => {
|
|
3441
3770
|
if (onPointMouseOver || onPointMouseOut) {
|
|
@@ -3447,6 +3776,7 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3447
3776
|
payload: lastPayloadRef.current
|
|
3448
3777
|
});
|
|
3449
3778
|
}
|
|
3779
|
+
previousMouseoverPayloadRef.current = null;
|
|
3450
3780
|
return;
|
|
3451
3781
|
}
|
|
3452
3782
|
const payload = __spreadProps(__spreadValues({}, (0, lodash_exports.pick)(event, "value", "seriesKey", "time", "index", "seriesIndex")), {
|
|
@@ -3454,25 +3784,36 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3454
3784
|
});
|
|
3455
3785
|
delete payload.seriesKey;
|
|
3456
3786
|
if (event.rowContext) {
|
|
3457
|
-
Object.
|
|
3458
|
-
payload
|
|
3459
|
-
|
|
3787
|
+
Object.assign(
|
|
3788
|
+
payload,
|
|
3789
|
+
Object.keys(event.rowContext).reduce((acc, fieldName) => {
|
|
3790
|
+
acc[`row.${fieldName}.value`] = event.rowContext[fieldName];
|
|
3791
|
+
return acc;
|
|
3792
|
+
}, {})
|
|
3793
|
+
);
|
|
3460
3794
|
}
|
|
3461
|
-
|
|
3795
|
+
const updatedPayload = appendTrellisToPayload(payload, trellisKey, trellisSplitBy);
|
|
3796
|
+
if (!hasMouseoverPayloadChanged(updatedPayload, previousMouseoverPayloadRef.current)) {
|
|
3797
|
+
return;
|
|
3798
|
+
}
|
|
3799
|
+
lastPayloadRef.current = updatedPayload;
|
|
3462
3800
|
lastOriginalEventRef.current = event;
|
|
3801
|
+
previousMouseoverPayloadRef.current = __spreadValues({}, updatedPayload);
|
|
3463
3802
|
if (onPointMouseOver) {
|
|
3464
3803
|
onPointMouseOver({
|
|
3465
3804
|
type: "point.mouseover",
|
|
3466
3805
|
originalEvent: event,
|
|
3467
|
-
payload
|
|
3806
|
+
payload: updatedPayload
|
|
3468
3807
|
});
|
|
3469
3808
|
}
|
|
3470
3809
|
}
|
|
3471
3810
|
},
|
|
3472
|
-
[onPointMouseOver, onPointMouseOut]
|
|
3811
|
+
[onPointMouseOver, onPointMouseOut, trellisKey, trellisSplitBy]
|
|
3473
3812
|
);
|
|
3474
|
-
const
|
|
3475
|
-
|
|
3813
|
+
const dataKey = `${(_b = chartData.columns[0]) == null ? void 0 : _b[0]}-${(_c = chartData.columns[0]) == null ? void 0 : _c[chartData.columns[0].length - 1]}-${(_d = chartData.columns[0]) == null ? void 0 : _d.length}`;
|
|
3814
|
+
const memoizedChart = (0, react_exports.useMemo)(() => {
|
|
3815
|
+
const computedOnRangeZoom = onSelect ? handleChartRangeZoom : void 0;
|
|
3816
|
+
return /* @__PURE__ */ react_exports.createElement(visualization_canvas_exports.RangeSelectionProvider, { key: dataKey }, /* @__PURE__ */ react_exports.createElement(
|
|
3476
3817
|
visualization_canvas_exports.TimeSeriesChart,
|
|
3477
3818
|
{
|
|
3478
3819
|
data: chartData,
|
|
@@ -3482,49 +3823,121 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
3482
3823
|
seriesColorsByField,
|
|
3483
3824
|
seriesConfig: seriesOverrides,
|
|
3484
3825
|
legend,
|
|
3826
|
+
legendLabels,
|
|
3827
|
+
legendTruncation,
|
|
3828
|
+
isSeriesCompare: legendMode === "seriesCompare",
|
|
3829
|
+
maxSeriesFocus: legendMode === "seriesCompare" ? 0 : void 0,
|
|
3485
3830
|
scaleConfig,
|
|
3486
3831
|
timestampFormat: "expanded",
|
|
3487
3832
|
onCrosshairClick: onClick ? handleChartClick : void 0,
|
|
3488
3833
|
onCrosshairChange: onPointMouseOver || onPointMouseOut ? handleChartCrosshairChange : void 0,
|
|
3489
3834
|
onSeriesClick: onClick ? handleChartLegendClick : void 0,
|
|
3835
|
+
onRangeSelection: handleChartRangeSelection,
|
|
3836
|
+
onRangeZoom: computedOnRangeZoom,
|
|
3837
|
+
serverSideZoom: enableSearchZoom,
|
|
3490
3838
|
userLocale,
|
|
3491
3839
|
events: chartingEventAnnotations,
|
|
3492
|
-
eventsConfig: { renderer: triangleEventAnnotationRenderer }
|
|
3840
|
+
eventsConfig: { renderer: triangleEventAnnotationRenderer },
|
|
3841
|
+
additionalTooltipValuesRef,
|
|
3842
|
+
showXMajorGridLines,
|
|
3843
|
+
showYMajorGridLines,
|
|
3844
|
+
showY2MajorGridLines,
|
|
3845
|
+
showYMinorGridLines,
|
|
3846
|
+
showY2MinorGridLines,
|
|
3847
|
+
showLineSmoothing,
|
|
3848
|
+
dataValuesDisplay,
|
|
3849
|
+
showXMajorTicks,
|
|
3850
|
+
xAxisMajorTickSize: xAxisMajorTickSizeNum,
|
|
3851
|
+
showYMajorTicks,
|
|
3852
|
+
showY2MajorTicks,
|
|
3853
|
+
yAxisMajorTickSize: yAxisMajorTickSizeNum,
|
|
3854
|
+
y2AxisMajorTickSize: y2AxisMajorTickSizeNum,
|
|
3855
|
+
yAxisMajorTickInterval: yAxisMajorTickIntervalNum,
|
|
3856
|
+
y2AxisMajorTickInterval: y2AxisMajorTickIntervalNum,
|
|
3857
|
+
showYMinorTicks,
|
|
3858
|
+
showY2MinorTicks,
|
|
3859
|
+
yAxisMinorTickSize: yAxisMinorTickSizeNum,
|
|
3860
|
+
y2AxisMinorTickSize: y2AxisMinorTickSizeNum,
|
|
3861
|
+
showYAxisWithZero,
|
|
3862
|
+
showY2AxisWithZero,
|
|
3863
|
+
showXAxisLine,
|
|
3864
|
+
showYAxisLine,
|
|
3865
|
+
showY2AxisLine,
|
|
3866
|
+
xAxisMaxLabelParts
|
|
3493
3867
|
}
|
|
3494
|
-
)
|
|
3495
|
-
|
|
3496
|
-
|
|
3497
|
-
|
|
3498
|
-
|
|
3499
|
-
|
|
3500
|
-
|
|
3501
|
-
|
|
3502
|
-
|
|
3503
|
-
|
|
3504
|
-
|
|
3505
|
-
|
|
3506
|
-
|
|
3507
|
-
|
|
3508
|
-
|
|
3509
|
-
|
|
3510
|
-
|
|
3511
|
-
|
|
3512
|
-
|
|
3513
|
-
|
|
3868
|
+
));
|
|
3869
|
+
}, [
|
|
3870
|
+
onSelect,
|
|
3871
|
+
handleChartRangeZoom,
|
|
3872
|
+
dataKey,
|
|
3873
|
+
chartData,
|
|
3874
|
+
containerWidth,
|
|
3875
|
+
containerHeight,
|
|
3876
|
+
seriesColors,
|
|
3877
|
+
seriesColorsByField,
|
|
3878
|
+
seriesOverrides,
|
|
3879
|
+
legend,
|
|
3880
|
+
legendLabels,
|
|
3881
|
+
legendTruncation,
|
|
3882
|
+
scaleConfig,
|
|
3883
|
+
onClick,
|
|
3884
|
+
handleChartClick,
|
|
3885
|
+
onPointMouseOver,
|
|
3886
|
+
onPointMouseOut,
|
|
3887
|
+
handleChartCrosshairChange,
|
|
3888
|
+
handleChartLegendClick,
|
|
3889
|
+
handleChartRangeSelection,
|
|
3890
|
+
enableSearchZoom,
|
|
3891
|
+
userLocale,
|
|
3892
|
+
chartingEventAnnotations,
|
|
3893
|
+
showXMajorGridLines,
|
|
3894
|
+
showYMajorGridLines,
|
|
3895
|
+
showY2MajorGridLines,
|
|
3896
|
+
showYMinorGridLines,
|
|
3897
|
+
showY2MinorGridLines,
|
|
3898
|
+
showLineSmoothing,
|
|
3899
|
+
dataValuesDisplay,
|
|
3900
|
+
showXMajorTicks,
|
|
3901
|
+
xAxisMajorTickSizeNum,
|
|
3902
|
+
showYMajorTicks,
|
|
3903
|
+
showY2MajorTicks,
|
|
3904
|
+
yAxisMajorTickSizeNum,
|
|
3905
|
+
y2AxisMajorTickSizeNum,
|
|
3906
|
+
yAxisMajorTickIntervalNum,
|
|
3907
|
+
y2AxisMajorTickIntervalNum,
|
|
3908
|
+
showYMinorTicks,
|
|
3909
|
+
showY2MinorTicks,
|
|
3910
|
+
yAxisMinorTickSizeNum,
|
|
3911
|
+
y2AxisMinorTickSizeNum,
|
|
3912
|
+
showYAxisWithZero,
|
|
3913
|
+
showY2AxisWithZero,
|
|
3914
|
+
showXAxisLine,
|
|
3915
|
+
showYAxisLine,
|
|
3916
|
+
showY2AxisLine,
|
|
3917
|
+
legendMode,
|
|
3918
|
+
xAxisMaxLabelParts
|
|
3919
|
+
]);
|
|
3514
3920
|
const memoizedVisualization = (0, react_exports.useMemo)(() => {
|
|
3515
|
-
return /* @__PURE__ */ react_exports.createElement(VizStyleWrapper_default, { backgroundColor }, memoizedChart);
|
|
3516
|
-
}, [
|
|
3517
|
-
return /* @__PURE__ */ react_exports.createElement(
|
|
3921
|
+
return /* @__PURE__ */ react_exports.createElement(VizStyleWrapper_default, { backgroundColor: bgColor }, memoizedChart);
|
|
3922
|
+
}, [bgColor, memoizedChart]);
|
|
3923
|
+
return /* @__PURE__ */ react_exports.createElement(react_exports.Fragment, null, trellisEnabled && /* @__PURE__ */ react_exports.createElement(
|
|
3924
|
+
TrellisTitle,
|
|
3925
|
+
{
|
|
3926
|
+
trellisKey,
|
|
3927
|
+
backgroundColor: bgColor,
|
|
3928
|
+
fontColor: defaultFontColor
|
|
3929
|
+
}
|
|
3930
|
+
), /* @__PURE__ */ react_exports.createElement(
|
|
3518
3931
|
TimeSeriesChartContainer,
|
|
3519
3932
|
{
|
|
3520
|
-
height,
|
|
3933
|
+
height: trellisEnabled ? Number(height) - TRELLIS_TITLE_HEIGHT : height,
|
|
3521
3934
|
width,
|
|
3522
3935
|
ref: uplotContainerElement,
|
|
3523
3936
|
"data-test": "timeseries-chart-wrapper"
|
|
3524
3937
|
},
|
|
3525
3938
|
/* @__PURE__ */ react_exports.createElement(SizeAwareWrapper_default, { width, height, onResize: cachedHandleResize }),
|
|
3526
3939
|
memoizedVisualization
|
|
3527
|
-
);
|
|
3940
|
+
));
|
|
3528
3941
|
};
|
|
3529
3942
|
var TimeSeriesChartWrapper_default = TimeSeriesChartWrapper;
|
|
3530
3943
|
|
|
@@ -3855,7 +4268,6 @@ var StaticMajorAndTrendLayout = [
|
|
|
3855
4268
|
[
|
|
3856
4269
|
{
|
|
3857
4270
|
label: (0, i18n_exports._)("Unit position"),
|
|
3858
|
-
// todo: we need a new editor combining unit and position
|
|
3859
4271
|
option: "unitPosition",
|
|
3860
4272
|
editor: "editor.select",
|
|
3861
4273
|
editorProps: {
|