diff --git a/src/examples/liquid_fill_gauge/liquid_fill_gauge.ts b/src/examples/liquid_fill_gauge/liquid_fill_gauge.ts index 86c2dd8e..16c38395 100644 --- a/src/examples/liquid_fill_gauge/liquid_fill_gauge.ts +++ b/src/examples/liquid_fill_gauge/liquid_fill_gauge.ts @@ -208,7 +208,7 @@ const vis: LiquidFillGaugeVisualization = { this.svg.attr('id', elementId) }, // Render in response to the data or settings changing - update(data, element, config, queryResponse) { + update(data, element, config, queryResponse, details) { if (!handleErrors(this, queryResponse, { min_pivots: 0, max_pivots: 0, min_dimensions: 0, max_dimensions: undefined, @@ -222,6 +222,9 @@ const vis: LiquidFillGaugeVisualization = { if (gaugeConfig.maxValue <= 0) { this.addError({ group: 'config', title: 'Max value must be greater than zero.' }) return + } else if (data.length === 0) { + this.addError({ title: 'No results.' }) + return } else { this.clearErrors('config') }