@vizzly/dashboard 0.15.0-dev-532824b8277b56794208595a2825194b1d110465 → 0.15.0-dev-f90cb9fe016b8d74be9d3b023741ac8c219fd11b

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.
@@ -49594,7 +49594,7 @@ var formattedResultToSeries = function formattedResultToSeries(formattedResult,
49594
49594
  };
49595
49595
 
49596
49596
  var buildBubbleChartRepresentation = function buildBubbleChartRepresentation(_ref) {
49597
- var _pivotConfig$x$, _xKeys$, _formattedResult$fiel, _formattedResult$fiel2, _axisTitles$x, _axisTitles$y;
49597
+ var _pivotConfig$x$, _xKeys$, _axisTitles$x, _axisTitles$y;
49598
49598
  var axisTitles = _ref.axisTitles,
49599
49599
  colors = _ref.colors,
49600
49600
  conditionalFormattingAttributes = _ref.conditionalFormattingAttributes,
@@ -49615,7 +49615,8 @@ var buildBubbleChartRepresentation = function buildBubbleChartRepresentation(_re
49615
49615
  approxYAxisLabelCount = _ref.approxYAxisLabelCount,
49616
49616
  _valueAlias = _ref.valueAlias,
49617
49617
  zFieldId = _ref.zFieldId,
49618
- quadrantsAttributes = _ref.quadrantsAttributes;
49618
+ quadrantsAttributes = _ref.quadrantsAttributes,
49619
+ dimension = _ref.dimension;
49619
49620
  var allPrefixes = {};
49620
49621
  var allPostfixes = {};
49621
49622
  var nullValues = {};
@@ -49765,9 +49766,11 @@ var buildBubbleChartRepresentation = function buildBubbleChartRepresentation(_re
49765
49766
 
49766
49767
  // ----- Lines -----
49767
49768
 
49768
- var groupByKey = (_formattedResult$fiel = (_formattedResult$fiel2 = formattedResult.fields.find(function (field) {
49769
- return field["function"] === 'none';
49770
- })) == null ? void 0 : _formattedResult$fiel2.id) != null ? _formattedResult$fiel : '';
49769
+ var dim = dimension[0];
49770
+ var groupByKey = id({
49771
+ field: dim.field,
49772
+ "function": dim["function"]
49773
+ });
49771
49774
  var styleDefinition = getStyleDefinition({
49772
49775
  colors: colors,
49773
49776
  yKeys: [].concat(yKeys, [xKey, zKey])
@@ -49915,7 +49918,8 @@ var BubbleChartV2View = function BubbleChartV2View(props) {
49915
49918
  quadrantsAttributes: props.attributes.quadrants,
49916
49919
  goalLineAttributes: (_props$attributes$goa = props.attributes.goalLines) != null ? _props$attributes$goa : [],
49917
49920
  conditionalFormattingAttributes: props.attributes.conditionalFormattingRules,
49918
- defaultFormats: props.defaultFormats
49921
+ defaultFormats: props.defaultFormats,
49922
+ dimension: props.attributes.dimension
49919
49923
  });
49920
49924
  }
49921
49925
 
@@ -50242,11 +50246,15 @@ var getConditionalFormatting$1 = function getConditionalFormatting(_ref) {
50242
50246
  operator: firstFilter.op,
50243
50247
  value: firstFilter.value,
50244
50248
  color: rule.ruleValue,
50245
- yKey: firstFilter["function"] ? firstFilter.field + "_" + firstFilter["function"] : firstFilter.field
50249
+ yKey: isValidFunctionName(firstFilter["function"]) ? firstFilter.field + "_" + firstFilter["function"] : firstFilter.field
50246
50250
  });
50247
50251
  });
50248
50252
  return conditionalFormattingRules;
50249
50253
  };
50254
+ function isValidFunctionName(functionName) {
50255
+ var invalidFunctionNames = [undefined, 'none'];
50256
+ return !invalidFunctionNames.includes(functionName);
50257
+ }
50250
50258
 
50251
50259
  function buildFieldFormatMaps(result, pivotConfig, xAxisPrefix, xAxisPostfix, xAxisFormat, yAxisPrefix, yAxisPostfix, yAxisFormat, nullValue, numberFormatOptions) {
50252
50260
  var allPrefixes = {};
@@ -33,6 +33,7 @@ interface buildBubbleChartRepresentationArgs {
33
33
  approxYAxisLabelCount: ApproxAxisLabelCount;
34
34
  zFieldId: string;
35
35
  quadrantsAttributes?: Component.Quadrant.Rule;
36
+ dimension: QueryAttributes.Dimension[];
36
37
  }
37
- export declare const buildBubbleChartRepresentation: ({ axisTitles, colors, conditionalFormattingAttributes, dateTimeFormatOptions, defaultFormats, goalLineAttributes, nullValue, numberFormatOptions, order, pivotConfig, result, xAxisFormat, xAxisPostfix, xAxisPrefix, yAxisFormat, yAxisPostfix, yAxisPrefix, approxYAxisLabelCount, valueAlias, zFieldId, quadrantsAttributes, }: buildBubbleChartRepresentationArgs) => BubbleChartRepresentation;
38
+ export declare const buildBubbleChartRepresentation: ({ axisTitles, colors, conditionalFormattingAttributes, dateTimeFormatOptions, defaultFormats, goalLineAttributes, nullValue, numberFormatOptions, order, pivotConfig, result, xAxisFormat, xAxisPostfix, xAxisPrefix, yAxisFormat, yAxisPostfix, yAxisPrefix, approxYAxisLabelCount, valueAlias, zFieldId, quadrantsAttributes, dimension, }: buildBubbleChartRepresentationArgs) => BubbleChartRepresentation;
38
39
  export {};
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@vizzly/dashboard",
3
3
  "author": "james@vizzly.co",
4
- "version": "0.15.0-dev-532824b8277b56794208595a2825194b1d110465",
4
+ "version": "0.15.0-dev-f90cb9fe016b8d74be9d3b023741ac8c219fd11b",
5
5
  "source": "src/index.tsx",
6
6
  "types": "./dist/dashboard/src/index.d.ts",
7
7
  "module": "./dist/dashboard.esm.js",