@datarailsshared/dr_renderer 1.2.320 → 1.2.321

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@datarailsshared/dr_renderer",
3
- "version": "1.2.320",
3
+ "version": "1.2.321",
4
4
  "description": "DataRails charts and tables renderer",
5
5
  "keywords": [
6
6
  "datarails",
@@ -9268,17 +9268,25 @@ let getHighchartsRenderer = function ($, document, Highcharts, default_colors, h
9268
9268
  }
9269
9269
 
9270
9270
  highchartsRenderer.checkFormats = function(render_options, widget_values_format) {
9271
- const isSecondaryAxis = lodash.some(render_options.comboOptions?.seriesOptions, series => series?.secondaryAxis);
9272
- const formats = lodash.map(render_options.comboOptions?.seriesOptions, series => series.format);
9271
+ let isSecondaryAxis = false;
9272
+ let formats = [];
9273
+ if (render_options && render_options.comboOptions && render_options.comboOptions.seriesOptions) {
9274
+ isSecondaryAxis = lodash.some(render_options.comboOptions.seriesOptions, series => series.secondaryAxis);
9275
+ formats = lodash.map(render_options.comboOptions.seriesOptions, series => series.format);
9276
+ }
9273
9277
  const isCustomFormat = !lodash.includes(formats, widget_values_format);
9274
9278
 
9275
9279
  return { isSecondaryAxis, isCustomFormat }
9276
9280
  }
9277
9281
 
9278
9282
  highchartsRenderer.getRecordFormats = function(render_options, recordName) {
9279
- return render_options?.comboOptions?.seriesOptions
9280
- .filter(series => series.series === recordName)
9281
- .map(series => series.format);
9283
+ let formats = [];
9284
+ if (render_options && render_options.comboOptions && render_options.comboOptions.seriesOptions) {
9285
+ formats = render_options.comboOptions.seriesOptions
9286
+ .filter(series => series.series === recordName)
9287
+ .map(series => series.format);
9288
+ }
9289
+ return formats;
9282
9290
  }
9283
9291
 
9284
9292
  highchartsRenderer.isCustomValuesFormat = function (render_options, widget_values_format) {