@splunk/visualizations 25.13.0 → 26.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Area.config.js +216 -216
- package/Area.config.js.map +1 -1
- package/Area.js +529 -561
- package/Area.js.map +1 -1
- package/Bar.config.js +213 -213
- package/Bar.config.js.map +1 -1
- package/Bar.js +394 -386
- package/Bar.js.map +1 -1
- package/Bubble.config.js +140 -140
- package/Bubble.config.js.map +1 -1
- package/Bubble.js +313 -305
- package/Bubble.js.map +1 -1
- package/ChoroplethSvg.config.js +15 -15
- package/ChoroplethSvg.config.js.map +1 -1
- package/ChoroplethSvg.js +149 -144
- package/ChoroplethSvg.js.map +1 -1
- package/Column.config.js +205 -205
- package/Column.config.js.map +1 -1
- package/Column.js +387 -379
- package/Column.js.map +1 -1
- package/Ellipse.config.js +45 -45
- package/Ellipse.config.js.map +1 -1
- package/Ellipse.js +157 -144
- package/Ellipse.js.map +1 -1
- package/Events.config.js +11 -11
- package/Events.config.js.map +1 -1
- package/Events.js +274 -262
- package/Events.js.map +1 -1
- package/FillerGauge.config.js +46 -46
- package/FillerGauge.config.js.map +1 -1
- package/FillerGauge.js +267 -262
- package/FillerGauge.js.map +1 -1
- package/Image.config.js +8 -8
- package/Image.config.js.map +1 -1
- package/Image.js +110 -104
- package/Image.js.map +1 -1
- package/Line.config.js +220 -220
- package/Line.config.js.map +1 -1
- package/Line.js +404 -396
- package/Line.js.map +1 -1
- package/LinkGraph.config.js +27 -27
- package/LinkGraph.config.js.map +1 -1
- package/LinkGraph.js +557 -548
- package/LinkGraph.js.map +1 -1
- package/Map.config.js +71 -71
- package/Map.config.js.map +1 -1
- package/Map.js +472 -466
- package/Map.js.map +1 -1
- package/Markdown.config.js +23 -23
- package/Markdown.config.js.map +1 -1
- package/Markdown.js +151 -145
- package/Markdown.js.map +1 -1
- package/MarkerGauge.config.js +84 -84
- package/MarkerGauge.config.js.map +1 -1
- package/MarkerGauge.js +295 -289
- package/MarkerGauge.js.map +1 -1
- package/ParallelCoordinates.config.js +23 -23
- package/ParallelCoordinates.config.js.map +1 -1
- package/ParallelCoordinates.js +164 -162
- package/ParallelCoordinates.js.map +1 -1
- package/Pie.config.js +24 -24
- package/Pie.config.js.map +1 -1
- package/Pie.js +233 -228
- package/Pie.js.map +1 -1
- package/Punchcard.config.js +33 -33
- package/Punchcard.config.js.map +1 -1
- package/Punchcard.js +278 -279
- package/Punchcard.js.map +1 -1
- package/Rectangle.config.js +46 -46
- package/Rectangle.config.js.map +1 -1
- package/Rectangle.js +154 -142
- package/Rectangle.js.map +1 -1
- package/Sankey.config.js +19 -19
- package/Sankey.config.js.map +1 -1
- package/Sankey.js +281 -275
- package/Sankey.js.map +1 -1
- package/Scatter.config.js +135 -135
- package/Scatter.config.js.map +1 -1
- package/Scatter.js +304 -299
- package/Scatter.js.map +1 -1
- package/SingleValue.config.js +119 -119
- package/SingleValue.config.js.map +1 -1
- package/SingleValue.js +359 -341
- package/SingleValue.js.map +1 -1
- package/SingleValueBasic.js +14 -14
- package/SingleValueBasic.js.map +1 -1
- package/SingleValueIcon.config.js +117 -117
- package/SingleValueIcon.config.js.map +1 -1
- package/SingleValueIcon.js +373 -371
- package/SingleValueIcon.js.map +1 -1
- package/SingleValueRadial.config.js +157 -115
- package/SingleValueRadial.config.js.map +1 -1
- package/SingleValueRadial.js +1114 -540
- package/SingleValueRadial.js.map +1 -1
- package/SparkLine.js +50 -20
- package/SparkLine.js.map +1 -1
- package/Table.config.js +54 -54
- package/Table.config.js.map +1 -1
- package/Table.js +302 -286
- package/Table.js.map +1 -1
- package/common/Charting.js +41 -41
- package/common/Charting.js.map +1 -1
- package/common/EventsDoc.js +15 -14
- 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 +22 -22
- package/common/OptionsDoc.js.map +1 -1
- package/common/OverviewDoc.js +32 -27
- 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 +14 -14
- package/common/ThemesDoc.js.map +1 -1
- package/common/chartingUtils.js +12 -12
- package/common/chartingUtils.js.map +1 -1
- package/common/docUtils.js +4 -4
- package/common/docUtils.js.map +1 -1
- package/common/gaugeUtils.js +112 -112
- package/common/gaugeUtils.js.map +1 -1
- package/common/shapeUtils.js +21 -15
- package/common/shapeUtils.js.map +1 -1
- package/common/utils/configUtils.js +10 -9
- package/common/utils/configUtils.js.map +1 -1
- package/common/utils/dataUtils.js +3 -3
- package/common/utils/dataUtils.js.map +1 -1
- package/common/utils/hocUtils.js +2 -2
- package/common/utils/hocUtils.js.map +1 -1
- package/common/utils/layoutUtils.js +2 -2
- package/common/utils/layoutUtils.js.map +1 -1
- package/common/utils/mapUtils.js +84 -80
- package/common/utils/mapUtils.js.map +1 -1
- package/common/utils/singleValueUtils.js +2 -2
- package/common/utils/singleValueUtils.js.map +1 -1
- package/common/utils/testHelper.js +27 -9
- package/common/utils/testHelper.js.map +1 -1
- package/common/utils/trellisUtils.js +26 -26
- package/common/utils/trellisUtils.js.map +1 -1
- package/common/utils/urlUtils.js +2 -2
- package/common/utils/urlUtils.js.map +1 -1
- package/common/withDashboardViz.js +107 -104
- package/common/withDashboardViz.js.map +1 -1
- package/package.json +19 -19
package/Markdown.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 = 423);
|
|
91
91
|
/******/ })
|
|
92
92
|
/************************************************************************/
|
|
93
93
|
/******/ ({
|
|
@@ -113,17 +113,17 @@ module.exports = require("@splunk/visualizations-shared/Message");
|
|
|
113
113
|
|
|
114
114
|
/***/ }),
|
|
115
115
|
|
|
116
|
-
/***/
|
|
116
|
+
/***/ 11:
|
|
117
117
|
/***/ (function(module, exports) {
|
|
118
118
|
|
|
119
|
-
module.exports = require("@splunk/
|
|
119
|
+
module.exports = require("@splunk/themes/variables");
|
|
120
120
|
|
|
121
121
|
/***/ }),
|
|
122
122
|
|
|
123
|
-
/***/
|
|
123
|
+
/***/ 110:
|
|
124
124
|
/***/ (function(module, exports) {
|
|
125
125
|
|
|
126
|
-
module.exports = require("@splunk/
|
|
126
|
+
module.exports = require("@splunk/react-ui/Paragraph");
|
|
127
127
|
|
|
128
128
|
/***/ }),
|
|
129
129
|
|
|
@@ -134,14 +134,14 @@ module.exports = require("@splunk/visualizations-shared/colorUtils");
|
|
|
134
134
|
|
|
135
135
|
/***/ }),
|
|
136
136
|
|
|
137
|
-
/***/
|
|
137
|
+
/***/ 122:
|
|
138
138
|
/***/ (function(module, exports) {
|
|
139
139
|
|
|
140
140
|
module.exports = require("@splunk/react-ui/Markdown");
|
|
141
141
|
|
|
142
142
|
/***/ }),
|
|
143
143
|
|
|
144
|
-
/***/
|
|
144
|
+
/***/ 125:
|
|
145
145
|
/***/ (function(module, exports) {
|
|
146
146
|
|
|
147
147
|
module.exports = require("@splunk/react-ui/Heading");
|
|
@@ -166,14 +166,14 @@ var Item = styled_components_1.default.div.attrs(function (_ref) {
|
|
|
166
166
|
var width = _ref.width;
|
|
167
167
|
return {
|
|
168
168
|
style: {
|
|
169
|
-
width: style_1.toPx(width)
|
|
169
|
+
width: (0, style_1.toPx)(width)
|
|
170
170
|
}
|
|
171
171
|
};
|
|
172
172
|
}).withConfig({
|
|
173
173
|
displayName: "FixedSizeContainer__Item",
|
|
174
174
|
componentId: "sc-1yhgpod-0"
|
|
175
175
|
})(["position:relative;background-color:", "};"], function (props) {
|
|
176
|
-
return colorUtils_1.isColor(props.backgroundColor) && props.backgroundColor || props.theme.defaultBackgroundColor;
|
|
176
|
+
return (0, colorUtils_1.isColor)(props.backgroundColor) && props.backgroundColor || props.theme.defaultBackgroundColor;
|
|
177
177
|
});
|
|
178
178
|
// Use `.attrs()` for highly dynamic styles. Ref: https://github.com/styled-components/styled-components/issues/134#issuecomment-312415291
|
|
179
179
|
var FixSizeItem = styled_components_1.default.div.attrs(function (_ref2) {
|
|
@@ -181,16 +181,16 @@ var FixSizeItem = styled_components_1.default.div.attrs(function (_ref2) {
|
|
|
181
181
|
height = _ref2.height;
|
|
182
182
|
return {
|
|
183
183
|
style: Object.assign(Object.assign({}, width && {
|
|
184
|
-
width: style_1.toPx(width)
|
|
184
|
+
width: (0, style_1.toPx)(width)
|
|
185
185
|
}), height && {
|
|
186
|
-
height: style_1.toPx(height)
|
|
186
|
+
height: (0, style_1.toPx)(height)
|
|
187
187
|
})
|
|
188
188
|
};
|
|
189
189
|
}).withConfig({
|
|
190
190
|
displayName: "FixedSizeContainer__FixSizeItem",
|
|
191
191
|
componentId: "sc-1yhgpod-1"
|
|
192
192
|
})(["position:relative;flex-direction:column;flex:1;display:flex;background-color:", "};"], function (props) {
|
|
193
|
-
return colorUtils_1.isColor(props.backgroundColor) && props.backgroundColor || props.theme.defaultBackgroundColor;
|
|
193
|
+
return (0, colorUtils_1.isColor)(props.backgroundColor) && props.backgroundColor || props.theme.defaultBackgroundColor;
|
|
194
194
|
});
|
|
195
195
|
var ItemContent = styled_components_1.default.div.withConfig({
|
|
196
196
|
displayName: "FixedSizeContainer__ItemContent",
|
|
@@ -214,7 +214,7 @@ var withFixedSizeContainer = function withFixedSizeContainer(Viz) {
|
|
|
214
214
|
}
|
|
215
215
|
return React.createElement(FixSizeItem, {
|
|
216
216
|
"data-test": "fix-size-item",
|
|
217
|
-
"data-splunk-visualization-version": "
|
|
217
|
+
"data-splunk-visualization-version": "26.0.0 - 2f7458907",
|
|
218
218
|
width: width,
|
|
219
219
|
height: height,
|
|
220
220
|
backgroundColor: backgroundColor
|
|
@@ -272,13 +272,20 @@ exports.extendStaticWrapperProps = extendStaticWrapperProps;
|
|
|
272
272
|
|
|
273
273
|
/***/ }),
|
|
274
274
|
|
|
275
|
-
/***/
|
|
275
|
+
/***/ 16:
|
|
276
|
+
/***/ (function(module, exports) {
|
|
277
|
+
|
|
278
|
+
module.exports = require("@splunk/visualizations-shared/schemaUtils");
|
|
279
|
+
|
|
280
|
+
/***/ }),
|
|
281
|
+
|
|
282
|
+
/***/ 161:
|
|
276
283
|
/***/ (function(module, exports, __webpack_require__) {
|
|
277
284
|
|
|
278
285
|
"use strict";
|
|
279
286
|
|
|
280
287
|
|
|
281
|
-
var _taggedTemplateLiteral = __webpack_require__(
|
|
288
|
+
var _taggedTemplateLiteral = __webpack_require__(59);
|
|
282
289
|
var _templateObject;
|
|
283
290
|
Object.defineProperty(exports, "__esModule", {
|
|
284
291
|
value: true
|
|
@@ -288,16 +295,16 @@ var lodash_1 = __webpack_require__(3);
|
|
|
288
295
|
var types_1 = __webpack_require__(94);
|
|
289
296
|
var React = __webpack_require__(1);
|
|
290
297
|
var style_1 = __webpack_require__(14);
|
|
291
|
-
var Markdown_1 = __webpack_require__(
|
|
298
|
+
var Markdown_1 = __webpack_require__(122);
|
|
292
299
|
var styled_components_1 = __webpack_require__(4);
|
|
293
300
|
var T = __webpack_require__(0);
|
|
294
|
-
var themes_1 = __webpack_require__(
|
|
295
|
-
var Heading_1 = __webpack_require__(
|
|
296
|
-
var Paragraph_1 = __webpack_require__(
|
|
297
|
-
var List_1 = __webpack_require__(
|
|
298
|
-
var Code_1 = __webpack_require__(
|
|
301
|
+
var themes_1 = __webpack_require__(60);
|
|
302
|
+
var Heading_1 = __webpack_require__(125);
|
|
303
|
+
var Paragraph_1 = __webpack_require__(110);
|
|
304
|
+
var List_1 = __webpack_require__(424);
|
|
305
|
+
var Code_1 = __webpack_require__(425);
|
|
299
306
|
var withDashboardViz_1 = __webpack_require__(36);
|
|
300
|
-
var config_1 = __webpack_require__(
|
|
307
|
+
var config_1 = __webpack_require__(426);
|
|
301
308
|
exports.config = config_1.default;
|
|
302
309
|
// map of valid font sizes with elements' respective pixel sizes
|
|
303
310
|
exports.FONT_SIZES = {
|
|
@@ -341,9 +348,9 @@ var MarkdownContainer = styled_components_1.default.div.withConfig({
|
|
|
341
348
|
displayName: "Markdown__MarkdownContainer",
|
|
342
349
|
componentId: "zd3qkg-0"
|
|
343
350
|
})(["overflow:auto;position:relative;box-sizing:border-box;", ";", ";background-color:", ";transform-origin:center;transform:rotate(", "deg);& *:not(code):not(pre):not(code *):not(a){color:", ";}", ";"], function (props) {
|
|
344
|
-
return style_1.toDimension(lodash_1.pick(props, ['width', 'height']));
|
|
351
|
+
return (0, style_1.toDimension)((0, lodash_1.pick)(props, ['width', 'height']));
|
|
345
352
|
}, function (props) {
|
|
346
|
-
return style_1.toPadding(props.padding);
|
|
353
|
+
return (0, style_1.toPadding)(props.padding);
|
|
347
354
|
}, function (props) {
|
|
348
355
|
return props.backgroundColor;
|
|
349
356
|
}, function (props) {
|
|
@@ -357,13 +364,13 @@ var MarkdownContainer = styled_components_1.default.div.withConfig({
|
|
|
357
364
|
var CodeBlockContainer = styled_components_1.default.div.withConfig({
|
|
358
365
|
displayName: "Markdown__CodeBlockContainer",
|
|
359
366
|
componentId: "zd3qkg-1"
|
|
360
|
-
})(["padding:", ";margin:", " 0;background-color:", ";pre[data-test='code']{margin-bottom:0px;}code{font-size:", "px !important;line-height:", "px !important;}"], themes_1.pick({
|
|
367
|
+
})(["padding:", ";margin:", " 0;background-color:", ";pre[data-test='code']{margin-bottom:0px;}code{font-size:", "px !important;line-height:", "px !important;}"], (0, themes_1.pick)({
|
|
361
368
|
enterprise: themes_1.variables.spacingHalf,
|
|
362
|
-
prisma: styled_components_1.css(_templateObject || (_templateObject = _taggedTemplateLiteral(["10px ", ""])), themes_1.variables.spacingLarge)
|
|
363
|
-
}), themes_1.pick({
|
|
369
|
+
prisma: (0, styled_components_1.css)(_templateObject || (_templateObject = _taggedTemplateLiteral(["10px ", ""])), themes_1.variables.spacingLarge)
|
|
370
|
+
}), (0, themes_1.pick)({
|
|
364
371
|
enterprise: themes_1.variables.spacingHalf,
|
|
365
372
|
prisma: themes_1.variables.spacingLarge
|
|
366
|
-
}), themes_1.pick({
|
|
373
|
+
}), (0, themes_1.pick)({
|
|
367
374
|
enterprise: {
|
|
368
375
|
light: themes_1.variables.gray96,
|
|
369
376
|
dark: themes_1.variables.gray22
|
|
@@ -377,7 +384,7 @@ var CodeBlockContainer = styled_components_1.default.div.withConfig({
|
|
|
377
384
|
var CodeInlineContainer = styled_components_1.default.code.withConfig({
|
|
378
385
|
displayName: "Markdown__CodeInlineContainer",
|
|
379
386
|
componentId: "zd3qkg-2"
|
|
380
|
-
})(["", ";font-family:", ";background-color:", ";"], themes_1.mixins.reset('inline'), themes_1.variables.monoFontFamily, themes_1.pick({
|
|
387
|
+
})(["", ";font-family:", ";background-color:", ";"], themes_1.mixins.reset('inline'), themes_1.variables.monoFontFamily, (0, themes_1.pick)({
|
|
381
388
|
enterprise: {
|
|
382
389
|
light: themes_1.variables.gray92,
|
|
383
390
|
dark: themes_1.variables.gray22
|
|
@@ -405,7 +412,7 @@ var StyledA = styled_components_1.default.a.withConfig({
|
|
|
405
412
|
// returns renderers customized with the appropriate font sizes given the provided `fontSize` value.
|
|
406
413
|
var getMarkdownRenderer = function getMarkdownRenderer(fontFamilyStyle, fontSize, customFontSize) {
|
|
407
414
|
// defaults to customFontSize of 14px if value is invalid
|
|
408
|
-
var cleanedCustomFontSize = types_1.isNumber(customFontSize) ? customFontSize : 14;
|
|
415
|
+
var cleanedCustomFontSize = (0, types_1.isNumber)(customFontSize) ? customFontSize : 14;
|
|
409
416
|
var isCustomFontSize = fontSize === 'custom';
|
|
410
417
|
/* eslint-disable react/display-name, react/prop-types */
|
|
411
418
|
var fontMap = isCustomFontSize ? {
|
|
@@ -489,8 +496,8 @@ var MarkdownVisualization = function MarkdownVisualization(_ref8) {
|
|
|
489
496
|
hasEventHandlers = _ref8.hasEventHandlers,
|
|
490
497
|
onMarkdownClick = _ref8.onMarkdownClick;
|
|
491
498
|
var _a;
|
|
492
|
-
var
|
|
493
|
-
defaultFontFamily =
|
|
499
|
+
var _ref9 = (0, themes_1.useSplunkTheme)(),
|
|
500
|
+
defaultFontFamily = _ref9.fontFamily; // font-family style for non-code content - default font family appended to custom option value as fallback
|
|
494
501
|
var markdownContentFontFamilyStyle = {
|
|
495
502
|
fontFamily: "".concat(fontFamily, ", ").concat(defaultFontFamily)
|
|
496
503
|
};
|
|
@@ -548,7 +555,7 @@ var computeVizProps = function computeVizProps(props) {
|
|
|
548
555
|
return props;
|
|
549
556
|
};
|
|
550
557
|
exports.computeVizProps = computeVizProps;
|
|
551
|
-
var Markdown = withDashboardViz_1.default({
|
|
558
|
+
var Markdown = (0, withDashboardViz_1.default)({
|
|
552
559
|
ReactViz: MarkdownVisualization,
|
|
553
560
|
vizConfig: config_1.default,
|
|
554
561
|
computeVizProps: exports.computeVizProps
|
|
@@ -559,13 +566,6 @@ exports.default = Markdown;
|
|
|
559
566
|
|
|
560
567
|
/***/ }),
|
|
561
568
|
|
|
562
|
-
/***/ 16:
|
|
563
|
-
/***/ (function(module, exports) {
|
|
564
|
-
|
|
565
|
-
module.exports = require("@splunk/visualizations-shared/schemaUtils");
|
|
566
|
-
|
|
567
|
-
/***/ }),
|
|
568
|
-
|
|
569
569
|
/***/ 17:
|
|
570
570
|
/***/ (function(module, exports) {
|
|
571
571
|
|
|
@@ -754,8 +754,8 @@ function hasCompatibleOptions(vizOptions, presetOptions) {
|
|
|
754
754
|
*/
|
|
755
755
|
function getInitialPreset(vizContext, vizOptions, presets) {
|
|
756
756
|
return presets.find(function (preset) {
|
|
757
|
-
var presetContext = lodash_1.get(preset, ['value', 'context'], {});
|
|
758
|
-
var presetOptions = lodash_1.get(preset, ['value', 'options'], {});
|
|
757
|
+
var presetContext = (0, lodash_1.get)(preset, ['value', 'context'], {});
|
|
758
|
+
var presetOptions = (0, lodash_1.get)(preset, ['value', 'options'], {});
|
|
759
759
|
var presetContextKeys = Object.keys(presetContext);
|
|
760
760
|
var presetOptionKeys = Object.keys(presetOptions);
|
|
761
761
|
// all presets have to explicitly specify which options to reset (i.e. need explicitly undefined keys)
|
|
@@ -772,7 +772,7 @@ exports.getInitialPreset = getInitialPreset;
|
|
|
772
772
|
* @returns {{ label: string; value; string }[]} array of { label, value } tuples
|
|
773
773
|
*/
|
|
774
774
|
function generatePrecisionValues(numPrecisionValues) {
|
|
775
|
-
return lodash_1.range(0, numPrecisionValues + 1).map(function (i) {
|
|
775
|
+
return (0, lodash_1.range)(0, numPrecisionValues + 1).map(function (i) {
|
|
776
776
|
return {
|
|
777
777
|
label: "".concat(i, " (0").concat(i > 0 ? '.' : '').concat('0'.repeat(i), ")"),
|
|
778
778
|
value: i
|
|
@@ -808,28 +808,28 @@ module.exports = require("@splunk/visualization-context/FeatureFlagContext");
|
|
|
808
808
|
/***/ 25:
|
|
809
809
|
/***/ (function(module, exports) {
|
|
810
810
|
|
|
811
|
-
module.exports = require("@splunk/
|
|
811
|
+
module.exports = require("@splunk/ui-utils/id");
|
|
812
812
|
|
|
813
813
|
/***/ }),
|
|
814
814
|
|
|
815
815
|
/***/ 26:
|
|
816
816
|
/***/ (function(module, exports) {
|
|
817
817
|
|
|
818
|
-
module.exports = require("@splunk/
|
|
818
|
+
module.exports = require("@splunk/visualization-context/TimezoneContext");
|
|
819
819
|
|
|
820
820
|
/***/ }),
|
|
821
821
|
|
|
822
822
|
/***/ 27:
|
|
823
823
|
/***/ (function(module, exports) {
|
|
824
824
|
|
|
825
|
-
module.exports = require("@splunk/visualizations-shared/
|
|
825
|
+
module.exports = require("@splunk/visualizations-shared/hocUtils");
|
|
826
826
|
|
|
827
827
|
/***/ }),
|
|
828
828
|
|
|
829
|
-
/***/
|
|
829
|
+
/***/ 28:
|
|
830
830
|
/***/ (function(module, exports) {
|
|
831
831
|
|
|
832
|
-
module.exports = require("@splunk/
|
|
832
|
+
module.exports = require("@splunk/visualizations-shared/JSONSchemaUtils");
|
|
833
833
|
|
|
834
834
|
/***/ }),
|
|
835
835
|
|
|
@@ -840,7 +840,14 @@ module.exports = require("lodash");
|
|
|
840
840
|
|
|
841
841
|
/***/ }),
|
|
842
842
|
|
|
843
|
-
/***/
|
|
843
|
+
/***/ 30:
|
|
844
|
+
/***/ (function(module, exports) {
|
|
845
|
+
|
|
846
|
+
module.exports = require("@splunk/visualization-encoding/Options");
|
|
847
|
+
|
|
848
|
+
/***/ }),
|
|
849
|
+
|
|
850
|
+
/***/ 32:
|
|
844
851
|
/***/ (function(module, exports, __webpack_require__) {
|
|
845
852
|
|
|
846
853
|
"use strict";
|
|
@@ -864,9 +871,9 @@ var FixedSizeContainer_1 = __webpack_require__(13);
|
|
|
864
871
|
*/
|
|
865
872
|
var shouldShowIconPlaceholder = function shouldShowIconPlaceholder(dataSources) {
|
|
866
873
|
var loading = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
867
|
-
var data = lodash_1.get(dataSources, 'primary.data.columns[0]', undefined);
|
|
874
|
+
var data = (0, lodash_1.get)(dataSources, 'primary.data.columns[0]', undefined);
|
|
868
875
|
var noData = data === undefined;
|
|
869
|
-
var fields = lodash_1.get(dataSources, 'primary.data.fields[0]', undefined);
|
|
876
|
+
var fields = (0, lodash_1.get)(dataSources, 'primary.data.fields[0]', undefined);
|
|
870
877
|
var noFields = fields === undefined;
|
|
871
878
|
return loading || noData || noFields;
|
|
872
879
|
};
|
|
@@ -907,7 +914,7 @@ var IconPlaceholder = function IconPlaceholder(props) {
|
|
|
907
914
|
width: width,
|
|
908
915
|
height: height,
|
|
909
916
|
level: "warning",
|
|
910
|
-
message: i18n_1._('No DataSource Connected')
|
|
917
|
+
message: (0, i18n_1._)('No DataSource Connected')
|
|
911
918
|
});
|
|
912
919
|
};
|
|
913
920
|
IconPlaceholder.propTypes = propTypes;
|
|
@@ -915,14 +922,7 @@ IconPlaceholder.defaultProps = {
|
|
|
915
922
|
width: '100%',
|
|
916
923
|
height: 250
|
|
917
924
|
};
|
|
918
|
-
exports.default = FixedSizeContainer_1.default(IconPlaceholder);
|
|
919
|
-
|
|
920
|
-
/***/ }),
|
|
921
|
-
|
|
922
|
-
/***/ 32:
|
|
923
|
-
/***/ (function(module, exports) {
|
|
924
|
-
|
|
925
|
-
module.exports = require("@splunk/ui-utils/id");
|
|
925
|
+
exports.default = (0, FixedSizeContainer_1.default)(IconPlaceholder);
|
|
926
926
|
|
|
927
927
|
/***/ }),
|
|
928
928
|
|
|
@@ -957,7 +957,7 @@ var getSortingParams = function getSortingParams(_ref) {
|
|
|
957
957
|
};
|
|
958
958
|
var onSort;
|
|
959
959
|
if (typeof onRequestParamsChange === 'function') {
|
|
960
|
-
if (requestParams && lodash_1.has(requestParams, 'sort')) {
|
|
960
|
+
if (requestParams && (0, lodash_1.has)(requestParams, 'sort')) {
|
|
961
961
|
currentSortKey = Object.keys(requestParams.sort).shift();
|
|
962
962
|
currentSortDir = requestParams.sort[currentSortKey];
|
|
963
963
|
}
|
|
@@ -966,7 +966,7 @@ var getSortingParams = function getSortingParams(_ref) {
|
|
|
966
966
|
var sortKey = _ref2.sortKey,
|
|
967
967
|
sortDir = _ref2.sortDir;
|
|
968
968
|
if (typeof sortKey === 'string') {
|
|
969
|
-
var nextSortDir = lodash_1.has(nextSortDirMap, sortDir) ? nextSortDirMap[sortDir] : 'none';
|
|
969
|
+
var nextSortDir = (0, lodash_1.has)(nextSortDirMap, sortDir) ? nextSortDirMap[sortDir] : 'none';
|
|
970
970
|
onRequestParamsChange(Object.assign(Object.assign({}, requestParams), {
|
|
971
971
|
offset: 0,
|
|
972
972
|
sort: _defineProperty({}, sortKey, nextSortDir)
|
|
@@ -1017,7 +1017,7 @@ var getPaginationParams = function getPaginationParams(_ref) {
|
|
|
1017
1017
|
var onChangeHandler = function onChangeHandler(e, _ref2) {
|
|
1018
1018
|
var page = _ref2.page,
|
|
1019
1019
|
countArg = _ref2.count;
|
|
1020
|
-
var newParams = lodash_1.cloneDeep(requestParams);
|
|
1020
|
+
var newParams = (0, lodash_1.cloneDeep)(requestParams);
|
|
1021
1021
|
if (typeof countArg === 'number') {
|
|
1022
1022
|
newParams.count = countArg;
|
|
1023
1023
|
newParams.offset = 0;
|
|
@@ -1081,16 +1081,16 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
1081
1081
|
var React = __webpack_require__(1);
|
|
1082
1082
|
var lodash_1 = __webpack_require__(3);
|
|
1083
1083
|
var getSettingsFromThemedProps_1 = __webpack_require__(37);
|
|
1084
|
-
var Options_1 = __webpack_require__(
|
|
1084
|
+
var Options_1 = __webpack_require__(30);
|
|
1085
1085
|
var SanitizeProps_1 = __webpack_require__(38);
|
|
1086
|
-
var TimezoneContext_1 = __webpack_require__(
|
|
1086
|
+
var TimezoneContext_1 = __webpack_require__(26);
|
|
1087
1087
|
var moment_1 = __webpack_require__(39);
|
|
1088
1088
|
var FeatureFlagContext_1 = __webpack_require__(21);
|
|
1089
1089
|
var styled_components_1 = __webpack_require__(4);
|
|
1090
|
-
var hocUtils_1 = __webpack_require__(
|
|
1091
|
-
var JSONSchemaUtils_1 = __webpack_require__(
|
|
1090
|
+
var hocUtils_1 = __webpack_require__(27);
|
|
1091
|
+
var JSONSchemaUtils_1 = __webpack_require__(28);
|
|
1092
1092
|
var async_dynamic_options_evaluator_1 = __webpack_require__(40);
|
|
1093
|
-
var id_1 = __webpack_require__(
|
|
1093
|
+
var id_1 = __webpack_require__(25);
|
|
1094
1094
|
var SplunkVisualization_1 = __webpack_require__(41);
|
|
1095
1095
|
var VizBehavior_1 = __webpack_require__(6);
|
|
1096
1096
|
var getSorting_1 = __webpack_require__(33);
|
|
@@ -1111,8 +1111,8 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1111
1111
|
computeVizProps = _opts$computeVizProps === void 0 ? function () {} : _opts$computeVizProps,
|
|
1112
1112
|
disableEditModeCover = opts.disableEditModeCover,
|
|
1113
1113
|
useIconPlaceholder = opts.useIconPlaceholder; // sanitizing props before sending them to reactviz.
|
|
1114
|
-
var SanitizedReactViz = SanitizeProps_1.withSanitizedProps(ReactViz);
|
|
1115
|
-
var defaultOptions = JSONSchemaUtils_1.pickFieldFromJSONSchema(vizConfig.optionsSchema, 'default');
|
|
1114
|
+
var SanitizedReactViz = (0, SanitizeProps_1.withSanitizedProps)(ReactViz);
|
|
1115
|
+
var defaultOptions = (0, JSONSchemaUtils_1.pickFieldFromJSONSchema)(vizConfig.optionsSchema, 'default');
|
|
1116
1116
|
var DashboardViz = function DashboardViz(props) {
|
|
1117
1117
|
var _a;
|
|
1118
1118
|
var mode = props.mode,
|
|
@@ -1147,19 +1147,19 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1147
1147
|
return (_b = (_a = vizConfig.themes)[themeVar]) === null || _b === void 0 ? void 0 : _b.call(_a, props);
|
|
1148
1148
|
};
|
|
1149
1149
|
var bgColorFromTheme = themeFunc('defaultBackgroundColor');
|
|
1150
|
-
var
|
|
1150
|
+
var _ref = (0, getSettingsFromThemedProps_1.default)({
|
|
1151
1151
|
theme: theme
|
|
1152
1152
|
}),
|
|
1153
|
-
currentThemeFamily =
|
|
1154
|
-
currentThemeColorScheme =
|
|
1155
|
-
currentThemeDensity =
|
|
1153
|
+
currentThemeFamily = _ref.family,
|
|
1154
|
+
currentThemeColorScheme = _ref.colorScheme,
|
|
1155
|
+
currentThemeDensity = _ref.density;
|
|
1156
1156
|
var evaluatedOptions = {}; // evaluatedOptions need to be initialized as an empty object
|
|
1157
1157
|
var _React$useState = React.useState({}),
|
|
1158
1158
|
_React$useState2 = _slicedToArray(_React$useState, 2),
|
|
1159
1159
|
evaluatedOptionsAsync = _React$useState2[0],
|
|
1160
1160
|
setEvaluatedOptionsAsync = _React$useState2[1]; // evaluatedOptions need to be initialized as an empty object
|
|
1161
1161
|
var featureFlagContext = React.useContext(FeatureFlagContext_1.default);
|
|
1162
|
-
var _React$useState3 = React.useState("".concat(vizConfig.name, " - ").concat(id_1.createGUID())),
|
|
1162
|
+
var _React$useState3 = React.useState("".concat(vizConfig.name, " - ").concat((0, id_1.createGUID)())),
|
|
1163
1163
|
_React$useState4 = _slicedToArray(_React$useState3, 1),
|
|
1164
1164
|
visualizationID = _React$useState4[0];
|
|
1165
1165
|
var _React$useState5 = React.useState({}),
|
|
@@ -1170,16 +1170,17 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1170
1170
|
_React$useState8 = _slicedToArray(_React$useState7, 2),
|
|
1171
1171
|
dataFramesInState = _React$useState8[0],
|
|
1172
1172
|
setDataFramesInState = _React$useState8[1];
|
|
1173
|
-
var _React$useState9 = React.useState(Boolean(featureFlagContext
|
|
1173
|
+
var _React$useState9 = React.useState(Boolean(featureFlagContext === null || featureFlagContext === void 0 ? void 0 : featureFlagContext.visualizations_useWebWorkersForDSL)),
|
|
1174
1174
|
_React$useState10 = _slicedToArray(_React$useState9, 2),
|
|
1175
1175
|
useAsyncEvaluatedOptions = _React$useState10[0],
|
|
1176
1176
|
setUseAsyncEvaluatedOptions = _React$useState10[1];
|
|
1177
|
-
|
|
1177
|
+
var isMounted = React.useRef(true);
|
|
1178
|
+
evaluatedOptions = (0, useDeepMemo_1.useDeepMemo)(function () {
|
|
1178
1179
|
try {
|
|
1179
1180
|
if (useAsyncEvaluatedOptions) {
|
|
1180
1181
|
var optionsToEvaluate = {
|
|
1181
|
-
context: lodash_1.defaultsDeep({}, context, vizConfig.defaultContext),
|
|
1182
|
-
options: hocUtils_1.deepMergeWithArrayPrimitiveOverrides({}, options, defaultOptions)
|
|
1182
|
+
context: (0, lodash_1.defaultsDeep)({}, context, vizConfig.defaultContext),
|
|
1183
|
+
options: (0, hocUtils_1.deepMergeWithArrayPrimitiveOverrides)({}, options, defaultOptions)
|
|
1183
1184
|
};
|
|
1184
1185
|
var asyncDynamicOptionsEvaluatorParams = {
|
|
1185
1186
|
visualizationID: visualizationID,
|
|
@@ -1190,10 +1191,10 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1190
1191
|
};
|
|
1191
1192
|
async_dynamic_options_evaluator_1.default.evaluate(asyncDynamicOptionsEvaluatorParams).then(function (results) {
|
|
1192
1193
|
setEvaluatedOptionsAsync(results.results);
|
|
1193
|
-
}).catch(function (
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1194
|
+
}).catch(function () {
|
|
1195
|
+
if (isMounted.current) {
|
|
1196
|
+
setUseAsyncEvaluatedOptions(false);
|
|
1197
|
+
}
|
|
1197
1198
|
});
|
|
1198
1199
|
} else {
|
|
1199
1200
|
var dataFrames = dataFramesInState;
|
|
@@ -1203,8 +1204,8 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1203
1204
|
setDataFramesInState(dataFrames);
|
|
1204
1205
|
}
|
|
1205
1206
|
return Options_1.Options.evaluate({
|
|
1206
|
-
context: lodash_1.defaultsDeep({}, context, vizConfig.defaultContext),
|
|
1207
|
-
options: hocUtils_1.deepMergeWithArrayPrimitiveOverrides({}, options, defaultOptions)
|
|
1207
|
+
context: (0, lodash_1.defaultsDeep)({}, context, vizConfig.defaultContext),
|
|
1208
|
+
options: (0, hocUtils_1.deepMergeWithArrayPrimitiveOverrides)({}, options, defaultOptions)
|
|
1208
1209
|
}, dataSources, themeFunc, dataFrames);
|
|
1209
1210
|
}
|
|
1210
1211
|
} catch (e) {
|
|
@@ -1233,6 +1234,7 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1233
1234
|
React.useEffect(function () {
|
|
1234
1235
|
return function () {
|
|
1235
1236
|
if (useAsyncEvaluatedOptions) {
|
|
1237
|
+
isMounted.current = false;
|
|
1236
1238
|
async_dynamic_options_evaluator_1.default.reset(visualizationID);
|
|
1237
1239
|
}
|
|
1238
1240
|
};
|
|
@@ -1242,7 +1244,7 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1242
1244
|
var _vizConfig$requiredPr = vizConfig.requiredProps,
|
|
1243
1245
|
requiredProps = _vizConfig$requiredPr === void 0 ? [] : _vizConfig$requiredPr,
|
|
1244
1246
|
supports = vizConfig.supports;
|
|
1245
|
-
var missing = MissingPropsMessage_1.missingKeys(requiredProps, evaluatedOptionsToUse);
|
|
1247
|
+
var missing = (0, MissingPropsMessage_1.missingKeys)(requiredProps, evaluatedOptionsToUse);
|
|
1246
1248
|
if (missing.length > 0 && supports.includes(VizBehavior_1.VizBehavior.PLACEHOLDER) && vizConfig.key !== 'splunk.singlevalue' // For SV missing props msg is not displayed if required props majorValue is missing, instead this will be handled from the component, instead handled within component
|
|
1247
1249
|
) {
|
|
1248
1250
|
return React.createElement(MissingPropsMessage_1.default, {
|
|
@@ -1258,7 +1260,7 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1258
1260
|
if (hasEventHandlers && mode === 'view' && vizConfig.supports.indexOf(VizBehavior_1.VizBehavior.EVENTS) > -1) {
|
|
1259
1261
|
var supportedEvents = vizConfig.events;
|
|
1260
1262
|
Object.keys(supportedEvents).forEach(function (eventName) {
|
|
1261
|
-
var eventCallbackPropName = lodash_1.camelCase("on.".concat(eventName));
|
|
1263
|
+
var eventCallbackPropName = (0, lodash_1.camelCase)("on.".concat(eventName));
|
|
1262
1264
|
eventCallbackProps[eventCallbackPropName] = null;
|
|
1263
1265
|
// todo: refactor single value and single value icon to send payload from viz
|
|
1264
1266
|
// then remove these lines
|
|
@@ -1301,19 +1303,19 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1301
1303
|
*/
|
|
1302
1304
|
var dataSourceMetadata = {};
|
|
1303
1305
|
var OptionKey = 'paginateDataSourceKey';
|
|
1304
|
-
var paginateDataSourceKey = lodash_1.has(evaluatedOptionsToUse, OptionKey) && evaluatedOptionsToUse[OptionKey] || 'primary';
|
|
1305
|
-
if (vizConfig.supports.indexOf(VizBehavior_1.VizBehavior.PAGE_AND_SORT) > -1 && lodash_1.has(dataSources, paginateDataSourceKey)) {
|
|
1306
|
-
var requestParams = lodash_1.get(dataSources, [paginateDataSourceKey, 'requestParams'], {});
|
|
1307
|
-
var meta = lodash_1.get(dataSources, [paginateDataSourceKey, 'meta'], {});
|
|
1306
|
+
var paginateDataSourceKey = (0, lodash_1.has)(evaluatedOptionsToUse, OptionKey) && evaluatedOptionsToUse[OptionKey] || 'primary';
|
|
1307
|
+
if (vizConfig.supports.indexOf(VizBehavior_1.VizBehavior.PAGE_AND_SORT) > -1 && (0, lodash_1.has)(dataSources, paginateDataSourceKey)) {
|
|
1308
|
+
var requestParams = (0, lodash_1.get)(dataSources, [paginateDataSourceKey, 'requestParams'], {});
|
|
1309
|
+
var meta = (0, lodash_1.get)(dataSources, [paginateDataSourceKey, 'meta'], {});
|
|
1308
1310
|
var handleRequestParamsChange = function handleRequestParamsChange(payload) {
|
|
1309
1311
|
return onRequestParamsChange(paginateDataSourceKey, payload);
|
|
1310
1312
|
};
|
|
1311
|
-
var sortParams = getSorting_1.getSortingParams({
|
|
1313
|
+
var sortParams = (0, getSorting_1.getSortingParams)({
|
|
1312
1314
|
requestParams: requestParams,
|
|
1313
1315
|
meta: meta,
|
|
1314
1316
|
onRequestParamsChange: handleRequestParamsChange
|
|
1315
1317
|
});
|
|
1316
|
-
var paginatorParams = getPagination_1.getPaginationParams({
|
|
1318
|
+
var paginatorParams = (0, getPagination_1.getPaginationParams)({
|
|
1317
1319
|
requestParams: requestParams,
|
|
1318
1320
|
meta: meta,
|
|
1319
1321
|
onRequestParamsChange: handleRequestParamsChange
|
|
@@ -1341,7 +1343,7 @@ var withDashboardViz = function withDashboardViz(opts) {
|
|
|
1341
1343
|
// attach viz config
|
|
1342
1344
|
DashboardViz.config = vizConfig;
|
|
1343
1345
|
// @ts-ignore: TODO fix sc upgrade TS issues
|
|
1344
|
-
return styled_components_1.withTheme(withPlaceholder_1.default(withEditModeCover_1.default(DashboardViz, disableEditModeCover), useIconPlaceholder));
|
|
1346
|
+
return (0, styled_components_1.withTheme)((0, withPlaceholder_1.default)((0, withEditModeCover_1.default)(DashboardViz, disableEditModeCover), useIconPlaceholder));
|
|
1345
1347
|
};
|
|
1346
1348
|
exports.default = withDashboardViz;
|
|
1347
1349
|
|
|
@@ -1545,7 +1547,7 @@ exports.DefaultVizActionHandler = DefaultVizActionHandler;
|
|
|
1545
1547
|
|
|
1546
1548
|
/***/ }),
|
|
1547
1549
|
|
|
1548
|
-
/***/
|
|
1550
|
+
/***/ 423:
|
|
1549
1551
|
/***/ (function(module, exports, __webpack_require__) {
|
|
1550
1552
|
|
|
1551
1553
|
"use strict";
|
|
@@ -1553,12 +1555,16 @@ exports.DefaultVizActionHandler = DefaultVizActionHandler;
|
|
|
1553
1555
|
|
|
1554
1556
|
var __createBinding = this && this.__createBinding || (Object.create ? function (o, m, k, k2) {
|
|
1555
1557
|
if (k2 === undefined) k2 = k;
|
|
1556
|
-
Object.
|
|
1557
|
-
|
|
1558
|
-
|
|
1559
|
-
|
|
1560
|
-
|
|
1561
|
-
|
|
1558
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
1559
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
1560
|
+
desc = {
|
|
1561
|
+
enumerable: true,
|
|
1562
|
+
get: function get() {
|
|
1563
|
+
return m[k];
|
|
1564
|
+
}
|
|
1565
|
+
};
|
|
1566
|
+
}
|
|
1567
|
+
Object.defineProperty(o, k2, desc);
|
|
1562
1568
|
} : function (o, m, k, k2) {
|
|
1563
1569
|
if (k2 === undefined) k2 = k;
|
|
1564
1570
|
o[k2] = m[k];
|
|
@@ -1572,8 +1578,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
1572
1578
|
value: true
|
|
1573
1579
|
});
|
|
1574
1580
|
exports.default = void 0;
|
|
1575
|
-
__exportStar(__webpack_require__(
|
|
1576
|
-
var Markdown_1 = __webpack_require__(
|
|
1581
|
+
__exportStar(__webpack_require__(161), exports);
|
|
1582
|
+
var Markdown_1 = __webpack_require__(161);
|
|
1577
1583
|
Object.defineProperty(exports, "default", {
|
|
1578
1584
|
enumerable: true,
|
|
1579
1585
|
get: function get() {
|
|
@@ -1583,21 +1589,21 @@ Object.defineProperty(exports, "default", {
|
|
|
1583
1589
|
|
|
1584
1590
|
/***/ }),
|
|
1585
1591
|
|
|
1586
|
-
/***/
|
|
1592
|
+
/***/ 424:
|
|
1587
1593
|
/***/ (function(module, exports) {
|
|
1588
1594
|
|
|
1589
1595
|
module.exports = require("@splunk/react-ui/List");
|
|
1590
1596
|
|
|
1591
1597
|
/***/ }),
|
|
1592
1598
|
|
|
1593
|
-
/***/
|
|
1599
|
+
/***/ 425:
|
|
1594
1600
|
/***/ (function(module, exports) {
|
|
1595
1601
|
|
|
1596
1602
|
module.exports = require("@splunk/react-ui/Code");
|
|
1597
1603
|
|
|
1598
1604
|
/***/ }),
|
|
1599
1605
|
|
|
1600
|
-
/***/
|
|
1606
|
+
/***/ 426:
|
|
1601
1607
|
/***/ (function(module, exports, __webpack_require__) {
|
|
1602
1608
|
|
|
1603
1609
|
"use strict";
|
|
@@ -1607,7 +1613,7 @@ var _toConsumableArray = __webpack_require__(8);
|
|
|
1607
1613
|
Object.defineProperty(exports, "__esModule", {
|
|
1608
1614
|
value: true
|
|
1609
1615
|
});
|
|
1610
|
-
var themes_1 = __webpack_require__(
|
|
1616
|
+
var themes_1 = __webpack_require__(60);
|
|
1611
1617
|
var i18n_1 = __webpack_require__(2);
|
|
1612
1618
|
var schemaUtils_1 = __webpack_require__(16);
|
|
1613
1619
|
var VizBehavior_1 = __webpack_require__(6);
|
|
@@ -1656,7 +1662,7 @@ var optionsSchema = {
|
|
|
1656
1662
|
},
|
|
1657
1663
|
fontFamily: {
|
|
1658
1664
|
default: 'Splunk Platform Sans',
|
|
1659
|
-
pattern: schemaUtils_1.getPattern(['Splunk Platform Sans', 'Splunk Data Sans', 'Splunk Platform Mono', 'Arial', 'Helvetica', 'Times New Roman', 'Comic Sans MS']),
|
|
1665
|
+
pattern: (0, schemaUtils_1.getPattern)(['Splunk Platform Sans', 'Splunk Data Sans', 'Splunk Platform Mono', 'Arial', 'Helvetica', 'Times New Roman', 'Comic Sans MS']),
|
|
1660
1666
|
description: 'Specify the font family you would like to use for markdown content, such as "Comic Sans MS". Note: the font needs to be available to your end user.',
|
|
1661
1667
|
type: 'string'
|
|
1662
1668
|
},
|
|
@@ -1664,7 +1670,7 @@ var optionsSchema = {
|
|
|
1664
1670
|
description: 'Specify the font size you would like to use for markdown content. Font sizes range from extra small (10px for unformatted text) to extra large (18px for unformatted text) with the default being 14px for unformatted text.',
|
|
1665
1671
|
type: 'string',
|
|
1666
1672
|
default: 'default',
|
|
1667
|
-
pattern: schemaUtils_1.getPattern(['extraSmall', 'small', 'default', 'large', 'extraLarge', 'custom'])
|
|
1673
|
+
pattern: (0, schemaUtils_1.getPattern)(['extraSmall', 'small', 'default', 'large', 'extraLarge', 'custom'])
|
|
1668
1674
|
},
|
|
1669
1675
|
markdown: {
|
|
1670
1676
|
description: 'Add text using basic markdown syntax.',
|
|
@@ -1678,7 +1684,7 @@ var optionsSchema = {
|
|
|
1678
1684
|
};
|
|
1679
1685
|
var themes = {
|
|
1680
1686
|
defaultFontColor: function defaultFontColor(props) {
|
|
1681
|
-
return themes_1.pick({
|
|
1687
|
+
return (0, themes_1.pick)({
|
|
1682
1688
|
enterprise: {
|
|
1683
1689
|
dark: themes_1.variables.textColor(props),
|
|
1684
1690
|
light: themes_1.variables.textColor(props)
|
|
@@ -1688,20 +1694,20 @@ var themes = {
|
|
|
1688
1694
|
}
|
|
1689
1695
|
};
|
|
1690
1696
|
var editorConfig = [{
|
|
1691
|
-
label: i18n_1._('Color and style'),
|
|
1697
|
+
label: (0, i18n_1._)('Color and style'),
|
|
1692
1698
|
layout: [[{
|
|
1693
|
-
label: i18n_1._('Font'),
|
|
1699
|
+
label: (0, i18n_1._)('Font'),
|
|
1694
1700
|
option: 'fontColor',
|
|
1695
1701
|
editor: 'editor.color',
|
|
1696
1702
|
editorProps: {
|
|
1697
1703
|
labelPosition: 'top',
|
|
1698
1704
|
themes: themes
|
|
1699
1705
|
}
|
|
1700
|
-
}].concat(_toConsumableArray(BackgroundColor_1.default({
|
|
1706
|
+
}].concat(_toConsumableArray((0, BackgroundColor_1.default)({
|
|
1701
1707
|
label: 'Background',
|
|
1702
1708
|
themes: themes
|
|
1703
1709
|
}))), [{
|
|
1704
|
-
label: i18n_1._('Font family'),
|
|
1710
|
+
label: (0, i18n_1._)('Font family'),
|
|
1705
1711
|
option: 'fontFamily',
|
|
1706
1712
|
editor: 'editor.select',
|
|
1707
1713
|
editorProps: {
|
|
@@ -1722,32 +1728,32 @@ var editorConfig = [{
|
|
|
1722
1728
|
}]
|
|
1723
1729
|
}
|
|
1724
1730
|
}], [{
|
|
1725
|
-
label: i18n_1._('Font size'),
|
|
1731
|
+
label: (0, i18n_1._)('Font size'),
|
|
1726
1732
|
option: 'fontSize',
|
|
1727
1733
|
editor: 'editor.select',
|
|
1728
1734
|
editorProps: {
|
|
1729
1735
|
values: [{
|
|
1730
|
-
label: i18n_1._('Extra Small'),
|
|
1736
|
+
label: (0, i18n_1._)('Extra Small'),
|
|
1731
1737
|
value: 'extraSmall'
|
|
1732
1738
|
}, {
|
|
1733
|
-
label: i18n_1._('Small'),
|
|
1739
|
+
label: (0, i18n_1._)('Small'),
|
|
1734
1740
|
value: 'small'
|
|
1735
1741
|
}, {
|
|
1736
|
-
label: i18n_1._('Default'),
|
|
1742
|
+
label: (0, i18n_1._)('Default'),
|
|
1737
1743
|
value: 'default'
|
|
1738
1744
|
}, {
|
|
1739
|
-
label: i18n_1._('Large'),
|
|
1745
|
+
label: (0, i18n_1._)('Large'),
|
|
1740
1746
|
value: 'large'
|
|
1741
1747
|
}, {
|
|
1742
|
-
label: i18n_1._('Extra Large'),
|
|
1748
|
+
label: (0, i18n_1._)('Extra Large'),
|
|
1743
1749
|
value: 'extraLarge'
|
|
1744
1750
|
}, {
|
|
1745
|
-
label: i18n_1._('Custom'),
|
|
1751
|
+
label: (0, i18n_1._)('Custom'),
|
|
1746
1752
|
value: 'custom'
|
|
1747
1753
|
}]
|
|
1748
1754
|
}
|
|
1749
1755
|
}, {
|
|
1750
|
-
label: i18n_1._('Custom font size (px)'),
|
|
1756
|
+
label: (0, i18n_1._)('Custom font size (px)'),
|
|
1751
1757
|
option: 'customFontSize',
|
|
1752
1758
|
editor: 'editor.number',
|
|
1753
1759
|
editorProps: {
|
|
@@ -1759,7 +1765,7 @@ var editorConfig = [{
|
|
|
1759
1765
|
return options.fontSize && !FONT_OPTIONS.has(options.fontSize);
|
|
1760
1766
|
}
|
|
1761
1767
|
}], [{
|
|
1762
|
-
label: i18n_1._('Rotation (degrees)'),
|
|
1768
|
+
label: (0, i18n_1._)('Rotation (degrees)'),
|
|
1763
1769
|
option: 'rotation',
|
|
1764
1770
|
editor: 'editor.number',
|
|
1765
1771
|
editorProps: {
|
|
@@ -1768,7 +1774,7 @@ var editorConfig = [{
|
|
|
1768
1774
|
}
|
|
1769
1775
|
}]]
|
|
1770
1776
|
}, {
|
|
1771
|
-
label: i18n_1._('Markdown content'),
|
|
1777
|
+
label: (0, i18n_1._)('Markdown content'),
|
|
1772
1778
|
open: true,
|
|
1773
1779
|
layout: [[{
|
|
1774
1780
|
label: '',
|
|
@@ -1787,7 +1793,7 @@ var config = {
|
|
|
1787
1793
|
/**
|
|
1788
1794
|
* viz name
|
|
1789
1795
|
*/
|
|
1790
|
-
name: i18n_1._('Markdown'),
|
|
1796
|
+
name: (0, i18n_1._)('Markdown'),
|
|
1791
1797
|
category: VizCategory_1.VizCategory.COMPARISONS,
|
|
1792
1798
|
/**
|
|
1793
1799
|
* viz icon
|
|
@@ -1806,7 +1812,7 @@ var config = {
|
|
|
1806
1812
|
supports: [VizBehavior_1.VizBehavior.DYNAMIC_OPTIONS, VizBehavior_1.VizBehavior.EVENTS],
|
|
1807
1813
|
themes: themes
|
|
1808
1814
|
};
|
|
1809
|
-
exports.default = configUtils_1.enhanceConfig(config);
|
|
1815
|
+
exports.default = (0, configUtils_1.enhanceConfig)(config);
|
|
1810
1816
|
|
|
1811
1817
|
/***/ }),
|
|
1812
1818
|
|
|
@@ -1850,8 +1856,8 @@ var lodash_1 = __webpack_require__(3);
|
|
|
1850
1856
|
* @param dependencies an array of dependencies
|
|
1851
1857
|
*/
|
|
1852
1858
|
var useDeepMemo = function useDeepMemo(fn, dependencies) {
|
|
1853
|
-
var ref = react_1.useRef();
|
|
1854
|
-
if (!ref.current || !lodash_1.isEqual(dependencies, ref.current.dependencies)) {
|
|
1859
|
+
var ref = (0, react_1.useRef)();
|
|
1860
|
+
if (!ref.current || !(0, lodash_1.isEqual)(dependencies, ref.current.dependencies)) {
|
|
1855
1861
|
ref.current = {
|
|
1856
1862
|
dependencies: dependencies,
|
|
1857
1863
|
value: fn()
|
|
@@ -1895,7 +1901,7 @@ exports.isMissing = isMissing;
|
|
|
1895
1901
|
*/
|
|
1896
1902
|
var missingKeys = function missingKeys(keys, target) {
|
|
1897
1903
|
return keys.filter(function (k) {
|
|
1898
|
-
return exports.isMissing(target[k]);
|
|
1904
|
+
return (0, exports.isMissing)(target[k]);
|
|
1899
1905
|
});
|
|
1900
1906
|
};
|
|
1901
1907
|
exports.missingKeys = missingKeys;
|
|
@@ -1919,7 +1925,7 @@ var MissingPropsMessage = function MissingPropsMessage(props) {
|
|
|
1919
1925
|
"data-test": "message",
|
|
1920
1926
|
width: width,
|
|
1921
1927
|
height: height,
|
|
1922
|
-
message: i18n_1._("Missing property: ".concat(missingProps.join(', ')))
|
|
1928
|
+
message: (0, i18n_1._)("Missing property: ".concat(missingProps.join(', ')))
|
|
1923
1929
|
});
|
|
1924
1930
|
};
|
|
1925
1931
|
exports.MissingPropsMessage = MissingPropsMessage;
|
|
@@ -1928,7 +1934,7 @@ exports.MissingPropsMessage.defaultProps = {
|
|
|
1928
1934
|
width: '100%',
|
|
1929
1935
|
height: 250
|
|
1930
1936
|
};
|
|
1931
|
-
exports.default = FixedSizeContainer_1.default(exports.MissingPropsMessage);
|
|
1937
|
+
exports.default = (0, FixedSizeContainer_1.default)(exports.MissingPropsMessage);
|
|
1932
1938
|
|
|
1933
1939
|
/***/ }),
|
|
1934
1940
|
|
|
@@ -1949,7 +1955,7 @@ var Cover = styled_components_1.default.div.withConfig({
|
|
|
1949
1955
|
componentId: "sc-1gsbnxb-0"
|
|
1950
1956
|
})(["position:absolute;left:0;right:0;top:0;bottom:0;"]);
|
|
1951
1957
|
var Blocker = styled_components_1.default.div.attrs({
|
|
1952
|
-
'data-splunk-visualization-version': "
|
|
1958
|
+
'data-splunk-visualization-version': "26.0.0 - 2f7458907"
|
|
1953
1959
|
}).withConfig({
|
|
1954
1960
|
displayName: "withEditModeCover__Blocker",
|
|
1955
1961
|
componentId: "sc-1gsbnxb-1"
|
|
@@ -1968,7 +1974,7 @@ var withEditModeCover = function withEditModeCover(Visualization, disableEditMod
|
|
|
1968
1974
|
"data-test": "edit-mode-cover"
|
|
1969
1975
|
}));
|
|
1970
1976
|
};
|
|
1971
|
-
hocUtils_1.extendStaticWrapperProps({
|
|
1977
|
+
(0, hocUtils_1.extendStaticWrapperProps)({
|
|
1972
1978
|
Wrapper: Wrapper,
|
|
1973
1979
|
Visualization: Visualization
|
|
1974
1980
|
});
|
|
@@ -1990,7 +1996,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
1990
1996
|
var React = __webpack_require__(1);
|
|
1991
1997
|
var colorUtils_1 = __webpack_require__(12);
|
|
1992
1998
|
var variables_1 = __webpack_require__(11);
|
|
1993
|
-
var IconPlaceholder_1 = __webpack_require__(
|
|
1999
|
+
var IconPlaceholder_1 = __webpack_require__(32);
|
|
1994
2000
|
var VizBehavior_1 = __webpack_require__(6);
|
|
1995
2001
|
var hocUtils_1 = __webpack_require__(15);
|
|
1996
2002
|
var withPlaceholder = function withPlaceholder(Visualization) {
|
|
@@ -2005,7 +2011,7 @@ var withPlaceholder = function withPlaceholder(Visualization) {
|
|
|
2005
2011
|
height = props.height,
|
|
2006
2012
|
width = props.width;
|
|
2007
2013
|
var showPlaceholder = useIconPlaceholder(dataSources, loading, options);
|
|
2008
|
-
var bgColorFromTheme = colorUtils_1.isColor(options === null || options === void 0 ? void 0 : options.backgroundColor) ? options === null || options === void 0 ? void 0 : options.backgroundColor : (_a = themes === null || themes === void 0 ? void 0 : themes.defaultBackgroundColor) === null || _a === void 0 ? void 0 : _a.call(themes, props);
|
|
2014
|
+
var bgColorFromTheme = (0, colorUtils_1.isColor)(options === null || options === void 0 ? void 0 : options.backgroundColor) ? options === null || options === void 0 ? void 0 : options.backgroundColor : (_a = themes === null || themes === void 0 ? void 0 : themes.defaultBackgroundColor) === null || _a === void 0 ? void 0 : _a.call(themes, props);
|
|
2009
2015
|
var icon = (_b = config.placeholderIcon) !== null && _b !== void 0 ? _b : config.icon;
|
|
2010
2016
|
var iconColor = variables_1.default.contentColorActive(props);
|
|
2011
2017
|
if (config.supports.includes(VizBehavior_1.VizBehavior.PLACEHOLDER) && showPlaceholder) {
|
|
@@ -2020,7 +2026,7 @@ var withPlaceholder = function withPlaceholder(Visualization) {
|
|
|
2020
2026
|
}
|
|
2021
2027
|
return React.createElement(Visualization, Object.assign({}, props));
|
|
2022
2028
|
};
|
|
2023
|
-
hocUtils_1.extendStaticWrapperProps({
|
|
2029
|
+
(0, hocUtils_1.extendStaticWrapperProps)({
|
|
2024
2030
|
Wrapper: Wrapper,
|
|
2025
2031
|
Visualization: Visualization
|
|
2026
2032
|
});
|
|
@@ -2045,7 +2051,7 @@ var background = function background(_ref) {
|
|
|
2045
2051
|
themes = _ref.themes,
|
|
2046
2052
|
labelPosition = _ref.labelPosition;
|
|
2047
2053
|
return [{
|
|
2048
|
-
label: i18n_1._(label || 'Background'),
|
|
2054
|
+
label: (0, i18n_1._)(label || 'Background'),
|
|
2049
2055
|
option: 'backgroundColor',
|
|
2050
2056
|
editor: 'editor.color',
|
|
2051
2057
|
editorProps: {
|
|
@@ -2061,7 +2067,7 @@ exports.default = background;
|
|
|
2061
2067
|
/***/ 59:
|
|
2062
2068
|
/***/ (function(module, exports) {
|
|
2063
2069
|
|
|
2064
|
-
module.exports = require("@
|
|
2070
|
+
module.exports = require("@babel/runtime/helpers/taggedTemplateLiteral");
|
|
2065
2071
|
|
|
2066
2072
|
/***/ }),
|
|
2067
2073
|
|
|
@@ -2102,6 +2108,13 @@ var VizBehavior;
|
|
|
2102
2108
|
|
|
2103
2109
|
/***/ }),
|
|
2104
2110
|
|
|
2111
|
+
/***/ 60:
|
|
2112
|
+
/***/ (function(module, exports) {
|
|
2113
|
+
|
|
2114
|
+
module.exports = require("@splunk/themes");
|
|
2115
|
+
|
|
2116
|
+
/***/ }),
|
|
2117
|
+
|
|
2105
2118
|
/***/ 7:
|
|
2106
2119
|
/***/ (function(module, exports) {
|
|
2107
2120
|
|
|
@@ -2128,13 +2141,6 @@ module.exports = require("@babel/runtime/helpers/classCallCheck");
|
|
|
2128
2141
|
|
|
2129
2142
|
module.exports = require("@splunk/visualization-encoding/utils/types");
|
|
2130
2143
|
|
|
2131
|
-
/***/ }),
|
|
2132
|
-
|
|
2133
|
-
/***/ 98:
|
|
2134
|
-
/***/ (function(module, exports) {
|
|
2135
|
-
|
|
2136
|
-
module.exports = require("@babel/runtime/helpers/taggedTemplateLiteral");
|
|
2137
|
-
|
|
2138
2144
|
/***/ })
|
|
2139
2145
|
|
|
2140
2146
|
/******/ });
|