@splunk/visualizations 25.8.1 → 25.9.1
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 +2 -2
- package/Area.config.js.map +1 -1
- package/Area.js +25 -9
- package/Area.js.map +1 -1
- package/Bar.config.js +3 -3
- package/Bar.config.js.map +1 -1
- package/Bar.js +26 -10
- package/Bar.js.map +1 -1
- package/Bubble.js +23 -7
- package/Bubble.js.map +1 -1
- package/ChoroplethSvg.js +20 -6
- package/ChoroplethSvg.js.map +1 -1
- package/Column.config.js +4 -4
- package/Column.config.js.map +1 -1
- package/Column.js +27 -11
- package/Column.js.map +1 -1
- package/Ellipse.js +20 -6
- package/Ellipse.js.map +1 -1
- package/Events.js +20 -6
- package/Events.js.map +1 -1
- package/FillerGauge.config.js +1 -1
- package/FillerGauge.config.js.map +1 -1
- package/FillerGauge.js +21 -7
- package/FillerGauge.js.map +1 -1
- package/Image.js +20 -6
- package/Image.js.map +1 -1
- package/Line.config.js +13 -4
- package/Line.config.js.map +1 -1
- package/Line.js +38 -12
- package/Line.js.map +1 -1
- package/LinkGraph.js +2117 -2472
- package/LinkGraph.js.map +1 -1
- package/Map.js +114 -93
- package/Map.js.map +1 -1
- package/Markdown.config.js +1 -0
- package/Markdown.config.js.map +1 -1
- package/Markdown.js +40 -25
- package/Markdown.js.map +1 -1
- package/MarkerGauge.config.js +1 -1
- package/MarkerGauge.config.js.map +1 -1
- package/MarkerGauge.js +29 -15
- package/MarkerGauge.js.map +1 -1
- package/ParallelCoordinates.js +49 -35
- package/ParallelCoordinates.js.map +1 -1
- package/Pie.config.js +1 -1
- package/Pie.config.js.map +1 -1
- package/Pie.js +32 -16
- package/Pie.js.map +1 -1
- package/Punchcard.js +143 -129
- package/Punchcard.js.map +1 -1
- package/README.internal.md +15 -5
- package/README.md +3 -1
- package/Rectangle.js +61 -47
- package/Rectangle.js.map +1 -1
- package/Sankey.js +34 -20
- package/Sankey.js.map +1 -1
- package/Scatter.js +74 -58
- package/Scatter.js.map +1 -1
- package/SingleValue.config.js +6 -6
- package/SingleValue.config.js.map +1 -1
- package/SingleValue.js +41 -25
- package/SingleValue.js.map +1 -1
- package/SingleValueBasic.js +4 -4
- package/SingleValueBasic.js.map +1 -1
- package/SingleValueIcon.config.js +10 -8
- package/SingleValueIcon.config.js.map +1 -1
- package/SingleValueIcon.js +86 -70
- package/SingleValueIcon.js.map +1 -1
- package/SingleValueRadial.config.js +10 -8
- package/SingleValueRadial.config.js.map +1 -1
- package/SingleValueRadial.js +85 -69
- package/SingleValueRadial.js.map +1 -1
- package/Table.config.js +1 -1
- package/Table.config.js.map +1 -1
- package/Table.js +54 -36
- package/Table.js.map +1 -1
- package/common/Charting.js +3 -1
- package/common/Charting.js.map +1 -1
- package/common/OptionsDoc.js +9 -6
- package/common/OptionsDoc.js.map +1 -1
- package/common/OverviewDoc.js +5 -5
- package/common/OverviewDoc.js.map +1 -1
- package/common/withDashboardViz.js +20 -6
- package/common/withDashboardViz.js.map +1 -1
- package/package.json +23 -23
package/README.internal.md
CHANGED
|
@@ -2,7 +2,9 @@ A visualization is a React component that you can use in an application like Das
|
|
|
2
2
|
|
|
3
3
|
The visualizations library consists of React components built on top of Highcharts and D3.js. If you’re familiar with these libraries, you can build on that knowledge and add tooltips, legends, and data series to a chart. You can choose from more than 20 different visualizations that show data in a variety of formats. If you would like to use Splunk visualizations in your applications, read on to learn more.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
Documentation for the Splunk Visualizations library can be found at [@splunk/visualizations](https://splunkui.splunkeng.com/Packages/visualizations).
|
|
6
|
+
|
|
7
|
+
If you don’t find a visualization you would like to use, go to [Contribute a Visualization](https://splunkui.splunkeng.com/Packages/visualizations/?path=%2FHowtoContribute). If you have any questions, please reach out to [ssg-swp-viz@splunk.com](ssg-swp-viz@splunk.com) or Slack us at [#splunk-viz](slack://channel?team=T024FQ3UW&id=CCC0XPLD6).
|
|
6
8
|
|
|
7
9
|
## Install
|
|
8
10
|
|
|
@@ -56,11 +58,11 @@ You can use UDF to create dashboards with visualizations, or you can work direct
|
|
|
56
58
|
- Splunk visualizations to enhance data presentation
|
|
57
59
|
- tokens to pass runtime values within a dashboard
|
|
58
60
|
|
|
59
|
-
To install the UDF library, see the setup guide in the [Quick Start](https://
|
|
61
|
+
To install the UDF library, see the setup guide in the [Quick Start](https://splunkui.splunkeng.com/Packages/dashboard-docs/?path=%2FQuickStart). When you have it installed, follow the quick start to install dependencies and learn about using the libraries.
|
|
60
62
|
|
|
61
63
|
You can also include visualizations in single page apps by using visualizations directly. To use visualizations directly, follow the [Splunk UI tutorials](https://splunkui.splunkeng.com/Create/Overview) to create a component and a simple app. The tutorials will create the app structure for other development.
|
|
62
64
|
|
|
63
|
-
Install the visualizations libraries and dependencies listed in the Visualizations docs. Some of the packages may have been installed with the Splunk UI setup.
|
|
65
|
+
Install the visualizations libraries and dependencies listed in the [Visualizations docs](https://splunkui.splunkeng.com/Packages/visualizations). Some of the packages may have been installed with the Splunk UI setup.
|
|
64
66
|
|
|
65
67
|
## Customize a visualization
|
|
66
68
|
|
|
@@ -75,6 +77,14 @@ A React visualization is reusable bits of code that you can use in an app or das
|
|
|
75
77
|
|
|
76
78
|
**Options** provide an extensive set of builtin properties that you configure. In React, properties are referred to as props. You can set props programmatically, or use an app to set them. For every visualization, there is a description and a type. In some cases, a prop value is selected from a set of values or an enumeration. In other cases, the author specifies the value of a prop. By setting props, you can change fonts, colors, data sources, or opacity of colors in a chart. Default values exist for most components so you can also leave a prop as is.
|
|
77
79
|
|
|
78
|
-
**Events** offer a mechanism to capture user activity on a chart. Activities can include point clicks on a chart or legend, range selection on a chart, as well as events like holding the pointer over a point or moving the pointer away. Each platform visualization has a tab for events that lists the events available for the chart. When an event occurs, such as a point click, the click event captures the data. You can use the data to drill down further by using the data points. For more information, see the [Interaction Guide](https://
|
|
80
|
+
**Events** offer a mechanism to capture user activity on a chart. Activities can include point clicks on a chart or legend, range selection on a chart, as well as events like holding the pointer over a point or moving the pointer away. Each platform visualization has a tab for events that lists the events available for the chart. When an event occurs, such as a point click, the click event captures the data. You can use the data to drill down further by using the data points. For more information, see the [Interaction Guide](https://splunkui.splunkeng.com/Packages/visualizations/?path=%2FInteractionGuide).
|
|
81
|
+
|
|
82
|
+
Dynamic options syntax (DOS), also referred to as DSL in the docs, exposes even more functionality in charts. A chart that presents text or background display according to a threshold value makes a data presentation more impactful. Dynamic options are a domain-specific language to bind data to options and make data presentation more reflective of changes. The dynamic options syntax consists of data sources, selector functions, and formatters. In the dynamic options syntax, the categories can be combined to create a pipeline. The pipeline begins with a data source, then includes selector functions to extract the data of interest, and formatters to transform and map the data. For more information about dynamic options syntax, see [Fundamentals of DSL](https://splunkui.splunkeng.com/Packages/visualizations/?path=%2FFundamentalsofDSL).
|
|
83
|
+
|
|
84
|
+
## Resources
|
|
79
85
|
|
|
80
|
-
|
|
86
|
+
- Release schedule can be found at [UDF & Visualization Releases](https://splunk.atlassian.net/wiki/spaces/SWP/pages/1078219509308/UDF+Visualization+Releases)
|
|
87
|
+
- Documentation and API reference can be found at [@splunk/visualizations](https://splunkui.splunkeng.com/Packages/visualizations)
|
|
88
|
+
- Storybooks playground with the main branch can be found at [devplat.splunkdev.page/vision](https://devplat.splunkdev.page/vision)
|
|
89
|
+
- A Splunk app using UDF with the main branch visualization viewing/editing/exporting experience can be found at [vizplayground:8000](http://vizplayground:8000)
|
|
90
|
+
- To request access to the Viz Playground instance, please fill out [this form](https://forms.gle/JEkUDXiYE52qLzcL6)
|
package/README.md
CHANGED
|
@@ -2,6 +2,8 @@ A visualization is a React component that you can use in an application like Das
|
|
|
2
2
|
|
|
3
3
|
The visualizations library consists of React components built on top of Highcharts and D3.js. If you’re familiar with these libraries, you can build on that knowledge and add tooltips, legends, and data series to a chart. You can choose from more than 20 different visualizations that show data in a variety of formats. If you would like to use Splunk visualizations in your applications, read on to learn more.
|
|
4
4
|
|
|
5
|
+
Documentation for the Splunk Visualizations library can be found at [@splunk/visualizations](https://splunkui.splunk.com/Packages/visualizations).
|
|
6
|
+
|
|
5
7
|
## Install
|
|
6
8
|
|
|
7
9
|
Install @splunk/visualizations
|
|
@@ -58,7 +60,7 @@ To install the UDF library, see the setup guide in the [Quick Start](https://spl
|
|
|
58
60
|
|
|
59
61
|
You can also include visualizations in single page apps by using visualizations directly. To use visualizations directly, follow the [Splunk UI tutorials](https://splunkui.splunk.com/Create/Overview) to create a component and a simple app. The tutorials will create the app structure for other development.
|
|
60
62
|
|
|
61
|
-
Install the visualizations libraries and dependencies listed in the Visualizations docs. Some of the packages may have been installed with the Splunk UI setup.
|
|
63
|
+
Install the visualizations libraries and dependencies listed in the [Visualizations docs](https://splunkui.splunk.com/Packages/visualizations). Some of the packages may have been installed with the Splunk UI setup.
|
|
62
64
|
|
|
63
65
|
## Customize a visualization
|
|
64
66
|
|
package/Rectangle.js
CHANGED
|
@@ -87,7 +87,7 @@ module.exports =
|
|
|
87
87
|
/******/
|
|
88
88
|
/******/
|
|
89
89
|
/******/ // Load entry module and return exports
|
|
90
|
-
/******/ return __webpack_require__(__webpack_require__.s =
|
|
90
|
+
/******/ return __webpack_require__(__webpack_require__.s = 449);
|
|
91
91
|
/******/ })
|
|
92
92
|
/************************************************************************/
|
|
93
93
|
/******/ ({
|
|
@@ -412,7 +412,7 @@ var withFixedSizeContainer = function withFixedSizeContainer(Viz) {
|
|
|
412
412
|
}
|
|
413
413
|
return React.createElement(FixSizeItem, {
|
|
414
414
|
"data-test": "fix-size-item",
|
|
415
|
-
"data-splunk-visualization-version": "25.
|
|
415
|
+
"data-splunk-visualization-version": "25.9.1 - 5ba41e723",
|
|
416
416
|
width: width,
|
|
417
417
|
height: height,
|
|
418
418
|
backgroundColor: backgroundColor
|
|
@@ -502,7 +502,7 @@ var styled_components_1 = __webpack_require__(4);
|
|
|
502
502
|
var lodash_1 = __webpack_require__(3);
|
|
503
503
|
var T = __webpack_require__(1);
|
|
504
504
|
var withDashboardViz_1 = __webpack_require__(36);
|
|
505
|
-
var config_1 = __webpack_require__(
|
|
505
|
+
var config_1 = __webpack_require__(450);
|
|
506
506
|
exports.config = config_1.default;
|
|
507
507
|
var shapeUtils_1 = __webpack_require__(117);
|
|
508
508
|
var SVGContainer = styled_components_1.default.svg.withConfig({
|
|
@@ -1188,10 +1188,18 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1188
1188
|
var _React$useState3 = React.useState("".concat(vizConfig.name, " - ").concat(id_1.createGUID())),
|
|
1189
1189
|
_React$useState4 = _slicedToArray(_React$useState3, 1),
|
|
1190
1190
|
visualizationID = _React$useState4[0];
|
|
1191
|
-
var _React$useState5 = React.useState(
|
|
1191
|
+
var _React$useState5 = React.useState({}),
|
|
1192
1192
|
_React$useState6 = _slicedToArray(_React$useState5, 2),
|
|
1193
|
-
|
|
1194
|
-
|
|
1193
|
+
dataSourcesInState = _React$useState6[0],
|
|
1194
|
+
setDataSourcesInState = _React$useState6[1];
|
|
1195
|
+
var _React$useState7 = React.useState(),
|
|
1196
|
+
_React$useState8 = _slicedToArray(_React$useState7, 2),
|
|
1197
|
+
dataFramesInState = _React$useState8[0],
|
|
1198
|
+
setDataFramesInState = _React$useState8[1];
|
|
1199
|
+
var _React$useState9 = React.useState(Boolean(featureFlagContext && featureFlagContext.visualizations_useWebWorkersForDSL && typeof Worker !== 'undefined')),
|
|
1200
|
+
_React$useState10 = _slicedToArray(_React$useState9, 2),
|
|
1201
|
+
useAsyncEvaluatedOptions = _React$useState10[0],
|
|
1202
|
+
setUseAsyncEvaluatedOptions = _React$useState10[1];
|
|
1195
1203
|
evaluatedOptions = useDeepMemo_1.useDeepMemo(function () {
|
|
1196
1204
|
try {
|
|
1197
1205
|
if (useAsyncEvaluatedOptions) {
|
|
@@ -1214,10 +1222,16 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1214
1222
|
setUseAsyncEvaluatedOptions(false);
|
|
1215
1223
|
});
|
|
1216
1224
|
} else {
|
|
1225
|
+
var dataFrames = dataFramesInState;
|
|
1226
|
+
if (dataSources !== dataSourcesInState) {
|
|
1227
|
+
setDataSourcesInState(dataSources);
|
|
1228
|
+
dataFrames = Options_1.Options.dataFrameFromDataSource(dataSources);
|
|
1229
|
+
setDataFramesInState(dataFrames);
|
|
1230
|
+
}
|
|
1217
1231
|
return Options_1.Options.evaluate({
|
|
1218
1232
|
context: lodash_1.defaultsDeep({}, context, vizConfig.defaultContext),
|
|
1219
1233
|
options: hocUtils_1.deepMergeWithArrayPrimitiveOverrides({}, options, defaultOptions)
|
|
1220
|
-
}, dataSources, themeFunc);
|
|
1234
|
+
}, dataSources, themeFunc, dataFrames);
|
|
1221
1235
|
}
|
|
1222
1236
|
} catch (e) {
|
|
1223
1237
|
// eslint-disable-next-line no-console
|
|
@@ -1610,6 +1624,44 @@ exports.useDeepMemo = useDeepMemo;
|
|
|
1610
1624
|
|
|
1611
1625
|
/***/ }),
|
|
1612
1626
|
|
|
1627
|
+
/***/ 449:
|
|
1628
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
1629
|
+
|
|
1630
|
+
"use strict";
|
|
1631
|
+
|
|
1632
|
+
|
|
1633
|
+
var __createBinding = this && this.__createBinding || (Object.create ? function (o, m, k, k2) {
|
|
1634
|
+
if (k2 === undefined) k2 = k;
|
|
1635
|
+
Object.defineProperty(o, k2, {
|
|
1636
|
+
enumerable: true,
|
|
1637
|
+
get: function get() {
|
|
1638
|
+
return m[k];
|
|
1639
|
+
}
|
|
1640
|
+
});
|
|
1641
|
+
} : function (o, m, k, k2) {
|
|
1642
|
+
if (k2 === undefined) k2 = k;
|
|
1643
|
+
o[k2] = m[k];
|
|
1644
|
+
});
|
|
1645
|
+
var __exportStar = this && this.__exportStar || function (m, exports) {
|
|
1646
|
+
for (var p in m) {
|
|
1647
|
+
if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
1648
|
+
}
|
|
1649
|
+
};
|
|
1650
|
+
Object.defineProperty(exports, "__esModule", {
|
|
1651
|
+
value: true
|
|
1652
|
+
});
|
|
1653
|
+
exports.default = void 0;
|
|
1654
|
+
__exportStar(__webpack_require__(161), exports);
|
|
1655
|
+
var Rectangle_1 = __webpack_require__(161);
|
|
1656
|
+
Object.defineProperty(exports, "default", {
|
|
1657
|
+
enumerable: true,
|
|
1658
|
+
get: function get() {
|
|
1659
|
+
return Rectangle_1.default;
|
|
1660
|
+
}
|
|
1661
|
+
});
|
|
1662
|
+
|
|
1663
|
+
/***/ }),
|
|
1664
|
+
|
|
1613
1665
|
/***/ 45:
|
|
1614
1666
|
/***/ (function(module, exports, __webpack_require__) {
|
|
1615
1667
|
|
|
@@ -1679,45 +1731,7 @@ exports.default = FixedSizeContainer_1.default(exports.MissingPropsMessage);
|
|
|
1679
1731
|
|
|
1680
1732
|
/***/ }),
|
|
1681
1733
|
|
|
1682
|
-
/***/
|
|
1683
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
1684
|
-
|
|
1685
|
-
"use strict";
|
|
1686
|
-
|
|
1687
|
-
|
|
1688
|
-
var __createBinding = this && this.__createBinding || (Object.create ? function (o, m, k, k2) {
|
|
1689
|
-
if (k2 === undefined) k2 = k;
|
|
1690
|
-
Object.defineProperty(o, k2, {
|
|
1691
|
-
enumerable: true,
|
|
1692
|
-
get: function get() {
|
|
1693
|
-
return m[k];
|
|
1694
|
-
}
|
|
1695
|
-
});
|
|
1696
|
-
} : function (o, m, k, k2) {
|
|
1697
|
-
if (k2 === undefined) k2 = k;
|
|
1698
|
-
o[k2] = m[k];
|
|
1699
|
-
});
|
|
1700
|
-
var __exportStar = this && this.__exportStar || function (m, exports) {
|
|
1701
|
-
for (var p in m) {
|
|
1702
|
-
if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
1703
|
-
}
|
|
1704
|
-
};
|
|
1705
|
-
Object.defineProperty(exports, "__esModule", {
|
|
1706
|
-
value: true
|
|
1707
|
-
});
|
|
1708
|
-
exports.default = void 0;
|
|
1709
|
-
__exportStar(__webpack_require__(161), exports);
|
|
1710
|
-
var Rectangle_1 = __webpack_require__(161);
|
|
1711
|
-
Object.defineProperty(exports, "default", {
|
|
1712
|
-
enumerable: true,
|
|
1713
|
-
get: function get() {
|
|
1714
|
-
return Rectangle_1.default;
|
|
1715
|
-
}
|
|
1716
|
-
});
|
|
1717
|
-
|
|
1718
|
-
/***/ }),
|
|
1719
|
-
|
|
1720
|
-
/***/ 452:
|
|
1734
|
+
/***/ 450:
|
|
1721
1735
|
/***/ (function(module, exports, __webpack_require__) {
|
|
1722
1736
|
|
|
1723
1737
|
"use strict";
|
|
@@ -2062,7 +2076,7 @@ var Cover = styled_components_1.default.div.withConfig({
|
|
|
2062
2076
|
componentId: "sc-1gsbnxb-0"
|
|
2063
2077
|
})(["position:absolute;left:0;right:0;top:0;bottom:0;"]);
|
|
2064
2078
|
var Blocker = styled_components_1.default.div.attrs({
|
|
2065
|
-
'data-splunk-visualization-version': "25.
|
|
2079
|
+
'data-splunk-visualization-version': "25.9.1 - 5ba41e723"
|
|
2066
2080
|
}).withConfig({
|
|
2067
2081
|
displayName: "withEditModeCover__Blocker",
|
|
2068
2082
|
componentId: "sc-1gsbnxb-1"
|