diff --git a/public/app/plugins/panel/bargauge/BarGaugePanel.tsx b/public/app/plugins/panel/bargauge/BarGaugePanel.tsx index 2288c95b756..3a54036363c 100644 --- a/public/app/plugins/panel/bargauge/BarGaugePanel.tsx +++ b/public/app/plugins/panel/bargauge/BarGaugePanel.tsx @@ -28,7 +28,7 @@ export class BarGaugePanel extends PureComponent> { let processor: DisplayProcessor | undefined = undefined; if (view && isNumber(colIndex)) { - processor = view!.getFieldDisplayProcessor(colIndex as number); + processor = view.getFieldDisplayProcessor(colIndex); } return ( @@ -57,13 +57,14 @@ export class BarGaugePanel extends PureComponent> { if (hasLinks && getLinks) { return ( - - {(api) => { - return this.renderComponent(valueProps, api); - }} - +
+ + {(api) => this.renderComponent(valueProps, api)} + +
); } + return this.renderComponent(valueProps, {}); };