@splunk/visualizations 24.2.0 → 24.3.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/.loki/reference/chrome_docker_PureVisualizations_PureFillerGauge_Orientation_horizontal_height_90_show_placeholder.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureFillerGauge_Too_Small_to_Render.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_Tooltip_Dark.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_Tooltip_Hover.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_Tooltip_Light.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_base_map_light.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_basic.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_bubble_layer_dynamic_color.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_bubble_layer_geostats_by.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_bubble_layer_static_color.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_bubble_layer_static_color_with_no_seriesColors.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_center_seattle.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_marker_layer_dynamic_color.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_marker_layer_static_color.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_marker_layer_static_color_with_no_seriesColors.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_scale_off.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_scale_unit_metric.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMap_zoom_9.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMarkerGauge_Invalid_ranges_duplicate_entries_from.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMarkerGauge_Invalid_ranges_duplicate_entries_to.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMarkerGauge_Invalid_ranges_invalid_entries_discontinuous_ranges.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMarkerGauge_Invalid_ranges_invalid_entries_from_equals_to_to.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMarkerGauge_Invalid_ranges_invalid_entries_from_is_larger_than_to.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMarkerGauge_Invalid_ranges_missing_entries.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMarkerGauge_Orientation_horizontal_width_150_show_placeholder.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureMarkerGauge_Too_Small_to_Render.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureSankey_dimensions_less_than_minWidth_300_and_minHeight_200.png +0 -0
- package/.loki/reference/chrome_docker_PureVisualizations_PureSankey_invalid_columns_data.png +0 -0
- package/.loki/reference/chrome_docker_VisualizationEditors_Editors_Map_Editor.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Choropleth_Svg_Choropleth_Svg_Missing_Props_Message_When_No_Svg.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Filler_Gauge_Filler_Gauge_Orientation_horizontal_height_90_show_placeholder.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Basic_Map.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Bubble_Layer.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Bubble_Layer_Geostats_By_GET.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Bubble_Layer_Geostats_By_GET_Dynamic_Coloring.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Bubble_Layer_Geostats_By_Static_Coloring.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Bubble_Layer_Geostats_Dynamic_Coloring.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Marker_layer.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Marker_layer_Dynamic_coloring.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Marker_layer_Result_Limit_Set_To_3.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Marker_layer_with_geostats_data_No_render.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Map_Map_Set_Map_tiles.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Pie_Pie_Missing_Column.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Sankey_Sankey_Dimension_Too_Small.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Align_By_Type_Custom.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Align_Default.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Align_Kitchen_Sink.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Align_Right.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Align_Single_Column.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Background_Color_light_blue.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Background_No_Stripe.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Background_Stripe.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Basic_Table.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Basic_Table_With_No_Click.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Cell_Types.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Column_Gradient.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Column_Override.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Column_Width.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Count_2.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Custom_Header_Colors.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Custom_Row_Colors.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Custom_Stripe.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Dark_Background_No_Stripe.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Dark_Background_Stripe.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Format_Number.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Format_Number_Adv.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Header_Visibility_fixed.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Header_Visibility_none.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Height_Percentage.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Height_Percentage_100_no_paginator.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Invalid_Background_Color.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Multi_Value_Field.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_No_Stripes.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_No_Stripes_Row_Numbers.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Show_Internal_Fields_false.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Show_Internal_Fields_true_default.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Show_Row_Numbers_true.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Sparkline.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Sparkline_Custom.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Sparkline_Width.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Sparklines_Adv.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Table_Formatting.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Table_Gradient.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Time_Formatting.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Width_Height.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Width_Percentage.png +0 -0
- package/.loki/reference/chrome_docker_Visualizations_Table_Table_Width_Px.png +0 -0
- package/Area.config.js +15 -15
- package/Area.config.js.map +1 -1
- package/Area.js +108 -121
- package/Area.js.map +1 -1
- package/Bar.config.js +15 -15
- package/Bar.config.js.map +1 -1
- package/Bar.js +101 -114
- package/Bar.js.map +1 -1
- package/Bubble.config.js +8 -8
- package/Bubble.config.js.map +1 -1
- package/Bubble.js +94 -107
- package/Bubble.js.map +1 -1
- package/ChoroplethSvg.config.js +11 -9
- package/ChoroplethSvg.config.js.map +1 -1
- package/ChoroplethSvg.js +120 -131
- package/ChoroplethSvg.js.map +1 -1
- package/Column.config.js +15 -15
- package/Column.config.js.map +1 -1
- package/Column.js +101 -114
- package/Column.js.map +1 -1
- package/Ellipse.config.js +22 -2
- package/Ellipse.config.js.map +1 -1
- package/Ellipse.js +106 -99
- package/Ellipse.js.map +1 -1
- package/FillerGauge.config.js +8 -8
- package/FillerGauge.config.js.map +1 -1
- package/FillerGauge.js +107 -120
- package/FillerGauge.js.map +1 -1
- package/Image.js +81 -97
- package/Image.js.map +1 -1
- package/Line.config.js +8 -8
- package/Line.config.js.map +1 -1
- package/Line.js +101 -114
- package/Line.js.map +1 -1
- package/LinkGraph.config.js +4 -4
- package/LinkGraph.js +128 -141
- package/LinkGraph.js.map +1 -1
- package/Map.config.js +740 -0
- package/Map.config.js.map +1 -0
- package/Map.js +3137 -0
- package/Map.js.map +1 -0
- package/Markdown.config.js +12 -12
- package/Markdown.config.js.map +1 -1
- package/Markdown.js +99 -115
- package/Markdown.js.map +1 -1
- package/MarkerGauge.config.js +6 -6
- package/MarkerGauge.config.js.map +1 -1
- package/MarkerGauge.js +2953 -3060
- package/MarkerGauge.js.map +1 -1
- package/ParallelCoordinates.config.js +11 -11
- package/ParallelCoordinates.config.js.map +1 -1
- package/ParallelCoordinates.js +137 -139
- package/ParallelCoordinates.js.map +1 -1
- package/Pie.config.js +13 -13
- package/Pie.config.js.map +1 -1
- package/Pie.js +912 -1019
- package/Pie.js.map +1 -1
- package/Punchcard.config.js +11 -11
- package/Punchcard.config.js.map +1 -1
- package/Punchcard.js +153 -155
- package/Punchcard.js.map +1 -1
- package/README.internal.md +36 -3
- package/README.md +7 -9
- package/Rectangle.config.js +32 -12
- package/Rectangle.config.js.map +1 -1
- package/Rectangle.js +187 -183
- package/Rectangle.js.map +1 -1
- package/Sankey.config.js +35 -25
- package/Sankey.config.js.map +1 -1
- package/Sankey.js +2964 -3079
- package/Sankey.js.map +1 -1
- package/Scatter.config.js +11 -11
- package/Scatter.config.js.map +1 -1
- package/Scatter.js +231 -247
- package/Scatter.js.map +1 -1
- package/SingleValue.config.js +23 -22
- package/SingleValue.config.js.map +1 -1
- package/SingleValue.js +423 -439
- package/SingleValue.js.map +1 -1
- package/SingleValueBasic.js +20 -20
- package/SingleValueBasic.js.map +1 -1
- package/SingleValueIcon.config.js +33 -34
- package/SingleValueIcon.config.js.map +1 -1
- package/SingleValueIcon.js +176 -181
- package/SingleValueIcon.js.map +1 -1
- package/SingleValueRadial.config.js +22 -22
- package/SingleValueRadial.config.js.map +1 -1
- package/SingleValueRadial.js +389 -405
- package/SingleValueRadial.js.map +1 -1
- package/Table.config.js +19 -7
- package/Table.config.js.map +1 -1
- package/Table.js +522 -383
- package/Table.js.map +1 -1
- package/common/Charting.js +21 -22
- package/common/Charting.js.map +1 -1
- package/common/ChartingApi.js +2 -2
- package/common/ChartingApi.js.map +1 -1
- package/common/EventsDoc.js +14 -15
- package/common/EventsDoc.js.map +1 -1
- package/common/GaugeMajorTicks.js +2 -2
- package/common/GaugeMajorTicks.js.map +1 -1
- package/common/GaugeValueMarker.js +2 -2
- package/common/GaugeValueMarker.js.map +1 -1
- package/common/OptionsDoc.js +7 -8
- package/common/OptionsDoc.js.map +1 -1
- package/common/OverviewDoc.js +22 -22
- package/common/OverviewDoc.js.map +1 -1
- package/common/SplunkVisualization.js +4 -4
- package/common/SplunkVisualization.js.map +1 -1
- package/common/SplunkVisualizationApi.js +2 -2
- package/common/SplunkVisualizationApi.js.map +1 -1
- package/common/ThemesDoc.js +16 -16
- package/common/ThemesDoc.js.map +1 -1
- package/common/chartingUtils.js +4 -4
- package/common/chartingUtils.js.map +1 -1
- package/common/docUtils.js +4 -4
- package/common/docUtils.js.map +1 -1
- package/common/gaugeUtils.js +13 -13
- package/common/gaugeUtils.js.map +1 -1
- package/common/shapeUtils.js +8 -8
- package/common/shapeUtils.js.map +1 -1
- package/common/withDashboardViz.js +53 -68
- package/common/withDashboardViz.js.map +1 -1
- package/loki.config.js +2 -0
- package/package.json +19 -15
- package/common/version.js +0 -110
- package/common/version.js.map +0 -1
- package/scripts/generateVersion.js +0 -13
package/Table.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 = 255);
|
|
91
91
|
/******/ })
|
|
92
92
|
/************************************************************************/
|
|
93
93
|
/******/ ({
|
|
@@ -159,14 +159,12 @@ var React = __webpack_require__(1);
|
|
|
159
159
|
|
|
160
160
|
var styled_components_1 = __webpack_require__(4);
|
|
161
161
|
|
|
162
|
-
var SizeAwareWrapper_1 = __webpack_require__(
|
|
162
|
+
var SizeAwareWrapper_1 = __webpack_require__(16);
|
|
163
163
|
|
|
164
|
-
var style_1 = __webpack_require__(
|
|
164
|
+
var style_1 = __webpack_require__(13);
|
|
165
165
|
|
|
166
166
|
var colorUtils_1 = __webpack_require__(11);
|
|
167
167
|
|
|
168
|
-
var version_1 = __webpack_require__(13);
|
|
169
|
-
|
|
170
168
|
var Item = styled_components_1.default.div.attrs(function (_ref) {
|
|
171
169
|
var width = _ref.width;
|
|
172
170
|
return {
|
|
@@ -222,7 +220,7 @@ var withFixedSizeContainer = function withFixedSizeContainer(Viz) {
|
|
|
222
220
|
|
|
223
221
|
return React.createElement(FixSizeItem, {
|
|
224
222
|
"data-test": "fix-size-item",
|
|
225
|
-
"data-splunk-visualization-version":
|
|
223
|
+
"data-splunk-visualization-version": "24.3.0 - 1c1ae4b3c",
|
|
226
224
|
width: width,
|
|
227
225
|
height: height,
|
|
228
226
|
backgroundColor: backgroundColor
|
|
@@ -245,25 +243,20 @@ exports.default = withFixedSizeContainer;
|
|
|
245
243
|
/***/ }),
|
|
246
244
|
|
|
247
245
|
/***/ 13:
|
|
248
|
-
/***/ (function(module, exports
|
|
249
|
-
|
|
250
|
-
"use strict";
|
|
251
|
-
|
|
246
|
+
/***/ (function(module, exports) {
|
|
252
247
|
|
|
253
|
-
|
|
254
|
-
value: true
|
|
255
|
-
});
|
|
256
|
-
exports.version = void 0;
|
|
257
|
-
exports.version = '24.2.0';
|
|
248
|
+
module.exports = require("@splunk/visualizations-shared/style");
|
|
258
249
|
|
|
259
250
|
/***/ }),
|
|
260
251
|
|
|
261
|
-
/***/
|
|
252
|
+
/***/ 131:
|
|
262
253
|
/***/ (function(module, exports, __webpack_require__) {
|
|
263
254
|
|
|
264
255
|
"use strict";
|
|
265
256
|
|
|
266
257
|
|
|
258
|
+
var _slicedToArray = __webpack_require__(48);
|
|
259
|
+
|
|
267
260
|
var __rest = this && this.__rest || function (s, e) {
|
|
268
261
|
var t = {};
|
|
269
262
|
|
|
@@ -282,57 +275,108 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
282
275
|
});
|
|
283
276
|
exports.config = exports.PureTable = exports.themes = exports.computeVizProps = void 0;
|
|
284
277
|
|
|
285
|
-
var
|
|
278
|
+
var lodash_1 = __webpack_require__(2);
|
|
279
|
+
|
|
280
|
+
var colorUtils_1 = __webpack_require__(11);
|
|
281
|
+
|
|
282
|
+
var config_1 = __webpack_require__(256);
|
|
286
283
|
|
|
287
284
|
exports.config = config_1.default;
|
|
288
285
|
|
|
289
|
-
var withDashboardViz_1 = __webpack_require__(
|
|
286
|
+
var withDashboardViz_1 = __webpack_require__(27);
|
|
290
287
|
|
|
291
|
-
var PureTable_1 = __webpack_require__(
|
|
288
|
+
var PureTable_1 = __webpack_require__(257);
|
|
292
289
|
|
|
293
290
|
exports.PureTable = PureTable_1.default;
|
|
294
291
|
|
|
295
292
|
var computeVizProps = function computeVizProps(_a) {
|
|
296
293
|
var props = __rest(_a, []);
|
|
297
294
|
|
|
298
|
-
|
|
295
|
+
var vizProps = lodash_1.cloneDeep(props);
|
|
296
|
+
|
|
297
|
+
if (vizProps.columnFormat) {
|
|
298
|
+
var columns = vizProps.columnFormat;
|
|
299
|
+
var themeRowBackgroundColorOdd = vizProps.themeFunc('rowBackgroundColorOdd');
|
|
300
|
+
var themeRowBackgroundColorEven = vizProps.themeFunc('rowBackgroundColorEven');
|
|
301
|
+
var themeTextColor = vizProps.themeFunc('textColor'); // `columns` looks like { `column title`: { rowBackgroundColors, rowColors... }}
|
|
302
|
+
|
|
303
|
+
Object.entries(columns).forEach(function (_ref) {
|
|
304
|
+
var _ref2 = _slicedToArray(_ref, 2),
|
|
305
|
+
columnKey = _ref2[0],
|
|
306
|
+
columnProperties = _ref2[1];
|
|
307
|
+
|
|
308
|
+
var rowBackgroundColors;
|
|
309
|
+
var rowColors; // If columns have `rowBackgroundColors` or `rowColors` arrays defined, sanitize them. If there are undefined values after sanitization, these
|
|
310
|
+
// elements are populated with the default values provided by the theme.
|
|
311
|
+
|
|
312
|
+
if (columnProperties.rowBackgroundColors) {
|
|
313
|
+
rowBackgroundColors = colorUtils_1.sanitizeArrayOfColors(columnProperties.rowBackgroundColors).map(function (color, i) {
|
|
314
|
+
return (// using (i + 1) % 2 because 'odd' refers to row number, so index 0 -> row 1 -> odd colored
|
|
315
|
+
color || ((i + 1) % 2 === 0 ? themeRowBackgroundColorEven : themeRowBackgroundColorOdd)
|
|
316
|
+
);
|
|
317
|
+
});
|
|
318
|
+
}
|
|
319
|
+
|
|
320
|
+
if (columnProperties.rowColors) {
|
|
321
|
+
rowColors = colorUtils_1.sanitizeArrayOfColors(columnProperties.rowColors).map(function (color) {
|
|
322
|
+
return color || themeTextColor;
|
|
323
|
+
});
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
vizProps.columnFormat[columnKey] = Object.assign(Object.assign(Object.assign({}, vizProps.columnFormat[columnKey]), columnProperties.rowBackgroundColors && {
|
|
327
|
+
rowBackgroundColors: rowBackgroundColors
|
|
328
|
+
}), columnProperties.rowColors && {
|
|
329
|
+
rowColors: rowColors
|
|
330
|
+
});
|
|
331
|
+
});
|
|
332
|
+
}
|
|
333
|
+
|
|
334
|
+
if (vizProps.onOptionsChange) {
|
|
335
|
+
var handleColumnFormatChange = function handleColumnFormatChange(updatedColumnFormat) {
|
|
336
|
+
vizProps.onOptionsChange({
|
|
337
|
+
columnFormat: updatedColumnFormat
|
|
338
|
+
});
|
|
339
|
+
};
|
|
340
|
+
|
|
341
|
+
vizProps.onColumnFormatChange = handleColumnFormatChange;
|
|
342
|
+
}
|
|
343
|
+
|
|
344
|
+
if (!vizProps.showInternalFields) {
|
|
299
345
|
var filteredFields = [];
|
|
300
346
|
var filteredTable = [];
|
|
301
347
|
var filteredIndexes = [];
|
|
302
|
-
|
|
348
|
+
vizProps.headers.forEach(function (fieldIn, index) {
|
|
303
349
|
var _a;
|
|
304
350
|
|
|
305
351
|
var field = (_a = fieldIn.name) !== null && _a !== void 0 ? _a : fieldIn;
|
|
306
352
|
|
|
307
353
|
if (field.charAt(0) !== '_' || field === '_time') {
|
|
308
354
|
filteredFields.push(field);
|
|
309
|
-
filteredTable.push(
|
|
355
|
+
filteredTable.push(vizProps.table[index]);
|
|
310
356
|
filteredIndexes.push(index);
|
|
311
357
|
}
|
|
312
358
|
});
|
|
313
359
|
var filteredTableFormat = null;
|
|
314
360
|
|
|
315
|
-
if (
|
|
361
|
+
if (vizProps.tableFormat) {
|
|
316
362
|
filteredTableFormat = {};
|
|
317
|
-
Object.keys(
|
|
318
|
-
if (Array.isArray(
|
|
319
|
-
filteredTableFormat[tableFormatKey] =
|
|
363
|
+
Object.keys(vizProps.tableFormat).forEach(function (tableFormatKey) {
|
|
364
|
+
if (Array.isArray(vizProps.tableFormat[tableFormatKey])) {
|
|
365
|
+
filteredTableFormat[tableFormatKey] = vizProps.tableFormat[tableFormatKey].filter(function (tableFormatItem, tableFormatItemIndex) {
|
|
320
366
|
return filteredIndexes.indexOf(tableFormatItemIndex) !== -1;
|
|
321
367
|
});
|
|
322
368
|
} else {
|
|
323
|
-
filteredTableFormat[tableFormatKey] =
|
|
369
|
+
filteredTableFormat[tableFormatKey] = vizProps.tableFormat[tableFormatKey];
|
|
324
370
|
}
|
|
325
371
|
});
|
|
326
372
|
}
|
|
327
373
|
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
tableFormat: filteredTableFormat
|
|
332
|
-
});
|
|
374
|
+
vizProps.headers = filteredFields;
|
|
375
|
+
vizProps.table = filteredTable;
|
|
376
|
+
vizProps.tableFormat = filteredTableFormat;
|
|
333
377
|
}
|
|
334
378
|
|
|
335
|
-
return
|
|
379
|
+
return vizProps;
|
|
336
380
|
};
|
|
337
381
|
|
|
338
382
|
exports.computeVizProps = computeVizProps;
|
|
@@ -350,28 +394,28 @@ exports.default = Table;
|
|
|
350
394
|
/***/ 14:
|
|
351
395
|
/***/ (function(module, exports) {
|
|
352
396
|
|
|
353
|
-
module.exports = require("@splunk/visualizations-shared/
|
|
397
|
+
module.exports = require("@splunk/visualizations-shared/schemaUtils");
|
|
354
398
|
|
|
355
399
|
/***/ }),
|
|
356
400
|
|
|
357
401
|
/***/ 15:
|
|
358
402
|
/***/ (function(module, exports) {
|
|
359
403
|
|
|
360
|
-
module.exports = require("@
|
|
404
|
+
module.exports = require("@babel/runtime/helpers/createClass");
|
|
361
405
|
|
|
362
406
|
/***/ }),
|
|
363
407
|
|
|
364
|
-
/***/
|
|
408
|
+
/***/ 16:
|
|
365
409
|
/***/ (function(module, exports) {
|
|
366
410
|
|
|
367
|
-
module.exports = require("@
|
|
411
|
+
module.exports = require("@splunk/visualizations-shared/SizeAwareWrapper");
|
|
368
412
|
|
|
369
413
|
/***/ }),
|
|
370
414
|
|
|
371
|
-
/***/
|
|
415
|
+
/***/ 19:
|
|
372
416
|
/***/ (function(module, exports) {
|
|
373
417
|
|
|
374
|
-
module.exports = require("@splunk/
|
|
418
|
+
module.exports = require("@splunk/themes/variables");
|
|
375
419
|
|
|
376
420
|
/***/ }),
|
|
377
421
|
|
|
@@ -385,7 +429,7 @@ module.exports = require("lodash");
|
|
|
385
429
|
/***/ 20:
|
|
386
430
|
/***/ (function(module, exports) {
|
|
387
431
|
|
|
388
|
-
module.exports = require("@
|
|
432
|
+
module.exports = require("@babel/runtime/helpers/typeof");
|
|
389
433
|
|
|
390
434
|
/***/ }),
|
|
391
435
|
|
|
@@ -397,19 +441,12 @@ module.exports = require("@splunk/themes/pick");
|
|
|
397
441
|
/***/ }),
|
|
398
442
|
|
|
399
443
|
/***/ 23:
|
|
400
|
-
/***/ (function(module, exports) {
|
|
401
|
-
|
|
402
|
-
module.exports = require("@babel/runtime/helpers/typeof");
|
|
403
|
-
|
|
404
|
-
/***/ }),
|
|
405
|
-
|
|
406
|
-
/***/ 24:
|
|
407
444
|
/***/ (function(module, exports, __webpack_require__) {
|
|
408
445
|
|
|
409
446
|
"use strict";
|
|
410
447
|
|
|
411
448
|
|
|
412
|
-
var _defineProperty = __webpack_require__(
|
|
449
|
+
var _defineProperty = __webpack_require__(8);
|
|
413
450
|
|
|
414
451
|
Object.defineProperty(exports, "__esModule", {
|
|
415
452
|
value: true
|
|
@@ -420,7 +457,7 @@ var T = __webpack_require__(0);
|
|
|
420
457
|
|
|
421
458
|
var lodash_1 = __webpack_require__(2);
|
|
422
459
|
|
|
423
|
-
var DataSource_1 = __webpack_require__(
|
|
460
|
+
var DataSource_1 = __webpack_require__(33);
|
|
424
461
|
|
|
425
462
|
exports.SortParamsPropTypes = T.shape({
|
|
426
463
|
currentSortKey: T.string,
|
|
@@ -474,7 +511,161 @@ exports.getSortingParams = getSortingParams;
|
|
|
474
511
|
|
|
475
512
|
/***/ }),
|
|
476
513
|
|
|
477
|
-
/***/
|
|
514
|
+
/***/ 24:
|
|
515
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
516
|
+
|
|
517
|
+
"use strict";
|
|
518
|
+
|
|
519
|
+
|
|
520
|
+
Object.defineProperty(exports, "__esModule", {
|
|
521
|
+
value: true
|
|
522
|
+
});
|
|
523
|
+
exports.getPaginationParams = exports.PaginatorParamsPropTypes = void 0;
|
|
524
|
+
|
|
525
|
+
var T = __webpack_require__(0);
|
|
526
|
+
|
|
527
|
+
var lodash_1 = __webpack_require__(2);
|
|
528
|
+
|
|
529
|
+
exports.PaginatorParamsPropTypes = T.shape({
|
|
530
|
+
isPaging: T.bool,
|
|
531
|
+
current: T.number,
|
|
532
|
+
totalPages: T.number,
|
|
533
|
+
onChange: T.func
|
|
534
|
+
});
|
|
535
|
+
|
|
536
|
+
var getPaginationParams = function getPaginationParams(_ref) {
|
|
537
|
+
var requestParams = _ref.requestParams,
|
|
538
|
+
meta = _ref.meta,
|
|
539
|
+
onRequestParamsChange = _ref.onRequestParamsChange;
|
|
540
|
+
var totalCount = meta && meta.totalCount || 0;
|
|
541
|
+
var offset = requestParams && requestParams.offset || 0;
|
|
542
|
+
var count = requestParams && requestParams.count;
|
|
543
|
+
var totalPages = typeof count === 'number' && count > 0 ? Math.ceil(totalCount / count) : 0;
|
|
544
|
+
var current = typeof count === 'number' && count > 0 ? Math.floor(offset / count) + 1 : 0;
|
|
545
|
+
var isPaging = totalPages > 1 && lodash_1.isFunction(onRequestParamsChange);
|
|
546
|
+
|
|
547
|
+
var onChangeHandler = function onChangeHandler(e, _ref2) {
|
|
548
|
+
var page = _ref2.page,
|
|
549
|
+
countArg = _ref2.count;
|
|
550
|
+
var newParams = lodash_1.cloneDeep(requestParams);
|
|
551
|
+
|
|
552
|
+
if (typeof countArg === 'number') {
|
|
553
|
+
newParams.count = countArg;
|
|
554
|
+
newParams.offset = 0;
|
|
555
|
+
}
|
|
556
|
+
|
|
557
|
+
var pageCount = typeof newParams.count === 'number' ? newParams.count : 10;
|
|
558
|
+
|
|
559
|
+
if (typeof page === 'number' && page > 0) {
|
|
560
|
+
newParams.count = pageCount;
|
|
561
|
+
newParams.offset = (page - 1) * pageCount;
|
|
562
|
+
}
|
|
563
|
+
|
|
564
|
+
onRequestParamsChange(newParams);
|
|
565
|
+
};
|
|
566
|
+
|
|
567
|
+
return {
|
|
568
|
+
isPaging: isPaging,
|
|
569
|
+
current: current,
|
|
570
|
+
totalPages: totalPages,
|
|
571
|
+
onChange: lodash_1.isFunction(onRequestParamsChange) ? onChangeHandler : lodash_1.noop
|
|
572
|
+
};
|
|
573
|
+
};
|
|
574
|
+
|
|
575
|
+
exports.getPaginationParams = getPaginationParams;
|
|
576
|
+
|
|
577
|
+
/***/ }),
|
|
578
|
+
|
|
579
|
+
/***/ 25:
|
|
580
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
581
|
+
|
|
582
|
+
"use strict";
|
|
583
|
+
|
|
584
|
+
|
|
585
|
+
Object.defineProperty(exports, "__esModule", {
|
|
586
|
+
value: true
|
|
587
|
+
});
|
|
588
|
+
exports.shouldShowIconPlaceholder = void 0;
|
|
589
|
+
|
|
590
|
+
var React = __webpack_require__(1);
|
|
591
|
+
|
|
592
|
+
var T = __webpack_require__(0);
|
|
593
|
+
|
|
594
|
+
var lodash_1 = __webpack_require__(2);
|
|
595
|
+
|
|
596
|
+
var i18n_1 = __webpack_require__(3);
|
|
597
|
+
|
|
598
|
+
var Message_1 = __webpack_require__(9);
|
|
599
|
+
|
|
600
|
+
var FixedSizeContainer_1 = __webpack_require__(12);
|
|
601
|
+
/**
|
|
602
|
+
* @method shouldShowIconPlaceholder
|
|
603
|
+
* @param {object} dataSources
|
|
604
|
+
* @param {boolean} loading
|
|
605
|
+
* @returns {boolean}
|
|
606
|
+
*/
|
|
607
|
+
|
|
608
|
+
|
|
609
|
+
var shouldShowIconPlaceholder = function shouldShowIconPlaceholder(dataSources) {
|
|
610
|
+
var loading = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
611
|
+
var data = lodash_1.get(dataSources, 'primary.data.columns[0]', undefined);
|
|
612
|
+
var noData = data === undefined;
|
|
613
|
+
var fields = lodash_1.get(dataSources, 'primary.data.fields[0]', undefined);
|
|
614
|
+
var noFields = fields === undefined;
|
|
615
|
+
return loading || noData || noFields;
|
|
616
|
+
};
|
|
617
|
+
|
|
618
|
+
exports.shouldShowIconPlaceholder = shouldShowIconPlaceholder;
|
|
619
|
+
var propTypes = {
|
|
620
|
+
icon: T.func,
|
|
621
|
+
width: T.oneOfType([T.string, T.number]),
|
|
622
|
+
height: T.oneOfType([T.string, T.number]),
|
|
623
|
+
// eslint-disable-next-line react/no-unused-prop-types
|
|
624
|
+
backgroundColor: T.string
|
|
625
|
+
};
|
|
626
|
+
/**
|
|
627
|
+
* @method IconPlaceholder
|
|
628
|
+
* @param {IconPlaceholderProps} props
|
|
629
|
+
* @returns {React.ReactElement}
|
|
630
|
+
*/
|
|
631
|
+
|
|
632
|
+
var IconPlaceholder = function IconPlaceholder(props) {
|
|
633
|
+
var width = props.width,
|
|
634
|
+
height = props.height,
|
|
635
|
+
icon = props.icon;
|
|
636
|
+
|
|
637
|
+
if (icon) {
|
|
638
|
+
return React.createElement(icon, {
|
|
639
|
+
style: {
|
|
640
|
+
left: '50%',
|
|
641
|
+
top: '50%',
|
|
642
|
+
color: 'grey',
|
|
643
|
+
position: 'absolute',
|
|
644
|
+
transform: 'translate(-50%, -50%)'
|
|
645
|
+
},
|
|
646
|
+
width: '50%',
|
|
647
|
+
height: '50%'
|
|
648
|
+
});
|
|
649
|
+
}
|
|
650
|
+
|
|
651
|
+
return React.createElement(Message_1.default, {
|
|
652
|
+
width: width,
|
|
653
|
+
height: height,
|
|
654
|
+
level: "warning",
|
|
655
|
+
message: i18n_1._('No DataSource Connected')
|
|
656
|
+
});
|
|
657
|
+
};
|
|
658
|
+
|
|
659
|
+
IconPlaceholder.propTypes = propTypes;
|
|
660
|
+
IconPlaceholder.defaultProps = {
|
|
661
|
+
width: '100%',
|
|
662
|
+
height: 250
|
|
663
|
+
};
|
|
664
|
+
exports.default = FixedSizeContainer_1.default(IconPlaceholder);
|
|
665
|
+
|
|
666
|
+
/***/ }),
|
|
667
|
+
|
|
668
|
+
/***/ 255:
|
|
478
669
|
/***/ (function(module, exports, __webpack_require__) {
|
|
479
670
|
|
|
480
671
|
"use strict";
|
|
@@ -506,9 +697,9 @@ exports.default = void 0; // NOTE: wildcard syntax only works for named exports
|
|
|
506
697
|
// for some reason, omitting the default export worked before TS v4
|
|
507
698
|
// see: https://stackoverflow.com/a/34445175
|
|
508
699
|
|
|
509
|
-
__exportStar(__webpack_require__(
|
|
700
|
+
__exportStar(__webpack_require__(131), exports);
|
|
510
701
|
|
|
511
|
-
var Table_1 = __webpack_require__(
|
|
702
|
+
var Table_1 = __webpack_require__(131);
|
|
512
703
|
|
|
513
704
|
Object.defineProperty(exports, "default", {
|
|
514
705
|
enumerable: true,
|
|
@@ -519,13 +710,13 @@ Object.defineProperty(exports, "default", {
|
|
|
519
710
|
|
|
520
711
|
/***/ }),
|
|
521
712
|
|
|
522
|
-
/***/
|
|
713
|
+
/***/ 256:
|
|
523
714
|
/***/ (function(module, exports, __webpack_require__) {
|
|
524
715
|
|
|
525
716
|
"use strict";
|
|
526
717
|
|
|
527
718
|
|
|
528
|
-
var _toConsumableArray = __webpack_require__(
|
|
719
|
+
var _toConsumableArray = __webpack_require__(39);
|
|
529
720
|
|
|
530
721
|
Object.defineProperty(exports, "__esModule", {
|
|
531
722
|
value: true
|
|
@@ -535,13 +726,13 @@ var i18n_1 = __webpack_require__(3);
|
|
|
535
726
|
|
|
536
727
|
var lodash_1 = __webpack_require__(2);
|
|
537
728
|
|
|
538
|
-
var schemaUtils_1 = __webpack_require__(
|
|
729
|
+
var schemaUtils_1 = __webpack_require__(14);
|
|
539
730
|
|
|
540
|
-
var colorConstants_1 = __webpack_require__(
|
|
731
|
+
var colorConstants_1 = __webpack_require__(40);
|
|
541
732
|
|
|
542
|
-
var visualization_icons_1 = __webpack_require__(
|
|
733
|
+
var visualization_icons_1 = __webpack_require__(42);
|
|
543
734
|
|
|
544
|
-
var variables_1 = __webpack_require__(
|
|
735
|
+
var variables_1 = __webpack_require__(19);
|
|
545
736
|
|
|
546
737
|
var pick_1 = __webpack_require__(21);
|
|
547
738
|
|
|
@@ -551,7 +742,7 @@ var VizBehavior_1 = __webpack_require__(5);
|
|
|
551
742
|
|
|
552
743
|
var consts_1 = __webpack_require__(105);
|
|
553
744
|
|
|
554
|
-
var VizCategory_1 = __webpack_require__(
|
|
745
|
+
var VizCategory_1 = __webpack_require__(26);
|
|
555
746
|
|
|
556
747
|
var dataContract = {
|
|
557
748
|
requiredDataSources: [{
|
|
@@ -685,6 +876,10 @@ var sequentialColorConfig = [{
|
|
|
685
876
|
from: 80,
|
|
686
877
|
value: '#118832'
|
|
687
878
|
}];
|
|
879
|
+
var matchColorConfig = [{
|
|
880
|
+
match: '',
|
|
881
|
+
value: '#5C33FF'
|
|
882
|
+
}];
|
|
688
883
|
var optionsSchema = {
|
|
689
884
|
backgroundColor: {
|
|
690
885
|
default: '> themes.defaultBackgroundColor',
|
|
@@ -780,7 +975,8 @@ var optionsSchema = {
|
|
|
780
975
|
},
|
|
781
976
|
width: {
|
|
782
977
|
description: 'Controls how wide in pixels (where 1px = 1/96th of 1in) the column should be displayed.',
|
|
783
|
-
type: 'number'
|
|
978
|
+
type: 'number',
|
|
979
|
+
minimum: 30
|
|
784
980
|
}
|
|
785
981
|
}
|
|
786
982
|
}
|
|
@@ -1094,6 +1290,13 @@ var editorConfig = [{
|
|
|
1094
1290
|
rowBackgroundColors: sequentialColorConfig,
|
|
1095
1291
|
rowColors: sequentialColorConfig
|
|
1096
1292
|
}
|
|
1293
|
+
}, {
|
|
1294
|
+
label: i18n_1._('Matches'),
|
|
1295
|
+
value: 'matchValue',
|
|
1296
|
+
defaults: {
|
|
1297
|
+
rowBackgroundColors: matchColorConfig,
|
|
1298
|
+
rowColors: matchColorConfig
|
|
1299
|
+
}
|
|
1097
1300
|
}],
|
|
1098
1301
|
themes: themes
|
|
1099
1302
|
},
|
|
@@ -1183,12 +1386,14 @@ exports.default = configUtils_1.enhanceConfig(config);
|
|
|
1183
1386
|
|
|
1184
1387
|
/***/ }),
|
|
1185
1388
|
|
|
1186
|
-
/***/
|
|
1389
|
+
/***/ 257:
|
|
1187
1390
|
/***/ (function(module, exports, __webpack_require__) {
|
|
1188
1391
|
|
|
1189
1392
|
"use strict";
|
|
1190
1393
|
|
|
1191
1394
|
|
|
1395
|
+
var _slicedToArray = __webpack_require__(48);
|
|
1396
|
+
|
|
1192
1397
|
var _taggedTemplateLiteral = __webpack_require__(101);
|
|
1193
1398
|
|
|
1194
1399
|
var _templateObject, _templateObject2;
|
|
@@ -1220,43 +1425,52 @@ var styled_components_1 = __webpack_require__(4);
|
|
|
1220
1425
|
|
|
1221
1426
|
var i18n_1 = __webpack_require__(3);
|
|
1222
1427
|
|
|
1223
|
-
var Table_1 = __webpack_require__(
|
|
1428
|
+
var Table_1 = __webpack_require__(82);
|
|
1224
1429
|
|
|
1225
|
-
var Paginator_1 = __webpack_require__(
|
|
1430
|
+
var Paginator_1 = __webpack_require__(258);
|
|
1226
1431
|
|
|
1227
|
-
var Message_1 = __webpack_require__(
|
|
1432
|
+
var Message_1 = __webpack_require__(259);
|
|
1228
1433
|
|
|
1229
1434
|
var colorUtils_1 = __webpack_require__(11);
|
|
1230
1435
|
|
|
1231
|
-
var style_1 = __webpack_require__(
|
|
1436
|
+
var style_1 = __webpack_require__(13);
|
|
1232
1437
|
|
|
1233
1438
|
var pick_1 = __webpack_require__(21);
|
|
1234
1439
|
|
|
1235
|
-
var variables_1 = __webpack_require__(
|
|
1440
|
+
var variables_1 = __webpack_require__(19);
|
|
1236
1441
|
|
|
1237
|
-
var hooks_1 = __webpack_require__(
|
|
1442
|
+
var hooks_1 = __webpack_require__(260);
|
|
1238
1443
|
|
|
1239
1444
|
var consts_1 = __webpack_require__(105);
|
|
1240
1445
|
|
|
1241
|
-
var cells_1 = __webpack_require__(
|
|
1446
|
+
var cells_1 = __webpack_require__(261);
|
|
1242
1447
|
|
|
1243
|
-
var getPagination_1 = __webpack_require__(
|
|
1448
|
+
var getPagination_1 = __webpack_require__(24);
|
|
1244
1449
|
|
|
1245
|
-
var getSorting_1 = __webpack_require__(
|
|
1450
|
+
var getSorting_1 = __webpack_require__(23);
|
|
1246
1451
|
|
|
1247
1452
|
var FixedSizeContainer_1 = __webpack_require__(12); // debounce was imported this way due to typing
|
|
1248
1453
|
// eslint-disable-next-line import/order
|
|
1249
1454
|
|
|
1250
1455
|
|
|
1251
|
-
var debounce = __webpack_require__(
|
|
1456
|
+
var debounce = __webpack_require__(266);
|
|
1252
1457
|
|
|
1253
|
-
var
|
|
1254
|
-
|
|
1458
|
+
var MINIMUM_COLUMN_SIZE = 30;
|
|
1459
|
+
var StyledTableHead = styled_components_1.default(Table_1.default.Head).withConfig({
|
|
1460
|
+
displayName: "PureTable__StyledTableHead",
|
|
1255
1461
|
componentId: "tovzjg-0"
|
|
1462
|
+
})(["& > tr > th:last-child > div > button{display:none;}"]);
|
|
1463
|
+
var NonVisibleTableHead = styled_components_1.default(StyledTableHead).withConfig({
|
|
1464
|
+
displayName: "PureTable__NonVisibleTableHead",
|
|
1465
|
+
componentId: "tovzjg-1"
|
|
1256
1466
|
})(["display:none;"]);
|
|
1467
|
+
var FixedTableHead = styled_components_1.default(StyledTableHead).withConfig({
|
|
1468
|
+
displayName: "PureTable__FixedTableHead",
|
|
1469
|
+
componentId: "tovzjg-2"
|
|
1470
|
+
})(["position:sticky;top:0;"]);
|
|
1257
1471
|
var VizTableContainer = styled_components_1.default.div.withConfig({
|
|
1258
1472
|
displayName: "PureTable__VizTableContainer",
|
|
1259
|
-
componentId: "tovzjg-
|
|
1473
|
+
componentId: "tovzjg-3"
|
|
1260
1474
|
})(["box-sizing:border-box;padding:", ";background-color:", ";display:flex;flex-flow:column nowrap;overflow:hidden;"], pick_1.default({
|
|
1261
1475
|
enterprise: variables_1.default.spacingHalf,
|
|
1262
1476
|
prisma: variables_1.default.spacingSmall
|
|
@@ -1268,7 +1482,7 @@ var PAGINATOR_CONTAINER_HEIGHT = 38;
|
|
|
1268
1482
|
var PAGINATOR_SPACING = 5;
|
|
1269
1483
|
var SUITableContainer = styled_components_1.default.div.withConfig({
|
|
1270
1484
|
displayName: "PureTable__SUITableContainer",
|
|
1271
|
-
componentId: "tovzjg-
|
|
1485
|
+
componentId: "tovzjg-4"
|
|
1272
1486
|
})(["box-sizing:border-box;flex-grow:1;overflow:hidden;", ";", ";", " ", ""], function (_ref) {
|
|
1273
1487
|
var width = _ref.width,
|
|
1274
1488
|
height = _ref.height,
|
|
@@ -1302,7 +1516,7 @@ var SUITableContainer = styled_components_1.default.div.withConfig({
|
|
|
1302
1516
|
SUITableContainer.displayName = 'SUITableContainer';
|
|
1303
1517
|
var PaginatorContainer = styled_components_1.default.div.withConfig({
|
|
1304
1518
|
displayName: "PureTable__PaginatorContainer",
|
|
1305
|
-
componentId: "tovzjg-
|
|
1519
|
+
componentId: "tovzjg-5"
|
|
1306
1520
|
})(["position:relative;text-align:right;height:", "px;"], PAGINATOR_CONTAINER_HEIGHT);
|
|
1307
1521
|
PaginatorContainer.displayName = 'PaginatorContainer'; // allow for early return in case of empty tableBody while still following hook rules
|
|
1308
1522
|
|
|
@@ -1349,6 +1563,20 @@ var withEmptyTableMessage = function withEmptyTableMessage(Viz) {
|
|
|
1349
1563
|
return Wrapper;
|
|
1350
1564
|
};
|
|
1351
1565
|
|
|
1566
|
+
var useTableHead = function useTableHead(visibility, mode) {
|
|
1567
|
+
if (visibility === 'none') {
|
|
1568
|
+
return NonVisibleTableHead;
|
|
1569
|
+
} // @TODO
|
|
1570
|
+
// Stacking context conflicts with editModeCover; temporary fix
|
|
1571
|
+
|
|
1572
|
+
|
|
1573
|
+
if (visibility === 'fixed' && mode === 'view') {
|
|
1574
|
+
return FixedTableHead;
|
|
1575
|
+
}
|
|
1576
|
+
|
|
1577
|
+
return StyledTableHead;
|
|
1578
|
+
};
|
|
1579
|
+
|
|
1352
1580
|
var PureTable = function PureTable(props) {
|
|
1353
1581
|
var count = props.count,
|
|
1354
1582
|
width = props.width,
|
|
@@ -1364,7 +1592,16 @@ var PureTable = function PureTable(props) {
|
|
|
1364
1592
|
_a = props.paginatorParams,
|
|
1365
1593
|
isPaging = _a.isPaging,
|
|
1366
1594
|
paginatorProps = __rest(_a, ["isPaging"]),
|
|
1367
|
-
onCellClick = props.onCellClick
|
|
1595
|
+
onCellClick = props.onCellClick,
|
|
1596
|
+
onColumnFormatChange = props.onColumnFormatChange,
|
|
1597
|
+
columnFormat = props.columnFormat,
|
|
1598
|
+
mode = props.mode,
|
|
1599
|
+
headerVisibility = props.headerVisibility;
|
|
1600
|
+
|
|
1601
|
+
var _React$useState = React.useState(columnFormat),
|
|
1602
|
+
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
1603
|
+
columns = _React$useState2[0],
|
|
1604
|
+
setColumns = _React$useState2[1];
|
|
1368
1605
|
|
|
1369
1606
|
var firstRenderCount = React.useRef(count);
|
|
1370
1607
|
React.useEffect(function () {
|
|
@@ -1375,7 +1612,11 @@ var PureTable = function PureTable(props) {
|
|
|
1375
1612
|
});
|
|
1376
1613
|
}
|
|
1377
1614
|
}, [count, paginatorProps]);
|
|
1378
|
-
var
|
|
1615
|
+
var stringifiedColumnFormat = JSON.stringify(columnFormat);
|
|
1616
|
+
React.useEffect(function () {
|
|
1617
|
+
setColumns(columnFormat);
|
|
1618
|
+
}, [mode, stringifiedColumnFormat]);
|
|
1619
|
+
var TableHead = useTableHead(headerVisibility, mode);
|
|
1379
1620
|
var debouncedDrilldown = debounce(function (e, payload) {
|
|
1380
1621
|
if (window.getSelection().toString() === '') {
|
|
1381
1622
|
if (lodash_1.isFunction(onCellClick)) {
|
|
@@ -1427,6 +1668,47 @@ var PureTable = function PureTable(props) {
|
|
|
1427
1668
|
debouncedDrilldown(e.nativeEvent, payload);
|
|
1428
1669
|
}
|
|
1429
1670
|
}, [onCellClick, showRowNumbers, tableHeader, tableBody]);
|
|
1671
|
+
var debouncedOnColumnFormatChange = React.useMemo(function () {
|
|
1672
|
+
return debounce(function (newFormat) {
|
|
1673
|
+
onColumnFormatChange(newFormat);
|
|
1674
|
+
}, 300);
|
|
1675
|
+
}, [onColumnFormatChange]);
|
|
1676
|
+
|
|
1677
|
+
var sumColumnWidths = function sumColumnWidths(allColumns) {
|
|
1678
|
+
return Object.keys(allColumns).reduce(function (prev, key) {
|
|
1679
|
+
var _a, _b, _c;
|
|
1680
|
+
|
|
1681
|
+
if (((_a = allColumns[key]) === null || _a === void 0 ? void 0 : _a.width) === 'auto' || ((_b = allColumns[key]) === null || _b === void 0 ? void 0 : _b.width) === undefined) {
|
|
1682
|
+
return prev + MINIMUM_COLUMN_SIZE; // Columns with no width defined are automatically size 30
|
|
1683
|
+
}
|
|
1684
|
+
|
|
1685
|
+
return prev + ((_c = allColumns[key]) === null || _c === void 0 ? void 0 : _c.width);
|
|
1686
|
+
}, 0) + // Add all remaining columns that do not have a columnFormat
|
|
1687
|
+
(tableHeader.cells.length - Object.keys(allColumns).length) * MINIMUM_COLUMN_SIZE;
|
|
1688
|
+
};
|
|
1689
|
+
|
|
1690
|
+
var handleResizeColumn = React.useCallback(function (_event, payload) {
|
|
1691
|
+
var updatedCF = lodash_1.cloneDeep(columns);
|
|
1692
|
+
var field = payload.columnId.split('-')[1];
|
|
1693
|
+
updatedCF[field] = Object.assign(Object.assign({}, updatedCF[field]), {
|
|
1694
|
+
width: Math.max(payload.width, MINIMUM_COLUMN_SIZE)
|
|
1695
|
+
}); // Prevent the user from expanding the columns too far
|
|
1696
|
+
|
|
1697
|
+
if (sumColumnWidths(updatedCF) > width) {
|
|
1698
|
+
return;
|
|
1699
|
+
}
|
|
1700
|
+
|
|
1701
|
+
setColumns(updatedCF); // Updates column json in edit mode
|
|
1702
|
+
|
|
1703
|
+
if (mode === 'edit') {
|
|
1704
|
+
debouncedOnColumnFormatChange(updatedCF);
|
|
1705
|
+
}
|
|
1706
|
+
}, [mode, columns, width, debouncedOnColumnFormatChange]);
|
|
1707
|
+
|
|
1708
|
+
var handleEventClick = function handleEventClick(e) {
|
|
1709
|
+
e.stopPropagation();
|
|
1710
|
+
};
|
|
1711
|
+
|
|
1430
1712
|
return React.createElement(VizTableContainer, {
|
|
1431
1713
|
backgroundColor: backgroundColor
|
|
1432
1714
|
}, React.createElement(SUITableContainer, {
|
|
@@ -1435,7 +1717,7 @@ var PureTable = function PureTable(props) {
|
|
|
1435
1717
|
isPaging: isPaging,
|
|
1436
1718
|
headerStyle: tableHeader.style
|
|
1437
1719
|
}, React.createElement(Table_1.default, {
|
|
1438
|
-
headType: tableHeader.visibility !== 'none' ?
|
|
1720
|
+
headType: tableHeader.visibility !== 'none' ? 'inline' : undefined,
|
|
1439
1721
|
innerStyle: {
|
|
1440
1722
|
height: '100%'
|
|
1441
1723
|
},
|
|
@@ -1443,8 +1725,12 @@ var PureTable = function PureTable(props) {
|
|
|
1443
1725
|
height: '100%',
|
|
1444
1726
|
cursor: onCellClick ? 'pointer' : 'unset'
|
|
1445
1727
|
},
|
|
1446
|
-
onClick: onCellClick ? drilldownHandler : lodash_1.noop
|
|
1728
|
+
onClick: onCellClick ? drilldownHandler : lodash_1.noop,
|
|
1729
|
+
onRequestResizeColumn: handleResizeColumn,
|
|
1730
|
+
resizableFillLayout: true
|
|
1447
1731
|
}, React.createElement(TableHead, null, tableHeader.cells.map(function (_a) {
|
|
1732
|
+
var _b;
|
|
1733
|
+
|
|
1448
1734
|
var key = _a.key,
|
|
1449
1735
|
value = _a.value,
|
|
1450
1736
|
sortKey = _a.sortKey,
|
|
@@ -1452,7 +1738,10 @@ var PureTable = function PureTable(props) {
|
|
|
1452
1738
|
|
|
1453
1739
|
return React.createElement(Table_1.default.HeadCell, Object.assign({
|
|
1454
1740
|
key: key,
|
|
1455
|
-
|
|
1741
|
+
columnId: key,
|
|
1742
|
+
sortDir: sortKey === currentSortKey ? currentSortDir : 'none',
|
|
1743
|
+
width: ((_b = columns[value]) === null || _b === void 0 ? void 0 : _b.width) || 'auto',
|
|
1744
|
+
onMouseDown: handleEventClick
|
|
1456
1745
|
}, Object.assign({
|
|
1457
1746
|
sortKey: sortKey,
|
|
1458
1747
|
onSort: onSort
|
|
@@ -1461,18 +1750,23 @@ var PureTable = function PureTable(props) {
|
|
|
1461
1750
|
return React.createElement(Table_1.default.Row, {
|
|
1462
1751
|
key: row.key
|
|
1463
1752
|
}, row.cells.map(function (cell) {
|
|
1753
|
+
var _a, _b, _c;
|
|
1754
|
+
|
|
1464
1755
|
return React.createElement(cells_1.SwitchTableCell, {
|
|
1465
1756
|
key: cell.key,
|
|
1466
1757
|
type: cell.cellType
|
|
1467
1758
|
}, React.createElement(cells_1.TextCell, {
|
|
1468
1759
|
cell: cell,
|
|
1469
|
-
useMouseOverEffect: !!onCellClick
|
|
1760
|
+
useMouseOverEffect: !!onCellClick,
|
|
1761
|
+
width: ((_a = columns[cell.header]) === null || _a === void 0 ? void 0 : _a.width) || 'auto'
|
|
1470
1762
|
}), React.createElement(cells_1.SparklineCell, {
|
|
1471
1763
|
cell: cell,
|
|
1472
|
-
useMouseOverEffect: !!onCellClick
|
|
1764
|
+
useMouseOverEffect: !!onCellClick,
|
|
1765
|
+
width: ((_b = columns[cell.header]) === null || _b === void 0 ? void 0 : _b.width) || 'auto'
|
|
1473
1766
|
}), React.createElement(cells_1.ArrayCell, {
|
|
1474
1767
|
cell: cell,
|
|
1475
|
-
useMouseOverEffect: !!onCellClick
|
|
1768
|
+
useMouseOverEffect: !!onCellClick,
|
|
1769
|
+
width: ((_c = columns[cell.header]) === null || _c === void 0 ? void 0 : _c.width) || 'auto'
|
|
1476
1770
|
}));
|
|
1477
1771
|
}));
|
|
1478
1772
|
})))), isPaging ? React.createElement(PaginatorContainer, null, React.createElement(Paginator_1.default, Object.assign({}, paginatorProps))) : null);
|
|
@@ -1514,7 +1808,8 @@ PureTable.propTypes = {
|
|
|
1514
1808
|
sparklineTypes: T.arrayOf(T.arrayOf(T.oneOf(consts_1.validSparklineTypes)))
|
|
1515
1809
|
}),
|
|
1516
1810
|
theme: T.any,
|
|
1517
|
-
width: T.oneOfType([T.number])
|
|
1811
|
+
width: T.oneOfType([T.number]),
|
|
1812
|
+
onColumnFormatChange: T.func
|
|
1518
1813
|
};
|
|
1519
1814
|
PureTable.defaultProps = {
|
|
1520
1815
|
columnFormat: {},
|
|
@@ -1534,57 +1829,84 @@ PureTable.defaultProps = {
|
|
|
1534
1829
|
table: [],
|
|
1535
1830
|
tableFormat: {},
|
|
1536
1831
|
theme: {},
|
|
1537
|
-
width: 300
|
|
1832
|
+
width: 300,
|
|
1833
|
+
onColumnFormatChange: lodash_1.noop
|
|
1538
1834
|
};
|
|
1539
1835
|
PureTable.displayName = 'VizTable';
|
|
1540
1836
|
exports.default = withEmptyTableMessage(FixedSizeContainer_1.default(PureTable));
|
|
1541
1837
|
|
|
1542
1838
|
/***/ }),
|
|
1543
1839
|
|
|
1544
|
-
/***/
|
|
1840
|
+
/***/ 258:
|
|
1545
1841
|
/***/ (function(module, exports) {
|
|
1546
1842
|
|
|
1547
1843
|
module.exports = require("@splunk/react-ui/Paginator");
|
|
1548
1844
|
|
|
1549
1845
|
/***/ }),
|
|
1550
1846
|
|
|
1551
|
-
/***/
|
|
1847
|
+
/***/ 259:
|
|
1552
1848
|
/***/ (function(module, exports) {
|
|
1553
1849
|
|
|
1554
1850
|
module.exports = require("@splunk/react-ui/Message");
|
|
1555
1851
|
|
|
1556
1852
|
/***/ }),
|
|
1557
1853
|
|
|
1558
|
-
/***/
|
|
1854
|
+
/***/ 26:
|
|
1559
1855
|
/***/ (function(module, exports, __webpack_require__) {
|
|
1560
1856
|
|
|
1561
1857
|
"use strict";
|
|
1562
1858
|
|
|
1563
1859
|
|
|
1564
|
-
var _toConsumableArray = __webpack_require__(40);
|
|
1565
|
-
|
|
1566
|
-
var _typeof = __webpack_require__(23);
|
|
1567
|
-
|
|
1568
1860
|
Object.defineProperty(exports, "__esModule", {
|
|
1569
1861
|
value: true
|
|
1570
1862
|
});
|
|
1571
|
-
exports.
|
|
1572
|
-
|
|
1573
|
-
|
|
1574
|
-
|
|
1575
|
-
|
|
1576
|
-
|
|
1577
|
-
|
|
1578
|
-
|
|
1579
|
-
|
|
1863
|
+
exports.VizCategory = void 0;
|
|
1864
|
+
var VizCategory;
|
|
1865
|
+
|
|
1866
|
+
(function (VizCategory) {
|
|
1867
|
+
VizCategory["SINGLE_VALUE"] = "Single Value";
|
|
1868
|
+
VizCategory["TRENDS"] = "Trends";
|
|
1869
|
+
VizCategory["COMPARISONS"] = "Comparisons";
|
|
1870
|
+
VizCategory["TABLE"] = "Table";
|
|
1871
|
+
VizCategory["GAUGE"] = "Gauge";
|
|
1872
|
+
VizCategory["DISTRIBUTIONS"] = "Distributions";
|
|
1873
|
+
VizCategory["CHOROPLETH"] = "Choropleth Maps";
|
|
1874
|
+
VizCategory["SHAPES"] = "Shapes";
|
|
1875
|
+
VizCategory["MISC"] = "misc";
|
|
1876
|
+
VizCategory["FLOW"] = "Flow";
|
|
1877
|
+
VizCategory["CORRELATION"] = "Correlation";
|
|
1878
|
+
VizCategory["SPATIAL"] = "Spatial";
|
|
1879
|
+
})(VizCategory = exports.VizCategory || (exports.VizCategory = {}));
|
|
1880
|
+
|
|
1881
|
+
/***/ }),
|
|
1882
|
+
|
|
1883
|
+
/***/ 260:
|
|
1884
|
+
/***/ (function(module, exports, __webpack_require__) {
|
|
1885
|
+
|
|
1886
|
+
"use strict";
|
|
1887
|
+
|
|
1888
|
+
|
|
1889
|
+
var _toConsumableArray = __webpack_require__(39);
|
|
1890
|
+
|
|
1891
|
+
var _typeof = __webpack_require__(20);
|
|
1892
|
+
|
|
1893
|
+
Object.defineProperty(exports, "__esModule", {
|
|
1894
|
+
value: true
|
|
1895
|
+
});
|
|
1896
|
+
exports.useTable = exports.getTextOverflowType = exports.getOverflowStyles = void 0;
|
|
1897
|
+
|
|
1898
|
+
var lodash_1 = __webpack_require__(2);
|
|
1899
|
+
|
|
1900
|
+
var colorUtils_1 = __webpack_require__(11);
|
|
1901
|
+
|
|
1902
|
+
var consts_1 = __webpack_require__(105);
|
|
1580
1903
|
|
|
1581
1904
|
var isArray = function isArray(v) {
|
|
1582
1905
|
return Array.isArray(v);
|
|
1583
1906
|
};
|
|
1584
1907
|
|
|
1585
1908
|
var getOverflowStyles = function getOverflowStyles(_ref) {
|
|
1586
|
-
var textOverflow = _ref.textOverflow
|
|
1587
|
-
variables = _ref.variables;
|
|
1909
|
+
var textOverflow = _ref.textOverflow;
|
|
1588
1910
|
var styles = {
|
|
1589
1911
|
anywhere: {
|
|
1590
1912
|
wordBreak: 'break-all'
|
|
@@ -1595,7 +1917,6 @@ var getOverflowStyles = function getOverflowStyles(_ref) {
|
|
|
1595
1917
|
overflowWrap: 'break-word'
|
|
1596
1918
|
},
|
|
1597
1919
|
ellipsis: {
|
|
1598
|
-
maxWidth: style_1.toPx(variables && variables.width || 100),
|
|
1599
1920
|
whiteSpace: 'nowrap',
|
|
1600
1921
|
overflow: 'hidden',
|
|
1601
1922
|
textOverflow: 'ellipsis'
|
|
@@ -1629,12 +1950,8 @@ var generateHeader = function generateHeader(value, i, columnFormat) {
|
|
|
1629
1950
|
if (lodash_1.isNumber(columnWidth)) {
|
|
1630
1951
|
var textOverflowType = exports.getTextOverflowType({}, value, 'ellipsis');
|
|
1631
1952
|
var textOverflowStyle = exports.getOverflowStyles({
|
|
1632
|
-
textOverflow: textOverflowType
|
|
1633
|
-
variables: {
|
|
1634
|
-
width: columnWidth
|
|
1635
|
-
}
|
|
1953
|
+
textOverflow: textOverflowType
|
|
1636
1954
|
});
|
|
1637
|
-
ret.width = columnWidth;
|
|
1638
1955
|
ret.truncate = true;
|
|
1639
1956
|
ret.style = textOverflowStyle;
|
|
1640
1957
|
}
|
|
@@ -1916,6 +2233,8 @@ var useTable = function useTable() {
|
|
|
1916
2233
|
cells: []
|
|
1917
2234
|
};
|
|
1918
2235
|
table.forEach(function (column, i) {
|
|
2236
|
+
var _a;
|
|
2237
|
+
|
|
1919
2238
|
var currentHeader = tableHeader.cells[i];
|
|
1920
2239
|
var value = validValueSelector(getColumnFormatData(columnFormat, currentHeader, currentRow), getTableFormatData(tableFormat, i, currentRow), column[currentRow], '');
|
|
1921
2240
|
var rawValue = column[currentRow];
|
|
@@ -1929,17 +2248,12 @@ var useTable = function useTable() {
|
|
|
1929
2248
|
var key = generateKey(value, "".concat(currentRow, "-").concat(i));
|
|
1930
2249
|
var additionalStyles = {};
|
|
1931
2250
|
|
|
1932
|
-
if (lodash_1.isNumber(currentHeader.width)) {
|
|
2251
|
+
if (lodash_1.isNumber((_a = columnFormat[currentHeader.value]) === null || _a === void 0 ? void 0 : _a.width)) {
|
|
1933
2252
|
var textOverflowType = exports.getTextOverflowType(columnFormat, currentHeader.value, 'ellipsis');
|
|
1934
2253
|
var textOverflowStyle = exports.getOverflowStyles({
|
|
1935
|
-
textOverflow: textOverflowType
|
|
1936
|
-
variables: {
|
|
1937
|
-
width: currentHeader.width
|
|
1938
|
-
}
|
|
1939
|
-
});
|
|
1940
|
-
additionalStyles = Object.assign(Object.assign(Object.assign({}, additionalStyles), textOverflowStyle), {
|
|
1941
|
-
width: style_1.toPx(currentHeader.width)
|
|
2254
|
+
textOverflow: textOverflowType
|
|
1942
2255
|
});
|
|
2256
|
+
additionalStyles = Object.assign(Object.assign({}, additionalStyles), textOverflowStyle);
|
|
1943
2257
|
}
|
|
1944
2258
|
|
|
1945
2259
|
row.cells.push({
|
|
@@ -1953,6 +2267,7 @@ var useTable = function useTable() {
|
|
|
1953
2267
|
sparklineColor: sparklineColor,
|
|
1954
2268
|
sparklineAreaColor: sparklineAreaColor,
|
|
1955
2269
|
sparklineType: sparklineType,
|
|
2270
|
+
header: currentHeader.value,
|
|
1956
2271
|
style: Object.assign({
|
|
1957
2272
|
backgroundColor: rowBackgroundColor,
|
|
1958
2273
|
color: rowColor
|
|
@@ -1976,72 +2291,7 @@ exports.useTable = useTable;
|
|
|
1976
2291
|
|
|
1977
2292
|
/***/ }),
|
|
1978
2293
|
|
|
1979
|
-
/***/
|
|
1980
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
1981
|
-
|
|
1982
|
-
"use strict";
|
|
1983
|
-
|
|
1984
|
-
|
|
1985
|
-
Object.defineProperty(exports, "__esModule", {
|
|
1986
|
-
value: true
|
|
1987
|
-
});
|
|
1988
|
-
exports.getPaginationParams = exports.PaginatorParamsPropTypes = void 0;
|
|
1989
|
-
|
|
1990
|
-
var T = __webpack_require__(0);
|
|
1991
|
-
|
|
1992
|
-
var lodash_1 = __webpack_require__(2);
|
|
1993
|
-
|
|
1994
|
-
exports.PaginatorParamsPropTypes = T.shape({
|
|
1995
|
-
isPaging: T.bool,
|
|
1996
|
-
current: T.number,
|
|
1997
|
-
totalPages: T.number,
|
|
1998
|
-
onChange: T.func
|
|
1999
|
-
});
|
|
2000
|
-
|
|
2001
|
-
var getPaginationParams = function getPaginationParams(_ref) {
|
|
2002
|
-
var requestParams = _ref.requestParams,
|
|
2003
|
-
meta = _ref.meta,
|
|
2004
|
-
onRequestParamsChange = _ref.onRequestParamsChange;
|
|
2005
|
-
var totalCount = meta && meta.totalCount || 0;
|
|
2006
|
-
var offset = requestParams && requestParams.offset || 0;
|
|
2007
|
-
var count = requestParams && requestParams.count;
|
|
2008
|
-
var totalPages = typeof count === 'number' && count > 0 ? Math.ceil(totalCount / count) : 0;
|
|
2009
|
-
var current = typeof count === 'number' && count > 0 ? Math.floor(offset / count) + 1 : 0;
|
|
2010
|
-
var isPaging = totalPages > 1 && lodash_1.isFunction(onRequestParamsChange);
|
|
2011
|
-
|
|
2012
|
-
var onChangeHandler = function onChangeHandler(e, _ref2) {
|
|
2013
|
-
var page = _ref2.page,
|
|
2014
|
-
countArg = _ref2.count;
|
|
2015
|
-
var newParams = lodash_1.cloneDeep(requestParams);
|
|
2016
|
-
|
|
2017
|
-
if (typeof countArg === 'number') {
|
|
2018
|
-
newParams.count = countArg;
|
|
2019
|
-
newParams.offset = 0;
|
|
2020
|
-
}
|
|
2021
|
-
|
|
2022
|
-
var pageCount = typeof newParams.count === 'number' ? newParams.count : 10;
|
|
2023
|
-
|
|
2024
|
-
if (typeof page === 'number' && page > 0) {
|
|
2025
|
-
newParams.count = pageCount;
|
|
2026
|
-
newParams.offset = (page - 1) * pageCount;
|
|
2027
|
-
}
|
|
2028
|
-
|
|
2029
|
-
onRequestParamsChange(newParams);
|
|
2030
|
-
};
|
|
2031
|
-
|
|
2032
|
-
return {
|
|
2033
|
-
isPaging: isPaging,
|
|
2034
|
-
current: current,
|
|
2035
|
-
totalPages: totalPages,
|
|
2036
|
-
onChange: lodash_1.isFunction(onRequestParamsChange) ? onChangeHandler : lodash_1.noop
|
|
2037
|
-
};
|
|
2038
|
-
};
|
|
2039
|
-
|
|
2040
|
-
exports.getPaginationParams = getPaginationParams;
|
|
2041
|
-
|
|
2042
|
-
/***/ }),
|
|
2043
|
-
|
|
2044
|
-
/***/ 250:
|
|
2294
|
+
/***/ 261:
|
|
2045
2295
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2046
2296
|
|
|
2047
2297
|
"use strict";
|
|
@@ -2070,17 +2320,17 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
2070
2320
|
value: true
|
|
2071
2321
|
});
|
|
2072
2322
|
|
|
2073
|
-
__exportStar(__webpack_require__(
|
|
2323
|
+
__exportStar(__webpack_require__(262), exports);
|
|
2074
2324
|
|
|
2075
|
-
__exportStar(__webpack_require__(
|
|
2325
|
+
__exportStar(__webpack_require__(263), exports);
|
|
2076
2326
|
|
|
2077
|
-
__exportStar(__webpack_require__(
|
|
2327
|
+
__exportStar(__webpack_require__(264), exports);
|
|
2078
2328
|
|
|
2079
|
-
__exportStar(__webpack_require__(
|
|
2329
|
+
__exportStar(__webpack_require__(265), exports);
|
|
2080
2330
|
|
|
2081
2331
|
/***/ }),
|
|
2082
2332
|
|
|
2083
|
-
/***/
|
|
2333
|
+
/***/ 262:
|
|
2084
2334
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2085
2335
|
|
|
2086
2336
|
"use strict";
|
|
@@ -2103,7 +2353,7 @@ exports.SwitchTableCell = SwitchTableCell;
|
|
|
2103
2353
|
|
|
2104
2354
|
/***/ }),
|
|
2105
2355
|
|
|
2106
|
-
/***/
|
|
2356
|
+
/***/ 263:
|
|
2107
2357
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2108
2358
|
|
|
2109
2359
|
"use strict";
|
|
@@ -2116,13 +2366,16 @@ exports.TextCell = void 0;
|
|
|
2116
2366
|
|
|
2117
2367
|
var React = __webpack_require__(1);
|
|
2118
2368
|
|
|
2119
|
-
var Table_1 = __webpack_require__(
|
|
2369
|
+
var Table_1 = __webpack_require__(82);
|
|
2120
2370
|
|
|
2121
2371
|
var TextCell = function TextCell(_ref) {
|
|
2122
2372
|
var cell = _ref.cell,
|
|
2123
|
-
useMouseOverEffect = _ref.useMouseOverEffect
|
|
2373
|
+
useMouseOverEffect = _ref.useMouseOverEffect,
|
|
2374
|
+
width = _ref.width;
|
|
2124
2375
|
return React.createElement(Table_1.default.Cell, {
|
|
2125
|
-
style: cell.style,
|
|
2376
|
+
style: Object.assign(Object.assign({}, cell.style), {
|
|
2377
|
+
width: width
|
|
2378
|
+
}),
|
|
2126
2379
|
align: cell.align,
|
|
2127
2380
|
"data-test-cell-type": "TextCell",
|
|
2128
2381
|
"data-row-index": cell.rowIndex,
|
|
@@ -2136,7 +2389,7 @@ exports.TextCell.displayName = 'TextCell';
|
|
|
2136
2389
|
|
|
2137
2390
|
/***/ }),
|
|
2138
2391
|
|
|
2139
|
-
/***/
|
|
2392
|
+
/***/ 264:
|
|
2140
2393
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2141
2394
|
|
|
2142
2395
|
"use strict";
|
|
@@ -2149,14 +2402,17 @@ exports.ArrayCell = void 0;
|
|
|
2149
2402
|
|
|
2150
2403
|
var React = __webpack_require__(1);
|
|
2151
2404
|
|
|
2152
|
-
var Table_1 = __webpack_require__(
|
|
2405
|
+
var Table_1 = __webpack_require__(82);
|
|
2153
2406
|
|
|
2154
2407
|
var ArrayCell = function ArrayCell(_ref) {
|
|
2155
2408
|
var cell = _ref.cell,
|
|
2156
|
-
useMouseOverEffect = _ref.useMouseOverEffect
|
|
2409
|
+
useMouseOverEffect = _ref.useMouseOverEffect,
|
|
2410
|
+
width = _ref.width;
|
|
2157
2411
|
var value = Array.isArray(cell.value) ? cell.value : [cell.value];
|
|
2158
2412
|
return React.createElement(Table_1.default.Cell, {
|
|
2159
|
-
style: cell.style,
|
|
2413
|
+
style: Object.assign(Object.assign({}, cell.style), {
|
|
2414
|
+
width: width
|
|
2415
|
+
}),
|
|
2160
2416
|
align: cell.align,
|
|
2161
2417
|
"data-test-cell-type": "ArrayCell",
|
|
2162
2418
|
onClick: useMouseOverEffect ? function () {} : undefined
|
|
@@ -2175,13 +2431,13 @@ exports.ArrayCell.displayName = 'ArrayCell';
|
|
|
2175
2431
|
|
|
2176
2432
|
/***/ }),
|
|
2177
2433
|
|
|
2178
|
-
/***/
|
|
2434
|
+
/***/ 265:
|
|
2179
2435
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2180
2436
|
|
|
2181
2437
|
"use strict";
|
|
2182
2438
|
|
|
2183
2439
|
|
|
2184
|
-
var _slicedToArray = __webpack_require__(
|
|
2440
|
+
var _slicedToArray = __webpack_require__(48);
|
|
2185
2441
|
|
|
2186
2442
|
Object.defineProperty(exports, "__esModule", {
|
|
2187
2443
|
value: true
|
|
@@ -2190,9 +2446,9 @@ exports.SparklineCell = exports.validSparklineTypes = void 0;
|
|
|
2190
2446
|
|
|
2191
2447
|
var React = __webpack_require__(1);
|
|
2192
2448
|
|
|
2193
|
-
var Table_1 = __webpack_require__(
|
|
2449
|
+
var Table_1 = __webpack_require__(82);
|
|
2194
2450
|
|
|
2195
|
-
var Line_1 = __webpack_require__(
|
|
2451
|
+
var Line_1 = __webpack_require__(83);
|
|
2196
2452
|
|
|
2197
2453
|
var paddingLeftRight = 5;
|
|
2198
2454
|
var paddingTopBottom = 3;
|
|
@@ -2210,7 +2466,8 @@ exports.validSparklineTypes = ['line', 'area'];
|
|
|
2210
2466
|
|
|
2211
2467
|
var SparklineCell = function SparklineCell(_ref) {
|
|
2212
2468
|
var cell = _ref.cell,
|
|
2213
|
-
useMouseOverEffect = _ref.useMouseOverEffect
|
|
2469
|
+
useMouseOverEffect = _ref.useMouseOverEffect,
|
|
2470
|
+
width = _ref.width;
|
|
2214
2471
|
|
|
2215
2472
|
var _React$useState = React.useState(React.createRef()),
|
|
2216
2473
|
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
@@ -2232,7 +2489,7 @@ var SparklineCell = function SparklineCell(_ref) {
|
|
|
2232
2489
|
style: Object.assign(Object.assign({}, cell.style), {
|
|
2233
2490
|
padding: 0,
|
|
2234
2491
|
margin: 0,
|
|
2235
|
-
width:
|
|
2492
|
+
width: width,
|
|
2236
2493
|
height: "".concat(height, "px")
|
|
2237
2494
|
}),
|
|
2238
2495
|
align: cell.align,
|
|
@@ -2267,137 +2524,19 @@ exports.SparklineCell.displayName = 'SparklineCell';
|
|
|
2267
2524
|
|
|
2268
2525
|
/***/ }),
|
|
2269
2526
|
|
|
2270
|
-
/***/
|
|
2527
|
+
/***/ 266:
|
|
2271
2528
|
/***/ (function(module, exports) {
|
|
2272
2529
|
|
|
2273
2530
|
module.exports = require("lodash/debounce");
|
|
2274
2531
|
|
|
2275
2532
|
/***/ }),
|
|
2276
2533
|
|
|
2277
|
-
/***/ 26:
|
|
2278
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
2279
|
-
|
|
2280
|
-
"use strict";
|
|
2281
|
-
|
|
2282
|
-
|
|
2283
|
-
Object.defineProperty(exports, "__esModule", {
|
|
2284
|
-
value: true
|
|
2285
|
-
});
|
|
2286
|
-
exports.shouldShowIconPlaceholder = void 0;
|
|
2287
|
-
|
|
2288
|
-
var React = __webpack_require__(1);
|
|
2289
|
-
|
|
2290
|
-
var T = __webpack_require__(0);
|
|
2291
|
-
|
|
2292
|
-
var lodash_1 = __webpack_require__(2);
|
|
2293
|
-
|
|
2294
|
-
var i18n_1 = __webpack_require__(3);
|
|
2295
|
-
|
|
2296
|
-
var Message_1 = __webpack_require__(9);
|
|
2297
|
-
|
|
2298
|
-
var FixedSizeContainer_1 = __webpack_require__(12);
|
|
2299
|
-
/**
|
|
2300
|
-
* @method shouldShowIconPlaceholder
|
|
2301
|
-
* @param {object} dataSources
|
|
2302
|
-
* @param {boolean} loading
|
|
2303
|
-
* @returns {boolean}
|
|
2304
|
-
*/
|
|
2305
|
-
|
|
2306
|
-
|
|
2307
|
-
var shouldShowIconPlaceholder = function shouldShowIconPlaceholder(dataSources) {
|
|
2308
|
-
var loading = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
2309
|
-
var data = lodash_1.get(dataSources, 'primary.data.columns[0]', undefined);
|
|
2310
|
-
var noData = data === undefined;
|
|
2311
|
-
var fields = lodash_1.get(dataSources, 'primary.data.fields[0]', undefined);
|
|
2312
|
-
var noFields = fields === undefined;
|
|
2313
|
-
return loading || noData || noFields;
|
|
2314
|
-
};
|
|
2315
|
-
|
|
2316
|
-
exports.shouldShowIconPlaceholder = shouldShowIconPlaceholder;
|
|
2317
|
-
var propTypes = {
|
|
2318
|
-
icon: T.func,
|
|
2319
|
-
width: T.oneOfType([T.string, T.number]),
|
|
2320
|
-
height: T.oneOfType([T.string, T.number]),
|
|
2321
|
-
// eslint-disable-next-line react/no-unused-prop-types
|
|
2322
|
-
backgroundColor: T.string
|
|
2323
|
-
};
|
|
2324
|
-
/**
|
|
2325
|
-
* @method IconPlaceholder
|
|
2326
|
-
* @param {IconPlaceholderProps} props
|
|
2327
|
-
* @returns {React.ReactElement}
|
|
2328
|
-
*/
|
|
2329
|
-
|
|
2330
|
-
var IconPlaceholder = function IconPlaceholder(props) {
|
|
2331
|
-
var width = props.width,
|
|
2332
|
-
height = props.height,
|
|
2333
|
-
icon = props.icon;
|
|
2334
|
-
|
|
2335
|
-
if (icon) {
|
|
2336
|
-
return React.createElement(icon, {
|
|
2337
|
-
style: {
|
|
2338
|
-
left: '50%',
|
|
2339
|
-
top: '50%',
|
|
2340
|
-
color: 'grey',
|
|
2341
|
-
position: 'absolute',
|
|
2342
|
-
transform: 'translate(-50%, -50%)'
|
|
2343
|
-
},
|
|
2344
|
-
width: '50%',
|
|
2345
|
-
height: '50%'
|
|
2346
|
-
});
|
|
2347
|
-
}
|
|
2348
|
-
|
|
2349
|
-
return React.createElement(Message_1.default, {
|
|
2350
|
-
width: width,
|
|
2351
|
-
height: height,
|
|
2352
|
-
level: "warning",
|
|
2353
|
-
message: i18n_1._('No DataSource Connected')
|
|
2354
|
-
});
|
|
2355
|
-
};
|
|
2356
|
-
|
|
2357
|
-
IconPlaceholder.propTypes = propTypes;
|
|
2358
|
-
IconPlaceholder.defaultProps = {
|
|
2359
|
-
width: '100%',
|
|
2360
|
-
height: 250
|
|
2361
|
-
};
|
|
2362
|
-
exports.default = FixedSizeContainer_1.default(IconPlaceholder);
|
|
2363
|
-
|
|
2364
|
-
/***/ }),
|
|
2365
|
-
|
|
2366
2534
|
/***/ 27:
|
|
2367
2535
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2368
2536
|
|
|
2369
2537
|
"use strict";
|
|
2370
2538
|
|
|
2371
2539
|
|
|
2372
|
-
Object.defineProperty(exports, "__esModule", {
|
|
2373
|
-
value: true
|
|
2374
|
-
});
|
|
2375
|
-
exports.VizCategory = void 0;
|
|
2376
|
-
var VizCategory;
|
|
2377
|
-
|
|
2378
|
-
(function (VizCategory) {
|
|
2379
|
-
VizCategory["SINGLE_VALUE"] = "Single Value";
|
|
2380
|
-
VizCategory["TRENDS"] = "Trends";
|
|
2381
|
-
VizCategory["COMPARISONS"] = "Comparisons";
|
|
2382
|
-
VizCategory["TABLE"] = "Table";
|
|
2383
|
-
VizCategory["GAUGE"] = "Gauge";
|
|
2384
|
-
VizCategory["DISTRIBUTIONS"] = "Distributions";
|
|
2385
|
-
VizCategory["CHOROPLETH"] = "Choropleth Maps";
|
|
2386
|
-
VizCategory["SHAPES"] = "Shapes";
|
|
2387
|
-
VizCategory["MISC"] = "misc";
|
|
2388
|
-
VizCategory["FLOW"] = "Flow";
|
|
2389
|
-
VizCategory["CORRELATION"] = "Correlation";
|
|
2390
|
-
VizCategory["SPATIAL"] = "Spatial";
|
|
2391
|
-
})(VizCategory = exports.VizCategory || (exports.VizCategory = {}));
|
|
2392
|
-
|
|
2393
|
-
/***/ }),
|
|
2394
|
-
|
|
2395
|
-
/***/ 28:
|
|
2396
|
-
/***/ (function(module, exports, __webpack_require__) {
|
|
2397
|
-
|
|
2398
|
-
"use strict";
|
|
2399
|
-
|
|
2400
|
-
|
|
2401
2540
|
Object.defineProperty(exports, "__esModule", {
|
|
2402
2541
|
value: true
|
|
2403
2542
|
});
|
|
@@ -2406,33 +2545,33 @@ var React = __webpack_require__(1);
|
|
|
2406
2545
|
|
|
2407
2546
|
var lodash_1 = __webpack_require__(2);
|
|
2408
2547
|
|
|
2409
|
-
var getSettingsFromThemedProps_1 = __webpack_require__(
|
|
2548
|
+
var getSettingsFromThemedProps_1 = __webpack_require__(28);
|
|
2410
2549
|
|
|
2411
|
-
var Options_1 = __webpack_require__(
|
|
2550
|
+
var Options_1 = __webpack_require__(29);
|
|
2412
2551
|
|
|
2413
|
-
var SanitizeProps_1 = __webpack_require__(
|
|
2552
|
+
var SanitizeProps_1 = __webpack_require__(30);
|
|
2414
2553
|
|
|
2415
2554
|
var styled_components_1 = __webpack_require__(4);
|
|
2416
2555
|
|
|
2417
|
-
var SplunkVisualization_1 = __webpack_require__(
|
|
2556
|
+
var SplunkVisualization_1 = __webpack_require__(31);
|
|
2418
2557
|
|
|
2419
2558
|
var VizBehavior_1 = __webpack_require__(5);
|
|
2420
2559
|
|
|
2421
|
-
var getSorting_1 = __webpack_require__(
|
|
2560
|
+
var getSorting_1 = __webpack_require__(23);
|
|
2422
2561
|
|
|
2423
|
-
var getPagination_1 = __webpack_require__(
|
|
2562
|
+
var getPagination_1 = __webpack_require__(24);
|
|
2424
2563
|
|
|
2425
|
-
var useDeepMemo_1 = __webpack_require__(
|
|
2564
|
+
var useDeepMemo_1 = __webpack_require__(34);
|
|
2426
2565
|
|
|
2427
|
-
var JSONSchemaUtils_1 = __webpack_require__(
|
|
2566
|
+
var JSONSchemaUtils_1 = __webpack_require__(35);
|
|
2428
2567
|
|
|
2429
|
-
var MissingPropsMessage_1 = __webpack_require__(
|
|
2568
|
+
var MissingPropsMessage_1 = __webpack_require__(36);
|
|
2430
2569
|
|
|
2431
|
-
var withEditModeCover_1 = __webpack_require__(
|
|
2570
|
+
var withEditModeCover_1 = __webpack_require__(37);
|
|
2432
2571
|
|
|
2433
|
-
var withPlaceholder_1 = __webpack_require__(
|
|
2572
|
+
var withPlaceholder_1 = __webpack_require__(38);
|
|
2434
2573
|
|
|
2435
|
-
var hocUtils_1 = __webpack_require__(
|
|
2574
|
+
var hocUtils_1 = __webpack_require__(7);
|
|
2436
2575
|
/**
|
|
2437
2576
|
* hoc that wraps a pure react visualization in a Dashboard visualization
|
|
2438
2577
|
* @param {DashboardVizOpts} opts
|
|
@@ -2445,6 +2584,7 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
2445
2584
|
vizConfig = opts.vizConfig,
|
|
2446
2585
|
_opts$computeVizProps = opts.computeVizProps,
|
|
2447
2586
|
computeVizProps = _opts$computeVizProps === void 0 ? function () {} : _opts$computeVizProps,
|
|
2587
|
+
disableEditModeCover = opts.disableEditModeCover,
|
|
2448
2588
|
useIconPlaceholder = opts.useIconPlaceholder; // sanitizing props before sending them to reactviz.
|
|
2449
2589
|
|
|
2450
2590
|
var SanitizedReactViz = SanitizeProps_1.withSanitizedProps(ReactViz);
|
|
@@ -2609,42 +2749,42 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
2609
2749
|
|
|
2610
2750
|
DashboardViz.config = vizConfig; // @ts-ignore: TODO fix sc upgrade TS issues
|
|
2611
2751
|
|
|
2612
|
-
return styled_components_1.withTheme(withPlaceholder_1.default(withEditModeCover_1.default(DashboardViz), useIconPlaceholder));
|
|
2752
|
+
return styled_components_1.withTheme(withPlaceholder_1.default(withEditModeCover_1.default(DashboardViz, disableEditModeCover), useIconPlaceholder));
|
|
2613
2753
|
};
|
|
2614
2754
|
|
|
2615
2755
|
exports.default = withDashboardViz;
|
|
2616
2756
|
|
|
2617
2757
|
/***/ }),
|
|
2618
2758
|
|
|
2619
|
-
/***/
|
|
2759
|
+
/***/ 28:
|
|
2620
2760
|
/***/ (function(module, exports) {
|
|
2621
2761
|
|
|
2622
2762
|
module.exports = require("@splunk/themes/getSettingsFromThemedProps");
|
|
2623
2763
|
|
|
2624
2764
|
/***/ }),
|
|
2625
2765
|
|
|
2626
|
-
/***/
|
|
2766
|
+
/***/ 29:
|
|
2627
2767
|
/***/ (function(module, exports) {
|
|
2628
2768
|
|
|
2629
|
-
module.exports = require("@splunk/
|
|
2769
|
+
module.exports = require("@splunk/visualization-encoding/Options");
|
|
2630
2770
|
|
|
2631
2771
|
/***/ }),
|
|
2632
2772
|
|
|
2633
|
-
/***/
|
|
2773
|
+
/***/ 3:
|
|
2634
2774
|
/***/ (function(module, exports) {
|
|
2635
2775
|
|
|
2636
|
-
module.exports = require("@splunk/
|
|
2776
|
+
module.exports = require("@splunk/ui-utils/i18n");
|
|
2637
2777
|
|
|
2638
2778
|
/***/ }),
|
|
2639
2779
|
|
|
2640
|
-
/***/
|
|
2780
|
+
/***/ 30:
|
|
2641
2781
|
/***/ (function(module, exports) {
|
|
2642
2782
|
|
|
2643
2783
|
module.exports = require("@splunk/visualizations-shared/SanitizeProps");
|
|
2644
2784
|
|
|
2645
2785
|
/***/ }),
|
|
2646
2786
|
|
|
2647
|
-
/***/
|
|
2787
|
+
/***/ 31:
|
|
2648
2788
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2649
2789
|
|
|
2650
2790
|
"use strict";
|
|
@@ -2662,7 +2802,7 @@ var T = __webpack_require__(0);
|
|
|
2662
2802
|
|
|
2663
2803
|
var lodash_1 = __webpack_require__(2);
|
|
2664
2804
|
|
|
2665
|
-
var VizActionHandler_1 = __webpack_require__(
|
|
2805
|
+
var VizActionHandler_1 = __webpack_require__(32); // this is identical to the initial height and width we use in BaseVisualization in dashboard-visualizations
|
|
2666
2806
|
|
|
2667
2807
|
|
|
2668
2808
|
exports.INITIAL_WIDTH = 250;
|
|
@@ -2796,7 +2936,7 @@ exports.default = SplunkVisualization;
|
|
|
2796
2936
|
|
|
2797
2937
|
/***/ }),
|
|
2798
2938
|
|
|
2799
|
-
/***/
|
|
2939
|
+
/***/ 32:
|
|
2800
2940
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2801
2941
|
|
|
2802
2942
|
"use strict";
|
|
@@ -2804,7 +2944,7 @@ exports.default = SplunkVisualization;
|
|
|
2804
2944
|
|
|
2805
2945
|
var _classCallCheck = __webpack_require__(10);
|
|
2806
2946
|
|
|
2807
|
-
var _createClass = __webpack_require__(
|
|
2947
|
+
var _createClass = __webpack_require__(15);
|
|
2808
2948
|
|
|
2809
2949
|
Object.defineProperty(exports, "__esModule", {
|
|
2810
2950
|
value: true
|
|
@@ -2834,7 +2974,7 @@ exports.DefaultVizActionHandler = DefaultVizActionHandler;
|
|
|
2834
2974
|
|
|
2835
2975
|
/***/ }),
|
|
2836
2976
|
|
|
2837
|
-
/***/
|
|
2977
|
+
/***/ 33:
|
|
2838
2978
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2839
2979
|
|
|
2840
2980
|
"use strict";
|
|
@@ -2848,7 +2988,7 @@ exports.validSortDirs = ['asc', 'desc', 'none'];
|
|
|
2848
2988
|
|
|
2849
2989
|
/***/ }),
|
|
2850
2990
|
|
|
2851
|
-
/***/
|
|
2991
|
+
/***/ 34:
|
|
2852
2992
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2853
2993
|
|
|
2854
2994
|
"use strict";
|
|
@@ -2894,7 +3034,7 @@ exports.useDeepMemo = useDeepMemo;
|
|
|
2894
3034
|
|
|
2895
3035
|
/***/ }),
|
|
2896
3036
|
|
|
2897
|
-
/***/
|
|
3037
|
+
/***/ 35:
|
|
2898
3038
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2899
3039
|
|
|
2900
3040
|
"use strict";
|
|
@@ -2928,7 +3068,7 @@ exports.pickFieldFromJSONSchema = pickFieldFromJSONSchema;
|
|
|
2928
3068
|
|
|
2929
3069
|
/***/ }),
|
|
2930
3070
|
|
|
2931
|
-
/***/
|
|
3071
|
+
/***/ 36:
|
|
2932
3072
|
/***/ (function(module, exports, __webpack_require__) {
|
|
2933
3073
|
|
|
2934
3074
|
"use strict";
|
|
@@ -3009,7 +3149,7 @@ exports.default = FixedSizeContainer_1.default(exports.MissingPropsMessage);
|
|
|
3009
3149
|
|
|
3010
3150
|
/***/ }),
|
|
3011
3151
|
|
|
3012
|
-
/***/
|
|
3152
|
+
/***/ 37:
|
|
3013
3153
|
/***/ (function(module, exports, __webpack_require__) {
|
|
3014
3154
|
|
|
3015
3155
|
"use strict";
|
|
@@ -3023,16 +3163,14 @@ var React = __webpack_require__(1);
|
|
|
3023
3163
|
|
|
3024
3164
|
var styled_components_1 = __webpack_require__(4);
|
|
3025
3165
|
|
|
3026
|
-
var hocUtils_1 = __webpack_require__(
|
|
3027
|
-
|
|
3028
|
-
var version_1 = __webpack_require__(13);
|
|
3166
|
+
var hocUtils_1 = __webpack_require__(7);
|
|
3029
3167
|
|
|
3030
3168
|
var Cover = styled_components_1.default.div.withConfig({
|
|
3031
3169
|
displayName: "withEditModeCover__Cover",
|
|
3032
3170
|
componentId: "sc-1gsbnxb-0"
|
|
3033
3171
|
})(["position:absolute;left:0;right:0;top:0;bottom:0;"]);
|
|
3034
3172
|
var Blocker = styled_components_1.default.div.attrs({
|
|
3035
|
-
'data-splunk-visualization-version':
|
|
3173
|
+
'data-splunk-visualization-version': "24.3.0 - 1c1ae4b3c"
|
|
3036
3174
|
}).withConfig({
|
|
3037
3175
|
displayName: "withEditModeCover__Blocker",
|
|
3038
3176
|
componentId: "sc-1gsbnxb-1"
|
|
@@ -3044,10 +3182,11 @@ var Blocker = styled_components_1.default.div.attrs({
|
|
|
3044
3182
|
* @returns {ExtendedDashViz} Wrapper
|
|
3045
3183
|
*/
|
|
3046
3184
|
|
|
3047
|
-
var withEditModeCover = function withEditModeCover(Visualization) {
|
|
3185
|
+
var withEditModeCover = function withEditModeCover(Visualization, disableEditModeCover) {
|
|
3048
3186
|
var Wrapper = function Wrapper(props) {
|
|
3049
3187
|
var mode = props.mode;
|
|
3050
|
-
|
|
3188
|
+
var showEditCover = mode === 'edit' && !disableEditModeCover;
|
|
3189
|
+
return React.createElement(Blocker, null, React.createElement(Visualization, Object.assign({}, props)), showEditCover && React.createElement(Cover, {
|
|
3051
3190
|
"data-test": "edit-mode-cover"
|
|
3052
3191
|
}));
|
|
3053
3192
|
};
|
|
@@ -3063,7 +3202,7 @@ exports.default = withEditModeCover;
|
|
|
3063
3202
|
|
|
3064
3203
|
/***/ }),
|
|
3065
3204
|
|
|
3066
|
-
/***/
|
|
3205
|
+
/***/ 38:
|
|
3067
3206
|
/***/ (function(module, exports, __webpack_require__) {
|
|
3068
3207
|
|
|
3069
3208
|
"use strict";
|
|
@@ -3077,11 +3216,11 @@ var React = __webpack_require__(1);
|
|
|
3077
3216
|
|
|
3078
3217
|
var colorUtils_1 = __webpack_require__(11);
|
|
3079
3218
|
|
|
3080
|
-
var IconPlaceholder_1 = __webpack_require__(
|
|
3219
|
+
var IconPlaceholder_1 = __webpack_require__(25);
|
|
3081
3220
|
|
|
3082
3221
|
var VizBehavior_1 = __webpack_require__(5);
|
|
3083
3222
|
|
|
3084
|
-
var hocUtils_1 = __webpack_require__(
|
|
3223
|
+
var hocUtils_1 = __webpack_require__(7);
|
|
3085
3224
|
|
|
3086
3225
|
var withPlaceholder = function withPlaceholder(Visualization) {
|
|
3087
3226
|
var useIconPlaceholder = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : IconPlaceholder_1.shouldShowIconPlaceholder;
|
|
@@ -3123,6 +3262,13 @@ exports.default = withPlaceholder;
|
|
|
3123
3262
|
|
|
3124
3263
|
/***/ }),
|
|
3125
3264
|
|
|
3265
|
+
/***/ 39:
|
|
3266
|
+
/***/ (function(module, exports) {
|
|
3267
|
+
|
|
3268
|
+
module.exports = require("@babel/runtime/helpers/toConsumableArray");
|
|
3269
|
+
|
|
3270
|
+
/***/ }),
|
|
3271
|
+
|
|
3126
3272
|
/***/ 4:
|
|
3127
3273
|
/***/ (function(module, exports) {
|
|
3128
3274
|
|
|
@@ -3133,21 +3279,21 @@ module.exports = require("styled-components");
|
|
|
3133
3279
|
/***/ 40:
|
|
3134
3280
|
/***/ (function(module, exports) {
|
|
3135
3281
|
|
|
3136
|
-
module.exports = require("@
|
|
3282
|
+
module.exports = require("@splunk/visualizations-shared/colorConstants");
|
|
3137
3283
|
|
|
3138
3284
|
/***/ }),
|
|
3139
3285
|
|
|
3140
|
-
/***/
|
|
3286
|
+
/***/ 42:
|
|
3141
3287
|
/***/ (function(module, exports) {
|
|
3142
3288
|
|
|
3143
|
-
module.exports = require("@splunk/
|
|
3289
|
+
module.exports = require("@splunk/visualization-icons");
|
|
3144
3290
|
|
|
3145
3291
|
/***/ }),
|
|
3146
3292
|
|
|
3147
|
-
/***/
|
|
3293
|
+
/***/ 48:
|
|
3148
3294
|
/***/ (function(module, exports) {
|
|
3149
3295
|
|
|
3150
|
-
module.exports = require("@
|
|
3296
|
+
module.exports = require("@babel/runtime/helpers/slicedToArray");
|
|
3151
3297
|
|
|
3152
3298
|
/***/ }),
|
|
3153
3299
|
|
|
@@ -3195,7 +3341,7 @@ var VizBehavior;
|
|
|
3195
3341
|
"use strict";
|
|
3196
3342
|
|
|
3197
3343
|
|
|
3198
|
-
var _defineProperty = __webpack_require__(
|
|
3344
|
+
var _defineProperty = __webpack_require__(8);
|
|
3199
3345
|
|
|
3200
3346
|
var __rest = this && this.__rest || function (s, e) {
|
|
3201
3347
|
var t = {};
|
|
@@ -3217,7 +3363,7 @@ exports.generatePrecisionValues = exports.getInitialPreset = exports.isDynamicOp
|
|
|
3217
3363
|
|
|
3218
3364
|
var lodash_1 = __webpack_require__(2);
|
|
3219
3365
|
|
|
3220
|
-
var schemaUtils_1 = __webpack_require__(
|
|
3366
|
+
var schemaUtils_1 = __webpack_require__(14);
|
|
3221
3367
|
|
|
3222
3368
|
var VizBehavior_1 = __webpack_require__(5);
|
|
3223
3369
|
|
|
@@ -3381,27 +3527,13 @@ exports.generatePrecisionValues = generatePrecisionValues;
|
|
|
3381
3527
|
|
|
3382
3528
|
/***/ }),
|
|
3383
3529
|
|
|
3384
|
-
/***/ 62:
|
|
3385
|
-
/***/ (function(module, exports) {
|
|
3386
|
-
|
|
3387
|
-
module.exports = require("@babel/runtime/helpers/slicedToArray");
|
|
3388
|
-
|
|
3389
|
-
/***/ }),
|
|
3390
|
-
|
|
3391
3530
|
/***/ 7:
|
|
3392
|
-
/***/ (function(module, exports) {
|
|
3393
|
-
|
|
3394
|
-
module.exports = require("@babel/runtime/helpers/defineProperty");
|
|
3395
|
-
|
|
3396
|
-
/***/ }),
|
|
3397
|
-
|
|
3398
|
-
/***/ 8:
|
|
3399
3531
|
/***/ (function(module, exports, __webpack_require__) {
|
|
3400
3532
|
|
|
3401
3533
|
"use strict";
|
|
3402
3534
|
|
|
3403
3535
|
|
|
3404
|
-
var _typeof = __webpack_require__(
|
|
3536
|
+
var _typeof = __webpack_require__(20);
|
|
3405
3537
|
|
|
3406
3538
|
Object.defineProperty(exports, "__esModule", {
|
|
3407
3539
|
value: true
|
|
@@ -3468,14 +3600,21 @@ exports.deepMergeWithArrayOverrides = deepMergeWithArrayOverrides;
|
|
|
3468
3600
|
|
|
3469
3601
|
/***/ }),
|
|
3470
3602
|
|
|
3471
|
-
/***/
|
|
3603
|
+
/***/ 8:
|
|
3604
|
+
/***/ (function(module, exports) {
|
|
3605
|
+
|
|
3606
|
+
module.exports = require("@babel/runtime/helpers/defineProperty");
|
|
3607
|
+
|
|
3608
|
+
/***/ }),
|
|
3609
|
+
|
|
3610
|
+
/***/ 82:
|
|
3472
3611
|
/***/ (function(module, exports) {
|
|
3473
3612
|
|
|
3474
3613
|
module.exports = require("@splunk/react-ui/Table");
|
|
3475
3614
|
|
|
3476
3615
|
/***/ }),
|
|
3477
3616
|
|
|
3478
|
-
/***/
|
|
3617
|
+
/***/ 83:
|
|
3479
3618
|
/***/ (function(module, exports) {
|
|
3480
3619
|
|
|
3481
3620
|
module.exports = require("@splunk/react-sparkline/Line");
|