@splunk/visualizations 28.5.2 → 28.6.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/areaUtils.d.ts +1 -1
- package/Area/areaUtils.d.ts.map +1 -1
- package/Area/config.d.ts.map +1 -1
- package/Area.config.js +93 -25
- package/Area.config.js.map +3 -3
- package/Area.js +708 -319
- package/Area.js.map +4 -4
- package/Bar/Bar.d.ts.map +1 -1
- package/Bar.config.js +81 -24
- package/Bar.config.js.map +3 -3
- package/Bar.js +528 -297
- package/Bar.js.map +4 -4
- package/Bubble.config.js +80 -23
- package/Bubble.config.js.map +2 -2
- package/Bubble.js +375 -208
- package/Bubble.js.map +4 -4
- package/CHANGELOG.external.md +75 -8
- package/ChoroplethSvg/PureChoroplethSvg/PureChoroplethSvg.d.ts +1 -0
- package/ChoroplethSvg/PureChoroplethSvg/PureChoroplethSvg.d.ts.map +1 -1
- package/ChoroplethSvg/PureChoroplethSvg/SvgChoroplethDynamic.d.ts +12 -25
- package/ChoroplethSvg/PureChoroplethSvg/SvgChoroplethDynamic.d.ts.map +1 -1
- package/ChoroplethSvg/PureChoroplethSvg/SvgMutator.d.ts +11 -4
- package/ChoroplethSvg/PureChoroplethSvg/SvgMutator.d.ts.map +1 -1
- package/ChoroplethSvg.js +1133 -253
- package/ChoroplethSvg.js.map +4 -4
- package/Column/Column.d.ts.map +1 -1
- package/Column.config.js +81 -24
- package/Column.config.js.map +3 -3
- package/Column.js +531 -300
- package/Column.js.map +4 -4
- package/Ellipse.config.js +1 -1
- package/Ellipse.config.js.map +2 -2
- package/Ellipse.js +277 -161
- package/Ellipse.js.map +4 -4
- package/Events/config.d.ts.map +1 -1
- package/Events.config.js +13 -3
- package/Events.config.js.map +2 -2
- package/Events.js +330 -194
- package/Events.js.map +4 -4
- package/FillerGauge/FillerGauge.d.ts.map +1 -1
- package/FillerGauge/config.d.ts.map +1 -1
- package/FillerGauge.config.js +76 -24
- package/FillerGauge.config.js.map +2 -2
- package/FillerGauge.js +512 -271
- package/FillerGauge.js.map +4 -4
- package/Image/config.d.ts.map +1 -1
- package/Image.config.js +7 -0
- package/Image.config.js.map +2 -2
- package/Image.js +282 -149
- package/Image.js.map +4 -4
- package/LICENSE +13 -0
- package/Line/Line.d.ts.map +1 -1
- package/Line/config.d.ts.map +1 -1
- package/Line/lineUtils.d.ts.map +1 -1
- package/Line/mockdata/LineData.d.ts +21 -0
- package/Line/mockdata/LineData.d.ts.map +1 -1
- package/Line.config.js +86 -25
- package/Line.config.js.map +3 -3
- package/Line.js +638 -382
- package/Line.js.map +4 -4
- package/LinkGraph/PureLinkGraph/PureLinkGraph.d.ts +47 -73
- package/LinkGraph/PureLinkGraph/PureLinkGraph.d.ts.map +1 -1
- package/LinkGraph/PureLinkGraph/PureLinkGraphUtils.d.ts +11 -2
- package/LinkGraph/PureLinkGraph/PureLinkGraphUtils.d.ts.map +1 -1
- package/LinkGraph/PureLinkGraph/components/Graph.d.ts +5 -5
- package/LinkGraph/PureLinkGraph/components/Node.d.ts +2 -2
- package/LinkGraph/PureLinkGraph/components/Nodes.d.ts +2 -2
- package/LinkGraph.js +886 -759
- package/LinkGraph.js.map +4 -4
- package/Map/PureMap/BubbleLayer.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 +4 -1
- package/Map.config.js.map +2 -2
- package/Map.js +296 -169
- package/Map.js.map +4 -4
- package/Markdown/Markdown.d.ts.map +1 -1
- package/Markdown.config.js.map +1 -1
- package/Markdown.js +283 -157
- package/Markdown.js.map +4 -4
- package/MarkerGauge/MarkerGauge.d.ts +1 -47
- package/MarkerGauge/MarkerGauge.d.ts.map +1 -1
- package/MarkerGauge/PureMarkerGauge/MarkerGauge.d.ts +22 -68
- package/MarkerGauge/PureMarkerGauge/MarkerGauge.d.ts.map +1 -1
- package/MarkerGauge/config.d.ts.map +1 -1
- package/MarkerGauge.config.js +75 -23
- package/MarkerGauge.config.js.map +2 -2
- package/MarkerGauge.js +560 -375
- package/MarkerGauge.js.map +4 -4
- package/NetworkGraph/NetworkGraph.d.ts +2 -1
- package/NetworkGraph/NetworkGraph.d.ts.map +1 -1
- package/NetworkGraph/PureNetworkGraph/utils/networkGraphUtils.d.ts.map +1 -1
- package/NetworkGraph.config.js.map +2 -2
- package/NetworkGraph.js +628 -434
- package/NetworkGraph.js.map +4 -4
- package/ParallelCoordinates.config.js.map +1 -1
- package/ParallelCoordinates.js +288 -172
- package/ParallelCoordinates.js.map +4 -4
- package/Pie/Pie.d.ts.map +1 -1
- package/Pie/pieUtils.d.ts +2 -2
- package/Pie.config.js +74 -22
- package/Pie.config.js.map +2 -2
- package/Pie.js +522 -296
- package/Pie.js.map +4 -4
- package/ProcessTree/ProcessTree.d.ts +21 -0
- package/ProcessTree/ProcessTree.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/PureProcessTree.d.ts +32 -0
- package/ProcessTree/PureProcessTree/PureProcessTree.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/components/DirectionalBytes.d.ts +8 -0
- package/ProcessTree/PureProcessTree/components/DirectionalBytes.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/components/ProcessTreeLeftPanel.d.ts +44 -0
- package/ProcessTree/PureProcessTree/components/ProcessTreeLeftPanel.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/components/ProcessTreeRightPanel.d.ts +20 -0
- package/ProcessTree/PureProcessTree/components/ProcessTreeRightPanel.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/hooks/useProcessTreeExpansionState.d.ts +20 -0
- package/ProcessTree/PureProcessTree/hooks/useProcessTreeExpansionState.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/hooks/useProcessTreeGraphData.d.ts +44 -0
- package/ProcessTree/PureProcessTree/hooks/useProcessTreeGraphData.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/hooks/useProcessTreeLinkOverlay.d.ts +23 -0
- package/ProcessTree/PureProcessTree/hooks/useProcessTreeLinkOverlay.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/mockdata/data.d.ts +235 -0
- package/ProcessTree/PureProcessTree/mockdata/data.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/utils/iconLoader.d.ts +9 -0
- package/ProcessTree/PureProcessTree/utils/iconLoader.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/utils/processTreeLinkOverlayUtils.d.ts +36 -0
- package/ProcessTree/PureProcessTree/utils/processTreeLinkOverlayUtils.d.ts.map +1 -0
- package/ProcessTree/PureProcessTree/utils/processTreeUtils.d.ts +80 -0
- package/ProcessTree/PureProcessTree/utils/processTreeUtils.d.ts.map +1 -0
- package/ProcessTree/config.d.ts +4 -0
- package/ProcessTree/config.d.ts.map +1 -0
- package/ProcessTree/index.d.ts +3 -0
- package/ProcessTree/index.d.ts.map +1 -0
- package/ProcessTree.config.js +192 -0
- package/ProcessTree.config.js.map +7 -0
- package/ProcessTree.js +5058 -0
- package/ProcessTree.js.map +7 -0
- package/Punchcard/Punchcard.d.ts +1 -5
- package/Punchcard/Punchcard.d.ts.map +1 -1
- package/Punchcard/PurePunchcard/Punchcard.d.ts +28 -32
- package/Punchcard/PurePunchcard/Punchcard.d.ts.map +1 -1
- package/Punchcard/PurePunchcard/src/PunchcardAxis.d.ts +7 -12
- package/Punchcard/PurePunchcard/src/PunchcardAxis.d.ts.map +1 -1
- package/Punchcard/PurePunchcard/src/PunchcardBubble.d.ts +14 -19
- package/Punchcard/PurePunchcard/src/PunchcardBubble.d.ts.map +1 -1
- package/Punchcard/PurePunchcard/src/PunchcardChartArea.d.ts +22 -27
- package/Punchcard/PurePunchcard/src/PunchcardChartArea.d.ts.map +1 -1
- package/Punchcard/PurePunchcard/src/PunchcardGridLines.d.ts +3 -8
- package/Punchcard/PurePunchcard/src/PunchcardGridLines.d.ts.map +1 -1
- package/Punchcard/PurePunchcard/src/PunchcardLegend.d.ts +9 -14
- package/Punchcard/PurePunchcard/src/PunchcardLegend.d.ts.map +1 -1
- package/Punchcard/PurePunchcard/src/PunchcardRow.d.ts.map +1 -1
- package/Punchcard.config.js.map +1 -1
- package/Punchcard.js +444 -631
- package/Punchcard.js.map +4 -4
- package/Rectangle.config.js +1 -1
- package/Rectangle.config.js.map +2 -2
- package/Rectangle.js +289 -173
- package/Rectangle.js.map +4 -4
- package/RichText/PureRichText/Editor/EditorPanel.d.ts +20 -0
- package/RichText/PureRichText/Editor/EditorPanel.d.ts.map +1 -0
- package/RichText/PureRichText/Editor/EditorPanelStyles.d.ts +17 -0
- package/RichText/PureRichText/Editor/EditorPanelStyles.d.ts.map +1 -0
- package/RichText/PureRichText/Editor/FontSelector.d.ts +15 -0
- package/RichText/PureRichText/Editor/FontSelector.d.ts.map +1 -0
- package/RichText/PureRichText/Editor/FormatButton.d.ts +23 -0
- package/RichText/PureRichText/Editor/FormatButton.d.ts.map +1 -0
- package/RichText/PureRichText/Editor/editorPanelUtils.d.ts +19 -0
- package/RichText/PureRichText/Editor/editorPanelUtils.d.ts.map +1 -0
- package/RichText/PureRichText/Editor/hooks/useLineSpacing.d.ts +11 -0
- package/RichText/PureRichText/Editor/hooks/useLineSpacing.d.ts.map +1 -0
- package/RichText/PureRichText/Editor/hooks/useLinkHandlers.d.ts +26 -0
- package/RichText/PureRichText/Editor/hooks/useLinkHandlers.d.ts.map +1 -0
- package/RichText/PureRichText/Editor/index.d.ts +9 -0
- package/RichText/PureRichText/Editor/index.d.ts.map +1 -0
- package/RichText/PureRichText/InnerEditor.d.ts +41 -0
- package/RichText/PureRichText/InnerEditor.d.ts.map +1 -0
- package/RichText/PureRichText/PureRichText.d.ts +19 -0
- package/RichText/PureRichText/PureRichText.d.ts.map +1 -0
- package/RichText/PureRichText/PureRichTextContext.d.ts +64 -0
- package/RichText/PureRichText/PureRichTextContext.d.ts.map +1 -0
- package/RichText/PureRichText/RichTextStyles.d.ts +25 -0
- package/RichText/PureRichText/RichTextStyles.d.ts.map +1 -0
- package/RichText/PureRichText/activeInstance.d.ts +23 -0
- package/RichText/PureRichText/activeInstance.d.ts.map +1 -0
- package/RichText/PureRichText/config.d.ts +17 -0
- package/RichText/PureRichText/config.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/index.d.ts +12 -0
- package/RichText/PureRichText/hooks/index.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useContentSave.d.ts +25 -0
- package/RichText/PureRichText/hooks/useContentSave.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useContentSync.d.ts +28 -0
- package/RichText/PureRichText/hooks/useContentSync.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useDashboardKeyboardNav.d.ts +33 -0
- package/RichText/PureRichText/hooks/useDashboardKeyboardNav.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useEditModeEffect.d.ts +10 -0
- package/RichText/PureRichText/hooks/useEditModeEffect.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useEditorSetup.d.ts +36 -0
- package/RichText/PureRichText/hooks/useEditorSetup.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useFakeHighlight.d.ts +33 -0
- package/RichText/PureRichText/hooks/useFakeHighlight.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useFocusHandlers.d.ts +35 -0
- package/RichText/PureRichText/hooks/useFocusHandlers.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useKeyboardShortcuts.d.ts +18 -0
- package/RichText/PureRichText/hooks/useKeyboardShortcuts.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useMouseHandlers.d.ts +24 -0
- package/RichText/PureRichText/hooks/useMouseHandlers.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useRichTextState.d.ts +38 -0
- package/RichText/PureRichText/hooks/useRichTextState.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useStepFontSize.d.ts +17 -0
- package/RichText/PureRichText/hooks/useStepFontSize.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useStepLineSpacing.d.ts +18 -0
- package/RichText/PureRichText/hooks/useStepLineSpacing.d.ts.map +1 -0
- package/RichText/PureRichText/hooks/useTokenMap.d.ts +45 -0
- package/RichText/PureRichText/hooks/useTokenMap.d.ts.map +1 -0
- package/RichText/PureRichText/index.d.ts +16 -0
- package/RichText/PureRichText/index.d.ts.map +1 -0
- package/RichText/PureRichText/renderers/ElementRenderer.d.ts +8 -0
- package/RichText/PureRichText/renderers/ElementRenderer.d.ts.map +1 -0
- package/RichText/PureRichText/renderers/LeafRenderer.d.ts +8 -0
- package/RichText/PureRichText/renderers/LeafRenderer.d.ts.map +1 -0
- package/RichText/PureRichText/types.d.ts +111 -0
- package/RichText/PureRichText/types.d.ts.map +1 -0
- package/RichText/PureRichText/utils/a11yUtils.d.ts +9 -0
- package/RichText/PureRichText/utils/a11yUtils.d.ts.map +1 -0
- package/RichText/PureRichText/utils/fontSize.d.ts +6 -0
- package/RichText/PureRichText/utils/fontSize.d.ts.map +1 -0
- package/RichText/PureRichText/utils/slateUtils.d.ts +99 -0
- package/RichText/PureRichText/utils/slateUtils.d.ts.map +1 -0
- package/RichText/RichText.d.ts +17 -0
- package/RichText/RichText.d.ts.map +1 -0
- package/RichText/config.d.ts +4 -0
- package/RichText/config.d.ts.map +1 -0
- package/RichText/index.d.ts +7 -0
- package/RichText/index.d.ts.map +1 -0
- package/RichText.config.js +268 -0
- package/RichText.config.js.map +7 -0
- package/RichText.js +7674 -0
- package/RichText.js.map +7 -0
- package/Sankey/PureSankey/PureSankey.d.ts.map +1 -1
- package/Sankey/PureSankey/SankeyLink.d.ts.map +1 -1
- package/Sankey/PureSankey/SankeyNode.d.ts +10 -3
- package/Sankey/PureSankey/SankeyNode.d.ts.map +1 -1
- package/Sankey/PureSankey/SankeyTooltip.d.ts.map +1 -1
- package/Sankey/PureSankey/SankeyUtils.d.ts +10 -0
- package/Sankey/PureSankey/SankeyUtils.d.ts.map +1 -1
- package/Sankey.config.js.map +1 -1
- package/Sankey.js +562 -290
- package/Sankey.js.map +4 -4
- package/Scatter/Scatter.d.ts.map +1 -1
- package/Scatter.config.js +81 -24
- package/Scatter.config.js.map +3 -3
- package/Scatter.js +528 -297
- 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 +76 -24
- package/SingleValue.config.js.map +2 -2
- package/SingleValue.js +534 -314
- package/SingleValue.js.map +4 -4
- 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 +76 -24
- package/SingleValueIcon.config.js.map +2 -2
- package/SingleValueIcon.js +512 -287
- package/SingleValueIcon.js.map +4 -4
- 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.d.ts.map +1 -1
- package/SingleValueRadial.config.js +76 -24
- package/SingleValueRadial.config.js.map +2 -2
- package/SingleValueRadial.js +543 -326
- package/SingleValueRadial.js.map +4 -4
- package/TRELLIS.md +48 -0
- package/Table/PureTable.d.ts +1 -0
- package/Table/PureTable.d.ts.map +1 -1
- package/Table/Table.d.ts.map +1 -1
- package/Table/cells/ArrayCell.d.ts.map +1 -1
- package/Table/config.d.ts.map +1 -1
- package/Table/hooks.d.ts.map +1 -1
- package/Table/tableUtils.d.ts +14 -0
- package/Table/tableUtils.d.ts.map +1 -0
- package/Table.config.js +4 -10
- package/Table.config.js.map +2 -2
- package/Table.js +769 -355
- package/Table.js.map +4 -4
- package/Timeline/PureTimeline/src/TimelineYAxis.d.ts.map +1 -1
- package/Timeline/PureTimeline/src/utils/timelineUtils.d.ts +5 -0
- package/Timeline/PureTimeline/src/utils/timelineUtils.d.ts.map +1 -1
- package/Timeline/Timeline.d.ts +2 -0
- package/Timeline/Timeline.d.ts.map +1 -1
- package/Timeline/config.d.ts.map +1 -1
- package/Timeline/mockdata/timelineDataSource.d.ts +34 -0
- package/Timeline/mockdata/timelineDataSource.d.ts.map +1 -1
- package/Timeline.config.js +15 -0
- package/Timeline.config.js.map +2 -2
- package/Timeline.js +348 -186
- package/Timeline.js.map +4 -4
- package/common/Charting.d.ts.map +1 -1
- package/common/Charting.js +50 -28
- package/common/Charting.js.map +2 -2
- package/common/ChartingApi.d.ts +1 -1
- package/common/ChartingApi.d.ts.map +1 -1
- package/common/ChartingApi.js.map +2 -2
- package/common/DocExampleWithVizSandbox.js.map +1 -1
- package/common/OptionsDoc.js.map +1 -1
- package/common/OverviewDoc.js.map +1 -1
- package/common/SplunkVisualization.d.ts +1 -1
- package/common/SplunkVisualization.d.ts.map +1 -1
- package/common/SplunkVisualization.js +6 -4
- package/common/SplunkVisualization.js.map +2 -2
- package/common/StyledSkipLink.d.ts +2 -0
- package/common/StyledSkipLink.d.ts.map +1 -0
- package/common/StyledSkipLink.js +81 -0
- package/common/StyledSkipLink.js.map +7 -0
- package/common/TimeSeriesChartWrapper.d.ts.map +1 -1
- package/common/TimeSeriesChartWrapper.js +228 -107
- package/common/TimeSeriesChartWrapper.js.map +4 -4
- package/common/chartingUtils.d.ts +32 -6
- package/common/chartingUtils.d.ts.map +1 -1
- package/common/chartingUtils.js +166 -39
- package/common/chartingUtils.js.map +4 -4
- package/common/components/TrellisTitle.d.ts.map +1 -1
- package/common/docUtils.js +1 -1
- package/common/docUtils.js.map +2 -2
- package/common/editorConfig/AxesChartDataDisplay.d.ts.map +1 -1
- package/common/editorConfig/AxesChartYGridAndLabels.d.ts.map +1 -1
- package/common/editorConfig/BackgroundColor.d.ts +2 -2
- package/common/editorConfig/TrellisEditors.d.ts +33 -5
- package/common/editorConfig/TrellisEditors.d.ts.map +1 -1
- package/common/hocs/mockdata/trellisData.d.ts +54 -0
- package/common/hocs/mockdata/trellisData.d.ts.map +1 -1
- package/common/hocs/withTrellis.d.ts +9 -0
- package/common/hocs/withTrellis.d.ts.map +1 -1
- package/common/hooks/useSorting.d.ts +2 -2
- package/common/hooks/useSorting.d.ts.map +1 -1
- package/common/shapeUtils.d.ts +1 -1
- package/common/shapeUtils.d.ts.map +1 -1
- package/common/shapeUtils.js.map +2 -2
- package/common/utils/dataUtils.js +2 -1
- package/common/utils/dataUtils.js.map +2 -2
- package/common/utils/focusUtils.d.ts +4 -0
- package/common/utils/focusUtils.d.ts.map +1 -0
- package/common/utils/focusUtils.js +101 -0
- package/common/utils/focusUtils.js.map +7 -0
- package/common/utils/mapUtils.js +2 -6
- package/common/utils/mapUtils.js.map +2 -2
- package/common/utils/singleValueUtils.js +14 -26
- package/common/utils/singleValueUtils.js.map +2 -2
- package/common/utils/trellisUtils.d.ts.map +1 -1
- package/common/utils/trellisUtils.js +76 -70
- package/common/utils/trellisUtils.js.map +2 -2
- package/common/withDashboardViz.d.ts.map +1 -1
- package/common/withDashboardViz.js +276 -151
- package/common/withDashboardViz.js.map +4 -4
- package/package.json +32 -27
- package/LICENSE.md +0 -449
package/Ellipse.js
CHANGED
|
@@ -12,6 +12,7 @@ var __getOwnPropSymbols = Object.getOwnPropertySymbols;
|
|
|
12
12
|
var __getProtoOf = Object.getPrototypeOf;
|
|
13
13
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
14
14
|
var __propIsEnum = Object.prototype.propertyIsEnumerable;
|
|
15
|
+
var __pow = Math.pow;
|
|
15
16
|
var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: true, configurable: true, writable: true, value }) : obj[key] = value;
|
|
16
17
|
var __spreadValues = (a, b) => {
|
|
17
18
|
for (var prop in b || (b = {}))
|
|
@@ -59,6 +60,7 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
|
|
|
59
60
|
mod
|
|
60
61
|
));
|
|
61
62
|
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
63
|
+
var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key !== "symbol" ? key + "" : key, value);
|
|
62
64
|
|
|
63
65
|
// src/Ellipse/index.ts
|
|
64
66
|
var Ellipse_exports = {};
|
|
@@ -461,7 +463,7 @@ var editorConfig = [
|
|
|
461
463
|
presets,
|
|
462
464
|
value: ({ context, options }) => {
|
|
463
465
|
const initialPreset = getInitialPreset(context, options, presets);
|
|
464
|
-
return initialPreset
|
|
466
|
+
return (initialPreset == null ? void 0 : initialPreset.label) || null;
|
|
465
467
|
}
|
|
466
468
|
}
|
|
467
469
|
}
|
|
@@ -673,7 +675,7 @@ var DefaultVizActionHandler = class {
|
|
|
673
675
|
var INITIAL_HEIGHT = 250;
|
|
674
676
|
var SplunkVisualization = class {
|
|
675
677
|
};
|
|
676
|
-
SplunkVisualization
|
|
678
|
+
__publicField(SplunkVisualization, "propTypes", {
|
|
677
679
|
/**
|
|
678
680
|
* display mode
|
|
679
681
|
*/
|
|
@@ -749,11 +751,11 @@ SplunkVisualization.propTypes = {
|
|
|
749
751
|
* A callback to request new data with updated request params
|
|
750
752
|
*/
|
|
751
753
|
onRequestParamsChange: prop_types_exports.func
|
|
752
|
-
};
|
|
754
|
+
});
|
|
753
755
|
/**
|
|
754
756
|
*
|
|
755
757
|
*/
|
|
756
|
-
SplunkVisualization
|
|
758
|
+
__publicField(SplunkVisualization, "defaults", {
|
|
757
759
|
// BaseVisualization in dashboard-visualizations uses 100% for width but 250 for height
|
|
758
760
|
width: "100%",
|
|
759
761
|
height: INITIAL_HEIGHT,
|
|
@@ -768,7 +770,7 @@ SplunkVisualization.defaults = {
|
|
|
768
770
|
onComputedProps: () => ({}),
|
|
769
771
|
loading: false,
|
|
770
772
|
onRequestParamsChange: lodash_exports.noop
|
|
771
|
-
};
|
|
773
|
+
});
|
|
772
774
|
var SplunkVisualization_default = SplunkVisualization;
|
|
773
775
|
|
|
774
776
|
// src/common/interfaces/DataSource.ts
|
|
@@ -822,9 +824,9 @@ var usePaginationParams = ({
|
|
|
822
824
|
meta,
|
|
823
825
|
onRequestParamsChange
|
|
824
826
|
}) => {
|
|
825
|
-
const totalCount = meta
|
|
826
|
-
const offset = requestParams
|
|
827
|
-
const count = requestParams
|
|
827
|
+
const totalCount = (meta == null ? void 0 : meta.totalCount) || 0;
|
|
828
|
+
const offset = (requestParams == null ? void 0 : requestParams.offset) || 0;
|
|
829
|
+
const count = requestParams == null ? void 0 : requestParams.count;
|
|
828
830
|
const totalPages = typeof count === "number" && count > 0 ? Math.ceil(totalCount / count) : 0;
|
|
829
831
|
const current = typeof count === "number" && count > 0 ? Math.floor(offset / count) + 1 : 0;
|
|
830
832
|
const isPaging = totalPages > 1 && typeof onRequestParamsChange === "function";
|
|
@@ -932,7 +934,7 @@ var Cover = styled_components_default.div`
|
|
|
932
934
|
bottom: 0;
|
|
933
935
|
`;
|
|
934
936
|
var Blocker = styled_components_default.div.attrs({
|
|
935
|
-
"data-splunk-visualization-version": "28.
|
|
937
|
+
"data-splunk-visualization-version": "28.6.0 - 92427899a"
|
|
936
938
|
})`
|
|
937
939
|
position: relative;
|
|
938
940
|
width: 100%;
|
|
@@ -1022,7 +1024,7 @@ var withFixedSizeContainer = (Viz) => {
|
|
|
1022
1024
|
FixSizeItem,
|
|
1023
1025
|
{
|
|
1024
1026
|
"data-test": "fix-size-item",
|
|
1025
|
-
"data-splunk-visualization-version": "28.
|
|
1027
|
+
"data-splunk-visualization-version": "28.6.0 - 92427899a",
|
|
1026
1028
|
width,
|
|
1027
1029
|
height,
|
|
1028
1030
|
backgroundColor
|
|
@@ -1563,6 +1565,24 @@ var defaultImport30 = __toESM(require("@splunk/react-icons/Triangle"));
|
|
|
1563
1565
|
__reExport(Triangle_exports, require("@splunk/react-icons/Triangle"));
|
|
1564
1566
|
var Triangle_default = "default" in defaultImport30 ? defaultImport30.default : defaultImport30;
|
|
1565
1567
|
|
|
1568
|
+
// esm-externals:@splunk/visualizations-shared/propUtils
|
|
1569
|
+
var propUtils_exports = {};
|
|
1570
|
+
__export(propUtils_exports, {
|
|
1571
|
+
default: () => propUtils_default
|
|
1572
|
+
});
|
|
1573
|
+
var defaultImport31 = __toESM(require("@splunk/visualizations-shared/propUtils"));
|
|
1574
|
+
__reExport(propUtils_exports, require("@splunk/visualizations-shared/propUtils"));
|
|
1575
|
+
var propUtils_default = "default" in defaultImport31 ? defaultImport31.default : defaultImport31;
|
|
1576
|
+
|
|
1577
|
+
// esm-externals:@splunk/visualizations-shared/simpleXMLOptions
|
|
1578
|
+
var simpleXMLOptions_exports = {};
|
|
1579
|
+
__export(simpleXMLOptions_exports, {
|
|
1580
|
+
default: () => simpleXMLOptions_default
|
|
1581
|
+
});
|
|
1582
|
+
var defaultImport32 = __toESM(require("@splunk/visualizations-shared/simpleXMLOptions"));
|
|
1583
|
+
__reExport(simpleXMLOptions_exports, require("@splunk/visualizations-shared/simpleXMLOptions"));
|
|
1584
|
+
var simpleXMLOptions_default = "default" in defaultImport32 ? defaultImport32.default : defaultImport32;
|
|
1585
|
+
|
|
1566
1586
|
// src/common/chartingUtils.ts
|
|
1567
1587
|
var DEFAULT_LINE_WIDTH = 2;
|
|
1568
1588
|
var getAnnotationsForCanvas = ({
|
|
@@ -1600,9 +1620,9 @@ var shouldEnableSearchZoom = (eventHandlers = [], xField = "") => {
|
|
|
1600
1620
|
const xAxisIsTime = xField === "_time";
|
|
1601
1621
|
return !!rangeSelectEventHandler && xAxisIsTime;
|
|
1602
1622
|
};
|
|
1603
|
-
var canvasSupportedTimeSeriesCharts = ["splunk.line"];
|
|
1623
|
+
var canvasSupportedTimeSeriesCharts = ["splunk.line", "splunk.area"];
|
|
1604
1624
|
var isTimeSeriesCanvasRenderSupported = (vizConfigKey) => {
|
|
1605
|
-
return canvasSupportedTimeSeriesCharts.
|
|
1625
|
+
return canvasSupportedTimeSeriesCharts.includes(vizConfigKey);
|
|
1606
1626
|
};
|
|
1607
1627
|
var filterChartDataFromInternalFields = (chartData) => {
|
|
1608
1628
|
const { fields, columns } = chartData;
|
|
@@ -1757,46 +1777,66 @@ var getY2ScaleConfig = (label, axisAbbreviation, axisScale, roundAxisLabelsToInt
|
|
|
1757
1777
|
}
|
|
1758
1778
|
return y2Config;
|
|
1759
1779
|
};
|
|
1760
|
-
var
|
|
1780
|
+
var getSeriesType = (isOverlay, isAreaChart, isStacked) => {
|
|
1781
|
+
if (isOverlay) return "line";
|
|
1782
|
+
if (!isAreaChart) return void 0;
|
|
1783
|
+
return isStacked ? "stacked-area" : "area";
|
|
1784
|
+
};
|
|
1785
|
+
var getY2Scale = (field, y2fields, overlayFields) => {
|
|
1786
|
+
const assignToY2 = (y2fields == null ? void 0 : y2fields.length) > 0 && y2fields.includes(field) || !(y2fields == null ? void 0 : y2fields.length) && (overlayFields == null ? void 0 : overlayFields.includes(field));
|
|
1787
|
+
return assignToY2 ? "y2" : "y";
|
|
1788
|
+
};
|
|
1789
|
+
var getSeriesOverrides = (opts) => {
|
|
1790
|
+
var _a;
|
|
1791
|
+
const {
|
|
1792
|
+
yfields,
|
|
1793
|
+
y2fields,
|
|
1794
|
+
lineWidth,
|
|
1795
|
+
overlayFields,
|
|
1796
|
+
y2Enabled,
|
|
1797
|
+
nullValueMode,
|
|
1798
|
+
markerDisplay,
|
|
1799
|
+
lineDashStyle,
|
|
1800
|
+
lineDashStylesByField,
|
|
1801
|
+
stepPosition,
|
|
1802
|
+
stepPositionsByField,
|
|
1803
|
+
type,
|
|
1804
|
+
stackMode,
|
|
1805
|
+
showLines
|
|
1806
|
+
} = opts;
|
|
1761
1807
|
const seriesConfig = {};
|
|
1762
1808
|
let spanGaps;
|
|
1763
|
-
let replaceNullsWithZero;
|
|
1764
1809
|
if (nullValueMode === "gaps") {
|
|
1765
1810
|
spanGaps = false;
|
|
1766
|
-
} else if (nullValueMode
|
|
1811
|
+
} else if (nullValueMode != null) {
|
|
1767
1812
|
spanGaps = true;
|
|
1768
|
-
|
|
1769
|
-
|
|
1770
|
-
}
|
|
1813
|
+
} else {
|
|
1814
|
+
spanGaps = void 0;
|
|
1771
1815
|
}
|
|
1772
|
-
|
|
1816
|
+
const replaceNullsWithZero = nullValueMode === "zero" ? true : void 0;
|
|
1817
|
+
const isAreaChart = type === "area";
|
|
1818
|
+
const isStacked = isAreaChart && (stackMode === "stacked" || stackMode === "stacked100");
|
|
1819
|
+
const areaFields = isAreaChart ? yfields.filter((f) => !(overlayFields == null ? void 0 : overlayFields.includes(f))) : yfields;
|
|
1820
|
+
const overlayFieldsInOrder = (_a = overlayFields == null ? void 0 : overlayFields.filter((f) => yfields.includes(f))) != null ? _a : [];
|
|
1821
|
+
const orderedFields = isAreaChart ? [...areaFields, ...overlayFieldsInOrder] : yfields;
|
|
1822
|
+
orderedFields.forEach((field) => {
|
|
1823
|
+
var _a2;
|
|
1824
|
+
const isOverlay = (_a2 = overlayFields == null ? void 0 : overlayFields.includes(field)) != null ? _a2 : false;
|
|
1825
|
+
const isPercent = isAreaChart && stackMode === "stacked100" && !isOverlay;
|
|
1826
|
+
const shouldHideAreaOutline = isAreaChart && showLines === false && !isOverlay;
|
|
1773
1827
|
seriesConfig[field] = {
|
|
1774
|
-
overrides: {
|
|
1828
|
+
overrides: __spreadValues({
|
|
1829
|
+
width: shouldHideAreaOutline ? 0 : lineWidth != null ? lineWidth : DEFAULT_LINE_WIDTH
|
|
1830
|
+
}, isPercent ? { stacking: { mode: "percent", group: "A" } } : {})
|
|
1775
1831
|
};
|
|
1776
|
-
|
|
1777
|
-
|
|
1778
|
-
|
|
1779
|
-
if (y2Enabled)
|
|
1780
|
-
|
|
1781
|
-
|
|
1782
|
-
|
|
1783
|
-
|
|
1784
|
-
);
|
|
1785
|
-
if (shouldAssignToY2) {
|
|
1786
|
-
seriesConfig[field].overrides.scale = "y2";
|
|
1787
|
-
} else {
|
|
1788
|
-
seriesConfig[field].overrides.scale = "y";
|
|
1789
|
-
}
|
|
1790
|
-
}
|
|
1791
|
-
if (overlayFields == null ? void 0 : overlayFields.includes(field)) {
|
|
1792
|
-
seriesConfig[field].type = "line";
|
|
1793
|
-
}
|
|
1794
|
-
if (markerDisplay !== void 0) {
|
|
1795
|
-
seriesConfig[field].markerDisplay = markerDisplay;
|
|
1796
|
-
}
|
|
1797
|
-
const fieldDashStyle = (lineDashStylesByField == null ? void 0 : lineDashStylesByField[field]) || lineDashStyle;
|
|
1798
|
-
if (fieldDashStyle) {
|
|
1799
|
-
seriesConfig[field].lineDashStyle = fieldDashStyle;
|
|
1832
|
+
const seriesType = getSeriesType(isOverlay, isAreaChart, isStacked);
|
|
1833
|
+
if (seriesType !== void 0) seriesConfig[field].type = seriesType;
|
|
1834
|
+
if (spanGaps !== void 0) seriesConfig[field].overrides.spanGaps = spanGaps;
|
|
1835
|
+
if (y2Enabled) seriesConfig[field].overrides.scale = getY2Scale(field, y2fields, overlayFields);
|
|
1836
|
+
if (markerDisplay !== void 0) seriesConfig[field].markerDisplay = markerDisplay;
|
|
1837
|
+
if (!isAreaChart || isOverlay) {
|
|
1838
|
+
const fieldDashStyle = (lineDashStylesByField == null ? void 0 : lineDashStylesByField[field]) || lineDashStyle;
|
|
1839
|
+
if (fieldDashStyle) seriesConfig[field].lineDashStyle = fieldDashStyle;
|
|
1800
1840
|
}
|
|
1801
1841
|
const hasFieldStepPosition = Object.hasOwn(stepPositionsByField || {}, field);
|
|
1802
1842
|
const fieldStepPosition = hasFieldStepPosition ? stepPositionsByField == null ? void 0 : stepPositionsByField[field] : stepPosition;
|
|
@@ -1867,8 +1907,27 @@ var TrellisTitleDiv = styled_components_default.div`
|
|
|
1867
1907
|
background-color: ${(props) => props.backgroundColor};
|
|
1868
1908
|
box-shadow: 0 1px ${(props) => props.backgroundColor}; // this is added to avoid a 1px gap between title and viz divs that showed up intermittently because of pixel rounding error in chrome.
|
|
1869
1909
|
`;
|
|
1910
|
+
var formatTrellisKey = (value) => {
|
|
1911
|
+
if (value === null || value === void 0) {
|
|
1912
|
+
return "";
|
|
1913
|
+
}
|
|
1914
|
+
if (typeof value === "string") {
|
|
1915
|
+
return value;
|
|
1916
|
+
}
|
|
1917
|
+
if (typeof value === "number" || typeof value === "boolean") {
|
|
1918
|
+
return value.toString();
|
|
1919
|
+
}
|
|
1920
|
+
if (typeof value === "symbol") {
|
|
1921
|
+
return value.toString();
|
|
1922
|
+
}
|
|
1923
|
+
try {
|
|
1924
|
+
return JSON.stringify(value);
|
|
1925
|
+
} catch (e) {
|
|
1926
|
+
return typeof value === "bigint" ? value.toString() : "";
|
|
1927
|
+
}
|
|
1928
|
+
};
|
|
1870
1929
|
var TrellisTitle = (props) => {
|
|
1871
|
-
const titleText =
|
|
1930
|
+
const titleText = formatTrellisKey(props.trellisKey);
|
|
1872
1931
|
return /* @__PURE__ */ react_exports.createElement(
|
|
1873
1932
|
TrellisTitleDiv,
|
|
1874
1933
|
{
|
|
@@ -2004,6 +2063,38 @@ var parseArrayOption = (value) => {
|
|
|
2004
2063
|
}
|
|
2005
2064
|
return void 0;
|
|
2006
2065
|
};
|
|
2066
|
+
var getAreaOpacityForCanvas = (areaOpacity) => (
|
|
2067
|
+
// Preserve legacy visualizations behavior where area opacity is squared to match charting output.
|
|
2068
|
+
areaOpacity !== void 0 && areaOpacity !== null ? __pow(areaOpacity, 2) : areaOpacity
|
|
2069
|
+
);
|
|
2070
|
+
var parseTickIntervalOption = (simpleXMLValue, canvasValue) => {
|
|
2071
|
+
if (simpleXMLValue) return Number(simpleXMLValue);
|
|
2072
|
+
if (canvasValue) return Number(canvasValue);
|
|
2073
|
+
return void 0;
|
|
2074
|
+
};
|
|
2075
|
+
var getYAxisTitles = ({
|
|
2076
|
+
y2Enabled,
|
|
2077
|
+
yFields,
|
|
2078
|
+
y2Fields,
|
|
2079
|
+
overlayFields,
|
|
2080
|
+
yAxisTitleText,
|
|
2081
|
+
yAxisTitleVisibility,
|
|
2082
|
+
y2AxisTitleText,
|
|
2083
|
+
y2AxisTitleVisibility,
|
|
2084
|
+
containerHeight
|
|
2085
|
+
}) => {
|
|
2086
|
+
const yFieldsForTitle = y2Enabled ? yFields.filter((field) => !y2Fields.includes(field)) : yFields;
|
|
2087
|
+
const fieldsForY2Axis = y2Fields.length > 0 ? y2Fields : overlayFields;
|
|
2088
|
+
const yAxisTitle = ellipsisAxisTitle(
|
|
2089
|
+
getComputedAxisTitles(yAxisTitleText, yFieldsForTitle, yAxisTitleVisibility),
|
|
2090
|
+
containerHeight
|
|
2091
|
+
);
|
|
2092
|
+
const y2AxisTitle = ellipsisAxisTitle(
|
|
2093
|
+
getComputedAxisTitles(y2AxisTitleText, fieldsForY2Axis, y2AxisTitleVisibility),
|
|
2094
|
+
containerHeight
|
|
2095
|
+
);
|
|
2096
|
+
return { yAxisTitle, y2AxisTitle };
|
|
2097
|
+
};
|
|
2007
2098
|
var TimeSeriesChartWrapper = (props) => {
|
|
2008
2099
|
var _b, _c, _d;
|
|
2009
2100
|
const _a = props, {
|
|
@@ -2093,6 +2184,8 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2093
2184
|
"chart.overlayFields": overlayFieldsStr,
|
|
2094
2185
|
"chart.nullValueMode": nullValueMode,
|
|
2095
2186
|
"chart.showDataLabels": showDataLabels,
|
|
2187
|
+
"chart.showLines": showLines,
|
|
2188
|
+
"chart.stackMode": stackMode,
|
|
2096
2189
|
lineWidth,
|
|
2097
2190
|
lineDashStyle,
|
|
2098
2191
|
fieldDashStyles: lineDashStylesByFieldStr,
|
|
@@ -2121,7 +2214,10 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2121
2214
|
yAxisMinorTickSize,
|
|
2122
2215
|
y2AxisMinorTickSize,
|
|
2123
2216
|
showYAxisWithZero: showYAxisWithZeroFromOptions,
|
|
2124
|
-
showY2AxisWithZero: showY2AxisWithZeroFromOptions
|
|
2217
|
+
showY2AxisWithZero: showY2AxisWithZeroFromOptions,
|
|
2218
|
+
// area only props
|
|
2219
|
+
areaFillOpacity: areaOpacity,
|
|
2220
|
+
chart: chartType
|
|
2125
2221
|
} = options;
|
|
2126
2222
|
const dataValuesDisplay = showDataLabels === "none" ? "off" : showDataLabels;
|
|
2127
2223
|
const showYAxisWithZero = showYAxisWithZeroFromProps != null ? showYAxisWithZeroFromProps : showYAxisWithZeroFromOptions;
|
|
@@ -2138,13 +2234,11 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2138
2234
|
const yAxisMax = parseAxisValue(yAxisMaxRaw);
|
|
2139
2235
|
const y2AxisMin = parseAxisValue(y2AxisMinRaw);
|
|
2140
2236
|
const y2AxisMax = parseAxisValue(y2AxisMaxRaw);
|
|
2141
|
-
const
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
const yAxisMajorTickIntervalNum = parseTickInterval(yAxisMajorUnitFromSimpleXML, yAxisMajorTickInterval);
|
|
2147
|
-
const y2AxisMajorTickIntervalNum = parseTickInterval(
|
|
2237
|
+
const yAxisMajorTickIntervalNum = parseTickIntervalOption(
|
|
2238
|
+
yAxisMajorUnitFromSimpleXML,
|
|
2239
|
+
yAxisMajorTickInterval
|
|
2240
|
+
);
|
|
2241
|
+
const y2AxisMajorTickIntervalNum = parseTickIntervalOption(
|
|
2148
2242
|
y2AxisMajorUnitFromSimpleXML,
|
|
2149
2243
|
y2AxisMajorTickInterval
|
|
2150
2244
|
);
|
|
@@ -2153,6 +2247,7 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2153
2247
|
const y2AxisMajorTickSizeNum = y2AxisMajorTickSize != null ? Number(y2AxisMajorTickSize) : void 0;
|
|
2154
2248
|
const yAxisMinorTickSizeNum = yAxisMinorTickSize != null ? Number(yAxisMinorTickSize) : void 0;
|
|
2155
2249
|
const y2AxisMinorTickSizeNum = y2AxisMinorTickSize != null ? Number(y2AxisMinorTickSize) : void 0;
|
|
2250
|
+
const areaOpacityForCanvas = getAreaOpacityForCanvas(areaOpacity);
|
|
2156
2251
|
const seriesColors = seriesColorsStr ? JSON.parse(seriesColorsStr) : void 0;
|
|
2157
2252
|
const seriesColorsByField = fieldColors ? JSON.parse(fieldColors) : void 0;
|
|
2158
2253
|
const lineDashStylesByField = lineDashStylesByFieldStr ? JSON.parse(lineDashStylesByFieldStr) : void 0;
|
|
@@ -2183,26 +2278,40 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2183
2278
|
);
|
|
2184
2279
|
let xAxisTitle = getComputedAxisTitles(xAxisTitleText, [xField], xAxisTitleVisibility);
|
|
2185
2280
|
xAxisTitle = ellipsisAxisTitle(xAxisTitle, containerWidth);
|
|
2186
|
-
const
|
|
2187
|
-
|
|
2188
|
-
|
|
2189
|
-
|
|
2190
|
-
|
|
2191
|
-
|
|
2281
|
+
const { yAxisTitle, y2AxisTitle } = getYAxisTitles({
|
|
2282
|
+
y2Enabled,
|
|
2283
|
+
yFields,
|
|
2284
|
+
y2Fields,
|
|
2285
|
+
overlayFields,
|
|
2286
|
+
yAxisTitleText,
|
|
2287
|
+
yAxisTitleVisibility,
|
|
2288
|
+
y2AxisTitleText,
|
|
2289
|
+
y2AxisTitleVisibility,
|
|
2290
|
+
containerHeight
|
|
2291
|
+
});
|
|
2192
2292
|
const xScaleConfig = (0, react_exports.useMemo)(
|
|
2193
2293
|
() => getXScaleConfig(xAxisTitle, xAxisLabelVisibility, xAxisLabelRotation),
|
|
2194
2294
|
[xAxisTitle, xAxisLabelVisibility, xAxisLabelRotation]
|
|
2195
2295
|
);
|
|
2296
|
+
const isStacked100 = stackMode === "stacked100";
|
|
2196
2297
|
const yScaleConfig = (0, react_exports.useMemo)(
|
|
2197
|
-
() =>
|
|
2198
|
-
|
|
2199
|
-
|
|
2200
|
-
|
|
2201
|
-
|
|
2202
|
-
|
|
2203
|
-
|
|
2204
|
-
|
|
2205
|
-
|
|
2298
|
+
() => {
|
|
2299
|
+
const config2 = getYScaleConfig(
|
|
2300
|
+
yAxisTitle,
|
|
2301
|
+
yAxisAbbreviation,
|
|
2302
|
+
yAxisScale,
|
|
2303
|
+
yAxisLabelVisibility,
|
|
2304
|
+
yAxisMin,
|
|
2305
|
+
yAxisMax
|
|
2306
|
+
);
|
|
2307
|
+
if (isStacked100) {
|
|
2308
|
+
config2.y.tickFmt = (v) => `${Math.round(v * 100)}%`;
|
|
2309
|
+
config2.y.range = () => [0, 1];
|
|
2310
|
+
}
|
|
2311
|
+
return config2;
|
|
2312
|
+
},
|
|
2313
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
2314
|
+
[yAxisTitle, yAxisAbbreviation, yAxisScale, yAxisLabelVisibility, yAxisMin, yAxisMax, isStacked100]
|
|
2206
2315
|
);
|
|
2207
2316
|
const y2ScaleConfig = (0, react_exports.useMemo)(() => {
|
|
2208
2317
|
if (y2Enabled) {
|
|
@@ -2234,10 +2343,11 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2234
2343
|
];
|
|
2235
2344
|
chartData.fields = filteredChartData.fields;
|
|
2236
2345
|
chartData.columns = seriesDataFormatted;
|
|
2346
|
+
const normalizedStackMode = stackMode === "stacked" || stackMode === "stacked100" ? stackMode : "auto";
|
|
2237
2347
|
const seriesOverrides = (0, react_exports.useMemo)(
|
|
2238
|
-
() => getSeriesOverrides(
|
|
2239
|
-
yFields,
|
|
2240
|
-
y2Fields,
|
|
2348
|
+
() => getSeriesOverrides({
|
|
2349
|
+
yfields: yFields,
|
|
2350
|
+
y2fields: y2Fields,
|
|
2241
2351
|
lineWidth,
|
|
2242
2352
|
overlayFields,
|
|
2243
2353
|
y2Enabled,
|
|
@@ -2246,8 +2356,11 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2246
2356
|
lineDashStyle,
|
|
2247
2357
|
lineDashStylesByField,
|
|
2248
2358
|
stepPosition,
|
|
2249
|
-
stepPositionsByField
|
|
2250
|
-
|
|
2359
|
+
stepPositionsByField,
|
|
2360
|
+
type: chartType,
|
|
2361
|
+
stackMode: normalizedStackMode,
|
|
2362
|
+
showLines
|
|
2363
|
+
}),
|
|
2251
2364
|
[
|
|
2252
2365
|
yFields,
|
|
2253
2366
|
y2Fields,
|
|
@@ -2259,7 +2372,10 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2259
2372
|
lineDashStyle,
|
|
2260
2373
|
lineDashStylesByField,
|
|
2261
2374
|
stepPosition,
|
|
2262
|
-
stepPositionsByField
|
|
2375
|
+
stepPositionsByField,
|
|
2376
|
+
chartType,
|
|
2377
|
+
normalizedStackMode,
|
|
2378
|
+
showLines
|
|
2263
2379
|
]
|
|
2264
2380
|
);
|
|
2265
2381
|
const chartingEventAnnotations = (0, react_exports.useMemo)(
|
|
@@ -2327,50 +2443,54 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2327
2443
|
react_exports.useEffect(() => {
|
|
2328
2444
|
additionalTooltipValuesRef.current = additionalTooltipValues;
|
|
2329
2445
|
}, [additionalTooltipValues]);
|
|
2446
|
+
const handleCrosshairMouseout = react_exports.useCallback(() => {
|
|
2447
|
+
if (onPointMouseOut && lastPayloadRef.current) {
|
|
2448
|
+
onPointMouseOut({
|
|
2449
|
+
type: "point.mouseout",
|
|
2450
|
+
originalEvent: lastOriginalEventRef.current,
|
|
2451
|
+
payload: lastPayloadRef.current
|
|
2452
|
+
});
|
|
2453
|
+
}
|
|
2454
|
+
previousMouseoverPayloadRef.current = null;
|
|
2455
|
+
}, [onPointMouseOut]);
|
|
2330
2456
|
const handleChartCrosshairChange = react_exports.useCallback(
|
|
2331
2457
|
(event) => {
|
|
2332
|
-
if (onPointMouseOver
|
|
2333
|
-
|
|
2334
|
-
|
|
2335
|
-
|
|
2336
|
-
|
|
2337
|
-
|
|
2338
|
-
|
|
2339
|
-
|
|
2340
|
-
|
|
2341
|
-
|
|
2342
|
-
|
|
2343
|
-
|
|
2344
|
-
|
|
2345
|
-
|
|
2458
|
+
if (!onPointMouseOver && !onPointMouseOut) {
|
|
2459
|
+
return;
|
|
2460
|
+
}
|
|
2461
|
+
if (!event) {
|
|
2462
|
+
handleCrosshairMouseout();
|
|
2463
|
+
return;
|
|
2464
|
+
}
|
|
2465
|
+
const payload = __spreadProps(__spreadValues({}, (0, lodash_exports.pick)(event, "value", "seriesKey", "time", "index", "seriesIndex")), {
|
|
2466
|
+
name: event.seriesKey
|
|
2467
|
+
});
|
|
2468
|
+
delete payload.seriesKey;
|
|
2469
|
+
if (event.rowContext) {
|
|
2470
|
+
Object.assign(
|
|
2471
|
+
payload,
|
|
2472
|
+
Object.keys(event.rowContext).reduce((acc, fieldName) => {
|
|
2473
|
+
acc[`row.${fieldName}.value`] = event.rowContext[fieldName];
|
|
2474
|
+
return acc;
|
|
2475
|
+
}, {})
|
|
2476
|
+
);
|
|
2477
|
+
}
|
|
2478
|
+
const updatedPayload = appendTrellisToPayload(payload, trellisKey, trellisSplitBy);
|
|
2479
|
+
if (!hasMouseoverPayloadChanged(updatedPayload, previousMouseoverPayloadRef.current)) {
|
|
2480
|
+
return;
|
|
2481
|
+
}
|
|
2482
|
+
lastPayloadRef.current = updatedPayload;
|
|
2483
|
+
lastOriginalEventRef.current = event;
|
|
2484
|
+
previousMouseoverPayloadRef.current = __spreadValues({}, updatedPayload);
|
|
2485
|
+
if (onPointMouseOver) {
|
|
2486
|
+
onPointMouseOver({
|
|
2487
|
+
type: "point.mouseover",
|
|
2488
|
+
originalEvent: event,
|
|
2489
|
+
payload: updatedPayload
|
|
2346
2490
|
});
|
|
2347
|
-
delete payload.seriesKey;
|
|
2348
|
-
if (event.rowContext) {
|
|
2349
|
-
Object.assign(
|
|
2350
|
-
payload,
|
|
2351
|
-
Object.keys(event.rowContext).reduce((acc, fieldName) => {
|
|
2352
|
-
acc[`row.${fieldName}.value`] = event.rowContext[fieldName];
|
|
2353
|
-
return acc;
|
|
2354
|
-
}, {})
|
|
2355
|
-
);
|
|
2356
|
-
}
|
|
2357
|
-
const updatedPayload = appendTrellisToPayload(payload, trellisKey, trellisSplitBy);
|
|
2358
|
-
if (!hasMouseoverPayloadChanged(updatedPayload, previousMouseoverPayloadRef.current)) {
|
|
2359
|
-
return;
|
|
2360
|
-
}
|
|
2361
|
-
lastPayloadRef.current = updatedPayload;
|
|
2362
|
-
lastOriginalEventRef.current = event;
|
|
2363
|
-
previousMouseoverPayloadRef.current = __spreadValues({}, updatedPayload);
|
|
2364
|
-
if (onPointMouseOver) {
|
|
2365
|
-
onPointMouseOver({
|
|
2366
|
-
type: "point.mouseover",
|
|
2367
|
-
originalEvent: event,
|
|
2368
|
-
payload: updatedPayload
|
|
2369
|
-
});
|
|
2370
|
-
}
|
|
2371
2491
|
}
|
|
2372
2492
|
},
|
|
2373
|
-
[onPointMouseOver, onPointMouseOut, trellisKey, trellisSplitBy]
|
|
2493
|
+
[onPointMouseOver, onPointMouseOut, trellisKey, trellisSplitBy, handleCrosshairMouseout]
|
|
2374
2494
|
);
|
|
2375
2495
|
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}`;
|
|
2376
2496
|
const memoizedChart = (0, react_exports.useMemo)(() => {
|
|
@@ -2425,7 +2545,8 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2425
2545
|
showXAxisLine,
|
|
2426
2546
|
showYAxisLine,
|
|
2427
2547
|
showY2AxisLine,
|
|
2428
|
-
xAxisMaxLabelParts
|
|
2548
|
+
xAxisMaxLabelParts,
|
|
2549
|
+
areaOpacity: areaOpacityForCanvas
|
|
2429
2550
|
}
|
|
2430
2551
|
));
|
|
2431
2552
|
}, [
|
|
@@ -2477,7 +2598,8 @@ var TimeSeriesChartWrapper = (props) => {
|
|
|
2477
2598
|
showYAxisLine,
|
|
2478
2599
|
showY2AxisLine,
|
|
2479
2600
|
legendMode,
|
|
2480
|
-
xAxisMaxLabelParts
|
|
2601
|
+
xAxisMaxLabelParts,
|
|
2602
|
+
areaOpacityForCanvas
|
|
2481
2603
|
]);
|
|
2482
2604
|
const memoizedVisualization = (0, react_exports.useMemo)(() => {
|
|
2483
2605
|
return /* @__PURE__ */ react_exports.createElement(VizStyleWrapper_default, { backgroundColor: bgColor }, memoizedChart);
|
|
@@ -2505,6 +2627,37 @@ var TimeSeriesChartWrapper_default = TimeSeriesChartWrapper;
|
|
|
2505
2627
|
|
|
2506
2628
|
// src/common/withDashboardViz.tsx
|
|
2507
2629
|
var SanitizedTimeSeriesChartWrapper = (0, SanitizeProps_exports.withSanitizedProps)(TimeSeriesChartWrapper_default);
|
|
2630
|
+
var buildEventCallbackProps = (supportedEvents, evaluatedOptionsToUse, onEventTrigger) => {
|
|
2631
|
+
const result = {};
|
|
2632
|
+
Object.keys(supportedEvents).forEach((eventName) => {
|
|
2633
|
+
const { parentKeys, payloadKeys } = supportedEvents[eventName];
|
|
2634
|
+
const eventCallbackPropName = (0, lodash_exports.camelCase)(`on.${eventName}`);
|
|
2635
|
+
let payload = {};
|
|
2636
|
+
if (Array.isArray(payloadKeys) && payloadKeys.length) {
|
|
2637
|
+
payloadKeys.forEach((p) => {
|
|
2638
|
+
payload[p] = evaluatedOptionsToUse[p];
|
|
2639
|
+
});
|
|
2640
|
+
}
|
|
2641
|
+
result[eventCallbackPropName] = (ev) => {
|
|
2642
|
+
if (ev == null ? void 0 : ev.payload) {
|
|
2643
|
+
payload = __spreadValues({}, ev.payload);
|
|
2644
|
+
}
|
|
2645
|
+
return onEventTrigger({
|
|
2646
|
+
originalEvent: ev,
|
|
2647
|
+
payload,
|
|
2648
|
+
type: eventName
|
|
2649
|
+
});
|
|
2650
|
+
};
|
|
2651
|
+
if (parentKeys) {
|
|
2652
|
+
for (let i = parentKeys.length - 1; i >= 0; i -= 1) {
|
|
2653
|
+
const newObject = {};
|
|
2654
|
+
newObject[parentKeys[i]] = result[eventCallbackPropName];
|
|
2655
|
+
result[eventCallbackPropName] = newObject;
|
|
2656
|
+
}
|
|
2657
|
+
}
|
|
2658
|
+
});
|
|
2659
|
+
return result;
|
|
2660
|
+
};
|
|
2508
2661
|
var withDashboardViz = (opts) => {
|
|
2509
2662
|
const {
|
|
2510
2663
|
ReactViz,
|
|
@@ -2562,9 +2715,7 @@ var withDashboardViz = (opts) => {
|
|
|
2562
2715
|
const isDownsamplingEnabledByFeatureFlag = Boolean(
|
|
2563
2716
|
featureFlagContext == null ? void 0 : featureFlagContext.visualizations_enableDownsampling
|
|
2564
2717
|
);
|
|
2565
|
-
const isTrellisFeatureFlagOn = Boolean(
|
|
2566
|
-
featureFlagContext && featureFlagContext.visualizations_enableTrellis
|
|
2567
|
-
);
|
|
2718
|
+
const isTrellisFeatureFlagOn = Boolean(featureFlagContext == null ? void 0 : featureFlagContext.visualizations_enableTrellis);
|
|
2568
2719
|
const isTrellisOn = isTrellisFeatureFlagOn && ((_a = vizConfig == null ? void 0 : vizConfig.supports) == null ? void 0 : _a.includes("trellis" /* TRELLIS */)) && (options == null ? void 0 : options.splitByLayout) === "trellis" /* TRELLIS */;
|
|
2569
2720
|
const isAcceleratedRenderFeatureFlagOn = Boolean(
|
|
2570
2721
|
featureFlagContext == null ? void 0 : featureFlagContext.visualizations_enableAcceleratedRender
|
|
@@ -2729,38 +2880,12 @@ var withDashboardViz = (opts) => {
|
|
|
2729
2880
|
}
|
|
2730
2881
|
);
|
|
2731
2882
|
}
|
|
2732
|
-
const eventCallbackProps = {};
|
|
2733
|
-
|
|
2734
|
-
|
|
2735
|
-
|
|
2736
|
-
|
|
2737
|
-
|
|
2738
|
-
let payload = {};
|
|
2739
|
-
if (Array.isArray(payloadKeys) && payloadKeys.length) {
|
|
2740
|
-
payloadKeys.forEach((p) => {
|
|
2741
|
-
payload[p] = evaluatedOptionsToUse[p];
|
|
2742
|
-
});
|
|
2743
|
-
}
|
|
2744
|
-
eventCallbackProps[eventCallbackPropName] = (ev) => {
|
|
2745
|
-
if (ev == null ? void 0 : ev.payload) {
|
|
2746
|
-
payload = __spreadValues({}, ev.payload);
|
|
2747
|
-
}
|
|
2748
|
-
return onEventTrigger({
|
|
2749
|
-
originalEvent: ev,
|
|
2750
|
-
payload,
|
|
2751
|
-
type: eventName
|
|
2752
|
-
});
|
|
2753
|
-
};
|
|
2754
|
-
if (parentKeys) {
|
|
2755
|
-
for (let i = parentKeys.length - 1; i >= 0; i -= 1) {
|
|
2756
|
-
const newObject = {};
|
|
2757
|
-
newObject[parentKeys[i]] = eventCallbackProps[eventCallbackPropName];
|
|
2758
|
-
eventCallbackProps[eventCallbackPropName] = newObject;
|
|
2759
|
-
}
|
|
2760
|
-
}
|
|
2761
|
-
});
|
|
2762
|
-
}
|
|
2763
|
-
const computedVizProps = computeVizProps2(__spreadProps(__spreadValues(__spreadValues(__spreadValues({}, props), evaluatedOptionsToUse), eventCallbackProps), {
|
|
2883
|
+
const eventCallbackProps = hasEventHandlers && mode === "view" && vizConfig.supports.includes("events" /* EVENTS */) ? buildEventCallbackProps(vizConfig.events, evaluatedOptionsToUse, onEventTrigger) : {};
|
|
2884
|
+
const computedVizProps = computeVizProps2(__spreadProps(__spreadValues(__spreadProps(__spreadValues(__spreadValues({}, props), evaluatedOptionsToUse), {
|
|
2885
|
+
// Align option transformation with the actual renderer selected below.
|
|
2886
|
+
// This prevents canvas-only option preservation from leaking into Highcharts mode.
|
|
2887
|
+
isAcceleratedRenderOn
|
|
2888
|
+
}), eventCallbackProps), {
|
|
2764
2889
|
themeFunc
|
|
2765
2890
|
}));
|
|
2766
2891
|
if (useAsyncEvaluatedOptions && Object.keys(evaluatedOptionsToUse).length === 0) {
|
|
@@ -2789,23 +2914,14 @@ var withDashboardViz = (opts) => {
|
|
|
2789
2914
|
};
|
|
2790
2915
|
var withDashboardViz_default = withDashboardViz;
|
|
2791
2916
|
|
|
2792
|
-
// esm-externals:@splunk/visualizations-shared/propUtils
|
|
2793
|
-
var propUtils_exports = {};
|
|
2794
|
-
__export(propUtils_exports, {
|
|
2795
|
-
default: () => propUtils_default
|
|
2796
|
-
});
|
|
2797
|
-
var defaultImport31 = __toESM(require("@splunk/visualizations-shared/propUtils"));
|
|
2798
|
-
__reExport(propUtils_exports, require("@splunk/visualizations-shared/propUtils"));
|
|
2799
|
-
var propUtils_default = "default" in defaultImport31 ? defaultImport31.default : defaultImport31;
|
|
2800
|
-
|
|
2801
2917
|
// esm-externals:@splunk/react-ui/ScreenReaderContent
|
|
2802
2918
|
var ScreenReaderContent_exports = {};
|
|
2803
2919
|
__export(ScreenReaderContent_exports, {
|
|
2804
2920
|
default: () => ScreenReaderContent_default
|
|
2805
2921
|
});
|
|
2806
|
-
var
|
|
2922
|
+
var defaultImport33 = __toESM(require("@splunk/react-ui/ScreenReaderContent"));
|
|
2807
2923
|
__reExport(ScreenReaderContent_exports, require("@splunk/react-ui/ScreenReaderContent"));
|
|
2808
|
-
var ScreenReaderContent_default = "default" in
|
|
2924
|
+
var ScreenReaderContent_default = "default" in defaultImport33 ? defaultImport33.default : defaultImport33;
|
|
2809
2925
|
|
|
2810
2926
|
// src/common/shapeUtils.tsx
|
|
2811
2927
|
var shapeOptionsMapping = {
|