@splunk/visualizations 26.2.0 → 26.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.
Files changed (149) hide show
  1. package/Area.config.js +91 -594
  2. package/Area.config.js.map +1 -1
  3. package/Area.js +184 -689
  4. package/Area.js.map +1 -1
  5. package/Bar.config.js +92 -561
  6. package/Bar.config.js.map +1 -1
  7. package/Bar.js +184 -655
  8. package/Bar.js.map +1 -1
  9. package/Bubble.config.js +83 -482
  10. package/Bubble.config.js.map +1 -1
  11. package/Bubble.js +177 -578
  12. package/Bubble.js.map +1 -1
  13. package/ChoroplethSvg.config.js +76 -201
  14. package/ChoroplethSvg.config.js.map +1 -1
  15. package/ChoroplethSvg.js +173 -301
  16. package/ChoroplethSvg.js.map +1 -1
  17. package/Column.config.js +92 -599
  18. package/Column.config.js.map +1 -1
  19. package/Column.js +184 -693
  20. package/Column.js.map +1 -1
  21. package/Ellipse.config.js +82 -200
  22. package/Ellipse.config.js.map +1 -1
  23. package/Ellipse.js +137 -262
  24. package/Ellipse.js.map +1 -1
  25. package/Events.config.js +61 -282
  26. package/Events.config.js.map +1 -1
  27. package/Events.js +222 -428
  28. package/Events.js.map +1 -1
  29. package/FillerGauge.config.js +90 -219
  30. package/FillerGauge.config.js.map +1 -1
  31. package/FillerGauge.js +163 -299
  32. package/FillerGauge.js.map +1 -1
  33. package/Image.config.js +61 -157
  34. package/Image.config.js.map +1 -1
  35. package/Image.js +130 -242
  36. package/Image.js.map +1 -1
  37. package/Line.config.js +91 -606
  38. package/Line.config.js.map +1 -1
  39. package/Line.js +184 -701
  40. package/Line.js.map +1 -1
  41. package/LinkGraph.config.js +74 -256
  42. package/LinkGraph.config.js.map +1 -1
  43. package/LinkGraph.js +17198 -24224
  44. package/LinkGraph.js.map +1 -1
  45. package/Map.config.js +128 -1123
  46. package/Map.config.js.map +1 -1
  47. package/Map.js +309 -680
  48. package/Map.js.map +1 -1
  49. package/Markdown.config.js +61 -188
  50. package/Markdown.config.js.map +1 -1
  51. package/Markdown.js +190 -323
  52. package/Markdown.js.map +1 -1
  53. package/MarkerGauge.config.js +137 -297
  54. package/MarkerGauge.config.js.map +1 -1
  55. package/MarkerGauge.js +1038 -1203
  56. package/MarkerGauge.js.map +1 -1
  57. package/ParallelCoordinates.config.js +71 -191
  58. package/ParallelCoordinates.config.js.map +1 -1
  59. package/ParallelCoordinates.js +218 -343
  60. package/ParallelCoordinates.js.map +1 -1
  61. package/Pie.config.js +72 -240
  62. package/Pie.config.js.map +1 -1
  63. package/Pie.js +214 -381
  64. package/Pie.js.map +1 -1
  65. package/Punchcard.config.js +71 -305
  66. package/Punchcard.config.js.map +1 -1
  67. package/Punchcard.js +246 -477
  68. package/Punchcard.js.map +1 -1
  69. package/Rectangle.config.js +211 -347
  70. package/Rectangle.config.js.map +1 -1
  71. package/Rectangle.js +274 -416
  72. package/Rectangle.js.map +1 -1
  73. package/Sankey.config.js +71 -213
  74. package/Sankey.config.js.map +1 -1
  75. package/Sankey.js +246 -382
  76. package/Sankey.js.map +1 -1
  77. package/Scatter.config.js +85 -463
  78. package/Scatter.config.js.map +1 -1
  79. package/Scatter.js +825 -1202
  80. package/Scatter.js.map +1 -1
  81. package/SingleValue.config.js +114 -409
  82. package/SingleValue.config.js.map +1 -1
  83. package/SingleValue.js +287 -582
  84. package/SingleValue.js.map +1 -1
  85. package/SingleValueBasic.js +30 -30
  86. package/SingleValueBasic.js.map +1 -1
  87. package/SingleValueIcon.config.js +113 -378
  88. package/SingleValueIcon.config.js.map +1 -1
  89. package/SingleValueIcon.js +268 -533
  90. package/SingleValueIcon.js.map +1 -1
  91. package/SingleValueRadial.config.js +110 -382
  92. package/SingleValueRadial.config.js.map +1 -1
  93. package/SingleValueRadial.js +272 -543
  94. package/SingleValueRadial.js.map +1 -1
  95. package/SparkLine.js +24 -24
  96. package/SparkLine.js.map +1 -1
  97. package/Table.config.js +74 -496
  98. package/Table.config.js.map +1 -1
  99. package/Table.js +302 -720
  100. package/Table.js.map +1 -1
  101. package/common/Charting.js +22 -34
  102. package/common/Charting.js.map +1 -1
  103. package/common/DocExampleWithVizSandbox.js +21 -21
  104. package/common/DocExampleWithVizSandbox.js.map +1 -1
  105. package/common/EventsDoc.js +18 -18
  106. package/common/EventsDoc.js.map +1 -1
  107. package/common/GaugeMajorTicks.js +4 -4
  108. package/common/GaugeMajorTicks.js.map +1 -1
  109. package/common/GaugeValueMarker.js +2 -2
  110. package/common/GaugeValueMarker.js.map +1 -1
  111. package/common/OptionsDoc.js +4 -4
  112. package/common/OptionsDoc.js.map +1 -1
  113. package/common/OverviewDoc.js +39 -40
  114. package/common/OverviewDoc.js.map +1 -1
  115. package/common/SplunkVisualization.js +2 -2
  116. package/common/SplunkVisualization.js.map +1 -1
  117. package/common/SplunkVisualizationApi.js +2 -2
  118. package/common/SplunkVisualizationApi.js.map +1 -1
  119. package/common/ThemesDoc.js +19 -19
  120. package/common/ThemesDoc.js.map +1 -1
  121. package/common/chartingUtils.js +2 -2
  122. package/common/chartingUtils.js.map +1 -1
  123. package/common/gaugeUtils.js +10 -10
  124. package/common/gaugeUtils.js.map +1 -1
  125. package/common/shapeUtils.js +10 -10
  126. package/common/shapeUtils.js.map +1 -1
  127. package/common/utils/configUtils.js +25 -155
  128. package/common/utils/configUtils.js.map +1 -1
  129. package/common/utils/dataUtils.js +75 -87
  130. package/common/utils/dataUtils.js.map +1 -1
  131. package/common/utils/featureFlagUtils.js +4 -4
  132. package/common/utils/featureFlagUtils.js.map +1 -1
  133. package/common/utils/hocUtils.js +2 -2
  134. package/common/utils/hocUtils.js.map +1 -1
  135. package/common/utils/mapUtils.js +51 -54
  136. package/common/utils/mapUtils.js.map +1 -1
  137. package/common/utils/singleValueUtils.js +7 -7
  138. package/common/utils/singleValueUtils.js.map +1 -1
  139. package/common/utils/testHelper.js +7 -36
  140. package/common/utils/testHelper.js.map +1 -1
  141. package/common/utils/trellisUtils.js +7 -6
  142. package/common/utils/trellisUtils.js.map +1 -1
  143. package/common/utils/urlUtils.js +2 -2
  144. package/common/utils/urlUtils.js.map +1 -1
  145. package/common/withDashboardViz.js +65 -77
  146. package/common/withDashboardViz.js.map +1 -1
  147. package/package.json +46 -49
  148. package/common/utils/layoutUtils.js +0 -115
  149. package/common/utils/layoutUtils.js.map +0 -1
package/Table.config.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 = 82);
90
+ /******/ return __webpack_require__(__webpack_require__.s = 73);
91
91
  /******/ })
92
92
  /************************************************************************/
93
93
  /******/ ({
@@ -109,18 +109,11 @@ module.exports = require("@babel/runtime/helpers/toConsumableArray");
109
109
  /***/ 10:
110
110
  /***/ (function(module, exports) {
111
111
 
112
- module.exports = require("@splunk/themes/variables");
113
-
114
- /***/ }),
115
-
116
- /***/ 11:
117
- /***/ (function(module, exports) {
118
-
119
112
  module.exports = require("@splunk/visualization-icons/placeholders");
120
113
 
121
114
  /***/ }),
122
115
 
123
- /***/ 12:
116
+ /***/ 11:
124
117
  /***/ (function(module, exports) {
125
118
 
126
119
  module.exports = require("@splunk/visualization-icons");
@@ -128,46 +121,13 @@ module.exports = require("@splunk/visualization-icons");
128
121
  /***/ }),
129
122
 
130
123
  /***/ 2:
131
- /***/ (function(module, exports, __webpack_require__) {
132
-
133
- "use strict";
134
-
135
-
136
- Object.defineProperty(exports, "__esModule", {
137
- value: true
138
- });
139
- exports.VizBehavior = void 0;
140
- var VizBehavior;
141
-
142
- (function (VizBehavior) {
143
- /**
144
- * Dynamic Options Behavior.
145
- * This allows visualization options to be powered by data
146
- *
147
- * **Example**
148
- *
149
- * sparklineValues: ">primary|seriesByIndex(0)"
150
- * would configure sparklineValues with an array of data points
151
- * coming from the first series in the primary datasource
152
- *
153
- */
154
- VizBehavior["DYNAMIC_OPTIONS"] = "dynamic-options";
155
- VizBehavior["EVENTS"] = "events";
156
- VizBehavior["DOWNSAMPLING"] = "downsampling";
157
- /**
158
- * Placeholder behavior: visualization will display a placeholder rather than fail if any of the `requiredProps` is
159
- * missing.
160
- * @type {string}
161
- */
124
+ /***/ (function(module, exports) {
162
125
 
163
- VizBehavior["PLACEHOLDER"] = "placeholder";
164
- VizBehavior["PAGE_AND_SORT"] = "page-and-sort";
165
- VizBehavior["TRELLIS"] = "trellis";
166
- })(VizBehavior = exports.VizBehavior || (exports.VizBehavior = {}));
126
+ module.exports = require("@splunk/visualization-schemas");
167
127
 
168
128
  /***/ }),
169
129
 
170
- /***/ 26:
130
+ /***/ 23:
171
131
  /***/ (function(module, exports) {
172
132
 
173
133
  module.exports = require("@splunk/visualizations-shared/colorConstants");
@@ -175,13 +135,6 @@ module.exports = require("@splunk/visualizations-shared/colorConstants");
175
135
  /***/ }),
176
136
 
177
137
  /***/ 3:
178
- /***/ (function(module, exports) {
179
-
180
- module.exports = require("@splunk/visualizations-shared/schemaUtils");
181
-
182
- /***/ }),
183
-
184
- /***/ 4:
185
138
  /***/ (function(module, exports, __webpack_require__) {
186
139
 
187
140
  "use strict";
@@ -189,97 +142,22 @@ module.exports = require("@splunk/visualizations-shared/schemaUtils");
189
142
 
190
143
  var _toConsumableArray = __webpack_require__(1);
191
144
 
192
- var _defineProperty = __webpack_require__(7);
193
-
194
- var __rest = this && this.__rest || function (s, e) {
195
- var t = {};
196
-
197
- for (var p in s) {
198
- if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0) t[p] = s[p];
199
- }
200
-
201
- if (s != null && typeof Object.getOwnPropertySymbols === "function") for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
202
- if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i])) t[p[i]] = s[p[i]];
203
- }
204
- return t;
205
- };
206
-
207
145
  Object.defineProperty(exports, "__esModule", {
208
146
  value: true
209
147
  });
210
- exports.insertLayout = exports.isDynamicOption = exports.uncollapseEditorConfig = exports.generatePrecisionValues = exports.getInitialPreset = exports.enhanceOptionsSchemaWithDynamicOptions = exports.enhanceConfig = void 0;
148
+ exports.insertLayout = exports.isDynamicOption = exports.uncollapseEditorConfig = exports.generatePrecisionValues = exports.getInitialPreset = exports.enhanceConfig = exports.enhanceOptionsSchemaWithDynamicOptions = void 0;
211
149
 
212
- var lodash_1 = __webpack_require__(6);
150
+ var lodash_1 = __webpack_require__(5); // included for backwards compatibility
213
151
 
214
- var schemaUtils_1 = __webpack_require__(3);
215
152
 
216
- var VizBehavior_1 = __webpack_require__(2);
153
+ var visualization_schemas_1 = __webpack_require__(2);
217
154
 
218
- var dynamicOptionsDSLType = {
219
- type: 'string',
220
- pattern: schemaUtils_1.DYNAMIC_OPTIONS_DSL_PATTERN
221
- };
222
- /**
223
- * Helper function to extend an options schema with dynamic options DSL
224
- * @param optionsSchema a visualization's options schema
225
- * @returns an updated options schema that additionally allows strings starting with > for each option
226
- */
227
-
228
- function enhanceOptionsSchemaWithDynamicOptions(optionsSchema) {
229
- var enhancedOptionsSchema = {};
230
- Object.keys(optionsSchema).forEach(function (key) {
231
- var _a = optionsSchema[key],
232
- title = _a.title,
233
- description = _a.description,
234
- readOnly = _a.readOnly,
235
- writeOnly = _a.writeOnly,
236
- examples = _a.examples,
237
- defaultValue = _a.default,
238
- type = _a.type,
239
- properties = _a.properties,
240
- patternProperties = _a.patternProperties,
241
- remainingSchemaEntry = __rest(_a, ["title", "description", "readOnly", "writeOnly", "examples", "default", "type", "properties", "patternProperties"]);
242
-
243
- var annotations = Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({}, title !== undefined && {
244
- title: title
245
- }), description !== undefined && {
246
- description: description
247
- }), readOnly !== undefined && {
248
- readOnly: readOnly
249
- }), writeOnly !== undefined && {
250
- writeOnly: writeOnly
251
- }), examples !== undefined && {
252
- examples: examples
253
- }), defaultValue !== undefined && {
254
- default: defaultValue
255
- });
256
-
257
- if (type === 'object') {
258
- enhancedOptionsSchema[key] = Object.assign(Object.assign(Object.assign(Object.assign({}, remainingSchemaEntry), annotations), {
259
- type: type
260
- }), properties && {
261
- properties: enhanceOptionsSchemaWithDynamicOptions(properties)
262
- });
263
-
264
- if (patternProperties) {
265
- var enhancedPatternProperties = {};
266
- Object.keys(patternProperties).forEach(function (opt) {
267
- enhancedPatternProperties = Object.assign(Object.assign({}, enhancedPatternProperties), enhanceOptionsSchemaWithDynamicOptions(_defineProperty({}, opt, patternProperties[opt])));
268
- });
269
- enhancedOptionsSchema[key].patternProperties = enhancedPatternProperties;
270
- }
271
- } else {
272
- enhancedOptionsSchema[key] = Object.assign(Object.assign({}, annotations), {
273
- anyOf: [Object.assign(Object.assign({}, type !== undefined && {
274
- type: type
275
- }), remainingSchemaEntry), dynamicOptionsDSLType]
276
- });
277
- }
278
- });
279
- return enhancedOptionsSchema;
280
- }
281
-
282
- exports.enhanceOptionsSchemaWithDynamicOptions = enhanceOptionsSchemaWithDynamicOptions;
155
+ Object.defineProperty(exports, "enhanceOptionsSchemaWithDynamicOptions", {
156
+ enumerable: true,
157
+ get: function get() {
158
+ return visualization_schemas_1.enhanceOptionsSchemaWithDynamicOptions;
159
+ }
160
+ });
283
161
  /**
284
162
  * Helper function to enhance a Visualization Config as needed based on behaviors specified in supports block
285
163
  * this function also collapse all editor panels
@@ -290,11 +168,6 @@ exports.enhanceOptionsSchemaWithDynamicOptions = enhanceOptionsSchemaWithDynamic
290
168
 
291
169
  function enhanceConfig(vizConfig) {
292
170
  var enhancedConfig = Object.assign({}, vizConfig);
293
-
294
- if (vizConfig.supports.indexOf(VizBehavior_1.VizBehavior.DYNAMIC_OPTIONS) !== -1) {
295
- enhancedConfig.optionsSchema = enhanceOptionsSchemaWithDynamicOptions(vizConfig.optionsSchema);
296
- }
297
-
298
171
  enhancedConfig.editorConfig = vizConfig.editorConfig.map(function (config) {
299
172
  return Object.assign(Object.assign({}, config), {
300
173
  open: config.open || false
@@ -418,21 +291,54 @@ exports.insertLayout = insertLayout;
418
291
 
419
292
  /***/ }),
420
293
 
421
- /***/ 6:
294
+ /***/ 5:
422
295
  /***/ (function(module, exports) {
423
296
 
424
297
  module.exports = require("lodash");
425
298
 
426
299
  /***/ }),
427
300
 
428
- /***/ 7:
429
- /***/ (function(module, exports) {
301
+ /***/ 6:
302
+ /***/ (function(module, exports, __webpack_require__) {
303
+
304
+ "use strict";
430
305
 
431
- module.exports = require("@babel/runtime/helpers/defineProperty");
306
+
307
+ Object.defineProperty(exports, "__esModule", {
308
+ value: true
309
+ });
310
+ exports.VizBehavior = void 0;
311
+ var VizBehavior;
312
+
313
+ (function (VizBehavior) {
314
+ /**
315
+ * Dynamic Options Behavior.
316
+ * This allows visualization options to be powered by data
317
+ *
318
+ * **Example**
319
+ *
320
+ * sparklineValues: ">primary|seriesByIndex(0)"
321
+ * would configure sparklineValues with an array of data points
322
+ * coming from the first series in the primary datasource
323
+ *
324
+ */
325
+ VizBehavior["DYNAMIC_OPTIONS"] = "dynamic-options";
326
+ VizBehavior["EVENTS"] = "events";
327
+ VizBehavior["DOWNSAMPLING"] = "downsampling";
328
+ /**
329
+ * Placeholder behavior: visualization will display a placeholder rather than fail if any of the `requiredProps` is
330
+ * missing.
331
+ * @type {string}
332
+ */
333
+
334
+ VizBehavior["PLACEHOLDER"] = "placeholder";
335
+ VizBehavior["PAGE_AND_SORT"] = "page-and-sort";
336
+ VizBehavior["TRELLIS"] = "trellis";
337
+ })(VizBehavior = exports.VizBehavior || (exports.VizBehavior = {}));
432
338
 
433
339
  /***/ }),
434
340
 
435
- /***/ 8:
341
+ /***/ 7:
436
342
  /***/ (function(module, exports, __webpack_require__) {
437
343
 
438
344
  "use strict";
@@ -461,7 +367,7 @@ var VizCategory;
461
367
 
462
368
  /***/ }),
463
369
 
464
- /***/ 82:
370
+ /***/ 73:
465
371
  /***/ (function(module, exports, __webpack_require__) {
466
372
 
467
373
  "use strict";
@@ -475,33 +381,31 @@ Object.defineProperty(exports, "__esModule", {
475
381
 
476
382
  var i18n_1 = __webpack_require__(0);
477
383
 
478
- var lodash_1 = __webpack_require__(6);
384
+ var lodash_1 = __webpack_require__(5);
479
385
 
480
- var schemaUtils_1 = __webpack_require__(3);
386
+ var visualization_schemas_1 = __webpack_require__(2);
481
387
 
482
- var colorConstants_1 = __webpack_require__(26);
388
+ var colorConstants_1 = __webpack_require__(23);
483
389
 
484
- var visualization_icons_1 = __webpack_require__(12);
390
+ var visualization_icons_1 = __webpack_require__(11);
485
391
 
486
- var placeholders_1 = __webpack_require__(11);
392
+ var placeholders_1 = __webpack_require__(10);
487
393
 
488
- var variables_1 = __webpack_require__(10);
394
+ var variables_1 = __webpack_require__(9);
489
395
 
490
- var pick_1 = __webpack_require__(9);
396
+ var pick_1 = __webpack_require__(8);
491
397
 
492
- var TextAlignCenter_1 = __webpack_require__(83);
398
+ var TextAlignCenter_1 = __webpack_require__(74);
493
399
 
494
- var TextAlignLeft_1 = __webpack_require__(84);
400
+ var TextAlignLeft_1 = __webpack_require__(75);
495
401
 
496
- var TextAlignRight_1 = __webpack_require__(85);
402
+ var TextAlignRight_1 = __webpack_require__(76);
497
403
 
498
- var configUtils_1 = __webpack_require__(4);
404
+ var configUtils_1 = __webpack_require__(3);
499
405
 
500
- var VizBehavior_1 = __webpack_require__(2);
406
+ var VizBehavior_1 = __webpack_require__(6);
501
407
 
502
- var consts_1 = __webpack_require__(86);
503
-
504
- var VizCategory_1 = __webpack_require__(8);
408
+ var VizCategory_1 = __webpack_require__(7);
505
409
 
506
410
  var dataContract = {
507
411
  requiredDataSources: [{
@@ -747,320 +651,6 @@ var matchColorConfig = [{
747
651
  match: '',
748
652
  value: '#5C33FF'
749
653
  }];
750
- var optionsSchema = {
751
- backgroundColor: {
752
- default: '> themes.defaultBackgroundColor',
753
- description: 'Specify the color for the background. You might use a data source to apply the color. The default for enterprise light is "#FFFFFF". The default for enterprise dark is "#000000". The default for prisma dark is "#0B0C0E".',
754
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA,
755
- type: 'string'
756
- },
757
- columnFormat: {
758
- description: 'Lets you format an individual column in a table. Specify a column in a table as a field, followed by a property. For more information, see the Column Format Align - Left example on the Examples page.',
759
- type: 'object',
760
- patternProperties: {
761
- '.*': {
762
- description: 'Customization for column property',
763
- type: 'object',
764
- properties: {
765
- align: {
766
- description: 'Specify the alignment for the whole column. Valid alignments include "left", "center", and "right". You can also pass an array to specify the alignment of each cell. When set to "auto", the column will use the same configuration as tableFormat.align.',
767
- type: ['string', 'array'],
768
- items: {
769
- type: 'string',
770
- enum: consts_1.validAlignments.concat()
771
- },
772
- default: 'auto'
773
- },
774
- cellTypes: {
775
- description: 'Specify how to render data in cells. Valid cell renders include "TextCell", "ArrayCell", "SparklineCell".',
776
- type: 'array',
777
- items: {
778
- type: 'string',
779
- enum: consts_1.validCellRenderers.concat()
780
- }
781
- },
782
- data: {
783
- description: 'Specify data points to be displayed in the cells of a column.',
784
- type: 'array',
785
- items: {
786
- oneOf: [{
787
- type: 'string'
788
- }, {
789
- type: 'number'
790
- }, {
791
- type: 'array',
792
- items: {
793
- type: ['string', 'number']
794
- }
795
- }]
796
- }
797
- },
798
- headerAlign: {
799
- description: 'Specify the heaader alignment for the whole column. Valid alignments include "left", "center", and "right". When set to "auto", the column will use the same configuration as tableFormat.headerAlign',
800
- type: 'string',
801
- items: {
802
- type: 'string',
803
- enum: consts_1.validAlignments.concat()
804
- },
805
- default: 'auto'
806
- },
807
- rowBackgroundColors: {
808
- description: 'Specify a list of colors, in hexadecimal code, for the background color of each column of the table. For example, ["#2C333B", "32373D"].',
809
- type: 'array',
810
- items: {
811
- type: 'string',
812
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA
813
- }
814
- },
815
- rowColors: {
816
- description: 'Specify a list of colors, in hexadecimal code, for the text color of the cells of a column. For example, ["#2C333B", "32373D"].',
817
- type: 'array',
818
- items: {
819
- type: 'string',
820
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA
821
- }
822
- },
823
- sparklineAreaColors: {
824
- description: 'Specify a list of colors, in hexadecimal code, for the sparkline area of each column. For example, ["#2C333B", "32373D"].',
825
- type: 'array',
826
- items: {
827
- type: 'string',
828
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA
829
- }
830
- },
831
- sparklineColors: {
832
- description: 'Specify a list of colors, in hexadecimal code, for the sparkline stroke of each column. For example, ["#2C333B", "32373D"].',
833
- type: 'array',
834
- items: {
835
- type: 'string',
836
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA
837
- }
838
- },
839
- sparklineTypes: {
840
- description: 'Choose either area or line formatting for the Sparkline. Valid sparkline types include "line" and "area".',
841
- type: 'array',
842
- items: {
843
- type: 'string',
844
- enum: consts_1.validSparklineTypes.concat()
845
- }
846
- },
847
- textOverflow: {
848
- description: 'Controls how the text should be truncated within a particular column. Valid types include "anywhere", "break-word", "ellipsis". Columns are "break-word" styled by default when "textOverflow" is not configured.',
849
- type: 'string',
850
- pattern: (0, schemaUtils_1.getPattern)(consts_1.validTextOverflows),
851
- enum: consts_1.validTextOverflows.concat()
852
- },
853
- width: {
854
- description: 'Specify, in pixels, the width of the column. The default displays a minimum width of at least 90, unless the table needs to filled further. The minimum width is 30px.',
855
- type: 'number',
856
- minimum: 30
857
- }
858
- }
859
- }
860
- }
861
- },
862
- count: {
863
- description: 'Specify the maximum number of rows to display.',
864
- type: 'number',
865
- default: 10
866
- },
867
- font: {
868
- default: 'proportional',
869
- description: 'Specify the font style to use for table content.',
870
- type: 'string',
871
- pattern: (0, schemaUtils_1.getPattern)(['proportional', 'monospace'])
872
- },
873
- fontSize: {
874
- default: 'default',
875
- description: 'Specify the font size to use for table content. Font sizes range from extra small (10px) to large (16px) with the default being 14px.',
876
- type: 'string',
877
- pattern: (0, schemaUtils_1.getPattern)(consts_1.validFontSizes)
878
- },
879
- headers: {
880
- default: '> table | getField()',
881
- description: "Specify an array of headers to display on the table. Though these can be statically listed, it's best to use the dynamic default, as it will return the fields of your search.",
882
- type: 'array',
883
- items: {
884
- type: 'string'
885
- }
886
- },
887
- headerVisibility: {
888
- default: 'inline',
889
- description: 'Specify how to display the table header row.',
890
- pattern: (0, schemaUtils_1.getPattern)(consts_1.validHeaderVisibilities),
891
- enum: consts_1.validHeaderVisibilities.concat(),
892
- type: 'string'
893
- },
894
- paginateDataSourceKey: {
895
- default: 'primary',
896
- description: 'Specify the data source key for pagination and sorting.',
897
- type: 'string'
898
- },
899
- showInternalFields: {
900
- default: true,
901
- description: 'Specify whether to show internal fields that start with an underscore. The _time field will still be shown if false.',
902
- type: 'boolean'
903
- },
904
- showRowNumbers: {
905
- default: false,
906
- description: 'Show row numbers in the first column.',
907
- type: 'boolean'
908
- },
909
- table: {
910
- default: '> primary',
911
- description: 'Two dimensional array of data to be displayed in the table.',
912
- type: 'array',
913
- items: {
914
- type: 'array',
915
- items: {
916
- oneOf: [{
917
- type: 'string'
918
- }, {
919
- type: 'number'
920
- }, {
921
- type: 'array',
922
- items: {
923
- type: ['string', 'number']
924
- }
925
- }]
926
- }
927
- }
928
- },
929
- tableFormat: {
930
- description: 'Lets you set global options for a table.',
931
- type: 'object',
932
- properties: {
933
- align: {
934
- default: '> table | type() | matchValue(tableAlignByType)',
935
- description: 'Specify alignment for the whole table. Valid alignments include "left", "center", and "right". You can also pass a 2 dimensional array to specify the alignment of each cell. By default, the table will be aligned by type.',
936
- type: ['string', 'array'],
937
- items: {
938
- type: 'array',
939
- items: {
940
- type: 'string',
941
- enum: consts_1.validAlignments.concat()
942
- }
943
- }
944
- },
945
- cellTypes: {
946
- default: '> table | type() | matchValue(tableCellTypeByType)',
947
- description: 'Specify how to render data in cells. Valid cell renders include "TextCell", "ArrayCell", "SparklineCell".',
948
- type: 'array',
949
- items: {
950
- type: 'array',
951
- items: {
952
- type: 'string',
953
- enum: consts_1.validCellRenderers.concat()
954
- }
955
- }
956
- },
957
- data: {
958
- description: 'Two dimensional data to be displayed in the table. This is usually formatted data instead of raw data from search.',
959
- type: 'array',
960
- items: {
961
- type: 'array',
962
- items: {
963
- oneOf: [{
964
- type: 'string'
965
- }, {
966
- type: 'number'
967
- }, {
968
- type: 'array',
969
- items: {
970
- type: ['string', 'number']
971
- }
972
- }]
973
- }
974
- }
975
- },
976
- headerAlign: {
977
- description: 'Specify the header alignment for the whole table. Valid alignments include "left", "center", and "right".',
978
- type: 'string',
979
- items: {
980
- type: 'string',
981
- enum: consts_1.validAlignments.concat()
982
- },
983
- default: 'left'
984
- },
985
- headerBackgroundColor: {
986
- default: '> themes.defaultHeaderBackgroundColor',
987
- description: 'Specify the table header background color using a hexadecimal code. For example, "#FFFFFF".',
988
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA,
989
- type: 'string'
990
- },
991
- headerColor: {
992
- description: 'Specify the table header text color using a hexadecimal code. For example, "#FFFFFF".',
993
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA,
994
- type: 'string'
995
- },
996
- rowBackgroundColors: {
997
- default: '> table | seriesByIndex(0) | pick(tableAltRowBackgroundColorsByTheme)',
998
- description: 'Specify a list of colors, in hexadecimal code, for the background color of each row of the table. For example, ["#2C333B", "32373D"].',
999
- type: 'array',
1000
- items: {
1001
- type: 'array',
1002
- items: {
1003
- type: 'string',
1004
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA
1005
- }
1006
- }
1007
- },
1008
- rowColors: {
1009
- description: 'Specify a list of colors, in hexadecimal code, for the text color of each row of the table. For example, ["#2C333B", "32373D"].',
1010
- type: 'array',
1011
- items: {
1012
- type: 'array',
1013
- items: {
1014
- type: 'string',
1015
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA
1016
- }
1017
- }
1018
- },
1019
- sparklineAreaColors: {
1020
- description: 'Specify a list of colors, in hexadecimal code, for the sparkline area of each row of the table. For example, ["#2C333B", "32373D"].',
1021
- type: 'array',
1022
- items: {
1023
- type: 'array',
1024
- items: {
1025
- type: 'string',
1026
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA
1027
- }
1028
- }
1029
- },
1030
- sparklineColors: {
1031
- description: 'Specify a list of colors, in hexadecimal code, for the sparkline stroke of each row of the table. For example, ["#2C333B", "32373D"].',
1032
- type: 'array',
1033
- items: {
1034
- type: 'array',
1035
- items: {
1036
- type: 'string',
1037
- pattern: schemaUtils_1.COLOR_OR_TOKEN_PATTERN_WITH_RGBA
1038
- }
1039
- }
1040
- },
1041
- sparklineTypes: {
1042
- description: 'Choose either area or line formatting for the Sparkline.',
1043
- type: 'array',
1044
- items: {
1045
- type: 'array',
1046
- items: {
1047
- type: 'string',
1048
- enum: consts_1.validSparklineTypes.concat()
1049
- }
1050
- }
1051
- },
1052
- textOverflow: {
1053
- description: 'Specify the text overflow for the whole column. Valid overflows include "break-word", "anywhere", and "ellipsis".',
1054
- type: 'string',
1055
- items: {
1056
- type: 'string',
1057
- enum: consts_1.validTextOverflows.concat()
1058
- },
1059
- default: 'break-word'
1060
- }
1061
- }
1062
- }
1063
- };
1064
654
  var themes = {
1065
655
  defaultBackgroundColor: function defaultBackgroundColor(props) {
1066
656
  return (0, pick_1.default)({
@@ -1319,7 +909,7 @@ var config = {
1319
909
  dataContract: dataContract,
1320
910
  size: size,
1321
911
  defaultContext: defaultContext,
1322
- optionsSchema: optionsSchema,
912
+ optionsSchema: visualization_schemas_1.tableOptionsSchema,
1323
913
  editorConfig: editorConfig,
1324
914
  events: {
1325
915
  'cell.click': {
@@ -1333,50 +923,38 @@ exports.default = (0, configUtils_1.enhanceConfig)(config);
1333
923
 
1334
924
  /***/ }),
1335
925
 
1336
- /***/ 83:
926
+ /***/ 74:
1337
927
  /***/ (function(module, exports) {
1338
928
 
1339
929
  module.exports = require("@splunk/react-icons/TextAlignCenter");
1340
930
 
1341
931
  /***/ }),
1342
932
 
1343
- /***/ 84:
933
+ /***/ 75:
1344
934
  /***/ (function(module, exports) {
1345
935
 
1346
936
  module.exports = require("@splunk/react-icons/TextAlignLeft");
1347
937
 
1348
938
  /***/ }),
1349
939
 
1350
- /***/ 85:
940
+ /***/ 76:
1351
941
  /***/ (function(module, exports) {
1352
942
 
1353
943
  module.exports = require("@splunk/react-icons/TextAlignRight");
1354
944
 
1355
945
  /***/ }),
1356
946
 
1357
- /***/ 86:
1358
- /***/ (function(module, exports, __webpack_require__) {
1359
-
1360
- "use strict";
1361
-
947
+ /***/ 8:
948
+ /***/ (function(module, exports) {
1362
949
 
1363
- Object.defineProperty(exports, "__esModule", {
1364
- value: true
1365
- });
1366
- exports.validFontSizes = exports.validTextOverflows = exports.validAlignments = exports.validHeaderVisibilities = exports.validSparklineTypes = exports.validCellRenderers = void 0;
1367
- exports.validCellRenderers = ['TextCell', 'ArrayCell', 'SparklineCell'];
1368
- exports.validSparklineTypes = ['line', 'area'];
1369
- exports.validHeaderVisibilities = ['none', 'fixed', 'inline'];
1370
- exports.validAlignments = ['left', 'center', 'right'];
1371
- exports.validTextOverflows = ['anywhere', 'break-word', 'ellipsis'];
1372
- exports.validFontSizes = ['extraSmall', 'small', 'default', 'large'];
950
+ module.exports = require("@splunk/themes/pick");
1373
951
 
1374
952
  /***/ }),
1375
953
 
1376
954
  /***/ 9:
1377
955
  /***/ (function(module, exports) {
1378
956
 
1379
- module.exports = require("@splunk/themes/pick");
957
+ module.exports = require("@splunk/themes/variables");
1380
958
 
1381
959
  /***/ })
1382
960