@splunk/visualizations 27.3.0 → 27.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.config.js +24 -3
- package/Area.config.js.map +2 -2
- package/Area.js +53 -9
- package/Area.js.map +2 -2
- package/Bar.config.js +24 -3
- package/Bar.config.js.map +3 -3
- package/Bar.js +54 -11
- package/Bar.js.map +3 -3
- package/Bubble.config.js +8 -1
- package/Bubble.config.js.map +2 -2
- package/Bubble.js +17 -6
- package/Bubble.js.map +2 -2
- package/CHANGELOG.external.md +1629 -0
- package/ChoroplethSvg.js +2 -2
- package/Column.config.js +24 -3
- package/Column.config.js.map +3 -3
- package/Column.js +53 -9
- package/Column.js.map +3 -3
- package/Ellipse.js +65 -7
- package/Ellipse.js.map +4 -4
- package/Events.js +11 -6
- package/Events.js.map +2 -2
- package/FEATUREFLAGS.md +2 -0
- package/FillerGauge.config.js +8 -28
- package/FillerGauge.config.js.map +2 -2
- package/FillerGauge.js +10 -30
- package/FillerGauge.js.map +2 -2
- package/Image.js +2 -2
- package/Line.config.js +24 -3
- package/Line.config.js.map +3 -3
- package/Line.js +53 -9
- package/Line.js.map +3 -3
- package/LinkGraph.js +2 -2
- package/Map.config.js +22 -0
- package/Map.config.js.map +2 -2
- package/Map.js +284 -121
- package/Map.js.map +4 -4
- package/Markdown.js +2 -2
- package/MarkerGauge.config.js +8 -25
- package/MarkerGauge.config.js.map +2 -2
- package/MarkerGauge.js +10 -27
- package/MarkerGauge.js.map +2 -2
- package/ParallelCoordinates.js +2 -2
- package/ParallelCoordinates.js.map +1 -1
- package/Pie.config.js +123 -3
- package/Pie.config.js.map +3 -3
- package/Pie.js +743 -19
- package/Pie.js.map +4 -4
- package/Punchcard.js +2 -2
- package/Punchcard.js.map +1 -1
- package/Rectangle.js +64 -7
- package/Rectangle.js.map +4 -4
- package/Sankey.js +36 -35
- package/Sankey.js.map +3 -3
- package/Scatter.config.js +320 -113
- package/Scatter.config.js.map +4 -4
- package/Scatter.js +936 -128
- package/Scatter.js.map +4 -4
- package/SingleValue.js +3 -3
- package/SingleValue.js.map +2 -2
- package/SingleValueBasic.js.map +1 -1
- package/SingleValueIcon.js +3 -3
- package/SingleValueIcon.js.map +2 -2
- package/SingleValueRadial.js +3 -3
- package/SingleValueRadial.js.map +2 -2
- package/TRELLIS.md +12 -3
- package/Table.js +2 -2
- package/Timeline.js +81 -63
- package/Timeline.js.map +4 -4
- package/common/Charting.js +7 -3
- package/common/Charting.js.map +2 -2
- package/common/chartingUtils.js +11 -0
- package/common/chartingUtils.js.map +2 -2
- package/common/shapeUtils.js +85 -3
- package/common/shapeUtils.js.map +4 -4
- package/common/utils/mapUtils.js +169 -48
- package/common/utils/mapUtils.js.map +4 -4
- package/common/utils/singleValueUtils.js +1 -1
- package/common/utils/singleValueUtils.js.map +2 -2
- package/common/withDashboardViz.js +2 -2
- package/package.json +18 -18
package/Line.js
CHANGED
|
@@ -652,6 +652,7 @@ var propTypes = {
|
|
|
652
652
|
onDownsamplingThresholdChange: prop_types_exports.func,
|
|
653
653
|
xField: prop_types_exports.string,
|
|
654
654
|
y2Fields: prop_types_exports.array,
|
|
655
|
+
additionalTooltipFields: prop_types_exports.array,
|
|
655
656
|
splitByLayout: prop_types_exports.oneOf(Object.values(visualization_schemas_exports.LAYOUT_TYPE)),
|
|
656
657
|
trellisKey: prop_types_exports.string,
|
|
657
658
|
trellisSplitBy: prop_types_exports.string,
|
|
@@ -697,7 +698,8 @@ var Charting = (props) => {
|
|
|
697
698
|
xField,
|
|
698
699
|
backgroundColor,
|
|
699
700
|
defaultFontColor,
|
|
700
|
-
trellisKey
|
|
701
|
+
trellisKey,
|
|
702
|
+
additionalTooltipFields
|
|
701
703
|
} = props;
|
|
702
704
|
const prevOptions = usePrevious(options);
|
|
703
705
|
const prevTimezone = usePrevious(timezone);
|
|
@@ -924,7 +926,8 @@ var Charting = (props) => {
|
|
|
924
926
|
timezone == null ? void 0 : timezone.utcOffset,
|
|
925
927
|
timezone == null ? void 0 : timezone.serializedTimezone,
|
|
926
928
|
themeKey,
|
|
927
|
-
onClick
|
|
929
|
+
onClick,
|
|
930
|
+
additionalTooltipFields
|
|
928
931
|
]);
|
|
929
932
|
return /* @__PURE__ */ react_exports.createElement(react_exports.Fragment, null, trellisEnabled && /* @__PURE__ */ react_exports.createElement(
|
|
930
933
|
TrellisTitle,
|
|
@@ -967,7 +970,8 @@ var defaultProps = {
|
|
|
967
970
|
trellisKey: void 0,
|
|
968
971
|
trellisSplitBy: void 0,
|
|
969
972
|
backgroundColor: "",
|
|
970
|
-
defaultFontColor: ""
|
|
973
|
+
defaultFontColor: "",
|
|
974
|
+
additionalTooltipFields: []
|
|
971
975
|
};
|
|
972
976
|
Charting.propTypes = propTypes;
|
|
973
977
|
Charting.defaultProps = defaultProps;
|
|
@@ -1085,6 +1089,13 @@ var AxesChartDataConfig = {
|
|
|
1085
1089
|
}
|
|
1086
1090
|
}
|
|
1087
1091
|
],
|
|
1092
|
+
[
|
|
1093
|
+
{
|
|
1094
|
+
label: (0, i18n_exports._)("Additional tooltip fields"),
|
|
1095
|
+
option: "additionalTooltipFields",
|
|
1096
|
+
editor: "editor.columnMultiSelectionByFieldNameEditor"
|
|
1097
|
+
}
|
|
1098
|
+
],
|
|
1088
1099
|
[
|
|
1089
1100
|
{
|
|
1090
1101
|
label: (0, i18n_exports._)("Result limit"),
|
|
@@ -1409,6 +1420,20 @@ var AxesChartDataDisplayBar = {
|
|
|
1409
1420
|
...AxesChartDataDisplayBase.layout.slice(2)
|
|
1410
1421
|
]
|
|
1411
1422
|
};
|
|
1423
|
+
var AxesChartDataDisplayScatter = {
|
|
1424
|
+
label: AxesChartDataDisplayBase.label,
|
|
1425
|
+
layout: [
|
|
1426
|
+
...TrellisEditorConfig,
|
|
1427
|
+
[
|
|
1428
|
+
{
|
|
1429
|
+
label: (0, i18n_exports._)("Shared y-axis scale"),
|
|
1430
|
+
option: "trellisSharedScale",
|
|
1431
|
+
editor: "editor.checkbox",
|
|
1432
|
+
showEditor: isTrellisEnabled3
|
|
1433
|
+
}
|
|
1434
|
+
]
|
|
1435
|
+
]
|
|
1436
|
+
};
|
|
1412
1437
|
var AxesChartDataDisplayColumn = {
|
|
1413
1438
|
label: AxesChartDataDisplayBase.label,
|
|
1414
1439
|
layout: [
|
|
@@ -1494,7 +1519,7 @@ var AxesChartColorAndStyle = {
|
|
|
1494
1519
|
]
|
|
1495
1520
|
]
|
|
1496
1521
|
};
|
|
1497
|
-
var
|
|
1522
|
+
var AxesChartColorAndStyleWithTrellis = __spreadProps(__spreadValues({}, AxesChartColorAndStyle), {
|
|
1498
1523
|
layout: [
|
|
1499
1524
|
AxesChartColorAndStyle.layout[0],
|
|
1500
1525
|
[
|
|
@@ -2274,9 +2299,9 @@ var editorConfig = [
|
|
|
2274
2299
|
AxesChartDataConfigAreaColumnLine,
|
|
2275
2300
|
AxesChartDataDisplayLine,
|
|
2276
2301
|
{
|
|
2277
|
-
label:
|
|
2302
|
+
label: AxesChartColorAndStyleWithTrellis.label,
|
|
2278
2303
|
layout: [
|
|
2279
|
-
...
|
|
2304
|
+
...AxesChartColorAndStyleWithTrellis.layout,
|
|
2280
2305
|
// [
|
|
2281
2306
|
// {
|
|
2282
2307
|
// label: _('Line dash style'),
|
|
@@ -2723,7 +2748,7 @@ var withFixedSizeContainer = (Viz) => {
|
|
|
2723
2748
|
FixSizeItem,
|
|
2724
2749
|
{
|
|
2725
2750
|
"data-test": "fix-size-item",
|
|
2726
|
-
"data-splunk-visualization-version": "27.
|
|
2751
|
+
"data-splunk-visualization-version": "27.5.0 - 5cfbc7064",
|
|
2727
2752
|
width,
|
|
2728
2753
|
height,
|
|
2729
2754
|
backgroundColor
|
|
@@ -2789,7 +2814,7 @@ var Cover = styled_components_default.div`
|
|
|
2789
2814
|
bottom: 0;
|
|
2790
2815
|
`;
|
|
2791
2816
|
var Blocker = styled_components_default.div.attrs({
|
|
2792
|
-
"data-splunk-visualization-version": "27.
|
|
2817
|
+
"data-splunk-visualization-version": "27.5.0 - 5cfbc7064"
|
|
2793
2818
|
})`
|
|
2794
2819
|
position: relative;
|
|
2795
2820
|
width: 100%;
|
|
@@ -3717,6 +3742,16 @@ var constructFieldsAndColumns = ({
|
|
|
3717
3742
|
fields
|
|
3718
3743
|
};
|
|
3719
3744
|
};
|
|
3745
|
+
function constructAdditionalTooltipFieldsMap({ fields, columns, additionalTooltipFields }) {
|
|
3746
|
+
const map = {};
|
|
3747
|
+
additionalTooltipFields == null ? void 0 : additionalTooltipFields.forEach((fieldName) => {
|
|
3748
|
+
const index = fields.findIndex((f) => f.name === fieldName);
|
|
3749
|
+
if (index !== -1) {
|
|
3750
|
+
map[fieldName] = columns[index];
|
|
3751
|
+
}
|
|
3752
|
+
});
|
|
3753
|
+
return map;
|
|
3754
|
+
}
|
|
3720
3755
|
var shouldEnableSearchZoom = (eventHandlers = [], xField = "") => {
|
|
3721
3756
|
const rangeSelectEventHandler = eventHandlers.find(
|
|
3722
3757
|
(eventHandler) => {
|
|
@@ -4090,6 +4125,7 @@ var computeVizProps = (_a) => {
|
|
|
4090
4125
|
y,
|
|
4091
4126
|
xField,
|
|
4092
4127
|
yFields,
|
|
4128
|
+
additionalTooltipFields,
|
|
4093
4129
|
onEventTrigger,
|
|
4094
4130
|
annotationX,
|
|
4095
4131
|
annotationColor,
|
|
@@ -4104,6 +4140,7 @@ var computeVizProps = (_a) => {
|
|
|
4104
4140
|
"y",
|
|
4105
4141
|
"xField",
|
|
4106
4142
|
"yFields",
|
|
4143
|
+
"additionalTooltipFields",
|
|
4107
4144
|
"onEventTrigger",
|
|
4108
4145
|
"annotationX",
|
|
4109
4146
|
"annotationColor",
|
|
@@ -4127,6 +4164,9 @@ var computeVizProps = (_a) => {
|
|
|
4127
4164
|
const truncationLimit = computedProps.options["chart.resultTruncationLimit"];
|
|
4128
4165
|
let primaryData = __spreadValues({}, dataSources.primary.data);
|
|
4129
4166
|
const { columns, fields } = constructFieldsAndColumns({ x, y, xField, yFields, y2, y2Fields });
|
|
4167
|
+
const additionalTooltipFieldsConstructed = constructAdditionalTooltipFieldsMap(__spreadProps(__spreadValues({}, dataSources.primary.data), {
|
|
4168
|
+
additionalTooltipFields
|
|
4169
|
+
}));
|
|
4130
4170
|
primaryData.columns = columns;
|
|
4131
4171
|
primaryData.fields = fields;
|
|
4132
4172
|
if (truncationLimit) {
|
|
@@ -4136,7 +4176,11 @@ var computeVizProps = (_a) => {
|
|
|
4136
4176
|
__spreadProps(__spreadValues({}, primaryData), {
|
|
4137
4177
|
annotations: chartingAnnotations
|
|
4138
4178
|
}),
|
|
4139
|
-
{
|
|
4179
|
+
{
|
|
4180
|
+
removeRangeSelectOnLoad: true,
|
|
4181
|
+
enableSearchZoom: shouldEnableSearchZoom(eventHandlers, xField),
|
|
4182
|
+
additionalTooltipFields: additionalTooltipFieldsConstructed
|
|
4183
|
+
}
|
|
4140
4184
|
);
|
|
4141
4185
|
if (hasEventHandlers) {
|
|
4142
4186
|
computedProps.onClick = onEventTrigger;
|