@splunk/visualization-schemas 27.1.0 → 27.2.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/dist/cjs/index.js CHANGED
@@ -101,6 +101,7 @@ __export(src_exports, {
101
101
  singleValueOptionsSchema: () => singleValueOptionsSchema,
102
102
  singleValueRadialOptionsSchema: () => singleValueRadialOptionsSchema,
103
103
  tableOptionsSchema: () => tableOptionsSchema,
104
+ timelineOptionsSchema: () => timelineOptionsSchema,
104
105
  validAlignments: () => validAlignments,
105
106
  validCellRenderers: () => validCellRenderers,
106
107
  validColumnAlignments: () => validColumnAlignments,
@@ -2867,6 +2868,9 @@ var mapOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
2867
2868
  latitude: '> primary | seriesByName("latitude")',
2868
2869
  longitude: '> primary | seriesByName("longitude")',
2869
2870
  seriesColors: visualization_color_palettes_exports.VIZ_CATEGORICAL,
2871
+ dataValues: '> primary | seriesByType("number")',
2872
+ dataColors: "",
2873
+ // default to an empty string to prioritize seriesColors
2870
2874
  bubbleSize: '> primary | frameWithoutSeriesNames("geobin", "latitude", "longitude") | frameBySeriesTypes("number")',
2871
2875
  additionalTooltipFields: [],
2872
2876
  resultLimit: 1e3
@@ -2876,6 +2880,9 @@ var mapOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
2876
2880
  latitude: '> primary | seriesByName("latitude")',
2877
2881
  longitude: '> primary | seriesByName("longitude")',
2878
2882
  seriesColors: visualization_color_palettes_exports.VIZ_CATEGORICAL,
2883
+ dataValues: '> primary | seriesByType("number")',
2884
+ dataColors: "",
2885
+ // default to an empty string to prioritize seriesColors
2879
2886
  additionalTooltipFields: [],
2880
2887
  resultLimit: 1e3
2881
2888
  },
@@ -2927,9 +2934,16 @@ var mapOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
2927
2934
  default: visualization_color_palettes_exports.VIZ_CATEGORICAL
2928
2935
  },
2929
2936
  dataColors: {
2930
- description: 'Specify the colors to use for data points. You can use an array of colors to be picked from, or you can use a dataSource to apply dynamic coloring. For example, \u201C> primary | seriesByName("status") | matchValue(colorMatchConfig)\u201D. When type: "choropleth", dataColors is defined by default, and the opacities are shown at 80% of maximum to allow textual information to be visible in the map. By default, the dataColors option is not defined for type "bubble" or "marker". If type: "bubble", dataColors requires bubbleSize to have only a single series configured.',
2937
+ description: 'Specify the colors to use for data points. You can use an array of colors to be picked from, or you can use a dataSource to apply dynamic coloring. For example, \u201C> primary | seriesByName("status") | matchValue(colorMatchConfig)\u201D. When type: "choropleth", dataColors is defined by default, and the opacities are shown at 80% of maximum to allow textual information to be visible in the map. By default, the dataColors option is empty for "bubble" or "marker" layers to prioritize seriesColors. For "bubble" layers, dataColors requires bubbleSize to have a single series configured. If multiple series are set for bubbleSize, only the first pie slice reflects the colors.',
2931
2938
  type: ["string", "array"],
2932
- items: { type: "string" }
2939
+ items: { type: "string" },
2940
+ default: ""
2941
+ },
2942
+ dataValues: {
2943
+ description: 'Specify the data series used to encode colors for dynamic coloring in layers of type "marker" or "bubble".',
2944
+ type: ["string"],
2945
+ items: { type: "number" },
2946
+ default: '> primary | seriesByType("number")'
2933
2947
  },
2934
2948
  additionalTooltipFields: {
2935
2949
  description: "Specify the fields to add to the default set of tooltips. Tooltips appear when you hover over data points. These fields and their corresponding values are shown in addition to the ones displayed by default.",
@@ -3024,7 +3038,7 @@ var mapOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
3024
3038
  default: "bubble" /* Bubble */
3025
3039
  },
3026
3040
  bubbleSize: {
3027
- description: 'Specify the data column to encode bubble size. This applies to layers where type: "bubble".',
3041
+ description: 'Specify the data column to encode bubble size. This applies to layers where type: "bubble". If a single data column is specified, each bubble appears as a circle. When multiple columns are provided, bubbles are displayed as pie charts, with each slice representing a different column.',
3028
3042
  type: ["string", "array"],
3029
3043
  items: { type: "number" },
3030
3044
  default: '> primary | frameWithoutSeriesNames("geobin", "latitude", "longitude") | frameBySeriesTypes("number")'
@@ -3048,9 +3062,16 @@ var mapOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
3048
3062
  default: visualization_color_palettes_exports.VIZ_CATEGORICAL
3049
3063
  },
3050
3064
  dataColors: {
3051
- description: 'Specify the colors to use for data points. You can use an array of colors to be picked from, or you can use a dataSource to apply dynamic coloring. For example, \u201C> primary | seriesByName("status") | matchValue(colorMatchConfig)\u201D. When type: "choropleth", dataColors is defined by default, and the opacities are shown at 80% of maximum to allow textual information to be visible in the map. By default, the dataColors option is not defined for type "bubble" or "marker". If type: "bubble", dataColors requires bubbleSize to have only a single series configured.',
3065
+ description: 'Specify the colors to use for data points. You can use an array of colors to be picked from, or you can use a dataSource to apply dynamic coloring. For example, \u201C> primary | seriesByName("status") | matchValue(colorMatchConfig)\u201D. When type: "choropleth", dataColors is defined by default, and the opacities are shown at 80% of maximum to allow textual information to be visible in the map. By default, the dataColors option is empty for "bubble" or "marker" layers to prioritize seriesColors. For "bubble" layers, dataColors requires bubbleSize to have a single series configured. If multiple series are set for bubbleSize, only the first pie slice reflects the colors.',
3052
3066
  type: ["string", "array"],
3053
- items: { type: "string" }
3067
+ items: { type: "string" },
3068
+ default: ""
3069
+ },
3070
+ dataValues: {
3071
+ description: 'Specify the data series used to encode colors for dynamic coloring in layers of type "marker" or "bubble".',
3072
+ type: ["string"],
3073
+ items: { type: "number" },
3074
+ default: '> primary | seriesByType("number")'
3054
3075
  },
3055
3076
  additionalTooltipFields: {
3056
3077
  description: "Specify the fields to add to the default set of tooltips. Tooltips appear when you hover over data points. These fields and their corresponding values are shown in addition to the ones displayed by default.",
@@ -3848,7 +3869,12 @@ var singleValueOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
3848
3869
  },
3849
3870
  majorValue: {
3850
3871
  default: "> sparklineValues|lastPoint()",
3851
- description: "The major value to display in the visualization.",
3872
+ description: "The raw value to display and used to calculate trendValue. It is not displayed if majorValueDisplay is specified.",
3873
+ type: ["string", "number"]
3874
+ },
3875
+ majorValueDisplay: {
3876
+ default: "> majorValue",
3877
+ description: "The formatted version of majorValue displayed in the visualization.",
3852
3878
  type: ["string", "number"]
3853
3879
  },
3854
3880
  majorValueField: {
@@ -4050,7 +4076,12 @@ var singleValueIconOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
4050
4076
  },
4051
4077
  majorValue: {
4052
4078
  default: '> primary|seriesByPrioritizedTypes("number", "string", "time")|lastPoint()',
4053
- description: "The major value to display in the visualization.",
4079
+ description: "The raw value to display and used to calculate trendValue. It is not displayed if majorValueDisplay is specified.",
4080
+ type: ["string", "number"]
4081
+ },
4082
+ majorValueDisplay: {
4083
+ default: "> majorValue",
4084
+ description: "The formatted version of majorValue displayed in the visualization.",
4054
4085
  type: ["string", "number"]
4055
4086
  },
4056
4087
  majorValueField: {
@@ -4201,7 +4232,12 @@ var singleValueRadialOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
4201
4232
  },
4202
4233
  majorValue: {
4203
4234
  default: '> primary | seriesByPrioritizedTypes("number", "string", "time") | lastPoint()',
4204
- description: "Specify the dataSource applied to the major value.",
4235
+ description: "The raw value to display and used to calculate trendValue. It is not displayed if majorValueDisplay is specified.",
4236
+ type: ["string", "number"]
4237
+ },
4238
+ majorValueDisplay: {
4239
+ default: "> majorValue",
4240
+ description: "The formatted version of majorValue displayed in the visualization.",
4205
4241
  type: ["string", "number"]
4206
4242
  },
4207
4243
  majorValueField: {
@@ -4614,4 +4650,97 @@ var tableOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
4614
4650
  }
4615
4651
  }
4616
4652
  });
4653
+
4654
+ // src/optionsSchemas/timeline.ts
4655
+ var timelineOptionsSchema = enhanceOptionsSchemaWithDynamicOptions({
4656
+ x: {
4657
+ default: '> primary | seriesByType("time")',
4658
+ description: "Specify the data source applied to the x-axis.",
4659
+ type: "array",
4660
+ items: { type: ["string", "number"] }
4661
+ },
4662
+ y: {
4663
+ default: '> primary | seriesByPrioritizedTypes("string", "number")',
4664
+ description: "Specify the data source applied to the y-axis.",
4665
+ type: "array",
4666
+ items: { type: ["string", "number"] }
4667
+ },
4668
+ duration: {
4669
+ default: '> primary | seriesByPrioritizedTypes("number", "time")',
4670
+ description: "Specify the data source to apply duration to events. This will display events over a length of time as a bar rather than a circle.",
4671
+ type: "array",
4672
+ items: { type: ["string", "number"] }
4673
+ },
4674
+ category: {
4675
+ default: '> primary| seriesByName("category")',
4676
+ description: "Specify the data source to apply series categories. This will color events in distinct categories.",
4677
+ type: "array",
4678
+ items: { type: ["string", "number"] }
4679
+ },
4680
+ xField: {
4681
+ default: "> x | getField()",
4682
+ description: "Specify the field that should be mapped to the x-axis.",
4683
+ type: "string"
4684
+ },
4685
+ yField: {
4686
+ default: "> y | getField()",
4687
+ description: "Specify the field that should be mapped to the y-axis.",
4688
+ type: "string"
4689
+ },
4690
+ durationField: {
4691
+ default: "> duration | getField()",
4692
+ description: "Specify the field that should be mapped to the x-axis.",
4693
+ type: "string"
4694
+ },
4695
+ categoryField: {
4696
+ default: "> category | getField()",
4697
+ description: "Specify the field that should be mapped to the y-axis.",
4698
+ type: "string"
4699
+ },
4700
+ additionalTooltipFields: {
4701
+ default: [],
4702
+ description: "Specify the fields to add to the default set of tooltips. Tooltips appear when you hover over events. These fields and their corresponding values are shown in addition to the ones displayed by default.",
4703
+ type: "array",
4704
+ items: { type: "string" }
4705
+ },
4706
+ backgroundColor: {
4707
+ default: "> themes.defaultBackgroundColor",
4708
+ description: 'Specify the color for the background. You may 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".',
4709
+ pattern: COLOR_OR_TOKEN_PATTERN_WITH_RGBA,
4710
+ type: "string"
4711
+ },
4712
+ dataColors: {
4713
+ description: 'Specify the colors to use for events. You can use an array of colors to be picked from, or you can use a data source to apply dynamic coloring. For example, \u201C> primary | seriesByName("count") | rangeValue(lowToHigh)\u201D. By default, the dataColors option is not defined and seriesColors is used for categorical coloring.',
4714
+ type: ["string", "array"],
4715
+ items: { type: "string" }
4716
+ },
4717
+ legendDisplay: {
4718
+ default: "off",
4719
+ description: "Specify the location of the legend on the panel.",
4720
+ pattern: getPattern(["right", "bottom", "off"]),
4721
+ type: "string"
4722
+ },
4723
+ legendTruncation: {
4724
+ default: "ellipsisEnd",
4725
+ description: "Specify how to display legend labels when they overflow the layout boundaries by replacing overflow text with an ellipsis.",
4726
+ pattern: getPattern(["ellipsisEnd", "ellipsisMiddle", "ellipsisStart", "ellipsisOff"]),
4727
+ type: "string"
4728
+ },
4729
+ resultLimit: {
4730
+ default: 1e4,
4731
+ description: "Specify the maximum number of events to render on the timeline. Adjust the value to improve performance.",
4732
+ type: "number"
4733
+ },
4734
+ seriesColors: {
4735
+ default: visualization_color_palettes_exports.VIZ_CATEGORICAL,
4736
+ description: 'Specify the colors used for a series. For example, ["#FF0000", "#0000FF", "#008000"].',
4737
+ type: "array",
4738
+ items: { type: "string" }
4739
+ },
4740
+ yAxisLabelWidth: {
4741
+ default: 100,
4742
+ description: "Specify the width, in pixels, for y-axis labels.",
4743
+ type: "number"
4744
+ }
4745
+ });
4617
4746
  //# sourceMappingURL=index.js.map